Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/austingebauer/devise.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/yargs/node_modules/ansi-regex/index.js')
-rw-r--r--node_modules/yargs/node_modules/ansi-regex/index.js14
1 files changed, 14 insertions, 0 deletions
diff --git a/node_modules/yargs/node_modules/ansi-regex/index.js b/node_modules/yargs/node_modules/ansi-regex/index.js
new file mode 100644
index 0000000..c254480
--- /dev/null
+++ b/node_modules/yargs/node_modules/ansi-regex/index.js
@@ -0,0 +1,14 @@
+'use strict';
+
+module.exports = options => {
+ options = Object.assign({
+ onlyFirst: false
+ }, options);
+
+ const pattern = [
+ '[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)',
+ '(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))'
+ ].join('|');
+
+ return new RegExp(pattern, options.onlyFirst ? undefined : 'g');
+};