@chamn/engine 0.0.18 → 0.0.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/README.md CHANGED
@@ -1,12 +1,10 @@
1
1
  # chameleon
2
2
 
3
- > "Chameleon", suitable for all environments
3
+ > Chameleon is ever-changing
4
4
 
5
- A streamlined low-code engine, all modules support custom extensions, which can be used for web page generation and rendering. Applicable to a variety of business scenarios, PC Page, H5 Page etc
5
+ A web visual programming engine, help to build a web page with 5 minutes. every people can use it easy.
6
6
 
7
- ## [Document](https://hlerenow.github.io/chameleon/documents/)
8
-
9
- ## [Demo](https://hlerenow.github.io/chameleon/)
7
+ [Docs](https://hlerenow.github.io/chameleon/documents/) | [Demo](https://hlerenow.github.io/chameleon/)
10
8
 
11
9
  ## Install
12
10
 
@@ -1,4 +1,7 @@
1
1
  /// <reference types="react" />
2
+ export declare const defaultPropertyOptions: {
3
+ value: string;
4
+ }[];
2
5
  export type SinglePropertyEditorProps = {
3
6
  mode: 'create' | 'edit';
4
7
  value: {
@@ -19,7 +22,7 @@ export type SinglePropertyEditorProps = {
19
22
  }) => void;
20
23
  onDelete?: () => void;
21
24
  };
22
- type SinglePropertyEditorRef = {
25
+ export type SinglePropertyEditorRef = {
23
26
  reset: () => void;
24
27
  };
25
28
  export declare const SinglePropertyEditor: import("react").ForwardRefExoticComponent<SinglePropertyEditorProps & import("react").RefAttributes<SinglePropertyEditorRef>>;
@@ -40,4 +43,3 @@ export type CSSPropertiesEditorRef = {
40
43
  }[]) => void;
41
44
  };
42
45
  export declare const CSSPropertiesEditor: import("react").ForwardRefExoticComponent<CSSPropertiesEditorProps & import("react").RefAttributes<CSSPropertiesEditorRef>>;
43
- export {};
@@ -1,6 +1,6 @@
1
1
  /// <reference types="react" />
2
2
  import { JSExpressionPropType } from '@chamn/model';
3
- export type SinglePropertyEditorProps = {
3
+ export type InnerSinglePropertyEditorProps = {
4
4
  value?: {
5
5
  key: string;
6
6
  value: JSExpressionPropType;
@@ -18,6 +18,9 @@ export type SinglePropertyEditorProps = {
18
18
  } | void;
19
19
  mod?: 'create' | 'edit';
20
20
  };
21
+ export type InnerSinglePropertyEditorRef = {
22
+ reset: () => void;
23
+ };
21
24
  export type CSSPropertiesVariableBindEditorProps = {
22
25
  initialValue?: {
23
26
  key: string;
@@ -1,3 +1,4 @@
1
1
  import { CSetter } from './type';
2
2
  declare const _default: Record<string, CSetter<any>>;
3
3
  export default _default;
4
+ export * from './type';
@@ -18,3 +18,5 @@ export type CustomSchemaFormProps = {
18
18
  customSetterMap?: CFormContextData['customSetterMap'];
19
19
  };
20
20
  export declare const CustomSchemaForm: React.ForwardRefExoticComponent<CustomSchemaFormProps & React.RefAttributes<CForm>>;
21
+ export * from './components/SetterSwitcher';
22
+ export * from './components/Setters';
@@ -1,15 +1,14 @@
1
1
  /// <reference types="react" />
2
- import * as monaco from 'monaco-editor';
3
- import * as monacoEditor from 'monaco-editor/esm/vs/editor/editor.api';
4
- export type MonacoEditorInstance = monacoEditor.editor.IStandaloneCodeEditor;
2
+ import { EditorProps, Monaco } from '@monaco-editor/react';
3
+ type EditorType = EditorProps;
4
+ export type MonacoEditorInstance = Parameters<Required<EditorType>['onMount']>[0];
5
5
  export type MonacoEditorProps = {
6
- beforeMount?: (monaco: typeof monacoEditor) => void;
6
+ beforeMount?: (monaco: Monaco) => void;
7
7
  onDidMount?: (editor: MonacoEditorInstance) => void;
8
- options?: monaco.editor.IStandaloneEditorConstructionOptions;
9
- override?: monaco.editor.IEditorOverrideServices;
10
- onChange?: (val: string, e: monaco.editor.IModelContentChangedEvent) => void;
11
- onDidChangeMarkers?: (markers: monaco.editor.IMarker[]) => void;
8
+ options?: EditorType['options'];
9
+ onChange?: EditorType['onChange'];
12
10
  initialValue?: string;
13
11
  language?: 'json' | 'javascript' | 'typescript';
14
12
  };
15
13
  export declare const MonacoEditor: (props: MonacoEditorProps) => JSX.Element;
14
+ export {};
package/dist/index.d.ts CHANGED
@@ -48,3 +48,4 @@ export * as plugins from './plugins';
48
48
  export * from '@chamn/layout';
49
49
  export * from './material/innerMaterial';
50
50
  export * from './component/CustomSchemaForm/components/Setters/type';
51
+ export * from './utils/index';