mirror of
https://github.com/umap-project/umap.git
synced 2025-04-28 19:42:36 +02:00
wip: use position: fixed for input/textarea in tableeditor
so it does not increase the cell width and does not change all the table size. Actually, there is still a small size change as we remove the cell content before adding the input/textarea, but more subtle than before
This commit is contained in:
parent
3fb7be28ec
commit
9f04f56c7c
2 changed files with 6 additions and 4 deletions
|
@ -70,9 +70,13 @@
|
|||
.umap-table-editor .formbox,
|
||||
.umap-table-editor input {
|
||||
margin: 0;
|
||||
min-height: initial;
|
||||
}
|
||||
.umap-table-editor input {
|
||||
.umap-table-editor textarea,
|
||||
.umap-table-editor input[type=text] {
|
||||
border-radius: initial;
|
||||
width: initial;
|
||||
position: fixed;
|
||||
}
|
||||
.umap-table-editor th button {
|
||||
transform: rotate(90deg);
|
||||
|
|
|
@ -215,10 +215,8 @@ export default class TableEditor extends WithTemplate {
|
|||
const tr = event.target.closest('tr')
|
||||
const feature = this.datalayer.getFeatureById(tr.dataset.feature)
|
||||
const handler = property === 'description' ? 'Textarea' : 'Input'
|
||||
const builder = new U.FormBuilder(feature, [[field, { handler: handler }]], {
|
||||
const builder = new U.FormBuilder(feature, [[field, { handler }]], {
|
||||
id: `umap-feature-properties_${L.stamp(feature)}`,
|
||||
className: 'trow',
|
||||
callback: feature.resetTooltip,
|
||||
})
|
||||
cell.innerHTML = ''
|
||||
cell.appendChild(builder.build())
|
||||
|
|
Loading…
Reference in a new issue