@dartech/arsenal-ui 1.4.26 → 1.4.27

Sign up to get free protection for your applications and to get access to all the features.
package/index.js CHANGED
@@ -415,6 +415,18 @@ const ControlDebouncedInput = _a => {
415
415
  }));
416
416
  };
417
417
 
418
+ const PopupIconComponent$2 = () => {
419
+ return jsx(SvgIcon, Object.assign({
420
+ sx: {
421
+ mr: 2
422
+ }
423
+ }, {
424
+ children: jsx("path", {
425
+ d: "M4.22032 8.46991C4.36094 8.32946 4.55157 8.25057 4.75032 8.25057C4.94907 8.25057 5.13969 8.32946 5.28032 8.46991L12.0003 15.1899L18.7203 8.46991C18.789 8.39622 18.8718 8.33712 18.9638 8.29613C19.0558 8.25514 19.1551 8.23309 19.2558 8.23132C19.3565 8.22954 19.4565 8.24807 19.5499 8.28579C19.6433 8.32351 19.7281 8.37965 19.7994 8.45087C19.8706 8.52209 19.9267 8.60692 19.9644 8.70031C20.0022 8.7937 20.0207 8.89373 20.0189 8.99443C20.0171 9.09513 19.9951 9.19445 19.9541 9.28645C19.9131 9.37845 19.854 9.46125 19.7803 9.52991L12.5303 16.7799C12.3897 16.9204 12.1991 16.9992 12.0003 16.9992C11.8016 16.9992 11.6109 16.9204 11.4703 16.7799L4.22032 9.52991C4.07987 9.38928 4.00098 9.19866 4.00098 8.99991C4.00098 8.80116 4.07987 8.61054 4.22032 8.46991Z",
426
+ fill: "#8B8C9E"
427
+ })
428
+ }));
429
+ };
418
430
  /**
419
431
  * Material UI `Select` controlled component. Used with react-hook-form
420
432
  * @category Forms
@@ -502,7 +514,7 @@ const ControlSelect = _a => {
502
514
  endAdornment: !required && value ? jsx(InputAdornment, Object.assign({
503
515
  position: "end",
504
516
  sx: {
505
- mr: 2
517
+ mr: 0
506
518
  }
507
519
  }, {
508
520
  children: jsx(IconButton, Object.assign({
@@ -518,7 +530,10 @@ const ControlSelect = _a => {
518
530
  }))
519
531
  }))
520
532
  })) : null
521
- }, textFieldProps === null || textFieldProps === void 0 ? void 0 : textFieldProps.InputProps)
533
+ }, textFieldProps === null || textFieldProps === void 0 ? void 0 : textFieldProps.InputProps),
534
+ SelectProps: {
535
+ IconComponent: PopupIconComponent$2
536
+ }
522
537
  }, {
523
538
  children: options.map((option, index) => jsx(MenuItem, Object.assign({
524
539
  value: getValue(option)
@@ -709,10 +724,19 @@ const useAutocomplete = ({
709
724
  };
710
725
  var useAutocomplete$1 = useAutocomplete;
711
726
 
727
+ var img$4 = "data:image/svg+xml,%3csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M4.22032 8.46991C4.36094 8.32946 4.55157 8.25057 4.75032 8.25057C4.94907 8.25057 5.13969 8.32946 5.28032 8.46991L12.0003 15.1899L18.7203 8.46991C18.789 8.39622 18.8718 8.33712 18.9638 8.29613C19.0558 8.25514 19.1551 8.23309 19.2558 8.23132C19.3565 8.22954 19.4565 8.24807 19.5499 8.28579C19.6433 8.32351 19.7281 8.37965 19.7994 8.45087C19.8706 8.52209 19.9267 8.60692 19.9644 8.70031C20.0022 8.7937 20.0207 8.89373 20.0189 8.99443C20.0171 9.09513 19.9951 9.19445 19.9541 9.28645C19.9131 9.37845 19.854 9.46125 19.7803 9.52991L12.5303 16.7799C12.3897 16.9204 12.1991 16.9992 12.0003 16.9992C11.8016 16.9992 11.6109 16.9204 11.4703 16.7799L4.22032 9.52991C4.07987 9.38928 4.00098 9.19866 4.00098 8.99991C4.00098 8.80116 4.07987 8.61054 4.22032 8.46991Z' fill='%238B8C9E'/%3e%3c/svg%3e";
728
+ var PopupIcon = img$4;
729
+
712
730
  /**
713
731
  * Material UI `Autocomplete` controlled component. Used with react-hook-form
714
732
  * @category Forms
715
733
  */
734
+ const PopupIconComponent$1 = () => {
735
+ return jsx("img", {
736
+ src: PopupIcon,
737
+ alt: ""
738
+ });
739
+ };
716
740
  const ControlAutocomplete = _a => {
717
741
  var {
718
742
  control,
@@ -787,6 +811,7 @@ const ControlAutocomplete = _a => {
787
811
  filterSelectedOptions: multiple,
788
812
  onChange: customOnChange ? customOnChange : handleChange,
789
813
  renderOption: renderOption,
814
+ popupIcon: jsx(PopupIconComponent$1, {}),
790
815
  renderInput: params => {
791
816
  return jsx(TextField, Object.assign({}, params, {
792
817
  variant: "outlined",
@@ -809,6 +834,12 @@ const ControlAutocomplete = _a => {
809
834
  }, autocompleteProps));
810
835
  };
811
836
 
837
+ const PopupIconComponent = () => {
838
+ return jsx("img", {
839
+ src: PopupIcon,
840
+ alt: ""
841
+ });
842
+ };
812
843
  function ControlQueryAutocomplete(_a) {
813
844
  var {
814
845
  name,
@@ -954,6 +985,7 @@ function ControlQueryAutocomplete(_a) {
954
985
  onScroll: handleOnScroll
955
986
  },
956
987
  renderOption: renderOption,
988
+ popupIcon: jsx(PopupIconComponent, {}),
957
989
  renderInput: params => jsx(TextField, Object.assign({}, params, {
958
990
  label: required ? jsxs(Fragment, {
959
991
  children: [label, " ", jsx("span", {
@@ -2660,6 +2692,11 @@ const ControlPhoneInput = _a => {
2660
2692
  children: "*"
2661
2693
  })]
2662
2694
  }) : label,
2695
+ sx: {
2696
+ '.MuiInputLabel-root span': {
2697
+ color: '#D6331F'
2698
+ }
2699
+ },
2663
2700
  inputMode: "numeric",
2664
2701
  InputProps: {
2665
2702
  startAdornment: jsx(InputAdornment, Object.assign({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dartech/arsenal-ui",
3
- "version": "1.4.26",
3
+ "version": "1.4.27",
4
4
  "author": "DAR",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -63,9 +63,5 @@ export type ControlAutocompleteProps = Omit<AutocompleteProps<unknown, boolean,
63
63
  useStringValue?: boolean;
64
64
  requiredErrorText?: string;
65
65
  };
66
- /**
67
- * Material UI `Autocomplete` controlled component. Used with react-hook-form
68
- * @category Forms
69
- */
70
66
  export declare const ControlAutocomplete: ({ control, validate, name, label, required, defaultValue, disabled, hideErrorMessage, onChange: customOnChange, labelKey, valueKey, options, multiple, textFieldProps, disableCloseOnSelect, useStringValue, requiredErrorText, ...autocompleteProps }: ControlAutocompleteProps) => JSX.Element;
71
67
  export default ControlAutocomplete;