We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7626d08 commit c73915eCopy full SHA for c73915e
src/extensions/core/editAttention.ts
@@ -21,7 +21,6 @@ app.registerExtension({
21
const floatWeight = parseFloat(weight)
22
if (isNaN(floatWeight)) return weight
23
const newWeight = floatWeight + delta
24
- if (newWeight < 0) return '0'
25
return String(Number(newWeight.toFixed(10)))
26
}
27
@@ -143,7 +142,7 @@ app.registerExtension({
143
142
// Increment the weight
144
const weightDelta = event.key === 'ArrowUp' ? delta : -delta
145
const updatedText = selectedText.replace(
146
- /\((.*):(\d+(?:\.\d+)?)\)/,
+ /\((.*):([+-]?\d+(?:\.\d+)?)\)/,
147
(match, text, weight) => {
148
weight = incrementWeight(weight, weightDelta)
149
if (weight == 1) {
0 commit comments