@socotra/ec-react-components 2.16.0 → 2.16.1-demo.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.
package/dist/index.d.ts CHANGED
@@ -15,6 +15,7 @@ import { ElementConfig } from '@socotra/ec-react-schemas';
15
15
  import { ElementRequest } from '@socotra/ec-react-schemas';
16
16
  import { ElementResponse } from '@socotra/ec-react-schemas';
17
17
  import { EvaluateConstraintsRequest } from '@socotra/ec-react-schemas';
18
+ import { ForwardRefExoticComponent } from 'react';
18
19
  import { JSX as JSX_2 } from 'react/jsx-runtime';
19
20
  import { ModifyChangeInstructionCreateRequest } from '@socotra/ec-react-schemas';
20
21
  import { ModifyChangeInstructionResponse } from '@socotra/ec-react-schemas';
@@ -27,8 +28,10 @@ import { ProductConfig } from '@socotra/ec-react-schemas';
27
28
  import { QuoteDependencyMapResponse } from '@socotra/ec-react-schemas';
28
29
  import { QuoteRequest } from '@socotra/ec-react-schemas';
29
30
  import { QuoteResponse } from '@socotra/ec-react-schemas';
31
+ import { RefAttributes } from 'react';
30
32
  import { ReversalTypeConfigRecord } from '@socotra/ec-react-schemas';
31
33
  import { SegmentResponse } from '@socotra/ec-react-schemas';
34
+ import { StyleDef } from '@jsonforms/vanilla-renderers';
32
35
  import { TransactionMethodEnum } from '@socotra/ec-react-schemas';
33
36
  import { TransactionSnapshotResponse } from '@socotra/ec-react-schemas';
34
37
 
@@ -257,10 +260,6 @@ declare type Props_2 = {
257
260
  * The resolved data model retrieved from data model response
258
261
  */
259
262
  dataModel: DataModel;
260
- /**
261
- * The custom data types for the configuration that may be referenced by the elementModel
262
- */
263
- dataTypes?: DataTypeConfigRecord;
264
263
  /**
265
264
  * The function to call when the form is submitted. It will create an QuoteRequest from the form data.
266
265
  */
@@ -355,6 +354,13 @@ declare type Props_2 = {
355
354
  * The hidden exception for the form
356
355
  */
357
356
  hiddenExceptions?: string[];
357
+ /**
358
+ * Custom form styling
359
+ * See https://github.com/eclipsesource/jsonforms/blob/master/packages/vanilla-renderers/Styles.md
360
+ */
361
+ styleContext?: {
362
+ styles: StyleDef[];
363
+ };
358
364
  /**
359
365
  * Titles for the form
360
366
  */
@@ -877,9 +883,11 @@ declare type Props_9 = {
877
883
  /**
878
884
  * QuoteForm is a form for updating a quote. It required a product data model, custom data types, and quote object to render the form.
879
885
  */
880
- export declare const QuoteForm: {
881
- ({ quote, dataModel, dataTypes, disabled, handleSubmit, isSubmitting, preventFormResetOnDisabled, validateOnSubmit, hideSubmitButton, hideDefaultFields, hideAdvancedFields, hideCoverageTerms, submitButtonText, id, titles, getEvaluatedConstraints, dependencyMap, hideAllFields, hiddenExceptions, }: Props_2): JSX_2.Element;
882
- displayName: string;
886
+ export declare const QuoteForm: ForwardRefExoticComponent<Props_2 & RefAttributes<QuoteFormRef>>;
887
+
888
+ export declare type QuoteFormRef = {
889
+ getValues: () => unknown;
890
+ subscribeOnChange: (field: string, callback: (value: unknown) => void) => () => void;
883
891
  };
884
892
 
885
893
  /**