@@ -11,7 +11,7 @@ import { useIntl } from "react-intl";
11
11
import { alert_message } from "@cocalc/frontend/alerts" ;
12
12
import { Icon } from "@cocalc/frontend/components" ;
13
13
import { jupyter , labels } from "@cocalc/frontend/i18n" ;
14
- import { commands } from "./commands" ;
14
+ import { commands , CLEAR_CELL_OUTPUT_LABEL } from "./commands" ;
15
15
import {
16
16
CODE_BAR_BTN_STYLE ,
17
17
COPY_CELL_ICON ,
@@ -110,6 +110,13 @@ export function CodeBarDropdownMenu({ actions, frameActions, id, cell }) {
110
110
onClick : pasteFromClipboard ,
111
111
} ,
112
112
{ key : "divider5" , type : "divider" } ,
113
+ {
114
+ key : "clear-output" ,
115
+ label : intl . formatMessage ( CLEAR_CELL_OUTPUT_LABEL ) ,
116
+ icon : < Icon name = "battery-empty" /> ,
117
+ onClick : ( ) => frameActions . current ?. clear_selected_outputs ( ) ,
118
+ } ,
119
+ { key : "divider9" , type : "divider" } ,
113
120
{
114
121
key : "cell-type" ,
115
122
label : intl . formatMessage ( jupyter . commands . cell_type_menu ) ,
@@ -261,7 +268,7 @@ export function CodeBarDropdownMenu({ actions, frameActions, id, cell }) {
261
268
onClick : ( ) => frameActions . current ?. delete_selected_cells ( ) ,
262
269
} ,
263
270
264
- { key : "divider6 " , type : "divider" } ,
271
+ { key : "divider8 " , type : "divider" } ,
265
272
{
266
273
key : "split-cell" ,
267
274
label : intl . formatMessage ( {
0 commit comments