@gitkraken/gitkraken-components 10.6.1 → 10.7.1
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/components/graph/GraphContainer.d.ts +6 -20
- package/dist/components/graph/commitzone/CommitZone.d.ts +1 -0
- package/dist/components/graph/common/GenericGraphZone.d.ts +1 -0
- package/dist/components/graph/refzone/RefNodes.d.ts +2 -1
- package/dist/components/graph/refzone/RefZone.d.ts +1 -0
- package/dist/domain/graph/GraphConstants.d.ts +1 -0
- package/dist/domain/graph/GraphHelpers.d.ts +2 -0
- package/dist/domain/graph/GraphTypes.d.ts +20 -0
- package/dist/domain/graph/row/ProcessedGraphRowObj.d.ts +2 -1
- package/dist/index.d.ts +1 -9
- package/dist/index.js +2 -2
- package/dist/types.d.ts +15 -0
- package/dist/types.js +1 -0
- package/package.json +1 -1
|
@@ -4,32 +4,14 @@ import type { ReactElement } from 'react';
|
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import type { Sha } from '../../domain/commit/CommitTypes';
|
|
6
6
|
import type { CssVariables } from '../../domain/generic/GenericTypes';
|
|
7
|
-
import type { GraphCommitDescDisplayMode, GraphMarkerType, GraphZone, GraphZoneType, ShiftSelectMode } from '../../domain/graph/GraphConstants';
|
|
7
|
+
import type { GraphCommitDescDisplayMode, GraphMarkerType, GraphSearchMode, GraphZone, GraphZoneType, ShiftSelectMode } from '../../domain/graph/GraphConstants';
|
|
8
8
|
import type { ThrottledFn } from '../../domain/graph/GraphHelpers';
|
|
9
|
-
import type { AbsoluteNodeLeftByColumn, AvatarUrlByEmail, AvatarUrlRequestedByEmail, ChildrenBySha, ColumnColorByColumn, DownstreamsByUpstream, EdgeByColumn, ExcludeByType, ExcludeRefsById, ExcludeRemotesByName, FormatCommitMessage, FormatRefShorthand, GetExternalIcon, GetMissingAvatar, GetMissingRefMetadata, GraphColumnSetting, GraphColumnsSettings, GraphContexts, GraphMarkerColors, GraphMarkerRowIndices, GraphPlatform, GraphRefGroup,
|
|
9
|
+
import type { AbsoluteNodeLeftByColumn, AvatarUrlByEmail, AvatarUrlRequestedByEmail, ChildrenBySha, ColumnColorByColumn, DownstreamsByUpstream, EdgeByColumn, ExcludeByType, ExcludeRefsById, ExcludeRemotesByName, FormatCommitMessage, FormatRefShorthand, GetExternalIcon, GetMissingAvatar, GetMissingRefMetadata, GraphColumnSetting, GraphColumnsSettings, GraphContexts, GraphMarkerColors, GraphMarkerRowIndices, GraphPlatform, GraphRefGroup, GraphRow, GraphZoneModeConstants, GraphZonesByType, Head, HighlightedShas, IncludeOnlyRefsById, IncludeOnlyRemotesByName, IsRefShorthandValid, IsSelectedBySha, NodeOffsetByColumn, NodeOpacityByColumn, OnClearCurrentlyHoveredGraphCommit, OnClickCommit, OnClickGraphRef, OnClickGraphRow, OnClickRef, OnCommitContextMenu, OnCommitMessageChange, OnCurrentlyHoveredGraphCommit, OnDoubleClickCommit, OnDoubleClickGraphRef, OnDoubleClickGraphRow, OnDoubleClickRef, OnEmailsMissingAvatarUrls, OnFilterColumnClick, OnFormatCommitDateTime, OnGraphColumnReOrdered, OnGraphColumnResized, OnGraphColumnsReOrdered, OnGraphMouseEnter, OnGraphMouseLeave, OnGraphRefNodeHovered, OnGraphRefNodeUnhovered, OnGraphResized, OnGraphRowHovered, OnGraphRowUnhovered, OnGraphScrollForZone, OnGraphVisibleRowsChanged, OnGraphZoneResize, OnGraphZoneResizeEnd, OnLoadSelectedGraphRow, OnPopupGraphHeaderContextMenu, OnRefBeginDrag, OnRefCanDrag, OnRefCanDrop, OnRefContextMenu, OnRefCreate, OnRefCreateCancel, OnRefCreateContextMenu, OnRefDragEnter, OnRefDragLeave, OnRefDrop, OnRefEndDrag, OnRefNodeHovered, OnRefNodeUnhovered, OnRefShorthandChange, OnRefsMissingMetadata, OnRefZoneContextMenu, OnRefZoneHovered, OnRefZoneUnhovered, OnRowContextMenu, OnScrollForZone, OnSelectGraphRows, OnSettingsClick, OnShowMoreCommits, OnToggleRefNodesShown, OnToggleRefsVisibilityClick, OnWipMessageBlur, OnWipMessageFocus, ProcessedGraphRow, ProcessedGraphRowBySha, RefMetadataById, RefMetadataRequestedById, RefMetadataType, RefsMissingMetadata, Remote, ReserverInfoBySha, RowEdges, RowStats, RowStatsConstraints, ShaByRefId, Tag, TopAndBottomVisibleRowIndex } from '../../domain/graph/GraphTypes';
|
|
10
10
|
import type { TranslationFn } from '../../domain/language/LanguageTypes';
|
|
11
11
|
import type { CreateRefFormData, RefIconsPosition } from '../../domain/ref/RefTypes';
|
|
12
12
|
import type { OnBlur, OnKeyDown, OnKeyUp, OnMouseDown, OnResizeParams } from '../../domain/ui/UiTypes';
|
|
13
13
|
import type { WorkDirStats } from '../../domain/workdir/WorkDirTypes';
|
|
14
14
|
import type { IGraphContainer } from './IGraphContainer';
|
|
15
|
-
type OnClickGraphRow = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
16
|
-
type OnDoubleClickGraphRow = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
17
|
-
type OnClickGraphRef = (event: React.MouseEvent<any>, refGroup: GraphRefGroup, graphRow: GraphRow, metadataItem?: RefMetadataItem) => void;
|
|
18
|
-
type OnDoubleClickGraphRef = (event: React.MouseEvent<any>, refGroup: GraphRefGroup, graphRow: GraphRow, metadataItem?: RefMetadataItem) => void;
|
|
19
|
-
type OnRowContextMenu = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
20
|
-
type OnRefContextMenu = (event: React.MouseEvent<any>, refGroup: GraphRefGroup, graphRow: GraphRow) => void;
|
|
21
|
-
type OnToggleRefsVisibilityClick = (event: React.MouseEvent<any>, refs: GraphRefOptData[], visible: boolean, graphRow?: GraphRow) => void;
|
|
22
|
-
type OnSelectGraphRows = (selectedRows: GraphRow[]) => void;
|
|
23
|
-
type OnGraphRowHovered = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
24
|
-
type OnGraphRowUnhovered = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
25
|
-
type OnGraphRefNodeHovered = (event: React.MouseEvent<any>, refGroup: GraphRefGroup, graphRow: GraphRow) => void;
|
|
26
|
-
type OnGraphScrollForZone = (graphZoneType: GraphZoneType, scroll: ScrollParams) => void;
|
|
27
|
-
type OnGraphRefNodeUnhovered = (event: React.MouseEvent<any> | React.FocusEvent<any> | null, refGroup: GraphRefGroup, graphRow: GraphRow) => void;
|
|
28
|
-
type OnGraphColumnsReOrdered = (columnsSettings: GraphColumnsSettings) => void;
|
|
29
|
-
type OnGraphColumnResized = (graphZoneType: GraphZoneType, columnSettings: GraphColumnSetting) => void;
|
|
30
|
-
type OnShowMoreCommits = () => void;
|
|
31
|
-
type OnEmailsMissingAvatarUrls = (emails: AvatarUrlByEmail) => void;
|
|
32
|
-
type OnRefsMissingMetadata = (refs: RefsMissingMetadata) => void;
|
|
33
15
|
type ClearScrollToIndex = () => void;
|
|
34
16
|
type OnZoneEnter = (e: React.MouseEvent<any>, zoneType: GraphZoneType, hoveredRefGroup?: GraphRefGroup, hoveredSha?: Sha) => void;
|
|
35
17
|
type OnGraphContainerBlurred = (event: React.FocusEvent<any>, hoveredRefGroup?: GraphRefGroup, hoveredSha?: Sha) => void;
|
|
@@ -77,6 +59,7 @@ export interface StateProps {
|
|
|
77
59
|
refMetadataById?: RefMetadataById | null;
|
|
78
60
|
refIconsPosition?: RefIconsPosition | null;
|
|
79
61
|
repoPath?: string;
|
|
62
|
+
searchMode?: GraphSearchMode;
|
|
80
63
|
columnsSettings?: GraphColumnsSettings;
|
|
81
64
|
themeOpacityFactor?: number;
|
|
82
65
|
translate?: TranslationFn;
|
|
@@ -214,6 +197,8 @@ declare class GraphContainer extends React.Component<Props, ComponentState> impl
|
|
|
214
197
|
includeOnlyRefsById: IncludeOnlyRefsById;
|
|
215
198
|
excludeRemotesByName: ExcludeRemotesByName;
|
|
216
199
|
includeOnlyRemotesByName: IncludeOnlyRemotesByName;
|
|
200
|
+
highlightedShas: HighlightedShas;
|
|
201
|
+
searchMode: GraphSearchMode;
|
|
217
202
|
scrollLeft: number;
|
|
218
203
|
scrollTop: number;
|
|
219
204
|
graphHeight: number;
|
|
@@ -380,6 +365,7 @@ declare class GraphContainer extends React.Component<Props, ComponentState> impl
|
|
|
380
365
|
onGraphVisibleRowsUpdated(): void;
|
|
381
366
|
getCurrentPlatform(): string;
|
|
382
367
|
isMacOSPlatform(): boolean;
|
|
368
|
+
isCommitListFiltered(): boolean;
|
|
383
369
|
getGraphColumnSettingFromZoneType(graphZone: GraphZone): GraphColumnSetting;
|
|
384
370
|
decorateWithHelmet: (container: ReactElement<'div'>, cssVariables: CssVariables, nonce?: string) => ReactElement<'div'>;
|
|
385
371
|
render(): ReactElement<'div'>;
|
|
@@ -12,6 +12,7 @@ type Props = {
|
|
|
12
12
|
clearCurrentlyHoveredGraphCommit: OnClearCurrentlyHoveredGraphCommit;
|
|
13
13
|
column: number;
|
|
14
14
|
columnColorByColumn: ColumnColorByColumn;
|
|
15
|
+
columnForColoring?: number;
|
|
15
16
|
commitZoneWidth: number;
|
|
16
17
|
cssVariables: CssVariables;
|
|
17
18
|
currentlyHoveredCommitSha?: Sha;
|
|
@@ -9,6 +9,7 @@ type Props = {
|
|
|
9
9
|
clearCurrentlyHoveredGraphCommit: OnClearCurrentlyHoveredGraphCommit;
|
|
10
10
|
children: ChildrenElements;
|
|
11
11
|
column: number;
|
|
12
|
+
columnForColoring?: number;
|
|
12
13
|
context?: GraphItemContext | null;
|
|
13
14
|
currentlyHoveredCommitSha: Sha | null;
|
|
14
15
|
dimRowsOfSelectedCommit?: boolean;
|
|
@@ -7,6 +7,7 @@ type RefNodesProps = {
|
|
|
7
7
|
onDoubleClickRef: OnDoubleClickRef;
|
|
8
8
|
enabledRefMetadataTypes: RefMetadataType[];
|
|
9
9
|
column: number;
|
|
10
|
+
columnForColoring?: number;
|
|
10
11
|
context: GraphItemContext | null;
|
|
11
12
|
enableShowHideRefsOptions: boolean;
|
|
12
13
|
getExternalIcon: GetExternalIcon;
|
|
@@ -41,5 +42,5 @@ type RefNodesProps = {
|
|
|
41
42
|
type: CommitType;
|
|
42
43
|
useColumnHeaderIcons: boolean;
|
|
43
44
|
};
|
|
44
|
-
declare function RefNodes({ enabledRefMetadataTypes, column, context, enableShowHideRefsOptions, getTargetRef, hasActive, hasRefs, getExternalIcon, includeOnlyRefsById, includeOnlyRemotesByName, isGhostRef, isHovered, isInUnsupportedRebase, numGraphColumns, onMissingRefMetadata, refGroupContexts, refGroupsByName, refIconsPosition, refMetadata, refNodeHovered, sha, showRemoteNamesOnRefs, showContextMenuForGroupedRef, onClickRef, onDoubleClickRef, onToggleRefNodesShown, onRefBeginDrag, onRefCanDrag, onRefCanDrop, onRefDragEnter, onRefDragLeave, onRefDrop, onRefEndDrag, translate, type, useColumnHeaderIcons, }: RefNodesProps): ReactElement<'span' | 'div'>;
|
|
45
|
+
declare function RefNodes({ enabledRefMetadataTypes, column, columnForColoring, context, enableShowHideRefsOptions, getTargetRef, hasActive, hasRefs, getExternalIcon, includeOnlyRefsById, includeOnlyRemotesByName, isGhostRef, isHovered, isInUnsupportedRebase, numGraphColumns, onMissingRefMetadata, refGroupContexts, refGroupsByName, refIconsPosition, refMetadata, refNodeHovered, sha, showRemoteNamesOnRefs, showContextMenuForGroupedRef, onClickRef, onDoubleClickRef, onToggleRefNodesShown, onRefBeginDrag, onRefCanDrag, onRefCanDrop, onRefDragEnter, onRefDragLeave, onRefDrop, onRefEndDrag, translate, type, useColumnHeaderIcons, }: RefNodesProps): ReactElement<'span' | 'div'>;
|
|
45
46
|
export default RefNodes;
|
|
@@ -155,3 +155,4 @@ export declare enum graphCommitDescDisplayModes {
|
|
|
155
155
|
}
|
|
156
156
|
export type GraphCommitDescDisplayMode = graphCommitDescDisplayModes.ALWAYS | graphCommitDescDisplayModes.ON_HOVER | graphCommitDescDisplayModes.NEVER;
|
|
157
157
|
export type ShiftSelectMode = 'simple';
|
|
158
|
+
export type GraphSearchMode = 'normal' | 'filter';
|
|
@@ -70,6 +70,7 @@ export interface GraphRowHelperProps {
|
|
|
70
70
|
selectedShas: Set<Sha>;
|
|
71
71
|
processedRows: ProcessedGraphRow[];
|
|
72
72
|
processedGraphRowBySha: ProcessedGraphRowBySha;
|
|
73
|
+
alwaysShowTimelines?: boolean;
|
|
73
74
|
}
|
|
74
75
|
export declare class GraphRowHelper {
|
|
75
76
|
props: GraphRowHelperProps;
|
|
@@ -79,6 +80,7 @@ export declare class GraphRowHelper {
|
|
|
79
80
|
getRow(rowIndex: number): ProcessedGraphRow | undefined;
|
|
80
81
|
getZoneWidth(graphZoneType: GraphZoneType, withoutVerticalScrollWidth?: boolean): number;
|
|
81
82
|
isDateTimeZoneActive(): boolean;
|
|
83
|
+
shouldShowTimelines(): boolean;
|
|
82
84
|
isFirstRow(rowIndex: number): boolean;
|
|
83
85
|
isColumnFollowingGraphColumn(graphZoneType: GraphZoneType): boolean;
|
|
84
86
|
isHighlighted(rowIndex: number): boolean;
|
|
@@ -71,6 +71,7 @@ export type RowEdges = {
|
|
|
71
71
|
[column: number]: RowEdge;
|
|
72
72
|
};
|
|
73
73
|
export interface CommonGraphRowProps {
|
|
74
|
+
alwaysShowTimelines?: boolean;
|
|
74
75
|
enabledRefMetadataTypes: RefMetadataType[];
|
|
75
76
|
enabledScrollMarkerTypes: GraphMarkerType[];
|
|
76
77
|
avatarUrlByEmail: AvatarUrlByEmail;
|
|
@@ -315,6 +316,7 @@ export interface GraphRefsData {
|
|
|
315
316
|
export interface ProcessedGraphRow extends GraphRow {
|
|
316
317
|
rowIndex?: number;
|
|
317
318
|
column: number;
|
|
319
|
+
columnForColoring?: number;
|
|
318
320
|
displayMessage: string;
|
|
319
321
|
displaySummary: string;
|
|
320
322
|
displayBody?: string;
|
|
@@ -453,3 +455,21 @@ export type OnRefCreate = (shorthand: RefShorthand, sha: Sha, refType: GraphRefT
|
|
|
453
455
|
export type OnRefCreateCancel = (shorthand: RefShorthand, sha: Sha, refType: GraphRefType, data?: any | null) => void;
|
|
454
456
|
export type OnRefCreateContextMenu = (event: React.MouseEvent<any>, shorthand: RefShorthand, sha: Sha, refType: GraphRefType, data?: any | null) => void;
|
|
455
457
|
export type OnRefShorthandChange = (shorthand: RefShorthand) => void;
|
|
458
|
+
export type OnClickGraphRow = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
459
|
+
export type OnDoubleClickGraphRow = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
460
|
+
export type OnClickGraphRef = (event: React.MouseEvent<any>, refGroup: GraphRefGroup, graphRow: GraphRow, metadataItem?: RefMetadataItem) => void;
|
|
461
|
+
export type OnDoubleClickGraphRef = (event: React.MouseEvent<any>, refGroup: GraphRefGroup, graphRow: GraphRow, metadataItem?: RefMetadataItem) => void;
|
|
462
|
+
export type OnRowContextMenu = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
463
|
+
export type OnRefContextMenu = (event: React.MouseEvent<any>, refGroup: GraphRefGroup, graphRow: GraphRow) => void;
|
|
464
|
+
export type OnToggleRefsVisibilityClick = (event: React.MouseEvent<any>, refs: GraphRefOptData[], visible: boolean, graphRow?: GraphRow) => void;
|
|
465
|
+
export type OnSelectGraphRows = (selectedRows: GraphRow[]) => void;
|
|
466
|
+
export type OnGraphRowHovered = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
467
|
+
export type OnGraphRowUnhovered = (event: React.MouseEvent<any>, graphZoneType: GraphZoneType, graphRow: GraphRow) => void;
|
|
468
|
+
export type OnGraphRefNodeHovered = (event: React.MouseEvent<any>, refGroup: GraphRefGroup, graphRow: GraphRow) => void;
|
|
469
|
+
export type OnGraphScrollForZone = (graphZoneType: GraphZoneType, scroll: ScrollParams) => void;
|
|
470
|
+
export type OnGraphRefNodeUnhovered = (event: React.MouseEvent<any> | React.FocusEvent<any> | null, refGroup: GraphRefGroup, graphRow: GraphRow) => void;
|
|
471
|
+
export type OnGraphColumnsReOrdered = (columnsSettings: GraphColumnsSettings) => void;
|
|
472
|
+
export type OnGraphColumnResized = (graphZoneType: GraphZoneType, columnSettings: GraphColumnSetting) => void;
|
|
473
|
+
export type OnShowMoreCommits = () => void;
|
|
474
|
+
export type OnEmailsMissingAvatarUrls = (emails: AvatarUrlByEmail) => void;
|
|
475
|
+
export type OnRefsMissingMetadata = (refs: RefsMissingMetadata) => void;
|
|
@@ -21,6 +21,7 @@ export declare class ProcessedGraphRowObj implements ProcessedGraphRow {
|
|
|
21
21
|
contexts?: RowContexts;
|
|
22
22
|
rowIndex?: number;
|
|
23
23
|
column: number;
|
|
24
|
+
columnForColoring?: number;
|
|
24
25
|
edgeColumnMaxes: number;
|
|
25
26
|
edges: RowEdges;
|
|
26
27
|
childRefs: ChildRefsByType;
|
|
@@ -41,7 +42,7 @@ export declare class ProcessedGraphRowObj implements ProcessedGraphRow {
|
|
|
41
42
|
get hasRefs(): boolean;
|
|
42
43
|
get hasChildRefs(): boolean;
|
|
43
44
|
get refsData(): GraphRefsData | undefined;
|
|
44
|
-
constructor(graphContainer: IGraphContainer, row: GraphRow, column?: number, edgeColumnMaxes?: number, edges?: RowEdges, childRefs?: ChildRefsByType, timeLineEntry?: TimelineEntry);
|
|
45
|
+
constructor(graphContainer: IGraphContainer, row: GraphRow, column?: number, edgeColumnMaxes?: number, edges?: RowEdges, childRefs?: ChildRefsByType, timeLineEntry?: TimelineEntry, columnForColoring?: number);
|
|
45
46
|
private updateSummaryAndBody;
|
|
46
47
|
private initializeRefGroups;
|
|
47
48
|
private addRefToRefGroup;
|
package/dist/index.d.ts
CHANGED
|
@@ -3,14 +3,6 @@ import ScrollbarContainer from './components/graph/common/ScrollbarContainer';
|
|
|
3
3
|
import GraphContainer from './components/graph/GraphContainer';
|
|
4
4
|
export * from './components/graph/GraphContainer';
|
|
5
5
|
export * from './components/dnd/DndComponent';
|
|
6
|
-
export * from './
|
|
7
|
-
export * from './domain/generic/GenericTypes';
|
|
8
|
-
export * from './domain/commit/CommitTypes';
|
|
9
|
-
export * from './domain/graph/GraphConstants';
|
|
10
|
-
export * from './domain/graph/GraphTypes';
|
|
11
|
-
export * from './domain/hostingservice/HostingServiceTypes';
|
|
12
|
-
export * from './domain/ref/RefConstants';
|
|
13
|
-
export * from './domain/ref/RefTypes';
|
|
14
|
-
export * from './domain/workdir/WorkDirTypes';
|
|
6
|
+
export * from './types';
|
|
15
7
|
export { DndComponent, ScrollbarContainer };
|
|
16
8
|
export default GraphContainer;
|