"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "app/src/ui/diff/diff-helpers.tsx" between
desktop-release-2.7.2-linux1.tar.gz and desktop-release-2.8.0-linux1.tar.gz

About: GitHub Desktop (Linux) is an open source Electron-based GitHub app. It is written in TypeScript and uses React. A fork of GitHub Desktop to support various Linux distributions. Release candidate.

diff-helpers.tsx  (desktop-release-2.7.2-linux1):diff-helpers.tsx  (desktop-release-2.8.0-linux1)
import * as React from 'react' import * as React from 'react'
import { ILineTokens } from '../../lib/highlighter/types' import { ILineTokens } from '../../lib/highlighter/types'
import classNames from 'classnames' import classNames from 'classnames'
import { relativeChanges } from './changed-range' import { relativeChanges } from './changed-range'
import { mapKeysEqual } from '../../lib/equality' import { mapKeysEqual } from '../../lib/equality'
import { import {
WorkingDirectoryFileChange, WorkingDirectoryFileChange,
CommittedFileChange, CommittedFileChange,
} from '../../models/status' } from '../../models/status'
import { DiffHunkExpansionType } from '../../models/diff/raw-diff'
/** /**
* DiffRowType defines the different types of * DiffRowType defines the different types of
* rows that a diff visualization can have. * rows that a diff visualization can have.
* *
* It contains similar values than DiffLineType * It contains similar values than DiffLineType
* with the addition of `Modified`, which * with the addition of `Modified`, which
* corresponds to a line that has both deleted and * corresponds to a line that has both deleted and
* added content. * added content.
*/ */
skipping to change at line 48 skipping to change at line 49
* The actual contents of the diff line. * The actual contents of the diff line.
*/ */
readonly content: string readonly content: string
/** /**
* The line number on the source file. * The line number on the source file.
*/ */
readonly lineNumber: number readonly lineNumber: number
/** /**
* The line number on the diff. * The line number on the original diff (without expansion).
* This is used for discarding lines * This is used for discarding lines and for partial committing lines.
* and for partial committing lines.
*/ */
readonly diffLineNumber: number readonly diffLineNumber: number | null
/** /**
* Flag to display that this diff line lacks a new line. * Flag to display that this diff line lacks a new line.
* This is used to display when a newline is * This is used to display when a newline is
* added or removed to the last line of a file. * added or removed to the last line of a file.
*/ */
readonly noNewLineIndicator: boolean readonly noNewLineIndicator: boolean
/** /**
* Whether the diff line has been selected for partial committing. * Whether the diff line has been selected for partial committing.
skipping to change at line 184 skipping to change at line 184
/** /**
* IDiffRowContext represents a row that contains the header * IDiffRowContext represents a row that contains the header
* of a diff hunk. * of a diff hunk.
*/ */
interface IDiffRowHunk { interface IDiffRowHunk {
readonly type: DiffRowType.Hunk readonly type: DiffRowType.Hunk
/** /**
* The actual contents of the line. * The actual contents of the line.
*/ */
readonly content: string readonly content: string
/** How the hunk can be expanded. */
readonly expansionType: DiffHunkExpansionType
/** Index of the hunk in the diff. */
readonly hunkIndex: number
} }
export type DiffRow = export type DiffRow =
| IDiffRowAdded | IDiffRowAdded
| IDiffRowDeleted | IDiffRowDeleted
| IDiffRowModified | IDiffRowModified
| IDiffRowContext | IDiffRowContext
| IDiffRowHunk | IDiffRowHunk
export type SimplifiedDiffRow = export type SimplifiedDiffRow =
 End of changes. 4 change blocks. 
4 lines changed or deleted 10 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)