@elliemae/ds-form 2.3.0-next.4 → 2.3.0-next.8

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.
@@ -5,7 +5,7 @@ require('core-js/modules/esnext.iterator.constructor.js');
5
5
  require('core-js/modules/esnext.iterator.filter.js');
6
6
  require('core-js/modules/esnext.async-iterator.for-each.js');
7
7
  require('core-js/modules/esnext.iterator.for-each.js');
8
- var _jsx = require('@babel/runtime/helpers/jsx');
8
+ var _objectWithoutProperties = require('@babel/runtime/helpers/objectWithoutProperties');
9
9
  var _defineProperty = require('@babel/runtime/helpers/defineProperty');
10
10
  require('react');
11
11
  var lodash = require('lodash');
@@ -15,12 +15,15 @@ var MultiValueLabel = require('./components/MultiValueLabel.js');
15
15
  var MultiValueRemove = require('./components/MultiValueRemove.js');
16
16
  var SingleValue = require('./components/SingleValue.js');
17
17
  var SingleValueRemove = require('./components/SingleValueRemove.js');
18
+ var jsxRuntime = require('react/jsx-runtime');
18
19
 
19
20
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
20
21
 
21
- var _jsx__default = /*#__PURE__*/_interopDefaultLegacy(_jsx);
22
+ var _objectWithoutProperties__default = /*#__PURE__*/_interopDefaultLegacy(_objectWithoutProperties);
22
23
  var _defineProperty__default = /*#__PURE__*/_interopDefaultLegacy(_defineProperty);
23
24
 
25
+ const _excluded = ["isMulti", "options", "value", "onChange", "onChangeV2", "onInputChange", "onFocus", "onBlur", "containerProps", "disabled", "menuIsOpen", "placeholder", "formatCreateLabel", "maxOptions"];
26
+
24
27
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
25
28
 
26
29
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
@@ -63,8 +66,10 @@ function ComboBoxFreeSolo(_ref) {
63
66
  placeholder = 'Select values',
64
67
  formatCreateLabel = val => "Create ".concat(val),
65
68
  maxOptions = undefined
66
- } = _ref;
67
- return /*#__PURE__*/_jsx__default["default"](Combobox.DSComboBox2, {
69
+ } = _ref,
70
+ rest = _objectWithoutProperties__default["default"](_ref, _excluded);
71
+
72
+ return /*#__PURE__*/jsxRuntime.jsx(Combobox.DSComboBox2, _objectSpread(_objectSpread({}, rest), {}, {
68
73
  isFreeSolo: true,
69
74
  clearable: true,
70
75
  isMulti: isMulti,
@@ -89,7 +94,7 @@ function ComboBoxFreeSolo(_ref) {
89
94
  SingleValue: SingleValue.SingleValue
90
95
  },
91
96
  componentsStyle: customStyles
92
- });
97
+ }));
93
98
  }
94
99
 
95
100
  module.exports = ComboBoxFreeSolo;
@@ -51,7 +51,6 @@ const MultiMenuItem = props => {
51
51
  pr: render ? 0 : 40,
52
52
  "data-testid": "combobox-option",
53
53
  children: /*#__PURE__*/_jsx__default["default"](styled$1.StyledItemContent, {}, void 0, render ? render(props) : /*#__PURE__*/_jsx__default["default"](dsControlledForm.DSControlledCheckbox, {
54
- tabIndex: tabIndex,
55
54
  disabled: disabled,
56
55
  checked: isSelected,
57
56
  onMouseDown: onMouseDown,
@@ -31,7 +31,8 @@ const SingleMenuItem = props => {
31
31
  onMouseLeave,
32
32
  wrapperStyles,
33
33
  render,
34
- dataTestid
34
+ dataTestid,
35
+ disabled
35
36
  } = props;
36
37
  return /*#__PURE__*/jsxRuntime.jsx(styled.StyledGlobalMenuItemWrapper, {
37
38
  "aria-selected": isSelected,
@@ -49,6 +50,7 @@ const SingleMenuItem = props => {
49
50
  style: wrapperStyles,
50
51
  pr: render ? 0 : 40,
51
52
  "data-testid": dataTestid,
53
+ disabled: disabled,
52
54
  children: render ? render(props) : /*#__PURE__*/_jsx__default["default"](Grid__default["default"], {
53
55
  cols: ['16px', 'auto'],
54
56
  height: "16px",
@@ -14,11 +14,26 @@ const borderOutside = function (color) {
14
14
  return styled.css([":after{display:block;content:' ';position:absolute;top:0;left:0;right:0;bottom:0;border:", "px solid ", ";pointer-events:none;z-index:7;}"], width, color);
15
15
  };
16
16
 
17
- const disabledOption = () => styled.css(["cursor:not-allowed;*{cursor:not-allowed;}"]);
18
-
19
- const activeBorderCss = props => borderOutside(props.theme.colors.brand[500]);
17
+ const disabledOption = () => styled.css(["color:", ";cursor:not-allowed;*{cursor:not-allowed;}"], _ref => {
18
+ let {
19
+ theme
20
+ } = _ref;
21
+ return theme.colors.neutral[500];
22
+ });
23
+
24
+ const activeBorderCss = _ref2 => {
25
+ let {
26
+ theme
27
+ } = _ref2;
28
+ return borderOutside(theme.colors.brand[500]);
29
+ };
20
30
 
21
- const focusBorderCss = props => borderOutside(props.theme.colors.brand[700], 2);
31
+ const focusBorderCss = _ref3 => {
32
+ let {
33
+ theme
34
+ } = _ref3;
35
+ return borderOutside(theme.colors.brand[700], 2);
36
+ };
22
37
 
23
38
  const StyledGlobalMenuItemWrapper = /*#__PURE__*/styled__default["default"].li.withConfig({
24
39
  componentId: "sc-jyoobd-0"
@@ -30,7 +45,7 @@ const StyledGlobalMenuItemWrapper = /*#__PURE__*/styled__default["default"].li.w
30
45
  }, props => props.isActive ? props.theme.colors.brand[200] : 'white', props => !props.disabled && props.theme.colors.brand[200]);
31
46
  const StyledMenuItemWrapper = /*#__PURE__*/styled__default["default"](StyledGlobalMenuItemWrapper).withConfig({
32
47
  componentId: "sc-jyoobd-1"
33
- })(["background-color:", " !important;cursor:", ";", ";"], props => props.isSelected ? props.theme.colors.brand[200] : 'white', props => props.disabled && 'not-allowed', props => props.isSelected && !props.isFocus ? activeBorderCss(props) : '');
48
+ })(["background-color:", " !important;", ";"], props => props.isSelected ? props.theme.colors.brand[200] : 'white', props => props.isSelected && !props.isFocus ? activeBorderCss(props) : '');
34
49
  const StyledSubmenuItemWrapper = /*#__PURE__*/styled__default["default"](StyledGlobalMenuItemWrapper).withConfig({
35
50
  componentId: "sc-jyoobd-2"
36
51
  })(["", ";padding-right:0;"], props => props.isSelected || props.isActive ? activeBorderCss(props) : '');
@@ -3,7 +3,7 @@ import 'core-js/modules/esnext.iterator.constructor.js';
3
3
  import 'core-js/modules/esnext.iterator.filter.js';
4
4
  import 'core-js/modules/esnext.async-iterator.for-each.js';
5
5
  import 'core-js/modules/esnext.iterator.for-each.js';
6
- import _jsx from '@babel/runtime/helpers/esm/jsx';
6
+ import _objectWithoutProperties from '@babel/runtime/helpers/esm/objectWithoutProperties';
7
7
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
8
8
  import 'react';
9
9
  import { noop } from 'lodash';
@@ -13,6 +13,9 @@ import { MultiValueLabel } from './components/MultiValueLabel.js';
13
13
  import { MultiValueRemove } from './components/MultiValueRemove.js';
14
14
  import { SingleValue } from './components/SingleValue.js';
15
15
  import { SingleValueRemove } from './components/SingleValueRemove.js';
16
+ import { jsx } from 'react/jsx-runtime';
17
+
18
+ const _excluded = ["isMulti", "options", "value", "onChange", "onChangeV2", "onInputChange", "onFocus", "onBlur", "containerProps", "disabled", "menuIsOpen", "placeholder", "formatCreateLabel", "maxOptions"];
16
19
 
17
20
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
18
21
 
@@ -56,8 +59,10 @@ function ComboBoxFreeSolo(_ref) {
56
59
  placeholder = 'Select values',
57
60
  formatCreateLabel = val => "Create ".concat(val),
58
61
  maxOptions = undefined
59
- } = _ref;
60
- return /*#__PURE__*/_jsx(DSComboBox2, {
62
+ } = _ref,
63
+ rest = _objectWithoutProperties(_ref, _excluded);
64
+
65
+ return /*#__PURE__*/jsx(DSComboBox2, _objectSpread(_objectSpread({}, rest), {}, {
61
66
  isFreeSolo: true,
62
67
  clearable: true,
63
68
  isMulti: isMulti,
@@ -82,7 +87,7 @@ function ComboBoxFreeSolo(_ref) {
82
87
  SingleValue
83
88
  },
84
89
  componentsStyle: customStyles
85
- });
90
+ }));
86
91
  }
87
92
 
88
93
  export { ComboBoxFreeSolo as default };
@@ -43,7 +43,6 @@ const MultiMenuItem = props => {
43
43
  pr: render ? 0 : 40,
44
44
  "data-testid": "combobox-option",
45
45
  children: /*#__PURE__*/_jsx(StyledItemContent, {}, void 0, render ? render(props) : /*#__PURE__*/_jsx(DSControlledCheckbox, {
46
- tabIndex: tabIndex,
47
46
  disabled: disabled,
48
47
  checked: isSelected,
49
48
  onMouseDown: onMouseDown,
@@ -22,7 +22,8 @@ const SingleMenuItem = props => {
22
22
  onMouseLeave,
23
23
  wrapperStyles,
24
24
  render,
25
- dataTestid
25
+ dataTestid,
26
+ disabled
26
27
  } = props;
27
28
  return /*#__PURE__*/jsx(StyledGlobalMenuItemWrapper, {
28
29
  "aria-selected": isSelected,
@@ -40,6 +41,7 @@ const SingleMenuItem = props => {
40
41
  style: wrapperStyles,
41
42
  pr: render ? 0 : 40,
42
43
  "data-testid": dataTestid,
44
+ disabled: disabled,
43
45
  children: render ? render(props) : /*#__PURE__*/_jsx(Grid, {
44
46
  cols: ['16px', 'auto'],
45
47
  height: "16px",
@@ -6,11 +6,26 @@ const borderOutside = function (color) {
6
6
  return css([":after{display:block;content:' ';position:absolute;top:0;left:0;right:0;bottom:0;border:", "px solid ", ";pointer-events:none;z-index:7;}"], width, color);
7
7
  };
8
8
 
9
- const disabledOption = () => css(["cursor:not-allowed;*{cursor:not-allowed;}"]);
9
+ const disabledOption = () => css(["color:", ";cursor:not-allowed;*{cursor:not-allowed;}"], _ref => {
10
+ let {
11
+ theme
12
+ } = _ref;
13
+ return theme.colors.neutral[500];
14
+ });
10
15
 
11
- const activeBorderCss = props => borderOutside(props.theme.colors.brand[500]);
16
+ const activeBorderCss = _ref2 => {
17
+ let {
18
+ theme
19
+ } = _ref2;
20
+ return borderOutside(theme.colors.brand[500]);
21
+ };
12
22
 
13
- const focusBorderCss = props => borderOutside(props.theme.colors.brand[700], 2);
23
+ const focusBorderCss = _ref3 => {
24
+ let {
25
+ theme
26
+ } = _ref3;
27
+ return borderOutside(theme.colors.brand[700], 2);
28
+ };
14
29
 
15
30
  const StyledGlobalMenuItemWrapper = /*#__PURE__*/styled.li.withConfig({
16
31
  componentId: "sc-jyoobd-0"
@@ -22,7 +37,7 @@ const StyledGlobalMenuItemWrapper = /*#__PURE__*/styled.li.withConfig({
22
37
  }, props => props.isActive ? props.theme.colors.brand[200] : 'white', props => !props.disabled && props.theme.colors.brand[200]);
23
38
  const StyledMenuItemWrapper = /*#__PURE__*/styled(StyledGlobalMenuItemWrapper).withConfig({
24
39
  componentId: "sc-jyoobd-1"
25
- })(["background-color:", " !important;cursor:", ";", ";"], props => props.isSelected ? props.theme.colors.brand[200] : 'white', props => props.disabled && 'not-allowed', props => props.isSelected && !props.isFocus ? activeBorderCss(props) : '');
40
+ })(["background-color:", " !important;", ";"], props => props.isSelected ? props.theme.colors.brand[200] : 'white', props => props.isSelected && !props.isFocus ? activeBorderCss(props) : '');
26
41
  const StyledSubmenuItemWrapper = /*#__PURE__*/styled(StyledGlobalMenuItemWrapper).withConfig({
27
42
  componentId: "sc-jyoobd-2"
28
43
  })(["", ";padding-right:0;"], props => props.isSelected || props.isActive ? activeBorderCss(props) : '');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elliemae/ds-form",
3
- "version": "2.3.0-next.4",
3
+ "version": "2.3.0-next.8",
4
4
  "license": "MIT",
5
5
  "description": "ICE MT - Dimsum - Form",
6
6
  "module": "./esm/index.js",
@@ -748,28 +748,28 @@
748
748
  "build": "node ../../scripts/build/build.js"
749
749
  },
750
750
  "dependencies": {
751
- "@elliemae/ds-button": "2.3.0-next.4",
752
- "@elliemae/ds-circular-progress-indicator": "2.3.0-next.4",
753
- "@elliemae/ds-classnames": "2.3.0-next.4",
754
- "@elliemae/ds-controlled-form": "2.3.0-next.4",
755
- "@elliemae/ds-dropdownmenu": "2.3.0-next.4",
756
- "@elliemae/ds-form": "2.3.0-next.4",
757
- "@elliemae/ds-grid": "2.3.0-next.4",
758
- "@elliemae/ds-icon": "2.3.0-next.4",
759
- "@elliemae/ds-icons": "2.3.0-next.4",
760
- "@elliemae/ds-menu": "2.3.0-next.4",
761
- "@elliemae/ds-overlay": "2.3.0-next.4",
762
- "@elliemae/ds-pills": "2.3.0-next.4",
763
- "@elliemae/ds-popper": "2.3.0-next.4",
764
- "@elliemae/ds-popperjs": "2.3.0-next.4",
765
- "@elliemae/ds-props-helpers": "2.3.0-next.4",
766
- "@elliemae/ds-separator": "2.3.0-next.4",
767
- "@elliemae/ds-shared": "2.3.0-next.4",
768
- "@elliemae/ds-system": "2.3.0-next.4",
769
- "@elliemae/ds-text-wrapper": "2.3.0-next.4",
770
- "@elliemae/ds-tooltip": "2.3.0-next.4",
771
- "@elliemae/ds-truncated-tooltip-text": "2.3.0-next.4",
772
- "@elliemae/ds-utilities": "2.3.0-next.4",
751
+ "@elliemae/ds-button": "2.3.0-next.8",
752
+ "@elliemae/ds-circular-progress-indicator": "2.3.0-next.8",
753
+ "@elliemae/ds-classnames": "2.3.0-next.8",
754
+ "@elliemae/ds-controlled-form": "2.3.0-next.8",
755
+ "@elliemae/ds-dropdownmenu": "2.3.0-next.8",
756
+ "@elliemae/ds-form": "2.3.0-next.8",
757
+ "@elliemae/ds-grid": "2.3.0-next.8",
758
+ "@elliemae/ds-icon": "2.3.0-next.8",
759
+ "@elliemae/ds-icons": "2.3.0-next.8",
760
+ "@elliemae/ds-menu": "2.3.0-next.8",
761
+ "@elliemae/ds-overlay": "2.3.0-next.8",
762
+ "@elliemae/ds-pills": "2.3.0-next.8",
763
+ "@elliemae/ds-popper": "2.3.0-next.8",
764
+ "@elliemae/ds-popperjs": "2.3.0-next.8",
765
+ "@elliemae/ds-props-helpers": "2.3.0-next.8",
766
+ "@elliemae/ds-separator": "2.3.0-next.8",
767
+ "@elliemae/ds-shared": "2.3.0-next.8",
768
+ "@elliemae/ds-system": "2.3.0-next.8",
769
+ "@elliemae/ds-text-wrapper": "2.3.0-next.8",
770
+ "@elliemae/ds-tooltip": "2.3.0-next.8",
771
+ "@elliemae/ds-truncated-tooltip-text": "2.3.0-next.8",
772
+ "@elliemae/ds-utilities": "2.3.0-next.8",
773
773
  "memoize-one": "~5.1.1",
774
774
  "moment": "~2.29.1",
775
775
  "prop-types": "~15.7.2",
@@ -1,6 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import PropTypes from 'prop-types';
3
- declare function ComboBoxFreeSolo({ isMulti, options, value, onChange, onChangeV2, onInputChange, onFocus, onBlur, containerProps, disabled, menuIsOpen, placeholder, formatCreateLabel, maxOptions, }: {
3
+ declare function ComboBoxFreeSolo({ isMulti, options, value, onChange, onChangeV2, onInputChange, onFocus, onBlur, containerProps, disabled, menuIsOpen, placeholder, formatCreateLabel, maxOptions, ...rest }: {
4
+ [x: string]: any;
4
5
  isMulti?: boolean | undefined;
5
6
  options?: {} | undefined;
6
7
  value?: never[] | undefined;
@@ -1,5 +1,7 @@
1
1
  import { LayoutProps, SizingProps, PositionProps, SpaceProps } from '@xstyled/styled-components';
2
2
  import { MenuItemT } from '../props';
3
3
  export declare const StyledGlobalMenuItemWrapper: import("styled-components").StyledComponent<"li", import("styled-components").DefaultTheme, Pick<MenuItemT, "isActive" | "isSelected" | "isFocus"> & LayoutProps<import("@xstyled/system").Theme> & SizingProps<import("@xstyled/system").Theme> & PositionProps<import("@xstyled/system").Theme> & SpaceProps<import("@xstyled/system").Theme>, never>;
4
- export declare const StyledMenuItemWrapper: import("styled-components").StyledComponent<"li", import("styled-components").DefaultTheme, Pick<MenuItemT, "isActive" | "isSelected" | "isFocus"> & LayoutProps<import("@xstyled/system").Theme> & SizingProps<import("@xstyled/system").Theme> & PositionProps<import("@xstyled/system").Theme> & SpaceProps<import("@xstyled/system").Theme>, never>;
4
+ export declare const StyledMenuItemWrapper: import("styled-components").StyledComponent<"li", import("styled-components").DefaultTheme, Pick<MenuItemT, "isActive" | "isSelected" | "isFocus"> & LayoutProps<import("@xstyled/system").Theme> & SizingProps<import("@xstyled/system").Theme> & PositionProps<import("@xstyled/system").Theme> & SpaceProps<import("@xstyled/system").Theme> & {
5
+ disabled: boolean;
6
+ }, never>;
5
7
  export declare const StyledSubmenuItemWrapper: import("styled-components").StyledComponent<"li", import("styled-components").DefaultTheme, Pick<MenuItemT, "isActive" | "isSelected" | "isFocus"> & LayoutProps<import("@xstyled/system").Theme> & SizingProps<import("@xstyled/system").Theme> & PositionProps<import("@xstyled/system").Theme> & SpaceProps<import("@xstyled/system").Theme>, never>;
@@ -1,7 +1,2 @@
1
- import React from 'react';
2
- declare const _default: React.ForwardRefExoticComponent<{
3
- checked: any;
4
- } & {
5
- theme?: import("styled-components").DefaultTheme | undefined;
6
- }>;
1
+ declare const _default: any;
7
2
  export default _default;