new license file version [CI SKIP]
This commit is contained in:
@@ -0,0 +1,100 @@
|
||||
# mime-db
|
||||
|
||||
[![NPM Version][npm-version-image]][npm-url]
|
||||
[![NPM Downloads][npm-downloads-image]][npm-url]
|
||||
[![Node.js Version][node-image]][node-url]
|
||||
[![Build Status][ci-image]][ci-url]
|
||||
[![Coverage Status][coveralls-image]][coveralls-url]
|
||||
|
||||
This is a database of all mime types.
|
||||
It consists of a single, public JSON file and does not include any logic,
|
||||
allowing it to remain as un-opinionated as possible with an API.
|
||||
It aggregates data from the following sources:
|
||||
|
||||
- http://www.iana.org/assignments/media-types/media-types.xhtml
|
||||
- http://svn.apache.org/repos/asf/httpd/httpd/trunk/docs/conf/mime.types
|
||||
- http://hg.nginx.org/nginx/raw-file/default/conf/mime.types
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
npm install mime-db
|
||||
```
|
||||
|
||||
### Database Download
|
||||
|
||||
If you're crazy enough to use this in the browser, you can just grab the
|
||||
JSON file using [jsDelivr](https://www.jsdelivr.com/). It is recommended to
|
||||
replace `master` with [a release tag](https://github.com/jshttp/mime-db/tags)
|
||||
as the JSON format may change in the future.
|
||||
|
||||
```
|
||||
https://cdn.jsdelivr.net/gh/jshttp/mime-db@master/db.json
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
var db = require('mime-db')
|
||||
|
||||
// grab data on .js files
|
||||
var data = db['application/javascript']
|
||||
```
|
||||
|
||||
## Data Structure
|
||||
|
||||
The JSON file is a map lookup for lowercased mime types.
|
||||
Each mime type has the following properties:
|
||||
|
||||
- `.source` - where the mime type is defined.
|
||||
If not set, it's probably a custom media type.
|
||||
- `apache` - [Apache common media types](http://svn.apache.org/repos/asf/httpd/httpd/trunk/docs/conf/mime.types)
|
||||
- `iana` - [IANA-defined media types](http://www.iana.org/assignments/media-types/media-types.xhtml)
|
||||
- `nginx` - [nginx media types](http://hg.nginx.org/nginx/raw-file/default/conf/mime.types)
|
||||
- `.extensions[]` - known extensions associated with this mime type.
|
||||
- `.compressible` - whether a file of this type can be gzipped.
|
||||
- `.charset` - the default charset associated with this type, if any.
|
||||
|
||||
If unknown, every property could be `undefined`.
|
||||
|
||||
## Contributing
|
||||
|
||||
To edit the database, only make PRs against `src/custom-types.json` or
|
||||
`src/custom-suffix.json`.
|
||||
|
||||
The `src/custom-types.json` file is a JSON object with the MIME type as the
|
||||
keys and the values being an object with the following keys:
|
||||
|
||||
- `compressible` - leave out if you don't know, otherwise `true`/`false` to
|
||||
indicate whether the data represented by the type is typically compressible.
|
||||
- `extensions` - include an array of file extensions that are associated with
|
||||
the type.
|
||||
- `notes` - human-readable notes about the type, typically what the type is.
|
||||
- `sources` - include an array of URLs of where the MIME type and the associated
|
||||
extensions are sourced from. This needs to be a [primary source](https://en.wikipedia.org/wiki/Primary_source);
|
||||
links to type aggregating sites and Wikipedia are _not acceptable_.
|
||||
|
||||
To update the build, run `npm run build`.
|
||||
|
||||
### Adding Custom Media Types
|
||||
|
||||
The best way to get new media types included in this library is to register
|
||||
them with the IANA. The community registration procedure is outlined in
|
||||
[RFC 6838 section 5](http://tools.ietf.org/html/rfc6838#section-5). Types
|
||||
registered with the IANA are automatically pulled into this library.
|
||||
|
||||
If that is not possible / feasible, they can be added directly here as a
|
||||
"custom" type. To do this, it is required to have a primary source that
|
||||
definitively lists the media type. If an extension is going to be listed as
|
||||
associateed with this media type, the source must definitively link the
|
||||
media type and extension as well.
|
||||
|
||||
[ci-image]: https://badgen.net/github/checks/jshttp/mime-db/master?label=ci
|
||||
[ci-url]: https://github.com/jshttp/mime-db/actions?query=workflow%3Aci
|
||||
[coveralls-image]: https://badgen.net/coveralls/c/github/jshttp/mime-db/master
|
||||
[coveralls-url]: https://coveralls.io/r/jshttp/mime-db?branch=master
|
||||
[node-image]: https://badgen.net/npm/node/mime-db
|
||||
[node-url]: https://nodejs.org/en/download
|
||||
[npm-downloads-image]: https://badgen.net/npm/dm/mime-db
|
||||
[npm-url]: https://npmjs.org/package/mime-db
|
||||
[npm-version-image]: https://badgen.net/npm/v/mime-db
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={C:{"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0.00536,"35":0,"36":0,"37":0.00536,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"101":0,"102":0.00536,"103":0.01607,"104":0,"105":0.00536,"106":0,"107":0,"108":0.31071,"109":0.19285,"110":0,"111":0,"3.5":0,"3.6":0},D:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0.00536,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0.02143,"70":0,"71":0.00536,"72":0,"73":0,"74":0.00536,"75":0.00536,"76":1.09283,"77":0.10178,"78":0,"79":0.04286,"80":0.00536,"81":0,"83":0,"84":0,"85":0,"86":0,"87":0.04286,"88":0.01607,"89":0,"90":0,"91":0.00536,"92":0,"93":0.19285,"94":0.00536,"95":0,"96":0,"97":0,"98":0.01071,"99":0.00536,"100":0,"101":0.00536,"102":0.01071,"103":0.10178,"104":0.01607,"105":0.1125,"106":0.05357,"107":0.13393,"108":8.7212,"109":5.91413,"110":0.05357,"111":0,"112":0},F:{"9":0,"11":0,"12":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"60":0,"62":0,"63":0.02679,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0.00536,"93":0.21428,"94":0.12321,"9.5-9.6":0,"10.0-10.1":0,"10.5":0,"10.6":0,"11.1":0,"11.5":0,"11.6":0,"12.1":0},B:{"12":0,"13":0,"14":0,"15":0,"16":0.075,"17":0.01071,"18":0.01071,"79":0,"80":0,"81":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"101":0,"102":0,"103":0,"104":0.01607,"105":0.36963,"106":0,"107":0.08571,"108":1.76781,"109":1.41961},E:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0.00536,"15":0,_:"0","3.1":0,"3.2":0,"5.1":0.00536,"6.1":0,"7.1":0,"9.1":0,"10.1":0,"11.1":0,"12.1":0,"13.1":0.03214,"14.1":0.16071,"15.1":0.02679,"15.2-15.3":0.00536,"15.4":0.05357,"15.5":0.09643,"15.6":0.48213,"16.0":0.06428,"16.1":0.15535,"16.2":0.43392,"16.3":0.01071},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0,"5.0-5.1":0.00917,"6.0-6.1":0,"7.0-7.1":0.01682,"8.1-8.4":0.00764,"9.0-9.2":0,"9.3":0.30729,"10.0-10.2":0,"10.3":0.00917,"11.0-11.2":0.00306,"11.3-11.4":0.01376,"12.0-12.1":0.03516,"12.2-12.5":0.26448,"13.0-13.1":0.00764,"13.2":0,"13.3":0,"13.4-13.7":0.01682,"14.0-14.4":0.09937,"14.5-14.8":0.159,"15.0-15.1":0.09479,"15.2-15.3":0.14218,"15.4":0.14829,"15.5":0.70325,"15.6":1.42027,"16.0":2.1648,"16.1":3.87248,"16.2":3.86636,"16.3":0.28436},P:{"4":0.18052,"5.0-5.4":0,"6.2-6.4":0,"7.2-7.4":0.04248,"8.2":0,"9.2":0,"10.1":0,"11.1-11.2":0.03186,"12.0":0.01062,"13.0":0.05309,"14.0":0.01062,"15.0":0,"16.0":0.07433,"17.0":0.93446,"18.0":0.06371,"19.0":3.11131},I:{"0":0,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0.12025,"4.4":0,"4.4.3-4.4.4":1.08222},K:{_:"0 10 11 12 11.1 11.5 12.1"},A:{"6":0,"7":0,"8":0,"9":0,"10":0,"11":0.00536,"5.5":0},J:{"7":0,"10":0},N:{"10":0,"11":0},R:{_:"0"},M:{"0":0.24608},Q:{"13.1":0},O:{"0":1.55541},H:{"0":0.09231},L:{"0":52.52508},S:{"2.5":0}};
|
||||
@@ -0,0 +1,58 @@
|
||||
{
|
||||
"name": "@vincjo/datatables",
|
||||
"version": "1.1.0",
|
||||
"keywords": [
|
||||
"svelte sveltejs table tables datatable datatables"
|
||||
],
|
||||
"description": "A toolkit for creating datatable components with Svelte",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/vincjo/datatables.git"
|
||||
},
|
||||
"author": "vincjo",
|
||||
"license": "MIT",
|
||||
"bugs": {
|
||||
"url": "https://github.com/vincjo/datatables/issues"
|
||||
},
|
||||
"homepage": "https://vincjo.fr/datatables",
|
||||
"devDependencies": {
|
||||
"@sveltejs/adapter-node": "^1.0.0-next.100",
|
||||
"@sveltejs/kit": "next",
|
||||
"@sveltejs/package": "next",
|
||||
"@typescript-eslint/eslint-plugin": "^5.27.0",
|
||||
"@typescript-eslint/parser": "^5.27.0",
|
||||
"eslint": "^8.16.0",
|
||||
"eslint-config-prettier": "^8.3.0",
|
||||
"eslint-plugin-svelte3": "^4.0.0",
|
||||
"mdsvex": "^0.10.6",
|
||||
"prettier": "^2.6.2",
|
||||
"prettier-plugin-svelte": "^2.7.0",
|
||||
"prism-svelte": "^0.5.0",
|
||||
"svelte": "^3.44.0",
|
||||
"svelte-check": "^2.7.1",
|
||||
"svelte-preprocess": "^4.10.6",
|
||||
"tslib": "^2.3.1",
|
||||
"typescript": "^4.7.4",
|
||||
"vite": "^4.0.0"
|
||||
},
|
||||
"type": "module",
|
||||
"exports": {
|
||||
"./package.json": "./package.json",
|
||||
"./core/Context": "./core/Context.js",
|
||||
"./core/Handlers/Filters": "./core/Handlers/Filters.js",
|
||||
"./core/Handlers/GlobalSearch": "./core/Handlers/GlobalSearch.js",
|
||||
"./core/Handlers/Pages": "./core/Handlers/Pages.js",
|
||||
"./core/Handlers/Rows": "./core/Handlers/Rows.js",
|
||||
"./core": "./core/index.js",
|
||||
"./DataHandler": "./DataHandler.js",
|
||||
"./Datatable.svelte": "./Datatable.svelte",
|
||||
".": "./index.js",
|
||||
"./Pagination.svelte": "./Pagination.svelte",
|
||||
"./RowCount.svelte": "./RowCount.svelte",
|
||||
"./RowsPerPage.svelte": "./RowsPerPage.svelte",
|
||||
"./Search.svelte": "./Search.svelte",
|
||||
"./Th.svelte": "./Th.svelte",
|
||||
"./ThFilter.svelte": "./ThFilter.svelte"
|
||||
},
|
||||
"svelte": "./index.js"
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={C:{"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0.00496,"39":0,"40":0,"41":0.00496,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0.00496,"51":0,"52":0.01984,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0.00992,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0.00992,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0.05455,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0.00496,"89":0.00496,"90":0,"91":0.09422,"92":0,"93":0.00496,"94":0,"95":0,"96":0,"97":0.00496,"98":0.00496,"99":0.00496,"100":0.00496,"101":0,"102":0.7141,"103":0.01984,"104":0.0248,"105":0.00992,"106":0.0248,"107":0.12893,"108":1.78524,"109":1.00668,"110":0.00496,"111":0,"3.5":0,"3.6":0},D:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0.01488,"50":0,"51":0,"52":0,"53":0.01488,"54":0,"55":0,"56":0.00496,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0.00496,"70":0.00496,"71":0,"72":0.14381,"73":0,"74":0.00992,"75":0.00496,"76":0,"77":0.01984,"78":0.0248,"79":0.05455,"80":0.00496,"81":0.00496,"83":0.03967,"84":0,"85":0.20332,"86":0.02975,"87":0.01488,"88":0,"89":0,"90":0.0248,"91":0.01488,"92":0.01488,"93":0.00496,"94":0.00496,"95":0.00992,"96":0.01488,"97":0.03471,"98":0.03967,"99":0.00992,"100":0.1091,"101":0.0248,"102":0.03967,"103":0.0843,"104":0.05951,"105":0.08926,"106":0.08926,"107":0.38184,"108":4.58212,"109":4.61187,"110":0,"111":0.00496,"112":0},F:{"9":0,"11":0,"12":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0.00496,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"60":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0.00496,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0.00496,"93":0.37688,"94":0.42152,"9.5-9.6":0,"10.0-10.1":0,"10.5":0,"10.6":0,"11.1":0,"11.5":0,"11.6":0,"12.1":0},B:{"12":0,"13":0,"14":0,"15":0,"16":0.00496,"17":0,"18":0.00992,"79":0,"80":0,"81":0,"83":0,"84":0,"85":0.01488,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0.00496,"93":0,"94":0,"95":0,"96":0.01984,"97":0,"98":0,"99":0,"100":0,"101":0.00496,"102":0.00496,"103":0.00496,"104":0.00496,"105":0.00496,"106":0.0843,"107":0.04959,"108":1.60672,"109":1.50754},E:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0.00992,"14":0.07934,"15":0.0248,_:"0","3.1":0,"3.2":0,"5.1":0,"6.1":0,"7.1":0,"9.1":0.00496,"10.1":0,"11.1":0.00496,"12.1":0.0843,"13.1":0.23803,"14.1":0.33721,"15.1":0.03471,"15.2-15.3":0.04463,"15.4":0.13885,"15.5":0.40664,"15.6":1.15545,"16.0":0.18844,"16.1":0.68434,"16.2":1.21496,"16.3":0.09918},G:{"8":0.00358,"3.2":0,"4.0-4.1":0,"4.2-4.3":0.19695,"5.0-5.1":0,"6.0-6.1":0,"7.0-7.1":0,"8.1-8.4":0,"9.0-9.2":0.62666,"9.3":0.02865,"10.0-10.2":0,"10.3":0.08952,"11.0-11.2":0.01432,"11.3-11.4":0.00358,"12.0-12.1":0.00716,"12.2-12.5":0.33302,"13.0-13.1":0.00358,"13.2":0.02149,"13.3":0.02507,"13.4-13.7":0.18263,"14.0-14.4":0.27215,"14.5-14.8":0.75199,"15.0-15.1":0.2435,"15.2-15.3":0.27215,"15.4":0.4691,"15.5":0.9561,"15.6":3.91752,"16.0":5.40001,"16.1":12.04618,"16.2":7.74193,"16.3":0.65889},P:{"4":0.2164,"5.0-5.4":0,"6.2-6.4":0,"7.2-7.4":0,"8.2":0,"9.2":0,"10.1":0,"11.1-11.2":0.0103,"12.0":0,"13.0":0.0103,"14.0":0.02061,"15.0":0.0103,"16.0":0.05152,"17.0":0.03091,"18.0":0.11335,"19.0":3.72008},I:{"0":0,"3":0.05572,"4":0.00526,"2.1":0.02733,"2.2":0.08095,"2.3":0,"4.1":0.05677,"4.2-4.3":0.05677,"4.4":0,"4.4.3-4.4.4":0.20184},K:{_:"0 10 11 12 11.1 11.5 12.1"},A:{"6":0,"7":0,"8":0,"9":0,"10":0,"11":0.12893,"5.5":0},J:{"7":0,"10":0},N:{"10":0,"11":0},R:{_:"0"},M:{"0":0.91242},Q:{"13.1":1.30058},O:{"0":0.96787},H:{"0":0.33885},L:{"0":29.31372},S:{"2.5":0}};
|
||||
@@ -0,0 +1 @@
|
||||
export * from 'rxjs-compat/operator/zip';
|
||||
@@ -0,0 +1,101 @@
|
||||
# p-limit
|
||||
|
||||
> Run multiple promise-returning & async functions with limited concurrency
|
||||
|
||||
## Install
|
||||
|
||||
```
|
||||
$ npm install p-limit
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
const pLimit = require('p-limit');
|
||||
|
||||
const limit = pLimit(1);
|
||||
|
||||
const input = [
|
||||
limit(() => fetchSomething('foo')),
|
||||
limit(() => fetchSomething('bar')),
|
||||
limit(() => doSomething())
|
||||
];
|
||||
|
||||
(async () => {
|
||||
// Only one promise is run at once
|
||||
const result = await Promise.all(input);
|
||||
console.log(result);
|
||||
})();
|
||||
```
|
||||
|
||||
## API
|
||||
|
||||
### pLimit(concurrency)
|
||||
|
||||
Returns a `limit` function.
|
||||
|
||||
#### concurrency
|
||||
|
||||
Type: `number`\
|
||||
Minimum: `1`\
|
||||
Default: `Infinity`
|
||||
|
||||
Concurrency limit.
|
||||
|
||||
### limit(fn, ...args)
|
||||
|
||||
Returns the promise returned by calling `fn(...args)`.
|
||||
|
||||
#### fn
|
||||
|
||||
Type: `Function`
|
||||
|
||||
Promise-returning/async function.
|
||||
|
||||
#### args
|
||||
|
||||
Any arguments to pass through to `fn`.
|
||||
|
||||
Support for passing arguments on to the `fn` is provided in order to be able to avoid creating unnecessary closures. You probably don't need this optimization unless you're pushing a *lot* of functions.
|
||||
|
||||
### limit.activeCount
|
||||
|
||||
The number of promises that are currently running.
|
||||
|
||||
### limit.pendingCount
|
||||
|
||||
The number of promises that are waiting to run (i.e. their internal `fn` was not called yet).
|
||||
|
||||
### limit.clearQueue()
|
||||
|
||||
Discard pending promises that are waiting to run.
|
||||
|
||||
This might be useful if you want to teardown the queue at the end of your program's lifecycle or discard any function calls referencing an intermediary state of your app.
|
||||
|
||||
Note: This does not cancel promises that are already running.
|
||||
|
||||
## FAQ
|
||||
|
||||
### How is this different from the [`p-queue`](https://github.com/sindresorhus/p-queue) package?
|
||||
|
||||
This package is only about limiting the number of concurrent executions, while `p-queue` is a fully featured queue implementation with lots of different options, introspection, and ability to pause the queue.
|
||||
|
||||
## Related
|
||||
|
||||
- [p-queue](https://github.com/sindresorhus/p-queue) - Promise queue with concurrency control
|
||||
- [p-throttle](https://github.com/sindresorhus/p-throttle) - Throttle promise-returning & async functions
|
||||
- [p-debounce](https://github.com/sindresorhus/p-debounce) - Debounce promise-returning & async functions
|
||||
- [p-all](https://github.com/sindresorhus/p-all) - Run promise-returning & async functions concurrently with optional limited concurrency
|
||||
- [More…](https://github.com/sindresorhus/promise-fun)
|
||||
|
||||
---
|
||||
|
||||
<div align="center">
|
||||
<b>
|
||||
<a href="https://tidelift.com/subscription/pkg/npm-p-limit?utm_source=npm-p-limit&utm_medium=referral&utm_campaign=readme">Get professional support for this package with a Tidelift subscription</a>
|
||||
</b>
|
||||
<br>
|
||||
<sub>
|
||||
Tidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies.
|
||||
</sub>
|
||||
</div>
|
||||
@@ -0,0 +1,20 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
var SubscriptionLog_1 = require("./SubscriptionLog");
|
||||
var SubscriptionLoggable = (function () {
|
||||
function SubscriptionLoggable() {
|
||||
this.subscriptions = [];
|
||||
}
|
||||
SubscriptionLoggable.prototype.logSubscribedFrame = function () {
|
||||
this.subscriptions.push(new SubscriptionLog_1.SubscriptionLog(this.scheduler.now()));
|
||||
return this.subscriptions.length - 1;
|
||||
};
|
||||
SubscriptionLoggable.prototype.logUnsubscribedFrame = function (index) {
|
||||
var subscriptionLogs = this.subscriptions;
|
||||
var oldSubscriptionLog = subscriptionLogs[index];
|
||||
subscriptionLogs[index] = new SubscriptionLog_1.SubscriptionLog(oldSubscriptionLog.subscribedFrame, this.scheduler.now());
|
||||
};
|
||||
return SubscriptionLoggable;
|
||||
}());
|
||||
exports.SubscriptionLoggable = SubscriptionLoggable;
|
||||
//# sourceMappingURL=SubscriptionLoggable.js.map
|
||||
@@ -0,0 +1,60 @@
|
||||
'use strict';
|
||||
const {constants: BufferConstants} = require('buffer');
|
||||
const pump = require('pump');
|
||||
const bufferStream = require('./buffer-stream');
|
||||
|
||||
class MaxBufferError extends Error {
|
||||
constructor() {
|
||||
super('maxBuffer exceeded');
|
||||
this.name = 'MaxBufferError';
|
||||
}
|
||||
}
|
||||
|
||||
async function getStream(inputStream, options) {
|
||||
if (!inputStream) {
|
||||
return Promise.reject(new Error('Expected a stream'));
|
||||
}
|
||||
|
||||
options = {
|
||||
maxBuffer: Infinity,
|
||||
...options
|
||||
};
|
||||
|
||||
const {maxBuffer} = options;
|
||||
|
||||
let stream;
|
||||
await new Promise((resolve, reject) => {
|
||||
const rejectPromise = error => {
|
||||
// Don't retrieve an oversized buffer.
|
||||
if (error && stream.getBufferedLength() <= BufferConstants.MAX_LENGTH) {
|
||||
error.bufferedData = stream.getBufferedValue();
|
||||
}
|
||||
|
||||
reject(error);
|
||||
};
|
||||
|
||||
stream = pump(inputStream, bufferStream(options), error => {
|
||||
if (error) {
|
||||
rejectPromise(error);
|
||||
return;
|
||||
}
|
||||
|
||||
resolve();
|
||||
});
|
||||
|
||||
stream.on('data', () => {
|
||||
if (stream.getBufferedLength() > maxBuffer) {
|
||||
rejectPromise(new MaxBufferError());
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
return stream.getBufferedValue();
|
||||
}
|
||||
|
||||
module.exports = getStream;
|
||||
// TODO: Remove this for the next major release
|
||||
module.exports.default = getStream;
|
||||
module.exports.buffer = (stream, options) => getStream(stream, {...options, encoding: 'buffer'});
|
||||
module.exports.array = (stream, options) => getStream(stream, {...options, array: true});
|
||||
module.exports.MaxBufferError = MaxBufferError;
|
||||
@@ -0,0 +1,76 @@
|
||||
<h1>
|
||||
<img src="logo.jpg" width="1280" alt="escape-goat">
|
||||
</h1>
|
||||
|
||||
> Escape a string for use in HTML or the inverse
|
||||
|
||||
[](https://travis-ci.org/sindresorhus/escape-goat)
|
||||
|
||||
|
||||
## Install
|
||||
|
||||
```
|
||||
$ npm install escape-goat
|
||||
```
|
||||
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
const {htmlEscape, htmlUnescape, htmlEscapeTag, htmlUnescapeTag} = require('escape-goat');
|
||||
|
||||
htmlEscape('🦄 & 🐐');
|
||||
//=> '🦄 & 🐐'
|
||||
|
||||
htmlUnescape('🦄 & 🐐');
|
||||
//=> '🦄 & 🐐'
|
||||
|
||||
htmlEscape('Hello <em>World</em>');
|
||||
//=> 'Hello <em>World</em>'
|
||||
|
||||
const url = 'https://sindresorhus.com?x="🦄"';
|
||||
|
||||
htmlEscapeTag`<a href="${url}">Unicorn</a>`;
|
||||
//=> '<a href="https://sindresorhus.com?x="🦄"">Unicorn</a>'
|
||||
|
||||
const escapedUrl = 'https://sindresorhus.com?x="🦄"';
|
||||
|
||||
htmlUnescapeTag`URL from HTML: ${url}`;
|
||||
//=> 'URL from HTML: https://sindresorhus.com?x="🦄"'
|
||||
```
|
||||
|
||||
|
||||
## API
|
||||
|
||||
### htmlEscape(string)
|
||||
|
||||
Escapes the following characters in the given `string` argument: `&` `<` `>` `"` `'`
|
||||
|
||||
### htmlUnescape(htmlString)
|
||||
|
||||
Unescapes the following HTML entities in the given `htmlString` argument: `&` `<` `>` `"` `'`
|
||||
|
||||
### htmlEscapeTag
|
||||
|
||||
[Tagged template literal](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Template_literals#Tagged_template_literals) that escapes interpolated values.
|
||||
|
||||
### htmlUnescapeTag
|
||||
|
||||
[Tagged template literal](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Template_literals#Tagged_template_literals) that unescapes interpolated values.
|
||||
|
||||
|
||||
## Tip
|
||||
|
||||
Ensure you always quote your HTML attributes to prevent possible [XSS](https://en.wikipedia.org/wiki/Cross-site_scripting).
|
||||
|
||||
|
||||
## FAQ
|
||||
|
||||
### Why yet another HTML escaping package?
|
||||
|
||||
I couldn't find one I liked that was tiny, well-tested, and had both `.escape()` and `.unescape()`.
|
||||
|
||||
|
||||
## License
|
||||
|
||||
MIT © [Sindre Sorhus](https://sindresorhus.com)
|
||||
@@ -0,0 +1,97 @@
|
||||
let Fraction = require('fraction.js')
|
||||
|
||||
let Prefixer = require('./prefixer')
|
||||
let utils = require('./utils')
|
||||
|
||||
const REGEXP = /(min|max)-resolution\s*:\s*\d*\.?\d+(dppx|dpcm|dpi|x)/gi
|
||||
const SPLIT = /(min|max)-resolution(\s*:\s*)(\d*\.?\d+)(dppx|dpcm|dpi|x)/i
|
||||
|
||||
class Resolution extends Prefixer {
|
||||
/**
|
||||
* Return prefixed query name
|
||||
*/
|
||||
prefixName (prefix, name) {
|
||||
if (prefix === '-moz-') {
|
||||
return name + '--moz-device-pixel-ratio'
|
||||
} else {
|
||||
return prefix + name + '-device-pixel-ratio'
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Return prefixed query
|
||||
*/
|
||||
prefixQuery (prefix, name, colon, value, units) {
|
||||
value = new Fraction(value)
|
||||
|
||||
// 1dpcm = 2.54dpi
|
||||
// 1dppx = 96dpi
|
||||
if (units === 'dpi') {
|
||||
value = value.div(96)
|
||||
} else if (units === 'dpcm') {
|
||||
value = value.mul(2.54).div(96)
|
||||
}
|
||||
value = value.simplify()
|
||||
|
||||
if (prefix === '-o-') {
|
||||
value = value.n + '/' + value.d
|
||||
}
|
||||
return this.prefixName(prefix, name) + colon + value
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove prefixed queries
|
||||
*/
|
||||
clean (rule) {
|
||||
if (!this.bad) {
|
||||
this.bad = []
|
||||
for (let prefix of this.prefixes) {
|
||||
this.bad.push(this.prefixName(prefix, 'min'))
|
||||
this.bad.push(this.prefixName(prefix, 'max'))
|
||||
}
|
||||
}
|
||||
|
||||
rule.params = utils.editList(rule.params, queries => {
|
||||
return queries.filter(query => this.bad.every(i => !query.includes(i)))
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* Add prefixed queries
|
||||
*/
|
||||
process (rule) {
|
||||
let parent = this.parentPrefix(rule)
|
||||
let prefixes = parent ? [parent] : this.prefixes
|
||||
|
||||
rule.params = utils.editList(rule.params, (origin, prefixed) => {
|
||||
for (let query of origin) {
|
||||
if (
|
||||
!query.includes('min-resolution') &&
|
||||
!query.includes('max-resolution')
|
||||
) {
|
||||
prefixed.push(query)
|
||||
continue
|
||||
}
|
||||
|
||||
for (let prefix of prefixes) {
|
||||
let processed = query.replace(REGEXP, str => {
|
||||
let parts = str.match(SPLIT)
|
||||
return this.prefixQuery(
|
||||
prefix,
|
||||
parts[1],
|
||||
parts[2],
|
||||
parts[3],
|
||||
parts[4]
|
||||
)
|
||||
})
|
||||
prefixed.push(processed)
|
||||
}
|
||||
prefixed.push(query)
|
||||
}
|
||||
|
||||
return utils.uniq(prefixed)
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = Resolution
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"J E F G A B BC"},B:{"1":"K L H M N O P Q R S T U V W X Y Z a b c d f g h i j k l m n o p q r s D t","2":"C"},C:{"1":"3 4 5 6 7 8 9 AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB e lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d f g h i j k l m n o p q r s D t xB yB","2":"0 1 2 CC tB I u J E F G A B C K L H M N O v w x y z DC EC"},D:{"1":"HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB e lB mB nB oB pB P Q R S T U V W X Y Z a b c d f g h i j k l m n o p q r s D t xB yB FC","2":"0 1 2 3 4 5 6 7 8 9 I u J E F G A B C K L H M N O v w x y z AB BB CB DB EB FB GB"},E:{"1":"A B C K L H KC 0B qB rB 1B LC MC 2B 3B 4B 5B sB 6B 7B 8B NC","2":"I u J E F G GC zB HC IC JC"},F:{"1":"4 5 6 7 8 9 AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB bB cB dB eB fB gB hB iB jB kB e lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d","2":"0 1 2 3 G B C H M N O v w x y z OC PC QC RC qB 9B SC rB"},G:{"1":"ZC aC bC cC dC eC fC gC hC iC jC kC lC mC 2B 3B 4B 5B sB 6B 7B 8B","2":"F zB TC AC UC VC WC XC YC"},H:{"2":"nC"},I:{"1":"D","2":"tB I oC pC qC rC AC sC tC"},J:{"2":"E A"},K:{"1":"e","2":"A B C qB 9B rB"},L:{"1":"D"},M:{"1":"D"},N:{"2":"A B"},O:{"1":"uC"},P:{"1":"I vC wC xC yC zC 0B 0C 1C 2C 3C 4C sB 5C 6C 7C"},Q:{"1":"1B"},R:{"1":"8C"},S:{"1":"9C"}},B:2,C:"CSS unset value"};
|
||||
@@ -0,0 +1,32 @@
|
||||
/**
|
||||
* Unicode special character support
|
||||
*
|
||||
* Detection is made by testing missing glyph box rendering against star character
|
||||
* If widths are the same, this "probably" means the browser didn't support the star character and rendered a glyph box instead
|
||||
* Just need to ensure the font characters have different widths
|
||||
*
|
||||
* Warning : positive Unicode support doesn't mean you can use it inside <title>, this seams more related to OS & Language packs
|
||||
*/
|
||||
Modernizr.addTest('unicode', function() {
|
||||
|
||||
|
||||
var bool,
|
||||
|
||||
missingGlyph = document.createElement('span'),
|
||||
|
||||
star = document.createElement('span');
|
||||
|
||||
Modernizr.testStyles('#modernizr{font-family:Arial,sans;font-size:300em;}', function(node) {
|
||||
|
||||
missingGlyph.innerHTML = 'ᝣ';
|
||||
star.innerHTML = '☆';
|
||||
|
||||
node.appendChild(missingGlyph);
|
||||
node.appendChild(star);
|
||||
|
||||
bool = 'offsetWidth' in missingGlyph && missingGlyph.offsetWidth !== star.offsetWidth;
|
||||
});
|
||||
|
||||
return bool;
|
||||
|
||||
});
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={C:{"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0.00308,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0.00308,"89":0,"90":0,"91":0.00616,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0.00308,"100":0,"101":0,"102":0.00308,"103":0.00308,"104":0,"105":0,"106":0.00308,"107":0.00308,"108":0.40937,"109":0.24008,"110":0.00308,"111":0,"3.5":0,"3.6":0},D:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0.00616,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0.00923,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0.00616,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0.00308,"62":0,"63":0,"64":0,"65":0.00308,"66":0,"67":0,"68":0,"69":0.03078,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0.01847,"77":0.00308,"78":0,"79":0.00616,"80":0,"81":0.01231,"83":0.00308,"84":0,"85":0,"86":0.01847,"87":0.00923,"88":0.00308,"89":0.00923,"90":0,"91":0,"92":0.00308,"93":0.00308,"94":0,"95":0.00923,"96":0.00923,"97":0.00308,"98":0.03694,"99":0,"100":0.01539,"101":0,"102":0.01539,"103":0.07695,"104":0.00616,"105":0.00616,"106":0.01231,"107":0.03694,"108":3.14264,"109":2.4901,"110":0,"111":0,"112":0},F:{"9":0,"11":0,"12":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0.00308,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0.00308,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"60":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0.00308,"92":0,"93":0.05233,"94":0.16313,"9.5-9.6":0,"10.0-10.1":0,"10.5":0,"10.6":0,"11.1":0,"11.5":0,"11.6":0,"12.1":0},B:{"12":0.00308,"13":0,"14":0,"15":0.00308,"16":0.00308,"17":0.00308,"18":0.00308,"79":0,"80":0,"81":0,"83":0,"84":0,"85":0,"86":0.00308,"87":0,"88":0.00308,"89":0,"90":0,"91":0,"92":0.00616,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"101":0,"102":0,"103":0,"104":0,"105":0,"106":0.00308,"107":0.01847,"108":0.65561,"109":0.51403},E:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0.05233,"15":0,_:"0","3.1":0,"3.2":0,"5.1":0.00308,"6.1":0,"7.1":0,"9.1":0,"10.1":0,"11.1":0,"12.1":0,"13.1":0.00923,"14.1":0.07079,"15.1":0.00308,"15.2-15.3":0,"15.4":0.02462,"15.5":0.05233,"15.6":0.11081,"16.0":0.01539,"16.1":0.03078,"16.2":0.0985,"16.3":0.01231},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0,"5.0-5.1":0,"6.0-6.1":0,"7.0-7.1":0.02361,"8.1-8.4":0,"9.0-9.2":0,"9.3":0.01771,"10.0-10.2":0,"10.3":0.20663,"11.0-11.2":0,"11.3-11.4":0.0059,"12.0-12.1":0.00394,"12.2-12.5":0.74978,"13.0-13.1":0.0059,"13.2":0.00394,"13.3":0.34242,"13.4-13.7":0.08659,"14.0-14.4":0.18695,"14.5-14.8":1.79868,"15.0-15.1":0.15153,"15.2-15.3":0.10627,"15.4":0.24009,"15.5":0.41129,"15.6":1.81639,"16.0":2.30837,"16.1":4.27235,"16.2":3.49305,"16.3":0.24205},P:{"4":0.63901,"5.0-5.4":0,"6.2-6.4":0,"7.2-7.4":0.4638,"8.2":0,"9.2":0.12368,"10.1":0,"11.1-11.2":0.05153,"12.0":0.04123,"13.0":0.18552,"14.0":0.18552,"15.0":0.05153,"16.0":0.1546,"17.0":0.44318,"18.0":0.3092,"19.0":6.21489},I:{"0":0,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0.02932,"4.4":0,"4.4.3-4.4.4":0.26386},K:{_:"0 10 11 12 11.1 11.5 12.1"},A:{"6":0,"7":0,"8":0,"9":0,"10":0,"11":0.00923,"5.5":0},J:{"7":0,"10":0},N:{"10":0,"11":0},S:{"2.5":0},R:{_:"0"},M:{"0":0.24227},Q:{"13.1":0},O:{"0":0.6299},H:{"0":0.24903},L:{"0":61.50399}};
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"auditTime.js","sources":["../src/operator/auditTime.ts"],"names":[],"mappings":";;;;;AAAA,oDAA+C"}
|
||||
@@ -0,0 +1,74 @@
|
||||
{
|
||||
"name": "got",
|
||||
"version": "9.6.0",
|
||||
"description": "Simplified HTTP requests",
|
||||
"license": "MIT",
|
||||
"repository": "sindresorhus/got",
|
||||
"main": "source",
|
||||
"engines": {
|
||||
"node": ">=8.6"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "xo && nyc ava",
|
||||
"release": "np"
|
||||
},
|
||||
"files": [
|
||||
"source"
|
||||
],
|
||||
"keywords": [
|
||||
"http",
|
||||
"https",
|
||||
"get",
|
||||
"got",
|
||||
"url",
|
||||
"uri",
|
||||
"request",
|
||||
"util",
|
||||
"utility",
|
||||
"simple",
|
||||
"curl",
|
||||
"wget",
|
||||
"fetch",
|
||||
"net",
|
||||
"network",
|
||||
"electron"
|
||||
],
|
||||
"dependencies": {
|
||||
"@sindresorhus/is": "^0.14.0",
|
||||
"@szmarczak/http-timer": "^1.1.2",
|
||||
"cacheable-request": "^6.0.0",
|
||||
"decompress-response": "^3.3.0",
|
||||
"duplexer3": "^0.1.4",
|
||||
"get-stream": "^4.1.0",
|
||||
"lowercase-keys": "^1.0.1",
|
||||
"mimic-response": "^1.0.1",
|
||||
"p-cancelable": "^1.0.0",
|
||||
"to-readable-stream": "^1.0.0",
|
||||
"url-parse-lax": "^3.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"ava": "^1.1.0",
|
||||
"coveralls": "^3.0.0",
|
||||
"delay": "^4.1.0",
|
||||
"form-data": "^2.3.3",
|
||||
"get-port": "^4.0.0",
|
||||
"np": "^3.1.0",
|
||||
"nyc": "^13.1.0",
|
||||
"p-event": "^2.1.0",
|
||||
"pem": "^1.13.2",
|
||||
"proxyquire": "^2.0.1",
|
||||
"sinon": "^7.2.2",
|
||||
"slow-stream": "0.0.4",
|
||||
"tempfile": "^2.0.0",
|
||||
"tempy": "^0.2.1",
|
||||
"tough-cookie": "^3.0.0",
|
||||
"xo": "^0.24.0"
|
||||
},
|
||||
"ava": {
|
||||
"concurrency": 4
|
||||
},
|
||||
"browser": {
|
||||
"decompress-response": false,
|
||||
"electron": false
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{"name":"figures","version":"3.2.0","files":{"license":{"checkedAt":1678887829613,"integrity":"sha512-0fM2/ycrxrltyaBKfQ748Ck23VlPUUBgNAR47ldf4B1V/HoXTfWBSk+vcshGKwEpmOynu4mOP5o+hyBfuRNa8g==","mode":420,"size":1117},"index.js":{"checkedAt":1678887830118,"integrity":"sha512-7d16So0YRcUfCkY8+aGpxWOl9fYxSIzLxLBkOGNJrOHU1qh5eKvAvhwQTbnNZtAffjcCXDF6HRjdN77PVn+HEA==","mode":420,"size":2931},"package.json":{"checkedAt":1678887830118,"integrity":"sha512-T3180nvqAaBS3pO4Xxrly5KpAn535A0PYVSopd+N9Jm14XxX3AiD4HwnWwM8aAZTuRIYprV1JZ+q/5/Ir12eIA==","mode":420,"size":807},"readme.md":{"checkedAt":1678887830118,"integrity":"sha512-KBb36d4rf78kq8IzbL6t4bF/jV/XPXHm+nEFHy2YFWJLdlXsQ8Zq3W3ZTERFj9GX9pAbQPRkSxrAWdLPBmY52w==","mode":420,"size":4740},"index.d.ts":{"checkedAt":1678887830118,"integrity":"sha512-t03h8bj42IlN+JdWbpbinPp9A6/jKmMsXKsjUAfuKepmxYI+EyY6sw7jt8G/YWpfZ7zgVpQLBykwDSmKgxi3ug==","mode":420,"size":2480}}}
|
||||
@@ -0,0 +1,95 @@
|
||||
import rng from './rng.js';
|
||||
import stringify from './stringify.js'; // **`v1()` - Generate time-based UUID**
|
||||
//
|
||||
// Inspired by https://github.com/LiosK/UUID.js
|
||||
// and http://docs.python.org/library/uuid.html
|
||||
|
||||
var _nodeId;
|
||||
|
||||
var _clockseq; // Previous uuid creation time
|
||||
|
||||
|
||||
var _lastMSecs = 0;
|
||||
var _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details
|
||||
|
||||
function v1(options, buf, offset) {
|
||||
var i = buf && offset || 0;
|
||||
var b = buf || new Array(16);
|
||||
options = options || {};
|
||||
var node = options.node || _nodeId;
|
||||
var clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not
|
||||
// specified. We do this lazily to minimize issues related to insufficient
|
||||
// system entropy. See #189
|
||||
|
||||
if (node == null || clockseq == null) {
|
||||
var seedBytes = options.random || (options.rng || rng)();
|
||||
|
||||
if (node == null) {
|
||||
// Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1)
|
||||
node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]];
|
||||
}
|
||||
|
||||
if (clockseq == null) {
|
||||
// Per 4.2.2, randomize (14 bit) clockseq
|
||||
clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff;
|
||||
}
|
||||
} // UUID timestamps are 100 nano-second units since the Gregorian epoch,
|
||||
// (1582-10-15 00:00). JSNumbers aren't precise enough for this, so
|
||||
// time is handled internally as 'msecs' (integer milliseconds) and 'nsecs'
|
||||
// (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00.
|
||||
|
||||
|
||||
var msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock
|
||||
// cycle to simulate higher resolution clock
|
||||
|
||||
var nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs)
|
||||
|
||||
var dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression
|
||||
|
||||
if (dt < 0 && options.clockseq === undefined) {
|
||||
clockseq = clockseq + 1 & 0x3fff;
|
||||
} // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new
|
||||
// time interval
|
||||
|
||||
|
||||
if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) {
|
||||
nsecs = 0;
|
||||
} // Per 4.2.1.2 Throw error if too many uuids are requested
|
||||
|
||||
|
||||
if (nsecs >= 10000) {
|
||||
throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");
|
||||
}
|
||||
|
||||
_lastMSecs = msecs;
|
||||
_lastNSecs = nsecs;
|
||||
_clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch
|
||||
|
||||
msecs += 12219292800000; // `time_low`
|
||||
|
||||
var tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000;
|
||||
b[i++] = tl >>> 24 & 0xff;
|
||||
b[i++] = tl >>> 16 & 0xff;
|
||||
b[i++] = tl >>> 8 & 0xff;
|
||||
b[i++] = tl & 0xff; // `time_mid`
|
||||
|
||||
var tmh = msecs / 0x100000000 * 10000 & 0xfffffff;
|
||||
b[i++] = tmh >>> 8 & 0xff;
|
||||
b[i++] = tmh & 0xff; // `time_high_and_version`
|
||||
|
||||
b[i++] = tmh >>> 24 & 0xf | 0x10; // include version
|
||||
|
||||
b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant)
|
||||
|
||||
b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low`
|
||||
|
||||
b[i++] = clockseq & 0xff; // `node`
|
||||
|
||||
for (var n = 0; n < 6; ++n) {
|
||||
b[i + n] = node[n];
|
||||
}
|
||||
|
||||
return buf || stringify(b);
|
||||
}
|
||||
|
||||
export default v1;
|
||||
@@ -0,0 +1,157 @@
|
||||
'use strict';
|
||||
const ansiEscapes = module.exports;
|
||||
// TODO: remove this in the next major version
|
||||
module.exports.default = ansiEscapes;
|
||||
|
||||
const ESC = '\u001B[';
|
||||
const OSC = '\u001B]';
|
||||
const BEL = '\u0007';
|
||||
const SEP = ';';
|
||||
const isTerminalApp = process.env.TERM_PROGRAM === 'Apple_Terminal';
|
||||
|
||||
ansiEscapes.cursorTo = (x, y) => {
|
||||
if (typeof x !== 'number') {
|
||||
throw new TypeError('The `x` argument is required');
|
||||
}
|
||||
|
||||
if (typeof y !== 'number') {
|
||||
return ESC + (x + 1) + 'G';
|
||||
}
|
||||
|
||||
return ESC + (y + 1) + ';' + (x + 1) + 'H';
|
||||
};
|
||||
|
||||
ansiEscapes.cursorMove = (x, y) => {
|
||||
if (typeof x !== 'number') {
|
||||
throw new TypeError('The `x` argument is required');
|
||||
}
|
||||
|
||||
let ret = '';
|
||||
|
||||
if (x < 0) {
|
||||
ret += ESC + (-x) + 'D';
|
||||
} else if (x > 0) {
|
||||
ret += ESC + x + 'C';
|
||||
}
|
||||
|
||||
if (y < 0) {
|
||||
ret += ESC + (-y) + 'A';
|
||||
} else if (y > 0) {
|
||||
ret += ESC + y + 'B';
|
||||
}
|
||||
|
||||
return ret;
|
||||
};
|
||||
|
||||
ansiEscapes.cursorUp = (count = 1) => ESC + count + 'A';
|
||||
ansiEscapes.cursorDown = (count = 1) => ESC + count + 'B';
|
||||
ansiEscapes.cursorForward = (count = 1) => ESC + count + 'C';
|
||||
ansiEscapes.cursorBackward = (count = 1) => ESC + count + 'D';
|
||||
|
||||
ansiEscapes.cursorLeft = ESC + 'G';
|
||||
ansiEscapes.cursorSavePosition = isTerminalApp ? '\u001B7' : ESC + 's';
|
||||
ansiEscapes.cursorRestorePosition = isTerminalApp ? '\u001B8' : ESC + 'u';
|
||||
ansiEscapes.cursorGetPosition = ESC + '6n';
|
||||
ansiEscapes.cursorNextLine = ESC + 'E';
|
||||
ansiEscapes.cursorPrevLine = ESC + 'F';
|
||||
ansiEscapes.cursorHide = ESC + '?25l';
|
||||
ansiEscapes.cursorShow = ESC + '?25h';
|
||||
|
||||
ansiEscapes.eraseLines = count => {
|
||||
let clear = '';
|
||||
|
||||
for (let i = 0; i < count; i++) {
|
||||
clear += ansiEscapes.eraseLine + (i < count - 1 ? ansiEscapes.cursorUp() : '');
|
||||
}
|
||||
|
||||
if (count) {
|
||||
clear += ansiEscapes.cursorLeft;
|
||||
}
|
||||
|
||||
return clear;
|
||||
};
|
||||
|
||||
ansiEscapes.eraseEndLine = ESC + 'K';
|
||||
ansiEscapes.eraseStartLine = ESC + '1K';
|
||||
ansiEscapes.eraseLine = ESC + '2K';
|
||||
ansiEscapes.eraseDown = ESC + 'J';
|
||||
ansiEscapes.eraseUp = ESC + '1J';
|
||||
ansiEscapes.eraseScreen = ESC + '2J';
|
||||
ansiEscapes.scrollUp = ESC + 'S';
|
||||
ansiEscapes.scrollDown = ESC + 'T';
|
||||
|
||||
ansiEscapes.clearScreen = '\u001Bc';
|
||||
|
||||
ansiEscapes.clearTerminal = process.platform === 'win32' ?
|
||||
`${ansiEscapes.eraseScreen}${ESC}0f` :
|
||||
// 1. Erases the screen (Only done in case `2` is not supported)
|
||||
// 2. Erases the whole screen including scrollback buffer
|
||||
// 3. Moves cursor to the top-left position
|
||||
// More info: https://www.real-world-systems.com/docs/ANSIcode.html
|
||||
`${ansiEscapes.eraseScreen}${ESC}3J${ESC}H`;
|
||||
|
||||
ansiEscapes.beep = BEL;
|
||||
|
||||
ansiEscapes.link = (text, url) => {
|
||||
return [
|
||||
OSC,
|
||||
'8',
|
||||
SEP,
|
||||
SEP,
|
||||
url,
|
||||
BEL,
|
||||
text,
|
||||
OSC,
|
||||
'8',
|
||||
SEP,
|
||||
SEP,
|
||||
BEL
|
||||
].join('');
|
||||
};
|
||||
|
||||
ansiEscapes.image = (buffer, options = {}) => {
|
||||
let ret = `${OSC}1337;File=inline=1`;
|
||||
|
||||
if (options.width) {
|
||||
ret += `;width=${options.width}`;
|
||||
}
|
||||
|
||||
if (options.height) {
|
||||
ret += `;height=${options.height}`;
|
||||
}
|
||||
|
||||
if (options.preserveAspectRatio === false) {
|
||||
ret += ';preserveAspectRatio=0';
|
||||
}
|
||||
|
||||
return ret + ':' + buffer.toString('base64') + BEL;
|
||||
};
|
||||
|
||||
ansiEscapes.iTerm = {
|
||||
setCwd: (cwd = process.cwd()) => `${OSC}50;CurrentDir=${cwd}${BEL}`,
|
||||
|
||||
annotation: (message, options = {}) => {
|
||||
let ret = `${OSC}1337;`;
|
||||
|
||||
const hasX = typeof options.x !== 'undefined';
|
||||
const hasY = typeof options.y !== 'undefined';
|
||||
if ((hasX || hasY) && !(hasX && hasY && typeof options.length !== 'undefined')) {
|
||||
throw new Error('`x`, `y` and `length` must be defined when `x` or `y` is defined');
|
||||
}
|
||||
|
||||
message = message.replace(/\|/g, '');
|
||||
|
||||
ret += options.isHidden ? 'AddHiddenAnnotation=' : 'AddAnnotation=';
|
||||
|
||||
if (options.length > 0) {
|
||||
ret +=
|
||||
(hasX ?
|
||||
[message, options.length, options.x, options.y] :
|
||||
[options.length, message]).join('|');
|
||||
} else {
|
||||
ret += message;
|
||||
}
|
||||
|
||||
return ret + BEL;
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,11 @@
|
||||
// last-child pseudo selector
|
||||
// https://github.com/Modernizr/Modernizr/pull/304
|
||||
|
||||
|
||||
Modernizr.addTest('lastchild', function(){
|
||||
|
||||
return Modernizr.testStyles("#modernizr div {width:100px} #modernizr :last-child{width:200px;display:block}", function (elem) {
|
||||
return elem.lastChild.offsetWidth > elem.firstChild.offsetWidth;
|
||||
}, 2);
|
||||
|
||||
});
|
||||
@@ -0,0 +1,78 @@
|
||||
import { Operator } from '../Operator';
|
||||
import { Observable } from '../Observable';
|
||||
import { Subscriber } from '../Subscriber';
|
||||
import { Notification } from '../Notification';
|
||||
import { OperatorFunction } from '../types';
|
||||
|
||||
/**
|
||||
* Converts an Observable of {@link Notification} objects into the emissions
|
||||
* that they represent.
|
||||
*
|
||||
* <span class="informal">Unwraps {@link Notification} objects as actual `next`,
|
||||
* `error` and `complete` emissions. The opposite of {@link materialize}.</span>
|
||||
*
|
||||
* 
|
||||
*
|
||||
* `dematerialize` is assumed to operate an Observable that only emits
|
||||
* {@link Notification} objects as `next` emissions, and does not emit any
|
||||
* `error`. Such Observable is the output of a `materialize` operation. Those
|
||||
* notifications are then unwrapped using the metadata they contain, and emitted
|
||||
* as `next`, `error`, and `complete` on the output Observable.
|
||||
*
|
||||
* Use this operator in conjunction with {@link materialize}.
|
||||
*
|
||||
* ## Example
|
||||
* Convert an Observable of Notifications to an actual Observable
|
||||
* ```ts
|
||||
* import { of, Notification } from 'rxjs';
|
||||
* import { dematerialize } from 'rxjs/operators';
|
||||
*
|
||||
* const notifA = new Notification('N', 'A');
|
||||
* const notifB = new Notification('N', 'B');
|
||||
* const notifE = new Notification('E', undefined,
|
||||
* new TypeError('x.toUpperCase is not a function')
|
||||
* );
|
||||
* const materialized = of(notifA, notifB, notifE);
|
||||
* const upperCase = materialized.pipe(dematerialize());
|
||||
* upperCase.subscribe(x => console.log(x), e => console.error(e));
|
||||
*
|
||||
* // Results in:
|
||||
* // A
|
||||
* // B
|
||||
* // TypeError: x.toUpperCase is not a function
|
||||
* ```
|
||||
*
|
||||
* @see {@link Notification}
|
||||
* @see {@link materialize}
|
||||
*
|
||||
* @return {Observable} An Observable that emits items and notifications
|
||||
* embedded in Notification objects emitted by the source Observable.
|
||||
* @method dematerialize
|
||||
* @owner Observable
|
||||
*/
|
||||
export function dematerialize<T>(): OperatorFunction<Notification<T>, T> {
|
||||
return function dematerializeOperatorFunction(source: Observable<Notification<T>>) {
|
||||
return source.lift(new DeMaterializeOperator());
|
||||
};
|
||||
}
|
||||
|
||||
class DeMaterializeOperator<T extends Notification<any>, R> implements Operator<T, R> {
|
||||
call(subscriber: Subscriber<any>, source: any): any {
|
||||
return source.subscribe(new DeMaterializeSubscriber(subscriber));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* We need this JSDoc comment for affecting ESDoc.
|
||||
* @ignore
|
||||
* @extends {Ignored}
|
||||
*/
|
||||
class DeMaterializeSubscriber<T extends Notification<any>> extends Subscriber<T> {
|
||||
constructor(destination: Subscriber<any>) {
|
||||
super(destination);
|
||||
}
|
||||
|
||||
protected _next(value: T) {
|
||||
value.observe(this.destination);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"every.js","sources":["../src/operators/every.ts"],"names":[],"mappings":";;;;;AAAA,iDAA4C"}
|
||||
@@ -0,0 +1,18 @@
|
||||
import Wrapper from './shared/Wrapper';
|
||||
import Renderer from '../Renderer';
|
||||
import Block from '../Block';
|
||||
import EachBlock from '../../nodes/EachBlock';
|
||||
import KeyBlock from '../../nodes/KeyBlock';
|
||||
import FragmentWrapper from './Fragment';
|
||||
import { Identifier } from 'estree';
|
||||
export default class KeyBlockWrapper extends Wrapper {
|
||||
node: KeyBlock;
|
||||
fragment: FragmentWrapper;
|
||||
block: Block;
|
||||
dependencies: string[];
|
||||
var: Identifier;
|
||||
constructor(renderer: Renderer, block: Block, parent: Wrapper, node: EachBlock, strip_whitespace: boolean, next_sibling: Wrapper);
|
||||
render(block: Block, parent_node: Identifier, parent_nodes: Identifier): void;
|
||||
render_static_key(_block: Block, parent_node: Identifier, parent_nodes: Identifier): void;
|
||||
render_dynamic_key(block: Block, parent_node: Identifier, parent_nodes: Identifier): void;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
/// <reference types="node" />
|
||||
import { EventEmitter } from 'events';
|
||||
declare type Origin = EventEmitter;
|
||||
declare type Event = string | symbol;
|
||||
declare type Fn = (...args: any[]) => void;
|
||||
interface Unhandler {
|
||||
once: (origin: Origin, event: Event, fn: Fn) => void;
|
||||
unhandleAll: () => void;
|
||||
}
|
||||
declare const _default: () => Unhandler;
|
||||
export default _default;
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"Subscriber.js","sources":["src/Subscriber.ts"],"names":[],"mappings":";;;;;AAAA,4CAAuC"}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"BehaviorSubject.js","sources":["../../src/internal/BehaviorSubject.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAIpC,OAAO,EAAE,uBAAuB,EAAE,MAAM,gCAAgC,CAAC;AAQzE,MAAM,OAAO,eAAmB,SAAQ,OAAU;IAEhD,YAAoB,MAAS;QAC3B,KAAK,EAAE,CAAC;QADU,WAAM,GAAN,MAAM,CAAG;IAE7B,CAAC;IAED,IAAI,KAAK;QACP,OAAO,IAAI,CAAC,QAAQ,EAAE,CAAC;IACzB,CAAC;IAGD,UAAU,CAAC,UAAyB;QAClC,MAAM,YAAY,GAAG,KAAK,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC;QAClD,IAAI,YAAY,IAAI,CAAoB,YAAa,CAAC,MAAM,EAAE;YAC5D,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;SAC9B;QACD,OAAO,YAAY,CAAC;IACtB,CAAC;IAED,QAAQ;QACN,IAAI,IAAI,CAAC,QAAQ,EAAE;YACjB,MAAM,IAAI,CAAC,WAAW,CAAC;SACxB;aAAM,IAAI,IAAI,CAAC,MAAM,EAAE;YACtB,MAAM,IAAI,uBAAuB,EAAE,CAAC;SACrC;aAAM;YACL,OAAO,IAAI,CAAC,MAAM,CAAC;SACpB;IACH,CAAC;IAED,IAAI,CAAC,KAAQ;QACX,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,CAAC;IAClC,CAAC;CACF"}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"debounceTime.js","sources":["../../src/add/operator/debounceTime.ts"],"names":[],"mappings":";;AAAA,iDAA+C"}
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={C:{"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0.00483,"41":0.00483,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0.00483,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0.00483,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0.00483,"85":0,"86":0,"87":0,"88":0.00966,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0.01932,"98":0,"99":0,"100":0,"101":0,"102":0.00483,"103":0.00483,"104":0.02897,"105":0.00483,"106":0.00966,"107":0.07244,"108":0.2656,"109":0.17867,"110":0,"111":0,"3.5":0,"3.6":0},D:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0.02415,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0.00483,"48":0,"49":0.01449,"50":0,"51":0,"52":0,"53":0.00966,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0.00483,"66":0.00483,"67":0,"68":0.01449,"69":0.00483,"70":0.00483,"71":0,"72":0,"73":0,"74":0.00483,"75":0,"76":0,"77":0.00483,"78":0.00483,"79":0.17384,"80":0.01932,"81":0.01932,"83":0.00966,"84":0.00483,"85":0.00966,"86":0.00483,"87":0.02897,"88":0.00966,"89":0.00483,"90":0.00483,"91":0.05312,"92":0.02897,"93":0.01932,"94":0.02897,"95":0.01932,"96":0.0338,"97":0.02897,"98":0.01449,"99":0.0338,"100":0.02897,"101":0.02897,"102":0.02897,"103":0.09175,"104":0.05795,"105":0.07244,"106":0.05312,"107":0.13521,"108":8.63908,"109":8.89985,"110":0.00483,"111":0.00483,"112":0},F:{"9":0,"11":0,"12":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0.00483,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0.00483,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"60":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0.00483,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0.00483,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0.00483,"93":0.8499,"94":0.60845,"9.5-9.6":0,"10.0-10.1":0,"10.5":0,"10.6":0,"11.1":0,"11.5":0,"11.6":0,"12.1":0},B:{"12":0.00483,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0.00483,"79":0,"80":0,"81":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0.00483,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0.00483,"101":0,"102":0,"103":0.00483,"104":0,"105":0.00483,"106":0.00483,"107":0.02415,"108":0.66157,"109":0.67123},E:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0.01932,"15":0.00483,_:"0","3.1":0,"3.2":0,"5.1":0,"6.1":0,"7.1":0,"9.1":0,"10.1":0,"11.1":0,"12.1":0,"13.1":0.00966,"14.1":0.02415,"15.1":0.00483,"15.2-15.3":0.00483,"15.4":0.00966,"15.5":0.02415,"15.6":0.07726,"16.0":0.01932,"16.1":0.06278,"16.2":0.07244,"16.3":0.00483},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0.00201,"5.0-5.1":0.0067,"6.0-6.1":0.00067,"7.0-7.1":0.00268,"8.1-8.4":0,"9.0-9.2":0.00201,"9.3":0.01875,"10.0-10.2":0,"10.3":0.01406,"11.0-11.2":0.00603,"11.3-11.4":0.00402,"12.0-12.1":0.00803,"12.2-12.5":0.18612,"13.0-13.1":0.00536,"13.2":0.00536,"13.3":0.01138,"13.4-13.7":0.02946,"14.0-14.4":0.08034,"14.5-14.8":0.24437,"15.0-15.1":0.06159,"15.2-15.3":0.09976,"15.4":0.15064,"15.5":0.2919,"15.6":0.83621,"16.0":0.94132,"16.1":1.84382,"16.2":1.31558,"16.3":0.11114},P:{"4":0.32158,"5.0-5.4":0.01005,"6.2-6.4":0,"7.2-7.4":0.09044,"8.2":0,"9.2":0.01005,"10.1":0,"11.1-11.2":0.0402,"12.0":0,"13.0":0.0402,"14.0":0.03015,"15.0":0.0201,"16.0":0.07035,"17.0":0.07035,"18.0":0.09044,"19.0":0.80394},I:{"0":0,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0.01017,"4.2-4.3":0.00508,"4.4":0,"4.4.3-4.4.4":0.1144},K:{_:"0 10 11 12 11.1 11.5 12.1"},A:{"6":0,"7":0,"8":0,"9":0,"10":0,"11":0.02897,"5.5":0},J:{"7":0,"10":0},N:{"10":0,"11":0},R:{_:"0"},M:{"0":0.10342},Q:{"13.1":0},O:{"0":0.02068},H:{"0":0.20072},L:{"0":67.87162},S:{"2.5":0}};
|
||||
@@ -0,0 +1,28 @@
|
||||
let Declaration = require('../declaration')
|
||||
|
||||
class UserSelect extends Declaration {
|
||||
/**
|
||||
* Change prefixed value for IE
|
||||
*/
|
||||
set (decl, prefix) {
|
||||
if (prefix === '-ms-' && decl.value === 'contain') {
|
||||
decl.value = 'element'
|
||||
}
|
||||
return super.set(decl, prefix)
|
||||
}
|
||||
|
||||
/**
|
||||
* Avoid prefixing all in IE
|
||||
*/
|
||||
insert (decl, prefix, prefixes) {
|
||||
if (decl.value === 'all' && prefix === '-ms-') {
|
||||
return undefined
|
||||
} else {
|
||||
return super.insert(decl, prefix, prefixes)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
UserSelect.names = ['user-select']
|
||||
|
||||
module.exports = UserSelect
|
||||
Reference in New Issue
Block a user