Skip to content

Commit e37ca82

Browse files
display chosen file path in form as text instead of readonly input. (#417)
1 parent 4bd1d39 commit e37ca82

File tree

2 files changed

+11
-8
lines changed

2 files changed

+11
-8
lines changed

packages/base/src/formbuilder/objectform/fileselectorwidget.tsx

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -113,18 +113,13 @@ export const FileSelectorWidget = (props: any) => {
113113

114114
return (
115115
<div>
116-
<div>
117-
<input
118-
type="text"
119-
className="jp-mod-styled"
120-
value={serverFilePath || ''}
121-
readOnly
122-
style={{ width: '70%', marginRight: '10px' }}
123-
/>
116+
<div className="file-container">
124117
<button className="jp-mod-styled" onClick={handleBrowseServerFiles}>
125118
Browse Server Files
126119
</button>
120+
<p>{serverFilePath || ''}</p>
127121
</div>
122+
128123
<div>
129124
<h3 className="jp-FormGroup-fieldLabel jp-FormGroup-contentItem">
130125
Or enter external URL

python/jupytergis_lab/style/base.css

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -732,3 +732,11 @@ div.jGIS-toolbar-widget > div.jp-Toolbar-item:last-child {
732732
.jgis-identify-grid-body:last-of-type strong:last-of-type {
733733
padding-bottom: 8px;
734734
}
735+
736+
/* Style the file path text */
737+
.file-container {
738+
display: flex;
739+
align-items: center;
740+
margin-bottom: 16px;
741+
gap: 10px;
742+
}

0 commit comments

Comments
 (0)