aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
author0x85FB9C51 <77808164+0x85FB9C51@users.noreply.github.com>2021-07-21 08:56:39 -0400
committer0x85FB9C51 <77808164+0x85FB9C51@users.noreply.github.com>2021-07-21 08:56:39 -0400
commit6330a8adc6e85bfa5e0b24016e5d76d85bc07e41 (patch)
tree91f8088675344f217e5bf1eafa704758f451b6dc /src
parentb5494be46ea1e02b85d24d9405f0d9c60ba2b0f1 (diff)
fixed date formatting
Diffstat (limited to 'src')
-rw-r--r--src/client/views/collections/collectionSchema/CollectionSchemaCells.tsx15
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>
}
}