fix(filter): move spaces out of button to after the matched filter value to prevent removal of spaces
This commit is contained in:
parent
e534a6a5bf
commit
6fbd24d5f6
@ -91,7 +91,15 @@ const highlightedFilterQuery = computed(() => {
|
|||||||
value = ''
|
value = ''
|
||||||
}
|
}
|
||||||
|
|
||||||
return `${o}${spacesBefore}${token}${spacesAfter}<button class="is-primary filter-query__date_value" data-position="${position}">${value}</button><span class="filter-query__date_value_placeholder">${value}</span>`
|
let endPadding = ''
|
||||||
|
if(value.endsWith(' ')) {
|
||||||
|
const fullLength = value.length
|
||||||
|
value = value.trimEnd()
|
||||||
|
const numberOfRemovedSpaces = fullLength - value.length
|
||||||
|
endPadding = endPadding.padEnd(numberOfRemovedSpaces, ' ')
|
||||||
|
}
|
||||||
|
|
||||||
|
return `${o}${spacesBefore}${token}${spacesAfter}<button class="is-primary filter-query__date_value" data-position="${position}">${value}</button><span class="filter-query__date_value_placeholder">${value}</span>${endPadding}`
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
ASSIGNEE_FIELDS
|
ASSIGNEE_FIELDS
|
||||||
|
Loading…
x
Reference in New Issue
Block a user