aboutsummaryrefslogtreecommitdiff
path: root/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width
diff options
context:
space:
mode:
Diffstat (limited to 'deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width')
-rw-r--r--deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/index.js36
-rw-r--r--deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/license9
-rw-r--r--deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/index.js46
-rw-r--r--deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/license21
-rw-r--r--deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/package.json81
-rw-r--r--deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/readme.md39
-rw-r--r--deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/package.json88
-rw-r--r--deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/readme.md42
8 files changed, 0 insertions, 362 deletions
diff --git a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/index.js b/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/index.js
deleted file mode 100644
index bbc49d29b1..0000000000
--- a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/index.js
+++ /dev/null
@@ -1,36 +0,0 @@
-'use strict';
-const stripAnsi = require('strip-ansi');
-const isFullwidthCodePoint = require('is-fullwidth-code-point');
-
-module.exports = str => {
- if (typeof str !== 'string' || str.length === 0) {
- return 0;
- }
-
- str = stripAnsi(str);
-
- let width = 0;
-
- for (let i = 0; i < str.length; i++) {
- const code = str.codePointAt(i);
-
- // Ignore control characters
- if (code <= 0x1F || (code >= 0x7F && code <= 0x9F)) {
- continue;
- }
-
- // Ignore combining characters
- if (code >= 0x300 && code <= 0x36F) {
- continue;
- }
-
- // Surrogates
- if (code > 0xFFFF) {
- i++;
- }
-
- width += isFullwidthCodePoint(code) ? 2 : 1;
- }
-
- return width;
-};
diff --git a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/license b/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/license
deleted file mode 100644
index e7af2f7710..0000000000
--- a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/license
+++ /dev/null
@@ -1,9 +0,0 @@
-MIT License
-
-Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
-
-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.
diff --git a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/index.js b/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/index.js
deleted file mode 100644
index d506327c3e..0000000000
--- a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/index.js
+++ /dev/null
@@ -1,46 +0,0 @@
-'use strict';
-/* eslint-disable yoda */
-module.exports = x => {
- if (Number.isNaN(x)) {
- return false;
- }
-
- // code points are derived from:
- // http://www.unix.org/Public/UNIDATA/EastAsianWidth.txt
- if (
- x >= 0x1100 && (
- x <= 0x115f || // Hangul Jamo
- x === 0x2329 || // LEFT-POINTING ANGLE BRACKET
- x === 0x232a || // RIGHT-POINTING ANGLE BRACKET
- // CJK Radicals Supplement .. Enclosed CJK Letters and Months
- (0x2e80 <= x && x <= 0x3247 && x !== 0x303f) ||
- // Enclosed CJK Letters and Months .. CJK Unified Ideographs Extension A
- (0x3250 <= x && x <= 0x4dbf) ||
- // CJK Unified Ideographs .. Yi Radicals
- (0x4e00 <= x && x <= 0xa4c6) ||
- // Hangul Jamo Extended-A
- (0xa960 <= x && x <= 0xa97c) ||
- // Hangul Syllables
- (0xac00 <= x && x <= 0xd7a3) ||
- // CJK Compatibility Ideographs
- (0xf900 <= x && x <= 0xfaff) ||
- // Vertical Forms
- (0xfe10 <= x && x <= 0xfe19) ||
- // CJK Compatibility Forms .. Small Form Variants
- (0xfe30 <= x && x <= 0xfe6b) ||
- // Halfwidth and Fullwidth Forms
- (0xff01 <= x && x <= 0xff60) ||
- (0xffe0 <= x && x <= 0xffe6) ||
- // Kana Supplement
- (0x1b000 <= x && x <= 0x1b001) ||
- // Enclosed Ideographic Supplement
- (0x1f200 <= x && x <= 0x1f251) ||
- // CJK Unified Ideographs Extension B .. Tertiary Ideographic Plane
- (0x20000 <= x && x <= 0x3fffd)
- )
- ) {
- return true;
- }
-
- return false;
-};
diff --git a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/license b/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/license
deleted file mode 100644
index 654d0bfe94..0000000000
--- a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/license
+++ /dev/null
@@ -1,21 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
-
-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.
diff --git a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/package.json b/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/package.json
deleted file mode 100644
index f72c16ab58..0000000000
--- a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/package.json
+++ /dev/null
@@ -1,81 +0,0 @@
-{
- "_from": "is-fullwidth-code-point@^2.0.0",
- "_id": "is-fullwidth-code-point@2.0.0",
- "_integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=",
- "_location": "/update-notifier/boxen/string-width/is-fullwidth-code-point",
- "_phantomChildren": {},
- "_requested": {
- "type": "range",
- "registry": true,
- "raw": "is-fullwidth-code-point@^2.0.0",
- "name": "is-fullwidth-code-point",
- "escapedName": "is-fullwidth-code-point",
- "rawSpec": "^2.0.0",
- "saveSpec": null,
- "fetchSpec": "^2.0.0"
- },
- "_requiredBy": [
- "/update-notifier/boxen/string-width"
- ],
- "_resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz",
- "_shasum": "a3b30a5c4f199183167aaab93beefae3ddfb654f",
- "_shrinkwrap": null,
- "_spec": "is-fullwidth-code-point@^2.0.0",
- "_where": "/Users/zkat/Documents/code/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width",
- "author": {
- "name": "Sindre Sorhus",
- "email": "sindresorhus@gmail.com",
- "url": "sindresorhus.com"
- },
- "bin": null,
- "bugs": {
- "url": "https://github.com/sindresorhus/is-fullwidth-code-point/issues"
- },
- "bundleDependencies": false,
- "dependencies": {},
- "deprecated": false,
- "description": "Check if the character represented by a given Unicode code point is fullwidth",
- "devDependencies": {
- "ava": "*",
- "xo": "*"
- },
- "engines": {
- "node": ">=4"
- },
- "files": [
- "index.js"
- ],
- "homepage": "https://github.com/sindresorhus/is-fullwidth-code-point#readme",
- "keywords": [
- "fullwidth",
- "full-width",
- "full",
- "width",
- "unicode",
- "character",
- "char",
- "string",
- "str",
- "codepoint",
- "code",
- "point",
- "is",
- "detect",
- "check"
- ],
- "license": "MIT",
- "name": "is-fullwidth-code-point",
- "optionalDependencies": {},
- "peerDependencies": {},
- "repository": {
- "type": "git",
- "url": "git+https://github.com/sindresorhus/is-fullwidth-code-point.git"
- },
- "scripts": {
- "test": "xo && ava"
- },
- "version": "2.0.0",
- "xo": {
- "esnext": true
- }
-}
diff --git a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/readme.md b/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/readme.md
deleted file mode 100644
index 093b0281b2..0000000000
--- a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/node_modules/is-fullwidth-code-point/readme.md
+++ /dev/null
@@ -1,39 +0,0 @@
-# is-fullwidth-code-point [![Build Status](https://travis-ci.org/sindresorhus/is-fullwidth-code-point.svg?branch=master)](https://travis-ci.org/sindresorhus/is-fullwidth-code-point)
-
-> Check if the character represented by a given [Unicode code point](https://en.wikipedia.org/wiki/Code_point) is [fullwidth](https://en.wikipedia.org/wiki/Halfwidth_and_fullwidth_forms)
-
-
-## Install
-
-```
-$ npm install --save is-fullwidth-code-point
-```
-
-
-## Usage
-
-```js
-const isFullwidthCodePoint = require('is-fullwidth-code-point');
-
-isFullwidthCodePoint('谢'.codePointAt());
-//=> true
-
-isFullwidthCodePoint('a'.codePointAt());
-//=> false
-```
-
-
-## API
-
-### isFullwidthCodePoint(input)
-
-#### input
-
-Type: `number`
-
-[Code point](https://en.wikipedia.org/wiki/Code_point) of a character.
-
-
-## License
-
-MIT © [Sindre Sorhus](https://sindresorhus.com)
diff --git a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/package.json b/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/package.json
deleted file mode 100644
index 52f250897c..0000000000
--- a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/package.json
+++ /dev/null
@@ -1,88 +0,0 @@
-{
- "_from": "string-width@^2.0.0",
- "_id": "string-width@2.1.1",
- "_inBundle": false,
- "_integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==",
- "_location": "/update-notifier/boxen/string-width",
- "_phantomChildren": {},
- "_requested": {
- "type": "range",
- "registry": true,
- "raw": "string-width@^2.0.0",
- "name": "string-width",
- "escapedName": "string-width",
- "rawSpec": "^2.0.0",
- "saveSpec": null,
- "fetchSpec": "^2.0.0"
- },
- "_requiredBy": [
- "/update-notifier/boxen",
- "/update-notifier/boxen/ansi-align"
- ],
- "_resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz",
- "_shasum": "ab93f27a8dc13d28cac815c462143a6d9012ae9e",
- "_spec": "string-width@^2.0.0",
- "_where": "/Users/zkat/Documents/code/npm/node_modules/update-notifier/node_modules/boxen",
- "author": {
- "name": "Sindre Sorhus",
- "email": "sindresorhus@gmail.com",
- "url": "sindresorhus.com"
- },
- "bugs": {
- "url": "https://github.com/sindresorhus/string-width/issues"
- },
- "bundleDependencies": false,
- "dependencies": {
- "is-fullwidth-code-point": "^2.0.0",
- "strip-ansi": "^4.0.0"
- },
- "deprecated": false,
- "description": "Get the visual width of a string - the number of columns required to display it",
- "devDependencies": {
- "ava": "*",
- "xo": "*"
- },
- "engines": {
- "node": ">=4"
- },
- "files": [
- "index.js"
- ],
- "homepage": "https://github.com/sindresorhus/string-width#readme",
- "keywords": [
- "string",
- "str",
- "character",
- "char",
- "unicode",
- "width",
- "visual",
- "column",
- "columns",
- "fullwidth",
- "full-width",
- "full",
- "ansi",
- "escape",
- "codes",
- "cli",
- "command-line",
- "terminal",
- "console",
- "cjk",
- "chinese",
- "japanese",
- "korean",
- "fixed-width"
- ],
- "license": "MIT",
- "name": "string-width",
- "repository": {
- "type": "git",
- "url": "git+https://github.com/sindresorhus/string-width.git"
- },
- "scripts": {
- "test": "xo && ava"
- },
- "version": "2.1.1"
-}
diff --git a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/readme.md b/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/readme.md
deleted file mode 100644
index df5b7199f9..0000000000
--- a/deps/npm/node_modules/update-notifier/node_modules/boxen/node_modules/string-width/readme.md
+++ /dev/null
@@ -1,42 +0,0 @@
-# string-width [![Build Status](https://travis-ci.org/sindresorhus/string-width.svg?branch=master)](https://travis-ci.org/sindresorhus/string-width)
-
-> Get the visual width of a string - the number of columns required to display it
-
-Some Unicode characters are [fullwidth](https://en.wikipedia.org/wiki/Halfwidth_and_fullwidth_forms) and use double the normal width. [ANSI escape codes](https://en.wikipedia.org/wiki/ANSI_escape_code) are stripped and doesn't affect the width.
-
-Useful to be able to measure the actual width of command-line output.
-
-
-## Install
-
-```
-$ npm install string-width
-```
-
-
-## Usage
-
-```js
-const stringWidth = require('string-width');
-
-stringWidth('古');
-//=> 2
-
-stringWidth('\u001b[1m古\u001b[22m');
-//=> 2
-
-stringWidth('a');
-//=> 1
-```
-
-
-## Related
-
-- [string-width-cli](https://github.com/sindresorhus/string-width-cli) - CLI for this module
-- [string-length](https://github.com/sindresorhus/string-length) - Get the real length of a string
-- [widest-line](https://github.com/sindresorhus/widest-line) - Get the visual width of the widest line in a string
-
-
-## License
-
-MIT © [Sindre Sorhus](https://sindresorhus.com)