grep-components 1.20.0-grepf-1794.1 → 1.20.0-grepf-1813.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.
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { SelectProps, InputBaseComponentProps } from '@mui/material';
2
+ import { SelectProps } from '@mui/material';
3
3
  export interface SelectItem {
4
4
  value: string | number;
5
5
  label?: string;
@@ -13,7 +13,6 @@ export interface GrepSelectProps extends SelectProps {
13
13
  selectItems: SelectItem[];
14
14
  unselectOption?: boolean;
15
15
  useCheckedSelect?: boolean;
16
- inputProps?: InputBaseComponentProps | undefined;
17
16
  }
18
17
  declare const _default: React.ComponentType<GrepSelectProps>;
19
18
  export default _default;
@@ -9,8 +9,6 @@ export interface SearchBarProps {
9
9
  onClear: () => void;
10
10
  onSearchAll?: () => void;
11
11
  onInputChange: (value: string) => void;
12
- id?: string;
13
- title?: string;
14
12
  }
15
13
  declare const _default: React.ComponentType<SearchBarProps>;
16
14
  export default _default;
package/dist/index.js CHANGED
@@ -3500,9 +3500,6 @@ var PaginationActions = function (_a) {
3500
3500
  var GrepTablePagination = function (props) {
3501
3501
  var classes = usePaginationStyles().classes;
3502
3502
  return (React__default.createElement(TablePagination, __assign({ classes: classes, rowsPerPageOptions: props.rowsPerPageOptions || [5, 10, 25, 50], SelectProps: {
3503
- inputProps: {
3504
- title: 'Velg antall elementer',
3505
- },
3506
3503
  style: {
3507
3504
  gridArea: 'left',
3508
3505
  justifySelf: 'start',
@@ -3835,13 +3832,7 @@ var SearchBar = function (props) {
3835
3832
  } },
3836
3833
  React.createElement(Box, { className: classes.icon },
3837
3834
  React.createElement(Search, null)),
3838
- React.createElement(TextField, { id: props.id, role: "search", className: classes.input, value: value, variant: "standard", inputRef: inputRef, onChange: _handleChange, autoFocus: props.autoFocus, placeholder: props.placeholder, InputProps: {
3839
- disableUnderline: true,
3840
- fullWidth: true,
3841
- inputProps: {
3842
- title: props.title,
3843
- },
3844
- } }),
3835
+ React.createElement(TextField, { role: "search", className: classes.input, value: value, variant: "standard", inputRef: inputRef, onChange: _handleChange, autoFocus: props.autoFocus, placeholder: props.placeholder, InputProps: { disableUnderline: true, fullWidth: true } }),
3845
3836
  React.createElement(Box, { className: classes.icon, style: { cursor: 'pointer' } }, !!value.length && (React.createElement(Close, { "data-testid": "searchBarClearBtn", tabIndex: 0, onClick: _handleClear, onKeyPress: keyboard.onActivation(_handleClear) })))),
3846
3837
  React.createElement("div", { style: { display: 'flex', alignItems: 'center' } },
3847
3838
  props.helpText && (React.createElement(Typography, { className: classes.helptext }, props.helpText)),
@@ -3964,7 +3955,7 @@ var GrepSelect = function (props) {
3964
3955
  React.useEffect(function () {
3965
3956
  setLabelWidth(inputLabel.current.offsetWidth);
3966
3957
  }, []);
3967
- var _b = props.unselectOption, unselectOption = _b === void 0 ? true : _b, errorMessage = props.errorMessage, selectItems = props.selectItems, helperText = props.helperText, fullWidth = props.fullWidth, outlined = props.outlined, disabled = props.disabled, required = props.required, label = props.label, inputProps = props.inputProps, value = props.value, size = props.size, id = props.id, useCheckedSelect = props.useCheckedSelect, rest = __rest$1(props, ["unselectOption", "errorMessage", "selectItems", "helperText", "fullWidth", "outlined", "disabled", "required", "label", "inputProps", "value", "size", "id", "useCheckedSelect"]);
3958
+ var _b = props.unselectOption, unselectOption = _b === void 0 ? true : _b, errorMessage = props.errorMessage, selectItems = props.selectItems, helperText = props.helperText, fullWidth = props.fullWidth, outlined = props.outlined, disabled = props.disabled, required = props.required, label = props.label, value = props.value, size = props.size, id = props.id, useCheckedSelect = props.useCheckedSelect, rest = __rest$1(props, ["unselectOption", "errorMessage", "selectItems", "helperText", "fullWidth", "outlined", "disabled", "required", "label", "value", "size", "id", "useCheckedSelect"]);
3968
3959
  var error = errorMessage ? errorMessage.length > 0 : false;
3969
3960
  var selected = value;
3970
3961
  return (React.createElement(FormControl, { variant: outlined ? 'outlined' : 'standard', className: props.className, fullWidth: fullWidth, required: required, style: props.style, error: error, size: size, disabled: disabled },
@@ -3972,7 +3963,7 @@ var GrepSelect = function (props) {
3972
3963
  minWidth: 'max-content',
3973
3964
  overflow: 'visible',
3974
3965
  } }, label),
3975
- React.createElement(Select, __assign({}, rest, { inputProps: __assign({ id: id }, inputProps), disabled: !selectItems || disabled, value: value === null ? '' : value, style: { minWidth: labelWidth + (outlined ? 35 : 25) },
3966
+ React.createElement(Select, __assign({}, rest, { inputProps: { id: id }, disabled: !selectItems || disabled, value: value === null ? '' : value, style: { minWidth: labelWidth + (outlined ? 35 : 25) },
3976
3967
  // @todo: make input respect label length
3977
3968
  input: outlined ? React.createElement(OutlinedInput, { label: label }) : React.createElement(Input, null), MenuProps: {
3978
3969
  anchorOrigin: {
@@ -20802,7 +20793,7 @@ var ToolbarMenuItem = styled(NavLink)(function (_a) {
20802
20793
  left: '50%',
20803
20794
  width: '32px',
20804
20795
  marginLeft: '-16px',
20805
- borderBottom: "2px solid ".concat(theme.palette.secondary.main),
20796
+ borderBottom: "2px solid ".concat(theme.palette.secondary.light),
20806
20797
  opacity: 0,
20807
20798
  content: '""',
20808
20799
  transition: 'all 0.3s ease',