diff options
author | 0x85FB9C51 <77808164+0x85FB9C51@users.noreply.github.com> | 2021-07-21 08:56:39 -0400 |
---|---|---|
committer | 0x85FB9C51 <77808164+0x85FB9C51@users.noreply.github.com> | 2021-07-21 08:56:39 -0400 |
commit | 6330a8adc6e85bfa5e0b24016e5d76d85bc07e41 (patch) | |
tree | 91f8088675344f217e5bf1eafa704758f451b6dc | |
parent | b5494be46ea1e02b85d24d9405f0d9c60ba2b0f1 (diff) |
fixed date formatting
-rw-r--r-- | src/client/views/collections/collectionSchema/CollectionSchemaCells.tsx | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/client/views/collections/collectionSchema/CollectionSchemaCells.tsx b/src/client/views/collections/collectionSchema/CollectionSchemaCells.tsx index f75179cea..a8d901f4d 100644 --- a/src/client/views/collections/collectionSchema/CollectionSchemaCells.tsx +++ b/src/client/views/collections/collectionSchema/CollectionSchemaCells.tsx @@ -351,13 +351,16 @@ export class CollectionSchemaDateCell extends CollectionSchemaCell { //} } + // If the cell is not clicked on, render the date normally. Otherwise, render a date picker. render() { - return !this.props.isFocused ? <span onPointerDown={this.onPointerDown}>{this._date ? Field.toString(this._date as Field) : "--"}</span> : - <DatePicker - selected={this._date?.date || new Date} - onSelect={date => this.handleChange(date)} - onChange={date => this.handleChange(date)} - />; + return !this.props.isFocused ? <span style={{ paddingLeft: 20 + "px" }} onPointerDown={this.onPointerDown}>{this._date ? Field.toString(this._date as Field) : "--"}</span> : + <div style={{ paddingLeft: 20 + "px" }}> + <DatePicker + selected={this._date?.date || new Date} + onSelect={date => this.handleChange(date)} + onChange={date => this.handleChange(date)} + /> + </div> } } |