chore: prettier

This commit is contained in:
Yohan Boniface 2024-05-07 12:31:28 +02:00
parent 8d24cc0ceb
commit b450acf81d
6 changed files with 15 additions and 13 deletions

View file

@ -33,7 +33,7 @@ export default class Orderable {
onDragStart(e) { onDragStart(e) {
// e.target is the source node. // e.target is the source node.
const realSrc = document.elementFromPoint(e.clientX, e.clientY); const realSrc = document.elementFromPoint(e.clientX, e.clientY)
// Only allow drag from the handle // Only allow drag from the handle
if (!realSrc.classList.contains('icon-drag')) { if (!realSrc.classList.contains('icon-drag')) {
e.preventDefault() e.preventDefault()

View file

@ -83,7 +83,7 @@ export const SCHEMA = {
easing: { easing: {
type: Boolean, type: Boolean,
impacts: [], impacts: [],
default: false default: false,
}, },
editinosmControl: { editinosmControl: {
type: Boolean, type: Boolean,

View file

@ -1,4 +1,4 @@
import { template } from "./utils.js" import { template } from './utils.js'
export default class URLs { export default class URLs {
constructor(serverUrls) { constructor(serverUrls) {

View file

@ -196,8 +196,11 @@ U.ToggleEditAction = U.BaseFeatureAction.extend({
}, },
onClick: function (e) { onClick: function (e) {
if (this.feature._toggleEditing) this.feature._toggleEditing(e) // Path if (this.feature._toggleEditing) {
else this.feature.edit(e) // Marker this.feature._toggleEditing(e) // Path
} else {
this.feature.edit(e) // Marker
}
}, },
}) })

View file

@ -878,12 +878,11 @@ L.FormBuilder.MultiChoice = L.FormBuilder.Element.extend({
}, },
fetch: function () { fetch: function () {
let value = (this.backup = this.toHTML()) this.backup = this.toHTML()
if (!this.container.querySelector(`input[type="radio"][value="${value}"]`)) let value = this.backup
value = if (!this.container.querySelector(`input[type="radio"][value="${value}"]`)) {
typeof this.options.default !== 'undefined' value = this.options.default !== undefined ? this.options.default : this.default
? this.options.default }
: this.default
this.container.querySelector(`input[type="radio"][value="${value}"]`).checked = true this.container.querySelector(`input[type="radio"][value="${value}"]`).checked = true
}, },

View file

@ -463,8 +463,8 @@ U.Layer.Heat = L.HeatLayer.extend({
this._latlngs[i].alt !== undefined this._latlngs[i].alt !== undefined
? this._latlngs[i].alt ? this._latlngs[i].alt
: this._latlngs[i][2] !== undefined : this._latlngs[i][2] !== undefined
? +this._latlngs[i][2] ? +this._latlngs[i][2]
: 1 : 1
grid[y] = grid[y] || [] grid[y] = grid[y] || []
cell = grid[y][x] cell = grid[y][x]