@jsonui/react 0.7.4 → 0.8.0

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.
Files changed (58) hide show
  1. package/dist/cjs/index.js +3401 -19187
  2. package/dist/cjs/index.js.map +1 -1
  3. package/dist/cjs/types/ErrorBoundary.d.ts +3 -2
  4. package/dist/cjs/types/ReduxProviders.d.ts +1 -1
  5. package/dist/cjs/types/Renderer.d.ts +5 -2
  6. package/dist/cjs/types/ViewerWeb.d.ts +1 -2
  7. package/dist/cjs/types/Wrapper.d.ts +1 -2
  8. package/dist/cjs/types/index.d.ts +1 -2
  9. package/dist/cjs/types/stock/components/Button.d.ts +1 -2
  10. package/dist/cjs/types/stock/components/Edit.d.ts +1 -2
  11. package/dist/cjs/types/stock/components/FormResult.d.ts +1 -2
  12. package/dist/cjs/types/stock/components/HelperText.d.ts +1 -2
  13. package/dist/cjs/types/stock/components/Image.d.ts +1 -2
  14. package/dist/cjs/types/stock/components/Label.d.ts +2 -2
  15. package/dist/cjs/types/stock/components/PrimitiveProp.d.ts +1 -2
  16. package/dist/cjs/types/stock/components/Text.d.ts +1 -2
  17. package/dist/cjs/types/stock/components/Undefined.d.ts +1 -2
  18. package/dist/cjs/types/stock/components/View.d.ts +1 -2
  19. package/dist/cjs/types/stories/JsonUI.stories.d.ts +3 -4
  20. package/dist/cjs/types/stories/MultiChild.stories.d.ts +2 -3
  21. package/dist/cjs/types/stories/PartialValueUpdateTest/PushNotificationTest.stories.d.ts +2 -3
  22. package/dist/cjs/types/stories/PerformansTest1.stories.d.ts +1 -2
  23. package/dist/cjs/types/stories/PerformansTest2.stories.d.ts +1 -2
  24. package/dist/cjs/types/stories/ReduxTest.stories.d.ts +3 -4
  25. package/dist/cjs/types/stories/Simple.stories.d.ts +2 -3
  26. package/dist/cjs/types/stories/StateSaveTest/StateSaveTest.stories.d.ts +2 -3
  27. package/dist/cjs/types/stories/Table.stories.d.ts +2 -3
  28. package/dist/cjs/types/stories/Validation.stories.d.ts +2 -3
  29. package/dist/esm/index.js +3377 -19159
  30. package/dist/esm/index.js.map +1 -1
  31. package/dist/esm/types/ErrorBoundary.d.ts +3 -2
  32. package/dist/esm/types/ReduxProviders.d.ts +1 -1
  33. package/dist/esm/types/Renderer.d.ts +5 -2
  34. package/dist/esm/types/ViewerWeb.d.ts +1 -2
  35. package/dist/esm/types/Wrapper.d.ts +1 -2
  36. package/dist/esm/types/index.d.ts +1 -2
  37. package/dist/esm/types/stock/components/Button.d.ts +1 -2
  38. package/dist/esm/types/stock/components/Edit.d.ts +1 -2
  39. package/dist/esm/types/stock/components/FormResult.d.ts +1 -2
  40. package/dist/esm/types/stock/components/HelperText.d.ts +1 -2
  41. package/dist/esm/types/stock/components/Image.d.ts +1 -2
  42. package/dist/esm/types/stock/components/Label.d.ts +2 -2
  43. package/dist/esm/types/stock/components/PrimitiveProp.d.ts +1 -2
  44. package/dist/esm/types/stock/components/Text.d.ts +1 -2
  45. package/dist/esm/types/stock/components/Undefined.d.ts +1 -2
  46. package/dist/esm/types/stock/components/View.d.ts +1 -2
  47. package/dist/esm/types/stories/JsonUI.stories.d.ts +3 -4
  48. package/dist/esm/types/stories/MultiChild.stories.d.ts +2 -3
  49. package/dist/esm/types/stories/PartialValueUpdateTest/PushNotificationTest.stories.d.ts +2 -3
  50. package/dist/esm/types/stories/PerformansTest1.stories.d.ts +1 -2
  51. package/dist/esm/types/stories/PerformansTest2.stories.d.ts +1 -2
  52. package/dist/esm/types/stories/ReduxTest.stories.d.ts +3 -4
  53. package/dist/esm/types/stories/Simple.stories.d.ts +2 -3
  54. package/dist/esm/types/stories/StateSaveTest/StateSaveTest.stories.d.ts +2 -3
  55. package/dist/esm/types/stories/Table.stories.d.ts +2 -3
  56. package/dist/esm/types/stories/Validation.stories.d.ts +2 -3
  57. package/dist/index.d.ts +23 -10
  58. package/package.json +51 -46
@@ -1,7 +1,8 @@
1
1
  import React from 'react';
2
- export interface ErrorBoundaryProps extends React.Props<any> {
2
+ export interface ErrorBoundaryProps {
3
3
  type?: string;
4
4
  id?: string;
5
+ children?: React.ReactNode;
5
6
  }
6
7
  declare type errorType = any;
7
8
  export interface ErrorBoundaryState {
@@ -16,6 +17,6 @@ declare class ErrorBoundary extends React.Component<ErrorBoundaryProps, ErrorBou
16
17
  error: any;
17
18
  };
18
19
  componentDidCatch(error: errorType, info: any): void;
19
- render(): React.ReactNode;
20
+ render(): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
20
21
  }
21
22
  export default ErrorBoundary;
@@ -5,5 +5,5 @@ interface Props {
5
5
  defaultValues?: DefaultValues;
6
6
  getFormState?: GetFormState;
7
7
  }
8
- declare const Providers: ({ children, defaultValues: root, getFormState: getState }: Props) => JSX.Element;
8
+ declare const Providers: ({ children, defaultValues: root, getFormState: getState }: Props) => import("react/jsx-runtime").JSX.Element;
9
9
  export default Providers;
@@ -1,7 +1,10 @@
1
- /// <reference types="react" />
1
+ import React from 'react';
2
+ import { Stock } from '@jsonui/core';
3
+ export declare const StockContext: React.Context<Stock | null>;
4
+ export declare const PathModifierContext: React.Context<{}>;
2
5
  interface RendererFuncProps {
3
6
  model: any;
4
7
  stockInit: any;
5
8
  }
6
- declare const rendererFunc: (props: RendererFuncProps) => JSX.Element;
9
+ declare const rendererFunc: (props: RendererFuncProps) => import("react/jsx-runtime").JSX.Element;
7
10
  export default rendererFunc;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { ViewerProps } from 'types';
3
- declare function ViewerWeb({ defaultValues, getFormState, ...props }: ViewerProps): JSX.Element;
2
+ declare function ViewerWeb({ defaultValues, getFormState, ...props }: ViewerProps): import("react/jsx-runtime").JSX.Element;
4
3
  export default ViewerWeb;
@@ -1,7 +1,6 @@
1
- /// <reference types="react" />
2
1
  import { PropsType } from '@jsonui/core';
3
2
  export declare const getStyle: (props: PropsType | undefined, component: string) => any;
4
3
  declare function Wrapper({ props: origProps }: {
5
4
  props: any;
6
- }): JSX.Element | null;
5
+ }): import("react/jsx-runtime").JSX.Element | null;
7
6
  export default Wrapper;
@@ -1,8 +1,7 @@
1
- /// <reference types="react" />
2
1
  import { JsonUIComponentsType, JsonUIFunctions, JsonUIFunctionType } from '@jsonui/core';
3
2
  import { ChangeDefaultValueFuncProp, JSONValue, ViewerProps } from './types';
4
3
  import { MessageHandlerContext, MessageHandler } from './MessageReceiverContext';
5
- declare const JsonUI: (props: ViewerProps) => JSX.Element;
4
+ declare const JsonUI: (props: ViewerProps) => import("react/jsx-runtime").JSX.Element;
6
5
  export { JsonUI, MessageHandlerContext, MessageHandler };
7
6
  export type { ViewerProps as JsonUIProps, JSONValue, ChangeDefaultValueFuncProp, JsonUIFunctions, JsonUIFunctionType, JsonUIComponentsType };
8
7
  export default JsonUI;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
- declare function Button({ children, type, ...props }: any): JSX.Element;
1
+ declare function Button({ children, type, ...props }: any): import("react/jsx-runtime").JSX.Element;
3
2
  export default Button;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
- declare function Edit(props: any): JSX.Element;
1
+ declare function Edit(props: any): import("react/jsx-runtime").JSX.Element;
3
2
  export default Edit;
@@ -1,5 +1,4 @@
1
- /// <reference types="react" />
2
1
  declare function FormResult({ value }: {
3
2
  value: any;
4
- }): JSX.Element;
3
+ }): import("react/jsx-runtime").JSX.Element;
5
4
  export default FormResult;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
- declare function HelperText(props: any): JSX.Element | null;
1
+ declare function HelperText(props: any): import("react/jsx-runtime").JSX.Element | null;
3
2
  export default HelperText;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
- declare function Image(props: any): JSX.Element;
1
+ declare function Image(props: any): import("react/jsx-runtime").JSX.Element;
3
2
  export default Image;
@@ -1,9 +1,9 @@
1
1
  import React from 'react';
2
- export declare const getLabel: (props: any) => JSX.Element;
2
+ export declare const getLabel: (props: any) => import("react/jsx-runtime").JSX.Element;
3
3
  export declare class InfoBox extends React.PureComponent {
4
4
  counter: number;
5
5
  constructor(props: any);
6
6
  componentDidMount(): void;
7
7
  componentDidUpdate(): void;
8
- render(): JSX.Element | null;
8
+ render(): import("react/jsx-runtime").JSX.Element | null;
9
9
  }
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
- declare function PrimitiveProp({ children }: any): JSX.Element;
1
+ declare function PrimitiveProp({ children }: any): import("react/jsx-runtime").JSX.Element;
3
2
  export default PrimitiveProp;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
- declare function Text({ value, children, ...props }: any): JSX.Element;
1
+ declare function Text({ value, children, ...props }: any): import("react/jsx-runtime").JSX.Element;
3
2
  export default Text;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
- declare function Undefined(props: any): JSX.Element;
1
+ declare function Undefined(props: any): import("react/jsx-runtime").JSX.Element;
3
2
  export default Undefined;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
- declare function View(props: any): JSX.Element;
1
+ declare function View(props: any): import("react/jsx-runtime").JSX.Element;
3
2
  export default View;
@@ -1,6 +1,5 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
4
- export declare const TableTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
5
- export declare const InputTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
3
+ export declare const TableTest: ComponentStory<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
4
+ export declare const InputTest: ComponentStory<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
6
5
  export default JsonUIStory;
@@ -1,5 +1,4 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
4
- export declare const MultiChild: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
3
+ export declare const MultiChild: ComponentStory<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
5
4
  export default JsonUIStory;
@@ -1,5 +1,4 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("../../types").ViewerProps) => JSX.Element>;
4
- export declare const PartialValueUpdateTest: ComponentStory<(props: import("../../types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("../../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
3
+ export declare const PartialValueUpdateTest: ComponentStory<(props: import("../../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
5
4
  export default JsonUIStory;
@@ -1,5 +1,4 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
4
3
  export declare const InputTest: ComponentStory<any>;
5
4
  export default JsonUIStory;
@@ -1,5 +1,4 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
4
3
  export declare const BoxTest: ComponentStory<any>;
5
4
  export default JsonUIStory;
@@ -1,6 +1,5 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
4
- export declare const TwoEditAnd1Modifier: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
5
- export declare const PathModifierTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
3
+ export declare const TwoEditAnd1Modifier: ComponentStory<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
4
+ export declare const PathModifierTest: ComponentStory<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
6
5
  export default JsonUIStory;
@@ -1,5 +1,4 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
4
- export declare const PrimitivesTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
3
+ export declare const PrimitivesTest: ComponentStory<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
5
4
  export default JsonUIStory;
@@ -1,5 +1,4 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("types").ViewerProps) => JSX.Element>;
4
- export declare const StoreStateTest: ComponentStory<(props: import("types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
3
+ export declare const StoreStateTest: ComponentStory<(props: import("types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
5
4
  export default JsonUIStory;
@@ -1,5 +1,4 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
4
- export declare const TableTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
3
+ export declare const TableTest: ComponentStory<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
5
4
  export default JsonUIStory;
@@ -1,7 +1,6 @@
1
- /// <reference types="react" />
2
1
  import { ComponentStory, ComponentMeta } from '@storybook/react';
3
- declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
4
- export declare const ValidationTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
2
+ declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
3
+ export declare const ValidationTest: ComponentStory<(props: import("../types").ViewerProps) => import("react/jsx-runtime").JSX.Element>;
5
4
  export default JsonUIStory;
6
5
  /**
7
6
  * TODO: