jamespot-react-components 1.3.104 → 1.3.105
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/jamespot-react-components.cjs +1267 -1205
- package/dist/jamespot-react-components.js +13558 -13196
- package/dist/src/components/Drives/JRCDriveMSGraph.d.ts +2 -1
- package/dist/src/components/Drives/MicrosoftGraph/MSGraphDocuments.d.ts +1 -0
- package/dist/src/components/Drives/hooks.d.ts +2 -5
- package/dist/src/components/Widgets/JRCWidgetArticleImage/JRCWidgetArticleImage.d.ts +8 -0
- package/dist/src/components/Widgets/JRCWidgetArticleImage/JRCWidgetArticleImage.stories.d.ts +4 -0
- package/dist/src/components/Widgets/JRCWidgetFlockler/JRCWidgetFlockler.const.d.ts +9 -0
- package/dist/src/components/Widgets/JRCWidgetFlockler/JRCWidgetFlockler.d.ts +11 -0
- package/dist/src/components/Widgets/JRCWidgetFlockler/JRCWidgetFlockler.stories.d.ts +7 -0
- package/dist/src/components/Widgets/JRCWidgetFlockler/JRCWidgetFlocklerEditor.d.ts +12 -0
- package/dist/src/components/Widgets/JRCWidgetImage/JRCWidgetImage.const.d.ts +39 -0
- package/dist/src/components/Widgets/JRCWidgetImage/JRCWidgetImage.d.ts +16 -5
- package/dist/src/components/Widgets/JRCWidgetImage/JRCWidgetImage.stories.d.ts +4 -2
- package/dist/src/components/Widgets/JRCWidgetImage/JRCWidgetImageEditor.d.ts +8 -7
- package/dist/src/components/index.d.ts +4 -1
- package/dist/src/translation/lang.json.d.ts +16 -0
- package/dist/src/utils/utils.url.d.ts +2 -0
- package/package.json +2 -2
- /package/dist/src/components/Widgets/{JRCWidgetImage → JRCWidgetArticleImage}/JRCWidgetArticleImageEditor.d.ts +0 -0
- /package/dist/src/components/Widgets/{JRCWidgetImage → JRCWidgetArticleImage}/styles.d.ts +0 -0
|
@@ -6,6 +6,7 @@ type JRCDriveMSGraphProps = {
|
|
|
6
6
|
useNavigation?: boolean;
|
|
7
7
|
useFilter?: boolean;
|
|
8
8
|
useDocumentFilters: string[];
|
|
9
|
+
foldersOnly?: boolean;
|
|
9
10
|
onSelect?: (item: MSUnifiedEntity, driveParams: MSDocumentParams) => void;
|
|
10
11
|
onSelectMultiDocument?: (items: MSUnifiedEntity[], driveParams: MSDocumentParams) => void;
|
|
11
12
|
onSelectDocument?: (item: MSUnifiedEntity, lastFolder: MSUnifiedEntity | undefined, driveParams: MSDocumentParams) => void;
|
|
@@ -15,5 +16,5 @@ type JRCDriveMSGraphProps = {
|
|
|
15
16
|
onLogout?: () => void;
|
|
16
17
|
currentAccount?: DriveAccount;
|
|
17
18
|
};
|
|
18
|
-
export declare const JRCDriveMSGraph: ({ initialParams, initialFolder, initialFolderColor, useDocumentFilters, useFilter, useNavigation, onSelect, onSelectDocument, onSelectMultiDocument, onError, handleLogin, onLogin, currentAccount, }: JRCDriveMSGraphProps) => import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare const JRCDriveMSGraph: ({ initialParams, initialFolder, initialFolderColor, useDocumentFilters, foldersOnly, useFilter, useNavigation, onSelect, onSelectDocument, onSelectMultiDocument, onError, handleLogin, onLogin, currentAccount, }: JRCDriveMSGraphProps) => import("react/jsx-runtime").JSX.Element;
|
|
19
20
|
export {};
|
|
@@ -5,6 +5,7 @@ type MSGraphDocumentsProps = {
|
|
|
5
5
|
useNavigation: boolean;
|
|
6
6
|
useFilter: boolean;
|
|
7
7
|
useDocumentFilters: string[];
|
|
8
|
+
foldersOnly?: boolean;
|
|
8
9
|
onClick: (entity: MSUnifiedEntity) => void;
|
|
9
10
|
onSelect?: (entity: MSUnifiedEntity) => void;
|
|
10
11
|
onSelectDocument?: (entity: MSUnifiedEntity) => void;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { MSTenantEntity } from 'jamespot-user-api';
|
|
1
2
|
type ErrorType = {
|
|
2
3
|
error: number;
|
|
3
4
|
errorMsg: string;
|
|
@@ -13,11 +14,7 @@ export declare function useTenants({ id }: {
|
|
|
13
14
|
id: string;
|
|
14
15
|
}): {
|
|
15
16
|
loading: boolean;
|
|
16
|
-
entities:
|
|
17
|
-
type: string;
|
|
18
|
-
title: string;
|
|
19
|
-
name?: "group" | "groups" | "sites" | "onedrive" | "documents" | "me" | undefined;
|
|
20
|
-
}[];
|
|
17
|
+
entities: MSTenantEntity[];
|
|
21
18
|
error: ErrorType | undefined;
|
|
22
19
|
};
|
|
23
20
|
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export type JRCWidgetArticleImageProps = {
|
|
2
|
+
useFilter?: boolean;
|
|
3
|
+
maxWidth: number;
|
|
4
|
+
maxHeight?: number;
|
|
5
|
+
uri?: string;
|
|
6
|
+
loadWithDelay?: number;
|
|
7
|
+
};
|
|
8
|
+
export declare const JRCWidgetArticleImage: ({ useFilter, maxWidth, maxHeight, uri, loadWithDelay, }: JRCWidgetArticleImageProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const FLOCKLER_PLUGINS_URL = "https://plugins.flockler.com/";
|
|
2
|
+
/**
|
|
3
|
+
* A Flockler embed URL ends with `.../{clientId}/{layoutId}` — the script src and the target
|
|
4
|
+
* div id are both derived from those two trailing path segments (iso the legacy `apply()`).
|
|
5
|
+
*/
|
|
6
|
+
export declare const parseFlocklerIds: (url: string) => {
|
|
7
|
+
clientId: string;
|
|
8
|
+
layoutId: string;
|
|
9
|
+
} | null;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export interface JRCWidgetFlocklerProps {
|
|
2
|
+
url?: string;
|
|
3
|
+
}
|
|
4
|
+
/**
|
|
5
|
+
* Flockler embed display. Flockler's hosted script populates a `<div id="flockler-embed-{layoutId}">`
|
|
6
|
+
* with the social wall. We inject that script imperatively (`useEffect` + `ref`) rather than via
|
|
7
|
+
* `JRCHtml`/`dangerouslySetInnerHTML`: the former sanitizes out `<script>` tags, the latter never
|
|
8
|
+
* executes injected scripts. Cleanup empties the container on url change /
|
|
9
|
+
* unmount so a re-render never double-injects or leaves a ghost wall.
|
|
10
|
+
*/
|
|
11
|
+
export declare const JRCWidgetFlockler: ({ url }: JRCWidgetFlocklerProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react-vite';
|
|
2
|
+
import { JRCWidgetFlockler } from './JRCWidgetFlockler';
|
|
3
|
+
declare const meta: Meta<typeof JRCWidgetFlockler>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof JRCWidgetFlockler>;
|
|
6
|
+
export declare const WithEmbed: Story;
|
|
7
|
+
export declare const Empty: Story;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { WidgetFlocklerContent } from 'jamespot-user-api';
|
|
2
|
+
export interface JRCWidgetFlocklerEditorProps {
|
|
3
|
+
uniqid: string;
|
|
4
|
+
content: WidgetFlocklerContent;
|
|
5
|
+
onChangeContent: (uniqid: string, content: WidgetFlocklerContent) => void;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Flockler editor: a single embed-URL field. No explicit "Apply" button (unlike the legacy panel) —
|
|
9
|
+
* the value flows through `onChangeContent` → Redux → the display re-injects the script, the React
|
|
10
|
+
* idiom shared with the youtube/embed editors.
|
|
11
|
+
*/
|
|
12
|
+
export declare const JRCWidgetFlocklerEditor: ({ uniqid, content, onChangeContent }: JRCWidgetFlocklerEditorProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
export declare const DEFAULT_URL_SCALE = 1000;
|
|
2
|
+
export declare const DEFAULT_BORDER_RADIUS = 0;
|
|
3
|
+
export declare const ADJUST_IMAGE = 1;
|
|
4
|
+
export declare const ADJUST_BACKGROUND = 0;
|
|
5
|
+
export declare const AdjustOptions: {
|
|
6
|
+
label: string;
|
|
7
|
+
value: number;
|
|
8
|
+
}[];
|
|
9
|
+
export declare const BackgroundPositionOptions: ({
|
|
10
|
+
label: string;
|
|
11
|
+
value: "left";
|
|
12
|
+
} | {
|
|
13
|
+
label: string;
|
|
14
|
+
value: "center";
|
|
15
|
+
} | {
|
|
16
|
+
label: string;
|
|
17
|
+
value: "right";
|
|
18
|
+
})[];
|
|
19
|
+
export declare const VerticalAlignOptions: ({
|
|
20
|
+
label: string;
|
|
21
|
+
value: "top";
|
|
22
|
+
} | {
|
|
23
|
+
label: string;
|
|
24
|
+
value: "center";
|
|
25
|
+
} | {
|
|
26
|
+
label: string;
|
|
27
|
+
value: "bottom";
|
|
28
|
+
})[];
|
|
29
|
+
export declare const ClickOptions: ({
|
|
30
|
+
label: string;
|
|
31
|
+
value: "yes";
|
|
32
|
+
} | {
|
|
33
|
+
label: string;
|
|
34
|
+
value: "no";
|
|
35
|
+
})[];
|
|
36
|
+
export declare const AdvancedSettingsOptions: {
|
|
37
|
+
label: string;
|
|
38
|
+
value: number;
|
|
39
|
+
}[];
|
|
@@ -1,8 +1,19 @@
|
|
|
1
|
+
import { HTMLAttributeAnchorTarget } from 'react';
|
|
1
2
|
export type JRCWidgetImageProps = {
|
|
2
|
-
useFilter?: boolean;
|
|
3
|
-
maxWidth: number;
|
|
4
|
-
maxHeight?: number;
|
|
5
3
|
uri?: string;
|
|
6
|
-
|
|
4
|
+
urlMode?: boolean;
|
|
5
|
+
urlValue?: string;
|
|
6
|
+
urlWidthValue?: number;
|
|
7
|
+
urlHeightValue?: number;
|
|
8
|
+
urlLeftValue?: number;
|
|
9
|
+
urlTopValue?: number;
|
|
10
|
+
urlScaleValue?: number;
|
|
11
|
+
adjust?: number;
|
|
12
|
+
backgroundPosition?: 'left' | 'center' | 'right';
|
|
13
|
+
verticalAlign?: 'top' | 'center' | 'bottom';
|
|
14
|
+
borderRadius?: number;
|
|
15
|
+
click?: 'yes' | 'no';
|
|
16
|
+
href?: string;
|
|
17
|
+
target?: HTMLAttributeAnchorTarget;
|
|
7
18
|
};
|
|
8
|
-
export declare const JRCWidgetImage: (
|
|
19
|
+
export declare const JRCWidgetImage: (props: JRCWidgetImageProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
import { Meta } from '@storybook/react-vite';
|
|
1
|
+
import { Meta, StoryFn } from '@storybook/react-vite';
|
|
2
2
|
declare const _default: Meta;
|
|
3
3
|
export default _default;
|
|
4
|
-
export declare const
|
|
4
|
+
export declare const UploadImage: StoryFn;
|
|
5
|
+
export declare const BackgroundMode: StoryFn;
|
|
6
|
+
export declare const ExternalUrl: StoryFn;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
}
|
|
1
|
+
import { WidgetImageContent } from 'jamespot-user-api';
|
|
2
|
+
export interface JRCWidgetImageEditorProps {
|
|
3
|
+
uniqid: string;
|
|
4
|
+
content: WidgetImageContent;
|
|
5
|
+
token?: string;
|
|
6
|
+
onChangeContent: (uniqid: string, content: WidgetImageContent) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare const JRCWidgetImageEditor: ({ uniqid, content, token, onChangeContent }: JRCWidgetImageEditorProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -201,7 +201,8 @@ export { JRCWidgetEmailsImapLevel2 } from './Widgets/JRCWidgetEmailsImap/JRCWidg
|
|
|
201
201
|
export { JRCWidgetEmptyInplace } from './Widgets/JRCWidgetEmptyInplace';
|
|
202
202
|
export { JRCWidgetExtensionEditor } from './Widgets/JRCWidgetExtension/JRCWidgetExtensionEditor';
|
|
203
203
|
export { JRCWidgetIcon } from './Widgets/JRCWidgetIcon';
|
|
204
|
-
export {
|
|
204
|
+
export { JRCWidgetArticleImage } from './Widgets/JRCWidgetArticleImage/JRCWidgetArticleImage';
|
|
205
|
+
export { JRCWidgetArticleImageEditor } from './Widgets/JRCWidgetArticleImage/JRCWidgetArticleImageEditor';
|
|
205
206
|
export { JRCWidgetImage } from './Widgets/JRCWidgetImage/JRCWidgetImage';
|
|
206
207
|
export { JRCWidgetImageEditor } from './Widgets/JRCWidgetImage/JRCWidgetImageEditor';
|
|
207
208
|
export { JRCWidgetLuccaAbsence } from './Widgets/JRCWidgetLuccaAbsence/JRCWidgetLuccaAbsence';
|
|
@@ -223,6 +224,8 @@ export { JRCWidgetText } from './Widgets/JRCWidgetText/JRCWidgetText';
|
|
|
223
224
|
export { JRCWidgetTextEditor } from './Widgets/JRCWidgetText/JRCWidgetTextEditor';
|
|
224
225
|
export { JRCWidgetEmbed } from './Widgets/JRCWidgetEmbed/JRCWidgetEmbed';
|
|
225
226
|
export { JRCWidgetEmbedEditor } from './Widgets/JRCWidgetEmbed/JRCWidgetEmbedEditor';
|
|
227
|
+
export { JRCWidgetFlockler } from './Widgets/JRCWidgetFlockler/JRCWidgetFlockler';
|
|
228
|
+
export { JRCWidgetFlocklerEditor } from './Widgets/JRCWidgetFlockler/JRCWidgetFlocklerEditor';
|
|
226
229
|
export { JRCWidgetUserProfile } from './Widgets/JRCWidgetUserProfile/JRCWidgetUserProfile';
|
|
227
230
|
export { JRCWidgetUserProfileEditor } from './Widgets/JRCWidgetUserProfile/JRCWidgetUserProfileEditor';
|
|
228
231
|
export { JRCWidgetWelcome } from './Widgets/JRCWidgetWelcome/JRCWidgetWelcome';
|
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
declare const _default: {
|
|
2
2
|
"en": {
|
|
3
|
+
"GLOBAL_Background": "Background",
|
|
4
|
+
"INTRANET_Advanced_Options": "Advanced options",
|
|
5
|
+
"WIDGET_Add_Image_Url": "Add an image URL",
|
|
6
|
+
"WIDGET_IMAGE": "Image",
|
|
7
|
+
"WIDGET_IMAGE_TEXT": "Display an image",
|
|
8
|
+
"WIDGET_Image_Adjust": "Image adjustment",
|
|
9
|
+
"WIDGET_Image_Background_Position": "Background position",
|
|
10
|
+
"WIDGET_Image_Upload_Label": "Add an image",
|
|
11
|
+
"WIDGET_Image_Background_Vertical_Position": "Vertical background position",
|
|
12
|
+
"WIDGET_Image_Scale": "Scale",
|
|
13
|
+
"WIDGET_Image_X_Position": "Horizontal position",
|
|
14
|
+
"WIDGET_Image_Y_Position": "Vertical position",
|
|
3
15
|
"ACTIVITY_Can_Not_comment": "You cannot comment on this content",
|
|
4
16
|
"ACTIVITY_Can_Not_comment_Desc": "You cannot comment on this content. Several reasons are possible:<p>- You are not part of the audience of the content</p><p>- You do not have sufficient rights according to the group settings</p><p>- A solar storm creates interference (less likely, but you never know)",
|
|
5
17
|
"ADD_FAVORITE": "Add to favorites",
|
|
@@ -541,6 +553,10 @@ declare const _default: {
|
|
|
541
553
|
"WIDGET_Welcome": "Message d'accueil",
|
|
542
554
|
"WIDGET_Embed": "Embed",
|
|
543
555
|
"WIDGET_Embed_Text": "Embed external HTML content (iframe, integration code)",
|
|
556
|
+
"WIDGET_FLOCKLER": "Flockler",
|
|
557
|
+
"WIDGET_FLOCKLER_TEXT": "Embed a Flockler social wall",
|
|
558
|
+
"WIDGET_Flockler_Embed_Code": "Embed code url",
|
|
559
|
+
"WIDGET_Flockler_Embed_Code_Help": "Copy preview URL here",
|
|
544
560
|
"WIDGET_Youtube_Url": "Video URL",
|
|
545
561
|
"WIDGET_Youtube": "Video",
|
|
546
562
|
"WIDGET_Youtube_Text": "Embed a YouTube video",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jamespot-react-components",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.105",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/jamespot-react-components.cjs",
|
|
6
6
|
"module": "dist/jamespot-react-components.js",
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"globals": "^16.5.0",
|
|
61
61
|
"html2canvas": "^1.4.1",
|
|
62
62
|
"jamespot-front-business": "^1.3.104",
|
|
63
|
-
"jamespot-user-api": "^1.3.
|
|
63
|
+
"jamespot-user-api": "^1.3.105",
|
|
64
64
|
"jsdom": "^26.1.0",
|
|
65
65
|
"knip": "^5.88.1",
|
|
66
66
|
"lint-staged": "^16.4.0",
|
|
File without changes
|
|
File without changes
|