@xqmsg/ui-core 0.25.1 → 0.26.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/dist/theme/foundations/breakpoints.d.ts +4 -1
- package/dist/ui-core.cjs.development.js +35 -5
- package/dist/ui-core.cjs.development.js.map +1 -1
- package/dist/ui-core.cjs.production.min.js +1 -1
- package/dist/ui-core.cjs.production.min.js.map +1 -1
- package/dist/ui-core.esm.js +36 -6
- package/dist/ui-core.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/input/Input.stories.tsx +18 -1
- package/src/components/input/StackedPilledInput/index.tsx +38 -2
- package/src/components/input/components/token/index.tsx +1 -1
- package/src/theme/foundations/breakpoints.ts +2 -7
|
@@ -1,3 +1,6 @@
|
|
|
1
1
|
import { BaseBreakpointConfig } from '@chakra-ui/theme-tools';
|
|
2
|
-
|
|
2
|
+
/**
|
|
3
|
+
* Breakpoints for responsive design
|
|
4
|
+
*/
|
|
5
|
+
declare const breakpoints: BaseBreakpointConfig;
|
|
3
6
|
export default breakpoints;
|
|
@@ -1319,7 +1319,7 @@ var Token = function Token(_ref) {
|
|
|
1319
1319
|
wordBreak: "break-word",
|
|
1320
1320
|
color: colors.label.primary.light,
|
|
1321
1321
|
fontSize: isMobile ? '17px' : '13px',
|
|
1322
|
-
lineHeight:
|
|
1322
|
+
lineHeight: "1.5",
|
|
1323
1323
|
pr: "2px",
|
|
1324
1324
|
maxWidth: maxWidth,
|
|
1325
1325
|
overflow: "hidden",
|
|
@@ -1848,6 +1848,8 @@ var StackedPilledInput = /*#__PURE__*/React__default.forwardRef(function (_ref2,
|
|
|
1848
1848
|
onClick: function onClick() {
|
|
1849
1849
|
if (isFocussed && tokenIndex !== null) {
|
|
1850
1850
|
setTokenIndex(null);
|
|
1851
|
+
} else if (!scrollMode) {
|
|
1852
|
+
setIsFocussed(true);
|
|
1851
1853
|
}
|
|
1852
1854
|
if (!disabled) {
|
|
1853
1855
|
var _inputRef$current;
|
|
@@ -1865,7 +1867,8 @@ var StackedPilledInput = /*#__PURE__*/React__default.forwardRef(function (_ref2,
|
|
|
1865
1867
|
overflowX: scrollMode ? 'scroll' : 'hidden',
|
|
1866
1868
|
flexWrap: scrollMode ? 'nowrap' : 'wrap',
|
|
1867
1869
|
overflowY: "hidden",
|
|
1868
|
-
|
|
1870
|
+
width: scrollMode ? 'auto' : '100%',
|
|
1871
|
+
maxWidth: isFocussed && scrollMode ? '80%' : '100%',
|
|
1869
1872
|
style: {
|
|
1870
1873
|
scrollbarWidth: 'none' /* Firefox */,
|
|
1871
1874
|
msOverflowStyle: 'none'
|
|
@@ -1912,7 +1915,35 @@ var StackedPilledInput = /*#__PURE__*/React__default.forwardRef(function (_ref2,
|
|
|
1912
1915
|
color: colors.label.secondary.light,
|
|
1913
1916
|
fontSize: isMobile ? '17px' : '13px',
|
|
1914
1917
|
pointerEvents: "none"
|
|
1915
|
-
}, placeholder) : null
|
|
1918
|
+
}, placeholder) : null, !disabled && !scrollMode && /*#__PURE__*/React__default.createElement(react.Flex, {
|
|
1919
|
+
flex: 1,
|
|
1920
|
+
minWidth: isFocussed && !tokenIndex ? 'auto' : '100px'
|
|
1921
|
+
}, /*#__PURE__*/React__default.createElement(react.Input, {
|
|
1922
|
+
onKeyDown: onHandleKeyDown,
|
|
1923
|
+
type: "text",
|
|
1924
|
+
padding: 0,
|
|
1925
|
+
alignContent: "flex-start",
|
|
1926
|
+
"float": "right",
|
|
1927
|
+
border: "none",
|
|
1928
|
+
height: "auto",
|
|
1929
|
+
color: tokenIndex !== null ? 'transparent' : colors.label.primary,
|
|
1930
|
+
_focus: {
|
|
1931
|
+
boxShadow: 'none !important'
|
|
1932
|
+
},
|
|
1933
|
+
value: localValue,
|
|
1934
|
+
onChange: handleOnChange,
|
|
1935
|
+
ref: inputRef,
|
|
1936
|
+
onFocus: function onFocus() {
|
|
1937
|
+
return setIsFocussed(true);
|
|
1938
|
+
},
|
|
1939
|
+
fontSize: isMobile ? '17px' : '13px',
|
|
1940
|
+
lineHeight: 1.5,
|
|
1941
|
+
placeholder: isMobile && label && lastestFormValueToArray.length === 0 ? label : '',
|
|
1942
|
+
variant: variant,
|
|
1943
|
+
style: isMobile ? {
|
|
1944
|
+
border: 'none'
|
|
1945
|
+
} : undefined
|
|
1946
|
+
}))), !disabled && scrollMode && /*#__PURE__*/React__default.createElement(react.Flex, {
|
|
1916
1947
|
flex: 1,
|
|
1917
1948
|
minWidth: isFocussed && !tokenIndex ? '20%' : 0
|
|
1918
1949
|
}, /*#__PURE__*/React__default.createElement(react.Input, {
|
|
@@ -3757,13 +3788,12 @@ var Text = function Text(_ref) {
|
|
|
3757
3788
|
/**
|
|
3758
3789
|
* Breakpoints for responsive design
|
|
3759
3790
|
*/
|
|
3760
|
-
var
|
|
3791
|
+
var breakpoints = {
|
|
3761
3792
|
sm: '30em',
|
|
3762
3793
|
md: '48em',
|
|
3763
3794
|
lg: '62em',
|
|
3764
3795
|
xl: '80em'
|
|
3765
3796
|
};
|
|
3766
|
-
var breakpoints = /*#__PURE__*/themeTools.createBreakpoints(breakpointValues);
|
|
3767
3797
|
|
|
3768
3798
|
var shadows = {
|
|
3769
3799
|
xs: '0 0 0 1px rgba(0, 0, 0, 0.05)',
|