@@ -10,20 +10,20 @@ import {
10
10
ILayoutRestorer ,
11
11
JupyterFrontEnd ,
12
12
JupyterFrontEndPlugin ,
13
- ILabShell
13
+ ILabShell ,
14
14
} from '@jupyterlab/application' ;
15
15
import { ReactWidget } from '@jupyterlab/apputils' ;
16
16
import {
17
17
Registry ,
18
18
relativeNestedDataType ,
19
19
nestedDataType ,
20
- URL_
20
+ URL_ ,
21
21
} from '@jupyterlab/dataregistry' ;
22
22
import { IRegistry } from '@jupyterlab/dataregistry-registry-extension' ;
23
23
import { Widget } from '@lumino/widgets' ;
24
24
import { widgetDataType , reactDataType } from './widgets' ;
25
25
import { IActiveDataset } from '.' ;
26
- import { luminoWidget } from './utils' ;
26
+ import { LuminoWidget } from './utils' ;
27
27
import { Observable } from 'rxjs' ;
28
28
29
29
function InnerBrowser ( { registry, url } : { registry : Registry ; url : URL_ } ) {
@@ -56,9 +56,9 @@ function InnerBrowser({ registry, url }: { registry: Registry; url: URL_ }) {
56
56
React . useEffect ( ( ) => {
57
57
if ( children$ ) {
58
58
const subscription = children$ . subscribe ( {
59
- next : value => {
59
+ next : ( value ) => {
60
60
setChildren ( [ ...value ] ) ;
61
- }
61
+ } ,
62
62
} ) ;
63
63
return ( ) => subscription . unsubscribe ( ) ;
64
64
}
@@ -81,7 +81,7 @@ function InnerBrowser({ registry, url }: { registry: Registry; url: URL_ }) {
81
81
for ( const child of children ) {
82
82
options . set ( `child-${ child } ` , {
83
83
value : child ,
84
- type : 'child'
84
+ type : 'child' ,
85
85
} ) ;
86
86
}
87
87
@@ -104,14 +104,14 @@ function InnerBrowser({ registry, url }: { registry: Registry; url: URL_ }) {
104
104
const widgetCreator = widgets . get ( name ) ;
105
105
return (
106
106
components . get ( name ) ||
107
- ( widgetCreator && < luminoWidget widget = { widgetCreator ( ) } /> )
107
+ ( widgetCreator && < LuminoWidget widget = { widgetCreator ( ) } /> )
108
108
) ;
109
109
} , [ options , label , components , widgets ] ) ;
110
110
// Use the widget creator to set the current widget
111
111
112
112
return (
113
113
< >
114
- < select value = { label } onChange = { event => setLabel ( event . target . value ) } >
114
+ < select value = { label } onChange = { ( event ) => setLabel ( event . target . value ) } >
115
115
{ [ ...options . entries ( ) ] . map ( ( [ idx , { value, type } ] ) => (
116
116
< option key = { idx } value = { idx } >
117
117
{ type === 'child' && value . startsWith ( url )
@@ -136,7 +136,7 @@ function InnerBrowser({ registry, url }: { registry: Registry; url: URL_ }) {
136
136
137
137
function Browser ( {
138
138
registry,
139
- active
139
+ active,
140
140
} : {
141
141
registry : Registry ;
142
142
active : IActiveDataset ;
@@ -152,10 +152,10 @@ function Browser({
152
152
React . useEffect ( ( ) => {
153
153
if ( follow ) {
154
154
const subscription = active . subscribe ( {
155
- next : value => {
155
+ next : ( value ) => {
156
156
setURL ( value || '' ) ;
157
157
setSubmittedURL ( value || '' ) ;
158
- }
158
+ } ,
159
159
} ) ;
160
160
return ( ) => subscription . unsubscribe ( ) ;
161
161
}
@@ -164,7 +164,7 @@ function Browser({
164
164
return (
165
165
< div className = "jl-dr-browser" >
166
166
< form
167
- onSubmit = { event => {
167
+ onSubmit = { ( event ) => {
168
168
setSubmittedURL ( url ) ;
169
169
event . preventDefault ( ) ;
170
170
} }
@@ -174,7 +174,7 @@ function Browser({
174
174
type = "text"
175
175
value = { url }
176
176
placeholder = "file:///data.csv"
177
- onChange = { event => setURL ( event . target . value ) }
177
+ onChange = { ( event ) => setURL ( event . target . value ) }
178
178
className = "jl-dr-browser-url-text"
179
179
/>
180
180
< input type = "submit" value = "Submit" />
@@ -184,7 +184,7 @@ function Browser({
184
184
< input
185
185
type = "checkbox"
186
186
checked = { follow }
187
- onChange = { e => {
187
+ onChange = { ( e ) => {
188
188
if ( e . target . checked ) {
189
189
setURL ( active . value || '' ) ;
190
190
}
@@ -201,7 +201,7 @@ export default {
201
201
activate,
202
202
id : '@jupyterlab/dataregistry-extension:browser' ,
203
203
requires : [ ILabShell , IRegistry , ILayoutRestorer , IActiveDataset ] ,
204
- autoStart : true
204
+ autoStart : true ,
205
205
} as JupyterFrontEndPlugin < void > ;
206
206
207
207
function activate (
0 commit comments