@mcurros2/microm 1.1.391-0 → 1.1.392-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 +118 -17
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +732 -507
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -500,6 +500,7 @@ export interface StepperFormStep {
|
|
|
500
500
|
nextStepLabel?: string;
|
|
501
501
|
nextStepValidLabel?: string;
|
|
502
502
|
nextStepValidation?: () => boolean | Promise<boolean>;
|
|
503
|
+
allowStepSelect?: boolean;
|
|
503
504
|
icon?: ReactNode;
|
|
504
505
|
}
|
|
505
506
|
export interface StepperFormProps extends EntityFormProps {
|
|
@@ -509,7 +510,6 @@ export interface StepperFormProps extends EntityFormProps {
|
|
|
509
510
|
initialStep: number;
|
|
510
511
|
nextStepLabel?: string;
|
|
511
512
|
prevStepLabel?: string;
|
|
512
|
-
allowStepClickForward?: boolean;
|
|
513
513
|
completedContent?: ReactNode;
|
|
514
514
|
hideNextAndBackWhenCompleted?: boolean;
|
|
515
515
|
onCompleted?: () => void;
|
|
@@ -1634,6 +1634,11 @@ export interface ParsedImportFile {
|
|
|
1634
1634
|
export function getImportFileExtension(file: File): string;
|
|
1635
1635
|
export function parseCSVRows(text: string): string[][];
|
|
1636
1636
|
export function parseImportFile(file: File): Promise<ParsedImportFile>;
|
|
1637
|
+
export interface ImportDataMappingRow {
|
|
1638
|
+
SourceHeader: string;
|
|
1639
|
+
SourceIndex: number;
|
|
1640
|
+
DestinationColumnName: string | null;
|
|
1641
|
+
}
|
|
1637
1642
|
export interface ImportDataMappingState {
|
|
1638
1643
|
mapping: FileImportMapping;
|
|
1639
1644
|
initialRow: number;
|
|
@@ -1644,13 +1649,34 @@ export interface ImportDataMappingState {
|
|
|
1644
1649
|
ignoredSourceColumns: string[];
|
|
1645
1650
|
omittedRequiredDestinations: string[];
|
|
1646
1651
|
}
|
|
1647
|
-
export interface
|
|
1648
|
-
file: File;
|
|
1652
|
+
export interface UseImportDataMappingProps {
|
|
1649
1653
|
destinations: readonly string[];
|
|
1650
1654
|
requiredDestinations: readonly string[];
|
|
1651
|
-
onChange: (state: ImportDataMappingState | undefined) => void;
|
|
1652
1655
|
initialRow?: number;
|
|
1653
1656
|
sampleRowCount?: number;
|
|
1657
|
+
fileErrorLabel?: string;
|
|
1658
|
+
}
|
|
1659
|
+
export interface ImportDataMappingAPI {
|
|
1660
|
+
parsedFile?: ParsedImportFile;
|
|
1661
|
+
sheetName: string;
|
|
1662
|
+
headerRow: number;
|
|
1663
|
+
mappingRows: ImportDataMappingRow[];
|
|
1664
|
+
sampleRows: string[][];
|
|
1665
|
+
mappingState?: ImportDataMappingState;
|
|
1666
|
+
loading: boolean;
|
|
1667
|
+
error?: string;
|
|
1668
|
+
revision: number;
|
|
1669
|
+
loadFile: (file: File) => Promise<void>;
|
|
1670
|
+
reset: () => void;
|
|
1671
|
+
selectSheet: (sheetName: string) => void;
|
|
1672
|
+
selectHeaderRow: (headerRow: number) => void;
|
|
1673
|
+
updateMappingRow: (rowIndex: number, destination: string | null) => void;
|
|
1674
|
+
}
|
|
1675
|
+
export function getImportSourceColumnLabel(row: ImportDataMappingRow): string;
|
|
1676
|
+
export function useImportDataMapping({ destinations, requiredDestinations, initialRow, sampleRowCount, fileErrorLabel }: UseImportDataMappingProps): ImportDataMappingAPI;
|
|
1677
|
+
export interface ImportDataMappingEditorProps {
|
|
1678
|
+
mappingAPI: ImportDataMappingAPI;
|
|
1679
|
+
destinations: readonly string[];
|
|
1654
1680
|
worksheetLabel?: string;
|
|
1655
1681
|
initialRowLabel?: string;
|
|
1656
1682
|
sourceHeaderLabel?: string;
|
|
@@ -1659,10 +1685,7 @@ export interface ImportDataMappingEditorProps {
|
|
|
1659
1685
|
mappingCorrectLabel?: string;
|
|
1660
1686
|
mappingReviewLabel?: string;
|
|
1661
1687
|
editMappedColumnsLabel?: string;
|
|
1662
|
-
viewSampleDataLabel?: string;
|
|
1663
|
-
noSampleDataLabel?: string;
|
|
1664
1688
|
noDestinationsLabel?: string;
|
|
1665
|
-
fileErrorLabel?: string;
|
|
1666
1689
|
}
|
|
1667
1690
|
export const ImportDataMappingEditorDefaultProps: Partial<ImportDataMappingEditorProps>;
|
|
1668
1691
|
export function ImportDataMappingEditor(props: ImportDataMappingEditorProps): JSX.Element | null;
|
|
@@ -1739,16 +1762,6 @@ export class ImportEntityDataDef extends EntityDefinition {
|
|
|
1739
1762
|
};
|
|
1740
1763
|
constructor();
|
|
1741
1764
|
}
|
|
1742
|
-
export interface CircleFilledIconProps {
|
|
1743
|
-
backColor?: MantineColor;
|
|
1744
|
-
color?: MantineColor;
|
|
1745
|
-
width?: string | number;
|
|
1746
|
-
minWidth?: string | number;
|
|
1747
|
-
icon: ReactNode;
|
|
1748
|
-
mr?: string;
|
|
1749
|
-
}
|
|
1750
|
-
export const CircleFilledIconDefaultProps: Partial<CircleFilledIconProps>;
|
|
1751
|
-
export const CircleFilledIcon: ForwardRefExoticComponent<CircleFilledIconProps & RefAttributes<HTMLInputElement>>;
|
|
1752
1765
|
export interface ImageCropOptions {
|
|
1753
1766
|
aspectRatio?: number;
|
|
1754
1767
|
}
|
|
@@ -2017,6 +2030,87 @@ export interface ModalFileUploadProps {
|
|
|
2017
2030
|
}
|
|
2018
2031
|
export const UseFileUploadFormOpenDefaultProps: Partial<ModalFileUploadProps>;
|
|
2019
2032
|
export function useFilesUploadForm(): (props: ModalFileUploadProps) => Promise<void>;
|
|
2033
|
+
export interface CircleFilledIconProps {
|
|
2034
|
+
backColor?: MantineColor;
|
|
2035
|
+
color?: MantineColor;
|
|
2036
|
+
width?: string | number;
|
|
2037
|
+
minWidth?: string | number;
|
|
2038
|
+
icon: ReactNode;
|
|
2039
|
+
mr?: string;
|
|
2040
|
+
}
|
|
2041
|
+
export const CircleFilledIconDefaultProps: Partial<CircleFilledIconProps>;
|
|
2042
|
+
export const CircleFilledIcon: ForwardRefExoticComponent<CircleFilledIconProps & RefAttributes<HTMLInputElement>>;
|
|
2043
|
+
export interface ImportCompletedContentProps {
|
|
2044
|
+
fileName: string;
|
|
2045
|
+
result: ImpDataResult;
|
|
2046
|
+
onClose?: () => void | Promise<void>;
|
|
2047
|
+
importedFileLabel?: string;
|
|
2048
|
+
recordsImportedSuccessfullyLabel?: string;
|
|
2049
|
+
recordsNotImportedDueToErrorsLabel?: string;
|
|
2050
|
+
errorColumnTitle?: string;
|
|
2051
|
+
rowColumnTitle?: string;
|
|
2052
|
+
closeLabel?: ReactNode;
|
|
2053
|
+
}
|
|
2054
|
+
export const ImportCompletedContentDefaultProps: Partial<ImportCompletedContentProps>;
|
|
2055
|
+
export function ImportCompletedContent(props: ImportCompletedContentProps): JSX.Element;
|
|
2056
|
+
export interface ImportDataMappingStepProps {
|
|
2057
|
+
mappingAPI: ImportDataMappingAPI;
|
|
2058
|
+
destinations: readonly string[];
|
|
2059
|
+
validationError?: string;
|
|
2060
|
+
}
|
|
2061
|
+
export const ImportDataMappingStepDefaultProps: Partial<ImportDataMappingStepProps>;
|
|
2062
|
+
export function ImportDataMappingStep(props: ImportDataMappingStepProps): JSX.Element;
|
|
2063
|
+
export interface ImportFileStepProps {
|
|
2064
|
+
entity: ImportEntityData;
|
|
2065
|
+
disabled?: boolean;
|
|
2066
|
+
validationError?: string;
|
|
2067
|
+
onValidateFile: (file: File) => Promise<ValidateFileReturnType>;
|
|
2068
|
+
onDelete: (fileGUID: string) => boolean | Promise<boolean>;
|
|
2069
|
+
onUploadComplete: (report: UploadProgressReport) => Promise<UploadCompletionResult | void>;
|
|
2070
|
+
}
|
|
2071
|
+
export function ImportFileStep({ entity, disabled, validationError, onValidateFile, onDelete, onUploadComplete }: ImportFileStepProps): JSX.Element;
|
|
2072
|
+
export interface ImportInstructionsStepProps {
|
|
2073
|
+
importEntity?: Entity<EntityDefinition>;
|
|
2074
|
+
requiredColumns: readonly string[];
|
|
2075
|
+
instructionsLabel?: string;
|
|
2076
|
+
columnHeaderLabel?: string;
|
|
2077
|
+
dataNameLabel?: string;
|
|
2078
|
+
dataTypeLabel?: string;
|
|
2079
|
+
contentLabel?: string;
|
|
2080
|
+
dateFormatLabel?: string;
|
|
2081
|
+
numberFormatLabel?: string;
|
|
2082
|
+
downloadExcelSampleLabel?: string;
|
|
2083
|
+
downloadCSVSampleLabel?: string;
|
|
2084
|
+
}
|
|
2085
|
+
export function getFriendlyImportDataType(type: SQLType): "Integer" | "Number" | "Date" | "Alphanumeric";
|
|
2086
|
+
export function ImportInstructionsStep({ importEntity, requiredColumns, instructionsLabel, columnHeaderLabel, dataNameLabel, dataTypeLabel, contentLabel, dateFormatLabel, numberFormatLabel, downloadExcelSampleLabel, downloadCSVSampleLabel }: ImportInstructionsStepProps): JSX.Element;
|
|
2087
|
+
export interface ImportSampleDataStepProps {
|
|
2088
|
+
mappingAPI: ImportDataMappingAPI;
|
|
2089
|
+
confirmationLabel?: string;
|
|
2090
|
+
noSampleDataLabel?: string;
|
|
2091
|
+
}
|
|
2092
|
+
export const ImportSampleDataStepDefaultProps: Partial<ImportSampleDataStepProps>;
|
|
2093
|
+
export function ImportSampleDataStep(props: ImportSampleDataStepProps): JSX.Element;
|
|
2094
|
+
export interface ImportSummaryStepProps {
|
|
2095
|
+
file: File | null;
|
|
2096
|
+
mappingState?: ImportDataMappingState;
|
|
2097
|
+
importStatus?: OperationStatus<ImpDataResult>;
|
|
2098
|
+
summaryTitleLabel?: string;
|
|
2099
|
+
fileLabel?: string;
|
|
2100
|
+
formatLabel?: string;
|
|
2101
|
+
unknownFormatLabel?: string;
|
|
2102
|
+
worksheetLabel?: string;
|
|
2103
|
+
headerRowLabel?: string;
|
|
2104
|
+
mappedColumnsLabel?: string;
|
|
2105
|
+
ofLabel?: string;
|
|
2106
|
+
ignoredSourceColumnsLabel?: string;
|
|
2107
|
+
omittedRequiredColumnsLabel?: string;
|
|
2108
|
+
noneLabel?: string;
|
|
2109
|
+
submitAndImportLabel?: string;
|
|
2110
|
+
importingDataLabel?: string;
|
|
2111
|
+
}
|
|
2112
|
+
export const ImportSummaryStepDefaultProps: Partial<ImportSummaryStepProps>;
|
|
2113
|
+
export function ImportSummaryStep(props: ImportSummaryStepProps): JSX.Element | null;
|
|
2020
2114
|
export interface ImportEntityDataFormProps extends FormOptions<ImportEntityData> {
|
|
2021
2115
|
importEntity?: Entity<EntityDefinition>;
|
|
2022
2116
|
entityProcName?: string;
|
|
@@ -2026,6 +2120,10 @@ export interface ImportEntityDataFormProps extends FormOptions<ImportEntityData>
|
|
|
2026
2120
|
instructionsStepDescription?: string;
|
|
2027
2121
|
uploadStepLabel?: string;
|
|
2028
2122
|
uploadStepDescription?: string;
|
|
2123
|
+
dataMappingStepLabel?: string;
|
|
2124
|
+
dataMappingStepDescription?: string;
|
|
2125
|
+
sampleDataStepLabel?: string;
|
|
2126
|
+
sampleDataStepDescription?: string;
|
|
2029
2127
|
summaryStepLabel?: string;
|
|
2030
2128
|
summaryStepDescription?: string;
|
|
2031
2129
|
instructionsLabel?: string;
|
|
@@ -2041,7 +2139,10 @@ export interface ImportEntityDataFormProps extends FormOptions<ImportEntityData>
|
|
|
2041
2139
|
emptyFileLabel?: string;
|
|
2042
2140
|
uploadRequiredLabel?: string;
|
|
2043
2141
|
mappingRequiredLabel?: string;
|
|
2142
|
+
confirmDataMappingLabel?: string;
|
|
2044
2143
|
importButtonLabel?: string;
|
|
2144
|
+
submitAndImportLabel?: string;
|
|
2145
|
+
importingDataLabel?: string;
|
|
2045
2146
|
importedFileLabel?: string;
|
|
2046
2147
|
recordsImportedSuccessfullyLabel?: string;
|
|
2047
2148
|
recordsNotImportedDueToErrorsLabel?: string;
|