hedgeagent/1.12.0 #1

Open
sa6anw wants to merge 201 commits from hedgeagent/1.12.0 into hedgeagent/1.10.5
4 changed files with 9 additions and 3 deletions
Showing only changes of commit fd4d5bfbd1 - Show all commits

View File

@@ -8,6 +8,7 @@ const config = require('./config')
exports.generateAvatar = function (name) {
// use darker colors for better contrast
const color = new Chance(name).color({
format: 'hex',
max_red: 150,
max_green: 150,
max_blue: 150

View File

@@ -710,7 +710,7 @@ function connection (socket) {
// initialize user data
// random color
let color = chance.color()
let color = chance.color({ format: 'hex' })
// make sure color not duplicated or reach max random count
if (notes[noteId]) {
let randomcount = 0
@@ -723,7 +723,7 @@ function connection (socket) {
}
})
if (found) {
color = chance.color()
color = chance.color({ format: 'hex' })
randomcount++
}
} while (found && randomcount < maxrandomcount)

View File

@@ -1,5 +1,10 @@
# Release Notes
## Unreleased
### Bugfixes
- Random colors for user's cursors and selections are now always in hex format to avoid conversion errors
## <i class="fa fa-tag"></i> 1.10.6 <i class="fa fa-calendar-o"></i> 2026-02-04
### Security fixes

View File

@@ -427,7 +427,7 @@ const supportExtraTags = [
text: '[random color tag]',
search: '[]',
command: function () {
const color = chance().color()
const color = chance().color({ format: 'hex' })
return '[color=' + color + ']'
}
}