Skip to content

Commit

Permalink
feat: adding helper text to cells (#18382)
Browse files Browse the repository at this point in the history
* feat: adding helper text to cells

* fix: prettier

Co-authored-by: drdelambre <drdelambre>
  • Loading branch information
drdelambre authored Jun 9, 2020
1 parent 077949c commit 3c49190
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions ui/src/notebooks/context/notebook.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,16 @@ export const NotebookProvider: FC = ({children}) => {
return pipes.slice()
}
}

if (
pipe.type === 'query' &&
pipes.filter(p => p.type === 'query').length
) {
pipe.queries[0].text =
'// tip: use the __PREVIOUS_RESULT__ variable to link your queries\n\n' +
pipe.queries[0].text
}

if (pipes.length && pipe.type !== 'query') {
_setResults(add({...results[results.length - 1]}))
_setMeta(
Expand Down

0 comments on commit 3c49190

Please sign in to comment.