@mailstep/design-system 0.6.19 → 0.6.20

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mailstep/design-system",
3
- "version": "0.6.19",
3
+ "version": "0.6.20",
4
4
  "license": "ISC",
5
5
  "type": "module",
6
6
  "main": "./ui/index.js",
@@ -18,7 +18,7 @@ var StyledInput = styled(Input)(templateObject_1 || (templateObject_1 = __makeTe
18
18
  });
19
19
  var QuickFilter = function (_a) {
20
20
  var searchedValue = _a.searchedValue, placeholderText = _a.placeholderText, onChange = _a.onChange, onClick = _a.onClick, displayInput = _a.displayInput, onClear = _a.onClear, isMobileInputView = _a.isMobileInputView;
21
- return (_jsx(x.div, { mr: "12px", children: displayInput ? (_jsx(StyledInput, { icon: "search", type: "text", value: searchedValue, placeholder: placeholderText, onChange: onChange, variant: "gray", onClear: onClear, isMobileInputView: isMobileInputView })) : (_jsx(Button, { variant: "icon", appearance: "secondary", icon: "search", onClick: onClick })) }));
21
+ return (_jsx(x.div, { mr: "12px", children: displayInput ? (_jsx(StyledInput, { icon: "search", type: "text", value: searchedValue, placeholder: placeholderText, onChange: onChange, variant: "gray", onClear: onClear, alwaysShowClear: true, isMobileInputView: isMobileInputView })) : (_jsx(Button, { variant: "icon", appearance: "secondary", icon: "search", onClick: onClick })) }));
22
22
  };
23
23
  export default QuickFilter;
24
24
  var templateObject_1;
@@ -0,0 +1,11 @@
1
+ declare const _default: {
2
+ title: string;
3
+ decorators: ((story: Function) => JSX.Element)[];
4
+ };
5
+ export default _default;
6
+ export declare const WithQuickFilter: {
7
+ (): import("react/jsx-runtime").JSX.Element;
8
+ story: {
9
+ name: string;
10
+ };
11
+ };
@@ -0,0 +1,18 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import CommonGrid from '../../CommonGridContainer';
3
+ import { createRandomData, gridSelectors, gridDummyActions } from '../utils/utils';
4
+ import { columnDefinitions } from '../utils/columnDefinition';
5
+ import withTheme from '../utils/withTheme';
6
+ import withRouter from '../utils/withRouter';
7
+ import withRedux from '../utils/withRedux';
8
+ import { LinguiContainer } from '../utils/linguiContainer';
9
+ export default {
10
+ title: '@Blocks/CommonGrid',
11
+ decorators: [withTheme, withRouter, withRedux],
12
+ };
13
+ export var WithQuickFilter = function () {
14
+ return (_jsx(LinguiContainer, { children: _jsx(CommonGrid, { columnsDefinitions: columnDefinitions, rowsData: createRandomData(10), gridActions: gridDummyActions, gridSelectors: gridSelectors, quickFilter: "numberColumn" }) }));
15
+ };
16
+ WithQuickFilter.story = {
17
+ name: 'with quick filter',
18
+ };
package/ui/index.es.js CHANGED
@@ -46857,7 +46857,7 @@ const QAe = ae.div`
46857
46857
  displayInput: i,
46858
46858
  onClear: o,
46859
46859
  isMobileInputView: l
46860
- }) => /* @__PURE__ */ b.jsx(ht.div, { mr: "12px", children: i ? /* @__PURE__ */ b.jsx(CCe, { icon: "search", type: "text", value: e, placeholder: t, onChange: r, variant: "gray", onClear: o, isMobileInputView: l }) : /* @__PURE__ */ b.jsx(oi, { variant: "icon", appearance: "secondary", icon: "search", onClick: n }) }), ECe = () => {
46860
+ }) => /* @__PURE__ */ b.jsx(ht.div, { mr: "12px", children: i ? /* @__PURE__ */ b.jsx(CCe, { icon: "search", type: "text", value: e, placeholder: t, onChange: r, variant: "gray", onClear: o, alwaysShowClear: !0, isMobileInputView: l }) : /* @__PURE__ */ b.jsx(oi, { variant: "icon", appearance: "secondary", icon: "search", onClick: n }) }), ECe = () => {
46861
46861
  const [e, t] = He(!1);
46862
46862
  return yt(() => {
46863
46863
  const r = () => {
package/ui/index.umd.js CHANGED
@@ -3664,7 +3664,7 @@ Avoid returning a new reference inside your input selector, e.g.
3664
3664
  position: ${({isMobileInputView:e})=>e?"absolute":"relative"};
3665
3665
  z-index: ${({isMobileInputView:e})=>e?"3":"1"};
3666
3666
  width: ${({isMobileInputView:e})=>e?"90vw":"auto"};
3667
- `,yxe=({searchedValue:e,placeholderText:t,onChange:r,onClick:n,displayInput:i,onClear:o,isMobileInputView:l})=>b.jsx(ut.div,{mr:"12px",children:i?b.jsx(bxe,{icon:"search",type:"text",value:e,placeholder:t,onChange:r,variant:"gray",onClear:o,isMobileInputView:l}):b.jsx(Pn,{variant:"icon",appearance:"secondary",icon:"search",onClick:n})}),wxe=()=>{const[e,t]=I.useState(!1);return I.useEffect(()=>{const r=()=>{window.innerWidth<1024?t==null||t(!0):t(!1)};return window.addEventListener("resize",r),r(),()=>window.removeEventListener("resize",r)},[]),{isMobile:e}};var iv={exports:{}};/**
3667
+ `,yxe=({searchedValue:e,placeholderText:t,onChange:r,onClick:n,displayInput:i,onClear:o,isMobileInputView:l})=>b.jsx(ut.div,{mr:"12px",children:i?b.jsx(bxe,{icon:"search",type:"text",value:e,placeholder:t,onChange:r,variant:"gray",onClear:o,alwaysShowClear:!0,isMobileInputView:l}):b.jsx(Pn,{variant:"icon",appearance:"secondary",icon:"search",onClick:n})}),wxe=()=>{const[e,t]=I.useState(!1);return I.useEffect(()=>{const r=()=>{window.innerWidth<1024?t==null||t(!0):t(!1)};return window.addEventListener("resize",r),r(),()=>window.removeEventListener("resize",r)},[]),{isMobile:e}};var iv={exports:{}};/**
3668
3668
  * @license
3669
3669
  * Lodash <https://lodash.com/>
3670
3670
  * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>