New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@s-ui/react-atom-input

Package Overview
Dependencies
Maintainers
4
Versions
103
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@s-ui/react-atom-input - npm Package Compare versions

Comparing version 4.24.0 to 5.0.0

8

lib/index.js

@@ -0,2 +1,4 @@

import _extends from "@babel/runtime/helpers/esm/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
import { jsx as _jsx } from "react/jsx-runtime";
import React from 'react';

@@ -23,9 +25,9 @@ import Input, { inputSizes, inputStates } from './Input';

case 'sui-password':
return /*#__PURE__*/React.createElement(Password, props);
return /*#__PURE__*/_jsx(Password, _extends({}, props));
case 'mask':
return /*#__PURE__*/React.createElement(Mask, props);
return /*#__PURE__*/_jsx(Mask, _extends({}, props));
default:
return /*#__PURE__*/React.createElement(Input, Object.assign({}, props, {
return /*#__PURE__*/_jsx(Input, _extends({}, props, {
type: type

@@ -32,0 +34,0 @@ }));

@@ -0,1 +1,2 @@

import { jsx as _jsx } from "react/jsx-runtime";
import React from 'react';

@@ -108,6 +109,6 @@ import cx from 'classnames';

});
return /*#__PURE__*/React.createElement("input", {
return /*#__PURE__*/_jsx("input", {
className: className,
tabIndex: tabIndex,
disabled: disabled || readOnly,
disabled: disabled,
readOnly: readOnly,

@@ -114,0 +115,0 @@ id: id,

@@ -0,2 +1,5 @@

import _extends from "@babel/runtime/helpers/esm/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
import { jsx as _jsx } from "react/jsx-runtime";
import { jsxs as _jsxs } from "react/jsx-runtime";
import React from 'react';

@@ -22,13 +25,16 @@ import cx from 'classnames';

return leftAddon || rightAddon ? /*#__PURE__*/React.createElement("div", {
className: CLASS_ADDON_WRAPPER
}, leftAddon && /*#__PURE__*/React.createElement("span", {
className: getClassName({
type: TYPES.LEFT
})
}, leftAddon), /*#__PURE__*/React.createElement(WrappedInput, props), rightAddon && /*#__PURE__*/React.createElement("span", {
className: getClassName({
type: TYPES.RIGHT
})
}, rightAddon)) : /*#__PURE__*/React.createElement(WrappedInput, props);
return leftAddon || rightAddon ? /*#__PURE__*/_jsxs("div", {
className: CLASS_ADDON_WRAPPER,
children: [leftAddon && /*#__PURE__*/_jsx("span", {
className: getClassName({
type: TYPES.LEFT
}),
children: leftAddon
}), /*#__PURE__*/_jsx(WrappedInput, _extends({}, props)), rightAddon && /*#__PURE__*/_jsx("span", {
className: getClassName({
type: TYPES.RIGHT
}),
children: rightAddon
})]
}) : /*#__PURE__*/_jsx(WrappedInput, _extends({}, props));
};

@@ -35,0 +41,0 @@

@@ -0,3 +1,6 @@

import _extends from "@babel/runtime/helpers/esm/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
import _inheritsLoose from "@babel/runtime/helpers/esm/inheritsLoose";
import { jsx as _jsx } from "react/jsx-runtime";
import { jsxs as _jsxs } from "react/jsx-runtime";
import React from 'react';

@@ -58,11 +61,14 @@ import cx from 'classnames';

return leftIcon || rightIcon ? /*#__PURE__*/React.createElement("div", {
className: cx(CLASS_ICON, (_cx = {}, _cx[CLASS_ICON_LEFT] = leftIcon, _cx[CLASS_ICON_RIGHT] = rightIcon, _cx))
}, leftIcon && /*#__PURE__*/React.createElement("span", {
className: cx(CLASS_ICON_COMPONENT, CLASS_ICON_COMPONENT_LEFT, (_cx2 = {}, _cx2[CLASS_ICON_COMPONENT_HANDLER] = onClickLeftIcon, _cx2)),
onClick: this.handleLeftClick
}, leftIcon), /*#__PURE__*/React.createElement(WrappedInput, props), rightIcon && /*#__PURE__*/React.createElement("span", {
className: cx(CLASS_ICON_COMPONENT, CLASS_ICON_COMPONENT_RIGHT, (_cx3 = {}, _cx3[CLASS_ICON_COMPONENT_HANDLER] = onClickRightIcon, _cx3)),
onClick: this.handleRightClick
}, rightIcon)) : /*#__PURE__*/React.createElement(WrappedInput, props);
return leftIcon || rightIcon ? /*#__PURE__*/_jsxs("div", {
className: cx(CLASS_ICON, (_cx = {}, _cx[CLASS_ICON_LEFT] = leftIcon, _cx[CLASS_ICON_RIGHT] = rightIcon, _cx)),
children: [leftIcon && /*#__PURE__*/_jsx("span", {
className: cx(CLASS_ICON_COMPONENT, CLASS_ICON_COMPONENT_LEFT, (_cx2 = {}, _cx2[CLASS_ICON_COMPONENT_HANDLER] = onClickLeftIcon, _cx2)),
onClick: this.handleLeftClick,
children: leftIcon
}), /*#__PURE__*/_jsx(WrappedInput, _extends({}, props)), rightIcon && /*#__PURE__*/_jsx("span", {
className: cx(CLASS_ICON_COMPONENT, CLASS_ICON_COMPONENT_RIGHT, (_cx3 = {}, _cx3[CLASS_ICON_COMPONENT_HANDLER] = onClickRightIcon, _cx3)),
onClick: this.handleRightClick,
children: rightIcon
})]
}) : /*#__PURE__*/_jsx(WrappedInput, _extends({}, props));
};

@@ -69,0 +75,0 @@

@@ -0,2 +1,5 @@

import _extends from "@babel/runtime/helpers/esm/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
import { jsx as _jsx } from "react/jsx-runtime";
import { jsxs as _jsxs } from "react/jsx-runtime";
import React from 'react';

@@ -10,9 +13,12 @@ var BASE_CLASS = 'sui-AtomInput-withButton';

return button ? /*#__PURE__*/React.createElement("div", {
className: BASE_CLASS
}, /*#__PURE__*/React.createElement("div", {
className: BASE_CLASS + "-input"
}, /*#__PURE__*/React.createElement(WrappedInput, props)), /*#__PURE__*/React.createElement("div", {
className: BASE_CLASS + "-button"
}, button)) : /*#__PURE__*/React.createElement(WrappedInput, props);
return button ? /*#__PURE__*/_jsxs("div", {
className: BASE_CLASS,
children: [/*#__PURE__*/_jsx("div", {
className: BASE_CLASS + "-input",
children: /*#__PURE__*/_jsx(WrappedInput, _extends({}, props))
}), /*#__PURE__*/_jsx("div", {
className: BASE_CLASS + "-button",
children: button
})]
}) : /*#__PURE__*/_jsx(WrappedInput, _extends({}, props));
};

@@ -19,0 +25,0 @@

@@ -0,2 +1,4 @@

import _extends from "@babel/runtime/helpers/esm/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
import { jsx as _jsx } from "react/jsx-runtime";
import React, { useState, useEffect, useRef } from 'react';

@@ -38,3 +40,3 @@ import Input from '../Input';

return /*#__PURE__*/React.createElement(Input, Object.assign({
return /*#__PURE__*/_jsx(Input, _extends({
id: name,

@@ -41,0 +43,0 @@ reference: refInput,

@@ -0,2 +1,5 @@

import _extends from "@babel/runtime/helpers/esm/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
import { jsx as _jsx } from "react/jsx-runtime";
import { jsxs as _jsxs } from "react/jsx-runtime";
import React, { useState } from 'react';

@@ -39,12 +42,14 @@ import Input from '../Input';

return /*#__PURE__*/React.createElement("div", {
className: CLASS_PASSWORD
}, /*#__PURE__*/React.createElement(Input, Object.assign({}, props, {
onChange: handleChange,
value: value,
type: type
})), /*#__PURE__*/React.createElement("div", {
onClick: toggle,
className: CLASS_PASSWORD_TOGGLE_BUTTON
}, type === PASSWORD ? pwShowLabel : pwHideLabel));
return /*#__PURE__*/_jsxs("div", {
className: CLASS_PASSWORD,
children: [/*#__PURE__*/_jsx(Input, _extends({}, props, {
onChange: handleChange,
value: value,
type: type
})), /*#__PURE__*/_jsx("div", {
onClick: toggle,
className: CLASS_PASSWORD_TOGGLE_BUTTON,
children: type === PASSWORD ? pwShowLabel : pwHideLabel
})]
});
};

@@ -51,0 +56,0 @@

{
"name": "@s-ui/react-atom-input",
"version": "4.24.0",
"version": "5.0.0",
"description": "",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc