File tree 1 file changed +0
-43
lines changed
1 file changed +0
-43
lines changed Original file line number Diff line number Diff line change 116
116
" button.on_click(on_button_clicked)"
117
117
]
118
118
},
119
- {
120
- "cell_type" : " markdown" ,
121
- "metadata" : {
122
- "slideshow" : {
123
- "slide_type" : " slide"
124
- }
125
- },
126
- "source" : [
127
- " ### on_submit"
128
- ]
129
- },
130
- {
131
- "cell_type" : " markdown" ,
132
- "metadata" : {},
133
- "source" : [
134
- " The `Text` widget also has a special `on_submit` event. The `on_submit` event fires when the user hits return."
135
- ]
136
- },
137
- {
138
- "cell_type" : " code" ,
139
- "execution_count" : 4 ,
140
- "metadata" : {},
141
- "outputs" : [
142
- {
143
- "data" : {
144
- "application/vnd.jupyter.widget-view+json" : {
145
- "model_id" : " cab0a6538a00491f95c48e77707e9ad8"
146
- }
147
- },
148
- "metadata" : {},
149
- "output_type" : " display_data"
150
- }
151
- ],
152
- "source" : [
153
- " text = widgets.Text()\n " ,
154
- " display(text)\n " ,
155
- " \n " ,
156
- " def handle_submit(sender):\n " ,
157
- " print(text.value)\n " ,
158
- " \n " ,
159
- " text.on_submit(handle_submit)"
160
- ]
161
- },
162
119
{
163
120
"cell_type" : " markdown" ,
164
121
"metadata" : {
You can’t perform that action at this time.
0 commit comments