@sinco/react 1.0.11-rc.4 → 1.0.11-rc.5

Sign up to get free protection for your applications and to get access to all the features.
package/index.js CHANGED
@@ -16924,7 +16924,7 @@ var EmptyStateImageUrls;
16924
16924
  (function (EmptyStateImageUrls) {
16925
16925
  EmptyStateImageUrls["error"] = "error";
16926
16926
  EmptyStateImageUrls["search"] = "search";
16927
- EmptyStateImageUrls["noresult"] = "noresult";
16927
+ EmptyStateImageUrls["noResult"] = "noResult";
16928
16928
  EmptyStateImageUrls["create"] = "create";
16929
16929
  })(EmptyStateImageUrls || (EmptyStateImageUrls = {}));
16930
16930
  const EmptyStateComponent = ({
@@ -17483,7 +17483,7 @@ const DrawerComponent = ({
17483
17483
  onClose
17484
17484
  }) => {
17485
17485
  const [stateActions, setActionsState] = useState(false);
17486
- const handleDrawerAcciones = () => {
17486
+ const handleDrawerActions = () => {
17487
17487
  setActionsState(true);
17488
17488
  };
17489
17489
  return /*#__PURE__*/React__default.createElement(ThemeProvider, {
@@ -17504,7 +17504,7 @@ const DrawerComponent = ({
17504
17504
  }, /*#__PURE__*/React__default.createElement(default_1, {
17505
17505
  fontSize: "small"
17506
17506
  })))), /*#__PURE__*/React__default.createElement(Box$2, {
17507
- onClick: handleDrawerAcciones,
17507
+ onClick: handleDrawerActions,
17508
17508
  sx: stylesDrawerContent
17509
17509
  }, children), stateActions && /*#__PURE__*/React__default.createElement(Box$2, {
17510
17510
  sx: stylesDrawerActions
@@ -17698,26 +17698,31 @@ const ToastNotificationComponent = toast => {
17698
17698
  })))));
17699
17699
  };
17700
17700
 
17701
- const PageContent = styled$1(Stack$1)(({
17701
+ const PageHeaderContent = styled$1(Stack$1)(({
17702
17702
  theme
17703
17703
  }) => ({
17704
- backgroundColor: "#fff",
17705
- boxShadow: "0px 1px 3px rgba(24, 39, 75, 0.12), 0px 1px 1px -1px rgba(24, 39, 75, 0.14), 0px 2px 1px -2px rgba(24, 39, 75, 0.2)",
17704
+ backgroundColor: '#fff',
17705
+ boxShadow: '0px 1px 3px rgba(24, 39, 75, 0.12), 0px 1px 1px -1px rgba(24, 39, 75, 0.14), 0px 2px 1px -2px rgba(24, 39, 75, 0.2)',
17706
17706
  zIndex: 100,
17707
- padding: "8px 24px",
17708
- justifyContent: "space-between",
17707
+ padding: '8px 24px',
17708
+ justifyContent: 'space-between',
17709
17709
  minHeight: 39,
17710
- position: "fixed",
17711
- width: "100%"
17710
+ position: 'fixed',
17711
+ width: '100%'
17712
17712
  }));
17713
- const PageHeaderComponent = page => {
17713
+ const PageHeaderComponent = ({
17714
+ title,
17715
+ subtitle,
17716
+ actions,
17717
+ buttonBack
17718
+ }) => {
17714
17719
  return /*#__PURE__*/React__default.createElement(ThemeProvider, {
17715
17720
  theme: SincoTheme
17716
17721
  }, /*#__PURE__*/React__default.createElement("div", {
17717
17722
  style: {
17718
17723
  minHeight: 56
17719
17724
  }
17720
- }, /*#__PURE__*/React__default.createElement(PageContent, null, /*#__PURE__*/React__default.createElement(Stack$1, {
17725
+ }, /*#__PURE__*/React__default.createElement(PageHeaderContent, null, /*#__PURE__*/React__default.createElement(Stack$1, {
17721
17726
  width: "90%",
17722
17727
  justifyContent: "space-between",
17723
17728
  flexDirection: "row",
@@ -17726,17 +17731,17 @@ const PageHeaderComponent = page => {
17726
17731
  gap: 1.5,
17727
17732
  flexDirection: "row",
17728
17733
  alignItems: "center"
17729
- }, page.buttonBack, /*#__PURE__*/React__default.createElement(Stack$1, null, /*#__PURE__*/React__default.createElement(Typography$1, {
17734
+ }, buttonBack, /*#__PURE__*/React__default.createElement(Stack$1, null, /*#__PURE__*/React__default.createElement(Typography$1, {
17730
17735
  variant: "h6",
17731
17736
  color: "text.primary"
17732
- }, page.title), /*#__PURE__*/React__default.createElement(Typography$1, {
17737
+ }, title), /*#__PURE__*/React__default.createElement(Typography$1, {
17733
17738
  variant: "caption",
17734
17739
  color: "text.secondary"
17735
- }, page.subtitle))), /*#__PURE__*/React__default.createElement(Stack$1, {
17740
+ }, subtitle))), /*#__PURE__*/React__default.createElement(Stack$1, {
17736
17741
  gap: 1,
17737
17742
  alignItems: "center",
17738
17743
  flexDirection: "row"
17739
- }, page.actions)))));
17744
+ }, actions)))));
17740
17745
  };
17741
17746
 
17742
17747
  const FooterActionComponent = ({
@@ -23226,4 +23231,4 @@ const useDynamicColor = url => {
23226
23231
  };
23227
23232
  };
23228
23233
 
23229
- export { DrawerComponent, DynamicColor, EmptyStateComponent, EmptyStateImageUrls, FooterActionComponent, PageContent, PageHeaderComponent, SincoTheme, ToastNotificationComponent, useDynamicColor };
23234
+ export { DrawerComponent, DynamicColor, EmptyStateComponent, EmptyStateImageUrls, FooterActionComponent, PageHeaderComponent, PageHeaderContent, SincoTheme, ToastNotificationComponent, useDynamicColor };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sinco/react",
3
- "version": "1.0.11-rc.4",
3
+ "version": "1.0.11-rc.5",
4
4
  "description": "package for the configuration of mui react sinco",
5
5
  "private": false,
6
6
  "license": "MIT",
@@ -1,9 +1,9 @@
1
1
  import { ReactNode } from 'react';
2
- export type EmptyStateStates = 'create' | 'error' | 'noresult' | 'search';
2
+ export type EmptyStateStates = 'create' | 'error' | 'noResult' | 'search';
3
3
  export declare enum EmptyStateImageUrls {
4
4
  error = "error",
5
5
  search = "search",
6
- noresult = "noresult",
6
+ noResult = "noResult",
7
7
  create = "create"
8
8
  }
9
9
  export interface EmptyStateProperties {
@@ -1,11 +1,5 @@
1
- import React from "react";
2
- interface Pageheader {
3
- title: string;
4
- subtitle?: string;
5
- actions?: React.ReactNode;
6
- buttonBack?: React.ReactNode;
7
- }
8
- export declare const PageContent: import("@emotion/styled").StyledComponent<import("@mui/system").SystemProps<import("@mui/material").Theme> & {
1
+ import React from 'react';
2
+ export declare const PageHeaderContent: import("@emotion/styled").StyledComponent<import("@mui/system").SystemProps<import("@mui/material").Theme> & {
9
3
  children?: React.ReactNode;
10
4
  direction?: import("@mui/system").ResponsiveStyleValue<"column" | "column-reverse" | "row" | "row-reverse"> | undefined;
11
5
  spacing?: import("@mui/system").ResponsiveStyleValue<string | number> | undefined;
@@ -15,5 +9,11 @@ export declare const PageContent: import("@emotion/styled").StyledComponent<impo
15
9
  } & import("@mui/material/OverridableComponent").CommonProps & Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
16
10
  ref?: ((instance: HTMLDivElement | null) => void) | React.RefObject<HTMLDivElement> | null | undefined;
17
11
  }, keyof import("@mui/material/OverridableComponent").CommonProps | "direction" | ("border" | "borderTop" | "borderRight" | "borderBottom" | "borderLeft" | "borderColor" | "borderRadius" | "display" | "displayPrint" | "overflow" | "textOverflow" | "visibility" | "whiteSpace" | "flexBasis" | "flexDirection" | "flexWrap" | "justifyContent" | "alignItems" | "alignContent" | "order" | "flex" | "flexGrow" | "flexShrink" | "alignSelf" | "justifyItems" | "justifySelf" | "gap" | "columnGap" | "rowGap" | "gridColumn" | "gridRow" | "gridAutoFlow" | "gridAutoColumns" | "gridAutoRows" | "gridTemplateColumns" | "gridTemplateRows" | "gridTemplateAreas" | "gridArea" | "bgcolor" | "color" | "zIndex" | "position" | "top" | "right" | "bottom" | "left" | "boxShadow" | "width" | "maxWidth" | "minWidth" | "height" | "maxHeight" | "minHeight" | "boxSizing" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "my" | "p" | "pt" | "pr" | "pb" | "pl" | "px" | "py" | "margin" | "marginTop" | "marginRight" | "marginBottom" | "marginLeft" | "marginX" | "marginY" | "padding" | "paddingTop" | "paddingRight" | "paddingBottom" | "paddingLeft" | "paddingX" | "paddingY" | "typography" | "fontFamily" | "fontSize" | "fontStyle" | "fontWeight" | "letterSpacing" | "lineHeight" | "textAlign" | "textTransform") | "children" | "spacing" | "divider" | "useFlexGap" | "sx"> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
18
- export declare const PageHeaderComponent: (page: Pageheader) => JSX.Element;
12
+ interface PageheaderProperties {
13
+ title: string;
14
+ subtitle?: string;
15
+ actions?: React.ReactNode;
16
+ buttonBack?: React.ReactNode;
17
+ }
18
+ export declare const PageHeaderComponent: ({ title, subtitle, actions, buttonBack, }: PageheaderProperties) => JSX.Element;
19
19
  export {};
@@ -1 +1 @@
1
- export * from './DynamicColor';
1
+ export * from './dynamicColor';