@homecode/ui 4.22.12 → 4.22.14

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.
@@ -8,12 +8,12 @@ import { Popup } from '../Popup/Popup.js';
8
8
  import S from './DatePickerInput.styl.js';
9
9
 
10
10
  function DatePickerInput(props) {
11
- const { value, variant = 'default', size = 'm', popupProps, displayFormat = 'MMM Do YYYY', } = props;
11
+ const { value, variant = 'default', size = 'm', popupProps, buttonProps, displayFormat = 'MMM Do YYYY', } = props;
12
12
  const isRange = Array.isArray(value);
13
13
  return (jsx(Popup, { size: size, focusControl: true, direction: "bottom-right", ...popupProps, trigger:
14
14
  // @ts-ignore
15
15
  jsx(Button, { variant: variant, size: size, children: isRange ? (jsxs(Fragment, { children: [jsx(DateTime, { value: strToDate(value[0]), format: displayFormat }), ' - ', jsx(DateTime, { value: strToDate(value[1]), format: displayFormat })] })) : (jsx(DateTime, { value: strToDate(value), format: displayFormat })) }), contentProps: {
16
- className: cn(S.popupContent, props.doubleCalendar && S.doubleCalendar, S[`size-${size}`]),
16
+ className: cn(S.popupContent, props.doubleCalendar && S.doubleCalendar, S[`size-${size}`], popupProps?.contentProps?.className),
17
17
  }, content: jsx(DatePicker, { ...props, className: S.content, calendarProps: { className: S.calendar } }) }));
18
18
  }
19
19
 
@@ -1,19 +1,21 @@
1
1
  import { jsx } from 'react/jsx-runtime';
2
2
  import S from './Flex.styl.js';
3
3
 
4
- const Flex = ({ children, ...props }) => {
5
- return (jsx("div", { className: S.root, ...props, style: {
6
- justifyContent: props.justifyContent,
7
- alignItems: props.alignItems,
8
- flexDirection: props.flexDirection,
9
- flexWrap: props.flexWrap,
10
- flexGrow: props.flexGrow,
11
- flexShrink: props.flexShrink,
12
- flexBasis: props.flexBasis,
13
- flex: props.flex,
14
- order: props.order,
15
- alignSelf: props.alignSelf,
16
- flexFlow: props.flexFlow,
4
+ const Flex = ({ children, justifyContent, alignItems, flexDirection, flexWrap, flexGrow, flexShrink, flexBasis, flex, order, alignSelf, flexFlow, ...props }) => {
5
+ return (jsx("div", { className: S.root,
6
+ // {...props}
7
+ style: {
8
+ justifyContent,
9
+ alignItems,
10
+ flexDirection,
11
+ flexWrap,
12
+ flexGrow,
13
+ flexShrink,
14
+ flexBasis,
15
+ flex,
16
+ order,
17
+ alignSelf,
18
+ flexFlow,
17
19
  }, children: children }));
18
20
  };
19
21
 
@@ -0,0 +1,17 @@
1
+ import * as React from 'react';
2
+
3
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
4
+ var SvgChat = function SvgChat(props) {
5
+ return /*#__PURE__*/React.createElement("svg", _extends({
6
+ xmlns: "http://www.w3.org/2000/svg",
7
+ fill: "currentColor",
8
+ viewBox: "0 0 24 24"
9
+ }, props), /*#__PURE__*/React.createElement("path", {
10
+ d: "M21.336 1.656H2.621c-1.268 0-2.34 1.072-2.34 2.34v12.867c0 1.268 1.072 2.34 2.34 2.34h11.135l3.783 4.16a.39.39 0 0 0 .678-.262v-3.899h3.12c1.267 0 2.339-1.071 2.339-2.34V3.997c0-1.268-1.072-2.34-2.34-2.34M4.96 6.726h5.849a.39.39 0 1 1 0 .779H4.96a.39.39 0 1 1 0-.78m13.257 7.018H4.96a.39.39 0 1 1 0-.78h13.257a.39.39 0 1 1 0 .78m0-3.12H4.96a.39.39 0 1 1 0-.78h13.257a.39.39 0 1 1 0 .78",
11
+ style: {
12
+ strokeWidth: 0.38991
13
+ }
14
+ }));
15
+ };
16
+
17
+ export { SvgChat as default };
@@ -5,6 +5,7 @@ var ICONS = {
5
5
  brain: () => import('./brain.svg.js'),
6
6
  brokenImage: () => import('./brokenImage.svg.js'),
7
7
  camera: () => import('./camera.svg.js'),
8
+ chat: () => import('./chat.svg.js'),
8
9
  check: () => import('./check.svg.js'),
9
10
  close: () => import('./close.svg.js'),
10
11
  colors: () => import('./colors.svg.js'),
@@ -1,8 +1,10 @@
1
1
  import type { Props as PopupProps } from 'uilib/components/Popup/Popup.types';
2
2
  import type { Props as DatePickerProps } from 'uilib/components/DatePicker/DatePicker.types';
3
+ import type { Props as ButtonProps } from 'uilib/components/Button/Button.types';
3
4
  export type Value = string | [string, string];
4
5
  export type Props = DatePickerProps & {
5
6
  variant?: string;
6
7
  displayFormat: string;
7
8
  popupProps?: PopupProps;
9
+ buttonProps?: Omit<ButtonProps, 'children'>;
8
10
  };
@@ -1,6 +1,6 @@
1
1
  import { CSSProperties, HTMLAttributes } from 'react';
2
- type FlexProps = HTMLAttributes<HTMLDivElement> & CSSProperties & {
2
+ type FlexProps = HTMLAttributes<HTMLDivElement> & Pick<CSSProperties, 'justifyContent' | 'alignItems' | 'flexDirection' | 'flexWrap' | 'flexGrow' | 'flexShrink' | 'flexBasis' | 'flex' | 'order' | 'alignSelf' | 'flexFlow'> & {
3
3
  children: React.ReactNode;
4
4
  };
5
- export declare const Flex: ({ children, ...props }: FlexProps) => JSX.Element;
5
+ export declare const Flex: ({ children, justifyContent, alignItems, flexDirection, flexWrap, flexGrow, flexShrink, flexBasis, flex, order, alignSelf, flexFlow, ...props }: FlexProps) => JSX.Element;
6
6
  export {};
@@ -5,6 +5,7 @@ declare const _default: {
5
5
  brain: () => Promise<any>;
6
6
  brokenImage: () => Promise<any>;
7
7
  camera: () => Promise<any>;
8
+ chat: () => Promise<any>;
8
9
  check: () => Promise<any>;
9
10
  close: () => Promise<any>;
10
11
  colors: () => Promise<any>;
@@ -1,4 +1,5 @@
1
1
  import { MenuGroupProps, MenuItemProps, MenuProps } from './Menu.types';
2
+ export { type MenuProps };
2
3
  export declare const Menu: import("react").ForwardRefExoticComponent<MenuProps & import("react").RefAttributes<Scroll>> & {
3
4
  Item: import("react").ForwardRefExoticComponent<MenuItemProps & import("react").RefAttributes<HTMLDivElement>>;
4
5
  Group: import("react").FC<MenuGroupProps>;
@@ -1,2 +1,3 @@
1
1
  import * as T from './Scroll.types';
2
+ export type ScrollProps = T.Props;
2
3
  export declare function Scroll(props: T.Props): JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@homecode/ui",
3
- "version": "4.22.12",
3
+ "version": "4.22.14",
4
4
  "description": "React UI components library",
5
5
  "scripts": {
6
6
  "test": "jest",