@razorpay/blade 11.36.0 → 11.36.1
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.
- package/build/lib/native/components/Input/BaseInput/BaseInput.js +1 -1
- package/build/lib/native/components/Input/BaseInput/BaseInput.js.map +1 -1
- package/build/lib/native/components/Input/BaseInput/BaseInputVisuals.js +2 -1
- package/build/lib/native/components/Input/BaseInput/BaseInputVisuals.js.map +1 -1
- package/build/lib/native/components/Input/DropdownInputTriggers/BaseDropdownInputTrigger.js +1 -1
- package/build/lib/native/components/Input/DropdownInputTriggers/BaseDropdownInputTrigger.js.map +1 -1
- package/build/lib/web/development/components/Input/BaseInput/BaseInput.js +3 -1
- package/build/lib/web/development/components/Input/BaseInput/BaseInput.js.map +1 -1
- package/build/lib/web/development/components/Input/BaseInput/BaseInputVisuals.js +77 -66
- package/build/lib/web/development/components/Input/BaseInput/BaseInputVisuals.js.map +1 -1
- package/build/lib/web/development/components/Input/DropdownInputTriggers/BaseDropdownInputTrigger.js +10 -10
- package/build/lib/web/development/components/Input/DropdownInputTriggers/BaseDropdownInputTrigger.js.map +1 -1
- package/build/lib/web/production/components/Input/BaseInput/BaseInput.js +3 -1
- package/build/lib/web/production/components/Input/BaseInput/BaseInput.js.map +1 -1
- package/build/lib/web/production/components/Input/BaseInput/BaseInputVisuals.js +77 -66
- package/build/lib/web/production/components/Input/BaseInput/BaseInputVisuals.js.map +1 -1
- package/build/lib/web/production/components/Input/DropdownInputTriggers/BaseDropdownInputTrigger.js +10 -10
- package/build/lib/web/production/components/Input/DropdownInputTriggers/BaseDropdownInputTrigger.js.map +1 -1
- package/build/types/components/index.d.ts +4 -0
- package/build/types/components/index.native.d.ts +4 -0
- package/package.json +1 -1
|
@@ -17,7 +17,7 @@ import { rowDensityToIsTableInputCellMapping, tableEditableCellRowDensityToInput
|
|
|
17
17
|
import { useTableEditableCell } from '../../Table/TableEditableCellContext.js';
|
|
18
18
|
import { jsx } from 'react/jsx-runtime';
|
|
19
19
|
|
|
20
|
-
var useControlledDropdownInput=function useControlledDropdownInput(props){var isFirstRender=useFirstRender();var _useDropdown=useDropdown(),changeCallbackTriggerer=_useDropdown.changeCallbackTriggerer,isControlled=_useDropdown.isControlled,options=_useDropdown.options,selectedIndices=_useDropdown.selectedIndices,controlledValueIndices=_useDropdown.controlledValueIndices,setSelectedIndices=_useDropdown.setSelectedIndices,selectionType=_useDropdown.selectionType,setIsControlled=_useDropdown.setIsControlled;var getValuesArrayFromIndices=function getValuesArrayFromIndices(){var indices=[];if(isControlled){indices=controlledValueIndices;}else {indices=selectedIndices;}return indices.map(function(selectionIndex){return options[selectionIndex].value;});};var selectValues=function selectValues(valuesToSelect){if(options.length>0){if(isEmpty(valuesToSelect)){setSelectedIndices([]);}else if(typeof valuesToSelect==='string'){var selectedItemIndex=options.findIndex(function(option){return option.value===valuesToSelect;});if(selectedItemIndex>=0){setSelectedIndices([selectedItemIndex]);}}else {var uniqueValues=Array.from(new Set(valuesToSelect));var userValues=selectionType==='single'?[valuesToSelect==null?void 0:valuesToSelect[0]]:uniqueValues;var selectedItemIndices=userValues.map(function(optionValue){return options.findIndex(function(option){return option.value===optionValue;});}).filter(function(value){return value>=0;});setSelectedIndices(selectedItemIndices);}}};React__default.useEffect(function(){if(options.length>0&&props.defaultValue){selectValues(props.defaultValue);}},[options.length]);React__default.useEffect(function(){if(options.length>0&&props.value!==undefined){if(!isControlled){setIsControlled(true);}selectValues(props.value);if(selectionType==='single'&&!Array.isArray(props.value)&&!props.isSelectInput){props.syncInputValueWithSelection==null?void 0:props.syncInputValueWithSelection(props.value);}}},[props.value,options]);React__default.useEffect(function(){if(!isFirstRender){props.onChange==null?void 0:props.onChange({name:props.name,values:getValuesArrayFromIndices()});}},[changeCallbackTriggerer]);};var _BaseDropdownInputTrigger=function _BaseDropdownInputTrigger(props,ref){var _props$placeholder,_props$validationStat,_props$maxRows,_props$label;var _useDropdown2=useDropdown(),isOpen=_useDropdown2.isOpen,activeTagIndex=_useDropdown2.activeTagIndex,setActiveTagIndex=_useDropdown2.setActiveTagIndex,displayValue=_useDropdown2.displayValue,selectionType=_useDropdown2.selectionType,dropdownTriggerer=_useDropdown2.dropdownTriggerer,dropdownBaseId=_useDropdown2.dropdownBaseId,selectedIndices=_useDropdown2.selectedIndices,triggererRef=_useDropdown2.triggererRef,triggererWrapperRef=_useDropdown2.triggererWrapperRef,isTagDismissedRef=_useDropdown2.isTagDismissedRef,onTriggerClick=_useDropdown2.onTriggerClick,value=_useDropdown2.value,shouldIgnoreBlurAnimation=_useDropdown2.shouldIgnoreBlurAnimation,setShouldIgnoreBlurAnimation=_useDropdown2.setShouldIgnoreBlurAnimation,activeIndex=_useDropdown2.activeIndex,hasFooterAction=_useDropdown2.hasFooterAction,hasAutoCompleteInBottomSheetHeader=_useDropdown2.hasAutoCompleteInBottomSheetHeader,options=_useDropdown2.options,removeOption=_useDropdown2.removeOption,setChangeCallbackTriggerer=_useDropdown2.setChangeCallbackTriggerer,changeCallbackTriggerer=_useDropdown2.changeCallbackTriggerer;var _useTableContext=useTableContext(),rowDensity=_useTableContext.rowDensity;var _useTableEditableCell=useTableEditableCell(),isInsideTableEditableCell=_useTableEditableCell.isInsideTableEditableCell;var dropdownTriggerPlaceholder=(_props$placeholder=props.placeholder)!=null?_props$placeholder:'Select Option';var isAutoCompleteInHeader=!props.isSelectInput&&hasAutoCompleteInBottomSheetHeader;var getShowAllTags=React__default.useCallback(function(){if(hasAutoCompleteInBottomSheetHeader){if(props.isSelectInput){return false;}return true;}return isOpen;},[hasAutoCompleteInBottomSheetHeader,props.isSelectInput,isOpen]);useControlledDropdownInput({onChange:props.onChange,name:props.name,value:props.value,defaultValue:props.defaultValue,syncInputValueWithSelection:props.syncInputValueWithSelection,isSelectInput:props.isSelectInput});var getValue=function getValue(){var prefix='';if(props.labelPosition==='inside-input'&&props.label){prefix=`${props.label}: `;}if(props.isSelectInput){if(selectionType==='single'){return `${prefix}${displayValue}`;}return undefined;}return props.inputValue;};var getTags=React__default.useMemo(function(){return function(_ref){var size=_ref.size;if(selectionType==='single'){return undefined;}return getTagsGroup({size:size,tags:selectedIndices.map(function(selectedIndex){var _options$selectedInde;return (_options$selectedInde=options[selectedIndex])==null?void 0:_options$selectedInde.title;}),activeTagIndex:activeTagIndex,isDisabled:props.isDisabled,onDismiss:function onDismiss(_ref2){var tagIndex=_ref2.tagIndex;if(isTagDismissedRef.current){isTagDismissedRef.current.value=true;}if(!isReactNative()){var _triggererRef$current;(_triggererRef$current=triggererRef.current)==null?void 0:_triggererRef$current.focus();}removeOption(selectedIndices[tagIndex]);setChangeCallbackTriggerer(Number(changeCallbackTriggerer)+1);}});};},[selectedIndices,selectionType,activeTagIndex,changeCallbackTriggerer,options]);var tableInputProps={isTableInputCell:rowDensityToIsTableInputCellMapping[rowDensity],id:'table-editable-cell-input',size:tableEditableCellRowDensityToInputSizeMap[rowDensity],trailingIcon:validationStateToInputTrailingIconMap[(_props$validationStat=props.validationState)!=null?_props$validationStat:'none'],showHintsAsTooltip:true};var isValidationStateNone=props.validationState==='none'||props.validationState===undefined;return jsx(BaseInput,Object.assign({as:props.isSelectInput?'button':'input',ref:!isReactNative()?function(node){triggererRef.current=node;if(ref){if(typeof ref==='function'){ref(node);}else {ref.current=node;}}}:null,isDropdownTrigger:true,setInputWrapperRef:function setInputWrapperRef(wrapperNode){triggererWrapperRef.current=wrapperNode;},maxTagRows:(_props$maxRows=props.maxRows)!=null?_props$maxRows:'single',tags:getTags({size:props.size||'medium'}),showAllTags:getShowAllTags(),activeTagIndex:activeTagIndex,setActiveTagIndex:setActiveTagIndex,shouldIgnoreBlurAnimation:shouldIgnoreBlurAnimation,setShouldIgnoreBlurAnimation:setShouldIgnoreBlurAnimation,textAlign:"left",label:props.label,placeholder:selectionType==='multiple'&&selectedIndices.length>0?undefined:dropdownTriggerPlaceholder,hideLabelText:((_props$label=props.label)==null?void 0:_props$label.length)===0,accessibilityLabel:props.accessibilityLabel,labelPosition:props.labelPosition==='inside-input'?undefined:props.labelPosition,isLabelInsideInput:props.labelPosition==='inside-input',necessityIndicator:props.necessityIndicator,autoCompleteSuggestionType:"none",validationState:props.validationState,helpText:props.helpText,errorText:props.errorText,successText:props.successText,name:props.name,isDisabled:props.isDisabled,isRequired:props.isRequired,prefix:props.prefix,suffix:props.suffix,autoFocus:props.autoFocus,value:getValue(),onClick:function onClick(e){if(props.isDisabled){return;}props.onTriggerClick==null?void 0:props.onTriggerClick(e);},onFocus:props.onFocus,onBlur:function onBlur(_ref3){var name=_ref3.name;props.onBlur==null?void 0:props.onBlur({name:name,value:value});},leadingIcon:props.icon,componentName:props.isSelectInput?MetaConstants.SelectInput:MetaConstants.AutoComplete,testID:props.testID,id:`${dropdownBaseId}-trigger`,labelId:`${dropdownBaseId}-label`,hasPopup:getActionListContainerRole(hasFooterAction,dropdownTriggerer),isPopupExpanded:isOpen,activeDescendant:activeIndex>=0?`${dropdownBaseId}-${activeIndex}`:undefined,popupId:`${dropdownBaseId}-actionlist`,onChange:props.isSelectInput?undefined:props.onInputValueChange,onKeyDown:props.onTriggerKeydown,size:props.size,
|
|
20
|
+
var useControlledDropdownInput=function useControlledDropdownInput(props){var isFirstRender=useFirstRender();var _useDropdown=useDropdown(),changeCallbackTriggerer=_useDropdown.changeCallbackTriggerer,isControlled=_useDropdown.isControlled,options=_useDropdown.options,selectedIndices=_useDropdown.selectedIndices,controlledValueIndices=_useDropdown.controlledValueIndices,setSelectedIndices=_useDropdown.setSelectedIndices,selectionType=_useDropdown.selectionType,setIsControlled=_useDropdown.setIsControlled;var getValuesArrayFromIndices=function getValuesArrayFromIndices(){var indices=[];if(isControlled){indices=controlledValueIndices;}else {indices=selectedIndices;}return indices.map(function(selectionIndex){return options[selectionIndex].value;});};var selectValues=function selectValues(valuesToSelect){if(options.length>0){if(isEmpty(valuesToSelect)){setSelectedIndices([]);}else if(typeof valuesToSelect==='string'){var selectedItemIndex=options.findIndex(function(option){return option.value===valuesToSelect;});if(selectedItemIndex>=0){setSelectedIndices([selectedItemIndex]);}}else {var uniqueValues=Array.from(new Set(valuesToSelect));var userValues=selectionType==='single'?[valuesToSelect==null?void 0:valuesToSelect[0]]:uniqueValues;var selectedItemIndices=userValues.map(function(optionValue){return options.findIndex(function(option){return option.value===optionValue;});}).filter(function(value){return value>=0;});setSelectedIndices(selectedItemIndices);}}};React__default.useEffect(function(){if(options.length>0&&props.defaultValue){selectValues(props.defaultValue);}},[options.length]);React__default.useEffect(function(){if(options.length>0&&props.value!==undefined){if(!isControlled){setIsControlled(true);}selectValues(props.value);if(selectionType==='single'&&!Array.isArray(props.value)&&!props.isSelectInput){props.syncInputValueWithSelection==null?void 0:props.syncInputValueWithSelection(props.value);}}},[props.value,options]);React__default.useEffect(function(){if(!isFirstRender){props.onChange==null?void 0:props.onChange({name:props.name,values:getValuesArrayFromIndices()});}},[changeCallbackTriggerer]);};var _BaseDropdownInputTrigger=function _BaseDropdownInputTrigger(props,ref){var _props$placeholder,_props$validationStat,_props$maxRows,_props$label;var _useDropdown2=useDropdown(),isOpen=_useDropdown2.isOpen,activeTagIndex=_useDropdown2.activeTagIndex,setActiveTagIndex=_useDropdown2.setActiveTagIndex,displayValue=_useDropdown2.displayValue,selectionType=_useDropdown2.selectionType,dropdownTriggerer=_useDropdown2.dropdownTriggerer,dropdownBaseId=_useDropdown2.dropdownBaseId,selectedIndices=_useDropdown2.selectedIndices,triggererRef=_useDropdown2.triggererRef,triggererWrapperRef=_useDropdown2.triggererWrapperRef,isTagDismissedRef=_useDropdown2.isTagDismissedRef,onTriggerClick=_useDropdown2.onTriggerClick,value=_useDropdown2.value,shouldIgnoreBlurAnimation=_useDropdown2.shouldIgnoreBlurAnimation,setShouldIgnoreBlurAnimation=_useDropdown2.setShouldIgnoreBlurAnimation,activeIndex=_useDropdown2.activeIndex,hasFooterAction=_useDropdown2.hasFooterAction,hasAutoCompleteInBottomSheetHeader=_useDropdown2.hasAutoCompleteInBottomSheetHeader,options=_useDropdown2.options,removeOption=_useDropdown2.removeOption,setChangeCallbackTriggerer=_useDropdown2.setChangeCallbackTriggerer,changeCallbackTriggerer=_useDropdown2.changeCallbackTriggerer;var _useTableContext=useTableContext(),rowDensity=_useTableContext.rowDensity;var _useTableEditableCell=useTableEditableCell(),isInsideTableEditableCell=_useTableEditableCell.isInsideTableEditableCell;var dropdownTriggerPlaceholder=(_props$placeholder=props.placeholder)!=null?_props$placeholder:'Select Option';var isAutoCompleteInHeader=!props.isSelectInput&&hasAutoCompleteInBottomSheetHeader;var getShowAllTags=React__default.useCallback(function(){if(hasAutoCompleteInBottomSheetHeader){if(props.isSelectInput){return false;}return true;}return isOpen;},[hasAutoCompleteInBottomSheetHeader,props.isSelectInput,isOpen]);useControlledDropdownInput({onChange:props.onChange,name:props.name,value:props.value,defaultValue:props.defaultValue,syncInputValueWithSelection:props.syncInputValueWithSelection,isSelectInput:props.isSelectInput});var getValue=function getValue(){var prefix='';if(props.labelPosition==='inside-input'&&props.label){prefix=`${props.label}: `;}if(props.isSelectInput){if(selectionType==='single'){return `${prefix}${displayValue}`;}return undefined;}return props.inputValue;};var getTags=React__default.useMemo(function(){return function(_ref){var size=_ref.size;if(selectionType==='single'){return undefined;}return getTagsGroup({size:size,tags:selectedIndices.map(function(selectedIndex){var _options$selectedInde;return (_options$selectedInde=options[selectedIndex])==null?void 0:_options$selectedInde.title;}),activeTagIndex:activeTagIndex,isDisabled:props.isDisabled,onDismiss:function onDismiss(_ref2){var tagIndex=_ref2.tagIndex;if(isTagDismissedRef.current){isTagDismissedRef.current.value=true;}if(!isReactNative()){var _triggererRef$current;(_triggererRef$current=triggererRef.current)==null?void 0:_triggererRef$current.focus();}removeOption(selectedIndices[tagIndex]);setChangeCallbackTriggerer(Number(changeCallbackTriggerer)+1);}});};},[selectedIndices,selectionType,activeTagIndex,changeCallbackTriggerer,options]);var tableInputProps={isTableInputCell:rowDensityToIsTableInputCellMapping[rowDensity],id:'table-editable-cell-input',size:tableEditableCellRowDensityToInputSizeMap[rowDensity],trailingIcon:validationStateToInputTrailingIconMap[(_props$validationStat=props.validationState)!=null?_props$validationStat:'none'],showHintsAsTooltip:true};var isValidationStateNone=props.validationState==='none'||props.validationState===undefined;return jsx(BaseInput,Object.assign({as:props.isSelectInput?'button':'input',ref:!isReactNative()?function(node){triggererRef.current=node;if(ref){if(typeof ref==='function'){ref(node);}else {ref.current=node;}}}:null,isDropdownTrigger:true,setInputWrapperRef:function setInputWrapperRef(wrapperNode){triggererWrapperRef.current=wrapperNode;},maxTagRows:(_props$maxRows=props.maxRows)!=null?_props$maxRows:'single',tags:getTags({size:props.size||'medium'}),showAllTags:getShowAllTags(),activeTagIndex:activeTagIndex,setActiveTagIndex:setActiveTagIndex,shouldIgnoreBlurAnimation:shouldIgnoreBlurAnimation,setShouldIgnoreBlurAnimation:setShouldIgnoreBlurAnimation,textAlign:"left",label:props.label,placeholder:selectionType==='multiple'&&selectedIndices.length>0?undefined:dropdownTriggerPlaceholder,hideLabelText:((_props$label=props.label)==null?void 0:_props$label.length)===0,accessibilityLabel:props.accessibilityLabel,labelPosition:props.labelPosition==='inside-input'?undefined:props.labelPosition,isLabelInsideInput:props.labelPosition==='inside-input',necessityIndicator:props.necessityIndicator,autoCompleteSuggestionType:"none",validationState:props.validationState,helpText:props.helpText,errorText:props.errorText,successText:props.successText,name:props.name,isDisabled:props.isDisabled,isRequired:props.isRequired,prefix:props.prefix,suffix:props.suffix,autoFocus:props.autoFocus,value:getValue(),onClick:function onClick(e){if(props.isDisabled){return;}props.onTriggerClick==null?void 0:props.onTriggerClick(e);},onFocus:props.onFocus,onBlur:function onBlur(_ref3){var name=_ref3.name;props.onBlur==null?void 0:props.onBlur({name:name,value:value});},leadingIcon:props.icon,componentName:props.isSelectInput?MetaConstants.SelectInput:MetaConstants.AutoComplete,testID:props.testID,id:`${dropdownBaseId}-trigger`,labelId:`${dropdownBaseId}-label`,hasPopup:getActionListContainerRole(hasFooterAction,dropdownTriggerer),isPopupExpanded:isOpen,activeDescendant:activeIndex>=0?`${dropdownBaseId}-${activeIndex}`:undefined,popupId:`${dropdownBaseId}-actionlist`,onChange:props.isSelectInput?undefined:props.onInputValueChange,onKeyDown:props.onTriggerKeydown,size:props.size,onTrailingInteractionElementClick:function onTrailingInteractionElementClick(){if(!props.isDisabled){if(!isReactNative()){var _triggererRef$current2;(_triggererRef$current2=triggererRef.current)==null?void 0:_triggererRef$current2.focus();}onTriggerClick();}},trailingInteractionElement:isAutoCompleteInHeader||isInsideTableEditableCell&&!isValidationStateNone?null:jsx(InputChevronIcon,{isDisabled:props.isDisabled,isOpen:isOpen})},isInsideTableEditableCell?tableInputProps:undefined));};var BaseDropdownInputTrigger=React__default.forwardRef(_BaseDropdownInputTrigger);
|
|
21
21
|
|
|
22
22
|
export { BaseDropdownInputTrigger };
|
|
23
23
|
//# sourceMappingURL=BaseDropdownInputTrigger.js.map
|
package/build/lib/native/components/Input/DropdownInputTriggers/BaseDropdownInputTrigger.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseDropdownInputTrigger.js","sources":["../../../../../../src/components/Input/DropdownInputTriggers/BaseDropdownInputTrigger.tsx"],"sourcesContent":["import React from 'react';\nimport { BaseInput } from '../BaseInput';\nimport type { BaseInputProps } from '../BaseInput';\nimport { InputChevronIcon } from './InputChevronIcon';\nimport type { BaseDropdownInputTriggerProps } from './types';\nimport isEmpty from '~utils/lodashButBetter/isEmpty';\nimport { useDropdown } from '~components/Dropdown/useDropdown';\nimport { isReactNative } from '~utils';\nimport { getActionListContainerRole } from '~components/ActionList/getA11yRoles';\nimport { MetaConstants } from '~utils/metaAttribute';\nimport { getTagsGroup } from '~components/Tag/getTagsGroup';\nimport type { BladeElementRef } from '~utils/types';\nimport { useFirstRender } from '~utils/useFirstRender';\nimport { useTableContext } from '~components/Table/TableContext';\nimport {\n rowDensityToIsTableInputCellMapping,\n tableEditableCellRowDensityToInputSizeMap,\n validationStateToInputTrailingIconMap,\n} from '~components/Table/tokens';\nimport { useTableEditableCell } from '~components/Table/TableEditableCellContext';\n\nconst useControlledDropdownInput = (\n props: Pick<\n BaseDropdownInputTriggerProps,\n | 'onChange'\n | 'name'\n | 'value'\n | 'defaultValue'\n | 'onInputValueChange'\n | 'syncInputValueWithSelection'\n | 'isSelectInput'\n >,\n): void => {\n const isFirstRender = useFirstRender();\n const {\n changeCallbackTriggerer,\n isControlled,\n options,\n selectedIndices,\n controlledValueIndices,\n setSelectedIndices,\n selectionType,\n setIsControlled,\n } = useDropdown();\n\n const getValuesArrayFromIndices = (): string[] => {\n let indices: number[] = [];\n if (isControlled) {\n indices = controlledValueIndices;\n } else {\n indices = selectedIndices;\n }\n\n return indices.map((selectionIndex) => options[selectionIndex].value);\n };\n\n const selectValues = (valuesToSelect: string | string[]): void => {\n if (options.length > 0) {\n // we use empty `''` for clearing the input\n if (isEmpty(valuesToSelect)) {\n setSelectedIndices([]);\n } else if (typeof valuesToSelect === 'string') {\n // single select control\n const selectedItemIndex = options.findIndex((option) => option.value === valuesToSelect);\n if (selectedItemIndex >= 0) {\n setSelectedIndices([selectedItemIndex]);\n }\n } else {\n // multiselect control\n\n // Handles repeated values in user state\n const uniqueValues = Array.from(new Set(valuesToSelect));\n // Handle selectionType single with multiselect values\n const userValues = selectionType === 'single' ? [valuesToSelect?.[0]] : uniqueValues;\n\n const selectedItemIndices = userValues\n .map((optionValue) => options.findIndex((option) => option.value === optionValue))\n .filter((value) => value >= 0);\n\n setSelectedIndices(selectedItemIndices);\n }\n }\n };\n\n // Handles `defaultValue` prop\n React.useEffect(() => {\n if (options.length > 0 && props.defaultValue) {\n selectValues(props.defaultValue);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [options.length]);\n\n // Handles `value` prop\n React.useEffect(() => {\n if (options.length > 0 && props.value !== undefined) {\n if (!isControlled) {\n setIsControlled(true);\n }\n\n selectValues(props.value);\n\n // in single select AutoComplete, we have to set inputValue of autocomplete according to the new selection.\n if (selectionType === 'single' && !Array.isArray(props.value) && !props.isSelectInput) {\n props.syncInputValueWithSelection?.(props.value);\n }\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [props.value, options]);\n\n // onChange behaviour\n React.useEffect(() => {\n // Ignore calling onChange on mount\n\n if (!isFirstRender) {\n props.onChange?.({\n name: props.name,\n values: getValuesArrayFromIndices(),\n });\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [changeCallbackTriggerer]);\n};\n\nconst _BaseDropdownInputTrigger = (\n props: BaseDropdownInputTriggerProps,\n ref: React.ForwardedRef<BladeElementRef>,\n): React.ReactElement => {\n const {\n isOpen,\n activeTagIndex,\n setActiveTagIndex,\n displayValue,\n selectionType,\n dropdownTriggerer,\n dropdownBaseId,\n selectedIndices,\n triggererRef,\n triggererWrapperRef,\n isTagDismissedRef,\n onTriggerClick,\n value,\n shouldIgnoreBlurAnimation,\n setShouldIgnoreBlurAnimation,\n activeIndex,\n hasFooterAction,\n hasAutoCompleteInBottomSheetHeader,\n options,\n removeOption,\n setChangeCallbackTriggerer,\n changeCallbackTriggerer,\n } = useDropdown();\n const { rowDensity } = useTableContext();\n const { isInsideTableEditableCell } = useTableEditableCell();\n\n const dropdownTriggerPlaceholder = props.placeholder ?? 'Select Option';\n const isAutoCompleteInHeader = !props.isSelectInput && hasAutoCompleteInBottomSheetHeader;\n\n const getShowAllTags = React.useCallback((): boolean => {\n if (hasAutoCompleteInBottomSheetHeader) {\n // When AutoComplete is in bottomsheet header, we never want to show all tags in outer select input\n if (props.isSelectInput) {\n return false;\n }\n\n // ... And we always want to show all tags in inner AutoComplete\n return true;\n }\n\n return isOpen;\n }, [hasAutoCompleteInBottomSheetHeader, props.isSelectInput, isOpen]);\n\n useControlledDropdownInput({\n onChange: props.onChange,\n name: props.name,\n value: props.value,\n defaultValue: props.defaultValue,\n syncInputValueWithSelection: props.syncInputValueWithSelection,\n isSelectInput: props.isSelectInput,\n });\n\n const getValue = (): string | undefined => {\n let prefix = '';\n if (props.labelPosition === 'inside-input' && props.label) {\n prefix = `${props.label}: `;\n }\n\n if (props.isSelectInput) {\n if (selectionType === 'single') {\n return `${prefix}${displayValue}`;\n }\n\n // In multiselect, we return tags so no display value is required\n return undefined;\n }\n\n // In AutoComplete, input has a special value too\n return props.inputValue;\n };\n\n const getTags = React.useMemo(\n () => ({ size }: { size: NonNullable<BaseInputProps['size']> }) => {\n if (selectionType === 'single') {\n return undefined;\n }\n\n return getTagsGroup({\n size,\n tags: selectedIndices.map((selectedIndex) => options[selectedIndex]?.title),\n activeTagIndex,\n isDisabled: props.isDisabled,\n onDismiss: ({ tagIndex }) => {\n if (isTagDismissedRef.current) {\n isTagDismissedRef.current.value = true;\n }\n\n if (!isReactNative()) {\n triggererRef.current?.focus();\n }\n\n removeOption(selectedIndices[tagIndex]);\n setChangeCallbackTriggerer(Number(changeCallbackTriggerer) + 1);\n },\n });\n },\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [selectedIndices, selectionType, activeTagIndex, changeCallbackTriggerer, options],\n );\n\n const tableInputProps: Partial<BaseInputProps> = {\n isTableInputCell: rowDensityToIsTableInputCellMapping[rowDensity],\n id: 'table-editable-cell-input',\n size: tableEditableCellRowDensityToInputSizeMap[rowDensity],\n trailingIcon: validationStateToInputTrailingIconMap[props.validationState ?? 'none'],\n showHintsAsTooltip: true,\n };\n\n const isValidationStateNone =\n props.validationState === 'none' || props.validationState === undefined;\n\n return (\n <BaseInput\n as={props.isSelectInput ? 'button' : 'input'}\n ref={\n (!isReactNative()\n ? // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (node: any) => {\n triggererRef.current = node;\n if (ref) {\n if (typeof ref === 'function') {\n ref(node);\n } else {\n ref.current = node;\n }\n }\n }\n : null) as never\n }\n isDropdownTrigger={true}\n setInputWrapperRef={(wrapperNode) => {\n triggererWrapperRef.current = wrapperNode;\n }}\n maxTagRows={props.maxRows ?? 'single'}\n tags={getTags({ size: props.size || 'medium' })}\n showAllTags={getShowAllTags()}\n activeTagIndex={activeTagIndex}\n setActiveTagIndex={setActiveTagIndex}\n shouldIgnoreBlurAnimation={shouldIgnoreBlurAnimation}\n setShouldIgnoreBlurAnimation={setShouldIgnoreBlurAnimation}\n textAlign=\"left\"\n // Form Props\n label={props.label as string}\n placeholder={\n selectionType === 'multiple' && selectedIndices.length > 0\n ? undefined\n : dropdownTriggerPlaceholder\n }\n hideLabelText={props.label?.length === 0}\n accessibilityLabel={props.accessibilityLabel}\n labelPosition={props.labelPosition === 'inside-input' ? undefined : props.labelPosition}\n isLabelInsideInput={props.labelPosition === 'inside-input'}\n necessityIndicator={props.necessityIndicator}\n autoCompleteSuggestionType=\"none\"\n validationState={props.validationState}\n helpText={props.helpText}\n errorText={props.errorText}\n successText={props.successText}\n name={props.name}\n isDisabled={props.isDisabled}\n isRequired={props.isRequired}\n prefix={props.prefix}\n suffix={props.suffix}\n autoFocus={props.autoFocus} // eslint-disable-line jsx-a11y/no-autofocus\n value={getValue()}\n onClick={(e) => {\n if (props.isDisabled) {\n return;\n }\n props.onTriggerClick?.(e);\n }}\n onFocus={props.onFocus}\n onBlur={({ name }) => {\n props.onBlur?.({ name, value });\n }}\n leadingIcon={props.icon}\n // Meta Props\n componentName={props.isSelectInput ? MetaConstants.SelectInput : MetaConstants.AutoComplete}\n testID={props.testID}\n // a11y Props\n id={`${dropdownBaseId}-trigger`}\n labelId={`${dropdownBaseId}-label`}\n hasPopup={getActionListContainerRole(hasFooterAction, dropdownTriggerer)}\n isPopupExpanded={isOpen}\n activeDescendant={activeIndex >= 0 ? `${dropdownBaseId}-${activeIndex}` : undefined}\n popupId={`${dropdownBaseId}-actionlist`}\n // Special Props for Unique behaviour between Select and AutoComplete\n onChange={props.isSelectInput ? undefined : props.onInputValueChange}\n onKeyDown={props.onTriggerKeydown}\n size={props.size}\n trailingInteractionElement={\n isAutoCompleteInHeader || (isInsideTableEditableCell && !isValidationStateNone) ? null : (\n <InputChevronIcon\n onClick={() => {\n if (!props.isDisabled) {\n // Icon onClicks to the SelectInput itself\n if (!isReactNative()) {\n triggererRef.current?.focus();\n }\n onTriggerClick();\n }\n }}\n isDisabled={props.isDisabled}\n isOpen={isOpen}\n />\n )\n }\n {...(isInsideTableEditableCell ? tableInputProps : undefined)}\n />\n );\n};\n\nconst BaseDropdownInputTrigger = React.forwardRef(_BaseDropdownInputTrigger);\n\nexport { BaseDropdownInputTrigger };\n"],"names":["useControlledDropdownInput","props","isFirstRender","useFirstRender","_useDropdown","useDropdown","changeCallbackTriggerer","isControlled","options","selectedIndices","controlledValueIndices","setSelectedIndices","selectionType","setIsControlled","getValuesArrayFromIndices","indices","map","selectionIndex","value","selectValues","valuesToSelect","length","isEmpty","selectedItemIndex","findIndex","option","uniqueValues","Array","from","Set","userValues","selectedItemIndices","optionValue","filter","React","useEffect","defaultValue","undefined","isArray","isSelectInput","syncInputValueWithSelection","onChange","name","values","_BaseDropdownInputTrigger","ref","_props$placeholder","_props$validationStat","_props$maxRows","_props$label","_useDropdown2","isOpen","activeTagIndex","setActiveTagIndex","displayValue","dropdownTriggerer","dropdownBaseId","triggererRef","triggererWrapperRef","isTagDismissedRef","onTriggerClick","shouldIgnoreBlurAnimation","setShouldIgnoreBlurAnimation","activeIndex","hasFooterAction","hasAutoCompleteInBottomSheetHeader","removeOption","setChangeCallbackTriggerer","_useTableContext","useTableContext","rowDensity","_useTableEditableCell","useTableEditableCell","isInsideTableEditableCell","dropdownTriggerPlaceholder","placeholder","isAutoCompleteInHeader","getShowAllTags","useCallback","getValue","prefix","labelPosition","label","inputValue","getTags","useMemo","_ref","size","getTagsGroup","tags","selectedIndex","_options$selectedInde","title","isDisabled","onDismiss","_ref2","tagIndex","current","isReactNative","_triggererRef$current","focus","Number","tableInputProps","isTableInputCell","rowDensityToIsTableInputCellMapping","id","tableEditableCellRowDensityToInputSizeMap","trailingIcon","validationStateToInputTrailingIconMap","validationState","showHintsAsTooltip","isValidationStateNone","_jsx","BaseInput","Object","assign","as","node","isDropdownTrigger","setInputWrapperRef","wrapperNode","maxTagRows","maxRows","showAllTags","textAlign","hideLabelText","accessibilityLabel","isLabelInsideInput","necessityIndicator","autoCompleteSuggestionType","helpText","errorText","successText","isRequired","suffix","autoFocus","onClick","e","onFocus","onBlur","_ref3","leadingIcon","icon","componentName","MetaConstants","SelectInput","AutoComplete","testID","labelId","hasPopup","getActionListContainerRole","isPopupExpanded","activeDescendant","popupId","onInputValueChange","onKeyDown","onTriggerKeydown","trailingInteractionElement","InputChevronIcon","_triggererRef$current2","BaseDropdownInputTrigger","forwardRef"],"mappings":";;;;;;;;;;;;;;;;;;;AAqBA,IAAMA,0BAA0B,CAAG,SAA7BA,0BAA0BA,CAC9BC,KASC,CACQ,CACT,IAAMC,aAAa,CAAGC,cAAc,EAAE,CACtC,IAAAC,YAAA,CASIC,WAAW,EAAE,CARfC,uBAAuB,CAAAF,YAAA,CAAvBE,uBAAuB,CACvBC,YAAY,CAAAH,YAAA,CAAZG,YAAY,CACZC,OAAO,CAAAJ,YAAA,CAAPI,OAAO,CACPC,eAAe,CAAAL,YAAA,CAAfK,eAAe,CACfC,sBAAsB,CAAAN,YAAA,CAAtBM,sBAAsB,CACtBC,kBAAkB,CAAAP,YAAA,CAAlBO,kBAAkB,CAClBC,aAAa,CAAAR,YAAA,CAAbQ,aAAa,CACbC,eAAe,CAAAT,YAAA,CAAfS,eAAe,CAGjB,IAAMC,yBAAyB,CAAG,SAA5BA,yBAAyBA,EAAmB,CAChD,IAAIC,OAAiB,CAAG,EAAE,CAC1B,GAAIR,YAAY,CAAE,CAChBQ,OAAO,CAAGL,sBAAsB,CAClC,CAAC,KAAM,CACLK,OAAO,CAAGN,eAAe,CAC3B,CAEA,OAAOM,OAAO,CAACC,GAAG,CAAC,SAACC,cAAc,SAAKT,OAAO,CAACS,cAAc,CAAC,CAACC,KAAK,CAAC,CAAA,CAAA,CACvE,CAAC,CAED,IAAMC,YAAY,CAAG,SAAfA,YAAYA,CAAIC,cAAiC,CAAW,CAChE,GAAIZ,OAAO,CAACa,MAAM,CAAG,CAAC,CAAE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CAAAA,yBAAyB,CAAG6B,eAAe,CAAGjE,SAAS,CAC7D,CAAC,CAEN,CAAC,CAEK,IAAA2H,wBAAwB,CAAG9H,cAAK,CAAC+H,UAAU,CAACrH,yBAAyB;;;;"}
|
|
1
|
+
{"version":3,"file":"BaseDropdownInputTrigger.js","sources":["../../../../../../src/components/Input/DropdownInputTriggers/BaseDropdownInputTrigger.tsx"],"sourcesContent":["import React from 'react';\nimport { BaseInput } from '../BaseInput';\nimport type { BaseInputProps } from '../BaseInput';\nimport { InputChevronIcon } from './InputChevronIcon';\nimport type { BaseDropdownInputTriggerProps } from './types';\nimport isEmpty from '~utils/lodashButBetter/isEmpty';\nimport { useDropdown } from '~components/Dropdown/useDropdown';\nimport { isReactNative } from '~utils';\nimport { getActionListContainerRole } from '~components/ActionList/getA11yRoles';\nimport { MetaConstants } from '~utils/metaAttribute';\nimport { getTagsGroup } from '~components/Tag/getTagsGroup';\nimport type { BladeElementRef } from '~utils/types';\nimport { useFirstRender } from '~utils/useFirstRender';\nimport { useTableContext } from '~components/Table/TableContext';\nimport {\n rowDensityToIsTableInputCellMapping,\n tableEditableCellRowDensityToInputSizeMap,\n validationStateToInputTrailingIconMap,\n} from '~components/Table/tokens';\nimport { useTableEditableCell } from '~components/Table/TableEditableCellContext';\n\nconst useControlledDropdownInput = (\n props: Pick<\n BaseDropdownInputTriggerProps,\n | 'onChange'\n | 'name'\n | 'value'\n | 'defaultValue'\n | 'onInputValueChange'\n | 'syncInputValueWithSelection'\n | 'isSelectInput'\n >,\n): void => {\n const isFirstRender = useFirstRender();\n const {\n changeCallbackTriggerer,\n isControlled,\n options,\n selectedIndices,\n controlledValueIndices,\n setSelectedIndices,\n selectionType,\n setIsControlled,\n } = useDropdown();\n\n const getValuesArrayFromIndices = (): string[] => {\n let indices: number[] = [];\n if (isControlled) {\n indices = controlledValueIndices;\n } else {\n indices = selectedIndices;\n }\n\n return indices.map((selectionIndex) => options[selectionIndex].value);\n };\n\n const selectValues = (valuesToSelect: string | string[]): void => {\n if (options.length > 0) {\n // we use empty `''` for clearing the input\n if (isEmpty(valuesToSelect)) {\n setSelectedIndices([]);\n } else if (typeof valuesToSelect === 'string') {\n // single select control\n const selectedItemIndex = options.findIndex((option) => option.value === valuesToSelect);\n if (selectedItemIndex >= 0) {\n setSelectedIndices([selectedItemIndex]);\n }\n } else {\n // multiselect control\n\n // Handles repeated values in user state\n const uniqueValues = Array.from(new Set(valuesToSelect));\n // Handle selectionType single with multiselect values\n const userValues = selectionType === 'single' ? [valuesToSelect?.[0]] : uniqueValues;\n\n const selectedItemIndices = userValues\n .map((optionValue) => options.findIndex((option) => option.value === optionValue))\n .filter((value) => value >= 0);\n\n setSelectedIndices(selectedItemIndices);\n }\n }\n };\n\n // Handles `defaultValue` prop\n React.useEffect(() => {\n if (options.length > 0 && props.defaultValue) {\n selectValues(props.defaultValue);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [options.length]);\n\n // Handles `value` prop\n React.useEffect(() => {\n if (options.length > 0 && props.value !== undefined) {\n if (!isControlled) {\n setIsControlled(true);\n }\n\n selectValues(props.value);\n\n // in single select AutoComplete, we have to set inputValue of autocomplete according to the new selection.\n if (selectionType === 'single' && !Array.isArray(props.value) && !props.isSelectInput) {\n props.syncInputValueWithSelection?.(props.value);\n }\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [props.value, options]);\n\n // onChange behaviour\n React.useEffect(() => {\n // Ignore calling onChange on mount\n\n if (!isFirstRender) {\n props.onChange?.({\n name: props.name,\n values: getValuesArrayFromIndices(),\n });\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [changeCallbackTriggerer]);\n};\n\nconst _BaseDropdownInputTrigger = (\n props: BaseDropdownInputTriggerProps,\n ref: React.ForwardedRef<BladeElementRef>,\n): React.ReactElement => {\n const {\n isOpen,\n activeTagIndex,\n setActiveTagIndex,\n displayValue,\n selectionType,\n dropdownTriggerer,\n dropdownBaseId,\n selectedIndices,\n triggererRef,\n triggererWrapperRef,\n isTagDismissedRef,\n onTriggerClick,\n value,\n shouldIgnoreBlurAnimation,\n setShouldIgnoreBlurAnimation,\n activeIndex,\n hasFooterAction,\n hasAutoCompleteInBottomSheetHeader,\n options,\n removeOption,\n setChangeCallbackTriggerer,\n changeCallbackTriggerer,\n } = useDropdown();\n const { rowDensity } = useTableContext();\n const { isInsideTableEditableCell } = useTableEditableCell();\n\n const dropdownTriggerPlaceholder = props.placeholder ?? 'Select Option';\n const isAutoCompleteInHeader = !props.isSelectInput && hasAutoCompleteInBottomSheetHeader;\n\n const getShowAllTags = React.useCallback((): boolean => {\n if (hasAutoCompleteInBottomSheetHeader) {\n // When AutoComplete is in bottomsheet header, we never want to show all tags in outer select input\n if (props.isSelectInput) {\n return false;\n }\n\n // ... And we always want to show all tags in inner AutoComplete\n return true;\n }\n\n return isOpen;\n }, [hasAutoCompleteInBottomSheetHeader, props.isSelectInput, isOpen]);\n\n useControlledDropdownInput({\n onChange: props.onChange,\n name: props.name,\n value: props.value,\n defaultValue: props.defaultValue,\n syncInputValueWithSelection: props.syncInputValueWithSelection,\n isSelectInput: props.isSelectInput,\n });\n\n const getValue = (): string | undefined => {\n let prefix = '';\n if (props.labelPosition === 'inside-input' && props.label) {\n prefix = `${props.label}: `;\n }\n\n if (props.isSelectInput) {\n if (selectionType === 'single') {\n return `${prefix}${displayValue}`;\n }\n\n // In multiselect, we return tags so no display value is required\n return undefined;\n }\n\n // In AutoComplete, input has a special value too\n return props.inputValue;\n };\n\n const getTags = React.useMemo(\n () => ({ size }: { size: NonNullable<BaseInputProps['size']> }) => {\n if (selectionType === 'single') {\n return undefined;\n }\n\n return getTagsGroup({\n size,\n tags: selectedIndices.map((selectedIndex) => options[selectedIndex]?.title),\n activeTagIndex,\n isDisabled: props.isDisabled,\n onDismiss: ({ tagIndex }) => {\n if (isTagDismissedRef.current) {\n isTagDismissedRef.current.value = true;\n }\n\n if (!isReactNative()) {\n triggererRef.current?.focus();\n }\n\n removeOption(selectedIndices[tagIndex]);\n setChangeCallbackTriggerer(Number(changeCallbackTriggerer) + 1);\n },\n });\n },\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [selectedIndices, selectionType, activeTagIndex, changeCallbackTriggerer, options],\n );\n\n const tableInputProps: Partial<BaseInputProps> = {\n isTableInputCell: rowDensityToIsTableInputCellMapping[rowDensity],\n id: 'table-editable-cell-input',\n size: tableEditableCellRowDensityToInputSizeMap[rowDensity],\n trailingIcon: validationStateToInputTrailingIconMap[props.validationState ?? 'none'],\n showHintsAsTooltip: true,\n };\n\n const isValidationStateNone =\n props.validationState === 'none' || props.validationState === undefined;\n\n return (\n <BaseInput\n as={props.isSelectInput ? 'button' : 'input'}\n ref={\n (!isReactNative()\n ? // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (node: any) => {\n triggererRef.current = node;\n if (ref) {\n if (typeof ref === 'function') {\n ref(node);\n } else {\n ref.current = node;\n }\n }\n }\n : null) as never\n }\n isDropdownTrigger={true}\n setInputWrapperRef={(wrapperNode) => {\n triggererWrapperRef.current = wrapperNode;\n }}\n maxTagRows={props.maxRows ?? 'single'}\n tags={getTags({ size: props.size || 'medium' })}\n showAllTags={getShowAllTags()}\n activeTagIndex={activeTagIndex}\n setActiveTagIndex={setActiveTagIndex}\n shouldIgnoreBlurAnimation={shouldIgnoreBlurAnimation}\n setShouldIgnoreBlurAnimation={setShouldIgnoreBlurAnimation}\n textAlign=\"left\"\n // Form Props\n label={props.label as string}\n placeholder={\n selectionType === 'multiple' && selectedIndices.length > 0\n ? undefined\n : dropdownTriggerPlaceholder\n }\n hideLabelText={props.label?.length === 0}\n accessibilityLabel={props.accessibilityLabel}\n labelPosition={props.labelPosition === 'inside-input' ? undefined : props.labelPosition}\n isLabelInsideInput={props.labelPosition === 'inside-input'}\n necessityIndicator={props.necessityIndicator}\n autoCompleteSuggestionType=\"none\"\n validationState={props.validationState}\n helpText={props.helpText}\n errorText={props.errorText}\n successText={props.successText}\n name={props.name}\n isDisabled={props.isDisabled}\n isRequired={props.isRequired}\n prefix={props.prefix}\n suffix={props.suffix}\n autoFocus={props.autoFocus} // eslint-disable-line jsx-a11y/no-autofocus\n value={getValue()}\n onClick={(e) => {\n if (props.isDisabled) {\n return;\n }\n props.onTriggerClick?.(e);\n }}\n onFocus={props.onFocus}\n onBlur={({ name }) => {\n props.onBlur?.({ name, value });\n }}\n leadingIcon={props.icon}\n // Meta Props\n componentName={props.isSelectInput ? MetaConstants.SelectInput : MetaConstants.AutoComplete}\n testID={props.testID}\n // a11y Props\n id={`${dropdownBaseId}-trigger`}\n labelId={`${dropdownBaseId}-label`}\n hasPopup={getActionListContainerRole(hasFooterAction, dropdownTriggerer)}\n isPopupExpanded={isOpen}\n activeDescendant={activeIndex >= 0 ? `${dropdownBaseId}-${activeIndex}` : undefined}\n popupId={`${dropdownBaseId}-actionlist`}\n // Special Props for Unique behaviour between Select and AutoComplete\n onChange={props.isSelectInput ? undefined : props.onInputValueChange}\n onKeyDown={props.onTriggerKeydown}\n size={props.size}\n onTrailingInteractionElementClick={() => {\n if (!props.isDisabled) {\n // Icon onClicks to the SelectInput itself\n if (!isReactNative()) {\n triggererRef.current?.focus();\n }\n onTriggerClick();\n }\n }}\n trailingInteractionElement={\n isAutoCompleteInHeader || (isInsideTableEditableCell && !isValidationStateNone) ? null : (\n <InputChevronIcon isDisabled={props.isDisabled} isOpen={isOpen} />\n )\n }\n {...(isInsideTableEditableCell ? tableInputProps : undefined)}\n />\n );\n};\n\nconst BaseDropdownInputTrigger = React.forwardRef(_BaseDropdownInputTrigger);\n\nexport { BaseDropdownInputTrigger };\n"],"names":["useControlledDropdownInput","props","isFirstRender","useFirstRender","_useDropdown","useDropdown","changeCallbackTriggerer","isControlled","options","selectedIndices","controlledValueIndices","setSelectedIndices","selectionType","setIsControlled","getValuesArrayFromIndices","indices","map","selectionIndex","value","selectValues","valuesToSelect","length","isEmpty","selectedItemIndex","findIndex","option","uniqueValues","Array","from","Set","userValues","selectedItemIndices","optionValue","filter","React","useEffect","defaultValue","undefined","isArray","isSelectInput","syncInputValueWithSelection","onChange","name","values","_BaseDropdownInputTrigger","ref","_props$placeholder","_props$validationStat","_props$maxRows","_props$label","_useDropdown2","isOpen","activeTagIndex","setActiveTagIndex","displayValue","dropdownTriggerer","dropdownBaseId","triggererRef","triggererWrapperRef","isTagDismissedRef","onTriggerClick","shouldIgnoreBlurAnimation","setShouldIgnoreBlurAnimation","activeIndex","hasFooterAction","hasAutoCompleteInBottomSheetHeader","removeOption","setChangeCallbackTriggerer","_useTableContext","useTableContext","rowDensity","_useTableEditableCell","useTableEditableCell","isInsideTableEditableCell","dropdownTriggerPlaceholder","placeholder","isAutoCompleteInHeader","getShowAllTags","useCallback","getValue","prefix","labelPosition","label","inputValue","getTags","useMemo","_ref","size","getTagsGroup","tags","selectedIndex","_options$selectedInde","title","isDisabled","onDismiss","_ref2","tagIndex","current","isReactNative","_triggererRef$current","focus","Number","tableInputProps","isTableInputCell","rowDensityToIsTableInputCellMapping","id","tableEditableCellRowDensityToInputSizeMap","trailingIcon","validationStateToInputTrailingIconMap","validationState","showHintsAsTooltip","isValidationStateNone","_jsx","BaseInput","Object","assign","as","node","isDropdownTrigger","setInputWrapperRef","wrapperNode","maxTagRows","maxRows","showAllTags","textAlign","hideLabelText","accessibilityLabel","isLabelInsideInput","necessityIndicator","autoCompleteSuggestionType","helpText","errorText","successText","isRequired","suffix","autoFocus","onClick","e","onFocus","onBlur","_ref3","leadingIcon","icon","componentName","MetaConstants","SelectInput","AutoComplete","testID","labelId","hasPopup","getActionListContainerRole","isPopupExpanded","activeDescendant","popupId","onInputValueChange","onKeyDown","onTriggerKeydown","onTrailingInteractionElementClick","_triggererRef$current2","trailingInteractionElement","InputChevronIcon","BaseDropdownInputTrigger","forwardRef"],"mappings":";;;;;;;;;;;;;;;;;;;AAqBA,IAAMA,0BAA0B,CAAG,SAA7BA,0BAA0BA,CAC9BC,KASC,CACQ,CACT,IAAMC,aAAa,CAAGC,cAAc,EAAE,CACtC,IA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CAAC,CAAI,CAAEP,EAAAA,cAAe,CAAGO,CAAAA,EAAAA,WAAY,EAAC,CAAG1B,SAAU,CACpFoH,OAAO,CAAG,GAAEjG,cAAe,CAAA,WAAA,CAAa,CAExCf,QAAQ,CAAExC,KAAK,CAACsC,aAAa,CAAGF,SAAS,CAAGpC,KAAK,CAACyJ,kBAAmB,CACrEC,SAAS,CAAE1J,KAAK,CAAC2J,gBAAiB,CAClCrE,IAAI,CAAEtF,KAAK,CAACsF,IAAK,CACjBsE,iCAAiC,CAAE,SAAAA,iCAAAA,EAAM,CACvC,GAAI,CAAC5J,KAAK,CAAC4F,UAAU,CAAE,CAErB,GAAI,CAACK,aAAa,EAAE,CAAE,CAAA,IAAA4D,sBAAA,CACpB,CAAAA,sBAAA,CAAArG,YAAY,CAACwC,OAAO,GAApB6D,IAAAA,CAAAA,KAAAA,CAAAA,CAAAA,sBAAA,CAAsB1D,KAAK,EAAE,CAC/B,CACAxC,cAAc,EAAE,CAClB,CACF,CAAE,CACFmG,0BAA0B,CACxBnF,sBAAsB,EAAKH,yBAAyB,EAAI,CAACsC,qBAAsB,CAAG,IAAI,CACpFC,GAAA,CAACgD,gBAAgB,CAAA,CAACnE,UAAU,CAAE5F,KAAK,CAAC4F,UAAW,CAAC1C,MAAM,CAAEA,MAAO,CAAE,CAEpE,CACIsB,CAAAA,yBAAyB,CAAG6B,eAAe,CAAGjE,SAAS,CAC7D,CAAC,CAEN,CAAC,CAEK,IAAA4H,wBAAwB,CAAG/H,cAAK,CAACgI,UAAU,CAACtH,yBAAyB;;;;"}
|
|
@@ -44,7 +44,7 @@ import { makeSize } from '../../../utils/makeSize/makeSize.js';
|
|
|
44
44
|
import { FormHint } from '../../Form/FormHint.js';
|
|
45
45
|
import { assignWithoutSideEffects } from '../../../utils/assignWithoutSideEffects/assignWithoutSideEffects.js';
|
|
46
46
|
|
|
47
|
-
var _excluded = ["as", "label", "labelPosition", "placeholder", "type", "defaultValue", "tags", "showAllTags", "activeTagIndex", "setActiveTagIndex", "name", "value", "onFocus", "onChange", "onInput", "onBlur", "onSubmit", "onClick", "onKeyDown", "isDisabled", "necessityIndicator", "validationState", "errorText", "helpText", "successText", "isRequired", "leadingIcon", "prefix", "trailingInteractionElement", "leadingInteractionElement", "suffix", "trailingIcon", "maxCharacters", "textAlign", "autoFocus", "keyboardReturnKeyType", "keyboardType", "autoCompleteSuggestionType", "trailingHeaderSlot", "trailingFooterSlot", "numberOfLines", "id", "componentName", "accessibilityLabel", "labelId", "activeDescendant", "hideLabelText", "hideFormHint", "hasPopup", "popupId", "isPopupExpanded", "maxTagRows", "shouldIgnoreBlurAnimation", "setShouldIgnoreBlurAnimation", "autoCapitalize", "setInputWrapperRef", "testID", "isDropdownTrigger", "isLabelInsideInput", "size", "trailingButton", "valueComponentType", "isTableInputCell", "showHintsAsTooltip"];
|
|
47
|
+
var _excluded = ["as", "label", "labelPosition", "placeholder", "type", "defaultValue", "tags", "showAllTags", "activeTagIndex", "setActiveTagIndex", "name", "value", "onFocus", "onChange", "onInput", "onBlur", "onSubmit", "onClick", "onKeyDown", "isDisabled", "necessityIndicator", "validationState", "errorText", "helpText", "successText", "isRequired", "leadingIcon", "prefix", "trailingInteractionElement", "onTrailingInteractionElementClick", "leadingInteractionElement", "suffix", "trailingIcon", "maxCharacters", "textAlign", "autoFocus", "keyboardReturnKeyType", "keyboardType", "autoCompleteSuggestionType", "trailingHeaderSlot", "trailingFooterSlot", "numberOfLines", "id", "componentName", "accessibilityLabel", "labelId", "activeDescendant", "hideLabelText", "hideFormHint", "hasPopup", "popupId", "isPopupExpanded", "maxTagRows", "shouldIgnoreBlurAnimation", "setShouldIgnoreBlurAnimation", "autoCapitalize", "setInputWrapperRef", "testID", "isDropdownTrigger", "isLabelInsideInput", "size", "trailingButton", "valueComponentType", "isTableInputCell", "showHintsAsTooltip"];
|
|
48
48
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
49
49
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
50
50
|
var autoCompleteSuggestionTypeValues = ['none', 'on', 'name', 'email', 'username', 'password', 'newPassword', 'oneTimeCode', 'telephone', 'postalCode', 'countryName', 'creditCardNumber', 'creditCardCSC', 'creditCardExpiry', 'creditCardExpiryMonth', 'creditCardExpiryYear'];
|
|
@@ -334,6 +334,7 @@ var _BaseInput = function _BaseInput(_ref12, ref) {
|
|
|
334
334
|
leadingIcon = _ref12.leadingIcon,
|
|
335
335
|
prefix = _ref12.prefix,
|
|
336
336
|
trailingInteractionElement = _ref12.trailingInteractionElement,
|
|
337
|
+
onTrailingInteractionElementClick = _ref12.onTrailingInteractionElementClick,
|
|
337
338
|
leadingInteractionElement = _ref12.leadingInteractionElement,
|
|
338
339
|
suffix = _ref12.suffix,
|
|
339
340
|
trailingIcon = _ref12.trailingIcon,
|
|
@@ -595,6 +596,7 @@ var _BaseInput = function _BaseInput(_ref12, ref) {
|
|
|
595
596
|
})))
|
|
596
597
|
}), /*#__PURE__*/jsx(BaseInputVisuals, {
|
|
597
598
|
trailingInteractionElement: trailingInteractionElement,
|
|
599
|
+
onTrailingInteractionElementClick: onTrailingInteractionElementClick,
|
|
598
600
|
suffix: suffix,
|
|
599
601
|
trailingIcon: trailingIcon,
|
|
600
602
|
isDisabled: isDisabled,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseInput.js","sources":["../../../../../../../src/components/Input/BaseInput/BaseInput.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\nimport React from 'react';\nimport type { ReactNode } from 'react';\nimport styled from 'styled-components';\nimport { StyledBaseInput } from './StyledBaseInput';\nimport { BaseInputVisuals } from './BaseInputVisuals';\nimport { BaseInputWrapper } from './BaseInputWrapper';\nimport { BaseInputTagSlot } from './BaseInputTagSlot';\nimport type { InputWrapperRef } from './types';\nimport { baseInputBorderBackgroundMotion, formHintLeftLabelMarginLeft } from './baseInputTokens';\nimport type {\n FormInputLabelProps,\n FormInputValidationProps,\n FormInputHandleOnEvent,\n FormInputOnEvent,\n FormHintProps,\n} from '~components/Form';\nimport { FormHint, FormLabel } from '~components/Form';\nimport type { IconComponent } from '~components/Icons';\nimport BaseBox from '~components/Box/BaseBox';\nimport { getStyledProps } from '~components/Box/styledProps';\nimport type { StyledPropsBlade } from '~components/Box/styledProps';\nimport {\n castWebType,\n getPlatformType,\n isReactNative,\n makeBorderSize,\n makeMotionTime,\n useBreakpoint,\n} from '~utils';\nimport type { Platform } from '~utils';\nimport { metaAttribute, MetaConstants } from '~utils/metaAttribute';\nimport { useFormId } from '~components/Form/useFormId';\nimport { useTheme } from '~components/BladeProvider';\nimport useInteraction from '~utils/useInteraction';\nimport type { ActionStates } from '~utils/useInteraction';\nimport type {\n FormInputHandleOnClickEvent,\n FormInputHandleOnKeyDownEvent,\n} from '~components/Form/FormTypes';\nimport type { BladeElementRef, ContainerElementType, TestID } from '~utils/types';\nimport { makeSize } from '~utils/makeSize';\nimport type { AriaAttributes } from '~utils/makeAccessible';\nimport { makeAccessible } from '~utils/makeAccessible';\nimport { throwBladeError } from '~utils/logger';\nimport { announce } from '~components/LiveAnnouncer/LiveAnnouncer';\nimport { assignWithoutSideEffects } from '~utils/assignWithoutSideEffects';\nimport type { LinkProps } from '~components/Link';\nimport { getFocusRingStyles } from '~utils/getFocusRingStyles';\nimport getIn from '~utils/lodashButBetter/get';\nimport { useMergeRefs } from '~utils/useMergeRefs';\n\ntype CommonAutoCompleteSuggestionTypes =\n | 'none'\n | 'name'\n | 'email'\n | 'username'\n | 'password'\n | 'newPassword'\n | 'oneTimeCode'\n | 'telephone'\n | 'postalCode'\n | 'countryName'\n | 'creditCardNumber'\n | 'creditCardCSC'\n | 'creditCardExpiry'\n | 'creditCardExpiryMonth'\n | 'creditCardExpiryYear';\n\ntype WebAutoCompleteSuggestionType = CommonAutoCompleteSuggestionTypes | 'on';\n\ntype BaseInputCommonProps = FormInputLabelProps &\n FormInputValidationProps & {\n /**\n * Determines if it needs to be rendered as input, textarea or button\n */\n as?: 'input' | 'textarea' | 'button';\n /**\n * ID that will be used for accessibility\n */\n id: string;\n /**\n * Placeholder text to be displayed inside the input field\n */\n placeholder?: string;\n /**\n * Type of Input Field to be rendered.\n *\n * @default text\n */\n type?: 'text' | 'telephone' | 'email' | 'url' | 'number' | 'search' | 'password';\n /**\n * Used to set the default value of input field when it's uncontrolled\n */\n defaultValue?: string;\n /**\n * The name of the input field.\n *\n * Useful in form submissions\n */\n name?: string;\n /**\n * The callback function to be invoked when the input field gets focus\n */\n onFocus?: FormInputOnEvent;\n /**\n * The callback function to be invoked when the value of the input field changes\n */\n onChange?: FormInputOnEvent;\n /**\n * The callback function to be invoked when input is clicked\n */\n onClick?: FormInputOnEvent;\n /**\n * The callback function to be invoked when the value of the input field has any input\n */\n onInput?: FormInputOnEvent;\n /**\n * The callback function to be invoked whenever there is a keyDown event\n */\n onKeyDown?: FormInputHandleOnKeyDownEvent;\n /**\n * The callback function to be invoked when the the input field loses focus\n *\n * For React Native this will call `onEndEditing` event since we want to get the last value of the input field\n */\n onBlur?: FormInputOnEvent;\n /**\n * Ignores the blur event animation (Used in Select to ignore blur animation when item in option is clicked)\n */\n shouldIgnoreBlurAnimation?: boolean;\n /**\n * sets boolean that ignores the blur animations on baseinput\n */\n setShouldIgnoreBlurAnimation?: (shouldIgnoreBlurAnimation: boolean) => void;\n /**\n * Used to turn the input field to controlled so user can control the value\n */\n value?: string;\n /**\n * Used to disable the input field\n */\n isDisabled?: boolean;\n /**\n * If true, the input is marked as required, and `required` attribute will be added\n */\n isRequired?: boolean;\n /**\n * Icon to be shown at the start of the input field\n */\n leadingIcon?: IconComponent;\n /**\n * Prefix symbol to be displayed at the beginning of the input field. If leadingIcon is provided it'll be placed after it\n */\n prefix?: string;\n /**\n * Element to be rendered before suffix. This is decided by the component which is extending BaseInput\n *\n * eg: consumers can render a loader or they could render a clear button\n */\n trailingInteractionElement?: ReactNode;\n /**\n * Element to be rendered before prefix. This is decided by the component which is extending BaseInput\n *\n * eg: consumers can render a country selector or button\n */\n leadingInteractionElement?: ReactNode;\n /**\n * Suffix symbol to be displayed at the end of the input field. If trailingIcon is provided it'll be placed before it\n */\n suffix?: string;\n /**\n * Icon to be displayed at the end of the input field\n */\n trailingIcon?: IconComponent;\n /**\n * Displays the character counter under the input field\n */\n maxCharacters?: number;\n /**\n * alignment of the text inside input field\n */\n textAlign?: 'left' | 'center' | 'right';\n /**\n * If true, focuses the input field on load\n *\n * **Note:**\n * Automatically focusing a form control can confuse visually-impaired people using screen-reading technology and people with cognitive impairments.\n * When autofocus is assigned, screen-readers \"teleport\" their user to the form control without warning them beforehand.\n */\n autoFocus?: boolean;\n /**\n * Hints the platform to display an appropriate virtual keyboard\n *\n * **Native:** Passes as is the `keyboardType` attribute\n *\n * **Web:** Passes the value to the `inputMode` attribute\n */\n keyboardType?: 'text' | 'search' | 'telephone' | 'email' | 'url' | 'decimal';\n /**\n * determines what return key to show on the keyboard of mobile devices/virtual keyboard\n * **Note**: Few values are platform dependent and might not render on all the platforms\n *\n * `default` is only available on native. it'll be mapped to `enter` for web\n * `previous` is only available on native android\n */\n keyboardReturnKeyType?: 'default' | 'go' | 'done' | 'next' | 'previous' | 'search' | 'send';\n /**\n * Element to be rendered on the trailing slot of input field label\n */\n trailingHeaderSlot?: (value?: string) => ReactNode;\n /**\n * Element to be rendered on the trailing slot of input field footer\n */\n trailingFooterSlot?: (value?: string) => ReactNode;\n /**\n * Sets the textarea's number of lines\n */\n numberOfLines?: 2 | 3 | 4 | 5;\n /**\n * Sets the accessibility label for the input\n */\n accessibilityLabel?: string;\n /**\n * Sets the id of the label\n *\n * (Useful when assigning one label to multiple elements using aria-labelledby)\n */\n labelId?: string;\n /**\n * Can be used in select to set the id of the active descendant from the listbox\n */\n activeDescendant?: string;\n /**\n * Hides the label text\n */\n hideLabelText?: boolean;\n /**\n * Hides the form hint text\n */\n hideFormHint?: boolean;\n /**\n * componentName prop sets the data-blade-component attribute name\n * for internal metric collection purposes\n */\n componentName?: string;\n /**\n * whether the input has a popup\n */\n hasPopup?: AriaAttributes['hasPopup'];\n /**\n * id of the popup\n */\n popupId?: string;\n /**\n * true if popup is in expanded state\n */\n isPopupExpanded?: boolean;\n setInputWrapperRef?: (node: ContainerElementType) => void;\n /**\n * sets the autocapitalize behavior for the input\n */\n autoCapitalize?: 'none' | 'sentences' | 'words' | 'characters';\n\n /**\n * constraints the height of input to given number rows\n *\n * When set to expandable, input takes 1 row in the begining and expands to take 3 when active\n *\n * @default 'single'\n */\n maxTagRows?: 'single' | 'multiple' | 'expandable';\n\n /**\n * A slot for adding tags to input\n */\n tags?: React.ReactElement[] | null;\n\n /**\n * Disables stripping of tags and shows all tags\n */\n showAllTags?: boolean;\n\n /**\n * State variable of active tag index\n */\n activeTagIndex?: number;\n\n /**\n * Is this input SelectInput or AutoComplete\n */\n isDropdownTrigger?: boolean;\n\n /**\n * Is the label expected to be rendered inside input?\n * Used in AutoComplete and Select when label can't exist outside\n *\n */\n isLabelInsideInput?: boolean;\n\n /**\n * State setter for active tag index\n */\n setActiveTagIndex?: (activeTagIndex: number) => void;\n /**\n * Sets the size of the input field\n * @default medium\n */\n size?: 'medium' | 'large';\n /**\n * Link button to be rendered at the end of the input field.\n * **Note:** `size` of the Link will be set to the same size as the input field, `isDisabled` will follow Input's `isDisabled`, & `variant` will be set to `button`.\n * Example:\n * ```tsx\n * trailingButton={<Link onClick={handleClick}>Apply</Link>}\n * ```\n */\n trailingButton?: React.ReactElement<LinkProps>;\n /**\n * Whether to use Text or Heading component for Input text\n * @default text\n **/\n valueComponentType?: 'text' | 'heading';\n /**\n * Whether to render the input as a table cell\n * @default true\n **/\n isTableInputCell?: boolean;\n\n /**\n * Hides the form hints and shows them as tooltip of trailing\n */\n showHintsAsTooltip?: boolean;\n } & TestID &\n Platform.Select<{\n native: {\n /**\n * The callback function to be invoked when the value of the input field is submitted.\n */\n onSubmit?: FormInputOnEvent;\n /**\n * determines what autoComplete suggestion type to show\n *\n * Internally it'll render platform specific attributes:\n *\n * - web: `autocomplete`\n * - iOS: `textContentType`\n * - android: `autoComplete`\n *\n */\n autoCompleteSuggestionType?: CommonAutoCompleteSuggestionTypes;\n };\n web: {\n /**\n * This is a react-native only prop and has no effect on web.\n */\n onSubmit?: undefined;\n /**\n * determines what autoComplete suggestion type to show\n *\n * Internally it'll render platform specific attributes:\n *\n * - web: `autocomplete`\n * - iOS: `textContentType`\n * - android: `autoComplete`\n *\n */\n autoCompleteSuggestionType?: WebAutoCompleteSuggestionType;\n };\n }> &\n StyledPropsBlade;\n\n/*\n Mandatory accessibilityLabel prop when label is not provided\n*/\ntype BaseInputPropsWithA11yLabel = {\n /**\n * Label to be shown for the input field\n */\n label?: undefined;\n /**\n * Accessibility label for the input\n */\n accessibilityLabel: string;\n};\n\n/*\n Optional accessibilityLabel prop when label is provided\n*/\ntype BaseInputPropsWithLabel = {\n /**\n * Label to be shown for the input field\n */\n label: string;\n /**\n * Accessibility label for the input\n */\n accessibilityLabel?: string;\n};\n\nexport type BaseInputProps = (BaseInputPropsWithA11yLabel | BaseInputPropsWithLabel) &\n BaseInputCommonProps;\n\nconst autoCompleteSuggestionTypeValues = [\n 'none',\n 'on',\n 'name',\n 'email',\n 'username',\n 'password',\n 'newPassword',\n 'oneTimeCode',\n 'telephone',\n 'postalCode',\n 'countryName',\n 'creditCardNumber',\n 'creditCardCSC',\n 'creditCardExpiry',\n 'creditCardExpiryMonth',\n 'creditCardExpiryYear',\n];\n\ntype OnInputKeydownTagHandlerType = (key: string | undefined) => void;\nconst useTags = (\n tags: BaseInputProps['tags'],\n activeTagIndex: number,\n setActiveTagIndex?: (activeTagIndex: number) => void,\n): {\n onInputKeydownTagHandler: OnInputKeydownTagHandlerType;\n visibleTagsCountRef: React.MutableRefObject<number>;\n} => {\n const visibleTagsCountRef = React.useRef<number>(0);\n\n React.useEffect(() => {\n if (tags && activeTagIndex >= 0 && activeTagIndex < tags.length) {\n const tagTitle = tags[activeTagIndex]?.props?.children;\n if (tagTitle) {\n announce(`Close ${tagTitle} Tag`);\n }\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [activeTagIndex, tags?.length]);\n\n const onTagLeft = (): void => {\n if (activeTagIndex < 0) {\n setActiveTagIndex?.(visibleTagsCountRef.current - 1);\n }\n\n if (activeTagIndex > 0) {\n setActiveTagIndex?.(activeTagIndex - 1);\n }\n };\n\n const onTagRight = (): void => {\n if (activeTagIndex < visibleTagsCountRef.current - 1) {\n setActiveTagIndex?.(activeTagIndex + 1);\n }\n };\n\n const onTagRemove = (): void => {\n if (activeTagIndex >= 0 && activeTagIndex < visibleTagsCountRef.current && tags) {\n tags[activeTagIndex].props.onDismiss({ tagIndex: activeTagIndex });\n }\n };\n\n const onInputKeydownTagHandler: OnInputKeydownTagHandlerType = (key) => {\n if (tags && tags.length > 0) {\n if (key === 'ArrowRight') {\n onTagRight();\n }\n\n if (key === 'ArrowLeft') {\n onTagLeft();\n }\n\n if (key === 'Backspace') {\n onTagRemove();\n }\n }\n };\n\n return {\n onInputKeydownTagHandler,\n visibleTagsCountRef,\n };\n};\n\nconst useInput = ({\n value,\n defaultValue,\n onClick,\n onFocus,\n onChange,\n onBlur,\n onSubmit,\n onInput,\n onKeyDown,\n onInputKeydownTagHandler,\n}: Pick<\n BaseInputProps,\n | 'value'\n | 'defaultValue'\n | 'onFocus'\n | 'onChange'\n | 'onBlur'\n | 'onInput'\n | 'onKeyDown'\n | 'onClick'\n | 'onSubmit'\n> & {\n onInputKeydownTagHandler: OnInputKeydownTagHandlerType;\n}): {\n handleOnFocus: FormInputHandleOnEvent;\n handleOnClick: FormInputHandleOnClickEvent;\n handleOnChange: FormInputHandleOnEvent;\n handleOnBlur: FormInputHandleOnEvent;\n handleOnSubmit: FormInputHandleOnEvent;\n handleOnInput: FormInputHandleOnEvent;\n handleOnKeyDown: FormInputHandleOnKeyDownEvent;\n inputValue?: string;\n} => {\n if (__DEV__) {\n if (value && defaultValue) {\n throwBladeError({\n message: `Either 'value' or 'defaultValue' shall be passed. This decides if the input field is controlled or uncontrolled`,\n moduleName: 'Input',\n });\n }\n }\n\n const [inputValue, setInputValue] = React.useState(defaultValue ?? value);\n\n const handleOnFocus: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n\n if (getPlatformType() === 'react-native' && typeof value === 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n\n onFocus?.({\n name,\n value: _value,\n });\n },\n [onFocus],\n );\n\n const handleOnClick: FormInputHandleOnClickEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n\n if (getPlatformType() === 'react-native' && typeof value === 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.currentTarget.value ?? '';\n }\n\n onClick?.({\n name,\n value: _value,\n });\n },\n [onClick],\n );\n\n const handleOnSubmit: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n\n if (getPlatformType() === 'react-native' && typeof value === 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n if (isReactNative()) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment, @typescript-eslint/prefer-ts-expect-error\n //@ts-ignore need to ignore this since it will throw a TS error for web but not for native\n onSubmit?.({\n name,\n value: _value,\n });\n }\n },\n [onSubmit],\n );\n\n const handleOnBlur: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n if (getPlatformType() === 'react-native' && typeof value == 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n\n onBlur?.({\n name,\n value: _value,\n });\n },\n [onBlur],\n );\n\n const handleOnChange: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n\n if (getPlatformType() === 'react-native' && typeof value === 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n\n onChange?.({\n name,\n value: _value,\n });\n setInputValue(_value);\n },\n [onChange],\n );\n\n const handleOnInput: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n if (getPlatformType() === 'react-native' && typeof value == 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n\n onInput?.({\n name,\n value: _value,\n });\n },\n [onInput],\n );\n\n const handleOnKeyDown: FormInputHandleOnKeyDownEvent = React.useCallback(\n ({ name, key, code, event }) => {\n onInputKeydownTagHandler(key);\n onKeyDown?.({\n name,\n key,\n code,\n event,\n });\n },\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [onKeyDown],\n );\n\n return {\n handleOnFocus,\n handleOnClick,\n handleOnChange,\n handleOnBlur,\n handleOnSubmit,\n handleOnInput,\n handleOnKeyDown,\n inputValue,\n };\n};\n\nexport const getHintType = ({\n validationState,\n hasHelpText,\n}: {\n validationState: BaseInputProps['validationState'];\n hasHelpText: boolean;\n}): FormHintProps['type'] => {\n if (validationState === 'error') {\n return 'error';\n }\n\n if (validationState === 'success') {\n return 'success';\n }\n\n if (hasHelpText) {\n return 'help';\n }\n\n return 'help';\n};\n\nconst getDescribedByElementId = ({\n validationState,\n hasErrorText,\n hasSuccessText,\n hasHelpText,\n errorTextId,\n successTextId,\n helpTextId,\n}: {\n validationState: BaseInputProps['validationState'];\n hasErrorText: boolean;\n hasSuccessText: boolean;\n hasHelpText: boolean;\n errorTextId: string;\n successTextId: string;\n helpTextId: string;\n}): string => {\n if (validationState === 'error' && hasErrorText) {\n return errorTextId;\n }\n\n if (validationState === 'success' && hasSuccessText) {\n return successTextId;\n }\n\n if (hasHelpText) {\n return helpTextId;\n }\n\n return '';\n};\n\nconst FocusRingWrapper = styled(BaseBox)<{\n currentInteraction: ActionStates;\n isTableInputCell: NonNullable<BaseInputProps['isTableInputCell']>;\n}>(({ theme, currentInteraction, isTableInputCell }) => ({\n borderRadius: makeBorderSize(\n isTableInputCell ? theme.border.radius.none : theme.border.radius.medium,\n ),\n width: '100%',\n '&:focus-within': !isTableInputCell\n ? {\n ...getFocusRingStyles({\n theme,\n }),\n transitionDuration: castWebType(\n makeMotionTime(\n getIn(\n theme.motion.duration,\n baseInputBorderBackgroundMotion[currentInteraction === 'focus' ? 'enter' : 'exit']\n .duration,\n ),\n ),\n ),\n transitionTimingFunction: castWebType(\n getIn(\n theme.motion.easing,\n baseInputBorderBackgroundMotion[currentInteraction === 'focus' ? 'enter' : 'exit']\n .easing,\n ),\n ),\n }\n : {},\n}));\n\nconst _BaseInput: React.ForwardRefRenderFunction<BladeElementRef, BaseInputProps> = (\n {\n as = 'input',\n label,\n labelPosition = 'top',\n placeholder,\n type = 'text',\n defaultValue,\n tags,\n showAllTags = false,\n activeTagIndex = -1,\n setActiveTagIndex,\n name,\n value,\n onFocus,\n onChange,\n onInput,\n onBlur,\n onSubmit,\n onClick,\n onKeyDown,\n isDisabled,\n necessityIndicator,\n validationState,\n errorText,\n helpText,\n successText,\n isRequired,\n leadingIcon,\n prefix,\n trailingInteractionElement,\n leadingInteractionElement,\n suffix,\n trailingIcon,\n maxCharacters,\n textAlign,\n autoFocus,\n keyboardReturnKeyType,\n keyboardType,\n autoCompleteSuggestionType,\n trailingHeaderSlot,\n trailingFooterSlot,\n numberOfLines,\n id,\n componentName,\n accessibilityLabel,\n labelId,\n activeDescendant,\n hideLabelText,\n hideFormHint,\n hasPopup,\n popupId,\n isPopupExpanded,\n maxTagRows,\n shouldIgnoreBlurAnimation,\n setShouldIgnoreBlurAnimation,\n autoCapitalize,\n setInputWrapperRef,\n testID,\n isDropdownTrigger,\n isLabelInsideInput,\n size = 'medium',\n trailingButton,\n valueComponentType = 'text',\n isTableInputCell = false,\n showHintsAsTooltip = false,\n ...styledProps\n },\n ref,\n) => {\n const { theme } = useTheme();\n const inputRef = React.useRef<BladeElementRef>(null);\n const mergedInputRef = useMergeRefs(ref, inputRef);\n const inputWrapperRef: InputWrapperRef = React.useRef(null);\n const { onInputKeydownTagHandler, visibleTagsCountRef } = useTags(\n tags,\n activeTagIndex,\n setActiveTagIndex,\n );\n const [showAllTagsWithAnimation, setShowAllTagsWithAnimation] = React.useState(false);\n const isReactNative = getPlatformType() === 'react-native';\n\n React.useEffect(() => {\n if (showAllTags) {\n setShowAllTagsWithAnimation(true);\n } else if (maxTagRows !== 'expandable') {\n setShowAllTagsWithAnimation(false);\n }\n }, [showAllTags, maxTagRows]);\n\n const {\n handleOnFocus,\n handleOnChange,\n handleOnClick,\n handleOnBlur,\n handleOnSubmit,\n handleOnInput,\n handleOnKeyDown,\n inputValue,\n } = useInput({\n defaultValue,\n value,\n onFocus,\n onClick,\n onChange,\n onBlur,\n onSubmit,\n onInput,\n onKeyDown,\n onInputKeydownTagHandler,\n });\n const { inputId, helpTextId, errorTextId, successTextId } = useFormId(id);\n const { matchedDeviceType } = useBreakpoint({ breakpoints: theme.breakpoints });\n const isLabelLeftPositioned = labelPosition === 'left' && matchedDeviceType === 'desktop';\n const { currentInteraction, setCurrentInteraction } = useInteraction();\n const _isRequired = isRequired || necessityIndicator === 'required';\n\n const accessibilityProps = makeAccessible({\n required: Boolean(_isRequired),\n disabled: Boolean(isDisabled),\n invalid: Boolean(validationState === 'error'),\n describedBy: getDescribedByElementId({\n validationState,\n hasErrorText: Boolean(errorText),\n hasSuccessText: Boolean(successText),\n hasHelpText: Boolean(helpText),\n errorTextId,\n successTextId,\n helpTextId,\n }),\n label: accessibilityLabel,\n hasPopup,\n expanded: hasPopup ? isPopupExpanded : undefined,\n controls: hasPopup ? popupId : undefined,\n role: hasPopup ? 'combobox' : undefined,\n activeDescendant,\n });\n\n const willRenderHintText = Boolean(helpText) || Boolean(successText) || Boolean(errorText);\n\n if (__DEV__) {\n if (\n autoCompleteSuggestionType &&\n !autoCompleteSuggestionTypeValues.includes(autoCompleteSuggestionType)\n ) {\n throwBladeError({\n message: `Expected autoCompleteSuggestionType to be one of ${autoCompleteSuggestionTypeValues.join(\n ', ',\n )} but received ${autoCompleteSuggestionType}`,\n moduleName: 'Input',\n });\n }\n }\n\n const isTextArea = as === 'textarea';\n return (\n <BaseBox {...metaAttribute({ name: componentName, testID })} {...getStyledProps(styledProps)}>\n <BaseBox\n display=\"flex\"\n flexDirection={isLabelLeftPositioned ? 'row' : 'column'}\n justifyContent={isLabelLeftPositioned ? 'center' : undefined}\n alignItems={isLabelLeftPositioned ? 'center' : undefined}\n position=\"relative\"\n width=\"100%\"\n >\n {!hideLabelText && !isLabelInsideInput && label && (\n <BaseBox\n display=\"flex\"\n flexDirection={isLabelLeftPositioned ? 'column' : 'row'}\n justifyContent=\"space-between\"\n alignSelf={isTextArea ? 'flex-start' : undefined}\n marginY={isTextArea && isLabelLeftPositioned ? 'spacing.3' : 'spacing.0'}\n >\n <FormLabel\n as=\"label\"\n necessityIndicator={necessityIndicator}\n position={labelPosition}\n id={labelId}\n htmlFor={inputId}\n size={size}\n >\n {label}\n </FormLabel>\n {trailingHeaderSlot?.(value ?? inputValue)}\n </BaseBox>\n )}\n <FocusRingWrapper\n currentInteraction={currentInteraction}\n isTableInputCell={isTableInputCell}\n >\n <BaseInputWrapper\n isDropdownTrigger={isDropdownTrigger}\n isTextArea={isTextArea}\n isDisabled={isDisabled}\n validationState={validationState}\n currentInteraction={currentInteraction}\n isLabelLeftPositioned={isLabelLeftPositioned}\n showAllTags={showAllTags}\n setShowAllTagsWithAnimation={setShowAllTagsWithAnimation}\n ref={(refNode) => {\n if (refNode) {\n setInputWrapperRef?.(refNode);\n inputWrapperRef.current = refNode;\n }\n }}\n maxTagRows={maxTagRows}\n size={size}\n numberOfLines={numberOfLines}\n onClick={() => {\n if (!isReactNative) {\n inputRef.current?.focus();\n }\n }}\n isTableInputCell={isTableInputCell}\n >\n <BaseInputVisuals\n size={size}\n leadingIcon={leadingIcon}\n prefix={prefix}\n isDisabled={isDisabled}\n leadingInteractionElement={leadingInteractionElement}\n />\n <BaseInputTagSlot\n renderAs={as}\n tags={tags}\n isDisabled={isDisabled}\n showAllTags={showAllTagsWithAnimation}\n setFocusOnInput={() => {\n if (ref && !isReactNative && 'current' in ref) {\n ref.current?.focus();\n }\n }}\n labelPrefix={isLabelInsideInput ? label : undefined}\n isDropdownTrigger={isDropdownTrigger}\n visibleTagsCountRef={visibleTagsCountRef}\n handleOnInputClick={(e) => {\n handleOnClick({ name, value: isReactNative ? value : e });\n }}\n setShouldIgnoreBlurAnimation={setShouldIgnoreBlurAnimation}\n maxTagRows={maxTagRows}\n inputWrapperRef={inputWrapperRef}\n size={size}\n numberOfLines={numberOfLines}\n isTextArea={isTextArea}\n >\n <StyledBaseInput\n as={as}\n id={inputId}\n ref={mergedInputRef as any}\n name={name}\n type={type}\n defaultValue={defaultValue}\n value={value}\n placeholder={placeholder}\n isDisabled={isDisabled}\n validationState={validationState}\n isRequired={_isRequired}\n handleOnFocus={handleOnFocus}\n handleOnChange={handleOnChange}\n handleOnBlur={handleOnBlur}\n handleOnSubmit={handleOnSubmit}\n handleOnInput={handleOnInput}\n handleOnKeyDown={handleOnKeyDown}\n handleOnClick={handleOnClick}\n leadingIcon={leadingIcon}\n prefix={prefix}\n trailingInteractionElement={trailingInteractionElement}\n leadingInteractionElement={leadingInteractionElement}\n suffix={suffix}\n trailingIcon={trailingIcon}\n maxCharacters={maxCharacters}\n textAlign={textAlign}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autoFocus}\n keyboardReturnKeyType={keyboardReturnKeyType}\n keyboardType={keyboardType}\n autoCompleteSuggestionType={autoCompleteSuggestionType}\n accessibilityProps={accessibilityProps}\n currentInteraction={currentInteraction}\n setCurrentInteraction={setCurrentInteraction}\n numberOfLines={numberOfLines}\n isTextArea={isTextArea || maxTagRows === 'multiple' || maxTagRows === 'expandable'}\n hasPopup={hasPopup}\n hasTags={!!(tags && tags.length > 0)}\n shouldIgnoreBlurAnimation={shouldIgnoreBlurAnimation}\n autoCapitalize={autoCapitalize}\n isDropdownTrigger={isDropdownTrigger}\n $size={size}\n valueComponentType={valueComponentType}\n isTableInputCell={isTableInputCell}\n {...metaAttribute({ name: MetaConstants.StyledBaseInput })}\n />\n </BaseInputTagSlot>\n <BaseInputVisuals\n trailingInteractionElement={trailingInteractionElement}\n suffix={suffix}\n trailingIcon={trailingIcon}\n isDisabled={isDisabled}\n validationState={validationState}\n trailingButton={trailingButton}\n size={size}\n errorText={errorText}\n successText={successText}\n showHintsAsTooltip={showHintsAsTooltip}\n />\n </BaseInputWrapper>\n </FocusRingWrapper>\n </BaseBox>\n\n {hideFormHint || showHintsAsTooltip ? null : (\n <BaseBox\n marginLeft={makeSize(\n isLabelLeftPositioned && !hideLabelText ? formHintLeftLabelMarginLeft[size] : 0,\n )}\n >\n <BaseBox\n display=\"flex\"\n flexDirection=\"row\"\n justifyContent={willRenderHintText ? 'space-between' : 'flex-end'}\n >\n <FormHint\n type={getHintType({ validationState, hasHelpText: Boolean(helpText) })}\n helpText={helpText}\n errorText={errorText}\n successText={successText}\n helpTextId={helpTextId}\n errorTextId={errorTextId}\n successTextId={successTextId}\n size={size}\n />\n {trailingFooterSlot?.(value ?? inputValue)}\n </BaseBox>\n </BaseBox>\n )}\n </BaseBox>\n );\n};\n\nconst BaseInputWithRef = React.forwardRef(_BaseInput);\nconst BaseInput = assignWithoutSideEffects(BaseInputWithRef, { displayName: 'BaseInput' });\n\nexport { BaseInput };\n"],"names":["autoCompleteSuggestionTypeValues","useTags","tags","activeTagIndex","setActiveTagIndex","visibleTagsCountRef","React","useRef","useEffect","length","_tags$activeTagIndex","_tags$activeTagIndex$","tagTitle","props","children","announce","concat","onTagLeft","current","onTagRight","onTagRemove","onDismiss","tagIndex","onInputKeydownTagHandler","key","useInput","_ref","value","defaultValue","onClick","onFocus","onChange","onBlur","onSubmit","onInput","onKeyDown","throwBladeError","message","moduleName","_React$useState","useState","_React$useState2","_slicedToArray","inputValue","setInputValue","handleOnFocus","useCallback","_ref2","name","_value","getPlatformType","_value$target$value","target","handleOnClick","_ref3","_value$currentTarget$","currentTarget","handleOnSubmit","_ref4","_value$target$value2","isReactNative","handleOnBlur","_ref5","_value$target$value3","handleOnChange","_ref6","_value$target$value4","handleOnInput","_ref7","_value$target$value5","handleOnKeyDown","_ref8","code","event","getHintType","_ref9","validationState","hasHelpText","getDescribedByElementId","_ref10","hasErrorText","hasSuccessText","errorTextId","successTextId","helpTextId","FocusRingWrapper","styled","BaseBox","withConfig","displayName","componentId","_ref11","theme","currentInteraction","isTableInputCell","borderRadius","makeBorderSize","border","radius","none","medium","width","_objectSpread","getFocusRingStyles","transitionDuration","castWebType","makeMotionTime","getIn","motion","duration","baseInputBorderBackgroundMotion","transitionTimingFunction","easing","_BaseInput","_ref12","ref","_ref12$as","as","label","_ref12$labelPosition","labelPosition","placeholder","_ref12$type","type","_ref12$showAllTags","showAllTags","_ref12$activeTagIndex","isDisabled","necessityIndicator","errorText","helpText","successText","isRequired","leadingIcon","prefix","trailingInteractionElement","leadingInteractionElement","suffix","trailingIcon","maxCharacters","textAlign","autoFocus","keyboardReturnKeyType","keyboardType","autoCompleteSuggestionType","trailingHeaderSlot","trailingFooterSlot","numberOfLines","id","componentName","accessibilityLabel","labelId","activeDescendant","hideLabelText","hideFormHint","hasPopup","popupId","isPopupExpanded","maxTagRows","shouldIgnoreBlurAnimation","setShouldIgnoreBlurAnimation","autoCapitalize","setInputWrapperRef","testID","isDropdownTrigger","isLabelInsideInput","_ref12$size","size","trailingButton","_ref12$valueComponent","valueComponentType","_ref12$isTableInputCe","_ref12$showHintsAsToo","showHintsAsTooltip","styledProps","_objectWithoutProperties","_excluded","_useTheme","useTheme","inputRef","mergedInputRef","useMergeRefs","inputWrapperRef","_useTags","_React$useState3","_React$useState4","showAllTagsWithAnimation","setShowAllTagsWithAnimation","_useInput","_useFormId","useFormId","inputId","_useBreakpoint","useBreakpoint","breakpoints","matchedDeviceType","isLabelLeftPositioned","_useInteraction","useInteraction","setCurrentInteraction","_isRequired","accessibilityProps","makeAccessible","required","Boolean","disabled","invalid","describedBy","expanded","undefined","controls","role","willRenderHintText","includes","join","isTextArea","_jsxs","metaAttribute","getStyledProps","display","flexDirection","justifyContent","alignItems","position","alignSelf","marginY","_jsx","FormLabel","htmlFor","BaseInputWrapper","refNode","_inputRef$current","focus","BaseInputVisuals","BaseInputTagSlot","renderAs","setFocusOnInput","_ref$current","labelPrefix","handleOnInputClick","e","StyledBaseInput","hasTags","$size","MetaConstants","marginLeft","makeSize","formHintLeftLabelMarginLeft","FormHint","BaseInputWithRef","forwardRef","BaseInput","assignWithoutSideEffects"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmZA,IAAMA,gCAAgC,GAAG,CACvC,MAAM,EACN,IAAI,EACJ,MAAM,EACN,OAAO,EACP,UAAU,EACV,UAAU,EACV,aAAa,EACb,aAAa,EACb,WAAW,EACX,YAAY,EACZ,aAAa,EACb,kBAAkB,EAClB,eAAe,EACf,kBAAkB,EAClB,uBAAuB,EACvB,sBAAsB,CACvB,CAAA;AAGD,IAAMC,OAAO,GAAG,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KAAK,aAALA,KAAK,KAAA,KAAA,CAAA,GAALA,KAAK,GAAIgB,UAAU,CAAC,CAAA;OACnC,CAAA;AAAC,KACH,CACV,CAAA;AAAA,GAAA,CACM,CAAC,CAAA;AAEd,CAAC,CAAA;AAED,IAAM8M,gBAAgB,gBAAGnP,cAAK,CAACoP,UAAU,CAACzI,UAAU,CAAC,CAAA;AACrD,IAAM0I,SAAS,gBAAGC,wBAAwB,CAACH,gBAAgB,EAAE;AAAEhK,EAAAA,WAAW,EAAE,WAAA;AAAY,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"BaseInput.js","sources":["../../../../../../../src/components/Input/BaseInput/BaseInput.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\nimport React from 'react';\nimport type { ReactNode } from 'react';\nimport styled from 'styled-components';\nimport { StyledBaseInput } from './StyledBaseInput';\nimport { BaseInputVisuals } from './BaseInputVisuals';\nimport { BaseInputWrapper } from './BaseInputWrapper';\nimport { BaseInputTagSlot } from './BaseInputTagSlot';\nimport type { InputWrapperRef } from './types';\nimport { baseInputBorderBackgroundMotion, formHintLeftLabelMarginLeft } from './baseInputTokens';\nimport type {\n FormInputLabelProps,\n FormInputValidationProps,\n FormInputHandleOnEvent,\n FormInputOnEvent,\n FormHintProps,\n} from '~components/Form';\nimport { FormHint, FormLabel } from '~components/Form';\nimport type { IconComponent } from '~components/Icons';\nimport BaseBox from '~components/Box/BaseBox';\nimport { getStyledProps } from '~components/Box/styledProps';\nimport type { StyledPropsBlade } from '~components/Box/styledProps';\nimport {\n castWebType,\n getPlatformType,\n isReactNative,\n makeBorderSize,\n makeMotionTime,\n useBreakpoint,\n} from '~utils';\nimport type { Platform } from '~utils';\nimport { metaAttribute, MetaConstants } from '~utils/metaAttribute';\nimport { useFormId } from '~components/Form/useFormId';\nimport { useTheme } from '~components/BladeProvider';\nimport useInteraction from '~utils/useInteraction';\nimport type { ActionStates } from '~utils/useInteraction';\nimport type {\n FormInputHandleOnClickEvent,\n FormInputHandleOnKeyDownEvent,\n} from '~components/Form/FormTypes';\nimport type { BladeElementRef, ContainerElementType, TestID } from '~utils/types';\nimport { makeSize } from '~utils/makeSize';\nimport type { AriaAttributes } from '~utils/makeAccessible';\nimport { makeAccessible } from '~utils/makeAccessible';\nimport { throwBladeError } from '~utils/logger';\nimport { announce } from '~components/LiveAnnouncer/LiveAnnouncer';\nimport { assignWithoutSideEffects } from '~utils/assignWithoutSideEffects';\nimport type { LinkProps } from '~components/Link';\nimport { getFocusRingStyles } from '~utils/getFocusRingStyles';\nimport getIn from '~utils/lodashButBetter/get';\nimport { useMergeRefs } from '~utils/useMergeRefs';\n\ntype CommonAutoCompleteSuggestionTypes =\n | 'none'\n | 'name'\n | 'email'\n | 'username'\n | 'password'\n | 'newPassword'\n | 'oneTimeCode'\n | 'telephone'\n | 'postalCode'\n | 'countryName'\n | 'creditCardNumber'\n | 'creditCardCSC'\n | 'creditCardExpiry'\n | 'creditCardExpiryMonth'\n | 'creditCardExpiryYear';\n\ntype WebAutoCompleteSuggestionType = CommonAutoCompleteSuggestionTypes | 'on';\n\ntype BaseInputCommonProps = FormInputLabelProps &\n FormInputValidationProps & {\n /**\n * Determines if it needs to be rendered as input, textarea or button\n */\n as?: 'input' | 'textarea' | 'button';\n /**\n * ID that will be used for accessibility\n */\n id: string;\n /**\n * Placeholder text to be displayed inside the input field\n */\n placeholder?: string;\n /**\n * Type of Input Field to be rendered.\n *\n * @default text\n */\n type?: 'text' | 'telephone' | 'email' | 'url' | 'number' | 'search' | 'password';\n /**\n * Used to set the default value of input field when it's uncontrolled\n */\n defaultValue?: string;\n /**\n * The name of the input field.\n *\n * Useful in form submissions\n */\n name?: string;\n /**\n * The callback function to be invoked when the input field gets focus\n */\n onFocus?: FormInputOnEvent;\n /**\n * The callback function to be invoked when the value of the input field changes\n */\n onChange?: FormInputOnEvent;\n /**\n * The callback function to be invoked when input is clicked\n */\n onClick?: FormInputOnEvent;\n /**\n * The callback function to be invoked when the value of the input field has any input\n */\n onInput?: FormInputOnEvent;\n /**\n * The callback function to be invoked whenever there is a keyDown event\n */\n onKeyDown?: FormInputHandleOnKeyDownEvent;\n /**\n * The callback function to be invoked when the the input field loses focus\n *\n * For React Native this will call `onEndEditing` event since we want to get the last value of the input field\n */\n onBlur?: FormInputOnEvent;\n /**\n * Ignores the blur event animation (Used in Select to ignore blur animation when item in option is clicked)\n */\n shouldIgnoreBlurAnimation?: boolean;\n /**\n * sets boolean that ignores the blur animations on baseinput\n */\n setShouldIgnoreBlurAnimation?: (shouldIgnoreBlurAnimation: boolean) => void;\n /**\n * Used to turn the input field to controlled so user can control the value\n */\n value?: string;\n /**\n * Used to disable the input field\n */\n isDisabled?: boolean;\n /**\n * If true, the input is marked as required, and `required` attribute will be added\n */\n isRequired?: boolean;\n /**\n * Icon to be shown at the start of the input field\n */\n leadingIcon?: IconComponent;\n /**\n * Prefix symbol to be displayed at the beginning of the input field. If leadingIcon is provided it'll be placed after it\n */\n prefix?: string;\n /**\n * Element to be rendered before suffix. This is decided by the component which is extending BaseInput\n *\n * eg: consumers can render a loader or they could render a clear button\n */\n trailingInteractionElement?: ReactNode;\n /**\n * Callback to be invoked when the TrailingInteractionElement is clicked\n */\n onTrailingInteractionElementClick?: () => void;\n /**\n * Element to be rendered before prefix. This is decided by the component which is extending BaseInput\n *\n * eg: consumers can render a country selector or button\n */\n leadingInteractionElement?: ReactNode;\n /**\n * Suffix symbol to be displayed at the end of the input field. If trailingIcon is provided it'll be placed before it\n */\n suffix?: string;\n /**\n * Icon to be displayed at the end of the input field\n */\n trailingIcon?: IconComponent;\n /**\n * Displays the character counter under the input field\n */\n maxCharacters?: number;\n /**\n * alignment of the text inside input field\n */\n textAlign?: 'left' | 'center' | 'right';\n /**\n * If true, focuses the input field on load\n *\n * **Note:**\n * Automatically focusing a form control can confuse visually-impaired people using screen-reading technology and people with cognitive impairments.\n * When autofocus is assigned, screen-readers \"teleport\" their user to the form control without warning them beforehand.\n */\n autoFocus?: boolean;\n /**\n * Hints the platform to display an appropriate virtual keyboard\n *\n * **Native:** Passes as is the `keyboardType` attribute\n *\n * **Web:** Passes the value to the `inputMode` attribute\n */\n keyboardType?: 'text' | 'search' | 'telephone' | 'email' | 'url' | 'decimal';\n /**\n * determines what return key to show on the keyboard of mobile devices/virtual keyboard\n * **Note**: Few values are platform dependent and might not render on all the platforms\n *\n * `default` is only available on native. it'll be mapped to `enter` for web\n * `previous` is only available on native android\n */\n keyboardReturnKeyType?: 'default' | 'go' | 'done' | 'next' | 'previous' | 'search' | 'send';\n /**\n * Element to be rendered on the trailing slot of input field label\n */\n trailingHeaderSlot?: (value?: string) => ReactNode;\n /**\n * Element to be rendered on the trailing slot of input field footer\n */\n trailingFooterSlot?: (value?: string) => ReactNode;\n /**\n * Sets the textarea's number of lines\n */\n numberOfLines?: 2 | 3 | 4 | 5;\n /**\n * Sets the accessibility label for the input\n */\n accessibilityLabel?: string;\n /**\n * Sets the id of the label\n *\n * (Useful when assigning one label to multiple elements using aria-labelledby)\n */\n labelId?: string;\n /**\n * Can be used in select to set the id of the active descendant from the listbox\n */\n activeDescendant?: string;\n /**\n * Hides the label text\n */\n hideLabelText?: boolean;\n /**\n * Hides the form hint text\n */\n hideFormHint?: boolean;\n /**\n * componentName prop sets the data-blade-component attribute name\n * for internal metric collection purposes\n */\n componentName?: string;\n /**\n * whether the input has a popup\n */\n hasPopup?: AriaAttributes['hasPopup'];\n /**\n * id of the popup\n */\n popupId?: string;\n /**\n * true if popup is in expanded state\n */\n isPopupExpanded?: boolean;\n setInputWrapperRef?: (node: ContainerElementType) => void;\n /**\n * sets the autocapitalize behavior for the input\n */\n autoCapitalize?: 'none' | 'sentences' | 'words' | 'characters';\n\n /**\n * constraints the height of input to given number rows\n *\n * When set to expandable, input takes 1 row in the begining and expands to take 3 when active\n *\n * @default 'single'\n */\n maxTagRows?: 'single' | 'multiple' | 'expandable';\n\n /**\n * A slot for adding tags to input\n */\n tags?: React.ReactElement[] | null;\n\n /**\n * Disables stripping of tags and shows all tags\n */\n showAllTags?: boolean;\n\n /**\n * State variable of active tag index\n */\n activeTagIndex?: number;\n\n /**\n * Is this input SelectInput or AutoComplete\n */\n isDropdownTrigger?: boolean;\n\n /**\n * Is the label expected to be rendered inside input?\n * Used in AutoComplete and Select when label can't exist outside\n *\n */\n isLabelInsideInput?: boolean;\n\n /**\n * State setter for active tag index\n */\n setActiveTagIndex?: (activeTagIndex: number) => void;\n /**\n * Sets the size of the input field\n * @default medium\n */\n size?: 'medium' | 'large';\n /**\n * Link button to be rendered at the end of the input field.\n * **Note:** `size` of the Link will be set to the same size as the input field, `isDisabled` will follow Input's `isDisabled`, & `variant` will be set to `button`.\n * Example:\n * ```tsx\n * trailingButton={<Link onClick={handleClick}>Apply</Link>}\n * ```\n */\n trailingButton?: React.ReactElement<LinkProps>;\n /**\n * Whether to use Text or Heading component for Input text\n * @default text\n **/\n valueComponentType?: 'text' | 'heading';\n /**\n * Whether to render the input as a table cell\n * @default true\n **/\n isTableInputCell?: boolean;\n /**\n * Hides the form hints and shows them as tooltip of trailing\n */\n showHintsAsTooltip?: boolean;\n } & TestID &\n Platform.Select<{\n native: {\n /**\n * The callback function to be invoked when the value of the input field is submitted.\n */\n onSubmit?: FormInputOnEvent;\n /**\n * determines what autoComplete suggestion type to show\n *\n * Internally it'll render platform specific attributes:\n *\n * - web: `autocomplete`\n * - iOS: `textContentType`\n * - android: `autoComplete`\n *\n */\n autoCompleteSuggestionType?: CommonAutoCompleteSuggestionTypes;\n };\n web: {\n /**\n * This is a react-native only prop and has no effect on web.\n */\n onSubmit?: undefined;\n /**\n * determines what autoComplete suggestion type to show\n *\n * Internally it'll render platform specific attributes:\n *\n * - web: `autocomplete`\n * - iOS: `textContentType`\n * - android: `autoComplete`\n *\n */\n autoCompleteSuggestionType?: WebAutoCompleteSuggestionType;\n };\n }> &\n StyledPropsBlade;\n\n/*\n Mandatory accessibilityLabel prop when label is not provided\n*/\ntype BaseInputPropsWithA11yLabel = {\n /**\n * Label to be shown for the input field\n */\n label?: undefined;\n /**\n * Accessibility label for the input\n */\n accessibilityLabel: string;\n};\n\n/*\n Optional accessibilityLabel prop when label is provided\n*/\ntype BaseInputPropsWithLabel = {\n /**\n * Label to be shown for the input field\n */\n label: string;\n /**\n * Accessibility label for the input\n */\n accessibilityLabel?: string;\n};\n\nexport type BaseInputProps = (BaseInputPropsWithA11yLabel | BaseInputPropsWithLabel) &\n BaseInputCommonProps;\n\nconst autoCompleteSuggestionTypeValues = [\n 'none',\n 'on',\n 'name',\n 'email',\n 'username',\n 'password',\n 'newPassword',\n 'oneTimeCode',\n 'telephone',\n 'postalCode',\n 'countryName',\n 'creditCardNumber',\n 'creditCardCSC',\n 'creditCardExpiry',\n 'creditCardExpiryMonth',\n 'creditCardExpiryYear',\n];\n\ntype OnInputKeydownTagHandlerType = (key: string | undefined) => void;\nconst useTags = (\n tags: BaseInputProps['tags'],\n activeTagIndex: number,\n setActiveTagIndex?: (activeTagIndex: number) => void,\n): {\n onInputKeydownTagHandler: OnInputKeydownTagHandlerType;\n visibleTagsCountRef: React.MutableRefObject<number>;\n} => {\n const visibleTagsCountRef = React.useRef<number>(0);\n\n React.useEffect(() => {\n if (tags && activeTagIndex >= 0 && activeTagIndex < tags.length) {\n const tagTitle = tags[activeTagIndex]?.props?.children;\n if (tagTitle) {\n announce(`Close ${tagTitle} Tag`);\n }\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [activeTagIndex, tags?.length]);\n\n const onTagLeft = (): void => {\n if (activeTagIndex < 0) {\n setActiveTagIndex?.(visibleTagsCountRef.current - 1);\n }\n\n if (activeTagIndex > 0) {\n setActiveTagIndex?.(activeTagIndex - 1);\n }\n };\n\n const onTagRight = (): void => {\n if (activeTagIndex < visibleTagsCountRef.current - 1) {\n setActiveTagIndex?.(activeTagIndex + 1);\n }\n };\n\n const onTagRemove = (): void => {\n if (activeTagIndex >= 0 && activeTagIndex < visibleTagsCountRef.current && tags) {\n tags[activeTagIndex].props.onDismiss({ tagIndex: activeTagIndex });\n }\n };\n\n const onInputKeydownTagHandler: OnInputKeydownTagHandlerType = (key) => {\n if (tags && tags.length > 0) {\n if (key === 'ArrowRight') {\n onTagRight();\n }\n\n if (key === 'ArrowLeft') {\n onTagLeft();\n }\n\n if (key === 'Backspace') {\n onTagRemove();\n }\n }\n };\n\n return {\n onInputKeydownTagHandler,\n visibleTagsCountRef,\n };\n};\n\nconst useInput = ({\n value,\n defaultValue,\n onClick,\n onFocus,\n onChange,\n onBlur,\n onSubmit,\n onInput,\n onKeyDown,\n onInputKeydownTagHandler,\n}: Pick<\n BaseInputProps,\n | 'value'\n | 'defaultValue'\n | 'onFocus'\n | 'onChange'\n | 'onBlur'\n | 'onInput'\n | 'onKeyDown'\n | 'onClick'\n | 'onSubmit'\n> & {\n onInputKeydownTagHandler: OnInputKeydownTagHandlerType;\n}): {\n handleOnFocus: FormInputHandleOnEvent;\n handleOnClick: FormInputHandleOnClickEvent;\n handleOnChange: FormInputHandleOnEvent;\n handleOnBlur: FormInputHandleOnEvent;\n handleOnSubmit: FormInputHandleOnEvent;\n handleOnInput: FormInputHandleOnEvent;\n handleOnKeyDown: FormInputHandleOnKeyDownEvent;\n inputValue?: string;\n} => {\n if (__DEV__) {\n if (value && defaultValue) {\n throwBladeError({\n message: `Either 'value' or 'defaultValue' shall be passed. This decides if the input field is controlled or uncontrolled`,\n moduleName: 'Input',\n });\n }\n }\n\n const [inputValue, setInputValue] = React.useState(defaultValue ?? value);\n\n const handleOnFocus: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n\n if (getPlatformType() === 'react-native' && typeof value === 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n\n onFocus?.({\n name,\n value: _value,\n });\n },\n [onFocus],\n );\n\n const handleOnClick: FormInputHandleOnClickEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n\n if (getPlatformType() === 'react-native' && typeof value === 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.currentTarget.value ?? '';\n }\n\n onClick?.({\n name,\n value: _value,\n });\n },\n [onClick],\n );\n\n const handleOnSubmit: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n\n if (getPlatformType() === 'react-native' && typeof value === 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n if (isReactNative()) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment, @typescript-eslint/prefer-ts-expect-error\n //@ts-ignore need to ignore this since it will throw a TS error for web but not for native\n onSubmit?.({\n name,\n value: _value,\n });\n }\n },\n [onSubmit],\n );\n\n const handleOnBlur: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n if (getPlatformType() === 'react-native' && typeof value == 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n\n onBlur?.({\n name,\n value: _value,\n });\n },\n [onBlur],\n );\n\n const handleOnChange: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n\n if (getPlatformType() === 'react-native' && typeof value === 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n\n onChange?.({\n name,\n value: _value,\n });\n setInputValue(_value);\n },\n [onChange],\n );\n\n const handleOnInput: FormInputHandleOnEvent = React.useCallback(\n ({ name, value }) => {\n let _value = '';\n if (getPlatformType() === 'react-native' && typeof value == 'string') {\n _value = value;\n } else if (typeof value !== 'string') {\n // Could have just done \"getPlatformType() === 'react-native' ? value : value?.target.value\" but TS doesn't understands that\n _value = value?.target.value ?? '';\n }\n\n onInput?.({\n name,\n value: _value,\n });\n },\n [onInput],\n );\n\n const handleOnKeyDown: FormInputHandleOnKeyDownEvent = React.useCallback(\n ({ name, key, code, event }) => {\n onInputKeydownTagHandler(key);\n onKeyDown?.({\n name,\n key,\n code,\n event,\n });\n },\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [onKeyDown],\n );\n\n return {\n handleOnFocus,\n handleOnClick,\n handleOnChange,\n handleOnBlur,\n handleOnSubmit,\n handleOnInput,\n handleOnKeyDown,\n inputValue,\n };\n};\n\nexport const getHintType = ({\n validationState,\n hasHelpText,\n}: {\n validationState: BaseInputProps['validationState'];\n hasHelpText: boolean;\n}): FormHintProps['type'] => {\n if (validationState === 'error') {\n return 'error';\n }\n\n if (validationState === 'success') {\n return 'success';\n }\n\n if (hasHelpText) {\n return 'help';\n }\n\n return 'help';\n};\n\nconst getDescribedByElementId = ({\n validationState,\n hasErrorText,\n hasSuccessText,\n hasHelpText,\n errorTextId,\n successTextId,\n helpTextId,\n}: {\n validationState: BaseInputProps['validationState'];\n hasErrorText: boolean;\n hasSuccessText: boolean;\n hasHelpText: boolean;\n errorTextId: string;\n successTextId: string;\n helpTextId: string;\n}): string => {\n if (validationState === 'error' && hasErrorText) {\n return errorTextId;\n }\n\n if (validationState === 'success' && hasSuccessText) {\n return successTextId;\n }\n\n if (hasHelpText) {\n return helpTextId;\n }\n\n return '';\n};\n\nconst FocusRingWrapper = styled(BaseBox)<{\n currentInteraction: ActionStates;\n isTableInputCell: NonNullable<BaseInputProps['isTableInputCell']>;\n}>(({ theme, currentInteraction, isTableInputCell }) => ({\n borderRadius: makeBorderSize(\n isTableInputCell ? theme.border.radius.none : theme.border.radius.medium,\n ),\n width: '100%',\n '&:focus-within': !isTableInputCell\n ? {\n ...getFocusRingStyles({\n theme,\n }),\n transitionDuration: castWebType(\n makeMotionTime(\n getIn(\n theme.motion.duration,\n baseInputBorderBackgroundMotion[currentInteraction === 'focus' ? 'enter' : 'exit']\n .duration,\n ),\n ),\n ),\n transitionTimingFunction: castWebType(\n getIn(\n theme.motion.easing,\n baseInputBorderBackgroundMotion[currentInteraction === 'focus' ? 'enter' : 'exit']\n .easing,\n ),\n ),\n }\n : {},\n}));\n\nconst _BaseInput: React.ForwardRefRenderFunction<BladeElementRef, BaseInputProps> = (\n {\n as = 'input',\n label,\n labelPosition = 'top',\n placeholder,\n type = 'text',\n defaultValue,\n tags,\n showAllTags = false,\n activeTagIndex = -1,\n setActiveTagIndex,\n name,\n value,\n onFocus,\n onChange,\n onInput,\n onBlur,\n onSubmit,\n onClick,\n onKeyDown,\n isDisabled,\n necessityIndicator,\n validationState,\n errorText,\n helpText,\n successText,\n isRequired,\n leadingIcon,\n prefix,\n trailingInteractionElement,\n onTrailingInteractionElementClick,\n leadingInteractionElement,\n suffix,\n trailingIcon,\n maxCharacters,\n textAlign,\n autoFocus,\n keyboardReturnKeyType,\n keyboardType,\n autoCompleteSuggestionType,\n trailingHeaderSlot,\n trailingFooterSlot,\n numberOfLines,\n id,\n componentName,\n accessibilityLabel,\n labelId,\n activeDescendant,\n hideLabelText,\n hideFormHint,\n hasPopup,\n popupId,\n isPopupExpanded,\n maxTagRows,\n shouldIgnoreBlurAnimation,\n setShouldIgnoreBlurAnimation,\n autoCapitalize,\n setInputWrapperRef,\n testID,\n isDropdownTrigger,\n isLabelInsideInput,\n size = 'medium',\n trailingButton,\n valueComponentType = 'text',\n isTableInputCell = false,\n showHintsAsTooltip = false,\n ...styledProps\n },\n ref,\n) => {\n const { theme } = useTheme();\n const inputRef = React.useRef<BladeElementRef>(null);\n const mergedInputRef = useMergeRefs(ref, inputRef);\n const inputWrapperRef: InputWrapperRef = React.useRef(null);\n const { onInputKeydownTagHandler, visibleTagsCountRef } = useTags(\n tags,\n activeTagIndex,\n setActiveTagIndex,\n );\n const [showAllTagsWithAnimation, setShowAllTagsWithAnimation] = React.useState(false);\n const isReactNative = getPlatformType() === 'react-native';\n\n React.useEffect(() => {\n if (showAllTags) {\n setShowAllTagsWithAnimation(true);\n } else if (maxTagRows !== 'expandable') {\n setShowAllTagsWithAnimation(false);\n }\n }, [showAllTags, maxTagRows]);\n\n const {\n handleOnFocus,\n handleOnChange,\n handleOnClick,\n handleOnBlur,\n handleOnSubmit,\n handleOnInput,\n handleOnKeyDown,\n inputValue,\n } = useInput({\n defaultValue,\n value,\n onFocus,\n onClick,\n onChange,\n onBlur,\n onSubmit,\n onInput,\n onKeyDown,\n onInputKeydownTagHandler,\n });\n const { inputId, helpTextId, errorTextId, successTextId } = useFormId(id);\n const { matchedDeviceType } = useBreakpoint({ breakpoints: theme.breakpoints });\n const isLabelLeftPositioned = labelPosition === 'left' && matchedDeviceType === 'desktop';\n const { currentInteraction, setCurrentInteraction } = useInteraction();\n const _isRequired = isRequired || necessityIndicator === 'required';\n\n const accessibilityProps = makeAccessible({\n required: Boolean(_isRequired),\n disabled: Boolean(isDisabled),\n invalid: Boolean(validationState === 'error'),\n describedBy: getDescribedByElementId({\n validationState,\n hasErrorText: Boolean(errorText),\n hasSuccessText: Boolean(successText),\n hasHelpText: Boolean(helpText),\n errorTextId,\n successTextId,\n helpTextId,\n }),\n label: accessibilityLabel,\n hasPopup,\n expanded: hasPopup ? isPopupExpanded : undefined,\n controls: hasPopup ? popupId : undefined,\n role: hasPopup ? 'combobox' : undefined,\n activeDescendant,\n });\n\n const willRenderHintText = Boolean(helpText) || Boolean(successText) || Boolean(errorText);\n\n if (__DEV__) {\n if (\n autoCompleteSuggestionType &&\n !autoCompleteSuggestionTypeValues.includes(autoCompleteSuggestionType)\n ) {\n throwBladeError({\n message: `Expected autoCompleteSuggestionType to be one of ${autoCompleteSuggestionTypeValues.join(\n ', ',\n )} but received ${autoCompleteSuggestionType}`,\n moduleName: 'Input',\n });\n }\n }\n\n const isTextArea = as === 'textarea';\n return (\n <BaseBox {...metaAttribute({ name: componentName, testID })} {...getStyledProps(styledProps)}>\n <BaseBox\n display=\"flex\"\n flexDirection={isLabelLeftPositioned ? 'row' : 'column'}\n justifyContent={isLabelLeftPositioned ? 'center' : undefined}\n alignItems={isLabelLeftPositioned ? 'center' : undefined}\n position=\"relative\"\n width=\"100%\"\n >\n {!hideLabelText && !isLabelInsideInput && label && (\n <BaseBox\n display=\"flex\"\n flexDirection={isLabelLeftPositioned ? 'column' : 'row'}\n justifyContent=\"space-between\"\n alignSelf={isTextArea ? 'flex-start' : undefined}\n marginY={isTextArea && isLabelLeftPositioned ? 'spacing.3' : 'spacing.0'}\n >\n <FormLabel\n as=\"label\"\n necessityIndicator={necessityIndicator}\n position={labelPosition}\n id={labelId}\n htmlFor={inputId}\n size={size}\n >\n {label}\n </FormLabel>\n {trailingHeaderSlot?.(value ?? inputValue)}\n </BaseBox>\n )}\n <FocusRingWrapper\n currentInteraction={currentInteraction}\n isTableInputCell={isTableInputCell}\n >\n <BaseInputWrapper\n isDropdownTrigger={isDropdownTrigger}\n isTextArea={isTextArea}\n isDisabled={isDisabled}\n validationState={validationState}\n currentInteraction={currentInteraction}\n isLabelLeftPositioned={isLabelLeftPositioned}\n showAllTags={showAllTags}\n setShowAllTagsWithAnimation={setShowAllTagsWithAnimation}\n ref={(refNode) => {\n if (refNode) {\n setInputWrapperRef?.(refNode);\n inputWrapperRef.current = refNode;\n }\n }}\n maxTagRows={maxTagRows}\n size={size}\n numberOfLines={numberOfLines}\n onClick={() => {\n if (!isReactNative) {\n inputRef.current?.focus();\n }\n }}\n isTableInputCell={isTableInputCell}\n >\n <BaseInputVisuals\n size={size}\n leadingIcon={leadingIcon}\n prefix={prefix}\n isDisabled={isDisabled}\n leadingInteractionElement={leadingInteractionElement}\n />\n <BaseInputTagSlot\n renderAs={as}\n tags={tags}\n isDisabled={isDisabled}\n showAllTags={showAllTagsWithAnimation}\n setFocusOnInput={() => {\n if (ref && !isReactNative && 'current' in ref) {\n ref.current?.focus();\n }\n }}\n labelPrefix={isLabelInsideInput ? label : undefined}\n isDropdownTrigger={isDropdownTrigger}\n visibleTagsCountRef={visibleTagsCountRef}\n handleOnInputClick={(e) => {\n handleOnClick({ name, value: isReactNative ? value : e });\n }}\n setShouldIgnoreBlurAnimation={setShouldIgnoreBlurAnimation}\n maxTagRows={maxTagRows}\n inputWrapperRef={inputWrapperRef}\n size={size}\n numberOfLines={numberOfLines}\n isTextArea={isTextArea}\n >\n <StyledBaseInput\n as={as}\n id={inputId}\n ref={mergedInputRef as any}\n name={name}\n type={type}\n defaultValue={defaultValue}\n value={value}\n placeholder={placeholder}\n isDisabled={isDisabled}\n validationState={validationState}\n isRequired={_isRequired}\n handleOnFocus={handleOnFocus}\n handleOnChange={handleOnChange}\n handleOnBlur={handleOnBlur}\n handleOnSubmit={handleOnSubmit}\n handleOnInput={handleOnInput}\n handleOnKeyDown={handleOnKeyDown}\n handleOnClick={handleOnClick}\n leadingIcon={leadingIcon}\n prefix={prefix}\n trailingInteractionElement={trailingInteractionElement}\n leadingInteractionElement={leadingInteractionElement}\n suffix={suffix}\n trailingIcon={trailingIcon}\n maxCharacters={maxCharacters}\n textAlign={textAlign}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autoFocus}\n keyboardReturnKeyType={keyboardReturnKeyType}\n keyboardType={keyboardType}\n autoCompleteSuggestionType={autoCompleteSuggestionType}\n accessibilityProps={accessibilityProps}\n currentInteraction={currentInteraction}\n setCurrentInteraction={setCurrentInteraction}\n numberOfLines={numberOfLines}\n isTextArea={isTextArea || maxTagRows === 'multiple' || maxTagRows === 'expandable'}\n hasPopup={hasPopup}\n hasTags={!!(tags && tags.length > 0)}\n shouldIgnoreBlurAnimation={shouldIgnoreBlurAnimation}\n autoCapitalize={autoCapitalize}\n isDropdownTrigger={isDropdownTrigger}\n $size={size}\n valueComponentType={valueComponentType}\n isTableInputCell={isTableInputCell}\n {...metaAttribute({ name: MetaConstants.StyledBaseInput })}\n />\n </BaseInputTagSlot>\n <BaseInputVisuals\n trailingInteractionElement={trailingInteractionElement}\n onTrailingInteractionElementClick={onTrailingInteractionElementClick}\n suffix={suffix}\n trailingIcon={trailingIcon}\n isDisabled={isDisabled}\n validationState={validationState}\n trailingButton={trailingButton}\n size={size}\n errorText={errorText}\n successText={successText}\n showHintsAsTooltip={showHintsAsTooltip}\n />\n </BaseInputWrapper>\n </FocusRingWrapper>\n </BaseBox>\n\n {hideFormHint || showHintsAsTooltip ? null : (\n <BaseBox\n marginLeft={makeSize(\n isLabelLeftPositioned && !hideLabelText ? formHintLeftLabelMarginLeft[size] : 0,\n )}\n >\n <BaseBox\n display=\"flex\"\n flexDirection=\"row\"\n justifyContent={willRenderHintText ? 'space-between' : 'flex-end'}\n >\n <FormHint\n type={getHintType({ validationState, hasHelpText: Boolean(helpText) })}\n helpText={helpText}\n errorText={errorText}\n successText={successText}\n helpTextId={helpTextId}\n errorTextId={errorTextId}\n successTextId={successTextId}\n size={size}\n />\n {trailingFooterSlot?.(value ?? inputValue)}\n </BaseBox>\n </BaseBox>\n )}\n </BaseBox>\n );\n};\n\nconst BaseInputWithRef = React.forwardRef(_BaseInput);\nconst BaseInput = assignWithoutSideEffects(BaseInputWithRef, { displayName: 'BaseInput' });\n\nexport { BaseInput };\n"],"names":["autoCompleteSuggestionTypeValues","useTags","tags","activeTagIndex","setActiveTagIndex","visibleTagsCountRef","React","useRef","useEffect","length","_tags$activeTagIndex","_tags$activeTagIndex$","tagTitle","props","children","announce","concat","onTagLeft","current","onTagRight","onTagRemove","onDismiss","tagIndex","onInputKeydownTagHandler","key","useInput","_ref","value","defaultValue","onClick","onFocus","onChange","onBlur","onSubmit","onInput","onKeyDown","throwBladeError","message","moduleName","_React$useState","useState","_React$useState2","_slicedToArray","inputValue","setInputValue","handleOnFocus","useCallback","_ref2","name","_value","getPlatformType","_value$target$value","target","handleOnClick","_ref3","_value$currentTarget$","currentTarget","handleOnSubmit","_ref4","_value$target$value2","isReactNative","handleOnBlur","_ref5","_value$target$value3","handleOnChange","_ref6","_value$target$value4","handleOnInput","_ref7","_value$target$value5","handleOnKeyDown","_ref8","code","event","getHintType","_ref9","validationState","hasHelpText","getDescribedByElementId","_ref10","hasErrorText","hasSuccessText","errorTextId","successTextId","helpTextId","FocusRingWrapper","styled","BaseBox","withConfig","displayName","componentId","_ref11","theme","currentInteraction","isTableInputCell","borderRadius","makeBorderSize","border","radius","none","medium","width","_objectSpread","getFocusRingStyles","transitionDuration","castWebType","makeMotionTime","getIn","motion","duration","baseInputBorderBackgroundMotion","transitionTimingFunction","easing","_BaseInput","_ref12","ref","_ref12$as","as","label","_ref12$labelPosition","labelPosition","placeholder","_ref12$type","type","_ref12$showAllTags","showAllTags","_ref12$activeTagIndex","isDisabled","necessityIndicator","errorText","helpText","successText","isRequired","leadingIcon","prefix","trailingInteractionElement","onTrailingInteractionElementClick","leadingInteractionElement","suffix","trailingIcon","maxCharacters","textAlign","autoFocus","keyboardReturnKeyType","keyboardType","autoCompleteSuggestionType","trailingHeaderSlot","trailingFooterSlot","numberOfLines","id","componentName","accessibilityLabel","labelId","activeDescendant","hideLabelText","hideFormHint","hasPopup","popupId","isPopupExpanded","maxTagRows","shouldIgnoreBlurAnimation","setShouldIgnoreBlurAnimation","autoCapitalize","setInputWrapperRef","testID","isDropdownTrigger","isLabelInsideInput","_ref12$size","size","trailingButton","_ref12$valueComponent","valueComponentType","_ref12$isTableInputCe","_ref12$showHintsAsToo","showHintsAsTooltip","styledProps","_objectWithoutProperties","_excluded","_useTheme","useTheme","inputRef","mergedInputRef","useMergeRefs","inputWrapperRef","_useTags","_React$useState3","_React$useState4","showAllTagsWithAnimation","setShowAllTagsWithAnimation","_useInput","_useFormId","useFormId","inputId","_useBreakpoint","useBreakpoint","breakpoints","matchedDeviceType","isLabelLeftPositioned","_useInteraction","useInteraction","setCurrentInteraction","_isRequired","accessibilityProps","makeAccessible","required","Boolean","disabled","invalid","describedBy","expanded","undefined","controls","role","willRenderHintText","includes","join","isTextArea","_jsxs","metaAttribute","getStyledProps","display","flexDirection","justifyContent","alignItems","position","alignSelf","marginY","_jsx","FormLabel","htmlFor","BaseInputWrapper","refNode","_inputRef$current","focus","BaseInputVisuals","BaseInputTagSlot","renderAs","setFocusOnInput","_ref$current","labelPrefix","handleOnInputClick","e","StyledBaseInput","hasTags","$size","MetaConstants","marginLeft","makeSize","formHintLeftLabelMarginLeft","FormHint","BaseInputWithRef","forwardRef","BaseInput","assignWithoutSideEffects"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsZA,IAAMA,gCAAgC,GAAG,CACvC,MAAM,EACN,IAAI,EACJ,MAAM,EACN,OAAO,EACP,UAAU,EACV,UAAU,EACV,aAAa,EACb,aAAa,EACb,WAAW,EACX,YAAY,EACZ,aAAa,EACb,kBAAkB,EAClB,eAAe,EACf,kBAAkB,EAClB,uBAAuB,EACvB,sBAAsB,CACvB,CAAA;AAGD,IAAMC,OAAO,GAAG,SAAVA,OAAOA,CACXC,IAA4B,EAC5BC,cAAsB,EACtBC,iBAAoD,EAIjD;AACH,EAAA,IAAMC,mBAAmB,GAAGC,cAAK,CAACC,MAAM,CAAS,CAAC,CAAC,CAAA;EAEnDD,cAAK,CAACE,SAAS,CAAC,YAAM;IACpB,IAAIN,IAAI,IAAIC,cAAc,IAAI,CAAC,IAAIA,cAAc,GAAGD,IAAI,CAACO,MAAM,EAAE;MAAA,IAAAC,oBAAA,EAAAC,qBAAA,CAAA;MAC/D,IAAMC,QAAQ,IAAAF,oBAAA,GAAGR,IAAI,CAACC,cAAc,CAAC,MAAAO,IAAAA,IAAAA,oBAAA,wBAAAC,qBAAA,GAApBD,oBAAA,CAAsBG,KAAK,cAAAF,qBAAA,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,GAA3BA,qBAAA,CAA6BG,QAAQ,CAAA;AACtD,MAAA,IAAIF,QAAQ,EAAE;AACZG,QAAAA,QAAQ,CAAAC,QAAAA,CAAAA,MAAA,CAAUJ,QAAQ,SAAM,CAAC,CAAA;AACnC,OAAA;AACF,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