parent
9e918c3b8a
commit
5dc9f9693b
@ -1,8 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<project version="4"> |
|
||||||
<component name="ProjectModuleManager"> |
|
||||||
<modules> |
|
||||||
<module fileurl="file://$PROJECT_DIR$/.idea/numeral-es6.iml" filepath="$PROJECT_DIR$/.idea/numeral-es6.iml" /> |
|
||||||
</modules> |
|
||||||
</component> |
|
||||||
</project> |
|
@ -1,12 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<module type="WEB_MODULE" version="4"> |
|
||||||
<component name="NewModuleRootManager"> |
|
||||||
<content url="file://$MODULE_DIR$"> |
|
||||||
<excludeFolder url="file://$MODULE_DIR$/.tmp" /> |
|
||||||
<excludeFolder url="file://$MODULE_DIR$/temp" /> |
|
||||||
<excludeFolder url="file://$MODULE_DIR$/tmp" /> |
|
||||||
</content> |
|
||||||
<orderEntry type="inheritedJdk" /> |
|
||||||
<orderEntry type="sourceFolder" forTests="false" /> |
|
||||||
</component> |
|
||||||
</module> |
|
@ -1,6 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<project version="4"> |
|
||||||
<component name="VcsDirectoryMappings"> |
|
||||||
<mapping directory="$PROJECT_DIR$" vcs="Git" /> |
|
||||||
</component> |
|
||||||
</project> |
|
@ -1,247 +0,0 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
|
||||||
<project version="4"> |
|
||||||
<component name="ChangeListManager"> |
|
||||||
<list default="true" id="9a0b394d-0612-44ab-871e-56f962b5d644" name="Default" comment=""> |
|
||||||
<change beforePath="" afterPath="$PROJECT_DIR$/.gitignore" /> |
|
||||||
<change beforePath="" afterPath="$PROJECT_DIR$/.idea/vcs.xml" /> |
|
||||||
<change beforePath="" afterPath="$PROJECT_DIR$/index.d.ts" /> |
|
||||||
<change beforePath="" afterPath="$PROJECT_DIR$/index.js" /> |
|
||||||
<change beforePath="" afterPath="$PROJECT_DIR$/package.json" /> |
|
||||||
<change beforePath="$PROJECT_DIR$/README.md" afterPath="$PROJECT_DIR$/README.md" /> |
|
||||||
</list> |
|
||||||
<ignored path="$PROJECT_DIR$/.tmp/" /> |
|
||||||
<ignored path="$PROJECT_DIR$/temp/" /> |
|
||||||
<ignored path="$PROJECT_DIR$/tmp/" /> |
|
||||||
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" /> |
|
||||||
<option name="TRACKING_ENABLED" value="true" /> |
|
||||||
<option name="SHOW_DIALOG" value="false" /> |
|
||||||
<option name="HIGHLIGHT_CONFLICTS" value="true" /> |
|
||||||
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" /> |
|
||||||
<option name="LAST_RESOLUTION" value="IGNORE" /> |
|
||||||
</component> |
|
||||||
<component name="FileEditorManager"> |
|
||||||
<leaf> |
|
||||||
<file leaf-file-name="package.json" pinned="false" current-in-tab="false"> |
|
||||||
<entry file="file://$PROJECT_DIR$/package.json"> |
|
||||||
<provider selected="true" editor-type-id="text-editor"> |
|
||||||
<state relative-caret-position="391"> |
|
||||||
<caret line="23" column="1" lean-forward="false" selection-start-line="23" selection-start-column="1" selection-end-line="23" selection-end-column="1" /> |
|
||||||
<folding /> |
|
||||||
</state> |
|
||||||
</provider> |
|
||||||
</entry> |
|
||||||
</file> |
|
||||||
<file leaf-file-name="index.d.ts" pinned="false" current-in-tab="true"> |
|
||||||
<entry file="file://$PROJECT_DIR$/index.d.ts"> |
|
||||||
<provider selected="true" editor-type-id="text-editor"> |
|
||||||
<state relative-caret-position="68"> |
|
||||||
<caret line="4" column="0" lean-forward="false" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" /> |
|
||||||
<folding /> |
|
||||||
</state> |
|
||||||
</provider> |
|
||||||
</entry> |
|
||||||
</file> |
|
||||||
<file leaf-file-name=".gitignore" pinned="false" current-in-tab="false"> |
|
||||||
<entry file="file://$PROJECT_DIR$/.gitignore"> |
|
||||||
<provider selected="true" editor-type-id="text-editor"> |
|
||||||
<state relative-caret-position="0"> |
|
||||||
<caret line="0" column="12" lean-forward="false" selection-start-line="0" selection-start-column="12" selection-end-line="0" selection-end-column="12" /> |
|
||||||
<folding /> |
|
||||||
</state> |
|
||||||
</provider> |
|
||||||
</entry> |
|
||||||
</file> |
|
||||||
<file leaf-file-name="README.md" pinned="false" current-in-tab="false"> |
|
||||||
<entry file="file://$PROJECT_DIR$/README.md"> |
|
||||||
<provider selected="true" editor-type-id="text-editor"> |
|
||||||
<state relative-caret-position="306"> |
|
||||||
<caret line="18" column="0" lean-forward="false" selection-start-line="18" selection-start-column="0" selection-end-line="18" selection-end-column="0" /> |
|
||||||
<folding /> |
|
||||||
</state> |
|
||||||
</provider> |
|
||||||
</entry> |
|
||||||
</file> |
|
||||||
</leaf> |
|
||||||
</component> |
|
||||||
<component name="FindInProjectRecents"> |
|
||||||
<findStrings> |
|
||||||
<find>"</find> |
|
||||||
<find>moment</find> |
|
||||||
</findStrings> |
|
||||||
<replaceStrings> |
|
||||||
<replace>'</replace> |
|
||||||
<replace>numeral</replace> |
|
||||||
</replaceStrings> |
|
||||||
</component> |
|
||||||
<component name="Git.Settings"> |
|
||||||
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" /> |
|
||||||
</component> |
|
||||||
<component name="IdeDocumentHistory"> |
|
||||||
<option name="CHANGED_PATHS"> |
|
||||||
<list> |
|
||||||
<option value="$PROJECT_DIR$/package.json" /> |
|
||||||
<option value="$PROJECT_DIR$/.gitignore" /> |
|
||||||
<option value="$PROJECT_DIR$/README.md" /> |
|
||||||
<option value="$PROJECT_DIR$/index.js" /> |
|
||||||
<option value="$PROJECT_DIR$/index.d.ts" /> |
|
||||||
</list> |
|
||||||
</option> |
|
||||||
</component> |
|
||||||
<component name="JsBuildToolGruntFileManager" detection-done="true" sorting="DEFINITION_ORDER" /> |
|
||||||
<component name="JsBuildToolPackageJson" detection-done="true" sorting="DEFINITION_ORDER" /> |
|
||||||
<component name="JsGulpfileManager"> |
|
||||||
<detection-done>true</detection-done> |
|
||||||
<sorting>DEFINITION_ORDER</sorting> |
|
||||||
</component> |
|
||||||
<component name="NodeModulesDirectoryManager"> |
|
||||||
<handled-path value="$PROJECT_DIR$/node_modules" /> |
|
||||||
</component> |
|
||||||
<component name="ProjectFrameBounds" extendedState="6"> |
|
||||||
<option name="x" value="-1928" /> |
|
||||||
<option name="y" value="-8" /> |
|
||||||
<option name="width" value="1936" /> |
|
||||||
<option name="height" value="1176" /> |
|
||||||
</component> |
|
||||||
<component name="ProjectView"> |
|
||||||
<navigator currentView="ProjectPane" proportions="" version="1"> |
|
||||||
<flattenPackages /> |
|
||||||
<showMembers /> |
|
||||||
<showModules /> |
|
||||||
<showLibraryContents /> |
|
||||||
<hideEmptyPackages /> |
|
||||||
<abbreviatePackageNames /> |
|
||||||
<autoscrollToSource /> |
|
||||||
<autoscrollFromSource /> |
|
||||||
<sortByType /> |
|
||||||
<manualOrder /> |
|
||||||
<foldersAlwaysOnTop value="true" /> |
|
||||||
</navigator> |
|
||||||
<panes> |
|
||||||
<pane id="Scope" /> |
|
||||||
<pane id="ProjectPane"> |
|
||||||
<subPane> |
|
||||||
<expand> |
|
||||||
<path> |
|
||||||
<item name="numeral-es6" type="b2602c69:ProjectViewProjectNode" /> |
|
||||||
<item name="numeral-es6" type="462c0819:PsiDirectoryNode" /> |
|
||||||
</path> |
|
||||||
</expand> |
|
||||||
<select /> |
|
||||||
</subPane> |
|
||||||
</pane> |
|
||||||
<pane id="Scratches" /> |
|
||||||
</panes> |
|
||||||
</component> |
|
||||||
<component name="PropertiesComponent"> |
|
||||||
<property name="nodejs_interpreter_path.stuck_in_default_project" value="undefined stuck path" /> |
|
||||||
<property name="WebServerToolWindowFactoryState" value="false" /> |
|
||||||
<property name="last_opened_file_path" value="$PROJECT_DIR$" /> |
|
||||||
</component> |
|
||||||
<component name="RunDashboard"> |
|
||||||
<option name="ruleStates"> |
|
||||||
<list> |
|
||||||
<RuleState> |
|
||||||
<option name="name" value="ConfigurationTypeDashboardGroupingRule" /> |
|
||||||
</RuleState> |
|
||||||
<RuleState> |
|
||||||
<option name="name" value="StatusDashboardGroupingRule" /> |
|
||||||
</RuleState> |
|
||||||
</list> |
|
||||||
</option> |
|
||||||
</component> |
|
||||||
<component name="ShelveChangesManager" show_recycled="false"> |
|
||||||
<option name="remove_strategy" value="false" /> |
|
||||||
</component> |
|
||||||
<component name="SvnConfiguration"> |
|
||||||
<configuration /> |
|
||||||
</component> |
|
||||||
<component name="TaskManager"> |
|
||||||
<task active="true" id="Default" summary="Default task"> |
|
||||||
<changelist id="9a0b394d-0612-44ab-871e-56f962b5d644" name="Default" comment="" /> |
|
||||||
<created>1522941586444</created> |
|
||||||
<option name="number" value="Default" /> |
|
||||||
<option name="presentableId" value="Default" /> |
|
||||||
<updated>1522941586444</updated> |
|
||||||
<workItem from="1522941587666" duration="647000" /> |
|
||||||
</task> |
|
||||||
<servers /> |
|
||||||
</component> |
|
||||||
<component name="TimeTrackingManager"> |
|
||||||
<option name="totallyTimeSpent" value="647000" /> |
|
||||||
</component> |
|
||||||
<component name="ToolWindowManager"> |
|
||||||
<frame x="-1928" y="-8" width="1936" height="1176" extended-state="6" /> |
|
||||||
<layout> |
|
||||||
<window_info id="TypeScript" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.24973656" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" /> |
|
||||||
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Docker" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="false" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="true" content_ui="tabs" /> |
|
||||||
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Terminal" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.3298077" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="true" content_ui="tabs" /> |
|
||||||
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" /> |
|
||||||
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" /> |
|
||||||
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> |
|
||||||
</layout> |
|
||||||
</component> |
|
||||||
<component name="TypeScriptGeneratedFilesManager"> |
|
||||||
<option name="version" value="1" /> |
|
||||||
</component> |
|
||||||
<component name="VcsContentAnnotationSettings"> |
|
||||||
<option name="myLimit" value="2678400000" /> |
|
||||||
</component> |
|
||||||
<component name="XDebuggerManager"> |
|
||||||
<breakpoint-manager /> |
|
||||||
<watches-manager /> |
|
||||||
</component> |
|
||||||
<component name="editorHistoryManager"> |
|
||||||
<entry file="file://$PROJECT_DIR$/package.json"> |
|
||||||
<provider selected="true" editor-type-id="text-editor"> |
|
||||||
<state relative-caret-position="391"> |
|
||||||
<caret line="23" column="1" lean-forward="false" selection-start-line="23" selection-start-column="1" selection-end-line="23" selection-end-column="1" /> |
|
||||||
<folding /> |
|
||||||
</state> |
|
||||||
</provider> |
|
||||||
</entry> |
|
||||||
<entry file="file://$PROJECT_DIR$/.gitignore"> |
|
||||||
<provider selected="true" editor-type-id="text-editor"> |
|
||||||
<state relative-caret-position="0"> |
|
||||||
<caret line="0" column="12" lean-forward="false" selection-start-line="0" selection-start-column="12" selection-end-line="0" selection-end-column="12" /> |
|
||||||
<folding /> |
|
||||||
</state> |
|
||||||
</provider> |
|
||||||
</entry> |
|
||||||
<entry file="file://$PROJECT_DIR$/README.md"> |
|
||||||
<provider selected="true" editor-type-id="text-editor"> |
|
||||||
<state relative-caret-position="306"> |
|
||||||
<caret line="18" column="0" lean-forward="false" selection-start-line="18" selection-start-column="0" selection-end-line="18" selection-end-column="0" /> |
|
||||||
<folding /> |
|
||||||
</state> |
|
||||||
</provider> |
|
||||||
</entry> |
|
||||||
<entry file="file://$PROJECT_DIR$/index.js"> |
|
||||||
<provider selected="true" editor-type-id="text-editor"> |
|
||||||
<state relative-caret-position="68"> |
|
||||||
<caret line="4" column="0" lean-forward="false" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" /> |
|
||||||
<folding /> |
|
||||||
</state> |
|
||||||
</provider> |
|
||||||
</entry> |
|
||||||
<entry file="file://$PROJECT_DIR$/index.d.ts"> |
|
||||||
<provider selected="true" editor-type-id="text-editor"> |
|
||||||
<state relative-caret-position="68"> |
|
||||||
<caret line="4" column="0" lean-forward="false" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" /> |
|
||||||
<folding /> |
|
||||||
</state> |
|
||||||
</provider> |
|
||||||
</entry> |
|
||||||
</component> |
|
||||||
</project> |
|
@ -1 +0,0 @@ |
|||||||
node_modules |
|
@ -1,18 +0,0 @@ |
|||||||
# numeral-es6 |
|
||||||
Exports numeral.js as an ES6 default export. Like moment-es6, but for numeral.js. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## Installation |
|
||||||
|
|
||||||
``` |
|
||||||
[npm|yarn] install numeral-es6 |
|
||||||
``` |
|
||||||
|
|
||||||
## Usage |
|
||||||
|
|
||||||
```javascript |
|
||||||
import numeral from 'numeral-es6'; |
|
||||||
|
|
||||||
console.log(numeral(13124.23, '$0,0[.]00'); |
|
||||||
``` |
|
@ -1,4 +0,0 @@ |
|||||||
declare module 'numeral-es6' { |
|
||||||
import * as numeral from 'numeral'; |
|
||||||
export default numeral; |
|
||||||
} |
|
@ -1,4 +0,0 @@ |
|||||||
'use strict' |
|
||||||
var numeral = require('numeral'); |
|
||||||
Object.defineProperty(exports, '__esModule', { value: true }); |
|
||||||
exports.default = numeral; |
|
@ -1,53 +0,0 @@ |
|||||||
{ |
|
||||||
"_from": "numeral-es6", |
|
||||||
"_id": "numeral-es6@1.0.0", |
|
||||||
"_inBundle": false, |
|
||||||
"_integrity": "sha1-xzqgKkvcp6CZ2pm2b03Kw5mkhk4=", |
|
||||||
"_location": "/numeral-es6", |
|
||||||
"_phantomChildren": {}, |
|
||||||
"_requested": { |
|
||||||
"type": "tag", |
|
||||||
"registry": true, |
|
||||||
"raw": "numeral-es6", |
|
||||||
"name": "numeral-es6", |
|
||||||
"escapedName": "numeral-es6", |
|
||||||
"rawSpec": "", |
|
||||||
"saveSpec": null, |
|
||||||
"fetchSpec": "latest" |
|
||||||
}, |
|
||||||
"_requiredBy": [ |
|
||||||
"#USER", |
|
||||||
"/" |
|
||||||
], |
|
||||||
"_resolved": "https://registry.npmjs.org/numeral-es6/-/numeral-es6-1.0.0.tgz", |
|
||||||
"_shasum": "c73aa02a4bdca7a099da99b66f4dcac399a4864e", |
|
||||||
"_spec": "numeral-es6", |
|
||||||
"_where": "/Users/mulish/Desktop/gitcoin/blockscout", |
|
||||||
"author": { |
|
||||||
"name": "benelliott", |
|
||||||
"email": "bengelliott@gmail.com" |
|
||||||
}, |
|
||||||
"bugs": { |
|
||||||
"url": "https://github.com/benelliott/numeral-es6/issues" |
|
||||||
}, |
|
||||||
"bundleDependencies": false, |
|
||||||
"dependencies": { |
|
||||||
"numeral": "*" |
|
||||||
}, |
|
||||||
"deprecated": false, |
|
||||||
"description": "Exports numeral.js as an ES6 default export.", |
|
||||||
"homepage": "https://github.com/benelliott/numeral-es6#readme", |
|
||||||
"keywords": [ |
|
||||||
"es6", |
|
||||||
"numeral", |
|
||||||
"numeraljs" |
|
||||||
], |
|
||||||
"license": "MIT", |
|
||||||
"main": "index.js", |
|
||||||
"name": "numeral-es6", |
|
||||||
"repository": { |
|
||||||
"type": "git", |
|
||||||
"url": "git+https://github.com/benelliott/numeral-es6.git" |
|
||||||
}, |
|
||||||
"version": "1.0.0" |
|
||||||
} |
|
@ -1,32 +0,0 @@ |
|||||||
# -------------------- |
|
||||||
# OSX Files |
|
||||||
# -------------------- |
|
||||||
.DS_Store |
|
||||||
.AppleDouble |
|
||||||
.LSOverride |
|
||||||
Icon |
|
||||||
._* |
|
||||||
.Spotlight-V100 |
|
||||||
.Trashes |
|
||||||
|
|
||||||
# -------------------- |
|
||||||
# IntelliJ Files |
|
||||||
# -------------------- |
|
||||||
*.iml |
|
||||||
*.ipr |
|
||||||
*.iws |
|
||||||
.idea/ |
|
||||||
|
|
||||||
# -------------------- |
|
||||||
# Sublime Files |
|
||||||
# -------------------- |
|
||||||
*.sublime-project |
|
||||||
*.sublime-workspace |
|
||||||
|
|
||||||
# -------------------- |
|
||||||
# App Files |
|
||||||
# -------------------- |
|
||||||
node_modules/ |
|
||||||
.sass-cache |
|
||||||
temp/ |
|
||||||
npm-debug.log |
|
@ -1,7 +0,0 @@ |
|||||||
language: node_js |
|
||||||
node_js: |
|
||||||
- "node" |
|
||||||
- "4" |
|
||||||
before_script: |
|
||||||
- npm install -g grunt-cli |
|
||||||
script: grunt travis --verbose |
|
@ -1,259 +0,0 @@ |
|||||||
module.exports = function(grunt) { |
|
||||||
|
|
||||||
var compileType = function() { |
|
||||||
var type = this.data.type; |
|
||||||
var template = grunt.file.read('templates/types.js'); |
|
||||||
var anon = grunt.file.read('templates/anon.js'); |
|
||||||
var files = grunt.file.expand([ |
|
||||||
'src/' + type + '/*.js' |
|
||||||
]); |
|
||||||
var regexp = /\}\(this, function \(numeral\) \{\s([\s\S]+)(?:\s\}\)\);)/; |
|
||||||
var content = ''; |
|
||||||
var file; |
|
||||||
var i; |
|
||||||
|
|
||||||
for (i = 0; i < files.length; i++) { |
|
||||||
file = grunt.file.read(files[i]); |
|
||||||
|
|
||||||
content += '\n' + grunt.template.process(anon, { |
|
||||||
data: { |
|
||||||
content: file.match(regexp)[1] |
|
||||||
} |
|
||||||
}) + '\n'; |
|
||||||
} |
|
||||||
|
|
||||||
grunt.file.write('temp/' + type + '.js', content); |
|
||||||
|
|
||||||
if (type === 'locales') { |
|
||||||
grunt.file.write('locales.js', grunt.template.process(template, { |
|
||||||
data: { |
|
||||||
type: type, |
|
||||||
content: content |
|
||||||
} |
|
||||||
})); |
|
||||||
} |
|
||||||
}, |
|
||||||
compileNumeral = function() { |
|
||||||
var regexp = /([\s])return numeral;(?:\s\}\)\);)/; |
|
||||||
var numeral = grunt.file.read('src/numeral.js'); |
|
||||||
var formats = grunt.file.read('temp/formats.js'); |
|
||||||
var index = numeral.indexOf('return numeral;'); |
|
||||||
|
|
||||||
numeral = numeral.substr(0, index) + '\n' + formats + numeral.substr(index); |
|
||||||
|
|
||||||
grunt.file.write('numeral.js', numeral); |
|
||||||
}; |
|
||||||
|
|
||||||
require('load-grunt-tasks')(grunt); |
|
||||||
|
|
||||||
grunt.initConfig({ |
|
||||||
mochaTest : { |
|
||||||
all: [ |
|
||||||
'tests/numeral.js', |
|
||||||
'tests/formats/*.js', |
|
||||||
'tests/locales/*.js' |
|
||||||
] |
|
||||||
}, |
|
||||||
karma: { |
|
||||||
options: { |
|
||||||
files: [ |
|
||||||
'numeral.js', |
|
||||||
'locales.js', |
|
||||||
'tests/numeral.js', |
|
||||||
'tests/formats/*.js', |
|
||||||
'tests/locales/*.js' |
|
||||||
], |
|
||||||
frameworks: [ |
|
||||||
'mocha', |
|
||||||
'chai' |
|
||||||
], |
|
||||||
singleRun: true, |
|
||||||
autoWatch: false |
|
||||||
}, |
|
||||||
local: { |
|
||||||
browsers: [ |
|
||||||
'Chrome', |
|
||||||
'Firefox' |
|
||||||
] |
|
||||||
}, |
|
||||||
ci: { |
|
||||||
configFile: 'karma-ci.conf.js' |
|
||||||
} |
|
||||||
}, |
|
||||||
copy: { |
|
||||||
locales: { |
|
||||||
files: [ |
|
||||||
{ |
|
||||||
expand: true, |
|
||||||
cwd: 'src/', |
|
||||||
src: [ |
|
||||||
'locales/*.js' |
|
||||||
], |
|
||||||
dest: './' |
|
||||||
} |
|
||||||
] |
|
||||||
} |
|
||||||
}, |
|
||||||
compile: { |
|
||||||
locales: { |
|
||||||
type: 'locales' |
|
||||||
}, |
|
||||||
formats: { |
|
||||||
type: 'formats' |
|
||||||
} |
|
||||||
}, |
|
||||||
uglify: { |
|
||||||
min: { |
|
||||||
files: [ |
|
||||||
{ |
|
||||||
expand: true, |
|
||||||
cwd: 'src/', |
|
||||||
src: [ |
|
||||||
'locales/*.js' |
|
||||||
], |
|
||||||
dest: 'min/', |
|
||||||
ext: '.min.js' |
|
||||||
}, |
|
||||||
{ |
|
||||||
expand: true, |
|
||||||
src: [ |
|
||||||
'numeral.js', |
|
||||||
'locales.js' |
|
||||||
], |
|
||||||
dest: 'min/', |
|
||||||
ext: '.min.js' |
|
||||||
} |
|
||||||
] |
|
||||||
}, |
|
||||||
options: { |
|
||||||
preserveComments: 'some' |
|
||||||
} |
|
||||||
}, |
|
||||||
jshint: { |
|
||||||
all: [ |
|
||||||
'Gruntfile.js', |
|
||||||
'src/**/*.js' |
|
||||||
], |
|
||||||
options: { |
|
||||||
'node': true, |
|
||||||
'browser': true, |
|
||||||
'curly': true, |
|
||||||
'devel': false, |
|
||||||
'eqeqeq': true, |
|
||||||
'eqnull': true, |
|
||||||
'newcap': true, |
|
||||||
'noarg': true, |
|
||||||
'undef': true, |
|
||||||
'sub': true, |
|
||||||
'strict': false, |
|
||||||
'quotmark': 'single', |
|
||||||
'globals': { |
|
||||||
'define': true |
|
||||||
} |
|
||||||
} |
|
||||||
} |
|
||||||
}); |
|
||||||
|
|
||||||
grunt.registerTask('default', [ |
|
||||||
'test' |
|
||||||
]); |
|
||||||
|
|
||||||
grunt.registerMultiTask('compile', compileType); |
|
||||||
|
|
||||||
grunt.registerTask('compile:numeral', compileNumeral); |
|
||||||
|
|
||||||
grunt.registerTask('build', [ |
|
||||||
'jshint', |
|
||||||
'compile', |
|
||||||
'compile:numeral', |
|
||||||
'copy' |
|
||||||
]); |
|
||||||
|
|
||||||
grunt.registerTask('test', [ |
|
||||||
'build', |
|
||||||
'mochaTest', |
|
||||||
'karma:local' |
|
||||||
]); |
|
||||||
|
|
||||||
grunt.registerTask('test:npm', [ |
|
||||||
'build', |
|
||||||
'mochaTest' |
|
||||||
]); |
|
||||||
|
|
||||||
grunt.registerTask('test:browser', [ |
|
||||||
'build', |
|
||||||
'karma:local' |
|
||||||
]); |
|
||||||
|
|
||||||
grunt.registerTask('dist', [ |
|
||||||
'build', |
|
||||||
'uglify' |
|
||||||
]); |
|
||||||
|
|
||||||
grunt.registerTask('version', function (version) { |
|
||||||
if (!version || version.split('.').length !== 3) { |
|
||||||
grunt.fail.fatal('malformed version. Use\n\n grunt version:1.2.3'); |
|
||||||
} |
|
||||||
|
|
||||||
grunt.config('string-replace.json', { |
|
||||||
files: { |
|
||||||
'package.json': 'package.json', |
|
||||||
'component.json': 'component.json', |
|
||||||
'bower.json': 'bower.json' |
|
||||||
}, |
|
||||||
options: { |
|
||||||
replacements: [ |
|
||||||
{ |
|
||||||
pattern: /"version": .*/, |
|
||||||
replacement: '"version": "' + version + '",' |
|
||||||
} |
|
||||||
] |
|
||||||
} |
|
||||||
}); |
|
||||||
|
|
||||||
grunt.config('string-replace.numeral', { |
|
||||||
files: { |
|
||||||
'src/numeral.js': 'src/numeral.js' |
|
||||||
}, |
|
||||||
options: { |
|
||||||
replacements: [ |
|
||||||
{ |
|
||||||
pattern: /version : .*/, |
|
||||||
replacement: 'version : ' + version |
|
||||||
}, |
|
||||||
{ |
|
||||||
pattern: /VERSION = .*/, |
|
||||||
replacement: 'VERSION = \'' + version + '\',' |
|
||||||
} |
|
||||||
] |
|
||||||
} |
|
||||||
}); |
|
||||||
|
|
||||||
grunt.config('string-replace.templates', { |
|
||||||
files: { |
|
||||||
'templates/types.js': 'templates/types.js' |
|
||||||
}, |
|
||||||
options: { |
|
||||||
replacements: [ |
|
||||||
{ |
|
||||||
pattern: /: .*/, |
|
||||||
replacement: ': ' + version |
|
||||||
} |
|
||||||
] |
|
||||||
} |
|
||||||
}); |
|
||||||
|
|
||||||
grunt.task.run([ |
|
||||||
'string-replace:json', |
|
||||||
'string-replace:templates', |
|
||||||
'string-replace:numeral' |
|
||||||
]); |
|
||||||
}); |
|
||||||
|
|
||||||
// Travis CI task.
|
|
||||||
grunt.registerTask('travis', [ |
|
||||||
'build', |
|
||||||
'mochaTest', |
|
||||||
'karma:ci' |
|
||||||
]); |
|
||||||
}; |
|
@ -1,22 +0,0 @@ |
|||||||
Copyright (c) 2016 Adam Draper |
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person |
|
||||||
obtaining a copy of this software and associated documentation |
|
||||||
files (the "Software"), to deal in the Software without |
|
||||||
restriction, including without limitation the rights to use, |
|
||||||
copy, modify, merge, publish, distribute, sublicense, and/or sell |
|
||||||
copies of the Software, and to permit persons to whom the |
|
||||||
Software is furnished to do so, subject to the following |
|
||||||
conditions: |
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be |
|
||||||
included in all copies or substantial portions of the Software. |
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, |
|
||||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES |
|
||||||
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND |
|
||||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT |
|
||||||
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, |
|
||||||
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
|
||||||
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR |
|
||||||
OTHER DEALINGS IN THE SOFTWARE. |
|
@ -1,303 +0,0 @@ |
|||||||
# [Numeral.js](http://numeraljs.com/) |
|
||||||
|
|
||||||
A javascript library for formatting and manipulating numbers. |
|
||||||
|
|
||||||
[Website and documentation](http://numeraljs.com/) |
|
||||||
|
|
||||||
|
|
||||||
# Travis Build Status |
|
||||||
|
|
||||||
Master [![Build Status](https://api.travis-ci.org/adamwdraper/Numeral-js.svg)](https://travis-ci.org/adamwdraper/Numeral-js) |
|
||||||
|
|
||||||
Develop [![Build Status](https://travis-ci.org/adamwdraper/Numeral-js.svg?branch=develop)](https://travis-ci.org/adamwdraper/Numeral-js) |
|
||||||
|
|
||||||
# NPM |
|
||||||
|
|
||||||
[![NPM](https://nodei.co/npm/numeral.svg?downloads=true)](https://nodei.co/npm/numeral/) |
|
||||||
|
|
||||||
#CDNJS |
|
||||||
|
|
||||||
[![CDNJS](https://img.shields.io/cdnjs/v/numeral.js.svg)](https://cdnjs.com/libraries/numeral.js) |
|
||||||
|
|
||||||
# Contributing |
|
||||||
|
|
||||||
#### Important: Please create your branch from and submit pull requests to the `develop` branch. All pull requests must include the appropriate tests. |
|
||||||
|
|
||||||
1. Fork the library |
|
||||||
|
|
||||||
2. [Install grunt](http://gruntjs.com/getting-started#installing-the-cli) |
|
||||||
|
|
||||||
3. Run `npm install` to install dependencies |
|
||||||
|
|
||||||
4. Create a new branch from `develop` |
|
||||||
|
|
||||||
5. Add your tests to the files in `/tests` |
|
||||||
|
|
||||||
6. To test your tests, run `grunt` |
|
||||||
|
|
||||||
7. When all your tests are passing, run `grunt dist` to compile and minify all files |
|
||||||
|
|
||||||
8. Submit a pull request to the `develop` branch. |
|
||||||
|
|
||||||
|
|
||||||
### Formats |
|
||||||
|
|
||||||
Formats now exist in their own files and act more or less as plugins. Check out the [bytes format](https://github.com/adamwdraper/Numeral-js/blob/master/src/formats/bytes.js) for an example of how to create one. |
|
||||||
|
|
||||||
|
|
||||||
### Locales |
|
||||||
|
|
||||||
When naming locale files use the [ISO 639-1 language codes](http://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) supplemented by [ISO 3166-1](http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) country codes when necessary. |
|
||||||
|
|
||||||
### Locale translations will not be merged without unit tests. |
|
||||||
|
|
||||||
See [the english unit tests](https://github.com/adamwdraper/Numeral-js/blob/master/tests/locales/en-gb.js) for an example. |
|
||||||
|
|
||||||
|
|
||||||
# Changelog |
|
||||||
|
|
||||||
### 2.0.6 |
|
||||||
|
|
||||||
Bug fix: Multi letter currency symbols and spacing |
|
||||||
|
|
||||||
Added: Formatting of numbers with leading zeros |
|
||||||
|
|
||||||
New format: Basic Point |
|
||||||
|
|
||||||
Option: Added `scalePercentBy100` (default: true) option to turn on/off scaling percentages |
|
||||||
|
|
||||||
### 2.0.4 |
|
||||||
|
|
||||||
Bug fix: Incorrect abbreviations for values rounded up [#187](https://github.com/adamwdraper/Numeral-js/issues/187) |
|
||||||
|
|
||||||
Bug fix: Signed currency is inconsistent [#89](https://github.com/adamwdraper/Numeral-js/issues/89) |
|
||||||
|
|
||||||
### 2.0.2 |
|
||||||
|
|
||||||
Bug fix: Updated module definitions |
|
||||||
|
|
||||||
### 2.0.1 |
|
||||||
|
|
||||||
Bug fix: Fixed regression for webpack/browserify/rollup |
|
||||||
|
|
||||||
### 2.0.0 |
|
||||||
|
|
||||||
2.0.0 brings a lot of breaking changes and a reorganization of the repo, but also simplifies the api as well as the creating of custom formats. |
|
||||||
|
|
||||||
Breaking change / Feature: All formats are now separate files. This makes it easy to create custom formats, and will also allow for custom builds with only certain formats. (Note: The built numeral.js still contains all formats in the repo). |
|
||||||
|
|
||||||
Breaking change / Feature: All formats and locales are now loaded using `numeral.register(type, name, {})` |
|
||||||
|
|
||||||
Breaking change: All `language` now renamed to `locale` and standardized to all lowercase filenames |
|
||||||
|
|
||||||
Breaking change: The `locale` function no longer loads locales, it only sets the current locale |
|
||||||
|
|
||||||
Breaking change: The `unformat` function has been removed `numeral().unformat(string)` and now happens on numeral init `numeral(string)` |
|
||||||
|
|
||||||
Breaking change / Feature: Bytes are now formatted as: `b` (base 1000) and `ib` (base 1024) |
|
||||||
|
|
||||||
Breaking change: `numeral(NaN)` is now treated the same as `numeral(null)` and no longer throws an error |
|
||||||
|
|
||||||
Feature: Exponential format using `e+` or `e-` |
|
||||||
|
|
||||||
Bug fix: Update to floating point helpers (Note: Numeral does not fix JS floating point errors, but look to our tests to see that it covers quite a few cases.) |
|
||||||
|
|
||||||
### 1.5.6 |
|
||||||
|
|
||||||
Bug fix: numeral converts strings to numbers |
|
||||||
|
|
||||||
Bug fix: Null values return same as 0 |
|
||||||
|
|
||||||
### 1.5.5 |
|
||||||
|
|
||||||
Contained breaking changes, recommended to use 1.5.6 |
|
||||||
|
|
||||||
Bug fix: Switch bytes back to `b` and change iecBinary to `ib`, and calculate both using 1024 for backwards compatibility |
|
||||||
|
|
||||||
### 1.5.4 |
|
||||||
|
|
||||||
Contained breaking changes, recommended to use 1.5.6 |
|
||||||
|
|
||||||
Tests: Changed all tests to use Mocha and Chai |
|
||||||
|
|
||||||
Tests: Added browser tests for Chrome, Firefox, and IE using saucelabs |
|
||||||
|
|
||||||
Added reset function to reset numeral to default options |
|
||||||
|
|
||||||
Added nullFormat option |
|
||||||
|
|
||||||
Update reduce polyfill |
|
||||||
|
|
||||||
Added Binary bytes |
|
||||||
|
|
||||||
Bug fix: Fixes problem with many optional decimals |
|
||||||
|
|
||||||
### 1.5.3 |
|
||||||
|
|
||||||
Added currency symbol to optionally appear before negative sign / open paren |
|
||||||
|
|
||||||
Added float precision math support |
|
||||||
|
|
||||||
Added specification of abbreviation in thousands, millions, billions |
|
||||||
|
|
||||||
### 1.5.2 |
|
||||||
|
|
||||||
Bug fix: Unformat should pass through if given a number |
|
||||||
|
|
||||||
Added a mechanism to control rounding behaviour |
|
||||||
|
|
||||||
Added languageData() for getting and setting language props at runtime |
|
||||||
|
|
||||||
### 1.5.1 |
|
||||||
|
|
||||||
Bug fix: Make sure values aren't changed during formatting |
|
||||||
|
|
||||||
### 1.5.0 |
|
||||||
|
|
||||||
Add defaultFormat(). numeral().format() uses the default to format if no string is provided |
|
||||||
|
|
||||||
.unformat() returns 0 when passed no string |
|
||||||
|
|
||||||
Added languages.js that contains all languages |
|
||||||
|
|
||||||
Bug fix: Fix bug while unformatting ordinals |
|
||||||
|
|
||||||
Add format option to always show signed value |
|
||||||
|
|
||||||
Added ability to instantiate numeral with a string value of a number |
|
||||||
|
|
||||||
### 1.4.9 |
|
||||||
|
|
||||||
Bug fix: Fix bug while unformatting ordinals |
|
||||||
|
|
||||||
### 1.4.8 |
|
||||||
|
|
||||||
Bug fix: Throw error if language is not defined |
|
||||||
|
|
||||||
### 1.4.7 |
|
||||||
|
|
||||||
Bug fix: Fix typo for trillion |
|
||||||
|
|
||||||
### 1.4.6 |
|
||||||
|
|
||||||
Bug fix: remove ' from unformatting regex that was causing an error with fr-ch.js |
|
||||||
|
|
||||||
### 1.4.5 |
|
||||||
|
|
||||||
Add zeroFormat() function that accepts a string for custom formating of zeros |
|
||||||
|
|
||||||
Add valueOf() function |
|
||||||
|
|
||||||
Chain functionality to language function |
|
||||||
|
|
||||||
Make all minified files have the same .min.js filename ending |
|
||||||
|
|
||||||
### 1.4.1 |
|
||||||
|
|
||||||
Bug fix: Bytes not formatting correctly |
|
||||||
|
|
||||||
### 1.4.0 |
|
||||||
|
|
||||||
Add optional format for all decimals |
|
||||||
|
|
||||||
### 1.3.4 |
|
||||||
|
|
||||||
Remove AMD module id. (This is encouraged by require.js to make the module more portable, and keep it from creating a global) |
|
||||||
|
|
||||||
### 1.3.3 |
|
||||||
|
|
||||||
AMD define() compatibility. |
|
||||||
|
|
||||||
### 1.3.2 |
|
||||||
|
|
||||||
Bug fix: Formatting some numbers results in the wrong value. Issue #21 |
|
||||||
|
|
||||||
### 1.3.1 |
|
||||||
|
|
||||||
Bug fix: Minor fix to unformatting parser |
|
||||||
|
|
||||||
### 1.3.0 |
|
||||||
|
|
||||||
Add support for spaces before/after $, a, o, b in a format string |
|
||||||
|
|
||||||
Bug fix: Fix unformat for languages that use '.' in ordinals |
|
||||||
|
|
||||||
Bug fix: Fix round up floating numbers with no precision correctly. |
|
||||||
|
|
||||||
Bug fix: Fix currency signs at the end in unformat |
|
||||||
|
|
||||||
### 1.2.6 |
|
||||||
|
|
||||||
Add support for optional decimal places |
|
||||||
|
|
||||||
### 1.2.5 |
|
||||||
|
|
||||||
Add support for appending currency symbol |
|
||||||
|
|
||||||
### 1.2.4 |
|
||||||
|
|
||||||
Add support for humanized filesizes |
|
||||||
|
|
||||||
### 1.2.3 |
|
||||||
|
|
||||||
Bug Fix: Fix unformatting for languages that use '.' as thousands delimiter |
|
||||||
|
|
||||||
### 1.2.2 |
|
||||||
|
|
||||||
Changed language definition property 'money' to 'currency' |
|
||||||
|
|
||||||
### 1.2.1 |
|
||||||
|
|
||||||
Bug fix: Fix unformatting non-negative abbreviations |
|
||||||
|
|
||||||
### 1.2.0 |
|
||||||
|
|
||||||
Add language support |
|
||||||
|
|
||||||
Update testing for to include languages |
|
||||||
|
|
||||||
### 1.1.0 |
|
||||||
|
|
||||||
Add Tests |
|
||||||
|
|
||||||
Bug fix: Fix difference returning negative values |
|
||||||
|
|
||||||
### 1.0.4 |
|
||||||
|
|
||||||
Bug fix: Non negative numbers were displaying as negative when using parentheses |
|
||||||
|
|
||||||
### 1.0.3 |
|
||||||
|
|
||||||
Add ordinal formatting using 'o' in the format |
|
||||||
|
|
||||||
### 1.0.2 |
|
||||||
|
|
||||||
Add clone functionality |
|
||||||
|
|
||||||
### 1.0.1 |
|
||||||
|
|
||||||
Added abbreviations for thousands and millions using 'a' in the format |
|
||||||
|
|
||||||
### 1.0.0 |
|
||||||
|
|
||||||
Initial release |
|
||||||
|
|
||||||
|
|
||||||
# Acknowlegements |
|
||||||
|
|
||||||
Numeral.js, while less complex, was inspired by and heavily borrowed from [Moment.js](http://momentjs.com) |
|
||||||
|
|
||||||
|
|
||||||
# License |
|
||||||
|
|
||||||
Numeral.js is freely distributable under the terms of the MIT license. |
|
||||||
|
|
||||||
Copyright (c) 2012 Adam Draper |
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation |
|
||||||
files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, |
|
||||||
copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: |
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. |
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
|
@ -1,16 +0,0 @@ |
|||||||
{ |
|
||||||
"name": "numeral", |
|
||||||
"repo": "adamwdraper/Numeral-js", |
|
||||||
"version": "2.0.6", |
|
||||||
"description": "Format and manipulate numbers.", |
|
||||||
"keywords": [ |
|
||||||
"numeral", |
|
||||||
"number", |
|
||||||
"format", |
|
||||||
"time", |
|
||||||
"money", |
|
||||||
"percentage" |
|
||||||
], |
|
||||||
"scripts": [ "numeral.js" ], |
|
||||||
"main": "numeral.js" |
|
||||||
} |
|
@ -1,16 +0,0 @@ |
|||||||
{ |
|
||||||
"name": "numeral", |
|
||||||
"repo": "adamwdraper/Numeral-js", |
|
||||||
"version": "2.0.6", |
|
||||||
"description": "Format and manipulate numbers.", |
|
||||||
"keywords": [ |
|
||||||
"numeral", |
|
||||||
"number", |
|
||||||
"format", |
|
||||||
"time", |
|
||||||
"money", |
|
||||||
"percentage" |
|
||||||
], |
|
||||||
"scripts": [ "numeral.js" ], |
|
||||||
"main": "numeral.js" |
|
||||||
} |
|
@ -1,41 +0,0 @@ |
|||||||
module.exports = function(config) { |
|
||||||
var customLaunchers = { |
|
||||||
sl_chrome: { |
|
||||||
base: 'SauceLabs', |
|
||||||
browserName: 'chrome', |
|
||||||
version: '50', |
|
||||||
platform: 'OS X 10.11' |
|
||||||
}, |
|
||||||
sl_firefox: { |
|
||||||
base: 'SauceLabs', |
|
||||||
browserName: 'firefox', |
|
||||||
version: '45', |
|
||||||
platform: 'OS X 10.11' |
|
||||||
}, |
|
||||||
sl_ie: { |
|
||||||
base: 'SauceLabs', |
|
||||||
browserName: 'internet explorer', |
|
||||||
version: '11.103', |
|
||||||
platform: 'Windows 10' |
|
||||||
} |
|
||||||
}; |
|
||||||
|
|
||||||
process.env.SAUCE_USERNAME = 'numeraljs'; |
|
||||||
process.env.SAUCE_ACCESS_KEY = '5506968c-cfdc-4797-ba75-294620ad475f'; |
|
||||||
|
|
||||||
config.set({ |
|
||||||
reporters: [ |
|
||||||
'mocha', |
|
||||||
'saucelabs' |
|
||||||
], |
|
||||||
browserDisconnectTimeout : 10000, |
|
||||||
browserNoActivityTimeout: 120000, |
|
||||||
browserDisconnectTolerance : 1, |
|
||||||
browsers: Object.keys(customLaunchers), |
|
||||||
sauceLabs: { |
|
||||||
testName: 'Web App Unit Tests' |
|
||||||
}, |
|
||||||
customLaunchers: customLaunchers, |
|
||||||
singleRun: true |
|
||||||
}); |
|
||||||
}; |
|
@ -1,40 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : Bulgarian
|
|
||||||
// author : Don Vince : https://github.com/donvince/
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'bg', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { // I found these here http://www.unicode.org/cldr/charts/28/verify/numbers/bg.html
|
|
||||||
thousand: 'хил', |
|
||||||
million: 'млн', |
|
||||||
billion: 'млрд', |
|
||||||
trillion: 'трлн' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
// google translate suggests:
|
|
||||||
// 1st=1-ви; 2nd=2-ри; 7th=7-ми;
|
|
||||||
// 8th=8-ми and many others end with -ти
|
|
||||||
// for example 3rd=3-ти
|
|
||||||
// However since I've seen suggestions that in
|
|
||||||
// Bulgarian the ordinal can be taken in
|
|
||||||
// different forms (masculine, feminine, neuter)
|
|
||||||
// I've opted to wimp out on commiting that to code
|
|
||||||
return ''; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'лв' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : simplified chinese (chs)
|
|
||||||
// author : badplum : https://github.com/badplum
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'chs', { |
|
||||||
delimiters: { |
|
||||||
thousands: ',', |
|
||||||
decimal: '.' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: '千', |
|
||||||
million: '百万', |
|
||||||
billion: '十亿', |
|
||||||
trillion: '兆' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '¥' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : czech (cs)
|
|
||||||
// author : Anatoli Papirovski : https://github.com/apapirovski
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'cs', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'tis.', |
|
||||||
million: 'mil.', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function () { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'Kč' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : danish denmark (dk)
|
|
||||||
// author : Michael Storgaard : https://github.com/mstorgaard
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'da-dk', { |
|
||||||
delimiters: { |
|
||||||
thousands: '.', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'mio', |
|
||||||
billion: 'mia', |
|
||||||
trillion: 'b' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'DKK' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : German in Switzerland (de-ch)
|
|
||||||
// author : Michael Piefel : https://github.com/piefel (based on work from Marco Krage : https://github.com/sinky)
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'de-ch', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'CHF' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : German (de) – generally useful in Germany, Austria, Luxembourg, Belgium
|
|
||||||
// author : Marco Krage : https://github.com/sinky
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'de', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,36 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : English Australia
|
|
||||||
// author : Don Vince : https://github.com/donvince/
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'en-au', { |
|
||||||
delimiters: { |
|
||||||
thousands: ',', |
|
||||||
decimal: '.' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
var b = number % 10; |
|
||||||
return (~~ (number % 100 / 10) === 1) ? 'th' : |
|
||||||
(b === 1) ? 'st' : |
|
||||||
(b === 2) ? 'nd' : |
|
||||||
(b === 3) ? 'rd' : 'th'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '$' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,36 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : english united kingdom (uk)
|
|
||||||
// author : Dan Ristic : https://github.com/dristic
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'en-gb', { |
|
||||||
delimiters: { |
|
||||||
thousands: ',', |
|
||||||
decimal: '.' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
var b = number % 10; |
|
||||||
return (~~ (number % 100 / 10) === 1) ? 'th' : |
|
||||||
(b === 1) ? 'st' : |
|
||||||
(b === 2) ? 'nd' : |
|
||||||
(b === 3) ? 'rd' : 'th'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '£' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,36 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : english south africa (uk)
|
|
||||||
// author : Etienne Boshoff : etienne@zailab.com
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'en-za', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
var b = number % 10; |
|
||||||
return (~~ (number % 100 / 10) === 1) ? 'th' : |
|
||||||
(b === 1) ? 'st' : |
|
||||||
(b === 2) ? 'nd' : |
|
||||||
(b === 3) ? 'rd' : 'th'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'R' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,37 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : spanish Spain
|
|
||||||
// author : Hernan Garcia : https://github.com/hgarcia
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'es-es', { |
|
||||||
delimiters: { |
|
||||||
thousands: '.', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'mm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
var b = number % 10; |
|
||||||
return (b === 1 || b === 3) ? 'er' : |
|
||||||
(b === 2) ? 'do' : |
|
||||||
(b === 7 || b === 0) ? 'mo' : |
|
||||||
(b === 8) ? 'vo' : |
|
||||||
(b === 9) ? 'no' : 'to'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,37 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : spanish
|
|
||||||
// author : Hernan Garcia : https://github.com/hgarcia
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'es', { |
|
||||||
delimiters: { |
|
||||||
thousands: '.', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'mm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
var b = number % 10; |
|
||||||
return (b === 1 || b === 3) ? 'er' : |
|
||||||
(b === 2) ? 'do' : |
|
||||||
(b === 7 || b === 0) ? 'mo' : |
|
||||||
(b === 8) ? 'vo' : |
|
||||||
(b === 9) ? 'no' : 'to'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '$' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,33 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : Estonian
|
|
||||||
// author : Illimar Tambek : https://github.com/ragulka
|
|
||||||
// Note: in Estonian, abbreviations are always separated from numbers with a space
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'et', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: ' tuh', |
|
||||||
million: ' mln', |
|
||||||
billion: ' mld', |
|
||||||
trillion: ' trl' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : Finnish
|
|
||||||
// author : Sami Saada : https://github.com/samitheberber
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'fi', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'M', |
|
||||||
billion: 'G', |
|
||||||
trillion: 'T' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : french (Canada) (fr-ca)
|
|
||||||
// author : Léo Renaud-Allaire : https://github.com/renaudleo
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'fr-ca', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'M', |
|
||||||
billion: 'G', |
|
||||||
trillion: 'T' |
|
||||||
}, |
|
||||||
ordinal : function (number) { |
|
||||||
return number === 1 ? 'er' : 'e'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '$' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : french (fr-ch)
|
|
||||||
// author : Adam Draper : https://github.com/adamwdraper
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'fr-ch', { |
|
||||||
delimiters: { |
|
||||||
thousands: '\'', |
|
||||||
decimal: '.' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal : function (number) { |
|
||||||
return number === 1 ? 'er' : 'e'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'CHF' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : french (fr)
|
|
||||||
// author : Adam Draper : https://github.com/adamwdraper
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'fr', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal : function (number) { |
|
||||||
return number === 1 ? 'er' : 'e'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : Hungarian (hu)
|
|
||||||
// author : Peter Bakondy : https://github.com/pbakondy
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'hu', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'E', // ezer
|
|
||||||
million: 'M', // millió
|
|
||||||
billion: 'Mrd', // milliárd
|
|
||||||
trillion: 'T' // trillió
|
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: ' Ft' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : italian Italy (it)
|
|
||||||
// author : Giacomo Trombi : http://cinquepunti.it
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'it', { |
|
||||||
delimiters: { |
|
||||||
thousands: '.', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'mila', |
|
||||||
million: 'mil', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return 'º'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : japanese
|
|
||||||
// author : teppeis : https://github.com/teppeis
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'ja', { |
|
||||||
delimiters: { |
|
||||||
thousands: ',', |
|
||||||
decimal: '.' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: '千', |
|
||||||
million: '百万', |
|
||||||
billion: '十億', |
|
||||||
trillion: '兆' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '¥' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : Latvian (lv)
|
|
||||||
// author : Lauris Bukšis-Haberkorns : https://github.com/Lafriks
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'lv', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: ' tūkst.', |
|
||||||
million: ' milj.', |
|
||||||
billion: ' mljrd.', |
|
||||||
trillion: ' trilj.' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,35 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : dutch-belgium (nl-be)
|
|
||||||
// author : Dieter Luypaert : https://github.com/moeriki
|
|
||||||
// corrected : Olivier Godefroy : https://github.com/godefroyo
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'nl-be', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal : ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand : 'k', |
|
||||||
million : ' mln', |
|
||||||
billion : ' mld', |
|
||||||
trillion : ' bln' |
|
||||||
}, |
|
||||||
ordinal : function (number) { |
|
||||||
var remainder = number % 100; |
|
||||||
|
|
||||||
return (number !== 0 && remainder <= 1 || remainder === 8 || remainder >= 20) ? 'ste' : 'de'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€ ' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,33 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : netherlands-dutch (nl-nl)
|
|
||||||
// author : Dave Clayton : https://github.com/davedx
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'nl-nl', { |
|
||||||
delimiters: { |
|
||||||
thousands: '.', |
|
||||||
decimal : ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand : 'k', |
|
||||||
million : 'mln', |
|
||||||
billion : 'mrd', |
|
||||||
trillion : 'bln' |
|
||||||
}, |
|
||||||
ordinal : function (number) { |
|
||||||
var remainder = number % 100; |
|
||||||
return (number !== 0 && remainder <= 1 || remainder === 8 || remainder >= 20) ? 'ste' : 'de'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€ ' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : norwegian (bokmål)
|
|
||||||
// author : Ove Andersen : https://github.com/azzlack
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'no', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'kr' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : polish (pl)
|
|
||||||
// author : Dominik Bulaj : https://github.com/dominikbulaj
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'pl', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'tys.', |
|
||||||
million: 'mln', |
|
||||||
billion: 'mld', |
|
||||||
trillion: 'bln' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'PLN' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : portuguese brazil (pt-br)
|
|
||||||
// author : Ramiro Varandas Jr : https://github.com/ramirovjr
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'pt-br', { |
|
||||||
delimiters: { |
|
||||||
thousands: '.', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'mil', |
|
||||||
million: 'milhões', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return 'º'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'R$' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : portuguese (pt-pt)
|
|
||||||
// author : Diogo Resende : https://github.com/dresende
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'pt-pt', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'm', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal : function (number) { |
|
||||||
return 'º'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,35 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : Russian for the Ukraine (ru-ua)
|
|
||||||
// author : Anatoli Papirovski : https://github.com/apapirovski
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'ru-ua', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'тыс.', |
|
||||||
million: 'млн', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function () { |
|
||||||
// not ideal, but since in Russian it can taken on
|
|
||||||
// different forms (masculine, feminine, neuter)
|
|
||||||
// this is all we can do
|
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '\u20B4' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,35 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : russian (ru)
|
|
||||||
// author : Anatoli Papirovski : https://github.com/apapirovski
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'ru', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'тыс.', |
|
||||||
million: 'млн.', |
|
||||||
billion: 'млрд.', |
|
||||||
trillion: 'трлн.' |
|
||||||
}, |
|
||||||
ordinal: function () { |
|
||||||
// not ideal, but since in Russian it can taken on
|
|
||||||
// different forms (masculine, feminine, neuter)
|
|
||||||
// this is all we can do
|
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'руб.' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : slovak (sk)
|
|
||||||
// author : Ahmed Al Hafoudh : http://www.freevision.sk
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'sk', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'tis.', |
|
||||||
million: 'mil.', |
|
||||||
billion: 'b', |
|
||||||
trillion: 't' |
|
||||||
}, |
|
||||||
ordinal: function () { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : slovenian (sl)
|
|
||||||
// author : Boštjan Pišler : https://github.com/BostjanPisler
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'sl', { |
|
||||||
delimiters: { |
|
||||||
thousands: '.', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'k', |
|
||||||
million: 'mio', |
|
||||||
billion: 'mrd', |
|
||||||
trillion: 'trilijon' |
|
||||||
}, |
|
||||||
ordinal: function () { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '€' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,66 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : turkish (tr)
|
|
||||||
// author : Ecmel Ercan : https://github.com/ecmel, Erhan Gundogan : https://github.com/erhangundogan, Burak Yiğit Kaya: https://github.com/BYK
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
var suffixes = { |
|
||||||
1: '\'inci', |
|
||||||
5: '\'inci', |
|
||||||
8: '\'inci', |
|
||||||
70: '\'inci', |
|
||||||
80: '\'inci', |
|
||||||
|
|
||||||
2: '\'nci', |
|
||||||
7: '\'nci', |
|
||||||
20: '\'nci', |
|
||||||
50: '\'nci', |
|
||||||
|
|
||||||
3: '\'üncü', |
|
||||||
4: '\'üncü', |
|
||||||
100: '\'üncü', |
|
||||||
|
|
||||||
6: '\'ncı', |
|
||||||
|
|
||||||
9: '\'uncu', |
|
||||||
10: '\'uncu', |
|
||||||
30: '\'uncu', |
|
||||||
|
|
||||||
60: '\'ıncı', |
|
||||||
90: '\'ıncı' |
|
||||||
}; |
|
||||||
|
|
||||||
numeral.register('locale', 'tr', { |
|
||||||
delimiters: { |
|
||||||
thousands: '.', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'bin', |
|
||||||
million: 'milyon', |
|
||||||
billion: 'milyar', |
|
||||||
trillion: 'trilyon' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
if (number === 0) { // special case for zero
|
|
||||||
return '\'ıncı'; |
|
||||||
} |
|
||||||
|
|
||||||
var a = number % 10, |
|
||||||
b = number % 100 - a, |
|
||||||
c = number >= 100 ? 100 : null; |
|
||||||
|
|
||||||
return suffixes[a] || suffixes[b] || suffixes[c]; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '\u20BA' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,35 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : Ukrainian for the Ukraine (uk-ua)
|
|
||||||
// author : Michael Piefel : https://github.com/piefel (with help from Tetyana Kuzmenko)
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'uk-ua', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: 'тис.', |
|
||||||
million: 'млн', |
|
||||||
billion: 'млрд', |
|
||||||
trillion: 'блн' |
|
||||||
}, |
|
||||||
ordinal: function () { |
|
||||||
// not ideal, but since in Ukrainian it can taken on
|
|
||||||
// different forms (masculine, feminine, neuter)
|
|
||||||
// this is all we can do
|
|
||||||
return ''; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '\u20B4' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,33 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : vietnam (vi)
|
|
||||||
// author : Harry Nguyen : https://github.com/thaihoa311
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
|
|
||||||
numeral.register('locale', 'vi', { |
|
||||||
delimiters: { |
|
||||||
thousands: '.', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: ' nghìn', |
|
||||||
million: ' triệu', |
|
||||||
billion: ' tỷ', |
|
||||||
trillion: ' nghìn tỷ' |
|
||||||
}, |
|
||||||
ordinal: function () { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '₫' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
File diff suppressed because one or more lines are too long
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","be-nl",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:" mln",billion:" mld",trillion:" bln"},ordinal:function(a){var b=a%100;return 0!==a&&b<=1||8===b||b>=20?"ste":"de"},currency:{symbol:"€ "}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","bg",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"хил",million:"млн",billion:"млрд",trillion:"трлн"},ordinal:function(a){return""},currency:{symbol:"лв"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","chs",{delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"千",million:"百万",billion:"十亿",trillion:"兆"},ordinal:function(a){return"."},currency:{symbol:"¥"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","cs",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"tis.",million:"mil.",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"Kč"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","da-dk",{delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mio",billion:"mia",trillion:"b"},ordinal:function(a){return"."},currency:{symbol:"DKK"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","de-ch",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(a){return"."},currency:{symbol:"CHF"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","de",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(a){return"."},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","en-au",{delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(a){var b=a%10;return 1===~~(a%100/10)?"th":1===b?"st":2===b?"nd":3===b?"rd":"th"},currency:{symbol:"$"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","en-gb",{delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(a){var b=a%10;return 1===~~(a%100/10)?"th":1===b?"st":2===b?"nd":3===b?"rd":"th"},currency:{symbol:"£"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","en-za",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(a){var b=a%10;return 1===~~(a%100/10)?"th":1===b?"st":2===b?"nd":3===b?"rd":"th"},currency:{symbol:"R"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","es-es",{delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(a){var b=a%10;return 1===b||3===b?"er":2===b?"do":7===b||0===b?"mo":8===b?"vo":9===b?"no":"to"},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","es",{delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(a){var b=a%10;return 1===b||3===b?"er":2===b?"do":7===b||0===b?"mo":8===b?"vo":9===b?"no":"to"},currency:{symbol:"$"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","et",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:" tuh",million:" mln",billion:" mld",trillion:" trl"},ordinal:function(a){return"."},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","fi",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"M",billion:"G",trillion:"T"},ordinal:function(a){return"."},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","fr-ca",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"M",billion:"G",trillion:"T"},ordinal:function(a){return 1===a?"er":"e"},currency:{symbol:"$"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","fr-ch",{delimiters:{thousands:"'",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(a){return 1===a?"er":"e"},currency:{symbol:"CHF"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","fr",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(a){return 1===a?"er":"e"},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","hu",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"E",million:"M",billion:"Mrd",trillion:"T"},ordinal:function(a){return"."},currency:{symbol:" Ft"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","it",{delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"mila",million:"mil",billion:"b",trillion:"t"},ordinal:function(a){return"º"},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","ja",{delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"千",million:"百万",billion:"十億",trillion:"兆"},ordinal:function(a){return"."},currency:{symbol:"¥"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","lv",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:" tūkst.",million:" milj.",billion:" mljrd.",trillion:" trilj."},ordinal:function(a){return"."},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","nl-be",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:" mln",billion:" mld",trillion:" bln"},ordinal:function(a){var b=a%100;return 0!==a&&1>=b||8===b||b>=20?"ste":"de"},currency:{symbol:"€ "}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","nl-nl",{delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mln",billion:"mrd",trillion:"bln"},ordinal:function(a){var b=a%100;return 0!==a&&1>=b||8===b||b>=20?"ste":"de"},currency:{symbol:"€ "}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","no",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(a){return"."},currency:{symbol:"kr"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","pl",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"tys.",million:"mln",billion:"mld",trillion:"bln"},ordinal:function(a){return"."},currency:{symbol:"PLN"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","pt-br",{delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"mil",million:"milhões",billion:"b",trillion:"t"},ordinal:function(a){return"º"},currency:{symbol:"R$"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","pt-pt",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(a){return"º"},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","ru-ua",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"тыс.",million:"млн",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"₴"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","ru",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"тыс.",million:"млн.",billion:"млрд.",trillion:"трлн."},ordinal:function(){return"."},currency:{symbol:"руб."}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","sk",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"tis.",million:"mil.",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","sl",{delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mio",billion:"mrd",trillion:"trilijon"},ordinal:function(){return"."},currency:{symbol:"€"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){var b={1:"'inci",5:"'inci",8:"'inci",70:"'inci",80:"'inci",2:"'nci",7:"'nci",20:"'nci",50:"'nci",3:"'üncü",4:"'üncü",100:"'üncü",6:"'ncı",9:"'uncu",10:"'uncu",30:"'uncu",60:"'ıncı",90:"'ıncı"};a.register("locale","tr",{delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"bin",million:"milyon",billion:"milyar",trillion:"trilyon"},ordinal:function(a){if(0===a)return"'ıncı";var c=a%10,d=a%100-c,e=a>=100?100:null;return b[c]||b[d]||b[e]},currency:{symbol:"₺"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","uk-ua",{delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"тис.",million:"млн",billion:"млрд",trillion:"блн"},ordinal:function(){return""},currency:{symbol:"₴"}})}); |
|
@ -1 +0,0 @@ |
|||||||
!function(a,b){"function"==typeof define&&define.amd?define(["../numeral"],b):b("object"==typeof module&&module.exports?require("../numeral"):a.numeral)}(this,function(a){a.register("locale","vi",{delimiters:{thousands:".",decimal:","},abbreviations:{thousand:" nghìn",million:" triệu",billion:" tỷ",trillion:" nghìn tỷ"},ordinal:function(){return"."},currency:{symbol:"₫"}})}); |
|
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
@ -1,82 +0,0 @@ |
|||||||
{ |
|
||||||
"_from": "numeral@*", |
|
||||||
"_id": "numeral@2.0.6", |
|
||||||
"_inBundle": false, |
|
||||||
"_integrity": "sha1-StCAk21EPCVhrtnyGX7//iX05QY=", |
|
||||||
"_location": "/numeral", |
|
||||||
"_phantomChildren": {}, |
|
||||||
"_requested": { |
|
||||||
"type": "range", |
|
||||||
"registry": true, |
|
||||||
"raw": "numeral@*", |
|
||||||
"name": "numeral", |
|
||||||
"escapedName": "numeral", |
|
||||||
"rawSpec": "*", |
|
||||||
"saveSpec": null, |
|
||||||
"fetchSpec": "*" |
|
||||||
}, |
|
||||||
"_requiredBy": [ |
|
||||||
"/numeral-es6" |
|
||||||
], |
|
||||||
"_resolved": "https://registry.npmjs.org/numeral/-/numeral-2.0.6.tgz", |
|
||||||
"_shasum": "4ad080936d443c2561aed9f2197efffe25f4e506", |
|
||||||
"_spec": "numeral@*", |
|
||||||
"_where": "/Users/mulish/Desktop/gitcoin/blockscout/node_modules/numeral-es6", |
|
||||||
"author": { |
|
||||||
"name": "Adam Draper", |
|
||||||
"email": "adamwdraper@gmail.com", |
|
||||||
"url": "http://github.com/adamwdraper" |
|
||||||
}, |
|
||||||
"bugs": { |
|
||||||
"url": "https://github.com/adamwdraper/Numeral-js/issues" |
|
||||||
}, |
|
||||||
"bundleDependencies": false, |
|
||||||
"deprecated": false, |
|
||||||
"description": "Format and manipulate numbers.", |
|
||||||
"devDependencies": { |
|
||||||
"chai": "^3.5.0", |
|
||||||
"grunt": "latest", |
|
||||||
"grunt-contrib-copy": "^1.0.0", |
|
||||||
"grunt-contrib-jshint": "latest", |
|
||||||
"grunt-contrib-nodeunit": "1.0.0", |
|
||||||
"grunt-contrib-uglify": "latest", |
|
||||||
"grunt-karma": "^2.0.0", |
|
||||||
"grunt-mocha-test": "^0.13.2", |
|
||||||
"grunt-saucelabs": "*", |
|
||||||
"grunt-string-replace": "^1.3.1", |
|
||||||
"karma": "^1.3.0", |
|
||||||
"karma-chai": "^0.1.0", |
|
||||||
"karma-chrome-launcher": "^2.0.0", |
|
||||||
"karma-firefox-launcher": "^1.0.0", |
|
||||||
"karma-mocha": "^1.3.0", |
|
||||||
"karma-mocha-reporter": "^2.2.1", |
|
||||||
"karma-sauce-launcher": "^1.1.0", |
|
||||||
"load-grunt-tasks": "^3.5.2", |
|
||||||
"mocha": "^3.1.2", |
|
||||||
"uglify-js": "latest" |
|
||||||
}, |
|
||||||
"ender": "./ender.js", |
|
||||||
"engines": { |
|
||||||
"node": "*" |
|
||||||
}, |
|
||||||
"homepage": "http://numeraljs.com", |
|
||||||
"keywords": [ |
|
||||||
"numeral", |
|
||||||
"number", |
|
||||||
"format", |
|
||||||
"time", |
|
||||||
"money", |
|
||||||
"percentage" |
|
||||||
], |
|
||||||
"license": "MIT", |
|
||||||
"main": "./numeral.js", |
|
||||||
"name": "numeral", |
|
||||||
"repository": { |
|
||||||
"type": "git", |
|
||||||
"url": "git+https://github.com/adamwdraper/Numeral-js.git" |
|
||||||
}, |
|
||||||
"scripts": { |
|
||||||
"test": "grunt" |
|
||||||
}, |
|
||||||
"version": "2.0.6" |
|
||||||
} |
|
@ -1,47 +0,0 @@ |
|||||||
// numeral.js format configuration
|
|
||||||
// format : BPS
|
|
||||||
// author : Jack Altiere : https://github.com/jaltiere
|
|
||||||
// BPS format - http://www.investopedia.com/terms/b/basispoint.asp
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('format', 'bps', { |
|
||||||
regexps: { |
|
||||||
format: /(BPS)/, |
|
||||||
unformat: /(BPS)/ |
|
||||||
}, |
|
||||||
format: function(value, format, roundingFunction) { |
|
||||||
var space = numeral._.includes(format, ' BPS') ? ' ' : '', |
|
||||||
output; |
|
||||||
|
|
||||||
value = value * 10000; |
|
||||||
|
|
||||||
// check for space before BPS
|
|
||||||
format = format.replace(/\s?BPS/, ''); |
|
||||||
|
|
||||||
output = numeral._.numberToFormat(value, format, roundingFunction); |
|
||||||
|
|
||||||
if (numeral._.includes(output, ')')) { |
|
||||||
output = output.split(''); |
|
||||||
|
|
||||||
output.splice(-1, 0, space + 'BPS'); |
|
||||||
|
|
||||||
output = output.join(''); |
|
||||||
} else { |
|
||||||
output = output + space + 'BPS'; |
|
||||||
} |
|
||||||
|
|
||||||
return output; |
|
||||||
}, |
|
||||||
unformat: function(string) { |
|
||||||
return +(numeral._.stringToNumber(string) * 0.0001).toFixed(15); |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,91 +0,0 @@ |
|||||||
// numeral.js format configuration
|
|
||||||
// format : bytes
|
|
||||||
// author : Adam Draper : https://github.com/adamwdraper
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
var decimal = { |
|
||||||
base: 1000, |
|
||||||
suffixes: ['B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'] |
|
||||||
}, |
|
||||||
binary = { |
|
||||||
base: 1024, |
|
||||||
suffixes: ['B', 'KiB', 'MiB', 'GiB', 'TiB', 'PiB', 'EiB', 'ZiB', 'YiB'] |
|
||||||
}; |
|
||||||
|
|
||||||
var allSuffixes = decimal.suffixes.concat(binary.suffixes.filter(function (item) { |
|
||||||
return decimal.suffixes.indexOf(item) < 0; |
|
||||||
})); |
|
||||||
var unformatRegex = allSuffixes.join('|'); |
|
||||||
// Allow support for BPS (http://www.investopedia.com/terms/b/basispoint.asp)
|
|
||||||
unformatRegex = '(' + unformatRegex.replace('B', 'B(?!PS)') + ')'; |
|
||||||
|
|
||||||
numeral.register('format', 'bytes', { |
|
||||||
regexps: { |
|
||||||
format: /([0\s]i?b)/, |
|
||||||
unformat: new RegExp(unformatRegex) |
|
||||||
}, |
|
||||||
format: function(value, format, roundingFunction) { |
|
||||||
var output, |
|
||||||
bytes = numeral._.includes(format, 'ib') ? binary : decimal, |
|
||||||
suffix = numeral._.includes(format, ' b') || numeral._.includes(format, ' ib') ? ' ' : '', |
|
||||||
power, |
|
||||||
min, |
|
||||||
max; |
|
||||||
|
|
||||||
// check for space before
|
|
||||||
format = format.replace(/\s?i?b/, ''); |
|
||||||
|
|
||||||
for (power = 0; power <= bytes.suffixes.length; power++) { |
|
||||||
min = Math.pow(bytes.base, power); |
|
||||||
max = Math.pow(bytes.base, power + 1); |
|
||||||
|
|
||||||
if (value === null || value === 0 || value >= min && value < max) { |
|
||||||
suffix += bytes.suffixes[power]; |
|
||||||
|
|
||||||
if (min > 0) { |
|
||||||
value = value / min; |
|
||||||
} |
|
||||||
|
|
||||||
break; |
|
||||||
} |
|
||||||
} |
|
||||||
|
|
||||||
output = numeral._.numberToFormat(value, format, roundingFunction); |
|
||||||
|
|
||||||
return output + suffix; |
|
||||||
}, |
|
||||||
unformat: function(string) { |
|
||||||
var value = numeral._.stringToNumber(string), |
|
||||||
power, |
|
||||||
bytesMultiplier; |
|
||||||
|
|
||||||
if (value) { |
|
||||||
for (power = decimal.suffixes.length - 1; power >= 0; power--) { |
|
||||||
if (numeral._.includes(string, decimal.suffixes[power])) { |
|
||||||
bytesMultiplier = Math.pow(decimal.base, power); |
|
||||||
|
|
||||||
break; |
|
||||||
} |
|
||||||
|
|
||||||
if (numeral._.includes(string, binary.suffixes[power])) { |
|
||||||
bytesMultiplier = Math.pow(binary.base, power); |
|
||||||
|
|
||||||
break; |
|
||||||
} |
|
||||||
} |
|
||||||
|
|
||||||
value *= (bytesMultiplier || 1); |
|
||||||
} |
|
||||||
|
|
||||||
return value; |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,74 +0,0 @@ |
|||||||
// numeral.js format configuration
|
|
||||||
// format : currency
|
|
||||||
// author : Adam Draper : https://github.com/adamwdraper
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('format', 'currency', { |
|
||||||
regexps: { |
|
||||||
format: /(\$)/ |
|
||||||
}, |
|
||||||
format: function(value, format, roundingFunction) { |
|
||||||
var locale = numeral.locales[numeral.options.currentLocale], |
|
||||||
symbols = { |
|
||||||
before: format.match(/^([\+|\-|\(|\s|\$]*)/)[0], |
|
||||||
after: format.match(/([\+|\-|\)|\s|\$]*)$/)[0] |
|
||||||
}, |
|
||||||
output, |
|
||||||
symbol, |
|
||||||
i; |
|
||||||
|
|
||||||
// strip format of spaces and $
|
|
||||||
format = format.replace(/\s?\$\s?/, ''); |
|
||||||
|
|
||||||
// format the number
|
|
||||||
output = numeral._.numberToFormat(value, format, roundingFunction); |
|
||||||
|
|
||||||
// update the before and after based on value
|
|
||||||
if (value >= 0) { |
|
||||||
symbols.before = symbols.before.replace(/[\-\(]/, ''); |
|
||||||
symbols.after = symbols.after.replace(/[\-\)]/, ''); |
|
||||||
} else if (value < 0 && (!numeral._.includes(symbols.before, '-') && !numeral._.includes(symbols.before, '('))) { |
|
||||||
symbols.before = '-' + symbols.before; |
|
||||||
} |
|
||||||
|
|
||||||
// loop through each before symbol
|
|
||||||
for (i = 0; i < symbols.before.length; i++) { |
|
||||||
symbol = symbols.before[i]; |
|
||||||
|
|
||||||
switch (symbol) { |
|
||||||
case '$': |
|
||||||
output = numeral._.insert(output, locale.currency.symbol, i); |
|
||||||
break; |
|
||||||
case ' ': |
|
||||||
output = numeral._.insert(output, ' ', i + locale.currency.symbol.length - 1); |
|
||||||
break; |
|
||||||
} |
|
||||||
} |
|
||||||
|
|
||||||
// loop through each after symbol
|
|
||||||
for (i = symbols.after.length - 1; i >= 0; i--) { |
|
||||||
symbol = symbols.after[i]; |
|
||||||
|
|
||||||
switch (symbol) { |
|
||||||
case '$': |
|
||||||
output = i === symbols.after.length - 1 ? output + locale.currency.symbol : numeral._.insert(output, locale.currency.symbol, -(symbols.after.length - (1 + i))); |
|
||||||
break; |
|
||||||
case ' ': |
|
||||||
output = i === symbols.after.length - 1 ? output + ' ' : numeral._.insert(output, ' ', -(symbols.after.length - (1 + i) + locale.currency.symbol.length - 1)); |
|
||||||
break; |
|
||||||
} |
|
||||||
} |
|
||||||
|
|
||||||
|
|
||||||
return output; |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,46 +0,0 @@ |
|||||||
// numeral.js format configuration
|
|
||||||
// format : exponential
|
|
||||||
// author : Adam Draper : https://github.com/adamwdraper
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('format', 'exponential', { |
|
||||||
regexps: { |
|
||||||
format: /(e\+|e-)/, |
|
||||||
unformat: /(e\+|e-)/ |
|
||||||
}, |
|
||||||
format: function(value, format, roundingFunction) { |
|
||||||
var output, |
|
||||||
exponential = typeof value === 'number' && !numeral._.isNaN(value) ? value.toExponential() : '0e+0', |
|
||||||
parts = exponential.split('e'); |
|
||||||
|
|
||||||
format = format.replace(/e[\+|\-]{1}0/, ''); |
|
||||||
|
|
||||||
output = numeral._.numberToFormat(Number(parts[0]), format, roundingFunction); |
|
||||||
|
|
||||||
return output + 'e' + parts[1]; |
|
||||||
}, |
|
||||||
unformat: function(string) { |
|
||||||
var parts = numeral._.includes(string, 'e+') ? string.split('e+') : string.split('e-'), |
|
||||||
value = Number(parts[0]), |
|
||||||
power = Number(parts[1]); |
|
||||||
|
|
||||||
power = numeral._.includes(string, 'e-') ? power *= -1 : power; |
|
||||||
|
|
||||||
function cback(accum, curr, currI, O) { |
|
||||||
var corrFactor = numeral._.correctionFactor(accum, curr), |
|
||||||
num = (accum * corrFactor) * (curr * corrFactor) / (corrFactor * corrFactor); |
|
||||||
return num; |
|
||||||
} |
|
||||||
|
|
||||||
return numeral._.reduce([value, Math.pow(10, power)], cback, 1); |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,33 +0,0 @@ |
|||||||
// numeral.js format configuration
|
|
||||||
// format : ordinal
|
|
||||||
// author : Adam Draper : https://github.com/adamwdraper
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('format', 'ordinal', { |
|
||||||
regexps: { |
|
||||||
format: /(o)/ |
|
||||||
}, |
|
||||||
format: function(value, format, roundingFunction) { |
|
||||||
var locale = numeral.locales[numeral.options.currentLocale], |
|
||||||
output, |
|
||||||
ordinal = numeral._.includes(format, ' o') ? ' ' : ''; |
|
||||||
|
|
||||||
// check for space before
|
|
||||||
format = format.replace(/\s?o/, ''); |
|
||||||
|
|
||||||
ordinal += locale.ordinal(value); |
|
||||||
|
|
||||||
output = numeral._.numberToFormat(value, format, roundingFunction); |
|
||||||
|
|
||||||
return output + ordinal; |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,52 +0,0 @@ |
|||||||
// numeral.js format configuration
|
|
||||||
// format : percentage
|
|
||||||
// author : Adam Draper : https://github.com/adamwdraper
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('format', 'percentage', { |
|
||||||
regexps: { |
|
||||||
format: /(%)/, |
|
||||||
unformat: /(%)/ |
|
||||||
}, |
|
||||||
format: function(value, format, roundingFunction) { |
|
||||||
var space = numeral._.includes(format, ' %') ? ' ' : '', |
|
||||||
output; |
|
||||||
|
|
||||||
if (numeral.options.scalePercentBy100) { |
|
||||||
value = value * 100; |
|
||||||
} |
|
||||||
|
|
||||||
// check for space before %
|
|
||||||
format = format.replace(/\s?\%/, ''); |
|
||||||
|
|
||||||
output = numeral._.numberToFormat(value, format, roundingFunction); |
|
||||||
|
|
||||||
if (numeral._.includes(output, ')')) { |
|
||||||
output = output.split(''); |
|
||||||
|
|
||||||
output.splice(-1, 0, space + '%'); |
|
||||||
|
|
||||||
output = output.join(''); |
|
||||||
} else { |
|
||||||
output = output + space + '%'; |
|
||||||
} |
|
||||||
|
|
||||||
return output; |
|
||||||
}, |
|
||||||
unformat: function(string) { |
|
||||||
var number = numeral._.stringToNumber(string); |
|
||||||
if (numeral.options.scalePercentBy100) { |
|
||||||
return number * 0.01; |
|
||||||
} |
|
||||||
return number; |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,47 +0,0 @@ |
|||||||
// numeral.js format configuration
|
|
||||||
// format : time
|
|
||||||
// author : Adam Draper : https://github.com/adamwdraper
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('format', 'time', { |
|
||||||
regexps: { |
|
||||||
format: /(:)/, |
|
||||||
unformat: /(:)/ |
|
||||||
}, |
|
||||||
format: function(value, format, roundingFunction) { |
|
||||||
var hours = Math.floor(value / 60 / 60), |
|
||||||
minutes = Math.floor((value - (hours * 60 * 60)) / 60), |
|
||||||
seconds = Math.round(value - (hours * 60 * 60) - (minutes * 60)); |
|
||||||
|
|
||||||
return hours + ':' + (minutes < 10 ? '0' + minutes : minutes) + ':' + (seconds < 10 ? '0' + seconds : seconds); |
|
||||||
}, |
|
||||||
unformat: function(string) { |
|
||||||
var timeArray = string.split(':'), |
|
||||||
seconds = 0; |
|
||||||
|
|
||||||
// turn hours and minutes into seconds and add them all up
|
|
||||||
if (timeArray.length === 3) { |
|
||||||
// hours
|
|
||||||
seconds = seconds + (Number(timeArray[0]) * 60 * 60); |
|
||||||
// minutes
|
|
||||||
seconds = seconds + (Number(timeArray[1]) * 60); |
|
||||||
// seconds
|
|
||||||
seconds = seconds + Number(timeArray[2]); |
|
||||||
} else if (timeArray.length === 2) { |
|
||||||
// minutes
|
|
||||||
seconds = seconds + (Number(timeArray[0]) * 60); |
|
||||||
// seconds
|
|
||||||
seconds = seconds + Number(timeArray[1]); |
|
||||||
} |
|
||||||
return Number(seconds); |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,40 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : Bulgarian
|
|
||||||
// author : Don Vince : https://github.com/donvince/
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'bg', { |
|
||||||
delimiters: { |
|
||||||
thousands: ' ', |
|
||||||
decimal: ',' |
|
||||||
}, |
|
||||||
abbreviations: { // I found these here http://www.unicode.org/cldr/charts/28/verify/numbers/bg.html
|
|
||||||
thousand: 'хил', |
|
||||||
million: 'млн', |
|
||||||
billion: 'млрд', |
|
||||||
trillion: 'трлн' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
// google translate suggests:
|
|
||||||
// 1st=1-ви; 2nd=2-ри; 7th=7-ми;
|
|
||||||
// 8th=8-ми and many others end with -ти
|
|
||||||
// for example 3rd=3-ти
|
|
||||||
// However since I've seen suggestions that in
|
|
||||||
// Bulgarian the ordinal can be taken in
|
|
||||||
// different forms (masculine, feminine, neuter)
|
|
||||||
// I've opted to wimp out on commiting that to code
|
|
||||||
return ''; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: 'лв' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
@ -1,32 +0,0 @@ |
|||||||
// numeral.js locale configuration
|
|
||||||
// locale : simplified chinese (chs)
|
|
||||||
// author : badplum : https://github.com/badplum
|
|
||||||
|
|
||||||
(function (global, factory) { |
|
||||||
if (typeof define === 'function' && define.amd) { |
|
||||||
define(['../numeral'], factory); |
|
||||||
} else if (typeof module === 'object' && module.exports) { |
|
||||||
factory(require('../numeral')); |
|
||||||
} else { |
|
||||||
factory(global.numeral); |
|
||||||
} |
|
||||||
}(this, function (numeral) { |
|
||||||
numeral.register('locale', 'chs', { |
|
||||||
delimiters: { |
|
||||||
thousands: ',', |
|
||||||
decimal: '.' |
|
||||||
}, |
|
||||||
abbreviations: { |
|
||||||
thousand: '千', |
|
||||||
million: '百万', |
|
||||||
billion: '十亿', |
|
||||||
trillion: '兆' |
|
||||||
}, |
|
||||||
ordinal: function (number) { |
|
||||||
return '.'; |
|
||||||
}, |
|
||||||
currency: { |
|
||||||
symbol: '¥' |
|
||||||
} |
|
||||||
}); |
|
||||||
})); |
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue