diff --git a/src/controls/dynamicForm/dynamicField/DynamicField.tsx b/src/controls/dynamicForm/dynamicField/DynamicField.tsx index dc4deb6f4..c8b009d96 100644 --- a/src/controls/dynamicForm/dynamicField/DynamicField.tsx +++ b/src/controls/dynamicForm/dynamicField/DynamicField.tsx @@ -79,7 +79,8 @@ export class DynamicField extends React.Component { this.onChange(newValue, true); }} context={context} + orderBy={orderBy} /> {descriptionEl} {errorTextEl} @@ -283,8 +285,8 @@ export class DynamicField extends React.Component { this.onChange(newText); }} disabled={disabled} onBlur={this.onBlur} - errorMessage={errorText || customNumberErrorMessage} - min={minimumValue} + errorMessage={errorText || customNumberErrorMessage} + min={minimumValue} max={maximumValue} /> {descriptionEl} ; @@ -306,8 +308,8 @@ export class DynamicField extends React.Component { this.onChange(newText); }} disabled={disabled} onBlur={this.onBlur} - errorMessage={errorText || customNumberErrorMessage} - min={minimumValue} + errorMessage={errorText || customNumberErrorMessage} + min={minimumValue} max={maximumValue} /> {descriptionEl} ; @@ -687,7 +689,7 @@ export class DynamicField extends React.Component void; // eslint-disable-line @typescript-eslint/no-explicit-any + onChanged?: ( + columnInternalName: string, + newValue: any, + validate: boolean, + additionalData?: FieldChangeAdditionalData + ) => void; // eslint-disable-line @typescript-eslint/no-explicit-any /** Represents the value of the field as updated by the user. Only updated by fields when changed. */ newValue?: any; // eslint-disable-line @typescript-eslint/no-explicit-any - + /** Represents a stringified value of the field. Used in custom formatting and validation. */ stringValue: any; // eslint-disable-line @typescript-eslint/no-explicit-any @@ -50,7 +55,7 @@ export interface IDynamicFieldProps { /** If validation raises an error message, it can be stored against the field here for display by DynamicField */ validationErrorMessage?: string; - + /** Field Term Set ID, used in Taxonomy / Metadata fields */ fieldTermSetId?: string; @@ -64,16 +69,16 @@ export interface IDynamicFieldProps { lookupField?: string; // changedValue: any; // eslint-disable-line @typescript-eslint/no-explicit-any - + /** Equivalent to HiddenListInternalName, used for Taxonomy Metadata fields */ hiddenFieldName?: string; - + /** Order of the field in the form */ Order: number; - + /** Used for files / image uploads */ additionalData?: FieldChangeAdditionalData; - + // Related to various field types options?: IDropdownOption[]; isRichText?: boolean; @@ -84,4 +89,5 @@ export interface IDynamicFieldProps { maximumValue?: number; minimumValue?: number; showAsPercentage?: boolean; + orderBy?: string; }