-
-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
15 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,27 @@ | ||
import React, { Component } from 'react'; | ||
import React, { Component } from "react"; | ||
|
||
import styles from './index.module.css'; | ||
import styles from "./index.module.css"; | ||
|
||
export interface LineGutterProps { | ||
/** | ||
* The gutter object | ||
*/ | ||
gutter: React.ReactNode; | ||
} | ||
|
||
interface LineGutterProps { | ||
gutter?: unknown; | ||
/** | ||
* The gutter object | ||
*/ | ||
gutter: React.ReactNode; | ||
} | ||
|
||
/** | ||
* The gutter is an element between the line number and content. | ||
*/ | ||
export default class LineGutter extends Component<LineGutterProps> { | ||
static defaultProps = { | ||
gutter: null, | ||
}; | ||
static defaultProps = { | ||
gutter: null, | ||
}; | ||
|
||
render() { | ||
const { gutter } = this.props; | ||
render() { | ||
const { gutter } = this.props; | ||
|
||
return ( | ||
<span className={`log-gutter ${styles.lineGutter}`}>{gutter}</span> | ||
); | ||
} | ||
return ( | ||
<span className={`log-gutter ${styles.lineGutter}`}>{gutter}</span> | ||
); | ||
} | ||
} |