Skip to content

Commit 7dc5d1f

Browse files
authored
fix: numeric sorting of tool macros in spoolman card
Signed-off-by: wasikuss <wasikuss@gmail.com>
1 parent 2425607 commit 7dc5d1f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/widgets/spoolman/SpoolmanCard.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ export default class SpoolmanCard extends Mixins(StateMixin) {
255255
256256
return macros
257257
.filter((macro): macro is MacroWithSpoolId => macro.variables != null && 'spool_id' in macro.variables)
258-
.sort((a, b) => a.name.toLowerCase().localeCompare(b.name.toLowerCase()))
258+
.sort((a, b) => a.name.toLowerCase().localeCompare(b.name.toLowerCase(), undefined, { numeric: true }))
259259
}
260260
261261
get remainingFilamentUnit (): SpoolmanRemainingFilamentUnit {

0 commit comments

Comments
 (0)