jamespot-react-components 1.3.121 → 1.3.122
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 +1448 -1453
- package/dist/jamespot-react-components.js +13924 -13845
- package/dist/src/components/Form/Input/JRCSelect/JRCInputSelect.style.d.ts +8 -4
- package/dist/src/components/JRCCalendar/JRCCalendarEvent.d.ts +1 -1
- package/dist/src/components/JRCCalendar/JRCCalendarEvent.stories.d.ts +110 -0
- package/dist/src/components/JRCFileViewer/JRCFileViewer.d.ts +16 -1
- package/dist/src/components/JRCFileViewer/JRCFileViewerContent.d.ts +5 -7
- package/dist/src/components/JRCFileViewer/JRCFileViewerContentApplication.d.ts +5 -6
- package/dist/src/components/JRCFileViewer/JRCFileViewerOpenWithOptions.d.ts +5 -6
- package/dist/src/components/JRCFileViewer/JRCFileViewerRaw.d.ts +2 -0
- package/dist/src/components/JRCFileViewer/fileToViewerItem.d.ts +8 -0
- package/dist/src/components/JRCFileViewer/types.d.ts +21 -12
- package/dist/src/components/JRCFlex/JRCFlexBox.d.ts +5 -2
- package/dist/src/components/JRCHtml/JRCHtml.d.ts +3 -0
- package/dist/src/components/JRCHtml/JRCHtml.stories.d.ts +2 -0
- package/dist/src/types.d.ts +1 -1
- package/dist/src/utils/utils.contentImages.d.ts +5 -0
- package/package.json +3 -3
|
@@ -56,19 +56,21 @@ export declare const FlexBoxTreeDescription: import('styled-components/dist/type
|
|
|
56
56
|
export declare const NoResult: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never> & Partial<Pick<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>>> & string;
|
|
57
57
|
export declare const WrapperList: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never> & Partial<Pick<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>>> & string;
|
|
58
58
|
export declare const ModalContentList: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never> & Partial<Pick<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>>> & string;
|
|
59
|
-
export declare const NoOptionList: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "$inline" | "direction" | "gap" | "childFull"> & Omit<import('../../../Common/FastCss').FastCssProps, "display"> & {
|
|
59
|
+
export declare const NoOptionList: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "overflow" | "$inline" | "direction" | "gap" | "childFull"> & Omit<import('../../../Common/FastCss').FastCssProps, "display"> & {
|
|
60
60
|
direction?: import('../../../JRCFlex/JRCFlexBox').FlexDirection;
|
|
61
61
|
$inline?: boolean;
|
|
62
62
|
flex?: boolean | string;
|
|
63
|
+
overflow?: "hidden" | "scroll" | "visible" | "auto";
|
|
63
64
|
gap?: number;
|
|
64
65
|
x?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
65
66
|
y?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
66
67
|
childFull?: boolean;
|
|
67
68
|
'data-testid'?: string;
|
|
68
|
-
}, never> & Partial<Pick<import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "$inline" | "direction" | "gap" | "childFull"> & Omit<import('../../../Common/FastCss').FastCssProps, "display"> & {
|
|
69
|
+
}, never> & Partial<Pick<import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "overflow" | "$inline" | "direction" | "gap" | "childFull"> & Omit<import('../../../Common/FastCss').FastCssProps, "display"> & {
|
|
69
70
|
direction?: import('../../../JRCFlex/JRCFlexBox').FlexDirection;
|
|
70
71
|
$inline?: boolean;
|
|
71
72
|
flex?: boolean | string;
|
|
73
|
+
overflow?: "hidden" | "scroll" | "visible" | "auto";
|
|
72
74
|
gap?: number;
|
|
73
75
|
x?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
74
76
|
y?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
@@ -77,19 +79,21 @@ export declare const NoOptionList: import('styled-components/dist/types').IStyle
|
|
|
77
79
|
}, never>>, "as" | "forwardedAs"> & {
|
|
78
80
|
as?: import('styled-components').WebTarget | undefined;
|
|
79
81
|
forwardedAs?: import('styled-components').WebTarget | undefined;
|
|
80
|
-
}, never> & Partial<Pick<import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "$inline" | "direction" | "gap" | "childFull"> & Omit<import('../../../Common/FastCss').FastCssProps, "display"> & {
|
|
82
|
+
}, never> & Partial<Pick<import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "overflow" | "$inline" | "direction" | "gap" | "childFull"> & Omit<import('../../../Common/FastCss').FastCssProps, "display"> & {
|
|
81
83
|
direction?: import('../../../JRCFlex/JRCFlexBox').FlexDirection;
|
|
82
84
|
$inline?: boolean;
|
|
83
85
|
flex?: boolean | string;
|
|
86
|
+
overflow?: "hidden" | "scroll" | "visible" | "auto";
|
|
84
87
|
gap?: number;
|
|
85
88
|
x?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
86
89
|
y?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
87
90
|
childFull?: boolean;
|
|
88
91
|
'data-testid'?: string;
|
|
89
|
-
}, never> & Partial<Pick<import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "$inline" | "direction" | "gap" | "childFull"> & Omit<import('../../../Common/FastCss').FastCssProps, "display"> & {
|
|
92
|
+
}, never> & Partial<Pick<import('styled-components').FastOmit<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "overflow" | "$inline" | "direction" | "gap" | "childFull"> & Omit<import('../../../Common/FastCss').FastCssProps, "display"> & {
|
|
90
93
|
direction?: import('../../../JRCFlex/JRCFlexBox').FlexDirection;
|
|
91
94
|
$inline?: boolean;
|
|
92
95
|
flex?: boolean | string;
|
|
96
|
+
overflow?: "hidden" | "scroll" | "visible" | "auto";
|
|
93
97
|
gap?: number;
|
|
94
98
|
x?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
95
99
|
y?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
@@ -31,5 +31,5 @@ type JRCCalendarEventProps = {
|
|
|
31
31
|
recurrent: boolean;
|
|
32
32
|
recurringEventId?: number;
|
|
33
33
|
};
|
|
34
|
-
export declare const JRCCalendarEvent: ({
|
|
34
|
+
export declare const JRCCalendarEvent: ({ id: stringId, onClick, ...props }: JRCCalendarEventProps) => import("react").JSX.Element | null;
|
|
35
35
|
export {};
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { StoryObj } from '@storybook/react-vite';
|
|
2
|
+
declare const meta: {
|
|
3
|
+
title: string;
|
|
4
|
+
component: ({ id: stringId, onClick, ...props }: {
|
|
5
|
+
id: string;
|
|
6
|
+
title: string;
|
|
7
|
+
start: Date | null;
|
|
8
|
+
end: Date | null;
|
|
9
|
+
status: import('jamespot-user-api').UserResponseStatus | null;
|
|
10
|
+
mode: import('./types').JRCCalendarMode;
|
|
11
|
+
display: import('./types').CalendarView;
|
|
12
|
+
onClick?: (id: number) => void;
|
|
13
|
+
href?: string;
|
|
14
|
+
audience: import('../JRCAvatars/JRCAvatars').AvatarAudience[];
|
|
15
|
+
allDay?: boolean;
|
|
16
|
+
textColor?: string;
|
|
17
|
+
backgroundColor?: string;
|
|
18
|
+
address?: string;
|
|
19
|
+
image: boolean;
|
|
20
|
+
type: string;
|
|
21
|
+
isVisio?: boolean;
|
|
22
|
+
noGestion: boolean;
|
|
23
|
+
canSubscribe: boolean;
|
|
24
|
+
urlGestion?: string;
|
|
25
|
+
onUpdateStatus: (params: {
|
|
26
|
+
status: import('jamespot-user-api').UserResponseStatus;
|
|
27
|
+
id: number;
|
|
28
|
+
type: string;
|
|
29
|
+
}) => void;
|
|
30
|
+
isUpdateStatusLoading: (id: number) => boolean;
|
|
31
|
+
recurrent: boolean;
|
|
32
|
+
recurringEventId?: number;
|
|
33
|
+
}) => import("react").JSX.Element | null;
|
|
34
|
+
tags: string[];
|
|
35
|
+
args: {
|
|
36
|
+
id: string;
|
|
37
|
+
title: string;
|
|
38
|
+
start: Date;
|
|
39
|
+
end: Date;
|
|
40
|
+
status: "available";
|
|
41
|
+
mode: "full";
|
|
42
|
+
display: "list";
|
|
43
|
+
audience: never[];
|
|
44
|
+
image: false;
|
|
45
|
+
type: string;
|
|
46
|
+
noGestion: false;
|
|
47
|
+
canSubscribe: true;
|
|
48
|
+
recurrent: false;
|
|
49
|
+
backgroundColor: string;
|
|
50
|
+
onUpdateStatus: import('storybook/test').Mock<(...args: any[]) => any>;
|
|
51
|
+
isUpdateStatusLoading: () => boolean;
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
export default meta;
|
|
55
|
+
type Story = StoryObj<typeof meta>;
|
|
56
|
+
export declare const MonthFilled: Story;
|
|
57
|
+
export declare const MonthOutlined: Story;
|
|
58
|
+
export declare const MonthAllDay: Story;
|
|
59
|
+
export declare const MonthWithoutStart: Story;
|
|
60
|
+
export declare const MonthRecurrent: Story;
|
|
61
|
+
export declare const MonthUnavailable: Story;
|
|
62
|
+
export declare const MonthWithHref: Story;
|
|
63
|
+
export declare const MonthWithoutHref: Story;
|
|
64
|
+
export declare const MonthTextColor: Story;
|
|
65
|
+
export declare const MonthLongTitle: Story;
|
|
66
|
+
export declare const WeekSizeLarge: Story;
|
|
67
|
+
export declare const WeekSizeSmall: Story;
|
|
68
|
+
export declare const WeekSizeExtraSmall: Story;
|
|
69
|
+
export declare const WeekOutlined: Story;
|
|
70
|
+
export declare const WeekAllDay: Story;
|
|
71
|
+
export declare const WeekWithoutEnd: Story;
|
|
72
|
+
export declare const WeekUnavailable: Story;
|
|
73
|
+
export declare const WeekWithHref: Story;
|
|
74
|
+
export declare const WeekRecurrentLargeIcon: Story;
|
|
75
|
+
export declare const WeekTooltipActive: Story;
|
|
76
|
+
export declare const WeekTooltipInactive: Story;
|
|
77
|
+
export declare const WeekRecurrentVisible: Story;
|
|
78
|
+
export declare const WeekRecurrentHiddenOnExtraSmall: Story;
|
|
79
|
+
export declare const WeekSpansMonths: Story;
|
|
80
|
+
export declare const DayView: Story;
|
|
81
|
+
export declare const ListFull: Story;
|
|
82
|
+
export declare const ListCompact: Story;
|
|
83
|
+
export declare const ListOutlined: Story;
|
|
84
|
+
export declare const ListFilled: Story;
|
|
85
|
+
export declare const ListWithHref: Story;
|
|
86
|
+
export declare const ListUnavailable: Story;
|
|
87
|
+
export declare const ListShadedText: Story;
|
|
88
|
+
export declare const ListStatusLoading: Story;
|
|
89
|
+
export declare const ListUnsupportedType: Story;
|
|
90
|
+
export declare const ListWithoutBackgroundColor: Story;
|
|
91
|
+
export declare const ListWithImage: Story;
|
|
92
|
+
export declare const ListWithAddress: Story;
|
|
93
|
+
export declare const ListWithEmptyAddress: Story;
|
|
94
|
+
export declare const ListWithoutAddress: Story;
|
|
95
|
+
export declare const ListRecurringEvent: Story;
|
|
96
|
+
export declare const ListRecurrent: Story;
|
|
97
|
+
export declare const ListWithoutStart: Story;
|
|
98
|
+
export declare const ListStatusButtonDisabled: Story;
|
|
99
|
+
export declare const ListWithUrlGestion: Story;
|
|
100
|
+
export declare const DateSameDayTimed: Story;
|
|
101
|
+
export declare const DateSameDayAllDay: Story;
|
|
102
|
+
export declare const DateSameDayWithoutEnd: Story;
|
|
103
|
+
export declare const DateSpansDaysTimed: Story;
|
|
104
|
+
export declare const DateSpansDaysAllDay: Story;
|
|
105
|
+
export declare const DateSpansMonths: Story;
|
|
106
|
+
export declare const DateSpansYears: Story;
|
|
107
|
+
export declare const DateSpansMonthsAllDay: Story;
|
|
108
|
+
export declare const KeyboardActivatesMonthEvent: Story;
|
|
109
|
+
export declare const KeyboardActivatesListEvent: Story;
|
|
110
|
+
export declare const KeyboardReachesStatusButton: Story;
|
|
@@ -1,3 +1,18 @@
|
|
|
1
1
|
import { jFileLittle } from 'jamespot-user-api';
|
|
2
|
-
import {
|
|
2
|
+
import { ReactElement } from 'react';
|
|
3
|
+
export type JRCFileViewerProps<T extends jFileLittle> = {
|
|
4
|
+
files: T[];
|
|
5
|
+
size?: string;
|
|
6
|
+
openWithOptions: JRCFileViewerOpenWithOptionsType;
|
|
7
|
+
children(open: (idFile: number) => void): ReactElement<HTMLElement>;
|
|
8
|
+
onReadFile?(file: T): void;
|
|
9
|
+
};
|
|
10
|
+
export type JRCFileViewerOpenWithOptionsType = Array<{
|
|
11
|
+
condition: (file: jFileLittle) => boolean;
|
|
12
|
+
options: JRCFileViewerOpenWithOptionType[];
|
|
13
|
+
}>;
|
|
14
|
+
export type JRCFileViewerOpenWithOptionType = {
|
|
15
|
+
label: string;
|
|
16
|
+
onClick: (file: jFileLittle | undefined) => void;
|
|
17
|
+
};
|
|
3
18
|
export declare const JRCFileViewer: <T extends jFileLittle>({ files, size, children, openWithOptions, onReadFile, }: JRCFileViewerProps<T>) => import("react").JSX.Element;
|
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
size?: string;
|
|
6
|
-
openWithOptions: JRCFileViewerOpenWithOptionsType;
|
|
1
|
+
import { JRCFileViewerItem, JRCFileViewerRawOptionsType } from './types';
|
|
2
|
+
type JRCFileViewerContentProps<TItem extends JRCFileViewerItem> = {
|
|
3
|
+
item: TItem;
|
|
4
|
+
openWithOptions: JRCFileViewerRawOptionsType<TItem>;
|
|
7
5
|
};
|
|
8
|
-
export declare const JRCFileViewerContent: ({
|
|
6
|
+
export declare const JRCFileViewerContent: <TItem extends JRCFileViewerItem>({ item, openWithOptions, }: JRCFileViewerContentProps<TItem>) => import("react").JSX.Element;
|
|
9
7
|
export {};
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import { jFileLittle } from 'jamespot-user-api';
|
|
2
1
|
import { ReactNode } from 'react';
|
|
3
|
-
import {
|
|
4
|
-
type JRCFileViewerContentApplicationProps = {
|
|
5
|
-
|
|
6
|
-
options?:
|
|
2
|
+
import { JRCFileViewerItem, JRCFileViewerRawOptionType } from './types';
|
|
3
|
+
type JRCFileViewerContentApplicationProps<TItem extends JRCFileViewerItem> = {
|
|
4
|
+
item?: TItem;
|
|
5
|
+
options?: JRCFileViewerRawOptionType<TItem>[];
|
|
7
6
|
children: ReactNode;
|
|
8
7
|
};
|
|
9
|
-
export declare const JRCFileViewerContentApplication: ({
|
|
8
|
+
export declare const JRCFileViewerContentApplication: <TItem extends JRCFileViewerItem>({ item, options, children, }: JRCFileViewerContentApplicationProps<TItem>) => import("react").JSX.Element;
|
|
10
9
|
export {};
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
options: JRCFileViewerOpenWithOptionType[];
|
|
1
|
+
import { JRCFileViewerItem, JRCFileViewerRawOptionType } from './types';
|
|
2
|
+
type JRCFileViewerOpenWithOptionsProps<TItem extends JRCFileViewerItem> = {
|
|
3
|
+
item: TItem;
|
|
4
|
+
options: JRCFileViewerRawOptionType<TItem>[];
|
|
6
5
|
};
|
|
7
|
-
export declare const JRCFileViewerOpenWithOptions: ({
|
|
6
|
+
export declare const JRCFileViewerOpenWithOptions: <TItem extends JRCFileViewerItem>({ item, options, }: JRCFileViewerOpenWithOptionsProps<TItem>) => import("react").JSX.Element;
|
|
8
7
|
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { jFileLittle } from 'jamespot-user-api';
|
|
2
|
+
import { JRCFileViewerItem } from './types';
|
|
3
|
+
export declare const DEFAULT_VIEWER_SIZE = "fitx1200";
|
|
4
|
+
/** Keeps the file the item was built from, so the file-facing callbacks stay typed on it. */
|
|
5
|
+
export type JRCFileViewerFileItem<T extends jFileLittle> = JRCFileViewerItem & {
|
|
6
|
+
file: T;
|
|
7
|
+
};
|
|
8
|
+
export declare const fileToViewerItem: <T extends jFileLittle>(file: T, size?: string) => JRCFileViewerFileItem<T>;
|
|
@@ -1,17 +1,26 @@
|
|
|
1
|
-
import { jFileLittle } from 'jamespot-user-api';
|
|
2
1
|
import { ReactElement } from 'react';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
/**
|
|
3
|
+
* What the Raw viewer needs to display one entry. Free of any file model on purpose: it renders a
|
|
4
|
+
* source, it does not know where that source comes from — the wrapper maps platform files onto it.
|
|
5
|
+
*/
|
|
6
|
+
export type JRCFileViewerItem = {
|
|
7
|
+
key: number;
|
|
8
|
+
url?: string | undefined;
|
|
9
|
+
title: string;
|
|
10
|
+
mimetype: string;
|
|
11
|
+
downloadHref?: string | undefined;
|
|
9
12
|
};
|
|
10
|
-
export type
|
|
11
|
-
|
|
12
|
-
|
|
13
|
+
export type JRCFileViewerRawProps<TItem extends JRCFileViewerItem> = {
|
|
14
|
+
files: TItem[];
|
|
15
|
+
openWithOptions: JRCFileViewerRawOptionsType<TItem>;
|
|
16
|
+
children(open: (key: number) => void): ReactElement<HTMLElement>;
|
|
17
|
+
onReadFile?(item: TItem): void;
|
|
18
|
+
};
|
|
19
|
+
export type JRCFileViewerRawOptionsType<TItem extends JRCFileViewerItem> = Array<{
|
|
20
|
+
condition: (item: TItem) => boolean;
|
|
21
|
+
options: JRCFileViewerRawOptionType<TItem>[];
|
|
13
22
|
}>;
|
|
14
|
-
export type
|
|
23
|
+
export type JRCFileViewerRawOptionType<TItem extends JRCFileViewerItem> = {
|
|
15
24
|
label: string;
|
|
16
|
-
onClick: (item:
|
|
25
|
+
onClick: (item: TItem) => void;
|
|
17
26
|
};
|
|
@@ -4,25 +4,28 @@ type FlexBoxProps = Omit<FastCssProps, 'display'> & {
|
|
|
4
4
|
direction?: FlexDirection;
|
|
5
5
|
$inline?: boolean;
|
|
6
6
|
flex?: boolean | string;
|
|
7
|
+
overflow?: 'hidden' | 'scroll' | 'visible' | 'auto';
|
|
7
8
|
gap?: number;
|
|
8
9
|
x?: 'flex-start' | 'center' | 'flex-end' | 'space-around' | 'space-between' | 'space-evenly';
|
|
9
10
|
y?: 'flex-start' | 'center' | 'flex-end' | 'space-around' | 'space-between' | 'space-evenly';
|
|
10
11
|
childFull?: boolean;
|
|
11
12
|
'data-testid'?: string;
|
|
12
13
|
};
|
|
13
|
-
export declare const JRCFlexBox: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "$inline" | "direction" | "gap" | "childFull"> & Omit<FastCssProps, "display"> & {
|
|
14
|
+
export declare const JRCFlexBox: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "overflow" | "$inline" | "direction" | "gap" | "childFull"> & Omit<FastCssProps, "display"> & {
|
|
14
15
|
direction?: FlexDirection;
|
|
15
16
|
$inline?: boolean;
|
|
16
17
|
flex?: boolean | string;
|
|
18
|
+
overflow?: "hidden" | "scroll" | "visible" | "auto";
|
|
17
19
|
gap?: number;
|
|
18
20
|
x?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
19
21
|
y?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
20
22
|
childFull?: boolean;
|
|
21
23
|
'data-testid'?: string;
|
|
22
|
-
}, never> & Partial<Pick<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "$inline" | "direction" | "gap" | "childFull"> & Omit<FastCssProps, "display"> & {
|
|
24
|
+
}, never> & Partial<Pick<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "flex" | "position" | "x" | "y" | "padding" | "margin" | "textAlign" | "data-testid" | "overflow" | "$inline" | "direction" | "gap" | "childFull"> & Omit<FastCssProps, "display"> & {
|
|
23
25
|
direction?: FlexDirection;
|
|
24
26
|
$inline?: boolean;
|
|
25
27
|
flex?: boolean | string;
|
|
28
|
+
overflow?: "hidden" | "scroll" | "visible" | "auto";
|
|
26
29
|
gap?: number;
|
|
27
30
|
x?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
28
31
|
y?: "flex-start" | "center" | "flex-end" | "space-around" | "space-between" | "space-evenly";
|
|
@@ -7,6 +7,9 @@ export type JRCHtmlProps = {
|
|
|
7
7
|
lines?: LimitLinesProps['$lines'];
|
|
8
8
|
/** Troncage si `lines` est défini : `'ellipsis'` (line-clamp, texte) ou `'fade'` (max-height + fondu, contenu riche). */
|
|
9
9
|
truncate?: 'ellipsis' | 'fade';
|
|
10
|
+
/** Set to false when rendering inside a clipped or clickable ancestor, which no inspection of
|
|
11
|
+
* the HTML fragment can detect: images stay plain instead of becoming controls. */
|
|
12
|
+
imagesInteractive?: boolean;
|
|
10
13
|
seeMore?: {
|
|
11
14
|
href: string;
|
|
12
15
|
label?: string;
|
|
@@ -6,3 +6,5 @@ export declare const Default: import('storybook/internal/csf').AnnotatedStoryFn<
|
|
|
6
6
|
export declare const seeMoreLines: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react-vite').ReactRenderer, JRCHtmlProps>;
|
|
7
7
|
export declare const seeMoreImg: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react-vite').ReactRenderer, JRCHtmlProps>;
|
|
8
8
|
export declare const fadeRichContent: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react-vite').ReactRenderer, JRCHtmlProps>;
|
|
9
|
+
export declare const imageViewer: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react-vite').ReactRenderer, JRCHtmlProps>;
|
|
10
|
+
export declare const imageViewerTextOnly: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react-vite').ReactRenderer, JRCHtmlProps>;
|
package/dist/src/types.d.ts
CHANGED
|
@@ -48,7 +48,7 @@ export type { BaseDndItem, DndData, DndDragItem, DndEmptyStateComponentProps, Dn
|
|
|
48
48
|
export type { JRCDropDownProps } from './components/JRCDropDown/JRCDropDown';
|
|
49
49
|
export type { JRCFileOpenProps } from './components/JRCFileOpen/JRCFileOpen';
|
|
50
50
|
export type { JRCFileRowProps } from './components/JRCFileRow/JRCFileRow';
|
|
51
|
-
export type { JRCFileViewerOpenWithOptionsType } from './components/JRCFileViewer/
|
|
51
|
+
export type { JRCFileViewerOpenWithOptionsType } from './components/JRCFileViewer/JRCFileViewer';
|
|
52
52
|
export type { JRCFlexBoxProps } from './components/JRCFlex/JRCFlexBox';
|
|
53
53
|
export type { JRCGridProps } from './components/JRCGrid/JRCGrid';
|
|
54
54
|
export type { JRCLinkToProps, JRCStyledHrefProps } from './components/JRCStyledHref/JRCStyledHref';
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { JRCFileViewerItem } from '../components/JRCFileViewer/types';
|
|
2
|
+
export declare const CONTENT_IMAGE_ID_ATTRIBUTE = "data-jrc-image-id";
|
|
3
|
+
export declare function isImageInsideInteractive(img: HTMLImageElement): boolean;
|
|
4
|
+
export declare function buildImageItem(img: HTMLImageElement, index: number): JRCFileViewerItem;
|
|
5
|
+
export declare function collectContentImages(root: ParentNode, fallbackLabel?: string): JRCFileViewerItem[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jamespot-react-components",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.122",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/jamespot-react-components.cjs",
|
|
6
6
|
"module": "dist/jamespot-react-components.js",
|
|
@@ -60,8 +60,8 @@
|
|
|
60
60
|
"eslint-plugin-storybook": "10.3.6",
|
|
61
61
|
"globals": "^16.5.0",
|
|
62
62
|
"html2canvas": "^1.4.1",
|
|
63
|
-
"jamespot-front-business": "^1.3.
|
|
64
|
-
"jamespot-user-api": "^1.3.
|
|
63
|
+
"jamespot-front-business": "^1.3.122",
|
|
64
|
+
"jamespot-user-api": "^1.3.122",
|
|
65
65
|
"jsdom": "^26.1.0",
|
|
66
66
|
"knip": "^5.88.1",
|
|
67
67
|
"lint-staged": "^16.4.0",
|