forstok-ui-lib 5.2.7 → 5.2.8
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.
- package/dist/index.d.ts +2 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +101 -101
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/assets/javascripts/function.ts +6 -0
package/package.json
CHANGED
|
@@ -93,4 +93,10 @@ export const generateMessageQuestion = (type: string, title: string, subtitle: s
|
|
|
93
93
|
cancelCallback: cancelCallback
|
|
94
94
|
}
|
|
95
95
|
return result
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
export const currencyNumber = (value: number) => {
|
|
99
|
+
if(value === null) return value
|
|
100
|
+
else if(typeof value == 'number') return value.toLocaleString('id-ID', {style: 'currency', currency: 'IDR', minimumFractionDigits: 0})
|
|
101
|
+
else return value
|
|
96
102
|
}
|