jamespot-react-components 1.0.206 → 1.0.208
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/build/jamespot-react-components.js +1100 -989
- package/build/jamespot-react-components.js.map +1 -1
- package/build/src/components/Drives/MicrosoftGraph/App365AccessDenied.d.ts +3 -0
- package/build/src/components/Drives/MicrosoftGraph/App365Account.d.ts +17 -0
- package/build/src/components/Drives/MicrosoftGraph/App365Documents.d.ts +20 -0
- package/build/src/components/Drives/MicrosoftGraph/App365Groups.d.ts +19 -0
- package/build/src/components/Drives/MicrosoftGraph/App365IsEmpty.d.ts +3 -0
- package/build/src/components/Drives/MicrosoftGraph/App365Tenants.d.ts +9 -0
- package/build/src/components/Drives/MicrosoftGraph/JRCApp365.d.ts +30 -0
- package/build/src/components/Drives/MicrosoftGraph/components/EntityAvarar.d.ts +6 -0
- package/build/src/components/Drives/MicrosoftGraph/components/EntityItem.d.ts +14 -0
- package/build/src/components/Drives/MicrosoftGraph/components/EntityItemSelection.d.ts +5 -0
- package/build/src/components/Drives/MicrosoftGraph/components/EntityItemTitle.d.ts +10 -0
- package/build/src/components/Drives/MicrosoftGraph/components/TenantEntityItem.d.ts +7 -0
- package/build/src/components/Drives/components/DriveFiltererList.d.ts +60 -0
- package/build/src/components/Drives/components/DriveItem.d.ts +7 -0
- package/build/src/components/Drives/drive.const.d.ts +2 -0
- package/build/src/components/Drives/drive.style.d.ts +3 -0
- package/build/src/components/Drives/hooks.d.ts +40 -0
- package/build/src/components/Editors/components/EditorUploader.d.ts +3 -2
- package/build/src/components/Form/Input/JRCInputFileAdvanced/JRCInputFileAdvancedRaw.d.ts +14 -2
- package/build/src/components/JRCCommentsBloc/JRCComment.d.ts +18 -3
- package/build/src/components/JRCCommentsBloc/JRCCommentsBloc.d.ts +14 -2
- package/build/src/components/JRCFolders/types.d.ts +9 -3
- package/build/src/components/Widgets/JRCWidgetArticleText/JRCWidgetArticleText.stories.d.ts +1 -0
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetDatasourceTableEditor.d.ts +18 -5
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetDatasourceTableEditor.styles.d.ts +5 -0
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetExcelDatasourceTableEditor.d.ts +58 -2
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetTable.d.ts +2 -2
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetTable.stories.d.ts +28 -1
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetTable.styles.d.ts +2 -1
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetTableSharedEditor.d.ts +3 -0
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetTableTdRenderer.d.ts +2 -1
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetTableTdRendererText.d.ts +15 -0
- package/build/src/components/Widgets/JRCWidgetTable/components/ModalColumnLabelize.d.ts +2 -1
- package/build/src/components/Widgets/JRCWidgetTable/components/WidgetDatasourceModelView.d.ts +3 -1
- package/build/src/components/Widgets/JRCWidgetTable/components/WidgetDatasourceModelViewChanges.d.ts +10 -0
- package/build/src/components/Widgets/JRCWidgetTable/components/WidgetDatasourceModelViewColumnAction.d.ts +17 -0
- package/build/src/components/Widgets/JRCWidgetTable/const.d.ts +3 -1
- package/build/src/components/Widgets/JRCWidgetTable/model/doc/DocEditor.d.ts +3 -22
- package/build/src/components/Widgets/JRCWidgetTable/model/doc/DocEditorObject.d.ts +2 -3
- package/build/src/components/Widgets/JRCWidgetTable/model/excel/ExcelEditor.d.ts +3 -22
- package/build/src/components/Widgets/JRCWidgetTable/model/excel/ExcelEditorBrokenModel.d.ts +4 -0
- package/build/src/components/Widgets/JRCWidgetTable/model/excel/ExcelEditorModel.d.ts +3 -22
- package/build/src/components/Widgets/JRCWidgetTable/model/excel/ExcelEditorObject.d.ts +3 -5
- package/build/src/components/Widgets/JRCWidgetTable/model/excel/ExcelEditorSelectDocument.d.ts +4 -0
- package/build/src/components/Widgets/JRCWidgetTable/model/excel/ExcelEditorSelectWedocFile.d.ts +4 -0
- package/build/src/components/Widgets/JRCWidgetTable/model/excel/ExcelEditorSpreadSheets.d.ts +4 -23
- package/build/src/components/Widgets/JRCWidgetTable/model/excel/ExcelEditorUploader.d.ts +2 -22
- package/build/src/components/Widgets/JRCWidgetTable/model/studio/StudioEditor.d.ts +3 -22
- package/build/src/components/Widgets/JRCWidgetTable/model/studio/StudioEditorApp.d.ts +1 -1
- package/build/src/components/Widgets/JRCWidgetTable/model/studio/StudioEditorFetch.d.ts +1 -2
- package/build/src/components/Widgets/JRCWidgetTable/model/studio/StudioEditorObject.d.ts +2 -3
- package/build/src/components/Widgets/JRCWidgetTable/pagination.d.ts +0 -2
- package/build/src/components/Widgets/JRCWidgetTable/utils.d.ts +18 -1
- package/build/src/components/Widgets/context/hooks.d.ts +114 -0
- package/build/src/components/Widgets/context/provider.d.ts +26 -0
- package/build/src/components/api/jamespot/mock_jamespot.d.ts +15 -0
- package/build/src/components/api/jamespot/mocks/application/application.d.ts +9 -0
- package/build/src/components/api/jamespot/mocks/datasource/datasource.d.ts +14 -0
- package/build/src/components/api/jamespot/mocks/file/file.d.ts +3 -0
- package/build/src/components/api/jamespot/mocks/network/network.d.ts +6 -0
- package/build/src/index.d.ts +1 -0
- package/build/src/styles/theme.d.ts +7 -0
- package/build/src/utils/utils.array.d.ts +1 -0
- package/package.json +2 -2
- package/build/src/components/Widgets/JRCWidgetTable/JRCWidgetTablePagination.d.ts +0 -9
- package/build/src/components/Widgets/JRCWidgetTable/components/ModalColumnDateFormat.d.ts +0 -7
- package/build/src/components/Widgets/JRCWidgetTable/components/WidgetDatasourceModelDiff.d.ts +0 -2
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { WidgetDatasourceValues, WidgetTableColumnsData } from 'jamespot-user-api';
|
|
3
|
+
export declare const JRCWidgetTableTdRendererText: ({ value, name, backgroundColor, tableColumnsData, }: {
|
|
4
|
+
name: string;
|
|
5
|
+
tableColumnsData: {
|
|
6
|
+
name?: string | undefined;
|
|
7
|
+
label?: string | undefined;
|
|
8
|
+
isVisible?: boolean | undefined;
|
|
9
|
+
textEllipsis?: boolean | undefined;
|
|
10
|
+
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
11
|
+
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
12
|
+
}[];
|
|
13
|
+
backgroundColor: string;
|
|
14
|
+
value: WidgetDatasourceValues;
|
|
15
|
+
}) => React.JSX.Element;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
export declare const ModalColumnLabelize: ({ title, onChange, onCloseHandler, }: {
|
|
2
|
+
export declare const ModalColumnLabelize: ({ title, initialValue, onChange, onCloseHandler, }: {
|
|
3
3
|
title: string;
|
|
4
|
+
initialValue?: string | undefined;
|
|
4
5
|
onChange: (label: string | undefined) => void;
|
|
5
6
|
onCloseHandler: () => void;
|
|
6
7
|
}) => React.JSX.Element;
|
package/build/src/components/Widgets/JRCWidgetTable/components/WidgetDatasourceModelView.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { WidgetTableColumn, WidgetTableColumnsData } from 'jamespot-user-api';
|
|
3
3
|
import { WidgetDatasourceTableContent } from 'jamespot-user-api';
|
|
4
|
-
export declare const WidgetDatasourceModelView: ({ model, tableColumnsData, onChange, }: {
|
|
4
|
+
export declare const WidgetDatasourceModelView: ({ model, excelHeaders, tableColumnsData, onChange, onUpdateModel, }: {
|
|
5
5
|
model: WidgetTableColumn[];
|
|
6
|
+
excelHeaders?: string[] | undefined;
|
|
6
7
|
tableColumnsData: {
|
|
7
8
|
name?: string | undefined;
|
|
8
9
|
label?: string | undefined;
|
|
@@ -12,4 +13,5 @@ export declare const WidgetDatasourceModelView: ({ model, tableColumnsData, onCh
|
|
|
12
13
|
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
13
14
|
}[];
|
|
14
15
|
onChange: (content: Partial<WidgetDatasourceTableContent>, override?: boolean) => void;
|
|
16
|
+
onUpdateModel?: ((model: WidgetTableColumn[]) => void) | undefined;
|
|
15
17
|
}) => React.JSX.Element;
|
package/build/src/components/Widgets/JRCWidgetTable/components/WidgetDatasourceModelViewChanges.d.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { WidgetTableColumn } from 'jamespot-user-api';
|
|
3
|
+
export declare const CSSAlert: import("styled-components").StyledComponent<"button", import("styled-components").DefaultTheme, {}, never>;
|
|
4
|
+
export declare const CSSWrapper: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
5
|
+
export declare const CSSModel: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
6
|
+
export declare const WidgetDatasourceModelViewChanges: ({ model, excelHeaders, onChange, }: {
|
|
7
|
+
model: WidgetTableColumn[];
|
|
8
|
+
excelHeaders: string[] | undefined;
|
|
9
|
+
onChange: (model: WidgetTableColumn[]) => void;
|
|
10
|
+
}) => React.JSX.Element;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { WidgetTableColumnData, WidgetTableColumnsData, WidgetTableColumnTypes } from 'jamespot-user-api';
|
|
3
|
+
import { WidgetDatasourceTableContent } from 'jamespot-user-api';
|
|
4
|
+
export declare const WidgetDatasourceModelViewColumnAction: ({ type, tableColumnsData, item, handleEditLabel, onChange, }: {
|
|
5
|
+
type: WidgetTableColumnTypes;
|
|
6
|
+
tableColumnsData: {
|
|
7
|
+
name?: string | undefined;
|
|
8
|
+
label?: string | undefined;
|
|
9
|
+
isVisible?: boolean | undefined;
|
|
10
|
+
textEllipsis?: boolean | undefined;
|
|
11
|
+
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
12
|
+
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
13
|
+
}[];
|
|
14
|
+
item: WidgetTableColumnData;
|
|
15
|
+
handleEditLabel: () => void;
|
|
16
|
+
onChange: (content: Partial<WidgetDatasourceTableContent>, override?: boolean) => void;
|
|
17
|
+
}) => React.JSX.Element;
|
|
@@ -4,8 +4,10 @@ export declare const SUPPORTED_ELLIPSIS_TYPE: string[];
|
|
|
4
4
|
export declare const SUPPORTED_LABELIZE_TYPE: string[];
|
|
5
5
|
export declare const SUPPORTED_DATE_FORMAT_TYPE: string[];
|
|
6
6
|
export declare const SUPPORTED_NUMBER_FORMAT_TYPE: string[];
|
|
7
|
+
export declare const SUPPORTED_MIMETYPES: string[];
|
|
7
8
|
export declare enum DATASOURCE_TYPE {
|
|
8
9
|
DOC = "doc",
|
|
9
10
|
STUDIO = "studio",
|
|
10
|
-
CALC = "calc"
|
|
11
|
+
CALC = "calc",
|
|
12
|
+
CALC_ATTACHMENT = "calc-attachment"
|
|
11
13
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { DatasourceModel, DatasourceType,
|
|
3
|
-
export declare const DocEditor: ({ uri, tableColumnsData, model, type,
|
|
2
|
+
import { DatasourceModel, DatasourceType, WidgetTableColumnsData } from 'jamespot-user-api';
|
|
3
|
+
export declare const DocEditor: ({ uri, tableColumnsData, model, type, }: {
|
|
4
4
|
uri?: string | undefined;
|
|
5
5
|
model?: DatasourceModel | undefined;
|
|
6
6
|
type?: DatasourceType | undefined;
|
|
@@ -12,23 +12,4 @@ export declare const DocEditor: ({ uri, tableColumnsData, model, type, onChange,
|
|
|
12
12
|
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
13
13
|
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
14
14
|
}[];
|
|
15
|
-
}
|
|
16
|
-
uri?: string | undefined;
|
|
17
|
-
limit?: number | boolean | undefined;
|
|
18
|
-
tableColumnsData?: {
|
|
19
|
-
name?: string | undefined;
|
|
20
|
-
label?: string | undefined;
|
|
21
|
-
isVisible?: boolean | undefined;
|
|
22
|
-
textEllipsis?: boolean | undefined;
|
|
23
|
-
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
24
|
-
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
25
|
-
}[] | undefined;
|
|
26
|
-
tableHeadColor?: string | undefined;
|
|
27
|
-
tableHeadTextColor?: string | undefined;
|
|
28
|
-
tableHeadIconColor?: string | undefined;
|
|
29
|
-
tableRowColor?: string | undefined;
|
|
30
|
-
tableRowTextColor?: string | undefined;
|
|
31
|
-
tableBorderRadius?: number | undefined;
|
|
32
|
-
tableSizedColumns?: boolean | undefined;
|
|
33
|
-
tableSizedColumnsWidth?: number | undefined;
|
|
34
|
-
}>, "onChange" | "onStateChange"> & WidgetEditorErrorActions) => React.JSX.Element;
|
|
15
|
+
}) => React.JSX.Element;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
export declare const DocEditorObject: ({ uri, onHandleRemove, onError, }: {
|
|
2
|
+
export declare const DocEditorObject: ({ uri, onHandleRemove }: {
|
|
4
3
|
uri: string;
|
|
5
4
|
onHandleRemove: () => void;
|
|
6
|
-
}
|
|
5
|
+
}) => React.JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
3
|
-
export declare const ExcelEditor: ({ uri, tableColumnsData
|
|
2
|
+
import { WidgetTableColumnsData } from 'jamespot-user-api';
|
|
3
|
+
export declare const ExcelEditor: ({ uri, tableColumnsData }: {
|
|
4
4
|
uri?: string | undefined;
|
|
5
5
|
tableColumnsData: {
|
|
6
6
|
name?: string | undefined;
|
|
@@ -10,23 +10,4 @@ export declare const ExcelEditor: ({ uri, tableColumnsData, onChange, onError, o
|
|
|
10
10
|
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
11
11
|
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
12
12
|
}[];
|
|
13
|
-
}
|
|
14
|
-
uri?: string | undefined;
|
|
15
|
-
limit?: number | boolean | undefined;
|
|
16
|
-
tableColumnsData?: {
|
|
17
|
-
name?: string | undefined;
|
|
18
|
-
label?: string | undefined;
|
|
19
|
-
isVisible?: boolean | undefined;
|
|
20
|
-
textEllipsis?: boolean | undefined;
|
|
21
|
-
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
22
|
-
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
23
|
-
}[] | undefined;
|
|
24
|
-
tableHeadColor?: string | undefined;
|
|
25
|
-
tableHeadTextColor?: string | undefined;
|
|
26
|
-
tableHeadIconColor?: string | undefined;
|
|
27
|
-
tableRowColor?: string | undefined;
|
|
28
|
-
tableRowTextColor?: string | undefined;
|
|
29
|
-
tableBorderRadius?: number | undefined;
|
|
30
|
-
tableSizedColumns?: boolean | undefined;
|
|
31
|
-
tableSizedColumnsWidth?: number | undefined;
|
|
32
|
-
}>, "onChange" | "onStateChange">) => React.JSX.Element;
|
|
13
|
+
}) => React.JSX.Element;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export declare const CSSAlert: import("styled-components").StyledComponent<"button", import("styled-components").DefaultTheme, {}, never>;
|
|
3
|
+
export declare const CSSWrapper: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
4
|
+
export declare const ExcelEditorBrokenModel: () => React.JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { DatasourceModel,
|
|
3
|
-
export declare const ExcelEditorModel: ({ uri, tableColumnsData, model,
|
|
2
|
+
import { DatasourceModel, WidgetTableColumnsData } from 'jamespot-user-api';
|
|
3
|
+
export declare const ExcelEditorModel: ({ uri, tableColumnsData, model, }: {
|
|
4
4
|
uri: string;
|
|
5
5
|
tableColumnsData: {
|
|
6
6
|
name?: string | undefined;
|
|
@@ -11,23 +11,4 @@ export declare const ExcelEditorModel: ({ uri, tableColumnsData, model, onChange
|
|
|
11
11
|
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
12
12
|
}[];
|
|
13
13
|
model: DatasourceModel;
|
|
14
|
-
}
|
|
15
|
-
uri?: string | undefined;
|
|
16
|
-
limit?: number | boolean | undefined;
|
|
17
|
-
tableColumnsData?: {
|
|
18
|
-
name?: string | undefined;
|
|
19
|
-
label?: string | undefined;
|
|
20
|
-
isVisible?: boolean | undefined;
|
|
21
|
-
textEllipsis?: boolean | undefined;
|
|
22
|
-
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
23
|
-
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
24
|
-
}[] | undefined;
|
|
25
|
-
tableHeadColor?: string | undefined;
|
|
26
|
-
tableHeadTextColor?: string | undefined;
|
|
27
|
-
tableHeadIconColor?: string | undefined;
|
|
28
|
-
tableRowColor?: string | undefined;
|
|
29
|
-
tableRowTextColor?: string | undefined;
|
|
30
|
-
tableBorderRadius?: number | undefined;
|
|
31
|
-
tableSizedColumns?: boolean | undefined;
|
|
32
|
-
tableSizedColumnsWidth?: number | undefined;
|
|
33
|
-
}>, "onChange" | "onStateChange"> & WidgetEditorErrorActions) => React.JSX.Element;
|
|
14
|
+
}) => React.JSX.Element;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
export declare const ExcelEditorObject: ({ uri, onHandleDatasource, onError, onHandleRemove, }: {
|
|
2
|
+
export declare const ExcelEditorObject: ({ uri, onHandleCancel }: {
|
|
4
3
|
uri: string;
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
} & WidgetEditorErrorActions) => React.JSX.Element;
|
|
4
|
+
onHandleCancel: () => void;
|
|
5
|
+
}) => React.JSX.Element;
|
package/build/src/components/Widgets/JRCWidgetTable/model/excel/ExcelEditorSpreadSheets.d.ts
CHANGED
|
@@ -1,25 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
export declare const ExcelEditorSpreadSheets: ({ uri, onChange, onCancel, onError, onStateChange, }: {
|
|
2
|
+
export declare const ExcelEditorSpreadSheets: ({ uri, onHandleCancel }: {
|
|
4
3
|
uri: string;
|
|
5
|
-
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
limit?: number | boolean | undefined;
|
|
9
|
-
tableColumnsData?: {
|
|
10
|
-
name?: string | undefined;
|
|
11
|
-
label?: string | undefined;
|
|
12
|
-
isVisible?: boolean | undefined;
|
|
13
|
-
textEllipsis?: boolean | undefined;
|
|
14
|
-
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
15
|
-
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
16
|
-
}[] | undefined;
|
|
17
|
-
tableHeadColor?: string | undefined;
|
|
18
|
-
tableHeadTextColor?: string | undefined;
|
|
19
|
-
tableHeadIconColor?: string | undefined;
|
|
20
|
-
tableRowColor?: string | undefined;
|
|
21
|
-
tableRowTextColor?: string | undefined;
|
|
22
|
-
tableBorderRadius?: number | undefined;
|
|
23
|
-
tableSizedColumns?: boolean | undefined;
|
|
24
|
-
tableSizedColumnsWidth?: number | undefined;
|
|
25
|
-
}>, "onChange" | "onStateChange">) => React.JSX.Element;
|
|
4
|
+
onHandleCancel: () => void;
|
|
5
|
+
}) => React.JSX.Element;
|
|
6
|
+
export declare function isValidSpreadsheet(spreadsheet: string, spreadsheetListHeader: Record<string, string[]>): boolean;
|
|
@@ -1,25 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
export declare const ExcelEditorUploader: ({ token, onCreateSuccess, onError, onStateChange, }: {
|
|
2
|
+
export declare const ExcelEditorUploader: ({ token, onCreateSuccess, }: {
|
|
4
3
|
token: string;
|
|
5
4
|
onCreateSuccess: (uri: string) => void;
|
|
6
|
-
}
|
|
7
|
-
uri?: string | undefined;
|
|
8
|
-
limit?: number | boolean | undefined;
|
|
9
|
-
tableColumnsData?: {
|
|
10
|
-
name?: string | undefined;
|
|
11
|
-
label?: string | undefined;
|
|
12
|
-
isVisible?: boolean | undefined;
|
|
13
|
-
textEllipsis?: boolean | undefined;
|
|
14
|
-
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
15
|
-
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
16
|
-
}[] | undefined;
|
|
17
|
-
tableHeadColor?: string | undefined;
|
|
18
|
-
tableHeadTextColor?: string | undefined;
|
|
19
|
-
tableHeadIconColor?: string | undefined;
|
|
20
|
-
tableRowColor?: string | undefined;
|
|
21
|
-
tableRowTextColor?: string | undefined;
|
|
22
|
-
tableBorderRadius?: number | undefined;
|
|
23
|
-
tableSizedColumns?: boolean | undefined;
|
|
24
|
-
tableSizedColumnsWidth?: number | undefined;
|
|
25
|
-
}>, "onStateChange">) => React.JSX.Element;
|
|
5
|
+
}) => React.JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { DatasourceModel, DatasourceType,
|
|
3
|
-
export declare const StudioEditor: ({ uri, tableColumnsData, model, type,
|
|
2
|
+
import { DatasourceModel, DatasourceType, WidgetTableColumnsData } from 'jamespot-user-api';
|
|
3
|
+
export declare const StudioEditor: ({ uri, tableColumnsData, model, type, }: {
|
|
4
4
|
uri?: string | undefined;
|
|
5
5
|
model?: DatasourceModel | undefined;
|
|
6
6
|
type?: DatasourceType | undefined;
|
|
@@ -12,23 +12,4 @@ export declare const StudioEditor: ({ uri, tableColumnsData, model, type, onChan
|
|
|
12
12
|
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
13
13
|
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
14
14
|
}[];
|
|
15
|
-
}
|
|
16
|
-
uri?: string | undefined;
|
|
17
|
-
limit?: number | boolean | undefined;
|
|
18
|
-
tableColumnsData?: {
|
|
19
|
-
name?: string | undefined;
|
|
20
|
-
label?: string | undefined;
|
|
21
|
-
isVisible?: boolean | undefined;
|
|
22
|
-
textEllipsis?: boolean | undefined;
|
|
23
|
-
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
24
|
-
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
25
|
-
}[] | undefined;
|
|
26
|
-
tableHeadColor?: string | undefined;
|
|
27
|
-
tableHeadTextColor?: string | undefined;
|
|
28
|
-
tableHeadIconColor?: string | undefined;
|
|
29
|
-
tableRowColor?: string | undefined;
|
|
30
|
-
tableRowTextColor?: string | undefined;
|
|
31
|
-
tableBorderRadius?: number | undefined;
|
|
32
|
-
tableSizedColumns?: boolean | undefined;
|
|
33
|
-
tableSizedColumnsWidth?: number | undefined;
|
|
34
|
-
}>, "onChange" | "onStateChange"> & WidgetEditorErrorActions) => React.JSX.Element;
|
|
15
|
+
}) => React.JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { StudioApplicationBase, StudioApplicationStatusEnumBased, WidgetEditorErrorActions } from 'jamespot-user-api';
|
|
3
|
-
export declare const StudioEditorApp: ({ idApp, status, onHandleSelection,
|
|
3
|
+
export declare const StudioEditorApp: ({ idApp, status, onHandleSelection, }: {
|
|
4
4
|
idApp: string;
|
|
5
5
|
status: StudioApplicationStatusEnumBased;
|
|
6
6
|
onHandleSelection: (app: StudioApplicationBase) => void;
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
export declare const StudioEditorFetch: ({ onChange, onStateChange, onError, }: Pick<WidgetEditorActions<WidgetDatasourceTableContent>, 'onChange' | 'onStateChange'> & WidgetEditorErrorActions) => React.JSX.Element;
|
|
2
|
+
export declare const StudioEditorFetch: () => React.JSX.Element;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
export declare const StudioEditorObject: ({ uri, onHandleRemove, onError, }: {
|
|
2
|
+
export declare const StudioEditorObject: ({ uri, onHandleRemove }: {
|
|
4
3
|
uri: string;
|
|
5
4
|
onHandleRemove: () => void;
|
|
6
|
-
}
|
|
5
|
+
}) => React.JSX.Element;
|
|
@@ -1,3 +1 @@
|
|
|
1
|
-
export declare function getPagination(total: number, limit: number): number[];
|
|
2
|
-
export declare function filterPagination(pagination: number[], page: number, range: number): number[];
|
|
3
1
|
export declare const paginate: <T extends {}[] = {}[]>(data: T, page: number, limit: number) => T[number][];
|
|
@@ -1,2 +1,19 @@
|
|
|
1
|
-
import { WidgetTableColumnsData } from 'jamespot-user-api';
|
|
1
|
+
import { WidgetTableColumn, WidgetTableColumnsData } from 'jamespot-user-api';
|
|
2
2
|
export declare function labelize(name: string, tableColumnsData: WidgetTableColumnsData, initialValue: string): string;
|
|
3
|
+
export declare function updateTableColumns(columns: WidgetTableColumn[], headers: string[]): {
|
|
4
|
+
type: "number" | "select" | "title" | "text" | "url" | "email" | "date" | "file" | "uri" | "datetime" | "transient";
|
|
5
|
+
name: string;
|
|
6
|
+
label: string;
|
|
7
|
+
widget: {} | {
|
|
8
|
+
type: "text";
|
|
9
|
+
} | {
|
|
10
|
+
options: {
|
|
11
|
+
value: string;
|
|
12
|
+
label: string;
|
|
13
|
+
}[];
|
|
14
|
+
type: "select";
|
|
15
|
+
} | {
|
|
16
|
+
type: "date";
|
|
17
|
+
};
|
|
18
|
+
sortable?: boolean | undefined;
|
|
19
|
+
}[];
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import { EditorBaseContext } from './provider';
|
|
2
|
+
export declare const useEditorContext: <T = EditorBaseContext<{
|
|
3
|
+
widgets?: import("jamespot-user-api").WidgetWrapperGeneric<({
|
|
4
|
+
layers?: string[] | undefined;
|
|
5
|
+
} & import("jamespot-user-api").WidgetArticleAttachmentType) | ({
|
|
6
|
+
layers?: string[] | undefined;
|
|
7
|
+
} & import("jamespot-user-api").WidgetArticleButtonType) | ({
|
|
8
|
+
layers?: string[] | undefined;
|
|
9
|
+
} & import("jamespot-user-api").WidgetArticleGalleryType) | ({
|
|
10
|
+
layers?: string[] | undefined;
|
|
11
|
+
} & import("jamespot-user-api").WidgetArticleImageType) | ({
|
|
12
|
+
layers?: string[] | undefined;
|
|
13
|
+
} & import("jamespot-user-api").WidgetArticleTitleType) | ({
|
|
14
|
+
layers?: string[] | undefined;
|
|
15
|
+
} & import("jamespot-user-api").WidgetArticleTextType) | ({
|
|
16
|
+
layers?: string[] | undefined;
|
|
17
|
+
} & import("jamespot-user-api").WidgetArticleSliderType) | ({
|
|
18
|
+
layers?: string[] | undefined;
|
|
19
|
+
} & import("jamespot-user-api").WidgetType<import("jamespot-user-api").WidgetCheckListContent>) | ({
|
|
20
|
+
layers?: string[] | undefined;
|
|
21
|
+
} & import("jamespot-user-api").WidgetDatasourceTableType) | ({
|
|
22
|
+
layers?: string[] | undefined;
|
|
23
|
+
} & {
|
|
24
|
+
name: import("jamespot-user-api").WidgetsName.ExcelDatasourceTable;
|
|
25
|
+
uniqid: string;
|
|
26
|
+
content: {
|
|
27
|
+
uri?: string | undefined;
|
|
28
|
+
limit?: number | boolean | undefined;
|
|
29
|
+
tableColumnsData?: {
|
|
30
|
+
name?: string | undefined;
|
|
31
|
+
label?: string | undefined;
|
|
32
|
+
isVisible?: boolean | undefined;
|
|
33
|
+
textEllipsis?: boolean | undefined;
|
|
34
|
+
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
35
|
+
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
36
|
+
}[] | undefined;
|
|
37
|
+
tableHeadColor?: string | undefined;
|
|
38
|
+
tableHeadTextColor?: string | undefined;
|
|
39
|
+
tableHeadIconColor?: string | undefined;
|
|
40
|
+
tableRowColor?: string | undefined;
|
|
41
|
+
tableRowTextColor?: string | undefined;
|
|
42
|
+
tableBorderRadius?: number | undefined;
|
|
43
|
+
tableSizedColumns?: boolean | undefined;
|
|
44
|
+
tableSizedColumnsWidth?: number | undefined;
|
|
45
|
+
};
|
|
46
|
+
}) | ({
|
|
47
|
+
layers?: string[] | undefined;
|
|
48
|
+
} & import("jamespot-user-api").WidgetPresenceType)>[] | undefined;
|
|
49
|
+
} & (import("jamespot-user-api").WidgetCheckListContent | import("jamespot-user-api").WidgetArticleAttachmentContent | import("jamespot-user-api").WidgetArticleGalleryContent | import("jamespot-user-api").WidgetArticleImageContent | import("jamespot-user-api").WidgetArticleTextContent | import("jamespot-user-api").WidgetArticleTitleContent | {
|
|
50
|
+
url?: string | undefined;
|
|
51
|
+
target?: string | undefined;
|
|
52
|
+
text?: string | undefined;
|
|
53
|
+
color?: string | undefined;
|
|
54
|
+
backgroundColor?: string | undefined;
|
|
55
|
+
borderRadius?: string | undefined;
|
|
56
|
+
fontSize?: string | undefined;
|
|
57
|
+
buttonSize?: "sm" | "md" | "lg" | undefined;
|
|
58
|
+
variant?: "contained" | "outlined" | undefined;
|
|
59
|
+
openingType?: "link" | "anchor" | "popup" | undefined;
|
|
60
|
+
openingTypeLink?: {
|
|
61
|
+
url: string;
|
|
62
|
+
target: string;
|
|
63
|
+
} | undefined;
|
|
64
|
+
openingTypeAnchor?: {
|
|
65
|
+
uniqid: string;
|
|
66
|
+
} | undefined;
|
|
67
|
+
openingTypePopup?: {
|
|
68
|
+
title: string;
|
|
69
|
+
widgets: import("jamespot-user-api").WidgetBaseType[];
|
|
70
|
+
} | undefined;
|
|
71
|
+
} | import("jamespot-user-api").WidgetArticleSliderContent | {
|
|
72
|
+
uri?: string | undefined;
|
|
73
|
+
limit?: number | boolean | undefined;
|
|
74
|
+
tableColumnsData?: {
|
|
75
|
+
name?: string | undefined;
|
|
76
|
+
label?: string | undefined;
|
|
77
|
+
isVisible?: boolean | undefined;
|
|
78
|
+
textEllipsis?: boolean | undefined;
|
|
79
|
+
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
80
|
+
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
81
|
+
}[] | undefined;
|
|
82
|
+
tableHeadColor?: string | undefined;
|
|
83
|
+
tableHeadTextColor?: string | undefined;
|
|
84
|
+
tableHeadIconColor?: string | undefined;
|
|
85
|
+
tableRowColor?: string | undefined;
|
|
86
|
+
tableRowTextColor?: string | undefined;
|
|
87
|
+
tableBorderRadius?: number | undefined;
|
|
88
|
+
tableSizedColumns?: boolean | undefined;
|
|
89
|
+
tableSizedColumnsWidth?: number | undefined;
|
|
90
|
+
} | {
|
|
91
|
+
uri?: string | undefined;
|
|
92
|
+
limit?: number | boolean | undefined;
|
|
93
|
+
tableColumnsData?: {
|
|
94
|
+
name?: string | undefined;
|
|
95
|
+
label?: string | undefined;
|
|
96
|
+
isVisible?: boolean | undefined;
|
|
97
|
+
textEllipsis?: boolean | undefined;
|
|
98
|
+
dateFormat?: "time" | "date" | "date-time" | "date-time-sec" | "time-sec" | undefined;
|
|
99
|
+
numberFormat?: "fr-FR" | "en-EN" | "filesize" | undefined;
|
|
100
|
+
}[] | undefined;
|
|
101
|
+
tableHeadColor?: string | undefined;
|
|
102
|
+
tableHeadTextColor?: string | undefined;
|
|
103
|
+
tableHeadIconColor?: string | undefined;
|
|
104
|
+
tableRowColor?: string | undefined;
|
|
105
|
+
tableRowTextColor?: string | undefined;
|
|
106
|
+
tableBorderRadius?: number | undefined;
|
|
107
|
+
tableSizedColumns?: boolean | undefined;
|
|
108
|
+
tableSizedColumnsWidth?: number | undefined;
|
|
109
|
+
} | {
|
|
110
|
+
limit?: number | boolean | undefined;
|
|
111
|
+
limitValue?: number | undefined;
|
|
112
|
+
closing?: boolean | undefined;
|
|
113
|
+
isClosed?: boolean | undefined;
|
|
114
|
+
})>>() => T;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { CombinedWidgetContent, HookListType, WidgetStateProps } from 'jamespot-user-api';
|
|
3
|
+
export type HookIsActive = (name: keyof HookListType) => boolean | undefined;
|
|
4
|
+
export type OnError = (message: string) => void;
|
|
5
|
+
export type OnStateChange = (state: WidgetStateProps) => void;
|
|
6
|
+
export type OnChange<T> = (content: Partial<T>, override?: boolean) => void;
|
|
7
|
+
export type OnSave<T> = (content: Partial<T>) => void;
|
|
8
|
+
export type Handlers = {
|
|
9
|
+
handleStart: () => void;
|
|
10
|
+
handleCatch: (reason: any) => void;
|
|
11
|
+
handleFinally: () => void;
|
|
12
|
+
};
|
|
13
|
+
export type EditorBaseContext<T = CombinedWidgetContent> = {
|
|
14
|
+
hook?: {
|
|
15
|
+
isActive: HookIsActive;
|
|
16
|
+
};
|
|
17
|
+
onStateChange: OnStateChange;
|
|
18
|
+
onChange: OnChange<T>;
|
|
19
|
+
onSave: OnSave<T>;
|
|
20
|
+
onError: OnError;
|
|
21
|
+
};
|
|
22
|
+
export declare const EditorContainerContext: <T>() => React.Context<T | null>;
|
|
23
|
+
export declare const ContainerContext: React.Context<unknown>;
|
|
24
|
+
export declare const EditorContainerProvider: <T>(props: {
|
|
25
|
+
children: React.ReactNode;
|
|
26
|
+
} & T) => React.JSX.Element;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ApiWrapper, BaseMessages } from 'jamespot-user-api';
|
|
2
|
+
export declare const mock_apiWrapper: ApiWrapper<any, BaseMessages>;
|
|
3
|
+
export declare const resolve: <T>(result: T) => Promise<{
|
|
4
|
+
result: T;
|
|
5
|
+
o: string;
|
|
6
|
+
f: string;
|
|
7
|
+
error: number;
|
|
8
|
+
messages: BaseMessages;
|
|
9
|
+
errorMsg?: string | undefined;
|
|
10
|
+
}>;
|
|
11
|
+
export declare const mock_api_network_default: Pick<import("jamespot-user-api").Network, "token" | "postFile" | "getUrl">;
|
|
12
|
+
export declare const mock_api_network_excel: Pick<import("jamespot-user-api").Network, "token" | "postFile" | "getUrl">;
|
|
13
|
+
export declare const mock_api_datasource_excel: Omit<import("jamespot-user-api").JDatasourceApi, "network" | "jApi">;
|
|
14
|
+
export declare const mock_api_datasource_studio: Omit<import("jamespot-user-api").JDatasourceApi, "network" | "jApi">;
|
|
15
|
+
export declare const mock_api_application: Pick<import("jamespot-user-api").JApplicationApi, "get" | "list">;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { DatasourceModel, DatasourceResult, JApplicationApi, StudioApplicationBase } from 'jamespot-user-api';
|
|
2
|
+
export type ApplicationMocks = {
|
|
3
|
+
list: StudioApplicationBase[];
|
|
4
|
+
app: StudioApplicationBase;
|
|
5
|
+
};
|
|
6
|
+
export declare function getApplicationApiMock(mocks: ApplicationMocks): Pick<JApplicationApi, 'get' | 'list'>;
|
|
7
|
+
export declare const mock_studio_datasource_model: DatasourceModel;
|
|
8
|
+
export declare const mock_studio_datasource_data: any;
|
|
9
|
+
export declare const mock_studio_datasource_result: DatasourceResult<any>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { DatasourceArticleLittle, DatasourceStudioLittle, DatasourceModel, DatasourceResult, DatasourceType, jFileLittle, JDatasourceApi } from 'jamespot-user-api';
|
|
2
|
+
export type DatasourceMockType = {
|
|
3
|
+
result: DatasourceResult<any>;
|
|
4
|
+
model: DatasourceModel;
|
|
5
|
+
headers?: string[];
|
|
6
|
+
datasource?: DatasourceArticleLittle | DatasourceStudioLittle;
|
|
7
|
+
datasourceType?: DatasourceType;
|
|
8
|
+
file?: jFileLittle;
|
|
9
|
+
};
|
|
10
|
+
export declare function getDatasourceMock(mocks: DatasourceMockType): Omit<JDatasourceApi, 'jApi' | 'network'>;
|
|
11
|
+
export declare const mock_excel_datasource_headers: string[];
|
|
12
|
+
export declare const mock_excel_datasource_model: DatasourceModel;
|
|
13
|
+
export declare const mock_excel_datasource_data: any;
|
|
14
|
+
export declare const mock_excel_datasource_result: DatasourceResult<any>;
|
package/build/src/index.d.ts
CHANGED
|
@@ -28,6 +28,7 @@ export { default as Resources } from './translation';
|
|
|
28
28
|
export { JRC404 } from './components/404';
|
|
29
29
|
export { BETA_JRCDoubleClick } from './components/Beta/BETA_JRCDoubleClick/BETA_JRCDoubleClick';
|
|
30
30
|
export { BETA_JRCDragAndDrop } from './components/Beta/BETA_JRCDragAndDrop/BETA_JRCDragAndDrop';
|
|
31
|
+
export { JRCApp365 } from './components/Drives/MicrosoftGraph/JRCApp365';
|
|
31
32
|
export { JRCConditionalWrapper } from './components/Common/JRCConditionalWrapper';
|
|
32
33
|
export { JRCDraggingPlaceholder } from './components/Common/JRCDraggingPlaceholder';
|
|
33
34
|
export { ClickAwayListener } from './components/Form/Common/ClickAwayListener';
|
|
@@ -66,6 +66,13 @@ export type ThemeType = {
|
|
|
66
66
|
l: number;
|
|
67
67
|
xl: number;
|
|
68
68
|
};
|
|
69
|
+
size: {
|
|
70
|
+
xs: number;
|
|
71
|
+
sm: number;
|
|
72
|
+
md: number;
|
|
73
|
+
l: number;
|
|
74
|
+
xl: number;
|
|
75
|
+
};
|
|
69
76
|
};
|
|
70
77
|
export declare function getColor(theme: ThemeType, color: string): string;
|
|
71
78
|
declare const Theme: ITheme;
|
|
@@ -19,4 +19,5 @@ export declare const arrayUniqueByUri: <T extends {
|
|
|
19
19
|
uri: string;
|
|
20
20
|
}>(arr1: T[], arr2: T[]) => T[];
|
|
21
21
|
export declare const arraySwapElements: <T>(arr: T[], index1: number, index2: number) => T[];
|
|
22
|
+
export declare function strArrayToggle(str: string, array: string[]): string[];
|
|
22
23
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jamespot-react-components",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.208",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./build/jamespot-react-components.js",
|
|
6
6
|
"types": "./build/src/index.d.ts",
|
|
@@ -80,7 +80,7 @@
|
|
|
80
80
|
"chroma-js": "^2.1.1",
|
|
81
81
|
"classnames": "^2.3.1",
|
|
82
82
|
"dompurify": "^3.0.5",
|
|
83
|
-
"jamespot-user-api": "^1.0.
|
|
83
|
+
"jamespot-user-api": "^1.0.186",
|
|
84
84
|
"moment": "2.29.4",
|
|
85
85
|
"react": "^17.x",
|
|
86
86
|
"react-beautiful-dnd": "^13.1.1",
|