fix format
This commit is contained in:
@@ -1,10 +1,12 @@
|
|||||||
const iskFormater = new Intl.NumberFormat("is-IS", {
|
const iskFormater = new Intl.NumberFormat("is-IS", {
|
||||||
minimumFractionDigits: 2,
|
minimumFractionDigits: 2,
|
||||||
|
maximumFractionDigits: 2
|
||||||
});
|
});
|
||||||
|
|
||||||
export const formatIsk = (value: number | bigint) => iskFormater.format(value) + " ISK";
|
export const formatIsk = (value: number | bigint) => iskFormater.format(value) + " ISK";
|
||||||
|
|
||||||
export const percentFormater = new Intl.NumberFormat("en-US", {
|
export const percentFormater = new Intl.NumberFormat("en-US", {
|
||||||
style: "percent",
|
style: "percent",
|
||||||
minimumFractionDigits: 0
|
minimumFractionDigits: 0,
|
||||||
|
maximumFractionDigits: 0
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -4,12 +4,12 @@ import { useStorage } from '@vueuse/core';
|
|||||||
import { ref } from 'vue';
|
import { ref } from 'vue';
|
||||||
|
|
||||||
const items = ref("");
|
const items = ref("");
|
||||||
const minerals = ref("");
|
const materials = ref("");
|
||||||
const efficiency = useStorage('reprocess-efficiency', 0.55);
|
const efficiency = useStorage('reprocess-efficiency', 0.55);
|
||||||
|
|
||||||
const result = ref<ReprocessItemValues[]>([]);
|
const result = ref<ReprocessItemValues[]>([]);
|
||||||
|
|
||||||
const send = async () => result.value = await reprocess(items.value, minerals.value, efficiency.value);
|
const send = async () => result.value = await reprocess(items.value, materials.value, efficiency.value);
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
@@ -22,7 +22,7 @@ const send = async () => result.value = await reprocess(items.value, minerals.va
|
|||||||
</div>
|
</div>
|
||||||
<div class="flex items-stretch">
|
<div class="flex items-stretch">
|
||||||
<ReprocessInput name="Item JSON" v-model="items" />
|
<ReprocessInput name="Item JSON" v-model="items" />
|
||||||
<ReprocessInput name="Mineral JSON" v-model="minerals" />
|
<ReprocessInput name="Materials JSON" v-model="materials" />
|
||||||
</div>
|
</div>
|
||||||
<div class="grid my-2">
|
<div class="grid my-2">
|
||||||
<button class="justify-self-end" @click="send">Send</button>
|
<button class="justify-self-end" @click="send">Send</button>
|
||||||
|
|||||||
Reference in New Issue
Block a user