@dspworkplace/ui 2.0.1 → 2.0.2
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/index.es.js +315 -196
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +315 -195
- package/dist/index.js.map +1 -1
- package/package.json +4 -2
package/dist/index.es.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import React, { forwardRef, useState, Fragment, useCallback, useEffect, useRef, Children } from 'react';
|
|
2
2
|
import styled, { keyframes } from 'styled-components';
|
|
3
|
+
import { createPortal } from 'react-dom';
|
|
3
4
|
import { supercomplete, useCombobox } from '@szhsin/react-autocomplete';
|
|
5
|
+
import { usePopper } from 'react-popper';
|
|
4
6
|
|
|
5
7
|
var defaultRadius = '4px';
|
|
6
8
|
var colors = {
|
|
@@ -4222,6 +4224,10 @@ var Text = styled.p(_templateObject4$2(), theme.colors.neutrals.gray, function (
|
|
|
4222
4224
|
return subtle && "\n color:".concat(theme.colors.neutrals.medium, ";\n ");
|
|
4223
4225
|
});
|
|
4224
4226
|
|
|
4227
|
+
function ownKeys$1(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
|
|
4228
|
+
|
|
4229
|
+
function _objectSpread$1(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$1(Object(source), true).forEach(function (key) { defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$1(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
4230
|
+
|
|
4225
4231
|
function _templateObject14() {
|
|
4226
4232
|
var data = taggedTemplateLiteral(["\n border: 0;\n padding-right: 8px;\n background: transparent;\n cursor: inherit;\n display: flex;\n align-items: center;\n height: 100%;\n"]);
|
|
4227
4233
|
|
|
@@ -4453,36 +4459,70 @@ var optionText = function optionText(node) {
|
|
|
4453
4459
|
if (typeof node === 'string' || typeof node === 'number') return node.toString();
|
|
4454
4460
|
if (Array.isArray(node)) return node.map(optionText).join('');
|
|
4455
4461
|
return node.props ? optionText(node.props.children) : '';
|
|
4456
|
-
};
|
|
4457
|
-
|
|
4458
|
-
var keepInViewport = function keepInViewport(node) {
|
|
4459
|
-
if (node && node.getBoundingClientRect().right > window.innerWidth) {
|
|
4460
|
-
node.style.left = 'unset';
|
|
4461
|
-
node.style.right = '0px';
|
|
4462
|
-
}
|
|
4463
|
-
}; // eslint-disable-next-line react/prop-types
|
|
4462
|
+
}; // rendered in document.body so overflow on any ancestor cannot clip it; popper flips and shifts it to stay in the viewport
|
|
4463
|
+
// eslint-disable-next-line react/prop-types
|
|
4464
4464
|
|
|
4465
4465
|
|
|
4466
|
-
var
|
|
4467
|
-
var
|
|
4468
|
-
selectedOpt = _ref3.selectedOpt,
|
|
4469
|
-
setSelected = _ref3.setSelected,
|
|
4470
|
-
onChange = _ref3.onChange,
|
|
4471
|
-
onSelect = _ref3.onSelect,
|
|
4472
|
-
placeholder = _ref3.placeholder,
|
|
4473
|
-
error = _ref3.error,
|
|
4474
|
-
valid = _ref3.valid,
|
|
4475
|
-
noOptions = _ref3.noOptions,
|
|
4476
|
-
visibleOptionsQty = _ref3.visibleOptionsQty,
|
|
4466
|
+
var FloatingOptions = /*#__PURE__*/forwardRef(function (_ref3, ref) {
|
|
4467
|
+
var anchor = _ref3.anchor,
|
|
4477
4468
|
openTo = _ref3.openTo,
|
|
4478
|
-
|
|
4479
|
-
|
|
4480
|
-
props = objectWithoutProperties(_ref3, ["options", "selectedOpt", "setSelected", "onChange", "onSelect", "placeholder", "error", "valid", "noOptions", "visibleOptionsQty", "openTo", "startOpen", "resetCallback"]);
|
|
4469
|
+
style = _ref3.style,
|
|
4470
|
+
props = objectWithoutProperties(_ref3, ["anchor", "openTo", "style"]);
|
|
4481
4471
|
|
|
4482
|
-
var _useState = useState(),
|
|
4472
|
+
var _useState = useState(null),
|
|
4483
4473
|
_useState2 = slicedToArray(_useState, 2),
|
|
4484
|
-
|
|
4485
|
-
|
|
4474
|
+
list = _useState2[0],
|
|
4475
|
+
setList = _useState2[1];
|
|
4476
|
+
|
|
4477
|
+
var listRef = useCallback(mergeRefs([setList, ref]), [ref]);
|
|
4478
|
+
|
|
4479
|
+
var _usePopper = usePopper(anchor, list, {
|
|
4480
|
+
strategy: 'fixed',
|
|
4481
|
+
placement: openTo === 'top' ? 'top-start' : 'bottom-start',
|
|
4482
|
+
modifiers: [{
|
|
4483
|
+
name: 'offset',
|
|
4484
|
+
options: {
|
|
4485
|
+
offset: [0, 4]
|
|
4486
|
+
}
|
|
4487
|
+
}]
|
|
4488
|
+
}),
|
|
4489
|
+
styles = _usePopper.styles,
|
|
4490
|
+
attributes = _usePopper.attributes;
|
|
4491
|
+
|
|
4492
|
+
return /*#__PURE__*/createPortal( /*#__PURE__*/React.createElement(Options$1, _extends_1({
|
|
4493
|
+
ref: listRef,
|
|
4494
|
+
style: _objectSpread$1(_objectSpread$1(_objectSpread$1({}, style), styles.popper), {}, {
|
|
4495
|
+
margin: 0,
|
|
4496
|
+
zIndex: 1000000
|
|
4497
|
+
})
|
|
4498
|
+
}, attributes.popper, props)), document.body);
|
|
4499
|
+
}); // eslint-disable-next-line react/prop-types
|
|
4500
|
+
|
|
4501
|
+
var AutocompleteSelect = function AutocompleteSelect(_ref4) {
|
|
4502
|
+
var options = _ref4.options,
|
|
4503
|
+
selectedOpt = _ref4.selectedOpt,
|
|
4504
|
+
setSelected = _ref4.setSelected,
|
|
4505
|
+
onChange = _ref4.onChange,
|
|
4506
|
+
onSelect = _ref4.onSelect,
|
|
4507
|
+
placeholder = _ref4.placeholder,
|
|
4508
|
+
error = _ref4.error,
|
|
4509
|
+
valid = _ref4.valid,
|
|
4510
|
+
noOptions = _ref4.noOptions,
|
|
4511
|
+
visibleOptionsQty = _ref4.visibleOptionsQty,
|
|
4512
|
+
openTo = _ref4.openTo,
|
|
4513
|
+
startOpen = _ref4.startOpen,
|
|
4514
|
+
resetCallback = _ref4.resetCallback,
|
|
4515
|
+
props = objectWithoutProperties(_ref4, ["options", "selectedOpt", "setSelected", "onChange", "onSelect", "placeholder", "error", "valid", "noOptions", "visibleOptionsQty", "openTo", "startOpen", "resetCallback"]);
|
|
4516
|
+
|
|
4517
|
+
var _useState3 = useState(),
|
|
4518
|
+
_useState4 = slicedToArray(_useState3, 2),
|
|
4519
|
+
search = _useState4[0],
|
|
4520
|
+
setSearch = _useState4[1];
|
|
4521
|
+
|
|
4522
|
+
var _useState5 = useState(null),
|
|
4523
|
+
_useState6 = slicedToArray(_useState5, 2),
|
|
4524
|
+
anchor = _useState6[0],
|
|
4525
|
+
setAnchor = _useState6[1];
|
|
4486
4526
|
|
|
4487
4527
|
var rows = flattenOptions(options);
|
|
4488
4528
|
var selectable = rows.filter(function (row) {
|
|
@@ -4525,8 +4565,8 @@ var AutocompleteSelect = function AutocompleteSelect(_ref3) {
|
|
|
4525
4565
|
},
|
|
4526
4566
|
disabled: props.disabled,
|
|
4527
4567
|
feature: supercomplete({
|
|
4528
|
-
onRequestItem: function onRequestItem(
|
|
4529
|
-
var value =
|
|
4568
|
+
onRequestItem: function onRequestItem(_ref5, res) {
|
|
4569
|
+
var value = _ref5.value;
|
|
4530
4570
|
var matches = filterItems(value);
|
|
4531
4571
|
if (matches.length > 0) res({
|
|
4532
4572
|
index: 0,
|
|
@@ -4550,6 +4590,7 @@ var AutocompleteSelect = function AutocompleteSelect(_ref3) {
|
|
|
4550
4590
|
}, []);
|
|
4551
4591
|
var index = -1;
|
|
4552
4592
|
return /*#__PURE__*/React.createElement(SelectUi$1, _extends_1({
|
|
4593
|
+
ref: setAnchor,
|
|
4553
4594
|
className: [open && 'open', error && 'error', valid && 'valid'].filter(Boolean).join(' ')
|
|
4554
4595
|
}, props, {
|
|
4555
4596
|
title: selectedText
|
|
@@ -4562,10 +4603,10 @@ var AutocompleteSelect = function AutocompleteSelect(_ref3) {
|
|
|
4562
4603
|
}) : /*#__PURE__*/React.createElement(Icons.ArrowDown, {
|
|
4563
4604
|
size: "15px",
|
|
4564
4605
|
color: theme.colors.info.border
|
|
4565
|
-
})), open && /*#__PURE__*/React.createElement(
|
|
4606
|
+
})), open && /*#__PURE__*/React.createElement(FloatingOptions, _extends_1({
|
|
4607
|
+
anchor: anchor,
|
|
4566
4608
|
visibleOptionsQty: visibleOptionsQty,
|
|
4567
|
-
openTo: openTo
|
|
4568
|
-
ref: keepInViewport
|
|
4609
|
+
openTo: openTo
|
|
4569
4610
|
}, getListProps()), items.length === 0 && /*#__PURE__*/React.createElement("li", {
|
|
4570
4611
|
style: {
|
|
4571
4612
|
paddingRight: '8px'
|
|
@@ -4575,9 +4616,9 @@ var AutocompleteSelect = function AutocompleteSelect(_ref3) {
|
|
|
4575
4616
|
item: item,
|
|
4576
4617
|
depth: 0
|
|
4577
4618
|
};
|
|
4578
|
-
}) : rows).map(function (
|
|
4579
|
-
var item =
|
|
4580
|
-
depth =
|
|
4619
|
+
}) : rows).map(function (_ref6, key) {
|
|
4620
|
+
var item = _ref6.item,
|
|
4621
|
+
depth = _ref6.depth;
|
|
4581
4622
|
|
|
4582
4623
|
if (!isOption(item)) {
|
|
4583
4624
|
return /*#__PURE__*/React.createElement(OptionGroup$1, {
|
|
@@ -4615,33 +4656,42 @@ var summarizeSelection = function summarizeSelection(names) {
|
|
|
4615
4656
|
}; // eslint-disable-next-line react/prop-types
|
|
4616
4657
|
|
|
4617
4658
|
|
|
4618
|
-
var MultiAutocompleteSelect = function MultiAutocompleteSelect(
|
|
4619
|
-
var options =
|
|
4620
|
-
selectedValues =
|
|
4621
|
-
onToggle =
|
|
4622
|
-
placeholder =
|
|
4623
|
-
error =
|
|
4624
|
-
valid =
|
|
4625
|
-
noOptions =
|
|
4626
|
-
visibleOptionsQty =
|
|
4627
|
-
openTo =
|
|
4628
|
-
startOpen =
|
|
4629
|
-
props = objectWithoutProperties(
|
|
4659
|
+
var MultiAutocompleteSelect = function MultiAutocompleteSelect(_ref7) {
|
|
4660
|
+
var options = _ref7.options,
|
|
4661
|
+
selectedValues = _ref7.selectedValues,
|
|
4662
|
+
onToggle = _ref7.onToggle,
|
|
4663
|
+
placeholder = _ref7.placeholder,
|
|
4664
|
+
error = _ref7.error,
|
|
4665
|
+
valid = _ref7.valid,
|
|
4666
|
+
noOptions = _ref7.noOptions,
|
|
4667
|
+
visibleOptionsQty = _ref7.visibleOptionsQty,
|
|
4668
|
+
openTo = _ref7.openTo,
|
|
4669
|
+
startOpen = _ref7.startOpen,
|
|
4670
|
+
props = objectWithoutProperties(_ref7, ["options", "selectedValues", "onToggle", "placeholder", "error", "valid", "noOptions", "visibleOptionsQty", "openTo", "startOpen"]);
|
|
4671
|
+
|
|
4672
|
+
var _useState7 = useState(''),
|
|
4673
|
+
_useState8 = slicedToArray(_useState7, 2),
|
|
4674
|
+
search = _useState8[0],
|
|
4675
|
+
setSearch = _useState8[1];
|
|
4630
4676
|
|
|
4631
|
-
var
|
|
4632
|
-
|
|
4633
|
-
|
|
4634
|
-
|
|
4677
|
+
var _useState9 = useState(startOpen),
|
|
4678
|
+
_useState10 = slicedToArray(_useState9, 2),
|
|
4679
|
+
open = _useState10[0],
|
|
4680
|
+
setOpen = _useState10[1];
|
|
4635
4681
|
|
|
4636
|
-
var
|
|
4637
|
-
|
|
4638
|
-
|
|
4639
|
-
|
|
4682
|
+
var _useState11 = useState(null),
|
|
4683
|
+
_useState12 = slicedToArray(_useState11, 2),
|
|
4684
|
+
anchor = _useState12[0],
|
|
4685
|
+
setAnchor = _useState12[1];
|
|
4640
4686
|
|
|
4641
4687
|
var nodeRef = useRef();
|
|
4688
|
+
var listRef = useRef();
|
|
4689
|
+
var setNode = useCallback(mergeRefs([nodeRef, setAnchor]), []);
|
|
4642
4690
|
useEffect(function () {
|
|
4643
4691
|
var closeOnOutsideClick = function closeOnOutsideClick(e) {
|
|
4644
|
-
|
|
4692
|
+
var inList = listRef.current && listRef.current.contains(e.target);
|
|
4693
|
+
|
|
4694
|
+
if (nodeRef.current && !nodeRef.current.contains(e.target) && !inList) {
|
|
4645
4695
|
setOpen(false);
|
|
4646
4696
|
setSearch('');
|
|
4647
4697
|
}
|
|
@@ -4667,7 +4717,7 @@ var MultiAutocompleteSelect = function MultiAutocompleteSelect(_ref6) {
|
|
|
4667
4717
|
return optionText(item.name);
|
|
4668
4718
|
}));
|
|
4669
4719
|
return /*#__PURE__*/React.createElement(SelectUi$1, _extends_1({
|
|
4670
|
-
ref:
|
|
4720
|
+
ref: setNode,
|
|
4671
4721
|
className: [open && 'open', error && 'error', valid && 'valid'].filter(Boolean).join(' ')
|
|
4672
4722
|
}, props, {
|
|
4673
4723
|
title: summary,
|
|
@@ -4702,10 +4752,11 @@ var MultiAutocompleteSelect = function MultiAutocompleteSelect(_ref6) {
|
|
|
4702
4752
|
}) : /*#__PURE__*/React.createElement(Icons.ArrowDown, {
|
|
4703
4753
|
size: "15px",
|
|
4704
4754
|
color: theme.colors.info.border
|
|
4705
|
-
})), open && /*#__PURE__*/React.createElement(
|
|
4755
|
+
})), open && /*#__PURE__*/React.createElement(FloatingOptions, {
|
|
4756
|
+
anchor: anchor,
|
|
4706
4757
|
visibleOptionsQty: visibleOptionsQty,
|
|
4707
4758
|
openTo: openTo,
|
|
4708
|
-
ref:
|
|
4759
|
+
ref: listRef
|
|
4709
4760
|
}, items.length === 0 && /*#__PURE__*/React.createElement("li", {
|
|
4710
4761
|
style: {
|
|
4711
4762
|
paddingRight: '8px'
|
|
@@ -4715,9 +4766,9 @@ var MultiAutocompleteSelect = function MultiAutocompleteSelect(_ref6) {
|
|
|
4715
4766
|
item: item,
|
|
4716
4767
|
depth: 0
|
|
4717
4768
|
};
|
|
4718
|
-
}) : rows).map(function (
|
|
4719
|
-
var item =
|
|
4720
|
-
depth =
|
|
4769
|
+
}) : rows).map(function (_ref8, key) {
|
|
4770
|
+
var item = _ref8.item,
|
|
4771
|
+
depth = _ref8.depth;
|
|
4721
4772
|
|
|
4722
4773
|
if (!isOption(item)) {
|
|
4723
4774
|
return /*#__PURE__*/React.createElement(OptionGroup$1, {
|
|
@@ -4752,27 +4803,27 @@ var MultiAutocompleteSelect = function MultiAutocompleteSelect(_ref6) {
|
|
|
4752
4803
|
})));
|
|
4753
4804
|
};
|
|
4754
4805
|
|
|
4755
|
-
var MultiDropdown = /*#__PURE__*/forwardRef(function (
|
|
4756
|
-
var name =
|
|
4757
|
-
label =
|
|
4758
|
-
help =
|
|
4759
|
-
error =
|
|
4760
|
-
valid =
|
|
4761
|
-
options =
|
|
4762
|
-
placeholder =
|
|
4763
|
-
onChange =
|
|
4764
|
-
defaultValue =
|
|
4765
|
-
visibleOptionsQty =
|
|
4766
|
-
openTo =
|
|
4767
|
-
|
|
4768
|
-
startOpen =
|
|
4769
|
-
resetCallback =
|
|
4770
|
-
props = objectWithoutProperties(
|
|
4771
|
-
|
|
4772
|
-
var
|
|
4773
|
-
|
|
4774
|
-
selectedValues =
|
|
4775
|
-
setSelectedValues =
|
|
4806
|
+
var MultiDropdown = /*#__PURE__*/forwardRef(function (_ref9, ref) {
|
|
4807
|
+
var name = _ref9.name,
|
|
4808
|
+
label = _ref9.label,
|
|
4809
|
+
help = _ref9.help,
|
|
4810
|
+
error = _ref9.error,
|
|
4811
|
+
valid = _ref9.valid,
|
|
4812
|
+
options = _ref9.options,
|
|
4813
|
+
placeholder = _ref9.placeholder,
|
|
4814
|
+
onChange = _ref9.onChange,
|
|
4815
|
+
defaultValue = _ref9.defaultValue,
|
|
4816
|
+
visibleOptionsQty = _ref9.visibleOptionsQty,
|
|
4817
|
+
openTo = _ref9.openTo,
|
|
4818
|
+
_ref9$startOpen = _ref9.startOpen,
|
|
4819
|
+
startOpen = _ref9$startOpen === void 0 ? false : _ref9$startOpen,
|
|
4820
|
+
resetCallback = _ref9.resetCallback,
|
|
4821
|
+
props = objectWithoutProperties(_ref9, ["name", "label", "help", "error", "valid", "options", "placeholder", "onChange", "defaultValue", "visibleOptionsQty", "openTo", "startOpen", "resetCallback"]);
|
|
4822
|
+
|
|
4823
|
+
var _useState13 = useState([]),
|
|
4824
|
+
_useState14 = slicedToArray(_useState13, 2),
|
|
4825
|
+
selectedValues = _useState14[0],
|
|
4826
|
+
setSelectedValues = _useState14[1];
|
|
4776
4827
|
|
|
4777
4828
|
var valueRef = useRef();
|
|
4778
4829
|
var selectable = flattenOptions(options).filter(function (row) {
|
|
@@ -4859,31 +4910,31 @@ var MultiDropdown = /*#__PURE__*/forwardRef(function (_ref8, ref) {
|
|
|
4859
4910
|
}, optionText(item.name));
|
|
4860
4911
|
})));
|
|
4861
4912
|
});
|
|
4862
|
-
var SingleDropdown = /*#__PURE__*/forwardRef(function (
|
|
4863
|
-
var name =
|
|
4864
|
-
label =
|
|
4865
|
-
help =
|
|
4866
|
-
error =
|
|
4867
|
-
valid =
|
|
4868
|
-
options =
|
|
4869
|
-
placeholder =
|
|
4870
|
-
onChange =
|
|
4871
|
-
defaultValue =
|
|
4872
|
-
visibleOptionsQty =
|
|
4873
|
-
openTo =
|
|
4874
|
-
|
|
4875
|
-
startOpen =
|
|
4876
|
-
props = objectWithoutProperties(
|
|
4913
|
+
var SingleDropdown = /*#__PURE__*/forwardRef(function (_ref10, ref) {
|
|
4914
|
+
var name = _ref10.name,
|
|
4915
|
+
label = _ref10.label,
|
|
4916
|
+
help = _ref10.help,
|
|
4917
|
+
error = _ref10.error,
|
|
4918
|
+
valid = _ref10.valid,
|
|
4919
|
+
options = _ref10.options,
|
|
4920
|
+
placeholder = _ref10.placeholder,
|
|
4921
|
+
onChange = _ref10.onChange,
|
|
4922
|
+
defaultValue = _ref10.defaultValue,
|
|
4923
|
+
visibleOptionsQty = _ref10.visibleOptionsQty,
|
|
4924
|
+
openTo = _ref10.openTo,
|
|
4925
|
+
_ref10$startOpen = _ref10.startOpen,
|
|
4926
|
+
startOpen = _ref10$startOpen === void 0 ? false : _ref10$startOpen,
|
|
4927
|
+
props = objectWithoutProperties(_ref10, ["name", "label", "help", "error", "valid", "options", "placeholder", "onChange", "defaultValue", "visibleOptionsQty", "openTo", "startOpen"]);
|
|
4877
4928
|
|
|
4878
4929
|
var defaultSelected = {
|
|
4879
4930
|
value: '',
|
|
4880
4931
|
desc: ''
|
|
4881
4932
|
};
|
|
4882
4933
|
|
|
4883
|
-
var
|
|
4884
|
-
|
|
4885
|
-
selectedOpt =
|
|
4886
|
-
setSelected =
|
|
4934
|
+
var _useState15 = useState(defaultSelected),
|
|
4935
|
+
_useState16 = slicedToArray(_useState15, 2),
|
|
4936
|
+
selectedOpt = _useState16[0],
|
|
4937
|
+
setSelected = _useState16[1];
|
|
4887
4938
|
|
|
4888
4939
|
var valueRef = useRef();
|
|
4889
4940
|
|
|
@@ -4965,9 +5016,9 @@ var SingleDropdown = /*#__PURE__*/forwardRef(function (_ref9, ref) {
|
|
|
4965
5016
|
disabled: props.disabled
|
|
4966
5017
|
}));
|
|
4967
5018
|
});
|
|
4968
|
-
var Dropdown = /*#__PURE__*/forwardRef(function (
|
|
4969
|
-
var multiple =
|
|
4970
|
-
props = objectWithoutProperties(
|
|
5019
|
+
var Dropdown = /*#__PURE__*/forwardRef(function (_ref11, ref) {
|
|
5020
|
+
var multiple = _ref11.multiple,
|
|
5021
|
+
props = objectWithoutProperties(_ref11, ["multiple"]);
|
|
4971
5022
|
|
|
4972
5023
|
return multiple ? /*#__PURE__*/React.createElement(MultiDropdown, _extends_1({
|
|
4973
5024
|
ref: ref
|
|
@@ -4976,17 +5027,17 @@ var Dropdown = /*#__PURE__*/forwardRef(function (_ref10, ref) {
|
|
|
4976
5027
|
}, props));
|
|
4977
5028
|
}); // eslint-disable-next-line react/prop-types
|
|
4978
5029
|
|
|
4979
|
-
var BoxOptions = function BoxOptions(
|
|
4980
|
-
var options =
|
|
4981
|
-
isChild =
|
|
4982
|
-
setSelected =
|
|
4983
|
-
onChange =
|
|
4984
|
-
noOptions =
|
|
4985
|
-
selectedOpt =
|
|
4986
|
-
setOpen =
|
|
4987
|
-
onSelect =
|
|
4988
|
-
visibleOptionsQty =
|
|
4989
|
-
openTo =
|
|
5030
|
+
var BoxOptions = function BoxOptions(_ref12) {
|
|
5031
|
+
var options = _ref12.options,
|
|
5032
|
+
isChild = _ref12.isChild,
|
|
5033
|
+
setSelected = _ref12.setSelected,
|
|
5034
|
+
onChange = _ref12.onChange,
|
|
5035
|
+
noOptions = _ref12.noOptions,
|
|
5036
|
+
selectedOpt = _ref12.selectedOpt,
|
|
5037
|
+
setOpen = _ref12.setOpen,
|
|
5038
|
+
onSelect = _ref12.onSelect,
|
|
5039
|
+
visibleOptionsQty = _ref12.visibleOptionsQty,
|
|
5040
|
+
openTo = _ref12.openTo;
|
|
4990
5041
|
|
|
4991
5042
|
if (!options) {
|
|
4992
5043
|
return /*#__PURE__*/React.createElement(Options$1, null, /*#__PURE__*/React.createElement("li", {
|
|
@@ -5058,32 +5109,32 @@ var BoxOptions = function BoxOptions(_ref11) {
|
|
|
5058
5109
|
})) : /*#__PURE__*/React.createElement(OptionGroup$1, null, item.name));
|
|
5059
5110
|
}));
|
|
5060
5111
|
};
|
|
5061
|
-
var CustomDropdown = /*#__PURE__*/forwardRef(function (
|
|
5062
|
-
var name =
|
|
5063
|
-
label =
|
|
5064
|
-
help =
|
|
5065
|
-
error =
|
|
5066
|
-
valid =
|
|
5067
|
-
options =
|
|
5068
|
-
placeholder =
|
|
5069
|
-
defaultValue =
|
|
5070
|
-
multiple =
|
|
5071
|
-
type =
|
|
5072
|
-
tooltip =
|
|
5073
|
-
onChange =
|
|
5074
|
-
visibleOptionsQty =
|
|
5075
|
-
openTo =
|
|
5076
|
-
props = objectWithoutProperties(
|
|
5112
|
+
var CustomDropdown = /*#__PURE__*/forwardRef(function (_ref13, ref) {
|
|
5113
|
+
var name = _ref13.name,
|
|
5114
|
+
label = _ref13.label,
|
|
5115
|
+
help = _ref13.help,
|
|
5116
|
+
error = _ref13.error,
|
|
5117
|
+
valid = _ref13.valid,
|
|
5118
|
+
options = _ref13.options,
|
|
5119
|
+
placeholder = _ref13.placeholder,
|
|
5120
|
+
defaultValue = _ref13.defaultValue,
|
|
5121
|
+
multiple = _ref13.multiple,
|
|
5122
|
+
type = _ref13.type,
|
|
5123
|
+
tooltip = _ref13.tooltip,
|
|
5124
|
+
onChange = _ref13.onChange,
|
|
5125
|
+
visibleOptionsQty = _ref13.visibleOptionsQty,
|
|
5126
|
+
openTo = _ref13.openTo,
|
|
5127
|
+
props = objectWithoutProperties(_ref13, ["name", "label", "help", "error", "valid", "options", "placeholder", "defaultValue", "multiple", "type", "tooltip", "onChange", "visibleOptionsQty", "openTo"]);
|
|
5077
5128
|
|
|
5078
|
-
var
|
|
5079
|
-
|
|
5080
|
-
open =
|
|
5081
|
-
setOpen =
|
|
5129
|
+
var _useState17 = useState(false),
|
|
5130
|
+
_useState18 = slicedToArray(_useState17, 2),
|
|
5131
|
+
open = _useState18[0],
|
|
5132
|
+
setOpen = _useState18[1];
|
|
5082
5133
|
|
|
5083
|
-
var
|
|
5084
|
-
|
|
5085
|
-
selectedOpt =
|
|
5086
|
-
setSelected =
|
|
5134
|
+
var _useState19 = useState([]),
|
|
5135
|
+
_useState20 = slicedToArray(_useState19, 2),
|
|
5136
|
+
selectedOpt = _useState20[0],
|
|
5137
|
+
setSelected = _useState20[1];
|
|
5087
5138
|
|
|
5088
5139
|
var nodeSelect = useRef();
|
|
5089
5140
|
var valueRef = useRef();
|
|
@@ -5309,16 +5360,16 @@ var HandleState = function HandleState(index, setSelected, selectedOpt, multiple
|
|
|
5309
5360
|
setSelected(ret);
|
|
5310
5361
|
};
|
|
5311
5362
|
|
|
5312
|
-
var SelectOption = function SelectOption(
|
|
5313
|
-
var options =
|
|
5314
|
-
setSelected =
|
|
5315
|
-
selectedOpt =
|
|
5316
|
-
multiple =
|
|
5317
|
-
type =
|
|
5318
|
-
onChange =
|
|
5319
|
-
noOptions =
|
|
5320
|
-
visibleOptionsQty =
|
|
5321
|
-
openTo =
|
|
5363
|
+
var SelectOption = function SelectOption(_ref14) {
|
|
5364
|
+
var options = _ref14.options,
|
|
5365
|
+
setSelected = _ref14.setSelected,
|
|
5366
|
+
selectedOpt = _ref14.selectedOpt,
|
|
5367
|
+
multiple = _ref14.multiple,
|
|
5368
|
+
type = _ref14.type,
|
|
5369
|
+
onChange = _ref14.onChange,
|
|
5370
|
+
noOptions = _ref14.noOptions,
|
|
5371
|
+
visibleOptionsQty = _ref14.visibleOptionsQty,
|
|
5372
|
+
openTo = _ref14.openTo;
|
|
5322
5373
|
|
|
5323
5374
|
if (!options) {
|
|
5324
5375
|
return /*#__PURE__*/React.createElement(OptionsPeople, null, /*#__PURE__*/React.createElement("li", null, noOptions || 'No data found'));
|
|
@@ -5353,9 +5404,9 @@ var SelectOption = function SelectOption(_ref13) {
|
|
|
5353
5404
|
}));
|
|
5354
5405
|
};
|
|
5355
5406
|
|
|
5356
|
-
var PhotoComponent = function PhotoComponent(
|
|
5357
|
-
var profile =
|
|
5358
|
-
index =
|
|
5407
|
+
var PhotoComponent = function PhotoComponent(_ref15) {
|
|
5408
|
+
var profile = _ref15.profile,
|
|
5409
|
+
index = _ref15.index;
|
|
5359
5410
|
var customStyle = {
|
|
5360
5411
|
position: 'relative',
|
|
5361
5412
|
display: 'inline-flex',
|
|
@@ -5379,11 +5430,11 @@ var PhotoComponent = function PhotoComponent(_ref14) {
|
|
|
5379
5430
|
}));
|
|
5380
5431
|
};
|
|
5381
5432
|
|
|
5382
|
-
var SelectValueRender = function SelectValueRender(
|
|
5383
|
-
var options =
|
|
5384
|
-
selectedOpt =
|
|
5385
|
-
type =
|
|
5386
|
-
noOptions =
|
|
5433
|
+
var SelectValueRender = function SelectValueRender(_ref16) {
|
|
5434
|
+
var options = _ref16.options,
|
|
5435
|
+
selectedOpt = _ref16.selectedOpt,
|
|
5436
|
+
type = _ref16.type,
|
|
5437
|
+
noOptions = _ref16.noOptions;
|
|
5387
5438
|
|
|
5388
5439
|
if (!options) {
|
|
5389
5440
|
return /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
@@ -5819,9 +5870,77 @@ var Password = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
5819
5870
|
})));
|
|
5820
5871
|
});
|
|
5821
5872
|
|
|
5822
|
-
function
|
|
5873
|
+
function _templateObject$9() {
|
|
5874
|
+
var data = taggedTemplateLiteral(["\n display: block;\n height: auto;\n min-height: 80px;\n resize: vertical;\n font-family: inherit;\n"]);
|
|
5823
5875
|
|
|
5824
|
-
|
|
5876
|
+
_templateObject$9 = function _templateObject() {
|
|
5877
|
+
return data;
|
|
5878
|
+
};
|
|
5879
|
+
|
|
5880
|
+
return data;
|
|
5881
|
+
}
|
|
5882
|
+
var TextAreaBase = styled(InputBase$1).attrs({
|
|
5883
|
+
as: 'textarea'
|
|
5884
|
+
})(_templateObject$9());
|
|
5885
|
+
var Textarea = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
5886
|
+
var name = _ref.name,
|
|
5887
|
+
label = _ref.label,
|
|
5888
|
+
help = _ref.help,
|
|
5889
|
+
invalid = _ref.invalid,
|
|
5890
|
+
valid = _ref.valid,
|
|
5891
|
+
error = _ref.error,
|
|
5892
|
+
_ref$rows = _ref.rows,
|
|
5893
|
+
rows = _ref$rows === void 0 ? 4 : _ref$rows,
|
|
5894
|
+
props = objectWithoutProperties(_ref, ["name", "label", "help", "invalid", "valid", "error", "rows"]);
|
|
5895
|
+
|
|
5896
|
+
var validationType = null;
|
|
5897
|
+
var useIcon = false;
|
|
5898
|
+
|
|
5899
|
+
if (invalid) {
|
|
5900
|
+
useIcon = /*#__PURE__*/React.createElement("span", {
|
|
5901
|
+
className: "requiredField"
|
|
5902
|
+
}, "*");
|
|
5903
|
+
validationType = 'error';
|
|
5904
|
+
}
|
|
5905
|
+
|
|
5906
|
+
if (props.Required) useIcon = /*#__PURE__*/React.createElement(RequiredText, null);
|
|
5907
|
+
|
|
5908
|
+
if (error) {
|
|
5909
|
+
validationType = 'error';
|
|
5910
|
+
}
|
|
5911
|
+
|
|
5912
|
+
if (valid) {
|
|
5913
|
+
useIcon = /*#__PURE__*/React.createElement("img", {
|
|
5914
|
+
src: Check
|
|
5915
|
+
});
|
|
5916
|
+
validationType = 'valid';
|
|
5917
|
+
}
|
|
5918
|
+
|
|
5919
|
+
return /*#__PURE__*/React.createElement(Frag$1, {
|
|
5920
|
+
size: props.size,
|
|
5921
|
+
className: "formAligner"
|
|
5922
|
+
}, label && !useIcon && /*#__PURE__*/React.createElement(Label, {
|
|
5923
|
+
htmlFor: name
|
|
5924
|
+
}, label), label && useIcon && /*#__PURE__*/React.createElement(Label, {
|
|
5925
|
+
htmlFor: name
|
|
5926
|
+
}, label, " ", useIcon), /*#__PURE__*/React.createElement(TextAreaBase, _extends_1({
|
|
5927
|
+
name: name,
|
|
5928
|
+
id: name,
|
|
5929
|
+
rows: rows
|
|
5930
|
+
}, props, {
|
|
5931
|
+
validation: validationType,
|
|
5932
|
+
ref: ref
|
|
5933
|
+
})), help && /*#__PURE__*/React.createElement(Span, null, help), error && /*#__PURE__*/React.createElement(SpanError$1, null, /*#__PURE__*/React.createElement("img", {
|
|
5934
|
+
src: Ex,
|
|
5935
|
+
style: {
|
|
5936
|
+
marginRight: '6px'
|
|
5937
|
+
}
|
|
5938
|
+
}), " ", error));
|
|
5939
|
+
});
|
|
5940
|
+
|
|
5941
|
+
function ownKeys$2(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
|
|
5942
|
+
|
|
5943
|
+
function _objectSpread$2(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$2(Object(source), true).forEach(function (key) { defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$2(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
5825
5944
|
|
|
5826
5945
|
function _templateObject7$3() {
|
|
5827
5946
|
var data = taggedTemplateLiteral(["\n position: absolute;\n height: 1px;\n width: 1px;\n z-index: -1;\n opacity: 0;\n"]);
|
|
@@ -5883,16 +6002,16 @@ function _templateObject2$5() {
|
|
|
5883
6002
|
return data;
|
|
5884
6003
|
}
|
|
5885
6004
|
|
|
5886
|
-
function _templateObject$
|
|
6005
|
+
function _templateObject$a() {
|
|
5887
6006
|
var data = taggedTemplateLiteral(["\n display:inline-block;\n vertical-align: top;\n"]);
|
|
5888
6007
|
|
|
5889
|
-
_templateObject$
|
|
6008
|
+
_templateObject$a = function _templateObject() {
|
|
5890
6009
|
return data;
|
|
5891
6010
|
};
|
|
5892
6011
|
|
|
5893
6012
|
return data;
|
|
5894
6013
|
}
|
|
5895
|
-
var Frag$3 = styled.div(_templateObject$
|
|
6014
|
+
var Frag$3 = styled.div(_templateObject$a());
|
|
5896
6015
|
var Span$3 = styled.span(_templateObject2$5(), theme.font.extraSmall.size);
|
|
5897
6016
|
var SpanError$4 = styled(Span$3)(_templateObject3$5(), theme.colors.error.text);
|
|
5898
6017
|
var Select = styled(InputBase)(_templateObject4$5(), theme.colors.neutrals.white, theme.colors.action, theme.colors.secondary, theme.colors.error.border);
|
|
@@ -6088,7 +6207,7 @@ var Tag = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
6088
6207
|
};
|
|
6089
6208
|
|
|
6090
6209
|
var addNewOption = function addNewOption(newObj) {
|
|
6091
|
-
newObj = _objectSpread$
|
|
6210
|
+
newObj = _objectSpread$2(_objectSpread$2({}, newObj), {}, {
|
|
6092
6211
|
value: newObj.name,
|
|
6093
6212
|
"new": true
|
|
6094
6213
|
});
|
|
@@ -6362,16 +6481,16 @@ function _templateObject2$6() {
|
|
|
6362
6481
|
return data;
|
|
6363
6482
|
}
|
|
6364
6483
|
|
|
6365
|
-
function _templateObject$
|
|
6484
|
+
function _templateObject$b() {
|
|
6366
6485
|
var data = taggedTemplateLiteral(["\n display:inline-block;\n vertical-align: top;\n"]);
|
|
6367
6486
|
|
|
6368
|
-
_templateObject$
|
|
6487
|
+
_templateObject$b = function _templateObject() {
|
|
6369
6488
|
return data;
|
|
6370
6489
|
};
|
|
6371
6490
|
|
|
6372
6491
|
return data;
|
|
6373
6492
|
}
|
|
6374
|
-
var Frag$4 = styled.div(_templateObject$
|
|
6493
|
+
var Frag$4 = styled.div(_templateObject$b());
|
|
6375
6494
|
var Field = styled.div(_templateObject2$6());
|
|
6376
6495
|
var WraperBucket = styled.div(_templateObject3$6(), function (props) {
|
|
6377
6496
|
return props.background ? props.background : theme.colors.info.shadow;
|
|
@@ -7255,10 +7374,10 @@ function _templateObject2$7() {
|
|
|
7255
7374
|
return data;
|
|
7256
7375
|
}
|
|
7257
7376
|
|
|
7258
|
-
function _templateObject$
|
|
7377
|
+
function _templateObject$c() {
|
|
7259
7378
|
var data = taggedTemplateLiteral(["\n font-family: ", ";\n font-weight:bold;\n border-radius:", ";\n cursor:pointer;\n display:inline-flex;\n background:", "\n color:", "\n height:40px;\n line-height:40px;\n padding:0 16px;\n font-size: ", ";\n align-items: center;\n gap: 4px;\n white-space: nowrap;\n justify-content: center;\n text-align: center;\n\n > * {\n border-color: ", ";\n }\n\n svg path {\n fill: currentColor;\n }\n\n &:hover,\n &.hover {\n background:", ";\n }\n\n &:focus,\n &.focus {\n background:", ";\n box-shadow:", ";\n }\n\n &:active,\n &.active {\n background:", ";\n box-shadow:", ";\n }\n\n &.selected {\n outline: 1px solid ", ";\n position: relative;\n z-index: 1;\n }\n\n &[disabled] {\n opacity: .5;\n cursor: not-allowed;\n }\n"]);
|
|
7260
7379
|
|
|
7261
|
-
_templateObject$
|
|
7380
|
+
_templateObject$c = function _templateObject() {
|
|
7262
7381
|
return data;
|
|
7263
7382
|
};
|
|
7264
7383
|
|
|
@@ -7269,7 +7388,7 @@ var defaultShadow = function defaultShadow(color) {
|
|
|
7269
7388
|
return "0px 0px 6px ".concat(color);
|
|
7270
7389
|
};
|
|
7271
7390
|
|
|
7272
|
-
var Base = styled.button(_templateObject$
|
|
7391
|
+
var Base = styled.button(_templateObject$c(), theme.font.main, theme.defaultRadius, theme.colors.info.bg, theme.colors.secondary, theme.font.medium.size, theme.colors.info.shadow, theme.colors.info.shadow, theme.colors.info.bg, defaultShadow(theme.form.button.secondary.bg), theme.colors.info.shadow, defaultShadow(theme.form.button.secondary.bg), theme.colors.secondary);
|
|
7273
7392
|
var Primary = "\n background:".concat(theme.form.button.primary.bg, ";\n color:").concat(theme.colors.neutrals.white, ";\n\n > * {\n border-color: ").concat(theme.colors.neutrals.white, ";\n }\n\n svg path {\n fill: ").concat(theme.colors.neutrals.white, ";\n }\n\n &:hover,\n &.hover {\n background:").concat(theme.form.button.primary.hover, "\n }\n\n &:focus,\n &.focus {\n background:").concat(theme.form.button.primary.bg, ";\n box-shadow:").concat(defaultShadow(theme.form.button.primary.bg), ";\n }\n\n &:active,\n &.active {\n background:").concat(theme.form.button.primary.hover, "\n box-shadow:").concat(defaultShadow(theme.form.button.primary.bg), ";\n }\n\n &.selected {\n border: 1px solid ").concat(theme.colors.neutrals.white, ";\n }\n");
|
|
7274
7393
|
var Secondary = "\n background:".concat(theme.form.button.secondary.bg, ";\n color:").concat(theme.colors.neutrals.white, ";\n\n > * {\n border-color: ").concat(theme.colors.neutrals.white, ";\n }\n\n svg path {\n fill: ").concat(theme.colors.neutrals.white, ";\n }\n\n &:hover {\n background:").concat(theme.form.button.secondary.hover, "\n }\n\n &:focus {\n background:").concat(theme.form.button.secondary.bg, ";\n box-shadow:").concat(defaultShadow(theme.form.button.secondary.bg), ";\n }\n\n &:active,\n &.active {\n background:").concat(theme.form.button.secondary.hover, "\n box-shadow:").concat(defaultShadow(theme.form.button.secondary.bg), ";\n }\n\n &.selected {\n border: 1px solid ").concat(theme.colors.neutrals.white, ";\n }\n");
|
|
7275
7394
|
var Cancel = "\n background:transparent;\n color:".concat(theme.form.button.secondary.bg, ";\n\n > * {\n border-color: ").concat(theme.colors.info.shadow, ";\n }\n\n svg path {\n fill: ").concat(theme.colors.secondary, ";\n }\n\n &:hover {\n background:transparent;\n text-decoration:underline;\n }\n\n &:focus {\n background:").concat(theme.colors.neutrals.white, ";\n box-shadow:").concat(defaultShadow(theme.form.button.secondary.bg), ";\n }\n\n &:active,\n &.active {\n background:").concat(theme.colors.neutrals.white, ";\n box-shadow:").concat(defaultShadow(theme.form.button.secondary.bg), ";\n text-decoration:underline;\n }\n\n &.selected {\n border: 1px solid ").concat(theme.form.button.secondary.bg, ";\n }\n");
|
|
@@ -7365,16 +7484,16 @@ function _templateObject2$8() {
|
|
|
7365
7484
|
return data;
|
|
7366
7485
|
}
|
|
7367
7486
|
|
|
7368
|
-
function _templateObject$
|
|
7487
|
+
function _templateObject$d() {
|
|
7369
7488
|
var data = taggedTemplateLiteral(["\n display:inline-block;\n vertical-align: top;\n"]);
|
|
7370
7489
|
|
|
7371
|
-
_templateObject$
|
|
7490
|
+
_templateObject$d = function _templateObject() {
|
|
7372
7491
|
return data;
|
|
7373
7492
|
};
|
|
7374
7493
|
|
|
7375
7494
|
return data;
|
|
7376
7495
|
}
|
|
7377
|
-
var Frag$5 = styled.div(_templateObject$
|
|
7496
|
+
var Frag$5 = styled.div(_templateObject$d());
|
|
7378
7497
|
var Wrapper$1 = styled.label(_templateObject2$8(), theme.colors.info.bg, theme.colors.secondary, theme.colors.action, theme.colors.secondary, theme.colors.success.border, theme.colors.success.border, theme.colors.error.border, theme.colors.error.border);
|
|
7379
7498
|
var Input$1 = styled(InputBase)(_templateObject3$7());
|
|
7380
7499
|
var Profile = styled.div(_templateObject4$7(), theme.colors.neutrals.silver);
|
|
@@ -7786,16 +7905,16 @@ function _templateObject2$9() {
|
|
|
7786
7905
|
return data;
|
|
7787
7906
|
}
|
|
7788
7907
|
|
|
7789
|
-
function _templateObject$
|
|
7908
|
+
function _templateObject$e() {
|
|
7790
7909
|
var data = taggedTemplateLiteral(["\n display:inline-block;\n vertical-align: top;\n"]);
|
|
7791
7910
|
|
|
7792
|
-
_templateObject$
|
|
7911
|
+
_templateObject$e = function _templateObject() {
|
|
7793
7912
|
return data;
|
|
7794
7913
|
};
|
|
7795
7914
|
|
|
7796
7915
|
return data;
|
|
7797
7916
|
}
|
|
7798
|
-
var Frag$6 = styled.div(_templateObject$
|
|
7917
|
+
var Frag$6 = styled.div(_templateObject$e());
|
|
7799
7918
|
var CheckBoxWrapper = styled.div(_templateObject2$9());
|
|
7800
7919
|
var CheckBoxLabel = styled.label(_templateObject3$8(), theme.colors.neutrals.white, theme.colors.info.border, theme.colors.action, theme.colors.secondary, theme.colors.info.border);
|
|
7801
7920
|
var CheckBox$1 = styled.input(_templateObject4$8(), CheckBoxLabel, theme.colors.info.text, theme.colors.info.border, theme.colors.neutrals.white);
|
|
@@ -7860,14 +7979,14 @@ var Toggle = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
7860
7979
|
}, singleText || (value ? textOn : textOff))), help && /*#__PURE__*/React.createElement(SpanHelp, null, help));
|
|
7861
7980
|
});
|
|
7862
7981
|
|
|
7863
|
-
function ownKeys$
|
|
7982
|
+
function ownKeys$3(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
|
|
7864
7983
|
|
|
7865
|
-
function _objectSpread$
|
|
7984
|
+
function _objectSpread$3(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$3(Object(source), true).forEach(function (key) { defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$3(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
7866
7985
|
|
|
7867
|
-
function _templateObject$
|
|
7986
|
+
function _templateObject$f() {
|
|
7868
7987
|
var data = taggedTemplateLiteral(["\n position: relative;\n\n ", " {\n left: 0;\n top: -21px;\n height: 192px;\n overflow: auto;\n\n li {\n padding-right: 8px;\n }\n }\n\n ", " {\n font-size: ", ";\n line-height: ", ";\n position: sticky;\n top: 0;\n z-index: 1;\n background: ", ";\n\n &:hover {\n background: ", ";\n }\n }\n"]);
|
|
7869
7988
|
|
|
7870
|
-
_templateObject$
|
|
7989
|
+
_templateObject$f = function _templateObject() {
|
|
7871
7990
|
return data;
|
|
7872
7991
|
};
|
|
7873
7992
|
|
|
@@ -8018,7 +8137,7 @@ var fromMilliseconds = function fromMilliseconds(milliseconds) {
|
|
|
8018
8137
|
};
|
|
8019
8138
|
};
|
|
8020
8139
|
|
|
8021
|
-
var TimePickerOptionsStyle = styled.div(_templateObject$
|
|
8140
|
+
var TimePickerOptionsStyle = styled.div(_templateObject$f(), Options, OptionGroup, theme.font.extraSmall.size, theme.font.extraSmall.lineHeight, theme.colors.neutrals.white, theme.colors.neutrals.white);
|
|
8022
8141
|
|
|
8023
8142
|
var TimePickerOptions = function TimePickerOptions(_ref5) {
|
|
8024
8143
|
var time = _ref5.time,
|
|
@@ -8057,7 +8176,7 @@ var TimePickerOptions = function TimePickerOptions(_ref5) {
|
|
|
8057
8176
|
}
|
|
8058
8177
|
|
|
8059
8178
|
var handleSelect = function handleSelect(what, value) {
|
|
8060
|
-
var newTime = _objectSpread$
|
|
8179
|
+
var newTime = _objectSpread$3({}, time);
|
|
8061
8180
|
|
|
8062
8181
|
newTime[what] = value;
|
|
8063
8182
|
setTime(newTime);
|
|
@@ -8270,10 +8389,10 @@ function _templateObject2$a() {
|
|
|
8270
8389
|
return data;
|
|
8271
8390
|
}
|
|
8272
8391
|
|
|
8273
|
-
function _templateObject$
|
|
8392
|
+
function _templateObject$g() {
|
|
8274
8393
|
var data = taggedTemplateLiteral(["\n display: inline-flex;\n align-items: stretch;\n padding: 0;\n\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n\n ", "\n"]);
|
|
8275
8394
|
|
|
8276
|
-
_templateObject$
|
|
8395
|
+
_templateObject$g = function _templateObject() {
|
|
8277
8396
|
return data;
|
|
8278
8397
|
};
|
|
8279
8398
|
|
|
@@ -8283,7 +8402,7 @@ var Container = styled(Base).attrs(function (props) {
|
|
|
8283
8402
|
return {
|
|
8284
8403
|
as: 'div'
|
|
8285
8404
|
};
|
|
8286
|
-
})(_templateObject$
|
|
8405
|
+
})(_templateObject$g(), function (props) {
|
|
8287
8406
|
return props.type === 'primary' && Primary;
|
|
8288
8407
|
}, function (props) {
|
|
8289
8408
|
return props.type === 'secondary' && Secondary;
|
|
@@ -8378,20 +8497,20 @@ var Dropdown$1 = function Dropdown$$1(_ref) {
|
|
|
8378
8497
|
})));
|
|
8379
8498
|
};
|
|
8380
8499
|
|
|
8381
|
-
function ownKeys$
|
|
8500
|
+
function ownKeys$4(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
|
|
8382
8501
|
|
|
8383
|
-
function _objectSpread$
|
|
8502
|
+
function _objectSpread$4(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$4(Object(source), true).forEach(function (key) { defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$4(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
8384
8503
|
|
|
8385
|
-
function _templateObject$
|
|
8504
|
+
function _templateObject$h() {
|
|
8386
8505
|
var data = taggedTemplateLiteral(["\n display: inline-flex;\n flex-wrap: nowrap;\n border: 1px solid ", ";\n border-radius: ", ";\n\n > *:not(.selected) {\n border-radius: 0;\n\n &:first-child {\n border-top-left-radius: ", ";\n border-bottom-left-radius: ", ";\n }\n\n &:last-child {\n border-top-right-radius: ", ";\n border-bottom-right-radius: ", ";\n }\n }\n"]);
|
|
8387
8506
|
|
|
8388
|
-
_templateObject$
|
|
8507
|
+
_templateObject$h = function _templateObject() {
|
|
8389
8508
|
return data;
|
|
8390
8509
|
};
|
|
8391
8510
|
|
|
8392
8511
|
return data;
|
|
8393
8512
|
}
|
|
8394
|
-
var BtnGroup = styled.div(_templateObject$
|
|
8513
|
+
var BtnGroup = styled.div(_templateObject$h(), theme.colors.neutrals.silver, theme.defaultRadius, theme.defaultRadius, theme.defaultRadius, theme.defaultRadius, theme.defaultRadius);
|
|
8395
8514
|
|
|
8396
8515
|
var ButtonGroup = function ButtonGroup(_ref) {
|
|
8397
8516
|
var children = _ref.children,
|
|
@@ -8409,7 +8528,7 @@ var ButtonGroup = function ButtonGroup(_ref) {
|
|
|
8409
8528
|
};
|
|
8410
8529
|
|
|
8411
8530
|
return /*#__PURE__*/React.createElement(BtnGroup, null, children.map(function (btn, k) {
|
|
8412
|
-
return btn.type(_objectSpread$
|
|
8531
|
+
return btn.type(_objectSpread$4(_objectSpread$4(_objectSpread$4({}, props), btn.props), {}, {
|
|
8413
8532
|
key: k,
|
|
8414
8533
|
className: generateClassName(btn.props)
|
|
8415
8534
|
}));
|
|
@@ -8446,16 +8565,16 @@ function _templateObject2$b() {
|
|
|
8446
8565
|
return data;
|
|
8447
8566
|
}
|
|
8448
8567
|
|
|
8449
|
-
function _templateObject$
|
|
8568
|
+
function _templateObject$i() {
|
|
8450
8569
|
var data = taggedTemplateLiteral(["\n 0% {\n opacity:0;\n visibility: hidden;\n transform: scale(0.6) translateY(-8px);\n }\n\n 100% {\n visibility: visible;\n opacity:1;\n }\n"]);
|
|
8451
8570
|
|
|
8452
|
-
_templateObject$
|
|
8571
|
+
_templateObject$i = function _templateObject() {
|
|
8453
8572
|
return data;
|
|
8454
8573
|
};
|
|
8455
8574
|
|
|
8456
8575
|
return data;
|
|
8457
8576
|
}
|
|
8458
|
-
var listAnimation = keyframes(_templateObject$
|
|
8577
|
+
var listAnimation = keyframes(_templateObject$i());
|
|
8459
8578
|
var POSITION_LIST = '100%';
|
|
8460
8579
|
var POSITION_LIST_DISTANCE = '10%';
|
|
8461
8580
|
|
|
@@ -8712,16 +8831,16 @@ function _templateObject2$c() {
|
|
|
8712
8831
|
return data;
|
|
8713
8832
|
}
|
|
8714
8833
|
|
|
8715
|
-
function _templateObject$
|
|
8834
|
+
function _templateObject$j() {
|
|
8716
8835
|
var data = taggedTemplateLiteral(["\n padding: 7px;\n border-radius: ", ";\n border-width:1px;\n border-style:solid;\n display:flex;\n align-items:center;\n position:relative;\n\n ", "\n\n svg {\n margin-right: 8px;\n display: block;\n }\n"]);
|
|
8717
8836
|
|
|
8718
|
-
_templateObject$
|
|
8837
|
+
_templateObject$j = function _templateObject() {
|
|
8719
8838
|
return data;
|
|
8720
8839
|
};
|
|
8721
8840
|
|
|
8722
8841
|
return data;
|
|
8723
8842
|
}
|
|
8724
|
-
var Div = styled.div(_templateObject$
|
|
8843
|
+
var Div = styled.div(_templateObject$j(), theme.defaultRadius, function (props) {
|
|
8725
8844
|
return props.useClose && "\n padding-right: 32px;\n ";
|
|
8726
8845
|
});
|
|
8727
8846
|
var Title$2 = styled.h5(_templateObject2$c(), theme.font.main, theme.font.medium.size, theme.font.big.lineHeight);
|
|
@@ -8816,5 +8935,5 @@ var index = {
|
|
|
8816
8935
|
Error: AlertError
|
|
8817
8936
|
};
|
|
8818
8937
|
|
|
8819
|
-
export { theme as Theme, ButtonIcon, Exported as Button, Dropdown$1 as ButtonDropdown, ButtonGroup, Form, Input, Password, CheckBox, RadioBox, Dropdown, CustomDropdown, Tag as TagInput, InputColor, Uploader, Toggle, TimePicker, DropUploader, Title, SubTitle, ThirdTitle, Text, index as Alert, Spacer, Icons as Icon, logo as Logo, dspwLoading as Loading };
|
|
8938
|
+
export { theme as Theme, ButtonIcon, Exported as Button, Dropdown$1 as ButtonDropdown, ButtonGroup, Form, Input, Textarea, Password, CheckBox, RadioBox, Dropdown, CustomDropdown, Tag as TagInput, InputColor, Uploader, Toggle, TimePicker, DropUploader, Title, SubTitle, ThirdTitle, Text, index as Alert, Spacer, Icons as Icon, logo as Logo, dspwLoading as Loading };
|
|
8820
8939
|
//# sourceMappingURL=index.es.js.map
|