diff --git a/src/App.css b/src/App.css index e636f69..72c065c 100644 --- a/src/App.css +++ b/src/App.css @@ -212,4 +212,8 @@ nav.navbar { color: #000080; font-weight: bold; padding-right: 10px; -} \ No newline at end of file +} + +.wide-tooltip .tooltip-inner { + max-width: none; +} diff --git a/src/DirectoryBreadcrumbs.jsx b/src/DirectoryBreadcrumbs.jsx index 47e5074..18b1d7d 100644 --- a/src/DirectoryBreadcrumbs.jsx +++ b/src/DirectoryBreadcrumbs.jsx @@ -12,26 +12,25 @@ export function DirectoryBreadcrumbs() { breadcrumbs.unshift(state) } - // TODO: get name of "snapshot"!!?? ##### - // TODO: no tooltip if no OID ##### // TODO: enable copying of OID to clipboard ##### - // TODO: disable / improve wrapping of tooltip ##### - // TODO: there is some flickering if hovering changes ##### - // TODO: disable clicking on current breadcrumb item ##### return ( - Snapshots ##### { breadcrumbs.map((state, i) => { const index = breadcrumbs.length - i - 1 // revert index + let item = { + if (index) history.go(-index); + }} + active={!index}> + {state.label} + ; return ( - OID: {state.oid}}> - history.go(-index)} - active={!index}> - {state.label} - - + state.oid + ? OID: {state.oid}}> + {item} + + : item ); }) } diff --git a/src/SnapshotsTable.jsx b/src/SnapshotsTable.jsx index e5b752d..dbadf69 100644 --- a/src/SnapshotsTable.jsx +++ b/src/SnapshotsTable.jsx @@ -248,8 +248,8 @@ export class SnapshotsTable extends Component { originalSnapshotDescription: x.description, }) }} - title={x.description + " - Click to update snapshot description."} - className={x.description ? "text-warning" : "text-muted"}>; + title={x.description + " - Click to update snapshot description."} + className={x.description ? "text-warning" : "text-muted"}>; } newPinFor(x) { @@ -321,6 +321,9 @@ export class SnapshotsTable extends Component { if (isLoading && !snapshots) { return ; } + const searchParams = new URLSearchParams(window.location.search); + const path = searchParams.get("path"); + snapshots.sort((a, b) => -compare(a.startTime, b.startTime)); @@ -336,7 +339,7 @@ export class SnapshotsTable extends Component { width: 200, accessor: x => { let timestamp = rfc3339TimestampForDisplay(x.startTime); - return {timestamp}; + return {timestamp}; }, }, { id: 'description', @@ -466,9 +469,9 @@ export class SnapshotsTable extends Component { Enter new description this.setState({ updatedSnapshotDescription: e.target.value })} /> + size="sm" + value={this.state.updatedSnapshotDescription} + onChange={e => this.setState({ updatedSnapshotDescription: e.target.value })} />