Add capacitorjs runtime

This commit is contained in:
olcxja 2026-05-03 17:09:55 +02:00
commit f90c0e6c40
8362 changed files with 1502407 additions and 1 deletions

25
node_modules/add-stream/.jshintrc generated vendored Normal file
View file

@ -0,0 +1,25 @@
{
"node": true,
"bitwise": false,
"camelcase": true,
"eqeqeq": true,
"forin": true,
"freeze": true,
"immed": true,
"indent": 4,
"latedef": "nofunc",
"newcap": true,
"noarg": true,
"quotmark": "single",
"undef": true,
"unused": true,
"strict": true,
"trailing": true,
"smarttabs": true,
"globals": {
"describe": false,
"it": false,
"beforeEach": false,
"afterEach": false
}
}

7
node_modules/add-stream/.npmignore generated vendored Normal file
View file

@ -0,0 +1,7 @@
/.idea
/atlassian-ide-plugin.xml
*.iml
.DS_Store
/node_modules
/coverage

4
node_modules/add-stream/.travis.yml generated vendored Normal file
View file

@ -0,0 +1,4 @@
language: node_js
node_js:
- "0.11"
- "0.10"

38
node_modules/add-stream/README.md generated vendored Normal file
View file

@ -0,0 +1,38 @@
# add-stream [![Build Status](https://travis-ci.org/wilsonjackson/add-stream.svg?branch=master)](https://travis-ci.org/wilsonjackson/add-stream)
> Append the contents of one stream onto another.
## Usage
```js
var fs = require('fs');
var es = require('event-stream');
var addStream = require('add-stream');
// Append strings/buffers
fs.createReadStream('1.txt') // 1.txt contains: number1
.pipe(addStream(fs.createReadStream('2.txt'))) // 2.txt contains: number2
.pipe(fs.createWriteStream('appended.txt')); // appended.txt contains: number1number2
// Append object streams
es.readArray([1, 2, 3])
.pipe(addStream.obj(es.readArray([4, 5, 6])))
.pipe(es.writeArray(function (err, array) {
console.log(array); // [ 1, 2, 3, 4, 5, 6 ]
}));
```
## API
### var transformStream = addStream(stream, opts = {})
Create a transform stream that appends the contents of `stream` onto whatever
is piped into it. Options are passed to the transform stream's constructor.
### var transformStream = addStream.obj(stream, opts = {})
A convenient shortcut for `addStream(stream, {objectMode: true})`.
## License
MIT

56
node_modules/add-stream/index.js generated vendored Normal file
View file

@ -0,0 +1,56 @@
'use strict';
var PassThrough = require('stream').PassThrough;
var Writable = require('stream').Writable;
var util = require('util');
util.inherits(Appendee, PassThrough);
util.inherits(Appender, Writable);
function Appendee(factory, opts) {
PassThrough.call(this, opts);
this.factory = factory;
this.opts = opts;
}
//noinspection JSUnusedGlobalSymbols
Appendee.prototype._flush = function (end) {
var stream = this.factory();
stream.pipe(new Appender(this, this.opts))
.on('finish', end);
stream.resume();
};
function Appender(target, opts) {
Writable.call(this, opts);
this.target = target;
}
//noinspection JSUnusedGlobalSymbols
Appender.prototype._write = function (chunk, enc, cb) {
this.target.push(chunk);
cb();
};
function addStream(stream, opts) {
opts = opts || {};
var factory;
if (typeof stream === 'function') {
factory = stream;
}
else {
stream.pause();
factory = function () {
return stream;
};
}
return new Appendee(factory, opts);
}
addStream.obj = function (stream, opts) {
opts = opts || {};
opts.objectMode = true;
return addStream(stream, opts);
};
module.exports = addStream;

34
node_modules/add-stream/package.json generated vendored Normal file
View file

@ -0,0 +1,34 @@
{
"name": "add-stream",
"version": "1.0.0",
"description": "Append the contents of one stream onto another.",
"main": "index.js",
"scripts": {
"test": "mocha",
"cover": "istanbul cover node_modules/.bin/_mocha -- -u exports -R spec"
},
"repository": {
"type": "git",
"url": "https://github.com/wilsonjackson/add-stream"
},
"keywords": [
"stream",
"append",
"add",
"concat",
"gulpfriendly"
],
"author": "Majid Burney <moocow@euphoricsoup.com>",
"license": "MIT",
"bugs": {
"url": "https://github.com/wilsonjackson/add-stream/issues"
},
"homepage": "https://github.com/wilsonjackson/add-stream",
"dependencies": {},
"devDependencies": {
"chai": "^1.10.0",
"event-stream": "^3.1.7",
"istanbul": "^0.3.4",
"mocha": "^2.0.1"
}
}

64
node_modules/add-stream/test/spec.js generated vendored Normal file
View file

@ -0,0 +1,64 @@
'use strict';
var chai = require('chai');
var expect = chai.expect;
var es = require('event-stream');
var addStream = require('../');
describe('add-stream', function () {
function emit(chunks) {
var mutableChunks = [].concat(chunks);
return es.readable(function (count, callback) {
if (mutableChunks.length === 0) {
return this.emit('end');
}
callback(null, mutableChunks.shift());
});
}
describe('buffer mode', function () {
it('should append a stream', function (done) {
var firstChunks = ['abc', 'def'];
var secondChunks = ['ghi', 'jkl'];
emit(firstChunks)
.pipe(addStream(emit(secondChunks)))
.pipe(es.wait(function (err, buffer) {
expect(buffer.toString()).to.equal(firstChunks.concat(secondChunks).join(''));
done();
}));
});
it('should append a stream from a factory function', function (done) {
var firstChunks = ['abc', 'def'];
var secondChunks = ['ghi', 'jkl'];
emit(firstChunks)
.pipe(addStream(function () {
return emit(secondChunks);
}))
.pipe(es.wait(function (err, buffer) {
expect(buffer.toString()).to.equal(firstChunks.concat(secondChunks).join(''));
done();
}));
});
});
describe('object mode', function () {
it('should append a stream', function (done) {
es.readArray([{p: 1}, {p: 2}, {p: 3}])
.pipe(addStream.obj(es.readArray([{p: 4}, {p: 5}, {p: 6}])))
.pipe(es.writeArray(function (err, array) {
expect(array).to.eql([{p: 1}, {p: 2}, {p: 3}, {p: 4}, {p: 5}, {p: 6}]);
done();
}));
});
it('should append a stream from a factory function', function (done) {
es.readArray([{p: 1}, {p: 2}, {p: 3}])
.pipe(addStream.obj(function () {return es.readArray([{p: 4}, {p: 5}, {p: 6}])}))
.pipe(es.writeArray(function (err, array) {
expect(array).to.eql([{p: 1}, {p: 2}, {p: 3}, {p: 4}, {p: 5}, {p: 6}]);
done();
}));
});
});
});