adminforth 1.6.3-next.13 → 1.6.3-next.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -42,7 +42,7 @@ const props = withDefaults(defineProps<Props>(), {
42
42
  const percentage = computed((): number => {
43
43
  const min = props.minValue
44
44
  const max = props.maxValue
45
- return Math.round(((props.currentValue - min) / (max - min)) * 100)
45
+ return Math.floor(((props.currentValue - min) / (max - min)) * 1000) / 10
46
46
  })
47
47
 
48
48
  const progressText = computed((): string => {
@@ -398,9 +398,9 @@ function onSortButtonClick(event, field) {
398
398
  } else {
399
399
  const sortField = sort.value[sortIndex];
400
400
  if (sortField.direction === 'asc') {
401
- sort.value[sortIndex].direction = 'desc';
401
+ sort.value = sort.value.map((s) => s.field === field ? {field, direction: 'desc'} : s);
402
402
  } else {
403
- sort.value.splice(sortIndex, 1);
403
+ sort.value = sort.value.filter((s) => s.field !== field);
404
404
  }
405
405
  }
406
406
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "adminforth",
3
- "version": "1.6.3-next.13",
3
+ "version": "1.6.3-next.15",
4
4
  "description": "OpenSource Vue3 powered forth-generation admin panel",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",