diff --git a/.eslintrc.json b/.eslintrc.json index ef1dd9eb9..bb93609a9 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -3,8 +3,7 @@ "browser": true, "commonjs": true, "es6": true, - "node": true, - "jquery": true + "node": true }, "parserOptions": { "ecmaVersion": 2018 diff --git a/.gitignore b/.gitignore index e722b8393..8ff786bba 100644 --- a/.gitignore +++ b/.gitignore @@ -52,6 +52,7 @@ builds build cache /app/data/docs +tempChangelog.md # tests error_screenshots/ diff --git a/app/Changelog.md b/app/Changelog.md index ff6f2779c..9299186b0 100644 --- a/app/Changelog.md +++ b/app/Changelog.md @@ -1,3 +1,63 @@ +## v 1.1.0 + +*15 October 2019* + +### ✨ New Features + +* Add a debug mode to ct.place (you can find it in the settings tab) +* texture-editor: Add the Symmetry tool for polygonal shapes (by @schadocalex) +* Add Iosevka as a default typeface for code, allow setting your own typeface, control line height and ligatures +* Open the `includes` folder from the hamburger menu +* Support for nested copies (#127) by @schadocalex +* Support for Yarn (a tool for making dialogues and interactive fiction), powered by bondage.js +* texture-editor: Directly add/remove shape points on texture with your mouse. Add a point by clicking on the yellow line segments, delete points by clicking on them (by @schadocalex) + +### ⚡️ General Improvements + +* Add Pt-Br translation of UI by Folha de SP from Discord +* Better checkboxes, radio inputs, and other fields +* Better styling of inline code fragments in the modules panel +* Better texture-editor layout +* Better, more readeable tables in module's docs +* Change Horizon colors a bit to make it more pleasant to look at +* Highlight code blocks at modules panel +* Improve texture packing +* Make module list and their details scroll independently +* Remove excess borders in nested views +* Remove excess borders on module panels +* Remove old language keys, add Comments.json, Debug.json +* Rename "Is tiled" property of textures to "Use as background", hide splitting tools if used as background +* texture-editor: Make the axis handle squared (by @schadocalex) +* texture-editor: Zooming in/out now works when scrolling outside the texture as well (by @schadocalex) +* Tiny UI improvements, here and there + +### 🐛 Bug Fixes + +* :pencil: Replace Lato's license with Open Sans', as we don't use Lato +* Color inputs should show white value on a dark background from the very start +* Fix broken style editor +* Fix numerous collision problems that appeared with rotated entities +* Fix the checkbox "close the shape", as it didn't change the actual state before +* Stop chromium from messing up with color profiles and colors in ct.js + +### 🍱 Demos and Stuff + +* Add a Yarn demo + +### 📝 Docs + +* Document the `alpha` property of copies +* :zap: Update Troubleshooting — teared backgrounds +* :bug: Update tut-making-shooter.md +* Pt-Br translation :tada: + +### 🌐 Website + +* :bug: Fix an outdated link to downloads in the header +* :sparkles: Add partial Russian translation +* :zap: Align social icons at the footer to the right + + ## v 1.0.2 *25 September 2019.* diff --git a/app/data/ct.libs/.eslintrc.json b/app/data/ct.libs/.eslintrc.json index d728f5e97..59a9c57b9 100644 --- a/app/data/ct.libs/.eslintrc.json +++ b/app/data/ct.libs/.eslintrc.json @@ -1,6 +1,7 @@ { "globals": { - "ct": false + "ct": false, + "PIXI": true }, "rules": { "object-shorthand": 0 diff --git a/app/data/ct.libs/place/index.js b/app/data/ct.libs/place/index.js index ebe835883..648203816 100644 --- a/app/data/ct.libs/place/index.js +++ b/app/data/ct.libs/place/index.js @@ -1,5 +1,5 @@ /* eslint-disable no-underscore-dangle */ -/* global ct SSCD */ +/* global SSCD */ /* eslint prefer-destructuring: 0 */ (function (ct) { const circlePrecision = 16, @@ -12,19 +12,19 @@ position.x -= copy.scale.x > 0? (shape.left * copy.scale.x) : (-copy.scale.x * shape.right); position.y -= copy.scale.y > 0? (shape.top * copy.scale.y) : (-shape.bottom * copy.scale.y); return new SSCD.Rectangle( - position, + position, new SSCD.Vector(Math.abs((shape.left + shape.right) * copy.scale.x), Math.abs((shape.bottom + shape.top) * copy.scale.y)) ); } const upperLeft = ct.u.rotate(-shape.left * copy.scale.x, -shape.top * copy.scale.y, copy.rotation), - upperRight = ct.u.rotate(shape.right * copy.scale.x, -shape.top * copy.scale.y, copy.rotation), bottomLeft = ct.u.rotate(-shape.left * copy.scale.x, shape.bottom * copy.scale.y, copy.rotation), - bottomRight = ct.u.rotate(shape.right * copy.scale.x, shape.bottom * copy.scale.y, copy.rotation); + bottomRight = ct.u.rotate(shape.right * copy.scale.x, shape.bottom * copy.scale.y, copy.rotation), + upperRight = ct.u.rotate(shape.right * copy.scale.x, -shape.top * copy.scale.y, copy.rotation); return new SSCD.LineStrip(position, [ new SSCD.Vector(upperLeft[0], upperLeft[1]), - new SSCD.Vector(upperRight[0], upperRight[1]), new SSCD.Vector(bottomLeft[0], bottomLeft[1]), - new SSCD.Vector(bottomRight[0], bottomRight[1]) + new SSCD.Vector(bottomRight[0], bottomRight[1]), + new SSCD.Vector(upperRight[0], upperRight[1]) ], true); } if (shape.type === 'circle') { @@ -57,7 +57,7 @@ vertices.push(new SSCD.Vector(point.x * copy.scale.x, point.y * copy.scale.y)); } } - return new SSCD.LineStrip(position, vertices, false); + return new SSCD.LineStrip(position, vertices, Boolean(shape.closedStrip)); } if (shape.type === 'line') { return new SSCD.Line( @@ -92,6 +92,37 @@ } return hashes; }, + /** + * Applied to copies in the debug mode. Draws a collision shape + * @this Copy + * @returns {void} + */ + drawDebugGraphic() { + const shape = this._shape || getSSCDShape(this); + const g = this.$cDebugCollision; + const color = this.$cHadCollision? 0x00ff00 : 0x0066ff; + if (shape instanceof SSCD.Rectangle) { + const pos = shape.get_position(), + size = shape.get_size(); + g.lineStyle(2, color) + .drawRect(pos.x - this.x, pos.y - this.y, size.x, size.y); + } else if (shape instanceof SSCD.LineStrip) { + g.lineStyle(2, color) + .moveTo(shape.__points[0].x, shape.__points[0].y); + for (let i = 1; i < shape.__points.length; i++) { + g.lineTo(shape.__points[i].x, shape.__points[i].y); + } + } else if (shape instanceof SSCD.Circle) { + g.lineStyle(2, color) + .drawCircle(0, 0, shape.get_radius()); + } else { + g.lineStyle(4, 0xff0000) + .moveTo(-40, -40) + .lineTo(40, 40,) + .moveTo(-40, 40) + .lineTo(40, -40); + } + }, collide(c1, c2) { // ct.place.collide() // Test collision between two copies @@ -105,12 +136,19 @@ return false; } } - return SSCD.CollisionManager.test_collision(c1._shape, c2._shape); + if (SSCD.CollisionManager.test_collision(c1._shape, c2._shape)) { + if ([/*%debugMode%*/][0]) { + c1.$cHadCollision = true; + c2.$cHadCollision = true; + } + return true; + } + return false; }, /** - * Determines if the place in (x,y) is occupied. + * Determines if the place in (x,y) is occupied. * Optionally can take 'ctype' as a filter for obstackles' collision group (not shape type) - * + * * @param {Copy} me The object to check collisions on * @param {Number} [x] The x coordinate to check, as if `me` was placed there. * @param {Number} [y] The y coordinate to check, as if `me` was placed there. @@ -120,7 +158,7 @@ * @returns {Copy|Array} The collided copy, or an array of all the detected collisions (if `multiple` is `true`) */ occupied(me, x, y, ctype, multiple) { - var oldx = me.x, + var oldx = me.x, oldy = me.y, shapeCashed = me._shape; let hashes; @@ -184,7 +222,7 @@ meet(me, x, y, type, multiple) { // ct.place.meet([, type: Type]) // detects collision between a given copy and a copy of a certain type - var oldx = me.x, + var oldx = me.x, oldy = me.y, shapeCashed = me._shape; let hashes; @@ -364,7 +402,7 @@ me.y += ct.u.ldy(length, dir); delete me._shape; me.dir = dir; - // otherwise, try to change direction by 30...60...90 degrees. + // otherwise, try to change direction by 30...60...90 degrees. // Direction changes over time (ct.place.m). } else { for (var i = -1; i <= 1; i+= 2) { @@ -382,14 +420,14 @@ }, /** * Throws a ray from point (x1, y1) to (x2, y2), returning all the instances that touched the ray. - * The first copy in the returned array is the closest copy, the last one is the furthest. - * + * The first copy in the returned array is the closest copy, the last one is the furthest. + * * @param {Number} x1 A horizontal coordinate of the starting point of the ray. * @param {Number} y1 A vertical coordinate of the starting point of the ray. * @param {Number} x2 A horizontal coordinate of the ending point of the ray. * @param {Number} y2 A vertical coordinate of the ending point of the ray. * @param {String} [ctype] An optional collision group to trace against. If omitted, will trace through all the copies in the current room. - * + * * @returns {Array} Array of all the copies that touched the ray */ trace(x1, y1, x2, y2, ctype) { diff --git a/app/data/ct.libs/place/injects/afterdraw.js b/app/data/ct.libs/place/injects/afterdraw.js index 95a180acf..55b5c3769 100644 --- a/app/data/ct.libs/place/injects/afterdraw.js +++ b/app/data/ct.libs/place/injects/afterdraw.js @@ -1,4 +1,5 @@ -if (this.x !== this.xprev || this.y !== this.yprev) { +/* eslint-disable no-underscore-dangle */ +if ((this.transform && (this.transform._localID !== this.transform._currentLocalID)) || this.x !== this.xprev || this.y !== this.yprev) { delete this._shape; const oldHashes = this.$chashes || []; this.$chashes = ct.place.getHashes(this); diff --git a/app/data/ct.libs/place/injects/beforedraw.js b/app/data/ct.libs/place/injects/beforedraw.js new file mode 100644 index 000000000..e43d1ab52 --- /dev/null +++ b/app/data/ct.libs/place/injects/beforedraw.js @@ -0,0 +1,16 @@ +if ([/*%debugMode%*/][0] && this instanceof ct.types.Copy) { + this.$cDebugText.scale.x = this.$cDebugCollision.scale.x = 1 / this.scale.x; + this.$cDebugText.scale.y = this.$cDebugCollision.scale.y = 1 / this.scale.y; + this.$cDebugText.rotation = this.$cDebugCollision.rotation = -ct.u.degToRad(this.rotation); + + const newtext = `Partitions: ${this.$chashes.join(', ')} +Group: ${this.ctype} +Shape: ${this._shape && this._shape.__type}`; + if (this.$cDebugText.text !== newtext) { + this.$cDebugText.text = newtext; + } + this.$cDebugCollision + .clear(); + ct.place.drawDebugGraphic.apply(this); + this.$cHadCollision = false; +} diff --git a/app/data/ct.libs/place/injects/oncreate.js b/app/data/ct.libs/place/injects/oncreate.js index 1aa5bbeec..9467dcd24 100644 --- a/app/data/ct.libs/place/injects/oncreate.js +++ b/app/data/ct.libs/place/injects/oncreate.js @@ -6,3 +6,13 @@ for (const hash of this.$chashes) { ct.place.grid[hash].push(this); } } +if ([/*%debugMode%*/][0] && this instanceof ct.types.Copy) { + this.$cDebugText = new PIXI.Text('Not initialized', { + fill: 0xffffff, + dropShadow: true, + dropShadowDistance: 2, + fontSize: [/*%debugText%*/][0] || 16 + }); + this.$cDebugCollision = new PIXI.Graphics(); + this.addChild(this.$cDebugCollision, this.$cDebugText); +} diff --git a/app/data/ct.libs/place/injects/start.js b/app/data/ct.libs/place/injects/start.js index c5edbf36e..9dbb4a71f 100644 --- a/app/data/ct.libs/place/injects/start.js +++ b/app/data/ct.libs/place/injects/start.js @@ -23,5 +23,5 @@ Object.defineProperty(ct.types.Copy.prototype, 'moveContinuous', { this.vspeed += this.gravity * ct.delta * Math.sin(this.gravityDir*Math.PI/-180); } return ct.place.moveAlong(this, this.direction, this.speed, ctype, precision); - } + } }); diff --git a/app/data/ct.libs/place/module.json b/app/data/ct.libs/place/module.json index d77e5ab58..6abb29741 100644 --- a/app/data/ct.libs/place/module.json +++ b/app/data/ct.libs/place/module.json @@ -21,6 +21,20 @@ "id": "gridY", "default": 512, "type": "number" + }, { + "name": "Debug mode", + "help": "Displays collision shapes, collision groups and partitions. It will also write additional keys to most colliding objects. Doesn't work on hidden objects.", + "key": "debugMode", + "id": "debugMode", + "default": false, + "type": "checkbox" + }, { + "name": "Debug text size", + "help": "", + "key": "debugText", + "id": "debugText", + "default": 16, + "type": "number" }], "typeExtends": [{ "name": "Collision group", diff --git a/app/data/ct.libs/yarn/DOCS.md b/app/data/ct.libs/yarn/DOCS.md new file mode 100644 index 000000000..32668e931 --- /dev/null +++ b/app/data/ct.libs/yarn/DOCS.md @@ -0,0 +1,160 @@ +## Loading a story + +### ct.yarn.openStory(data) ⇒ `YarnStory` + +Opens the given JSON object and returns a YarnStory object, ready for playing. + +### ct.yarn.openFromFile(data) ⇒ `Promise` + +Opens the given JSON object and returns a promise that resolves into a YarnStory. + + +## YarnStory +**Kind**: private class + +### new YarnStory(data, [first]) +Creates a new YarnStory + + +**Returns**: `YarnStory` - self + +| Param | Type | Description | +| --- | --- | --- | +| data | `Object` | The exported, inlined Yarn's .json file | +| [first] | `String` | The starting node's name from which to run the story. Defaults to "Start" | + + +### yarnStory.text ⇒ `String` \| `Boolean` +Returns the current text line, including the character's name + +**Kind**: instance property of `YarnStory` + +**Returns**: `String` \| `Boolean` - Returns `false` if the current position is not a speech line, + otherwise returns the current line. + +### yarnStory.character ⇒ `Boolean` \| `String` \| `undefined` +Returns the character's name that says the current text line. +It is expected that your character's names will be in one word, +otherwise they will be detected as parts of the speech line. +E.g. `Cat: Hello!` will return `'Cat'`, but `Kitty cat: Hello!` +will return `undefined`. + +**Kind**: instance property of `YarnStory` + +**Returns**: `Boolean` \| `String` \| `undefined` - Returns `false` if the current position is not a speech line, + `undefined` if the line does not have a character specified, and a string of your character + if it was specified. + +### yarnStory.body ⇒ `String` \| `Boolean` +Returns the the current text line, without a character. +It is expected that your character's names will be in one word, +otherwise they will be detected as parts of the speech line. +E.g. `Cat: Hello!` will return `'Cat'`, but `Kitty cat: Hello!` +will return `undefined`. + +**Kind**: instance property of `YarnStory` + +**Returns**: `String` \| `Boolean` - The speech line or `false` if the current position + is not a speech line. + +### yarnStory.title ⇒ `String` +Returns the title of the current node + +**Kind**: instance property of `YarnStory` + +**Returns**: `String` - The title of the current node + +### yarnStory.command ⇒ `String` \| `Boolean` +Returns the current command + +**Kind**: instance property of `YarnStory` + +**Returns**: `String` \| `Boolean` - The current command, or `false` if the current + position is not a command. + +### yarnStory.tags ⇒ `String` +Returns the tags of the current node + +**Kind**: instance property of `YarnStory` + +**Returns**: `String` - The tags of the current node. + +### yarnStory.options ⇒ `Array` +Returns currently possible dialogue options, if there are any. + +**Kind**: instance property of `YarnStory` + +**Returns**: `Array` - An array of possible dialogue lines. + +### yarnStory.variables : `Object` +Current variables + +**Kind**: instance property of `YarnStory` + +### yarnStory.start() ⇒ `void` +Starts the story, essentially jumping to a starting node + +**Kind**: instance method of `YarnStory` + +### yarnStory.say(line) ⇒ `void` +"Says" the given option, advancing the story further on a taken branch, if this dialogue option exists. + +**Kind**: instance method of `YarnStory` + +| Param | Type | Description | +| --- | --- | --- | +| line | `String` | The line to say | + + +### yarnStory.jump(title) ⇒ `void` +Manually moves the story to a node with a given title + +**Kind**: instance method of `YarnStory` + +| Param | Type | Description | +| --- | --- | --- | +| title | `String` | The title of the needed node | + + +### yarnStory.back() ⇒ `void` +Moves back to the previous node, but just once + +**Kind**: instance method of `YarnStory` + +### yarnStory.next() ⇒ `void` +Naturally advances in the story, if no options are available + +**Kind**: instance method of `YarnStory` + + +### yarnStory.nodes ⇒ `Object` + +An object containing all the nodes in the story. Each key in this object stands for a node's title. + +**Kind**: instance property of `YarnStory` + +### yarnStory.visited(title) ⇒ `Boolean` +Checks whether a given node was visited + +**Kind**: instance method of `YarnStory` + +**Returns**: `Boolean` - Returns `true` if the specified node was visited, `false` otherwise. + +| Param | Type | Description | +| --- | --- | --- | +| title | `String` | The node's title to check against | + +## Events + +You can listen to events by using `story.on('eventName', data => /* handler */)`. +For other event-related functions, see [PIXI.utils.EventEmitter](http://pixijs.download/release/docs/PIXI.utils.EventEmitter.html) as `YarnStory` extends this class. For examples, see the "Info" tab. + +**Possible events:** + +* `drained` — dispatched when the story has ended, either by the `<>` command or when nothing left to play. +* `newnode` — dispatched when the story switched to a new Yarn's node. +* `start` — called at the start of the story. Can be called more than once by calling `YarnStory.start()`. +* `command` — called when the story has advanced and faced a command. +* `options` — called when the story has advanced and faced a number of dialogue options. +* `text` — called when the story has advanced and returned a new dialogue line. +* `next` — called when the story advances in some way. \ No newline at end of file diff --git a/app/data/ct.libs/yarn/LICENSE b/app/data/ct.libs/yarn/LICENSE new file mode 100644 index 000000000..56bc2ec68 --- /dev/null +++ b/app/data/ct.libs/yarn/LICENSE @@ -0,0 +1,48 @@ +=========================== CT.YARN LICENSE ================================== + +The MIT License (MIT) + +Copyright (c) 2019 Cosmo Myzrail Gorynych + +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. + + +========================== BONDAGE.JS LICENSE ================================= + +The MIT License (MIT) + +Copyright (c) 2017 j hayley + +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/app/data/ct.libs/yarn/README.md b/app/data/ct.libs/yarn/README.md new file mode 100644 index 000000000..699006a69 --- /dev/null +++ b/app/data/ct.libs/yarn/README.md @@ -0,0 +1,71 @@ +ct.yarn is a tool to read Yarn projects and create dialogues/interactive fiction in your games. Under the hood, it uses [Bondage.js](https://github.com/hylyh/bondage.js) to parse Yarn syntax. + +# Writing the story + +Stories are better written with the Yarn Editor, which can be found [here](https://github.com/YarnSpinnerTool/YarnEditor), with its [online edit tool](https://yarnspinnertool.github.io/YarnEditor/). + +See the [Yarn guide](https://github.com/YarnSpinnerTool/YarnSpinner/blob/master/Documentation/YarnSpinner-Dialogue/Yarn-Syntax.md) for nodes' syntax. When you're done, press File -> Save as JSON. + +# Loading stories and working with them + +Though there are tons of different methods and parameters to work with, you'll probably use just five of them to create your first interactive story. You can use a plain JSON object copy-pasted from Yarn Editor: + +```js +var storyData = {/* Your exported yarn .json file */} +var story = ct.yarn.openStory(storyData); +story.on('text', text => { + // A new line appeared. Update UIs, create copies for blurbs, etc. +}); +story.on('command', command => { + // a command was called by a syntax `<>` (you get the string without the <>) +}); +story.on('options', options => { + // here you get an array of strings your character can say. Use it to create reply buttons +}); +ct.room.story = story; // to use it later in UI and your game's logic +``` + +**OR** you can load from a file in your project folder -> includes: + +```js +ct.yarn.openFromFile('myStory.json') +.then(story => { + ct.room.story = story; + story.on('text', text => { + // A new line appeared. Update UIs, create copies for blurbs, etc. + }); + story.on('command', command => { + // a command was called by a syntax `<>` (you get the string without the <>) + }); + story.on('options', options => { + // here you get an array of strings your character can say. Use it to create reply buttons + }); +}); +``` + +To advance through your story, use `story.say('The answer')`: + +```js +ct.room.story.on('options', options => { + for (const option of options) { + ct.types.copy('SpeechButton', 0, 0, { + option: option + }); + } +}); +// Later, in your button's click events: +ct.room.story.say(this.option); +``` + +See the demo `yarn` in the `examples` folder for a full-featured dialogue system. + + +# Using functions + +By default, ct.yarn will execute the built-in Yarn's functions and statements, but there are also a couple of additional "magical" functions: + +* `<>` to play 2D sounds; +* `<>` to switch to other rooms; +* `<>` to pause the execution for a given number of milliseconds. + +These won't trigger the `command` or `next` events and will work automatically. You can disable this behavior and manage these commands by yourself by disabling "Use magic commands" in the Settings tab. diff --git a/app/data/ct.libs/yarn/includes/bondage.min.js b/app/data/ct.libs/yarn/includes/bondage.min.js new file mode 100644 index 000000000..558dde35c --- /dev/null +++ b/app/data/ct.libs/yarn/includes/bondage.min.js @@ -0,0 +1,11 @@ +var bondage=function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={exports:{},id:r,loaded:!1};return e[r].call(i.exports,i,i.exports,t),i.loaded=!0,i.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){n(1),e.exports=n(326)},function(e,t,n){(function(e){"use strict";function t(e,t,n){e[t]||Object[r](e,t,{writable:!0,configurable:!0,value:n})}if(n(2),n(322),n(323),e._babelPolyfill)throw new Error("only one instance of babel-polyfill is allowed");e._babelPolyfill=!0;var r="defineProperty";t(String.prototype,"padLeft","".padStart),t(String.prototype,"padRight","".padEnd),"pop,reverse,shift,keys,values,entries,indexOf,every,some,forEach,map,filter,find,findIndex,includes,join,slice,concat,push,splice,unshift,sort,lastIndexOf,reduce,reduceRight,copyWithin,fill".split(",").forEach(function(e){[][e]&&t(Array,e,Function.call.bind([][e]))})}).call(t,function(){return this}())},function(e,t,n){n(3),n(51),n(52),n(53),n(54),n(56),n(59),n(60),n(61),n(62),n(63),n(64),n(65),n(66),n(67),n(69),n(71),n(73),n(75),n(78),n(79),n(80),n(84),n(86),n(88),n(91),n(92),n(93),n(94),n(96),n(97),n(98),n(99),n(100),n(101),n(102),n(104),n(105),n(106),n(108),n(109),n(110),n(112),n(114),n(115),n(116),n(117),n(118),n(119),n(120),n(121),n(122),n(123),n(124),n(125),n(126),n(131),n(132),n(136),n(137),n(138),n(139),n(141),n(142),n(143),n(144),n(145),n(146),n(147),n(148),n(149),n(150),n(151),n(152),n(153),n(154),n(155),n(157),n(158),n(160),n(161),n(167),n(168),n(170),n(171),n(172),n(176),n(177),n(178),n(179),n(180),n(182),n(183),n(184),n(185),n(188),n(190),n(191),n(192),n(194),n(196),n(198),n(199),n(200),n(202),n(203),n(204),n(205),n(215),n(219),n(220),n(222),n(223),n(227),n(228),n(230),n(231),n(232),n(233),n(234),n(235),n(236),n(237),n(238),n(239),n(240),n(241),n(242),n(243),n(244),n(245),n(246),n(247),n(248),n(250),n(251),n(252),n(253),n(254),n(256),n(257),n(258),n(260),n(261),n(262),n(263),n(264),n(265),n(266),n(267),n(269),n(270),n(272),n(273),n(274),n(275),n(278),n(279),n(281),n(282),n(283),n(284),n(286),n(287),n(288),n(289),n(290),n(291),n(292),n(293),n(294),n(295),n(297),n(298),n(299),n(300),n(301),n(302),n(303),n(304),n(305),n(306),n(307),n(309),n(310),n(311),n(312),n(313),n(314),n(315),n(316),n(317),n(318),n(319),n(320),n(321),e.exports=n(9)},function(e,t,n){"use strict";var r=n(4),i=n(5),o=n(6),s=n(8),a=n(18),c=n(22).KEY,u=n(7),l=n(23),h=n(24),f=n(19),p=n(25),d=n(26),y=n(27),m=n(29),g=n(44),v=n(12),b=n(32),x=n(16),_=n(17),S=n(45),w=n(48),E=n(50),k=n(11),A=n(30),C=E.f,O=k.f,I=w.f,N=r.Symbol,L=r.JSON,P=L&&L.stringify,T="prototype",$=p("_hidden"),M=p("toPrimitive"),j={}.propertyIsEnumerable,R=l("symbol-registry"),F=l("symbols"),D=l("op-symbols"),B=Object[T],G="function"==typeof N,q=r.QObject,U=!q||!q[T]||!q[T].findChild,z=o&&u(function(){return 7!=S(O({},"a",{get:function(){return O(this,"a",{value:7}).a}})).a})?function(e,t,n){var r=C(B,t);r&&delete B[t],O(e,t,n),r&&e!==B&&O(B,t,r)}:O,V=function(e){var t=F[e]=S(N[T]);return t._k=e,t},W=G&&"symbol"==typeof N.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof N},J=function(e,t,n){return e===B&&J(D,t,n),v(e),t=x(t,!0),v(n),i(F,t)?(n.enumerable?(i(e,$)&&e[$][t]&&(e[$][t]=!1),n=S(n,{enumerable:_(0,!1)})):(i(e,$)||O(e,$,_(1,{})),e[$][t]=!0),z(e,t,n)):O(e,t,n)},Y=function(e,t){v(e);for(var n,r=m(t=b(t)),i=0,o=r.length;o>i;)J(e,n=r[i++],t[n]);return e},Z=function(e,t){return void 0===t?S(e):Y(S(e),t)},H=function(e){var t=j.call(this,e=x(e,!0));return!(this===B&&i(F,e)&&!i(D,e))&&(!(t||!i(this,e)||!i(F,e)||i(this,$)&&this[$][e])||t)},K=function(e,t){if(e=b(e),t=x(t,!0),e!==B||!i(F,t)||i(D,t)){var n=C(e,t);return!n||!i(F,t)||i(e,$)&&e[$][t]||(n.enumerable=!0),n}},X=function(e){for(var t,n=I(b(e)),r=[],o=0;n.length>o;)i(F,t=n[o++])||t==$||t==c||r.push(t);return r},Q=function(e){for(var t,n=e===B,r=I(n?D:b(e)),o=[],s=0;r.length>s;)!i(F,t=r[s++])||n&&!i(B,t)||o.push(F[t]);return o};G||(N=function(){if(this instanceof N)throw TypeError("Symbol is not a constructor!");var e=f(arguments.length>0?arguments[0]:void 0),t=function(n){this===B&&t.call(D,n),i(this,$)&&i(this[$],e)&&(this[$][e]=!1),z(this,e,_(1,n))};return o&&U&&z(B,e,{configurable:!0,set:t}),V(e)},a(N[T],"toString",function(){return this._k}),E.f=K,k.f=J,n(49).f=w.f=X,n(43).f=H,n(42).f=Q,o&&!n(28)&&a(B,"propertyIsEnumerable",H,!0),d.f=function(e){return V(p(e))}),s(s.G+s.W+s.F*!G,{Symbol:N});for(var ee="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),te=0;ee.length>te;)p(ee[te++]);for(var ne=A(p.store),re=0;ne.length>re;)y(ne[re++]);s(s.S+s.F*!G,"Symbol",{for:function(e){return i(R,e+="")?R[e]:R[e]=N(e)},keyFor:function(e){if(!W(e))throw TypeError(e+" is not a symbol!");for(var t in R)if(R[t]===e)return t},useSetter:function(){U=!0},useSimple:function(){U=!1}}),s(s.S+s.F*!G,"Object",{create:Z,defineProperty:J,defineProperties:Y,getOwnPropertyDescriptor:K,getOwnPropertyNames:X,getOwnPropertySymbols:Q}),L&&s(s.S+s.F*(!G||u(function(){var e=N();return"[null]"!=P([e])||"{}"!=P({a:e})||"{}"!=P(Object(e))})),"JSON",{stringify:function(e){if(void 0!==e&&!W(e)){for(var t,n,r=[e],i=1;arguments.length>i;)r.push(arguments[i++]);return t=r[1],"function"==typeof t&&(n=t),!n&&g(t)||(t=function(e,t){if(n&&(t=n.call(this,e,t)),!W(t))return t}),r[1]=t,P.apply(L,r)}}}),N[T][M]||n(10)(N[T],M,N[T].valueOf),h(N,"Symbol"),h(Math,"Math",!0),h(r.JSON,"JSON",!0)},function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t,n){e.exports=!n(7)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t,n){var r=n(4),i=n(9),o=n(10),s=n(18),a=n(20),c="prototype",u=function(e,t,n){var l,h,f,p,d=e&u.F,y=e&u.G,m=e&u.S,g=e&u.P,v=e&u.B,b=y?r:m?r[t]||(r[t]={}):(r[t]||{})[c],x=y?i:i[t]||(i[t]={}),_=x[c]||(x[c]={});y&&(n=t);for(l in n)h=!d&&b&&void 0!==b[l],f=(h?b:n)[l],p=v&&h?a(f,r):g&&"function"==typeof f?a(Function.call,f):f,b&&s(b,l,f,e&u.U),x[l]!=f&&o(x,l,p),g&&_[l]!=f&&(_[l]=f)};r.core=i,u.F=1,u.G=2,u.S=4,u.P=8,u.B=16,u.W=32,u.U=64,u.R=128,e.exports=u},function(e,t){var n=e.exports={version:"2.5.1"};"number"==typeof __e&&(__e=n)},function(e,t,n){var r=n(11),i=n(17);e.exports=n(6)?function(e,t,n){return r.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var r=n(12),i=n(14),o=n(16),s=Object.defineProperty;t.f=n(6)?Object.defineProperty:function(e,t,n){if(r(e),t=o(t,!0),r(n),i)try{return s(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){var r=n(13);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){e.exports=!n(6)&&!n(7)(function(){return 7!=Object.defineProperty(n(15)("div"),"a",{get:function(){return 7}}).a})},function(e,t,n){var r=n(13),i=n(4).document,o=r(i)&&r(i.createElement);e.exports=function(e){return o?i.createElement(e):{}}},function(e,t,n){var r=n(13);e.exports=function(e,t){if(!r(e))return e;var n,i;if(t&&"function"==typeof(n=e.toString)&&!r(i=n.call(e)))return i;if("function"==typeof(n=e.valueOf)&&!r(i=n.call(e)))return i;if(!t&&"function"==typeof(n=e.toString)&&!r(i=n.call(e)))return i;throw TypeError("Can't convert object to primitive value")}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,n){var r=n(4),i=n(10),o=n(5),s=n(19)("src"),a="toString",c=Function[a],u=(""+c).split(a);n(9).inspectSource=function(e){return c.call(e)},(e.exports=function(e,t,n,a){var c="function"==typeof n;c&&(o(n,"name")||i(n,"name",t)),e[t]!==n&&(c&&(o(n,s)||i(n,s,e[t]?""+e[t]:u.join(String(t)))),e===r?e[t]=n:a?e[t]?e[t]=n:i(e,t,n):(delete e[t],i(e,t,n)))})(Function.prototype,a,function(){return"function"==typeof this&&this[s]||c.call(this)})},function(e,t){var n=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+r).toString(36))}},function(e,t,n){var r=n(21);e.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,i){return e.call(t,n,r,i)}}return function(){return e.apply(t,arguments)}}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){var r=n(19)("meta"),i=n(13),o=n(5),s=n(11).f,a=0,c=Object.isExtensible||function(){return!0},u=!n(7)(function(){return c(Object.preventExtensions({}))}),l=function(e){s(e,r,{value:{i:"O"+ ++a,w:{}}})},h=function(e,t){if(!i(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!o(e,r)){if(!c(e))return"F";if(!t)return"E";l(e)}return e[r].i},f=function(e,t){if(!o(e,r)){if(!c(e))return!0;if(!t)return!1;l(e)}return e[r].w},p=function(e){return u&&d.NEED&&c(e)&&!o(e,r)&&l(e),e},d=e.exports={KEY:r,NEED:!1,fastKey:h,getWeak:f,onFreeze:p}},function(e,t,n){var r=n(4),i="__core-js_shared__",o=r[i]||(r[i]={});e.exports=function(e){return o[e]||(o[e]={})}},function(e,t,n){var r=n(11).f,i=n(5),o=n(25)("toStringTag");e.exports=function(e,t,n){e&&!i(e=n?e:e.prototype,o)&&r(e,o,{configurable:!0,value:t})}},function(e,t,n){var r=n(23)("wks"),i=n(19),o=n(4).Symbol,s="function"==typeof o,a=e.exports=function(e){return r[e]||(r[e]=s&&o[e]||(s?o:i)("Symbol."+e))};a.store=r},function(e,t,n){t.f=n(25)},function(e,t,n){var r=n(4),i=n(9),o=n(28),s=n(26),a=n(11).f;e.exports=function(e){var t=i.Symbol||(i.Symbol=o?{}:r.Symbol||{});"_"==e.charAt(0)||e in t||a(t,e,{value:s.f(e)})}},function(e,t){e.exports=!1},function(e,t,n){var r=n(30),i=n(42),o=n(43);e.exports=function(e){var t=r(e),n=i.f;if(n)for(var s,a=n(e),c=o.f,u=0;a.length>u;)c.call(e,s=a[u++])&&t.push(s);return t}},function(e,t,n){var r=n(31),i=n(41);e.exports=Object.keys||function(e){return r(e,i)}},function(e,t,n){var r=n(5),i=n(32),o=n(36)(!1),s=n(40)("IE_PROTO");e.exports=function(e,t){var n,a=i(e),c=0,u=[];for(n in a)n!=s&&r(a,n)&&u.push(n);for(;t.length>c;)r(a,n=t[c++])&&(~o(u,n)||u.push(n));return u}},function(e,t,n){var r=n(33),i=n(35);e.exports=function(e){return r(i(e))}},function(e,t,n){var r=n(34);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t){e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,n){var r=n(32),i=n(37),o=n(39);e.exports=function(e){return function(t,n,s){var a,c=r(t),u=i(c.length),l=o(s,u);if(e&&n!=n){for(;u>l;)if(a=c[l++],a!=a)return!0}else for(;u>l;l++)if((e||l in c)&&c[l]===n)return e||l||0;return!e&&-1}}},function(e,t,n){var r=n(38),i=Math.min;e.exports=function(e){return e>0?i(r(e),9007199254740991):0}},function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?r:n)(e)}},function(e,t,n){var r=n(38),i=Math.max,o=Math.min;e.exports=function(e,t){return e=r(e),e<0?i(e+t,0):o(e,t)}},function(e,t,n){var r=n(23)("keys"),i=n(19);e.exports=function(e){return r[e]||(r[e]=i(e))}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,n){var r=n(34);e.exports=Array.isArray||function(e){return"Array"==r(e)}},function(e,t,n){var r=n(12),i=n(46),o=n(41),s=n(40)("IE_PROTO"),a=function(){},c="prototype",u=function(){var e,t=n(15)("iframe"),r=o.length,i="<",s=">";for(t.style.display="none",n(47).appendChild(t),t.src="javascript:",e=t.contentWindow.document,e.open(),e.write(i+"script"+s+"document.F=Object"+i+"/script"+s),e.close(),u=e.F;r--;)delete u[c][o[r]];return u()};e.exports=Object.create||function(e,t){var n;return null!==e?(a[c]=r(e),n=new a,a[c]=null,n[s]=e):n=u(),void 0===t?n:i(n,t)}},function(e,t,n){var r=n(11),i=n(12),o=n(30);e.exports=n(6)?Object.defineProperties:function(e,t){i(e);for(var n,s=o(t),a=s.length,c=0;a>c;)r.f(e,n=s[c++],t[n]);return e}},function(e,t,n){var r=n(4).document;e.exports=r&&r.documentElement},function(e,t,n){var r=n(32),i=n(49).f,o={}.toString,s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],a=function(e){try{return i(e)}catch(e){return s.slice()}};e.exports.f=function(e){return s&&"[object Window]"==o.call(e)?a(e):i(r(e))}},function(e,t,n){var r=n(31),i=n(41).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,i)}},function(e,t,n){var r=n(43),i=n(17),o=n(32),s=n(16),a=n(5),c=n(14),u=Object.getOwnPropertyDescriptor;t.f=n(6)?u:function(e,t){if(e=o(e),t=s(t,!0),c)try{return u(e,t)}catch(e){}if(a(e,t))return i(!r.f.call(e,t),e[t])}},function(e,t,n){var r=n(8);r(r.S,"Object",{create:n(45)})},function(e,t,n){var r=n(8);r(r.S+r.F*!n(6),"Object",{defineProperty:n(11).f})},function(e,t,n){var r=n(8);r(r.S+r.F*!n(6),"Object",{defineProperties:n(46)})},function(e,t,n){var r=n(32),i=n(50).f;n(55)("getOwnPropertyDescriptor",function(){return function(e,t){return i(r(e),t)}})},function(e,t,n){var r=n(8),i=n(9),o=n(7);e.exports=function(e,t){var n=(i.Object||{})[e]||Object[e],s={};s[e]=t(n),r(r.S+r.F*o(function(){n(1)}),"Object",s)}},function(e,t,n){var r=n(57),i=n(58);n(55)("getPrototypeOf",function(){return function(e){return i(r(e))}})},function(e,t,n){var r=n(35);e.exports=function(e){return Object(r(e))}},function(e,t,n){var r=n(5),i=n(57),o=n(40)("IE_PROTO"),s=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=i(e),r(e,o)?e[o]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?s:null}},function(e,t,n){var r=n(57),i=n(30);n(55)("keys",function(){return function(e){return i(r(e))}})},function(e,t,n){n(55)("getOwnPropertyNames",function(){return n(48).f})},function(e,t,n){var r=n(13),i=n(22).onFreeze;n(55)("freeze",function(e){return function(t){return e&&r(t)?e(i(t)):t}})},function(e,t,n){var r=n(13),i=n(22).onFreeze;n(55)("seal",function(e){return function(t){return e&&r(t)?e(i(t)):t}})},function(e,t,n){var r=n(13),i=n(22).onFreeze;n(55)("preventExtensions",function(e){return function(t){return e&&r(t)?e(i(t)):t}})},function(e,t,n){var r=n(13);n(55)("isFrozen",function(e){return function(t){return!r(t)||!!e&&e(t)}})},function(e,t,n){var r=n(13);n(55)("isSealed",function(e){return function(t){return!r(t)||!!e&&e(t)}})},function(e,t,n){var r=n(13);n(55)("isExtensible",function(e){return function(t){return!!r(t)&&(!e||e(t))}})},function(e,t,n){var r=n(8);r(r.S+r.F,"Object",{assign:n(68)})},function(e,t,n){"use strict";var r=n(30),i=n(42),o=n(43),s=n(57),a=n(33),c=Object.assign;e.exports=!c||n(7)(function(){var e={},t={},n=Symbol(),r="abcdefghijklmnopqrst";return e[n]=7,r.split("").forEach(function(e){t[e]=e}),7!=c({},e)[n]||Object.keys(c({},t)).join("")!=r})?function(e,t){for(var n=s(e),c=arguments.length,u=1,l=i.f,h=o.f;c>u;)for(var f,p=a(arguments[u++]),d=l?r(p).concat(l(p)):r(p),y=d.length,m=0;y>m;)h.call(p,f=d[m++])&&(n[f]=p[f]);return n}:c},function(e,t,n){var r=n(8);r(r.S,"Object",{is:n(70)})},function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e===1/t:e!=e&&t!=t}},function(e,t,n){var r=n(8);r(r.S,"Object",{setPrototypeOf:n(72).set})},function(e,t,n){var r=n(13),i=n(12),o=function(e,t){if(i(e),!r(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,r){try{r=n(20)(Function.call,n(50).f(Object.prototype,"__proto__").set,2),r(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,n){return o(e,n),t?e.__proto__=n:r(e,n),e}}({},!1):void 0),check:o}},function(e,t,n){"use strict";var r=n(74),i={};i[n(25)("toStringTag")]="z",i+""!="[object z]"&&n(18)(Object.prototype,"toString",function(){return"[object "+r(this)+"]"},!0)},function(e,t,n){var r=n(34),i=n(25)("toStringTag"),o="Arguments"==r(function(){return arguments}()),s=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,n,a;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=s(t=Object(e),i))?n:o?r(t):"Object"==(a=r(t))&&"function"==typeof t.callee?"Arguments":a}},function(e,t,n){var r=n(8);r(r.P,"Function",{bind:n(76)})},function(e,t,n){"use strict";var r=n(21),i=n(13),o=n(77),s=[].slice,a={},c=function(e,t,n){if(!(t in a)){for(var r=[],i=0;i>>0||(s.test(n)?16:10))}:r},function(e,t,n){var r=n(8),i=n(35),o=n(7),s=n(83),a="["+s+"]",c="​…",u=RegExp("^"+a+a+"*"),l=RegExp(a+a+"*$"),h=function(e,t,n){var i={},a=o(function(){return!!s[e]()||c[e]()!=c}),u=i[e]=a?t(f):s[e];n&&(i[n]=u),r(r.P+r.F*a,"String",i)},f=h.trim=function(e,t){return e=String(i(e)),1&t&&(e=e.replace(u,"")),2&t&&(e=e.replace(l,"")),e};e.exports=h},function(e,t){e.exports="\t\n\v\f\r   ᠎              \u2028\u2029\ufeff"},function(e,t,n){var r=n(8),i=n(85);r(r.G+r.F*(parseFloat!=i),{parseFloat:i})},function(e,t,n){var r=n(4).parseFloat,i=n(82).trim;e.exports=1/r(n(83)+"-0")!==-(1/0)?function(e){var t=i(String(e),3),n=r(t);return 0===n&&"-"==t.charAt(0)?-0:n}:r},function(e,t,n){"use strict";var r=n(4),i=n(5),o=n(34),s=n(87),a=n(16),c=n(7),u=n(49).f,l=n(50).f,h=n(11).f,f=n(82).trim,p="Number",d=r[p],y=d,m=d.prototype,g=o(n(45)(m))==p,v="trim"in String.prototype,b=function(e){var t=a(e,!1);if("string"==typeof t&&t.length>2){t=v?t.trim():f(t,3);var n,r,i,o=t.charCodeAt(0);if(43===o||45===o){if(n=t.charCodeAt(2),88===n||120===n)return NaN}else if(48===o){switch(t.charCodeAt(1)){case 66:case 98:r=2,i=49;break;case 79:case 111:r=8,i=55;break;default:return+t}for(var s,c=t.slice(2),u=0,l=c.length;ui)return NaN;return parseInt(c,r)}}return+t};if(!d(" 0o1")||!d("0b1")||d("+0x1")){d=function(e){var t=arguments.length<1?0:e,n=this;return n instanceof d&&(g?c(function(){m.valueOf.call(n)}):o(n)!=p)?s(new y(b(t)),n,d):b(t)};for(var x,_=n(6)?u(y):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),S=0;_.length>S;S++)i(y,x=_[S])&&!i(d,x)&&h(d,x,l(y,x));d.prototype=m,m.constructor=d,n(18)(r,p,d)}},function(e,t,n){var r=n(13),i=n(72).set;e.exports=function(e,t,n){var o,s=t.constructor;return s!==n&&"function"==typeof s&&(o=s.prototype)!==n.prototype&&r(o)&&i&&i(e,o),e}},function(e,t,n){"use strict";var r=n(8),i=n(38),o=n(89),s=n(90),a=1..toFixed,c=Math.floor,u=[0,0,0,0,0,0],l="Number.toFixed: incorrect invocation!",h="0",f=function(e,t){for(var n=-1,r=t;++n<6;)r+=e*u[n],u[n]=r%1e7,r=c(r/1e7)},p=function(e){for(var t=6,n=0;--t>=0;)n+=u[t],u[t]=c(n/e),n=n%e*1e7},d=function(){for(var e=6,t="";--e>=0;)if(""!==t||0===e||0!==u[e]){var n=String(u[e]);t=""===t?n:t+s.call(h,7-n.length)+n}return t},y=function(e,t,n){return 0===t?n:t%2===1?y(e,t-1,n*e):y(e*e,t/2,n)},m=function(e){for(var t=0,n=e;n>=4096;)t+=12,n/=4096;for(;n>=2;)t+=1,n/=2;return t};r(r.P+r.F*(!!a&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!n(7)(function(){a.call({})})),"Number",{toFixed:function(e){var t,n,r,a,c=o(this,l),u=i(e),g="",v=h;if(u<0||u>20)throw RangeError(l);if(c!=c)return"NaN";if(c<=-1e21||c>=1e21)return String(c);if(c<0&&(g="-",c=-c),c>1e-21)if(t=m(c*y(2,69,1))-69,n=t<0?c*y(2,-t,1):c/y(2,t,1),n*=4503599627370496,t=52-t,t>0){for(f(0,n),r=u;r>=7;)f(1e7,0),r-=7;for(f(y(10,r,1),0),r=t-1;r>=23;)p(1<<23),r-=23;p(1<0?(a=v.length,v=g+(a<=u?"0."+s.call(h,u-a)+v:v.slice(0,a-u)+"."+v.slice(a-u))):v=g+v,v}})},function(e,t,n){var r=n(34);e.exports=function(e,t){if("number"!=typeof e&&"Number"!=r(e))throw TypeError(t);return+e}},function(e,t,n){"use strict";var r=n(38),i=n(35);e.exports=function(e){var t=String(i(this)),n="",o=r(e);if(o<0||o==1/0)throw RangeError("Count can't be negative");for(;o>0;(o>>>=1)&&(t+=t))1&o&&(n+=t);return n}},function(e,t,n){"use strict";var r=n(8),i=n(7),o=n(89),s=1..toPrecision;r(r.P+r.F*(i(function(){return"1"!==s.call(1,void 0)})||!i(function(){s.call({})})),"Number",{toPrecision:function(e){var t=o(this,"Number#toPrecision: incorrect invocation!");return void 0===e?s.call(t):s.call(t,e)}})},function(e,t,n){var r=n(8);r(r.S,"Number",{EPSILON:Math.pow(2,-52)})},function(e,t,n){var r=n(8),i=n(4).isFinite;r(r.S,"Number",{isFinite:function(e){return"number"==typeof e&&i(e)}})},function(e,t,n){var r=n(8);r(r.S,"Number",{isInteger:n(95)})},function(e,t,n){var r=n(13),i=Math.floor;e.exports=function(e){return!r(e)&&isFinite(e)&&i(e)===e}},function(e,t,n){var r=n(8);r(r.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,n){var r=n(8),i=n(95),o=Math.abs;r(r.S,"Number",{isSafeInteger:function(e){return i(e)&&o(e)<=9007199254740991}})},function(e,t,n){var r=n(8);r(r.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,n){var r=n(8);r(r.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,n){var r=n(8),i=n(85);r(r.S+r.F*(Number.parseFloat!=i),"Number",{parseFloat:i})},function(e,t,n){var r=n(8),i=n(81);r(r.S+r.F*(Number.parseInt!=i),"Number",{parseInt:i})},function(e,t,n){var r=n(8),i=n(103),o=Math.sqrt,s=Math.acosh;r(r.S+r.F*!(s&&710==Math.floor(s(Number.MAX_VALUE))&&s(1/0)==1/0),"Math",{acosh:function(e){return(e=+e)<1?NaN:e>94906265.62425156?Math.log(e)+Math.LN2:i(e-1+o(e-1)*o(e+1))}})},function(e,t){e.exports=Math.log1p||function(e){return(e=+e)>-1e-8&&e<1e-8?e-e*e/2:Math.log(1+e)}},function(e,t,n){function r(e){return isFinite(e=+e)&&0!=e?e<0?-r(-e):Math.log(e+Math.sqrt(e*e+1)):e}var i=n(8),o=Math.asinh;i(i.S+i.F*!(o&&1/o(0)>0),"Math",{asinh:r})},function(e,t,n){var r=n(8),i=Math.atanh;r(r.S+r.F*!(i&&1/i(-0)<0),"Math",{atanh:function(e){return 0==(e=+e)?e:Math.log((1+e)/(1-e))/2}})},function(e,t,n){var r=n(8),i=n(107);r(r.S,"Math",{cbrt:function(e){return i(e=+e)*Math.pow(Math.abs(e),1/3)}})},function(e,t){e.exports=Math.sign||function(e){return 0==(e=+e)||e!=e?e:e<0?-1:1}},function(e,t,n){var r=n(8);r(r.S,"Math",{clz32:function(e){return(e>>>=0)?31-Math.floor(Math.log(e+.5)*Math.LOG2E):32}})},function(e,t,n){var r=n(8),i=Math.exp;r(r.S,"Math",{cosh:function(e){return(i(e=+e)+i(-e))/2}})},function(e,t,n){var r=n(8),i=n(111);r(r.S+r.F*(i!=Math.expm1),"Math",{expm1:i})},function(e,t){var n=Math.expm1;e.exports=!n||n(10)>22025.465794806718||n(10)<22025.465794806718||n(-2e-17)!=-2e-17?function(e){return 0==(e=+e)?e:e>-1e-6&&e<1e-6?e+e*e/2:Math.exp(e)-1}:n},function(e,t,n){var r=n(8);r(r.S,"Math",{fround:n(113)})},function(e,t,n){var r=n(107),i=Math.pow,o=i(2,-52),s=i(2,-23),a=i(2,127)*(2-s),c=i(2,-126),u=function(e){return e+1/o-1/o};e.exports=Math.fround||function(e){var t,n,i=Math.abs(e),l=r(e);return ia||n!=n?l*(1/0):l*n)}},function(e,t,n){var r=n(8),i=Math.abs;r(r.S,"Math",{hypot:function(e,t){for(var n,r,o=0,s=0,a=arguments.length,c=0;s0?(r=n/c,o+=r*r):o+=n;return c===1/0?1/0:c*Math.sqrt(o)}})},function(e,t,n){var r=n(8),i=Math.imul;r(r.S+r.F*n(7)(function(){return i(4294967295,5)!=-5||2!=i.length}),"Math",{imul:function(e,t){var n=65535,r=+e,i=+t,o=n&r,s=n&i;return 0|o*s+((n&r>>>16)*s+o*(n&i>>>16)<<16>>>0)}})},function(e,t,n){var r=n(8);r(r.S,"Math",{log10:function(e){return Math.log(e)*Math.LOG10E}})},function(e,t,n){var r=n(8);r(r.S,"Math",{log1p:n(103)})},function(e,t,n){var r=n(8);r(r.S,"Math",{log2:function(e){return Math.log(e)/Math.LN2}})},function(e,t,n){var r=n(8);r(r.S,"Math",{sign:n(107)})},function(e,t,n){var r=n(8),i=n(111),o=Math.exp;r(r.S+r.F*n(7)(function(){return!Math.sinh(-2e-17)!=-2e-17}),"Math",{sinh:function(e){return Math.abs(e=+e)<1?(i(e)-i(-e))/2:(o(e-1)-o(-e-1))*(Math.E/2)}})},function(e,t,n){var r=n(8),i=n(111),o=Math.exp;r(r.S,"Math",{tanh:function(e){var t=i(e=+e),n=i(-e);return t==1/0?1:n==1/0?-1:(t-n)/(o(e)+o(-e))}})},function(e,t,n){var r=n(8);r(r.S,"Math",{trunc:function(e){return(e>0?Math.floor:Math.ceil)(e)}})},function(e,t,n){var r=n(8),i=n(39),o=String.fromCharCode,s=String.fromCodePoint;r(r.S+r.F*(!!s&&1!=s.length),"String",{fromCodePoint:function(e){for(var t,n=[],r=arguments.length,s=0;r>s;){if(t=+arguments[s++],i(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?o(t):o(((t-=65536)>>10)+55296,t%1024+56320))}return n.join("")}})},function(e,t,n){var r=n(8),i=n(32),o=n(37);r(r.S,"String",{raw:function(e){for(var t=i(e.raw),n=o(t.length),r=arguments.length,s=[],a=0;n>a;)s.push(String(t[a++])),a=t.length?{value:void 0,done:!0}:(e=r(t,n),this._i+=e.length,{value:e,done:!1})})},function(e,t,n){var r=n(38),i=n(35);e.exports=function(e){return function(t,n){var o,s,a=String(i(t)),c=r(n),u=a.length;return c<0||c>=u?e?"":void 0:(o=a.charCodeAt(c),o<55296||o>56319||c+1===u||(s=a.charCodeAt(c+1))<56320||s>57343?e?a.charAt(c):o:e?a.slice(c,c+2):(o-55296<<10)+(s-56320)+65536)}}},function(e,t,n){"use strict";var r=n(28),i=n(8),o=n(18),s=n(10),a=n(5),c=n(129),u=n(130),l=n(24),h=n(58),f=n(25)("iterator"),p=!([].keys&&"next"in[].keys()),d="@@iterator",y="keys",m="values",g=function(){return this};e.exports=function(e,t,n,v,b,x,_){u(n,t,v);var S,w,E,k=function(e){if(!p&&e in I)return I[e];switch(e){case y:return function(){return new n(this,e)};case m:return function(){return new n(this,e)}}return function(){return new n(this,e)}},A=t+" Iterator",C=b==m,O=!1,I=e.prototype,N=I[f]||I[d]||b&&I[b],L=N||k(b),P=b?C?k("entries"):L:void 0,T="Array"==t?I.entries||N:N;if(T&&(E=h(T.call(new e)),E!==Object.prototype&&E.next&&(l(E,A,!0),r||a(E,f)||s(E,f,g))),C&&N&&N.name!==m&&(O=!0,L=function(){return N.call(this)}),r&&!_||!p&&!O&&I[f]||s(I,f,L),c[t]=L,c[A]=g,b)if(S={values:C?L:k(m),keys:x?L:k(y),entries:P},_)for(w in S)w in I||o(I,w,S[w]);else i(i.P+i.F*(p||O),t,S);return S}},function(e,t){e.exports={}},function(e,t,n){"use strict";var r=n(45),i=n(17),o=n(24),s={};n(10)(s,n(25)("iterator"),function(){return this}),e.exports=function(e,t,n){e.prototype=r(s,{next:i(1,n)}),o(e,t+" Iterator")}},function(e,t,n){"use strict";var r=n(8),i=n(127)(!1);r(r.P,"String",{codePointAt:function(e){return i(this,e)}})},function(e,t,n){"use strict";var r=n(8),i=n(37),o=n(133),s="endsWith",a=""[s];r(r.P+r.F*n(135)(s),"String",{endsWith:function(e){var t=o(this,e,s),n=arguments.length>1?arguments[1]:void 0,r=i(t.length),c=void 0===n?r:Math.min(i(n),r),u=String(e);return a?a.call(t,u,c):t.slice(c-u.length,c)===u}})},function(e,t,n){var r=n(134),i=n(35);e.exports=function(e,t,n){if(r(t))throw TypeError("String#"+n+" doesn't accept regex!");return String(i(e))}},function(e,t,n){var r=n(13),i=n(34),o=n(25)("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[o])?!!t:"RegExp"==i(e))}},function(e,t,n){var r=n(25)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[r]=!1,!"/./"[e](t)}catch(e){}}return!0}},function(e,t,n){"use strict";var r=n(8),i=n(133),o="includes";r(r.P+r.F*n(135)(o),"String",{includes:function(e){return!!~i(this,e,o).indexOf(e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){var r=n(8);r(r.P,"String",{repeat:n(90)})},function(e,t,n){"use strict";var r=n(8),i=n(37),o=n(133),s="startsWith",a=""[s];r(r.P+r.F*n(135)(s),"String",{startsWith:function(e){var t=o(this,e,s),n=i(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),r=String(e);return a?a.call(t,r,n):t.slice(n,n+r.length)===r}})},function(e,t,n){"use strict";n(140)("anchor",function(e){return function(t){return e(this,"a","name",t)}})},function(e,t,n){var r=n(8),i=n(7),o=n(35),s=/"/g,a=function(e,t,n,r){var i=String(o(e)),a="<"+t;return""!==n&&(a+=" "+n+'="'+String(r).replace(s,""")+'"'),a+">"+i+""};e.exports=function(e,t){var n={};n[e]=t(a),r(r.P+r.F*i(function(){var t=""[e]('"');return t!==t.toLowerCase()||t.split('"').length>3}),"String",n)}},function(e,t,n){"use strict";n(140)("big",function(e){return function(){return e(this,"big","","")}})},function(e,t,n){"use strict";n(140)("blink",function(e){return function(){return e(this,"blink","","")}})},function(e,t,n){"use strict";n(140)("bold",function(e){return function(){return e(this,"b","","")}})},function(e,t,n){"use strict";n(140)("fixed",function(e){return function(){return e(this,"tt","","")}})},function(e,t,n){"use strict";n(140)("fontcolor",function(e){return function(t){return e(this,"font","color",t)}})},function(e,t,n){"use strict";n(140)("fontsize",function(e){return function(t){return e(this,"font","size",t)}})},function(e,t,n){"use strict";n(140)("italics",function(e){return function(){return e(this,"i","","")}})},function(e,t,n){"use strict";n(140)("link",function(e){return function(t){return e(this,"a","href",t)}})},function(e,t,n){"use strict";n(140)("small",function(e){return function(){return e(this,"small","","")}})},function(e,t,n){"use strict";n(140)("strike",function(e){return function(){return e(this,"strike","","")}})},function(e,t,n){"use strict";n(140)("sub",function(e){return function(){return e(this,"sub","","")}})},function(e,t,n){"use strict";n(140)("sup",function(e){return function(){return e(this,"sup","","")}})},function(e,t,n){var r=n(8);r(r.S,"Date",{now:function(){return(new Date).getTime()}})},function(e,t,n){"use strict";var r=n(8),i=n(57),o=n(16);r(r.P+r.F*n(7)(function(){return null!==new Date(NaN).toJSON()||1!==Date.prototype.toJSON.call({toISOString:function(){return 1}})}),"Date",{toJSON:function(e){var t=i(this),n=o(t);return"number"!=typeof n||isFinite(n)?t.toISOString():null}})},function(e,t,n){var r=n(8),i=n(156);r(r.P+r.F*(Date.prototype.toISOString!==i),"Date",{toISOString:i})},function(e,t,n){"use strict";var r=n(7),i=Date.prototype.getTime,o=Date.prototype.toISOString,s=function(e){return e>9?e:"0"+e};e.exports=r(function(){return"0385-07-25T07:06:39.999Z"!=o.call(new Date(-5e13-1))})||!r(function(){o.call(new Date(NaN))})?function(){if(!isFinite(i.call(this)))throw RangeError("Invalid time value");var e=this,t=e.getUTCFullYear(),n=e.getUTCMilliseconds(),r=t<0?"-":t>9999?"+":""; +return r+("00000"+Math.abs(t)).slice(r?-6:-4)+"-"+s(e.getUTCMonth()+1)+"-"+s(e.getUTCDate())+"T"+s(e.getUTCHours())+":"+s(e.getUTCMinutes())+":"+s(e.getUTCSeconds())+"."+(n>99?n:"0"+s(n))+"Z"}:o},function(e,t,n){var r=Date.prototype,i="Invalid Date",o="toString",s=r[o],a=r.getTime;new Date(NaN)+""!=i&&n(18)(r,o,function(){var e=a.call(this);return e===e?s.call(this):i})},function(e,t,n){var r=n(25)("toPrimitive"),i=Date.prototype;r in i||n(10)(i,r,n(159))},function(e,t,n){"use strict";var r=n(12),i=n(16),o="number";e.exports=function(e){if("string"!==e&&e!==o&&"default"!==e)throw TypeError("Incorrect hint");return i(r(this),e!=o)}},function(e,t,n){var r=n(8);r(r.S,"Array",{isArray:n(44)})},function(e,t,n){"use strict";var r=n(20),i=n(8),o=n(57),s=n(162),a=n(163),c=n(37),u=n(164),l=n(165);i(i.S+i.F*!n(166)(function(e){Array.from(e)}),"Array",{from:function(e){var t,n,i,h,f=o(e),p="function"==typeof this?this:Array,d=arguments.length,y=d>1?arguments[1]:void 0,m=void 0!==y,g=0,v=l(f);if(m&&(y=r(y,d>2?arguments[2]:void 0,2)),void 0==v||p==Array&&a(v))for(t=c(f.length),n=new p(t);t>g;g++)u(n,g,m?y(f[g],g):f[g]);else for(h=v.call(f),n=new p;!(i=h.next()).done;g++)u(n,g,m?s(h,y,[i.value,g],!0):i.value);return n.length=g,n}})},function(e,t,n){var r=n(12);e.exports=function(e,t,n,i){try{return i?t(r(n)[0],n[1]):t(n)}catch(t){var o=e.return;throw void 0!==o&&r(o.call(e)),t}}},function(e,t,n){var r=n(129),i=n(25)("iterator"),o=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||o[i]===e)}},function(e,t,n){"use strict";var r=n(11),i=n(17);e.exports=function(e,t,n){t in e?r.f(e,t,i(0,n)):e[t]=n}},function(e,t,n){var r=n(74),i=n(25)("iterator"),o=n(129);e.exports=n(9).getIteratorMethod=function(e){if(void 0!=e)return e[i]||e["@@iterator"]||o[r(e)]}},function(e,t,n){var r=n(25)("iterator"),i=!1;try{var o=[7][r]();o.return=function(){i=!0},Array.from(o,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!i)return!1;var n=!1;try{var o=[7],s=o[r]();s.next=function(){return{done:n=!0}},o[r]=function(){return s},e(o)}catch(e){}return n}},function(e,t,n){"use strict";var r=n(8),i=n(164);r(r.S+r.F*n(7)(function(){function e(){}return!(Array.of.call(e)instanceof e)}),"Array",{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);t>e;)i(n,e,arguments[e++]);return n.length=t,n}})},function(e,t,n){"use strict";var r=n(8),i=n(32),o=[].join;r(r.P+r.F*(n(33)!=Object||!n(169)(o)),"Array",{join:function(e){return o.call(i(this),void 0===e?",":e)}})},function(e,t,n){"use strict";var r=n(7);e.exports=function(e,t){return!!e&&r(function(){t?e.call(null,function(){},1):e.call(null)})}},function(e,t,n){"use strict";var r=n(8),i=n(47),o=n(34),s=n(39),a=n(37),c=[].slice;r(r.P+r.F*n(7)(function(){i&&c.call(i)}),"Array",{slice:function(e,t){var n=a(this.length),r=o(this);if(t=void 0===t?n:t,"Array"==r)return c.call(this,e,t);for(var i=s(e,n),u=s(t,n),l=a(u-i),h=Array(l),f=0;f_;_++)if((f||_ in v)&&(y=v[_],m=b(y,_,g),e))if(n)S[_]=m;else if(m)switch(e){case 3:return!0;case 5:return y;case 6:return _;case 2:S.push(y)}else if(l)return!1;return h?-1:u||l?l:S}}},function(e,t,n){var r=n(175);e.exports=function(e,t){return new(r(e))(t)}},function(e,t,n){var r=n(13),i=n(44),o=n(25)("species");e.exports=function(e){var t;return i(e)&&(t=e.constructor,"function"!=typeof t||t!==Array&&!i(t.prototype)||(t=void 0),r(t)&&(t=t[o],null===t&&(t=void 0))),void 0===t?Array:t}},function(e,t,n){"use strict";var r=n(8),i=n(173)(1);r(r.P+r.F*!n(169)([].map,!0),"Array",{map:function(e){return i(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(8),i=n(173)(2);r(r.P+r.F*!n(169)([].filter,!0),"Array",{filter:function(e){return i(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(8),i=n(173)(3);r(r.P+r.F*!n(169)([].some,!0),"Array",{some:function(e){return i(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(8),i=n(173)(4);r(r.P+r.F*!n(169)([].every,!0),"Array",{every:function(e){return i(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(8),i=n(181);r(r.P+r.F*!n(169)([].reduce,!0),"Array",{reduce:function(e){return i(this,e,arguments.length,arguments[1],!1)}})},function(e,t,n){var r=n(21),i=n(57),o=n(33),s=n(37);e.exports=function(e,t,n,a,c){r(t);var u=i(e),l=o(u),h=s(u.length),f=c?h-1:0,p=c?-1:1;if(n<2)for(;;){if(f in l){a=l[f],f+=p;break}if(f+=p,c?f<0:h<=f)throw TypeError("Reduce of empty array with no initial value")}for(;c?f>=0:h>f;f+=p)f in l&&(a=t(a,l[f],f,u));return a}},function(e,t,n){"use strict";var r=n(8),i=n(181);r(r.P+r.F*!n(169)([].reduceRight,!0),"Array",{reduceRight:function(e){return i(this,e,arguments.length,arguments[1],!0)}})},function(e,t,n){"use strict";var r=n(8),i=n(36)(!1),o=[].indexOf,s=!!o&&1/[1].indexOf(1,-0)<0;r(r.P+r.F*(s||!n(169)(o)),"Array",{indexOf:function(e){return s?o.apply(this,arguments)||0:i(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(8),i=n(32),o=n(38),s=n(37),a=[].lastIndexOf,c=!!a&&1/[1].lastIndexOf(1,-0)<0;r(r.P+r.F*(c||!n(169)(a)),"Array",{lastIndexOf:function(e){if(c)return a.apply(this,arguments)||0;var t=i(this),n=s(t.length),r=n-1;for(arguments.length>1&&(r=Math.min(r,o(arguments[1]))),r<0&&(r=n+r);r>=0;r--)if(r in t&&t[r]===e)return r||0;return-1}})},function(e,t,n){var r=n(8);r(r.P,"Array",{copyWithin:n(186)}),n(187)("copyWithin")},function(e,t,n){"use strict";var r=n(57),i=n(39),o=n(37);e.exports=[].copyWithin||function(e,t){var n=r(this),s=o(n.length),a=i(e,s),c=i(t,s),u=arguments.length>2?arguments[2]:void 0,l=Math.min((void 0===u?s:i(u,s))-c,s-a),h=1;for(c0;)c in n?n[a]=n[c]:delete n[a],a+=h,c+=h;return n}},function(e,t,n){var r=n(25)("unscopables"),i=Array.prototype;void 0==i[r]&&n(10)(i,r,{}),e.exports=function(e){i[r][e]=!0}},function(e,t,n){var r=n(8);r(r.P,"Array",{fill:n(189)}),n(187)("fill")},function(e,t,n){"use strict";var r=n(57),i=n(39),o=n(37);e.exports=function(e){for(var t=r(this),n=o(t.length),s=arguments.length,a=i(s>1?arguments[1]:void 0,n),c=s>2?arguments[2]:void 0,u=void 0===c?n:i(c,n);u>a;)t[a++]=e;return t}},function(e,t,n){"use strict";var r=n(8),i=n(173)(5),o="find",s=!0;o in[]&&Array(1)[o](function(){s=!1}),r(r.P+r.F*s,"Array",{find:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),n(187)(o)},function(e,t,n){"use strict";var r=n(8),i=n(173)(6),o="findIndex",s=!0;o in[]&&Array(1)[o](function(){s=!1}),r(r.P+r.F*s,"Array",{findIndex:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),n(187)(o)},function(e,t,n){n(193)("Array")},function(e,t,n){"use strict";var r=n(4),i=n(11),o=n(6),s=n(25)("species");e.exports=function(e){var t=r[e];o&&t&&!t[s]&&i.f(t,s,{configurable:!0,get:function(){return this}})}},function(e,t,n){"use strict";var r=n(187),i=n(195),o=n(129),s=n(32);e.exports=n(128)(Array,"Array",function(e,t){this._t=s(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,i(1)):"keys"==t?i(0,n):"values"==t?i(0,e[n]):i(0,[n,e[n]])},"values"),o.Arguments=o.Array,r("keys"),r("values"),r("entries")},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,n){var r=n(4),i=n(87),o=n(11).f,s=n(49).f,a=n(134),c=n(197),u=r.RegExp,l=u,h=u.prototype,f=/a/g,p=/a/g,d=new u(f)!==f;if(n(6)&&(!d||n(7)(function(){return p[n(25)("match")]=!1,u(f)!=f||u(p)==p||"/a/i"!=u(f,"i")}))){u=function(e,t){var n=this instanceof u,r=a(e),o=void 0===t;return!n&&r&&e.constructor===u&&o?e:i(d?new l(r&&!o?e.source:e,t):l((r=e instanceof u)?e.source:e,r&&o?c.call(e):t),n?this:h,u)};for(var y=(function(e){e in u||o(u,e,{configurable:!0,get:function(){return l[e]},set:function(t){l[e]=t}})}),m=s(l),g=0;m.length>g;)y(m[g++]);h.constructor=u,u.prototype=h,n(18)(r,"RegExp",u)}n(193)("RegExp")},function(e,t,n){"use strict";var r=n(12);e.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,n){"use strict";n(199);var r=n(12),i=n(197),o=n(6),s="toString",a=/./[s],c=function(e){n(18)(RegExp.prototype,s,e,!0)};n(7)(function(){return"/a/b"!=a.call({source:"a",flags:"b"})})?c(function(){var e=r(this);return"/".concat(e.source,"/","flags"in e?e.flags:!o&&e instanceof RegExp?i.call(e):void 0)}):a.name!=s&&c(function(){return a.call(this)})},function(e,t,n){n(6)&&"g"!=/./g.flags&&n(11).f(RegExp.prototype,"flags",{configurable:!0,get:n(197)})},function(e,t,n){n(201)("match",1,function(e,t,n){return[function(n){"use strict";var r=e(this),i=void 0==n?void 0:n[t];return void 0!==i?i.call(n,r):new RegExp(n)[t](String(r))},n]})},function(e,t,n){"use strict";var r=n(10),i=n(18),o=n(7),s=n(35),a=n(25);e.exports=function(e,t,n){var c=a(e),u=n(s,c,""[e]),l=u[0],h=u[1];o(function(){var t={};return t[c]=function(){return 7},7!=""[e](t)})&&(i(String.prototype,e,l),r(RegExp.prototype,c,2==t?function(e,t){return h.call(e,this,t)}:function(e){return h.call(e,this)}))}},function(e,t,n){n(201)("replace",2,function(e,t,n){return[function(r,i){"use strict";var o=e(this),s=void 0==r?void 0:r[t];return void 0!==s?s.call(r,o,i):n.call(String(o),r,i)},n]})},function(e,t,n){n(201)("search",1,function(e,t,n){return[function(n){"use strict";var r=e(this),i=void 0==n?void 0:n[t];return void 0!==i?i.call(n,r):new RegExp(n)[t](String(r))},n]})},function(e,t,n){n(201)("split",2,function(e,t,r){"use strict";var i=n(134),o=r,s=[].push,a="split",c="length",u="lastIndex";if("c"=="abbc"[a](/(b)*/)[1]||4!="test"[a](/(?:)/,-1)[c]||2!="ab"[a](/(?:ab)*/)[c]||4!="."[a](/(.?)(.?)/)[c]||"."[a](/()()/)[c]>1||""[a](/.?/)[c]){var l=void 0===/()??/.exec("")[1];r=function(e,t){var n=String(this);if(void 0===e&&0===t)return[];if(!i(e))return o.call(n,e,t);var r,a,h,f,p,d=[],y=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),m=0,g=void 0===t?4294967295:t>>>0,v=new RegExp(e.source,y+"g");for(l||(r=new RegExp("^"+v.source+"$(?!\\s)",y));(a=v.exec(n))&&(h=a.index+a[0][c],!(h>m&&(d.push(n.slice(m,a.index)),!l&&a[c]>1&&a[0].replace(r,function(){for(p=1;p1&&a.index=g)));)v[u]===a.index&&v[u]++;return m===n[c]?!f&&v.test("")||d.push(""):d.push(n.slice(m)),d[c]>g?d.slice(0,g):d}}else"0"[a](void 0,0)[c]&&(r=function(e,t){return void 0===e&&0===t?[]:o.call(this,e,t)});return[function(n,i){var o=e(this),s=void 0==n?void 0:n[t];return void 0!==s?s.call(n,o,i):r.call(String(o),n,i)},r]})},function(e,t,n){"use strict";var r,i,o,s,a=n(28),c=n(4),u=n(20),l=n(74),h=n(8),f=n(13),p=n(21),d=n(206),y=n(207),m=n(208),g=n(209).set,v=n(210)(),b=n(211),x=n(212),_=n(213),S="Promise",w=c.TypeError,E=c.process,k=c[S],A="process"==l(E),C=function(){},O=i=b.f,I=!!function(){try{var e=k.resolve(1),t=(e.constructor={})[n(25)("species")]=function(e){e(C,C)};return(A||"function"==typeof PromiseRejectionEvent)&&e.then(C)instanceof t}catch(e){}}(),N=function(e){var t;return!(!f(e)||"function"!=typeof(t=e.then))&&t},L=function(e,t){if(!e._n){e._n=!0;var n=e._c;v(function(){for(var r=e._v,i=1==e._s,o=0,s=function(t){var n,o,s=i?t.ok:t.fail,a=t.resolve,c=t.reject,u=t.domain;try{s?(i||(2==e._h&&$(e),e._h=1),s===!0?n=r:(u&&u.enter(),n=s(r),u&&u.exit()),n===t.promise?c(w("Promise-chain cycle")):(o=N(n))?o.call(n,a,c):a(n)):c(r)}catch(e){c(e)}};n.length>o;)s(n[o++]);e._c=[],e._n=!1,t&&!e._h&&P(e)})}},P=function(e){g.call(c,function(){var t,n,r,i=e._v,o=T(e);if(o&&(t=x(function(){A?E.emit("unhandledRejection",i,e):(n=c.onunhandledrejection)?n({promise:e,reason:i}):(r=c.console)&&r.error&&r.error("Unhandled promise rejection",i)}),e._h=A||T(e)?2:1),e._a=void 0,o&&t.e)throw t.v})},T=function(e){if(1==e._h)return!1;for(var t,n=e._a||e._c,r=0;n.length>r;)if(t=n[r++],t.fail||!T(t.promise))return!1;return!0},$=function(e){g.call(c,function(){var t;A?E.emit("rejectionHandled",e):(t=c.onrejectionhandled)&&t({promise:e,reason:e._v})})},M=function(e){var t=this;t._d||(t._d=!0,t=t._w||t,t._v=e,t._s=2,t._a||(t._a=t._c.slice()),L(t,!0))},j=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw w("Promise can't be resolved itself");(t=N(e))?v(function(){var r={_w:n,_d:!1};try{t.call(e,u(j,r,1),u(M,r,1))}catch(e){M.call(r,e)}}):(n._v=e,n._s=1,L(n,!1))}catch(e){M.call({_w:n,_d:!1},e)}}};I||(k=function(e){d(this,k,S,"_h"),p(e),r.call(this);try{e(u(j,this,1),u(M,this,1))}catch(e){M.call(this,e)}},r=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},r.prototype=n(214)(k.prototype,{then:function(e,t){var n=O(m(this,k));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=A?E.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&L(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),o=function(){var e=new r;this.promise=e,this.resolve=u(j,e,1),this.reject=u(M,e,1)},b.f=O=function(e){return e===k||e===s?new o(e):i(e)}),h(h.G+h.W+h.F*!I,{Promise:k}),n(24)(k,S),n(193)(S),s=n(9)[S],h(h.S+h.F*!I,S,{reject:function(e){var t=O(this),n=t.reject;return n(e),t.promise}}),h(h.S+h.F*(a||!I),S,{resolve:function(e){return _(a&&this===s?k:this,e)}}),h(h.S+h.F*!(I&&n(166)(function(e){k.all(e).catch(C)})),S,{all:function(e){var t=this,n=O(t),r=n.resolve,i=n.reject,o=x(function(){var n=[],o=0,s=1;y(e,!1,function(e){var a=o++,c=!1;n.push(void 0),s++,t.resolve(e).then(function(e){c||(c=!0,n[a]=e,--s||r(n))},i)}),--s||r(n)});return o.e&&i(o.v),n.promise},race:function(e){var t=this,n=O(t),r=n.reject,i=x(function(){y(e,!1,function(e){t.resolve(e).then(n.resolve,r)})});return i.e&&r(i.v),n.promise}})},function(e,t){e.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},function(e,t,n){var r=n(20),i=n(162),o=n(163),s=n(12),a=n(37),c=n(165),u={},l={},t=e.exports=function(e,t,n,h,f){var p,d,y,m,g=f?function(){return e}:c(e),v=r(n,h,t?2:1),b=0;if("function"!=typeof g)throw TypeError(e+" is not iterable!");if(o(g)){for(p=a(e.length);p>b;b++)if(m=t?v(s(d=e[b])[0],d[1]):v(e[b]),m===u||m===l)return m}else for(y=g.call(e);!(d=y.next()).done;)if(m=i(y,v,d.value,t),m===u||m===l)return m};t.BREAK=u,t.RETURN=l},function(e,t,n){var r=n(12),i=n(21),o=n(25)("species");e.exports=function(e,t){var n,s=r(e).constructor;return void 0===s||void 0==(n=r(s)[o])?t:i(n)}},function(e,t,n){var r,i,o,s=n(20),a=n(77),c=n(47),u=n(15),l=n(4),h=l.process,f=l.setImmediate,p=l.clearImmediate,d=l.MessageChannel,y=l.Dispatch,m=0,g={},v="onreadystatechange",b=function(){var e=+this;if(g.hasOwnProperty(e)){var t=g[e];delete g[e],t()}},x=function(e){b.call(e.data)};f&&p||(f=function(e){for(var t=[],n=1;arguments.length>n;)t.push(arguments[n++]);return g[++m]=function(){a("function"==typeof e?e:Function(e),t)},r(m),m},p=function(e){delete g[e]},"process"==n(34)(h)?r=function(e){h.nextTick(s(b,e,1))}:y&&y.now?r=function(e){y.now(s(b,e,1))}:d?(i=new d,o=i.port2,i.port1.onmessage=x,r=s(o.postMessage,o,1)):l.addEventListener&&"function"==typeof postMessage&&!l.importScripts?(r=function(e){l.postMessage(e+"","*")},l.addEventListener("message",x,!1)):r=v in u("script")?function(e){c.appendChild(u("script"))[v]=function(){c.removeChild(this),b.call(e)}}:function(e){setTimeout(s(b,e,1),0)}),e.exports={set:f,clear:p}},function(e,t,n){var r=n(4),i=n(209).set,o=r.MutationObserver||r.WebKitMutationObserver,s=r.process,a=r.Promise,c="process"==n(34)(s);e.exports=function(){var e,t,n,u=function(){var r,i;for(c&&(r=s.domain)&&r.exit();e;){i=e.fn,e=e.next;try{i()}catch(r){throw e?n():t=void 0,r}}t=void 0,r&&r.enter()};if(c)n=function(){s.nextTick(u)};else if(o){var l=!0,h=document.createTextNode("");new o(u).observe(h,{characterData:!0}),n=function(){h.data=l=!l}}else if(a&&a.resolve){var f=a.resolve();n=function(){f.then(u)}}else n=function(){i.call(r,u)};return function(r){var i={fn:r,next:void 0};t&&(t.next=i),e||(e=i,n()),t=i}}},function(e,t,n){"use strict";function r(e){var t,n;this.promise=new e(function(e,r){if(void 0!==t||void 0!==n)throw TypeError("Bad Promise constructor");t=e,n=r}),this.resolve=i(t),this.reject=i(n)}var i=n(21);e.exports.f=function(e){return new r(e)}},function(e,t){e.exports=function(e){try{return{e:!1,v:e()}}catch(e){return{e:!0,v:e}}}},function(e,t,n){var r=n(12),i=n(13),o=n(211);e.exports=function(e,t){if(r(e),i(t)&&t.constructor===e)return t;var n=o.f(e),s=n.resolve;return s(t),n.promise}},function(e,t,n){var r=n(18);e.exports=function(e,t,n){for(var i in t)r(e,i,t[i],n);return e}},function(e,t,n){"use strict";var r=n(216),i=n(217),o="Map";e.exports=n(218)(o,function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{get:function(e){var t=r.getEntry(i(this,o),e);return t&&t.v},set:function(e,t){return r.def(i(this,o),0===e?0:e,t)}},r,!0)},function(e,t,n){"use strict";var r=n(11).f,i=n(45),o=n(214),s=n(20),a=n(206),c=n(207),u=n(128),l=n(195),h=n(193),f=n(6),p=n(22).fastKey,d=n(217),y=f?"_s":"size",m=function(e,t){var n,r=p(t);if("F"!==r)return e._i[r];for(n=e._f;n;n=n.n)if(n.k==t)return n};e.exports={getConstructor:function(e,t,n,u){var l=e(function(e,r){a(e,l,t,"_i"),e._t=t,e._i=i(null),e._f=void 0,e._l=void 0,e[y]=0,void 0!=r&&c(r,n,e[u],e)});return o(l.prototype,{clear:function(){for(var e=d(this,t),n=e._i,r=e._f;r;r=r.n)r.r=!0,r.p&&(r.p=r.p.n=void 0),delete n[r.i];e._f=e._l=void 0,e[y]=0},delete:function(e){var n=d(this,t),r=m(n,e);if(r){var i=r.n,o=r.p;delete n._i[r.i],r.r=!0,o&&(o.n=i),i&&(i.p=o),n._f==r&&(n._f=i),n._l==r&&(n._l=o),n[y]--}return!!r},forEach:function(e){d(this,t);for(var n,r=s(e,arguments.length>1?arguments[1]:void 0,3);n=n?n.n:this._f;)for(r(n.v,n.k,this);n&&n.r;)n=n.p},has:function(e){return!!m(d(this,t),e)}}),f&&r(l.prototype,"size",{get:function(){return d(this,t)[y]}}),l},def:function(e,t,n){var r,i,o=m(e,t);return o?o.v=n:(e._l=o={i:i=p(t,!0),k:t,v:n,p:r=e._l,n:void 0,r:!1},e._f||(e._f=o),r&&(r.n=o),e[y]++,"F"!==i&&(e._i[i]=o)),e},getEntry:m,setStrong:function(e,t,n){u(e,t,function(e,n){this._t=d(e,t),this._k=n,this._l=void 0},function(){for(var e=this,t=e._k,n=e._l;n&&n.r;)n=n.p;return e._t&&(e._l=n=n?n.n:e._t._f)?"keys"==t?l(0,n.k):"values"==t?l(0,n.v):l(0,[n.k,n.v]):(e._t=void 0,l(1))},n?"entries":"values",!n,!0),h(t)}}},function(e,t,n){var r=n(13);e.exports=function(e,t){if(!r(e)||e._t!==t)throw TypeError("Incompatible receiver, "+t+" required!");return e}},function(e,t,n){"use strict";var r=n(4),i=n(8),o=n(18),s=n(214),a=n(22),c=n(207),u=n(206),l=n(13),h=n(7),f=n(166),p=n(24),d=n(87);e.exports=function(e,t,n,y,m,g){var v=r[e],b=v,x=m?"set":"add",_=b&&b.prototype,S={},w=function(e){var t=_[e];o(_,e,"delete"==e?function(e){return!(g&&!l(e))&&t.call(this,0===e?0:e)}:"has"==e?function(e){return!(g&&!l(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return g&&!l(e)?void 0:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,n){return t.call(this,0===e?0:e,n),this})};if("function"==typeof b&&(g||_.forEach&&!h(function(){(new b).entries().next()}))){var E=new b,k=E[x](g?{}:-0,1)!=E,A=h(function(){E.has(1)}),C=f(function(e){new b(e)}),O=!g&&h(function(){for(var e=new b,t=5;t--;)e[x](t,t);return!e.has(-0)});C||(b=t(function(t,n){u(t,b,e);var r=d(new v,t,b);return void 0!=n&&c(n,m,r[x],r),r}),b.prototype=_,_.constructor=b),(A||O)&&(w("delete"),w("has"),m&&w("get")),(O||k)&&w(x),g&&_.clear&&delete _.clear}else b=y.getConstructor(t,e,m,x),s(b.prototype,n),a.NEED=!0;return p(b,e),S[e]=b,i(i.G+i.W+i.F*(b!=v),S),g||y.setStrong(b,e,m),b}},function(e,t,n){"use strict";var r=n(216),i=n(217),o="Set";e.exports=n(218)(o,function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return r.def(i(this,o),e=0===e?0:e,e)}},r)},function(e,t,n){"use strict";var r,i=n(173)(0),o=n(18),s=n(22),a=n(68),c=n(221),u=n(13),l=n(7),h=n(217),f="WeakMap",p=s.getWeak,d=Object.isExtensible,y=c.ufstore,m={},g=function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},v={get:function(e){if(u(e)){var t=p(e);return t===!0?y(h(this,f)).get(e):t?t[this._i]:void 0}},set:function(e,t){return c.def(h(this,f),e,t)}},b=e.exports=n(218)(f,g,v,c,!0,!0);l(function(){return 7!=(new b).set((Object.freeze||Object)(m),7).get(m)})&&(r=c.getConstructor(g,f),a(r.prototype,v),s.NEED=!0,i(["delete","has","get","set"],function(e){var t=b.prototype,n=t[e];o(t,e,function(t,i){if(u(t)&&!d(t)){this._f||(this._f=new r);var o=this._f[e](t,i);return"set"==e?this:o}return n.call(this,t,i)})}))},function(e,t,n){"use strict";var r=n(214),i=n(22).getWeak,o=n(12),s=n(13),a=n(206),c=n(207),u=n(173),l=n(5),h=n(217),f=u(5),p=u(6),d=0,y=function(e){return e._l||(e._l=new m)},m=function(){this.a=[]},g=function(e,t){return f(e.a,function(e){return e[0]===t})};m.prototype={get:function(e){var t=g(this,e);if(t)return t[1]},has:function(e){return!!g(this,e)},set:function(e,t){var n=g(this,e);n?n[1]=t:this.a.push([e,t])},delete:function(e){var t=p(this.a,function(t){return t[0]===e});return~t&&this.a.splice(t,1),!!~t}},e.exports={getConstructor:function(e,t,n,o){var u=e(function(e,r){a(e,u,t,"_i"),e._t=t,e._i=d++,e._l=void 0,void 0!=r&&c(r,n,e[o],e)});return r(u.prototype,{delete:function(e){if(!s(e))return!1;var n=i(e);return n===!0?y(h(this,t)).delete(e):n&&l(n,this._i)&&delete n[this._i]},has:function(e){if(!s(e))return!1;var n=i(e);return n===!0?y(h(this,t)).has(e):n&&l(n,this._i)}}),u},def:function(e,t,n){var r=i(o(t),!0);return r===!0?y(e).set(t,n):r[e._i]=n,e},ufstore:y}},function(e,t,n){"use strict";var r=n(221),i=n(217),o="WeakSet";n(218)(o,function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return r.def(i(this,o),e,!0)}},r,!1,!0)},function(e,t,n){"use strict";var r=n(8),i=n(224),o=n(225),s=n(12),a=n(39),c=n(37),u=n(13),l=n(4).ArrayBuffer,h=n(208),f=o.ArrayBuffer,p=o.DataView,d=i.ABV&&l.isView,y=f.prototype.slice,m=i.VIEW,g="ArrayBuffer";r(r.G+r.W+r.F*(l!==f),{ArrayBuffer:f}),r(r.S+r.F*!i.CONSTR,g,{isView:function(e){return d&&d(e)||u(e)&&m in e}}),r(r.P+r.U+r.F*n(7)(function(){return!new f(2).slice(1,void 0).byteLength}),g,{slice:function(e,t){if(void 0!==y&&void 0===t)return y.call(s(this),e);for(var n=s(this).byteLength,r=a(e,n),i=a(void 0===t?n:t,n),o=new(h(this,f))(c(i-r)),u=new p(this),l=new p(o),d=0;r>1,l=23===t?G(2,-24)-G(2,-77):0,h=0,f=e<0||0===e&&1/e<0?1:0;for(e=B(e),e!=e||e===F?(i=e!=e?1:0,r=c):(r=q(U(e)/z),e*(o=G(2,-r))<1&&(r--,o*=2),e+=r+u>=1?l/o:l*G(2,1-u),e*o>=2&&(r++,o/=2),r+u>=c?(i=0,r=c):r+u>=1?(i=(e*o-1)*G(2,t),r+=u):(i=e*G(2,u-1)*G(2,t),r=0));t>=8;s[h++]=255&i,i/=256,t-=8);for(r=r<0;s[h++]=255&r,r/=256,a-=8);return s[--h]|=128*f,s}function i(e,t,n){var r,i=8*n-t-1,o=(1<>1,a=i-7,c=n-1,u=e[c--],l=127&u;for(u>>=7;a>0;l=256*l+e[c],c--,a-=8);for(r=l&(1<<-a)-1,l>>=-a,a+=t;a>0;r=256*r+e[c],c--,a-=8);if(0===l)l=1-s;else{if(l===o)return r?NaN:u?-F:F;r+=G(2,t),l-=s}return(u?-1:1)*r*G(2,l-t)}function o(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]}function s(e){return[255&e]}function a(e){return[255&e,e>>8&255]}function c(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]}function u(e){return r(e,52,8)}function l(e){return r(e,23,4)}function h(e,t,n){A(e[L],t,{get:function(){return this[n]}})}function f(e,t,n,r){var i=+n,o=E(i);if(o+t>e[Z])throw R(T);var s=e[Y]._b,a=o+e[H],c=s.slice(a,a+t);return r?c:c.reverse()}function p(e,t,n,r,i,o){var s=+n,a=E(s);if(a+t>e[Z])throw R(T);for(var c=e[Y]._b,u=a+e[H],l=r(+i),h=0;hee;)(K=Q[ee++])in $||v($,K,D[K]);m||(X.constructor=$)}var te=new M(new $(2)),ne=M[L].setInt8;te.setInt8(0,2147483648),te.setInt8(1,2147483649),!te.getInt8(0)&&te.getInt8(1)||b(M[L],{setInt8:function(e,t){ne.call(this,e,t<<24>>24)},setUint8:function(e,t){ne.call(this,e,t<<24>>24)}},!0)}else $=function(e){_(this,$,I);var t=E(e);this._b=C.call(Array(t),0),this[Z]=t},M=function(e,t,n){_(this,M,N),_(e,$,N);var r=e[Z],i=S(t);if(i<0||i>r)throw R("Wrong offset!");if(n=void 0===n?r-i:w(n),i+n>r)throw R(P);this[Y]=e,this[H]=i,this[Z]=n},y&&(h($,W,"_l"),h(M,V,"_b"),h(M,W,"_l"),h(M,J,"_o")),b(M[L],{getInt8:function(e){return f(this,1,e)[0]<<24>>24},getUint8:function(e){return f(this,1,e)[0]},getInt16:function(e){var t=f(this,2,e,arguments[1]);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=f(this,2,e,arguments[1]);return t[1]<<8|t[0]},getInt32:function(e){return o(f(this,4,e,arguments[1]))},getUint32:function(e){return o(f(this,4,e,arguments[1]))>>>0},getFloat32:function(e){return i(f(this,4,e,arguments[1]),23,4)},getFloat64:function(e){return i(f(this,8,e,arguments[1]),52,8)},setInt8:function(e,t){p(this,1,e,s,t)},setUint8:function(e,t){p(this,1,e,s,t)},setInt16:function(e,t){p(this,2,e,a,t,arguments[2])},setUint16:function(e,t){p(this,2,e,a,t,arguments[2])},setInt32:function(e,t){p(this,4,e,c,t,arguments[2])},setUint32:function(e,t){p(this,4,e,c,t,arguments[2])},setFloat32:function(e,t){p(this,4,e,l,t,arguments[2])},setFloat64:function(e,t){p(this,8,e,u,t,arguments[2])}});O($,I),O(M,N),v(M[L],g.VIEW,!0),t[I]=$,t[N]=M},function(e,t,n){var r=n(38),i=n(37);e.exports=function(e){if(void 0===e)return 0;var t=r(e),n=i(t);if(t!==n)throw RangeError("Wrong length!");return n}},function(e,t,n){var r=n(8);r(r.G+r.W+r.F*!n(224).ABV,{DataView:n(225).DataView})},function(e,t,n){n(229)("Int8",1,function(e){return function(t,n,r){return e(this,t,n,r)}})},function(e,t,n){"use strict";if(n(6)){var r=n(28),i=n(4),o=n(7),s=n(8),a=n(224),c=n(225),u=n(20),l=n(206),h=n(17),f=n(10),p=n(214),d=n(38),y=n(37),m=n(226),g=n(39),v=n(16),b=n(5),x=n(74),_=n(13),S=n(57),w=n(163),E=n(45),k=n(58),A=n(49).f,C=n(165),O=n(19),I=n(25),N=n(173),L=n(36),P=n(208),T=n(194),$=n(129),M=n(166),j=n(193),R=n(189),F=n(186),D=n(11),B=n(50),G=D.f,q=B.f,U=i.RangeError,z=i.TypeError,V=i.Uint8Array,W="ArrayBuffer",J="Shared"+W,Y="BYTES_PER_ELEMENT",Z="prototype",H=Array[Z],K=c.ArrayBuffer,X=c.DataView,Q=N(0),ee=N(2),te=N(3),ne=N(4),re=N(5),ie=N(6),oe=L(!0),se=L(!1),ae=T.values,ce=T.keys,ue=T.entries,le=H.lastIndexOf,he=H.reduce,fe=H.reduceRight,pe=H.join,de=H.sort,ye=H.slice,me=H.toString,ge=H.toLocaleString,ve=I("iterator"),be=I("toStringTag"),xe=O("typed_constructor"),_e=O("def_constructor"),Se=a.CONSTR,we=a.TYPED,Ee=a.VIEW,ke="Wrong length!",Ae=N(1,function(e,t){return Le(P(e,e[_e]),t)}),Ce=o(function(){return 1===new V(new Uint16Array([1]).buffer)[0]}),Oe=!!V&&!!V[Z].set&&o(function(){new V(1).set({})}),Ie=function(e,t){var n=d(e);if(n<0||n%t)throw U("Wrong offset!");return n},Ne=function(e){if(_(e)&&we in e)return e;throw z(e+" is not a typed array!")},Le=function(e,t){if(!(_(e)&&xe in e))throw z("It is not a typed array constructor!");return new e(t)},Pe=function(e,t){return Te(P(e,e[_e]),t)},Te=function(e,t){for(var n=0,r=t.length,i=Le(e,r);r>n;)i[n]=t[n++];return i},$e=function(e,t,n){G(e,t,{get:function(){return this._d[n]}})},Me=function(e){var t,n,r,i,o,s,a=S(e),c=arguments.length,l=c>1?arguments[1]:void 0,h=void 0!==l,f=C(a);if(void 0!=f&&!w(f)){for(s=f.call(a),r=[],t=0;!(o=s.next()).done;t++)r.push(o.value);a=r}for(h&&c>2&&(l=u(l,arguments[2],2)),t=0,n=y(a.length),i=Le(this,n);n>t;t++)i[t]=h?l(a[t],t):a[t];return i},je=function(){for(var e=0,t=arguments.length,n=Le(this,t);t>e;)n[e]=arguments[e++];return n},Re=!!V&&o(function(){ge.call(new V(1))}),Fe=function(){return ge.apply(Re?ye.call(Ne(this)):Ne(this),arguments)},De={copyWithin:function(e,t){return F.call(Ne(this),e,t,arguments.length>2?arguments[2]:void 0)},every:function(e){return ne(Ne(this),e,arguments.length>1?arguments[1]:void 0)},fill:function(e){return R.apply(Ne(this),arguments)},filter:function(e){return Pe(this,ee(Ne(this),e,arguments.length>1?arguments[1]:void 0))},find:function(e){return re(Ne(this),e,arguments.length>1?arguments[1]:void 0)},findIndex:function(e){return ie(Ne(this),e,arguments.length>1?arguments[1]:void 0)},forEach:function(e){Q(Ne(this),e,arguments.length>1?arguments[1]:void 0)},indexOf:function(e){return se(Ne(this),e,arguments.length>1?arguments[1]:void 0)},includes:function(e){return oe(Ne(this),e,arguments.length>1?arguments[1]:void 0)},join:function(e){return pe.apply(Ne(this),arguments)},lastIndexOf:function(e){return le.apply(Ne(this),arguments)},map:function(e){return Ae(Ne(this),e,arguments.length>1?arguments[1]:void 0)},reduce:function(e){return he.apply(Ne(this),arguments)},reduceRight:function(e){return fe.apply(Ne(this),arguments)},reverse:function(){for(var e,t=this,n=Ne(t).length,r=Math.floor(n/2),i=0;i1?arguments[1]:void 0)},sort:function(e){return de.call(Ne(this),e)},subarray:function(e,t){var n=Ne(this),r=n.length,i=g(e,r);return new(P(n,n[_e]))(n.buffer,n.byteOffset+i*n.BYTES_PER_ELEMENT,y((void 0===t?r:g(t,r))-i))}},Be=function(e,t){return Pe(this,ye.call(Ne(this),e,t))},Ge=function(e){Ne(this);var t=Ie(arguments[1],1),n=this.length,r=S(e),i=y(r.length),o=0;if(i+t>n)throw U(ke);for(;o255?255:255&r),i.v[p](n*t+i.o,r,Ce)},I=function(e,t){G(e,t,{get:function(){return C(this,t)},set:function(e){return O(this,t,e); +},enumerable:!0})};b?(d=n(function(e,n,r,i){l(e,d,u,"_d");var o,s,a,c,h=0,p=0;if(_(n)){if(!(n instanceof K||(c=x(n))==W||c==J))return we in n?Te(d,n):Me.call(d,n);o=n,p=Ie(r,t);var g=n.byteLength;if(void 0===i){if(g%t)throw U(ke);if(s=g-p,s<0)throw U(ke)}else if(s=y(i)*t,s+p>g)throw U(ke);a=s/t}else a=m(n),s=a*t,o=new K(s);for(f(e,"_d",{b:o,o:p,l:s,e:a,v:new X(o)});h=n.length)return{value:void 0,done:!0};while(!((e=n[t._i++])in t._t));return{value:e,done:!1}}),r(r.S,"Reflect",{enumerate:function(e){return new o(e)}})},function(e,t,n){function r(e,t){var n,a,l=arguments.length<3?e:arguments[2];return u(e)===l?e[t]:(n=i.f(e,t))?s(n,"value")?n.value:void 0!==n.get?n.get.call(l):void 0:c(a=o(e))?r(a,t,l):void 0}var i=n(50),o=n(58),s=n(5),a=n(8),c=n(13),u=n(12);a(a.S,"Reflect",{get:r})},function(e,t,n){var r=n(50),i=n(8),o=n(12);i(i.S,"Reflect",{getOwnPropertyDescriptor:function(e,t){return r.f(o(e),t)}})},function(e,t,n){var r=n(8),i=n(58),o=n(12);r(r.S,"Reflect",{getPrototypeOf:function(e){return i(o(e))}})},function(e,t,n){var r=n(8);r(r.S,"Reflect",{has:function(e,t){return t in e}})},function(e,t,n){var r=n(8),i=n(12),o=Object.isExtensible;r(r.S,"Reflect",{isExtensible:function(e){return i(e),!o||o(e)}})},function(e,t,n){var r=n(8);r(r.S,"Reflect",{ownKeys:n(249)})},function(e,t,n){var r=n(49),i=n(42),o=n(12),s=n(4).Reflect;e.exports=s&&s.ownKeys||function(e){var t=r.f(o(e)),n=i.f;return n?t.concat(n(e)):t}},function(e,t,n){var r=n(8),i=n(12),o=Object.preventExtensions;r(r.S,"Reflect",{preventExtensions:function(e){i(e);try{return o&&o(e),!0}catch(e){return!1}}})},function(e,t,n){function r(e,t,n){var c,f,p=arguments.length<4?e:arguments[3],d=o.f(l(e),t);if(!d){if(h(f=s(e)))return r(f,t,n,p);d=u(0)}return a(d,"value")?!(d.writable===!1||!h(p))&&(c=o.f(p,t)||u(0),c.value=n,i.f(p,t,c),!0):void 0!==d.set&&(d.set.call(p,n),!0)}var i=n(11),o=n(50),s=n(58),a=n(5),c=n(8),u=n(17),l=n(12),h=n(13);c(c.S,"Reflect",{set:r})},function(e,t,n){var r=n(8),i=n(72);i&&r(r.S,"Reflect",{setPrototypeOf:function(e,t){i.check(e,t);try{return i.set(e,t),!0}catch(e){return!1}}})},function(e,t,n){"use strict";var r=n(8),i=n(36)(!0);r(r.P,"Array",{includes:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),n(187)("includes")},function(e,t,n){"use strict";var r=n(8),i=n(255),o=n(57),s=n(37),a=n(21),c=n(174);r(r.P,"Array",{flatMap:function(e){var t,n,r=o(this);return a(e),t=s(r.length),n=c(r,0),i(n,r,r,t,0,1,e,arguments[1]),n}}),n(187)("flatMap")},function(e,t,n){"use strict";function r(e,t,n,u,l,h,f,p){for(var d,y,m=l,g=0,v=!!f&&a(f,p,3);g0)m=r(e,t,d,s(d.length),m,h-1)-1;else{if(m>=9007199254740991)throw TypeError();e[m]=d}m++}g++}return m}var i=n(44),o=n(13),s=n(37),a=n(20),c=n(25)("isConcatSpreadable");e.exports=r},function(e,t,n){"use strict";var r=n(8),i=n(255),o=n(57),s=n(37),a=n(38),c=n(174);r(r.P,"Array",{flatten:function(){var e=arguments[0],t=o(this),n=s(t.length),r=c(t,0);return i(r,t,t,n,0,void 0===e?1:a(e)),r}}),n(187)("flatten")},function(e,t,n){"use strict";var r=n(8),i=n(127)(!0);r(r.P,"String",{at:function(e){return i(this,e)}})},function(e,t,n){"use strict";var r=n(8),i=n(259);r(r.P,"String",{padStart:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0,!0)}})},function(e,t,n){var r=n(37),i=n(90),o=n(35);e.exports=function(e,t,n,s){var a=String(o(e)),c=a.length,u=void 0===n?" ":String(n),l=r(t);if(l<=c||""==u)return a;var h=l-c,f=i.call(u,Math.ceil(h/u.length));return f.length>h&&(f=f.slice(0,h)),s?f+a:a+f}},function(e,t,n){"use strict";var r=n(8),i=n(259);r(r.P,"String",{padEnd:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0,!1)}})},function(e,t,n){"use strict";n(82)("trimLeft",function(e){return function(){return e(this,1)}},"trimStart")},function(e,t,n){"use strict";n(82)("trimRight",function(e){return function(){return e(this,2)}},"trimEnd")},function(e,t,n){"use strict";var r=n(8),i=n(35),o=n(37),s=n(134),a=n(197),c=RegExp.prototype,u=function(e,t){this._r=e,this._s=t};n(130)(u,"RegExp String",function(){var e=this._r.exec(this._s);return{value:e,done:null===e}}),r(r.P,"String",{matchAll:function(e){if(i(this),!s(e))throw TypeError(e+" is not a regexp!");var t=String(this),n="flags"in c?String(e.flags):a.call(e),r=new RegExp(e.source,~n.indexOf("g")?n:"g"+n);return r.lastIndex=o(e.lastIndex),new u(r,t)}})},function(e,t,n){n(27)("asyncIterator")},function(e,t,n){n(27)("observable")},function(e,t,n){var r=n(8),i=n(249),o=n(32),s=n(50),a=n(164);r(r.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,n,r=o(e),c=s.f,u=i(r),l={},h=0;u.length>h;)n=c(r,t=u[h++]),void 0!==n&&a(l,t,n);return l}})},function(e,t,n){var r=n(8),i=n(268)(!1);r(r.S,"Object",{values:function(e){return i(e)}})},function(e,t,n){var r=n(30),i=n(32),o=n(43).f;e.exports=function(e){return function(t){for(var n,s=i(t),a=r(s),c=a.length,u=0,l=[];c>u;)o.call(s,n=a[u++])&&l.push(e?[n,s[n]]:s[n]);return l}}},function(e,t,n){var r=n(8),i=n(268)(!0);r(r.S,"Object",{entries:function(e){return i(e)}})},function(e,t,n){"use strict";var r=n(8),i=n(57),o=n(21),s=n(11);n(6)&&r(r.P+n(271),"Object",{__defineGetter__:function(e,t){s.f(i(this),e,{get:o(t),enumerable:!0,configurable:!0})}})},function(e,t,n){"use strict";e.exports=n(28)||!n(7)(function(){var e=Math.random();__defineSetter__.call(null,e,function(){}),delete n(4)[e]})},function(e,t,n){"use strict";var r=n(8),i=n(57),o=n(21),s=n(11);n(6)&&r(r.P+n(271),"Object",{__defineSetter__:function(e,t){s.f(i(this),e,{set:o(t),enumerable:!0,configurable:!0})}})},function(e,t,n){"use strict";var r=n(8),i=n(57),o=n(16),s=n(58),a=n(50).f;n(6)&&r(r.P+n(271),"Object",{__lookupGetter__:function(e){var t,n=i(this),r=o(e,!0);do if(t=a(n,r))return t.get;while(n=s(n))}})},function(e,t,n){"use strict";var r=n(8),i=n(57),o=n(16),s=n(58),a=n(50).f;n(6)&&r(r.P+n(271),"Object",{__lookupSetter__:function(e){var t,n=i(this),r=o(e,!0);do if(t=a(n,r))return t.set;while(n=s(n))}})},function(e,t,n){var r=n(8);r(r.P+r.R,"Map",{toJSON:n(276)("Map")})},function(e,t,n){var r=n(74),i=n(277);e.exports=function(e){return function(){if(r(this)!=e)throw TypeError(e+"#toJSON isn't generic");return i(this)}}},function(e,t,n){var r=n(207);e.exports=function(e,t){var n=[];return r(e,!1,n.push,n,t),n}},function(e,t,n){var r=n(8);r(r.P+r.R,"Set",{toJSON:n(276)("Set")})},function(e,t,n){n(280)("Map")},function(e,t,n){"use strict";var r=n(8);e.exports=function(e){r(r.S,e,{of:function(){for(var e=arguments.length,t=Array(e);e--;)t[e]=arguments[e];return new this(t)}})}},function(e,t,n){n(280)("Set")},function(e,t,n){n(280)("WeakMap")},function(e,t,n){n(280)("WeakSet")},function(e,t,n){n(285)("Map")},function(e,t,n){"use strict";var r=n(8),i=n(21),o=n(20),s=n(207);e.exports=function(e){r(r.S,e,{from:function(e){var t,n,r,a,c=arguments[1];return i(this),t=void 0!==c,t&&i(c),void 0==e?new this:(n=[],t?(r=0,a=o(c,arguments[2],2),s(e,!1,function(e){n.push(a(e,r++))})):s(e,!1,n.push,n),new this(n))}})}},function(e,t,n){n(285)("Set")},function(e,t,n){n(285)("WeakMap")},function(e,t,n){n(285)("WeakSet")},function(e,t,n){var r=n(8);r(r.G,{global:n(4)})},function(e,t,n){var r=n(8);r(r.S,"System",{global:n(4)})},function(e,t,n){var r=n(8),i=n(34);r(r.S,"Error",{isError:function(e){return"Error"===i(e)}})},function(e,t,n){var r=n(8);r(r.S,"Math",{clamp:function(e,t,n){return Math.min(n,Math.max(t,e))}})},function(e,t,n){var r=n(8);r(r.S,"Math",{DEG_PER_RAD:Math.PI/180})},function(e,t,n){var r=n(8),i=180/Math.PI;r(r.S,"Math",{degrees:function(e){return e*i}})},function(e,t,n){var r=n(8),i=n(296),o=n(113);r(r.S,"Math",{fscale:function(e,t,n,r,s){return o(i(e,t,n,r,s))}})},function(e,t){e.exports=Math.scale||function(e,t,n,r,i){return 0===arguments.length||e!=e||t!=t||n!=n||r!=r||i!=i?NaN:e===1/0||e===-(1/0)?e:(e-t)*(i-r)/(n-t)+r}},function(e,t,n){var r=n(8);r(r.S,"Math",{iaddh:function(e,t,n,r){var i=e>>>0,o=t>>>0,s=n>>>0;return o+(r>>>0)+((i&s|(i|s)&~(i+s>>>0))>>>31)|0}})},function(e,t,n){var r=n(8);r(r.S,"Math",{isubh:function(e,t,n,r){var i=e>>>0,o=t>>>0,s=n>>>0;return o-(r>>>0)-((~i&s|~(i^s)&i-s>>>0)>>>31)|0}})},function(e,t,n){var r=n(8);r(r.S,"Math",{imulh:function(e,t){var n=65535,r=+e,i=+t,o=r&n,s=i&n,a=r>>16,c=i>>16,u=(a*s>>>0)+(o*s>>>16);return a*c+(u>>16)+((o*c>>>0)+(u&n)>>16)}})},function(e,t,n){var r=n(8);r(r.S,"Math",{RAD_PER_DEG:180/Math.PI})},function(e,t,n){var r=n(8),i=Math.PI/180;r(r.S,"Math",{radians:function(e){return e*i}})},function(e,t,n){var r=n(8);r(r.S,"Math",{scale:n(296)})},function(e,t,n){var r=n(8);r(r.S,"Math",{umulh:function(e,t){var n=65535,r=+e,i=+t,o=r&n,s=i&n,a=r>>>16,c=i>>>16,u=(a*s>>>0)+(o*s>>>16);return a*c+(u>>>16)+((o*c>>>0)+(u&n)>>>16)}})},function(e,t,n){var r=n(8);r(r.S,"Math",{signbit:function(e){return(e=+e)!=e?e:0==e?1/e==1/0:e>0}})},function(e,t,n){"use strict";var r=n(8),i=n(9),o=n(4),s=n(208),a=n(213);r(r.P+r.R,"Promise",{finally:function(e){var t=s(this,i.Promise||o.Promise),n="function"==typeof e;return this.then(n?function(n){return a(t,e()).then(function(){return n})}:e,n?function(n){return a(t,e()).then(function(){throw n})}:e)}})},function(e,t,n){"use strict";var r=n(8),i=n(211),o=n(212);r(r.S,"Promise",{try:function(e){var t=i.f(this),n=o(e);return(n.e?t.reject:t.resolve)(n.v),t.promise}})},function(e,t,n){var r=n(308),i=n(12),o=r.key,s=r.set;r.exp({defineMetadata:function(e,t,n,r){s(e,t,i(n),o(r))}})},function(e,t,n){var r=n(215),i=n(8),o=n(23)("metadata"),s=o.store||(o.store=new(n(220))),a=function(e,t,n){var i=s.get(e);if(!i){if(!n)return;s.set(e,i=new r)}var o=i.get(t);if(!o){if(!n)return;i.set(t,o=new r)}return o},c=function(e,t,n){var r=a(t,n,!1);return void 0!==r&&r.has(e)},u=function(e,t,n){var r=a(t,n,!1);return void 0===r?void 0:r.get(e)},l=function(e,t,n,r){a(n,r,!0).set(e,t)},h=function(e,t){var n=a(e,t,!1),r=[];return n&&n.forEach(function(e,t){r.push(t)}),r},f=function(e){return void 0===e||"symbol"==typeof e?e:String(e)},p=function(e){i(i.S,"Reflect",e)};e.exports={store:s,map:a,has:c,get:u,set:l,keys:h,key:f,exp:p}},function(e,t,n){var r=n(308),i=n(12),o=r.key,s=r.map,a=r.store;r.exp({deleteMetadata:function(e,t){var n=arguments.length<3?void 0:o(arguments[2]),r=s(i(t),n,!1);if(void 0===r||!r.delete(e))return!1;if(r.size)return!0;var c=a.get(t);return c.delete(n),!!c.size||a.delete(t)}})},function(e,t,n){var r=n(308),i=n(12),o=n(58),s=r.has,a=r.get,c=r.key,u=function(e,t,n){var r=s(e,t,n);if(r)return a(e,t,n);var i=o(t);return null!==i?u(e,i,n):void 0};r.exp({getMetadata:function(e,t){return u(e,i(t),arguments.length<3?void 0:c(arguments[2]))}})},function(e,t,n){var r=n(219),i=n(277),o=n(308),s=n(12),a=n(58),c=o.keys,u=o.key,l=function(e,t){var n=c(e,t),o=a(e);if(null===o)return n;var s=l(o,t);return s.length?n.length?i(new r(n.concat(s))):s:n};o.exp({getMetadataKeys:function(e){return l(s(e),arguments.length<2?void 0:u(arguments[1]))}})},function(e,t,n){var r=n(308),i=n(12),o=r.get,s=r.key;r.exp({getOwnMetadata:function(e,t){return o(e,i(t),arguments.length<3?void 0:s(arguments[2]))}})},function(e,t,n){var r=n(308),i=n(12),o=r.keys,s=r.key;r.exp({getOwnMetadataKeys:function(e){return o(i(e),arguments.length<2?void 0:s(arguments[1]))}})},function(e,t,n){var r=n(308),i=n(12),o=n(58),s=r.has,a=r.key,c=function(e,t,n){var r=s(e,t,n);if(r)return!0;var i=o(t);return null!==i&&c(e,i,n)};r.exp({hasMetadata:function(e,t){return c(e,i(t),arguments.length<3?void 0:a(arguments[2]))}})},function(e,t,n){var r=n(308),i=n(12),o=r.has,s=r.key;r.exp({hasOwnMetadata:function(e,t){return o(e,i(t),arguments.length<3?void 0:s(arguments[2]))}})},function(e,t,n){var r=n(308),i=n(12),o=n(21),s=r.key,a=r.set;r.exp({metadata:function(e,t){return function(n,r){a(e,t,(void 0!==r?i:o)(n),s(r))}}})},function(e,t,n){var r=n(8),i=n(210)(),o=n(4).process,s="process"==n(34)(o);r(r.G,{asap:function(e){var t=s&&o.domain;i(t?t.bind(e):e)}})},function(e,t,n){"use strict";var r=n(8),i=n(4),o=n(9),s=n(210)(),a=n(25)("observable"),c=n(21),u=n(12),l=n(206),h=n(214),f=n(10),p=n(207),d=p.RETURN,y=function(e){return null==e?void 0:c(e)},m=function(e){var t=e._c;t&&(e._c=void 0,t())},g=function(e){return void 0===e._o},v=function(e){g(e)||(e._o=void 0,m(e))},b=function(e,t){u(e),this._c=void 0,this._o=e,e=new x(this);try{var n=t(e),r=n;null!=n&&("function"==typeof n.unsubscribe?n=function(){r.unsubscribe()}:c(n),this._c=n)}catch(t){return void e.error(t)}g(this)&&m(this)};b.prototype=h({},{unsubscribe:function(){v(this)}});var x=function(e){this._s=e};x.prototype=h({},{next:function(e){var t=this._s;if(!g(t)){var n=t._o;try{var r=y(n.next);if(r)return r.call(n,e)}catch(e){try{v(t)}finally{throw e}}}},error:function(e){var t=this._s;if(g(t))throw e;var n=t._o;t._o=void 0;try{var r=y(n.error);if(!r)throw e;e=r.call(n,e)}catch(e){try{m(t)}finally{throw e}}return m(t),e},complete:function(e){var t=this._s;if(!g(t)){var n=t._o;t._o=void 0;try{var r=y(n.complete);e=r?r.call(n,e):void 0}catch(e){try{m(t)}finally{throw e}}return m(t),e}}});var _=function(e){l(this,_,"Observable","_f")._f=c(e)};h(_.prototype,{subscribe:function(e){return new b(e,this._f)},forEach:function(e){var t=this;return new(o.Promise||i.Promise)(function(n,r){c(e);var i=t.subscribe({next:function(t){try{return e(t)}catch(e){r(e),i.unsubscribe()}},error:r,complete:n})})}}),h(_,{from:function(e){var t="function"==typeof this?this:_,n=y(u(e)[a]);if(n){var r=u(n.call(e));return r.constructor===t?r:new t(function(e){return r.subscribe(e)})}return new t(function(t){var n=!1;return s(function(){if(!n){try{if(p(e,!1,function(e){if(t.next(e),n)return d})===d)return}catch(e){if(n)throw e;return void t.error(e)}t.complete()}}),function(){n=!0}})},of:function(){for(var e=0,t=arguments.length,n=Array(t);e2,i=!!r&&s.call(arguments,2);return e(r?function(){("function"==typeof t?t:Function(t)).apply(this,i)}:t,n)}};i(i.G+i.B+i.F*a,{setTimeout:c(r.setTimeout),setInterval:c(r.setInterval)})},function(e,t,n){var r=n(8),i=n(209);r(r.G+r.B,{setImmediate:i.set,clearImmediate:i.clear})},function(e,t,n){for(var r=n(194),i=n(30),o=n(18),s=n(4),a=n(10),c=n(129),u=n(25),l=u("iterator"),h=u("toStringTag"),f=c.Array,p={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},d=i(p),y=0;y=0;--r){var i=this.tryEntries[r],o=i.completion;if("root"===i.tryLoc)return t("end");if(i.tryLoc<=this.prev){var s=v.call(i,"catchLoc"),a=v.call(i,"finallyLoc");if(s&&a){if(this.prev=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&v.call(r,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),f(n),I}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;f(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:d(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=m),I}}}("object"==typeof t?t:"object"==typeof window?window:"object"==typeof self?self:this)}).call(t,function(){return this}())},function(e,t,n){n(324),e.exports=n(9).RegExp.escape},function(e,t,n){var r=n(8),i=n(325)(/[\\^$*+?.()|[\]{}]/g,"\\$&");r(r.S,"RegExp",{escape:function(e){return i(e)}})},function(e,t){e.exports=function(e,t){var n=t===Object(t)?function(e){return t[e]}:t;return function(t){return String(t).replace(e,n)}}},function(e,t,n){"use strict";e.exports=n(327)},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=function(){function e(e,t){for(var n=0;n1||t[0]instanceof c.Shortcut)){e.next=17;break}if(n=t.filter(function(e){return"ConditionalDialogOptionNode"!==e.type||o.evaluateExpressionOrLiteral(e.conditionalExpression)}),0!==n.length){e.next=4;break}return e.abrupt("return");case 4:return r=new s.OptionsResult(n.map(function(e){return e.text})),e.next=7,r;case 7:if(r.selected===-1){e.next=15;break}if(i=n[r.selected],!i.content){e.next=13;break}return e.delegateYield(this.evalNodes(i.content),"t0",11);case 11:e.next=15;break;case 13:if(!i.identifier){e.next=15;break}return e.delegateYield(this.run(i.identifier),"t1",15);case 15:e.next=18;break;case 17:return e.delegateYield(this.run(t[0].identifier),"t2",18);case 18:case"end":return e.stop()}},e,this)})},{key:"evaluateAssignment",value:function(e){var t=this.evaluateExpressionOrLiteral(e.expression),n=this.variables.get(e.variableName);if("SetVariableAddNode"===e.type)t+=n;else if("SetVariableMinusNode"===e.type)t-=n;else if("SetVariableMultiplyNode"===e.type)t*=n;else if("SetVariableDivideNode"===e.type)t/=n;else if("SetVariableEqualToNode"!==e.type)throw new Error("I don't recognize assignment type "+e.type);this.variables.set(e.variableName,t)}},{key:"evaluateConditional",value:function(e){if("IfNode"===e.type){if(this.evaluateExpressionOrLiteral(e.expression))return e.statement}else if("IfElseNode"===e.type||"ElseIfNode"===e.type){if(this.evaluateExpressionOrLiteral(e.expression))return e.statement;if(e.elseStatement)return this.evaluateConditional(e.elseStatement)}else if("ElseNode"===e.type)return e.statement;return null}},{key:"evaluateExpressionOrLiteral",value:function(e){if(e instanceof c.Expression){if("UnaryMinusExpressionNode"===e.type)return-1*this.evaluateExpressionOrLiteral(e.expression);if("ArithmeticExpressionNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression);if("ArithmeticExpressionAddNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)+this.evaluateExpressionOrLiteral(e.expression2);if("ArithmeticExpressionMinusNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)-this.evaluateExpressionOrLiteral(e.expression2);if("ArithmeticExpressionMultiplyNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)*this.evaluateExpressionOrLiteral(e.expression2);if("ArithmeticExpressionDivideNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)/this.evaluateExpressionOrLiteral(e.expression2);if("BooleanExpressionNode"===e.type)return this.evaluateExpressionOrLiteral(e.booleanExpression);if("NegatedBooleanExpressionNode"===e.type)return!this.evaluateExpressionOrLiteral(e.booleanExpression);if("BooleanOrExpressionNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)||this.evaluateExpressionOrLiteral(e.expression2);if("BooleanAndExpressionNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)&&this.evaluateExpressionOrLiteral(e.expression2);if("BooleanXorExpressionNode"===e.type)return!this.evaluateExpressionOrLiteral(e.expression1)!=!this.evaluateExpressionOrLiteral(e.expression2); +if("EqualToExpressionNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)===this.evaluateExpressionOrLiteral(e.expression2);if("NotEqualToExpressionNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)!==this.evaluateExpressionOrLiteral(e.expression2);if("GreaterThanExpressionNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)>this.evaluateExpressionOrLiteral(e.expression2);if("GreaterThanOrEqualToExpressionNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1)>=this.evaluateExpressionOrLiteral(e.expression2);if("LessThanExpressionNode"===e.type)return this.evaluateExpressionOrLiteral(e.expression1) .label > .name:val("_token_stack"))',n);return i[0].body=r,escodegen.generate(n).replace(/_token_stack:\s?/,"").replace(/\\\\n/g,"\\n")}catch(e){return t}}function tokenStackLex(){var e;return e=tstack.pop()||lexer.lex()||EOF,"number"!=typeof e&&(e instanceof Array&&(tstack=e,e=tstack.pop()),e=self.symbols_[e]||e),e}function removeErrorRecovery(e){var t=e;try{var n=esprima.parse(t),r=JSONSelect.match(':has(:root > .label > .name:val("_handle_error"))',n),i=r[0].body.consequent.body[3].consequent.body;return i[0]=r[0].body.consequent.body[1],i[4].expression.arguments[1].properties.pop(),r[0].body.consequent.body=i,escodegen.generate(n).replace(/_handle_error:\s?/,"").replace(/\\\\n/g,"\\n")}catch(e){return t}}function createVariable(){var e=nextVariableId++,t="$V";do t+=variableTokens[e%variableTokensLength],e=~~(e/variableTokensLength);while(0!==e);return t}function commonjsMain(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),process.exit(1));var t=__webpack_require__(336).readFileSync(__webpack_require__(337).normalize(e[1]),"utf8");return exports.parser.parse(t)}function printAction(e,t){var n=1==e[0]?"shift token (then go to state "+e[1]+")":2==e[0]?"reduce by rule: "+t.productions[e[1]]:"accept";return n}function traceParseError(e,t){this.trace(e)}function parseError(e,t){if(!t.recoverable){var n=new Error(e);throw n.hash=t,n}this.trace(e)}var Nonterminal=typal.construct({constructor:function(e){this.symbol=e,this.productions=new Set,this.first=[],this.follows=[],this.nullable=!1},toString:function(){var e=this.symbol+"\n";return e+=this.nullable?"nullable":"not nullable",e+="\nFirsts: "+this.first.join(", "),e+="\nFollows: "+this.first.join(", "),e+="\nProductions:\n "+this.productions.join("\n ")}}),Production=typal.construct({constructor:function(e,t,n){this.symbol=e,this.handle=t,this.nullable=!1,this.id=n,this.first=[],this.precedence=0},toString:function(){return this.symbol+" -> "+this.handle.join(" ")}}),generator=typal.beget();generator.constructor=function(e,t){"string"==typeof e&&(e=ebnfParser.parse(e));var n=typal.mix.call({},e.options,t);this.terms={},this.operators={},this.productions=[],this.conflicts=0,this.resolutions=[],this.options=n,this.parseParams=e.parseParams,this.yy={},e.actionInclude&&("function"==typeof e.actionInclude&&(e.actionInclude=String(e.actionInclude).replace(/^\s*function \(\) \{/,"").replace(/\}\s*$/,"")),this.actionInclude=e.actionInclude),this.moduleInclude=e.moduleInclude||"",this.DEBUG=n.debug||!1,this.DEBUG&&this.mix(generatorDebug),this.processGrammar(e),e.lex&&(this.lexer=new Lexer(e.lex,null,this.terminals_))},generator.processGrammar=function(e){var t=e.bnf,n=e.tokens,r=this.nonterminals={},i=this.productions,o=this;!e.bnf&&e.ebnf&&(t=e.bnf=ebnfParser.transform(e.ebnf)),n&&(n="string"==typeof n?n.trim().split(" "):n.slice(0));var s=this.symbols=[],a=this.operators=processOperators(e.operators);this.buildProductions(t,i,r,s,a),n&&this.terminals.length!==n.length&&(o.trace("Warning: declared tokens differ from tokens found in rules."),o.trace(this.terminals),o.trace(n)),this.augmentGrammar(e)},generator.augmentGrammar=function(e){if(0===this.productions.length)throw new Error("Grammar error: must have at least one rule.");if(this.startSymbol=e.start||e.startSymbol||this.productions[0].symbol,!this.nonterminals[this.startSymbol])throw new Error("Grammar error: startSymbol must be a non-terminal found in your grammar.");this.EOF="$end";var t=new Production("$accept",[this.startSymbol,"$end"],0);this.productions.unshift(t),this.symbols.unshift("$accept",this.EOF),this.symbols_.$accept=0,this.symbols_[this.EOF]=1,this.terminals.unshift(this.EOF),this.nonterminals.$accept=new Nonterminal("$accept"),this.nonterminals.$accept.productions.push(t),this.nonterminals[this.startSymbol].follows.push(this.EOF)},generator.buildProductions=function(e,t,n,r,i){function o(e){e&&!p[e]&&(p[e]=++f,r.push(e))}function s(e){var r,s,a;if(e.constructor===Array){for(s="string"==typeof e[0]?e[0].trim().split(" "):e[0].slice(0),a=0;a=0;a--)!(r.handle[a]in n)&&r.handle[a]in i&&(r.precedence=i[r.handle[a]].precedence);t.push(r),h.push([p[r.symbol],""===r.handle[0]?0:r.handle.length]),n[c].productions.push(r)}var a,c,u=["/* this == yyval */",this.actionInclude||"","var $0 = $$.length - 1;","switch (yystate) {"],l={},h=[0],f=1,p={},d=!1;o("error");for(c in e)e.hasOwnProperty(c)&&(o(c),n[c]=new Nonterminal(c),a="string"==typeof e[c]?e[c].split(/\s*\|\s*/g):e[c].slice(0),a.forEach(s));for(var y in l)u.push(l[y].join(" "),y,"break;");var m=[],g={};each(p,function(e,t){n[t]||(m.push(t),g[e]=t)}),this.hasErrorRecovery=d,this.terminals=m,this.terminals_=g,this.symbols_=p,this.productions_=h,u.push("}"),u=u.join("\n").replace(/YYABORT/g,"return false").replace(/YYACCEPT/g,"return true");var v="yytext, yyleng, yylineno, yy, yystate /* action[1] */, $$ /* vstack */, _$ /* lstack */";this.parseParams&&(v+=", "+this.parseParams.join(", ")),this.performAction="function anonymous("+v+") {\n"+u+"\n}"},generator.createParser=function(){throw new Error("Calling abstract method.")},generator.trace=function(){},generator.warn=function(){var e=Array.prototype.slice.call(arguments,0);Jison.print.call(null,e.join(""))},generator.error=function(e){throw new Error(e)};var generatorDebug={trace:function(){Jison.print.apply(null,arguments)},beforeprocessGrammar:function(){this.trace("Processing grammar.")},afteraugmentGrammar:function(){var e=this.trace;each(this.symbols,function(t,n){e(t+"("+n+")")})}},lookaheadMixin={};lookaheadMixin.computeLookaheads=function(){this.DEBUG&&this.mix(lookaheadDebug),this.computeLookaheads=function(){},this.nullableSets(),this.firstSets(),this.followSets()},lookaheadMixin.followSets=function(){for(var e=this.productions,t=this.nonterminals,n=this,r=!0;r;)r=!1,e.forEach(function(e,i){for(var o,s,a,c=!!n.go_,u=[],l=0;a=e.handle[l];++l)if(t[a]){c&&(o=n.go_(e.symbol,e.handle.slice(0,l)));var h=!c||o===parseInt(n.nterms_[a],10);if(l===e.handle.length+1&&h)u=t[e.symbol].follows;else{var f=e.handle.slice(l+1);u=n.first(f),n.nullable(f)&&h&&u.push.apply(u,t[e.symbol].follows)}s=t[a].follows.length,Set.union(t[a].follows,u),s!==t[a].follows.length&&(r=!0)}})},lookaheadMixin.first=function(e){if(""===e)return[];if(e instanceof Array){for(var t,n=[],r=0;(t=e[r])&&(this.nonterminals[t]?Set.union(n,this.nonterminals[t].first):n.indexOf(t)===-1&&n.push(t),this.nullable(t));++r);return n}return this.nonterminals[e]?this.nonterminals[e].first:[e]},lookaheadMixin.firstSets=function(){for(var e,t,n=this.productions,r=this.nonterminals,i=this,o=!0;o;){o=!1,n.forEach(function(e,t){var n=i.first(e.handle);n.length!==e.first.length&&(e.first=n,o=!0)});for(e in r)t=[],r[e].productions.forEach(function(e){Set.union(t,e.first)}),t.length!==r[e].first.length&&(r[e].first=t,o=!0)}},lookaheadMixin.nullableSets=function(){for(var e=(this.firsts={},this.nonterminals),t=this,n=!0;n;){n=!1,this.productions.forEach(function(e,r){if(!e.nullable){for(var i,o=0,s=0;i=e.handle[o];++o)t.nullable(i)&&s++;s===o&&(e.nullable=n=!0)}});for(var r in e)if(!this.nullable(r))for(var i,o=0;i=e[r].productions.item(o);o++)i.nullable&&(e[r].nullable=n=!0)}},lookaheadMixin.nullable=function(e){if(""===e)return!0;if(e instanceof Array){for(var t,n=0;t=e[n];++n)if(!this.nullable(t))return!1;return!0}return!!this.nonterminals[e]&&this.nonterminals[e].nullable};var lookaheadDebug={beforenullableSets:function(){this.trace("Computing Nullable sets.")},beforefirstSets:function(){this.trace("Computing First sets.")},beforefollowSets:function(){this.trace("Computing Follow sets.")},afterfollowSets:function(){var e=this.trace;each(this.nonterminals,function(t,n){e(t,"\n")})}},lrGeneratorMixin={};lrGeneratorMixin.buildTable=function(){this.DEBUG&&this.mix(lrGeneratorDebug),this.states=this.canonicalCollection(),this.table=this.parseTable(this.states),this.defaultActions=findDefaults(this.table)},lrGeneratorMixin.Item=typal.construct({constructor:function(e,t,n,r){this.production=e,this.dotPosition=t||0,this.follows=n||[],this.predecessor=r,this.id=parseInt(e.id+"a"+this.dotPosition,36),this.markedSymbol=this.production.handle[this.dotPosition]},remainingHandle:function(){return this.production.handle.slice(this.dotPosition+1)},eq:function(e){return e.id===this.id},handleToString:function(){var e=this.production.handle.slice(0);return e[this.dotPosition]="."+(e[this.dotPosition]||""),e.join(" ")},toString:function(){var e=this.production.handle.slice(0);return e[this.dotPosition]="."+(e[this.dotPosition]||""),this.production.symbol+" -> "+e.join(" ")+(0===this.follows.length?"":" #lookaheads= "+this.follows.join(" "))}}),lrGeneratorMixin.ItemSet=Set.prototype.construct({afterconstructor:function(){this.reductions=[],this.goes={},this.edges={},this.shifts=!1,this.inadequate=!1,this.hash_={};for(var e=this._items.length-1;e>=0;e--)this.hash_[this._items[e].id]=!0},concat:function(e){for(var t=e._items||e,n=t.length-1;n>=0;n--)this.hash_[t[n].id]=!0;return this._items.push.apply(this._items,t),this},push:function(e){return this.hash_[e.id]=!0,this._items.push(e)},contains:function(e){return this.hash_[e.id]},valueOf:function(){var e=this._items.map(function(e){return e.id}).sort().join("|");return this.valueOf=function(){return e},e}}),lrGeneratorMixin.closureOperation=function(e){var t,n=new this.ItemSet,r=this,i=e,o={};do t=new Set,n.concat(i),i.forEach(function(e){var i=e.markedSymbol;i&&r.nonterminals[i]?o[i]||(r.nonterminals[i].productions.forEach(function(e){var i=new r.Item(e,0);n.contains(i)||t.push(i)}),o[i]=!0):i?(n.shifts=!0,n.inadequate=n.reductions.length>0):(n.reductions.push(e),n.inadequate=n.reductions.length>1||n.shifts)}),i=t;while(!t.isEmpty());return n},lrGeneratorMixin.gotoOperation=function(e,t){var n=new this.ItemSet,r=this;return e.forEach(function(e,i){e.markedSymbol===t&&n.push(new r.Item(e.production,e.dotPosition+1,e.follows,i))}),n.isEmpty()?n:this.closureOperation(n)},lrGeneratorMixin.canonicalCollection=function(){var e,t=new this.Item(this.productions[0],0,[this.EOF]),n=this.closureOperation(new this.ItemSet(t)),r=new Set(n),i=0,o=this;for(r.has={},r.has[n]=0;i!==r.size();)e=r.item(i),i++,e.forEach(function(t){t.markedSymbol&&t.markedSymbol!==o.EOF&&o.canonicalCollectionInsert(t.markedSymbol,e,r,i-1)});return r},lrGeneratorMixin.canonicalCollectionInsert=function(e,t,n,r){var i=this.gotoOperation(t,e);if(i.predecessors||(i.predecessors={}),!i.isEmpty()){var o=i.valueOf(),s=n.has[o];s===-1||"undefined"==typeof s?(n.has[o]=n.size(),t.edges[e]=n.size(),n.push(i),i.predecessors[e]=[r]):(t.edges[e]=s,n.item(s).predecessors[e].push(r))}};var NONASSOC=0;lrGeneratorMixin.parseTable=function(e){var t=[],n=this.nonterminals,r=this.operators,i={},o=this,s=1,a=2,c=3;return e.forEach(function(e,u){var l,h,f=t[u]={};for(h in e.edges)e.forEach(function(t,r){if(t.markedSymbol==h){var i=e.edges[h];n[h]?f[o.symbols_[h]]=i:f[o.symbols_[h]]=[s,i]}});e.forEach(function(e,t){e.markedSymbol==o.EOF&&(f[o.symbols_[o.EOF]]=[c])});var p=!o.lookAheads&&o.terminals;e.reductions.forEach(function(t,n){var s=p||o.lookAheads(e,t);s.forEach(function(e){l=f[o.symbols_[e]];var n=r[e];if(l||l&&l.length){var s=resolveConflict(t.production,n,[a,t.production.id],l[0]instanceof Array?l[0]:l);o.resolutions.push([u,e,s]),s.bydefault?(o.conflicts++,o.DEBUG||(o.warn("Conflict in grammar: multiple actions possible when lookahead token is ",e," in state ",u,"\n- ",printAction(s.r,o),"\n- ",printAction(s.s,o)),i[u]=!0),o.options.noDefaultResolve&&(l[0]instanceof Array||(l=[l]),l.push(s.r))):l=s.action}else l=[a,t.production.id];l&&l.length?f[o.symbols_[e]]=l:l===NONASSOC&&(f[o.symbols_[e]]=void 0)})})}),!o.DEBUG&&o.conflicts>0&&(o.warn("\nStates with conflicts:"),each(i,function(t,n){o.warn("State "+n),o.warn(" ",e.item(n).join("\n "))})),t},lrGeneratorMixin.generate=function(e){e=typal.mix.call({},this.options,e);var t="";switch(e.moduleName&&e.moduleName.match(/^[A-Za-z_$][A-Za-z0-9_$]*$/)||(e.moduleName="parser"),e.moduleType){case"js":t=this.generateModule(e);break;case"amd":t=this.generateAMDModule(e);break;default:t=this.generateCommonJSModule(e)}return t},lrGeneratorMixin.generateAMDModule=function(e){e=typal.mix.call({},this.options,e);var t=this.generateModule_(),n="\n\ndefine(function(require){\n"+t.commonCode+"\nvar parser = "+t.moduleCode+"\n"+this.moduleInclude+(this.lexer&&this.lexer.generateModule?"\n"+this.lexer.generateModule()+"\nparser.lexer = lexer;":"")+"\nreturn parser;\n});";return n},lrGeneratorMixin.generateCommonJSModule=function(e){e=typal.mix.call({},this.options,e);var t=e.moduleName||"parser",n=this.generateModule(e)+"\n\n\nif (typeof require !== 'undefined' && typeof exports !== 'undefined') {\nexports.parser = "+t+";\nexports.Parser = "+t+".Parser;\nexports.parse = function () { return "+t+".parse.apply("+t+", arguments); };\nexports.main = "+String(e.moduleMain||commonjsMain)+";\nif (typeof module !== 'undefined' && require.main === module) {\n exports.main(process.argv.slice(1));\n}\n}";return n},lrGeneratorMixin.generateModule=function(e){e=typal.mix.call({},this.options,e);var t=e.moduleName||"parser",n="/* parser generated by jison "+version+" */\n/*\n Returns a Parser object of the following structure:\n\n Parser: {\n yy: {}\n }\n\n Parser.prototype: {\n yy: {},\n trace: function(),\n symbols_: {associative list: name ==> number},\n terminals_: {associative list: number ==> name},\n productions_: [...],\n performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$),\n table: [...],\n defaultActions: {...},\n parseError: function(str, hash),\n parse: function(input),\n\n lexer: {\n EOF: 1,\n parseError: function(str, hash),\n setInput: function(input),\n input: function(),\n unput: function(str),\n more: function(),\n less: function(n),\n pastInput: function(),\n upcomingInput: function(),\n showPosition: function(),\n test_match: function(regex_match_array, rule_index),\n next: function(),\n lex: function(),\n begin: function(condition),\n popState: function(),\n _currentRules: function(),\n topState: function(),\n pushState: function(condition),\n\n options: {\n ranges: boolean (optional: true ==> token location info will include a .range[] member)\n flex: boolean (optional: true ==> flex-like lexing behaviour where the rules are tested exhaustively to find the longest match)\n backtrack_lexer: boolean (optional: true ==> lexer regexes are tested in order and for each matching regex the action code is invoked; the lexer terminates the scan when a token is returned by the action code)\n },\n\n performAction: function(yy, yy_, $avoiding_name_collisions, YY_START),\n rules: [...],\n conditions: {associative list: name ==> set},\n }\n }\n\n\n token location info (@$, _$, etc.): {\n first_line: n,\n last_line: n,\n first_column: n,\n last_column: n,\n range: [start_number, end_number] (where the numbers are indexes into the input string, regular zero-based)\n }\n\n\n the parseError function receives a 'hash' object with these members for lexer and parser errors: {\n text: (matched text)\n token: (the produced terminal token, if any)\n line: (yylineno)\n }\n while parser (grammar) errors will also provide these members, i.e. parser errors deliver a superset of attributes: {\n loc: (yylloc)\n expected: (string describing the set of expected tokens)\n recoverable: (boolean: TRUE when the parser has a error recovery rule available for this particular error)\n }\n*/\n";return n+=(t.match(/\./)?t:"var "+t)+" = "+this.generateModuleExpr()},lrGeneratorMixin.generateModuleExpr=function(){var e="",t=this.generateModule_();return e+="(function(){\n",e+=t.commonCode,e+="\nvar parser = "+t.moduleCode,e+="\n"+this.moduleInclude,this.lexer&&this.lexer.generateModule&&(e+=this.lexer.generateModule(),e+="\nparser.lexer = lexer;"),e+="\nfunction Parser () {\n this.yy = {};\n}\nParser.prototype = parser;parser.Parser = Parser;\nreturn new Parser;\n})();"},lrGeneratorMixin.generateModule_=function(){var e=String(parser.parse);this.hasErrorRecovery||(e=removeErrorRecovery(e)),this.options["token-stack"]&&(e=addTokenStack(e)),nextVariableId=0;var t=this.generateTableCode(this.table),n=t.commonCode,r="{";return r+=["trace: "+String(this.trace||parser.trace),"yy: {}","symbols_: "+JSON.stringify(this.symbols_),"terminals_: "+JSON.stringify(this.terminals_).replace(/"([0-9]+)":/g,"$1:"),"productions_: "+JSON.stringify(this.productions_),"performAction: "+String(this.performAction),"table: "+t.moduleCode,"defaultActions: "+JSON.stringify(this.defaultActions).replace(/"([0-9]+)":/g,"$1:"),"parseError: "+String(this.parseError||(this.hasErrorRecovery?traceParseError:parser.parseError)),"parse: "+e].join(",\n"),r+="};",{commonCode:n,moduleCode:r}},lrGeneratorMixin.generateTableCode=function(e){var t=JSON.stringify(e),n=[createObjectCode];t=t.replace(/"([0-9]+)"(?=:)/g,"$1"),t=t.replace(/\{\d+:[^\}]+,\d+:[^\}]+\}/g,function(e){for(var t,n,r,i,o,s={},a=0,c=[],u=/(\d+):([^:]+)(?=,\d+:|\})/g;o=u.exec(e);)r=o[1],t=o[2],i=1,t in s?i=s[t].push(r):s[t]=[r],i>a&&(a=i,n=t);if(a>1){for(t in s)if(t!==n)for(var l=s[t],h=0,f=l.length;h0&&(this.resolutions.forEach(function(t,n){t[2].bydefault&&e.warn("Conflict at state: ",t[0],", token: ",t[1],"\n ",printAction(t[2].r,e),"\n ",printAction(t[2].s,e))}),this.trace("\n"+this.conflicts+" Conflict(s) found in grammar.")),this.trace("Done.")},aftercanonicalCollection:function(e){var t=this.trace;t("\nItem sets\n------"),e.forEach(function(e,n){t("\nitem set",n,"\n"+e.join("\n"),"\ntransitions -> ",JSON.stringify(e.edges))})}},parser=typal.beget();lrGeneratorMixin.createParser=function createParser(){function bind(e){return function(){return self.lexer=p.lexer,self[e].apply(self,arguments)}}var p=eval(this.generateModuleExpr());p.productions=this.productions;var self=this;return p.lexer=this.lexer,p.generate=bind("generate"),p.generateAMDModule=bind("generateAMDModule"),p.generateModule=bind("generateModule"),p.generateCommonJSModule=bind("generateCommonJSModule"),p},parser.trace=generator.trace,parser.warn=generator.warn,parser.error=generator.error,parser.parseError=lrGeneratorMixin.parseError=parseError,parser.parse=function(e){function t(e){i.length=i.length-2*e,o.length=o.length-e,s.length=s.length-e}function n(e){for(var t=i.length-1,n=0;;){if(f.toString()in a[e])return n;if(0===e||t<2)return!1;t-=2,e=i[t],++n}}var r=this,i=[0],o=[null],s=[],a=this.table,c="",u=0,l=0,h=0,f=2,p=1,d=s.slice.call(arguments,1),y=Object.create(this.lexer),m={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(m.yy[g]=this.yy[g]);y.setInput(e,m.yy),m.yy.lexer=y,m.yy.parser=this,"undefined"==typeof y.yylloc&&(y.yylloc={});var v=y.yylloc;s.push(v);var b=y.options&&y.options.ranges;"function"==typeof m.yy.parseError?this.parseError=m.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var x,_,S,w,E,k,A,C,O,I=function(){var e;return e=y.lex()||p,"number"!=typeof e&&(e=r.symbols_[e]||e),e},N={};;){if(S=i[i.length-1],this.defaultActions[S]?w=this.defaultActions[S]:(null!==x&&"undefined"!=typeof x||(x=I()),w=a[S]&&a[S][x]),"undefined"==typeof w||!w.length||!w[0]){var L,P="";if(h)_!==p&&(L=n(S));else{L=n(S),O=[];for(k in a[S])this.terminals_[k]&&k>f&&O.push("'"+this.terminals_[k]+"'");P=y.showPosition?"Parse error on line "+(u+1)+":\n"+y.showPosition()+"\nExpecting "+O.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(u+1)+": Unexpected "+(x==p?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(P,{text:y.match,token:this.terminals_[x]||x,line:y.yylineno,loc:v,expected:O,recoverable:L!==!1})}if(3==h){if(x===p||_===p)throw new Error(P||"Parsing halted while starting to recover from another error.");l=y.yyleng,c=y.yytext,u=y.yylineno,v=y.yylloc,x=I()}if(L===!1)throw new Error(P||"Parsing halted. No suitable error recovery rule available.");t(L),_=x==f?null:x,x=f,S=i[i.length-1],w=a[S]&&a[S][f],h=3}if(w[0]instanceof Array&&w.length>1)throw new Error("Parse Error: multiple actions possible at state: "+S+", token: "+x);switch(w[0]){case 1:i.push(x),o.push(y.yytext),s.push(y.yylloc),i.push(w[1]),x=null,_?(x=_,_=null):(l=y.yyleng,c=y.yytext,u=y.yylineno,v=y.yylloc,h>0&&h--);break;case 2:if(A=this.productions_[w[1]][1],N.$=o[o.length-A],N._$={first_line:s[s.length-(A||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(A||1)].first_column,last_column:s[s.length-1].last_column},b&&(N._$.range=[s[s.length-(A||1)].range[0],s[s.length-1].range[1]]),E=this.performAction.apply(N,[c,l,u,m.yy,w[1],o,s].concat(d)),"undefined"!=typeof E)return E;A&&(i=i.slice(0,-1*A*2),o=o.slice(0,-1*A),s=s.slice(0,-1*A)),i.push(this.productions_[w[1]][0]),o.push(N.$),s.push(N._$),C=a[i[i.length-2]][i[i.length-1]],i.push(C);break;case 3:return!0}}return!0},parser.init=function(e){this.table=e.table,this.defaultActions=e.defaultActions,this.performAction=e.performAction,this.productions_=e.productions_,this.symbols_=e.symbols_,this.terminals_=e.terminals_};var lr0=generator.beget(lookaheadMixin,lrGeneratorMixin,{ +type:"LR(0)",afterconstructor:function(){this.buildTable()}}),LR0Generator=exports.LR0Generator=lr0.construct(),lalr=generator.beget(lookaheadMixin,lrGeneratorMixin,{type:"LALR(1)",afterconstructor:function(e,t){this.DEBUG&&this.mix(lrGeneratorDebug,lalrGeneratorDebug),t=t||{},this.states=this.canonicalCollection(),this.terms_={};var n=this.newg=typal.beget(lookaheadMixin,{oldg:this,trace:this.trace,nterms_:{},DEBUG:!1,go_:function(e,t){return e=e.split(":")[0],t=t.map(function(e){return e.slice(e.indexOf(":")+1)}),this.oldg.go(e,t)}});n.nonterminals={},n.productions=[],this.inadequateStates=[],this.onDemandLookahead=t.onDemandLookahead||!1,this.buildNewGrammar(),n.computeLookaheads(),this.unionLookaheads(),this.table=this.parseTable(this.states),this.defaultActions=findDefaults(this.table)},lookAheads:function(e,t){return this.onDemandLookahead&&!e.inadequate?this.terminals:t.follows},go:function(e,t){for(var n=parseInt(e,10),r=0;r1)for(var n=1;n=0;--r)n[e[r]]=!0;for(var i=t.length-1;i>=0;--i)n[t[i]]||e.push(t[i]);return e}});t.Set=o},function(module,exports,__webpack_require__){"use strict";function prepareRules(e,t,n,r,i,o){function s(e,t){return"return "+(r[t]||"'"+t+"'")}var a,c,u,l,h,f=[];for(t&&(t=prepareMacros(t)),n.push("switch($avoiding_name_collisions) {"),c=0;c20?"...":"")+e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var e=this.pastInput(),t=new Array(e.length+1).join("-");return e+this.upcomingInput()+"\n"+t+"^"},test_match:function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var o in i)this[o]=i[o];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),o=0;ot[0].length)){if(t=n,r=o,this.options.backtrack_lexer){if(e=this.test_match(n,i[o]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var e=this.next();return e?e:this.lex()},begin:function(e){this.conditionStack.push(e)},popState:function(){var e=this.conditionStack.length-1;return e>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:"INITIAL"},pushState:function(e){this.begin(e)},stateStackSize:function(){return this.conditionStack.length}},RegExpLexer.generate=generate,module.exports=RegExpLexer},function(e,t,n){(function(e,r){var i=function(){function e(e){return e.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1").replace(/\\\\u([a-fA-F0-9]{4})/g,"\\u$1")}function t(t){return t=t.replace(/\\\\/g,"\\"),t=e(t)}function n(){this.yy={}}var r={trace:function(){},yy:{},symbols_:{error:2,lex:3,definitions:4,"%%":5,rules:6,epilogue:7,EOF:8,CODE:9,definition:10,ACTION:11,NAME:12,regex:13,START_INC:14,names_inclusive:15,START_EXC:16,names_exclusive:17,START_COND:18,rule:19,start_conditions:20,action:21,"{":22,action_body:23,"}":24,action_comments_body:25,ACTION_BODY:26,"<":27,name_list:28,">":29,"*":30,",":31,regex_list:32,"|":33,regex_concat:34,regex_base:35,"(":36,")":37,SPECIAL_GROUP:38,"+":39,"?":40,"/":41,"/!":42,name_expansion:43,range_regex:44,any_group_regex:45,".":46,"^":47,$:48,string:49,escape_char:50,NAME_BRACE:51,ANY_GROUP_REGEX:52,ESCAPE_CHAR:53,RANGE_REGEX:54,STRING_LIT:55,CHARACTER_LIT:56,$accept:0,$end:1},terminals_:{2:"error",5:"%%",8:"EOF",9:"CODE",11:"ACTION",12:"NAME",14:"START_INC",16:"START_EXC",18:"START_COND",22:"{",24:"}",26:"ACTION_BODY",27:"<",29:">",30:"*",31:",",33:"|",36:"(",37:")",38:"SPECIAL_GROUP",39:"+",40:"?",41:"/",42:"/!",46:".",47:"^",48:"$",51:"NAME_BRACE",52:"ANY_GROUP_REGEX",53:"ESCAPE_CHAR",54:"RANGE_REGEX",55:"STRING_LIT",56:"CHARACTER_LIT"},productions_:[0,[3,4],[7,1],[7,2],[7,3],[4,2],[4,2],[4,0],[10,2],[10,2],[10,2],[15,1],[15,2],[17,1],[17,2],[6,2],[6,1],[19,3],[21,3],[21,1],[23,0],[23,1],[23,5],[23,4],[25,1],[25,2],[20,3],[20,3],[20,0],[28,1],[28,3],[13,1],[32,3],[32,2],[32,1],[32,0],[34,2],[34,1],[35,3],[35,3],[35,2],[35,2],[35,2],[35,2],[35,2],[35,1],[35,2],[35,1],[35,1],[35,1],[35,1],[35,1],[35,1],[43,1],[45,1],[50,1],[44,1],[49,1],[49,1]],performAction:function(e,n,r,i,o,s,a){var c=s.length-1;switch(o){case 1:return this.$={rules:s[c-1]},s[c-3][0]&&(this.$.macros=s[c-3][0]),s[c-3][1]&&(this.$.startConditions=s[c-3][1]),s[c]&&(this.$.moduleInclude=s[c]),i.options&&(this.$.options=i.options),i.actionInclude&&(this.$.actionInclude=i.actionInclude),delete i.options,delete i.actionInclude,this.$;case 2:this.$=null;break;case 3:this.$=null;break;case 4:this.$=s[c-1];break;case 5:if(this.$=s[c],"length"in s[c-1])this.$[0]=this.$[0]||{},this.$[0][s[c-1][0]]=s[c-1][1];else{this.$[1]=this.$[1]||{};for(var u in s[c-1])this.$[1][u]=s[c-1][u]}break;case 6:i.actionInclude+=s[c-1],this.$=s[c];break;case 7:i.actionInclude="",this.$=[null,null];break;case 8:this.$=[s[c-1],s[c]];break;case 9:this.$=s[c];break;case 10:this.$=s[c];break;case 11:this.$={},this.$[s[c]]=0;break;case 12:this.$=s[c-1],this.$[s[c]]=0;break;case 13:this.$={},this.$[s[c]]=1;break;case 14:this.$=s[c-1],this.$[s[c]]=1;break;case 15:this.$=s[c-1],this.$.push(s[c]);break;case 16:this.$=[s[c]];break;case 17:this.$=s[c-2]?[s[c-2],s[c-1],s[c]]:[s[c-1],s[c]];break;case 18:this.$=s[c-1];break;case 19:this.$=s[c];break;case 20:this.$="";break;case 21:this.$=s[c];break;case 22:this.$=s[c-4]+s[c-3]+s[c-2]+s[c-1]+s[c];break;case 23:this.$=s[c-3]+s[c-2]+s[c-1]+s[c];break;case 24:this.$=e;break;case 25:this.$=s[c-1]+s[c];break;case 26:this.$=s[c-1];break;case 27:this.$=["*"];break;case 29:this.$=[s[c]];break;case 30:this.$=s[c-2],this.$.push(s[c]);break;case 31:this.$=s[c],i.options&&i.options.flex||!this.$.match(/[\w\d]$/)||this.$.match(/\\(r|f|n|t|v|s|b|c[A-Z]|x[0-9A-F]{2}|u[a-fA-F0-9]{4}|[0-7]{1,3})$/)||(this.$+="\\b");break;case 32:this.$=s[c-2]+"|"+s[c];break;case 33:this.$=s[c-1]+"|";break;case 35:this.$="";break;case 36:this.$=s[c-1]+s[c];break;case 38:this.$="("+s[c-1]+")";break;case 39:this.$=s[c-2]+s[c-1]+")";break;case 40:this.$=s[c-1]+"+";break;case 41:this.$=s[c-1]+"*";break;case 42:this.$=s[c-1]+"?";break;case 43:this.$="(?="+s[c]+")";break;case 44:this.$="(?!"+s[c]+")";break;case 46:this.$=s[c-1]+s[c];break;case 48:this.$=".";break;case 49:this.$="^";break;case 50:this.$="$";break;case 54:this.$=e;break;case 55:this.$=e;break;case 56:this.$=e;break;case 57:this.$=t(e.substr(1,e.length-2))}},table:[{3:1,4:2,5:[2,7],10:3,11:[1,4],12:[1,5],14:[1,6],16:[1,7]},{1:[3]},{5:[1,8]},{4:9,5:[2,7],10:3,11:[1,4],12:[1,5],14:[1,6],16:[1,7]},{4:10,5:[2,7],10:3,11:[1,4],12:[1,5],14:[1,6],16:[1,7]},{5:[2,35],11:[2,35],12:[2,35],13:11,14:[2,35],16:[2,35],32:12,33:[2,35],34:13,35:14,36:[1,15],38:[1,16],41:[1,17],42:[1,18],43:19,45:20,46:[1,21],47:[1,22],48:[1,23],49:24,50:25,51:[1,26],52:[1,27],53:[1,30],55:[1,28],56:[1,29]},{15:31,18:[1,32]},{17:33,18:[1,34]},{6:35,11:[2,28],19:36,20:37,22:[2,28],27:[1,38],33:[2,28],36:[2,28],38:[2,28],41:[2,28],42:[2,28],46:[2,28],47:[2,28],48:[2,28],51:[2,28],52:[2,28],53:[2,28],55:[2,28],56:[2,28]},{5:[2,5]},{5:[2,6]},{5:[2,8],11:[2,8],12:[2,8],14:[2,8],16:[2,8]},{5:[2,31],11:[2,31],12:[2,31],14:[2,31],16:[2,31],22:[2,31],33:[1,39]},{5:[2,34],11:[2,34],12:[2,34],14:[2,34],16:[2,34],22:[2,34],33:[2,34],35:40,36:[1,15],37:[2,34],38:[1,16],41:[1,17],42:[1,18],43:19,45:20,46:[1,21],47:[1,22],48:[1,23],49:24,50:25,51:[1,26],52:[1,27],53:[1,30],55:[1,28],56:[1,29]},{5:[2,37],11:[2,37],12:[2,37],14:[2,37],16:[2,37],22:[2,37],30:[1,42],33:[2,37],36:[2,37],37:[2,37],38:[2,37],39:[1,41],40:[1,43],41:[2,37],42:[2,37],44:44,46:[2,37],47:[2,37],48:[2,37],51:[2,37],52:[2,37],53:[2,37],54:[1,45],55:[2,37],56:[2,37]},{32:46,33:[2,35],34:13,35:14,36:[1,15],37:[2,35],38:[1,16],41:[1,17],42:[1,18],43:19,45:20,46:[1,21],47:[1,22],48:[1,23],49:24,50:25,51:[1,26],52:[1,27],53:[1,30],55:[1,28],56:[1,29]},{32:47,33:[2,35],34:13,35:14,36:[1,15],37:[2,35],38:[1,16],41:[1,17],42:[1,18],43:19,45:20,46:[1,21],47:[1,22],48:[1,23],49:24,50:25,51:[1,26],52:[1,27],53:[1,30],55:[1,28],56:[1,29]},{35:48,36:[1,15],38:[1,16],41:[1,17],42:[1,18],43:19,45:20,46:[1,21],47:[1,22],48:[1,23],49:24,50:25,51:[1,26],52:[1,27],53:[1,30],55:[1,28],56:[1,29]},{35:49,36:[1,15],38:[1,16],41:[1,17],42:[1,18],43:19,45:20,46:[1,21],47:[1,22],48:[1,23],49:24,50:25,51:[1,26],52:[1,27],53:[1,30],55:[1,28],56:[1,29]},{5:[2,45],11:[2,45],12:[2,45],14:[2,45],16:[2,45],22:[2,45],30:[2,45],33:[2,45],36:[2,45],37:[2,45],38:[2,45],39:[2,45],40:[2,45],41:[2,45],42:[2,45],46:[2,45],47:[2,45],48:[2,45],51:[2,45],52:[2,45],53:[2,45],54:[2,45],55:[2,45],56:[2,45]},{5:[2,47],11:[2,47],12:[2,47],14:[2,47],16:[2,47],22:[2,47],30:[2,47],33:[2,47],36:[2,47],37:[2,47],38:[2,47],39:[2,47],40:[2,47],41:[2,47],42:[2,47],46:[2,47],47:[2,47],48:[2,47],51:[2,47],52:[2,47],53:[2,47],54:[2,47],55:[2,47],56:[2,47]},{5:[2,48],11:[2,48],12:[2,48],14:[2,48],16:[2,48],22:[2,48],30:[2,48],33:[2,48],36:[2,48],37:[2,48],38:[2,48],39:[2,48],40:[2,48],41:[2,48],42:[2,48],46:[2,48],47:[2,48],48:[2,48],51:[2,48],52:[2,48],53:[2,48],54:[2,48],55:[2,48],56:[2,48]},{5:[2,49],11:[2,49],12:[2,49],14:[2,49],16:[2,49],22:[2,49],30:[2,49],33:[2,49],36:[2,49],37:[2,49],38:[2,49],39:[2,49],40:[2,49],41:[2,49],42:[2,49],46:[2,49],47:[2,49],48:[2,49],51:[2,49],52:[2,49],53:[2,49],54:[2,49],55:[2,49],56:[2,49]},{5:[2,50],11:[2,50],12:[2,50],14:[2,50],16:[2,50],22:[2,50],30:[2,50],33:[2,50],36:[2,50],37:[2,50],38:[2,50],39:[2,50],40:[2,50],41:[2,50],42:[2,50],46:[2,50],47:[2,50],48:[2,50],51:[2,50],52:[2,50],53:[2,50],54:[2,50],55:[2,50],56:[2,50]},{5:[2,51],11:[2,51],12:[2,51],14:[2,51],16:[2,51],22:[2,51],30:[2,51],33:[2,51],36:[2,51],37:[2,51],38:[2,51],39:[2,51],40:[2,51],41:[2,51],42:[2,51],46:[2,51],47:[2,51],48:[2,51],51:[2,51],52:[2,51],53:[2,51],54:[2,51],55:[2,51],56:[2,51]},{5:[2,52],11:[2,52],12:[2,52],14:[2,52],16:[2,52],22:[2,52],30:[2,52],33:[2,52],36:[2,52],37:[2,52],38:[2,52],39:[2,52],40:[2,52],41:[2,52],42:[2,52],46:[2,52],47:[2,52],48:[2,52],51:[2,52],52:[2,52],53:[2,52],54:[2,52],55:[2,52],56:[2,52]},{5:[2,53],11:[2,53],12:[2,53],14:[2,53],16:[2,53],22:[2,53],30:[2,53],33:[2,53],36:[2,53],37:[2,53],38:[2,53],39:[2,53],40:[2,53],41:[2,53],42:[2,53],46:[2,53],47:[2,53],48:[2,53],51:[2,53],52:[2,53],53:[2,53],54:[2,53],55:[2,53],56:[2,53]},{5:[2,54],11:[2,54],12:[2,54],14:[2,54],16:[2,54],22:[2,54],30:[2,54],33:[2,54],36:[2,54],37:[2,54],38:[2,54],39:[2,54],40:[2,54],41:[2,54],42:[2,54],46:[2,54],47:[2,54],48:[2,54],51:[2,54],52:[2,54],53:[2,54],54:[2,54],55:[2,54],56:[2,54]},{5:[2,57],11:[2,57],12:[2,57],14:[2,57],16:[2,57],22:[2,57],30:[2,57],33:[2,57],36:[2,57],37:[2,57],38:[2,57],39:[2,57],40:[2,57],41:[2,57],42:[2,57],46:[2,57],47:[2,57],48:[2,57],51:[2,57],52:[2,57],53:[2,57],54:[2,57],55:[2,57],56:[2,57]},{5:[2,58],11:[2,58],12:[2,58],14:[2,58],16:[2,58],22:[2,58],30:[2,58],33:[2,58],36:[2,58],37:[2,58],38:[2,58],39:[2,58],40:[2,58],41:[2,58],42:[2,58],46:[2,58],47:[2,58],48:[2,58],51:[2,58],52:[2,58],53:[2,58],54:[2,58],55:[2,58],56:[2,58]},{5:[2,55],11:[2,55],12:[2,55],14:[2,55],16:[2,55],22:[2,55],30:[2,55],33:[2,55],36:[2,55],37:[2,55],38:[2,55],39:[2,55],40:[2,55],41:[2,55],42:[2,55],46:[2,55],47:[2,55],48:[2,55],51:[2,55],52:[2,55],53:[2,55],54:[2,55],55:[2,55],56:[2,55]},{5:[2,9],11:[2,9],12:[2,9],14:[2,9],16:[2,9],18:[1,50]},{5:[2,11],11:[2,11],12:[2,11],14:[2,11],16:[2,11],18:[2,11]},{5:[2,10],11:[2,10],12:[2,10],14:[2,10],16:[2,10],18:[1,51]},{5:[2,13],11:[2,13],12:[2,13],14:[2,13],16:[2,13],18:[2,13]},{5:[1,55],7:52,8:[1,54],11:[2,28],19:53,20:37,22:[2,28],27:[1,38],33:[2,28],36:[2,28],38:[2,28],41:[2,28],42:[2,28],46:[2,28],47:[2,28],48:[2,28],51:[2,28],52:[2,28],53:[2,28],55:[2,28],56:[2,28]},{5:[2,16],8:[2,16],11:[2,16],22:[2,16],27:[2,16],33:[2,16],36:[2,16],38:[2,16],41:[2,16],42:[2,16],46:[2,16],47:[2,16],48:[2,16],51:[2,16],52:[2,16],53:[2,16],55:[2,16],56:[2,16]},{11:[2,35],13:56,22:[2,35],32:12,33:[2,35],34:13,35:14,36:[1,15],38:[1,16],41:[1,17],42:[1,18],43:19,45:20,46:[1,21],47:[1,22],48:[1,23],49:24,50:25,51:[1,26],52:[1,27],53:[1,30],55:[1,28],56:[1,29]},{12:[1,59],28:57,30:[1,58]},{5:[2,33],11:[2,33],12:[2,33],14:[2,33],16:[2,33],22:[2,33],33:[2,33],34:60,35:14,36:[1,15],37:[2,33],38:[1,16],41:[1,17],42:[1,18],43:19,45:20,46:[1,21],47:[1,22],48:[1,23],49:24,50:25,51:[1,26],52:[1,27],53:[1,30],55:[1,28],56:[1,29]},{5:[2,36],11:[2,36],12:[2,36],14:[2,36],16:[2,36],22:[2,36],30:[1,42],33:[2,36],36:[2,36],37:[2,36],38:[2,36],39:[1,41],40:[1,43],41:[2,36],42:[2,36],44:44,46:[2,36],47:[2,36],48:[2,36],51:[2,36],52:[2,36],53:[2,36],54:[1,45],55:[2,36],56:[2,36]},{5:[2,40],11:[2,40],12:[2,40],14:[2,40],16:[2,40],22:[2,40],30:[2,40],33:[2,40],36:[2,40],37:[2,40],38:[2,40],39:[2,40],40:[2,40],41:[2,40],42:[2,40],46:[2,40],47:[2,40],48:[2,40],51:[2,40],52:[2,40],53:[2,40],54:[2,40],55:[2,40],56:[2,40]},{5:[2,41],11:[2,41],12:[2,41],14:[2,41],16:[2,41],22:[2,41],30:[2,41],33:[2,41],36:[2,41],37:[2,41],38:[2,41],39:[2,41],40:[2,41],41:[2,41],42:[2,41],46:[2,41],47:[2,41],48:[2,41],51:[2,41],52:[2,41],53:[2,41],54:[2,41],55:[2,41],56:[2,41]},{5:[2,42],11:[2,42],12:[2,42],14:[2,42],16:[2,42],22:[2,42],30:[2,42],33:[2,42],36:[2,42],37:[2,42],38:[2,42],39:[2,42],40:[2,42],41:[2,42],42:[2,42],46:[2,42],47:[2,42],48:[2,42],51:[2,42],52:[2,42],53:[2,42],54:[2,42],55:[2,42],56:[2,42]},{5:[2,46],11:[2,46],12:[2,46],14:[2,46],16:[2,46],22:[2,46],30:[2,46],33:[2,46],36:[2,46],37:[2,46],38:[2,46],39:[2,46],40:[2,46],41:[2,46],42:[2,46],46:[2,46],47:[2,46],48:[2,46],51:[2,46],52:[2,46],53:[2,46],54:[2,46],55:[2,46],56:[2,46]},{5:[2,56],11:[2,56],12:[2,56],14:[2,56],16:[2,56],22:[2,56],30:[2,56],33:[2,56],36:[2,56],37:[2,56],38:[2,56],39:[2,56],40:[2,56],41:[2,56],42:[2,56],46:[2,56],47:[2,56],48:[2,56],51:[2,56],52:[2,56],53:[2,56],54:[2,56],55:[2,56],56:[2,56]},{33:[1,39],37:[1,61]},{33:[1,39],37:[1,62]},{5:[2,43],11:[2,43],12:[2,43],14:[2,43],16:[2,43],22:[2,43],30:[1,42],33:[2,43],36:[2,43],37:[2,43],38:[2,43],39:[1,41],40:[1,43],41:[2,43],42:[2,43],44:44,46:[2,43],47:[2,43],48:[2,43],51:[2,43],52:[2,43],53:[2,43],54:[1,45],55:[2,43],56:[2,43]},{5:[2,44],11:[2,44],12:[2,44],14:[2,44],16:[2,44],22:[2,44],30:[1,42],33:[2,44],36:[2,44],37:[2,44],38:[2,44],39:[1,41],40:[1,43],41:[2,44],42:[2,44],44:44,46:[2,44],47:[2,44],48:[2,44],51:[2,44],52:[2,44],53:[2,44],54:[1,45],55:[2,44],56:[2,44]},{5:[2,12],11:[2,12],12:[2,12],14:[2,12],16:[2,12],18:[2,12]},{5:[2,14],11:[2,14],12:[2,14],14:[2,14],16:[2,14],18:[2,14]},{1:[2,1]},{5:[2,15],8:[2,15],11:[2,15],22:[2,15],27:[2,15],33:[2,15],36:[2,15],38:[2,15],41:[2,15],42:[2,15],46:[2,15],47:[2,15],48:[2,15],51:[2,15],52:[2,15],53:[2,15],55:[2,15],56:[2,15]},{1:[2,2]},{8:[1,63],9:[1,64]},{11:[1,67],21:65,22:[1,66]},{29:[1,68],31:[1,69]},{29:[1,70]},{29:[2,29],31:[2,29]},{5:[2,32],11:[2,32],12:[2,32],14:[2,32],16:[2,32],22:[2,32],33:[2,32],35:40,36:[1,15],37:[2,32],38:[1,16],41:[1,17],42:[1,18],43:19,45:20,46:[1,21],47:[1,22], +48:[1,23],49:24,50:25,51:[1,26],52:[1,27],53:[1,30],55:[1,28],56:[1,29]},{5:[2,38],11:[2,38],12:[2,38],14:[2,38],16:[2,38],22:[2,38],30:[2,38],33:[2,38],36:[2,38],37:[2,38],38:[2,38],39:[2,38],40:[2,38],41:[2,38],42:[2,38],46:[2,38],47:[2,38],48:[2,38],51:[2,38],52:[2,38],53:[2,38],54:[2,38],55:[2,38],56:[2,38]},{5:[2,39],11:[2,39],12:[2,39],14:[2,39],16:[2,39],22:[2,39],30:[2,39],33:[2,39],36:[2,39],37:[2,39],38:[2,39],39:[2,39],40:[2,39],41:[2,39],42:[2,39],46:[2,39],47:[2,39],48:[2,39],51:[2,39],52:[2,39],53:[2,39],54:[2,39],55:[2,39],56:[2,39]},{1:[2,3]},{8:[1,71]},{5:[2,17],8:[2,17],11:[2,17],22:[2,17],27:[2,17],33:[2,17],36:[2,17],38:[2,17],41:[2,17],42:[2,17],46:[2,17],47:[2,17],48:[2,17],51:[2,17],52:[2,17],53:[2,17],55:[2,17],56:[2,17]},{22:[2,20],23:72,24:[2,20],25:73,26:[1,74]},{5:[2,19],8:[2,19],11:[2,19],22:[2,19],27:[2,19],33:[2,19],36:[2,19],38:[2,19],41:[2,19],42:[2,19],46:[2,19],47:[2,19],48:[2,19],51:[2,19],52:[2,19],53:[2,19],55:[2,19],56:[2,19]},{11:[2,26],22:[2,26],33:[2,26],36:[2,26],38:[2,26],41:[2,26],42:[2,26],46:[2,26],47:[2,26],48:[2,26],51:[2,26],52:[2,26],53:[2,26],55:[2,26],56:[2,26]},{12:[1,75]},{11:[2,27],22:[2,27],33:[2,27],36:[2,27],38:[2,27],41:[2,27],42:[2,27],46:[2,27],47:[2,27],48:[2,27],51:[2,27],52:[2,27],53:[2,27],55:[2,27],56:[2,27]},{1:[2,4]},{22:[1,77],24:[1,76]},{22:[2,21],24:[2,21],26:[1,78]},{22:[2,24],24:[2,24],26:[2,24]},{29:[2,30],31:[2,30]},{5:[2,18],8:[2,18],11:[2,18],22:[2,18],27:[2,18],33:[2,18],36:[2,18],38:[2,18],41:[2,18],42:[2,18],46:[2,18],47:[2,18],48:[2,18],51:[2,18],52:[2,18],53:[2,18],55:[2,18],56:[2,18]},{22:[2,20],23:79,24:[2,20],25:73,26:[1,74]},{22:[2,25],24:[2,25],26:[2,25]},{22:[1,77],24:[1,80]},{22:[2,23],24:[2,23],25:81,26:[1,74]},{22:[2,22],24:[2,22],26:[1,78]}],defaultActions:{9:[2,5],10:[2,6],52:[2,1],54:[2,2],63:[2,3],71:[2,4]},parseError:function(e,t){if(!t.recoverable)throw new Error(e);this.trace(e)},parse:function(e){function t(){var e;return e=n.lexer.lex()||f,"number"!=typeof e&&(e=n.symbols_[e]||e),e}var n=this,r=[0],i=[null],o=[],s=this.table,a="",c=0,u=0,l=0,h=2,f=1;this.lexer.setInput(e),this.lexer.yy=this.yy,this.yy.lexer=this.lexer,this.yy.parser=this,"undefined"==typeof this.lexer.yylloc&&(this.lexer.yylloc={});var p=this.lexer.yylloc;o.push(p);var d=this.lexer.options&&this.lexer.options.ranges;"function"==typeof this.yy.parseError?this.parseError=this.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var y,m,g,v,b,x,_,S,w,E={};;){if(g=r[r.length-1],this.defaultActions[g]?v=this.defaultActions[g]:(null!==y&&"undefined"!=typeof y||(y=t()),v=s[g]&&s[g][y]),"undefined"==typeof v||!v.length||!v[0]){var k="";w=[];for(x in s[g])this.terminals_[x]&&x>h&&w.push("'"+this.terminals_[x]+"'");k=this.lexer.showPosition?"Parse error on line "+(c+1)+":\n"+this.lexer.showPosition()+"\nExpecting "+w.join(", ")+", got '"+(this.terminals_[y]||y)+"'":"Parse error on line "+(c+1)+": Unexpected "+(y==f?"end of input":"'"+(this.terminals_[y]||y)+"'"),this.parseError(k,{text:this.lexer.match,token:this.terminals_[y]||y,line:this.lexer.yylineno,loc:p,expected:w})}if(v[0]instanceof Array&&v.length>1)throw new Error("Parse Error: multiple actions possible at state: "+g+", token: "+y);switch(v[0]){case 1:r.push(y),i.push(this.lexer.yytext),o.push(this.lexer.yylloc),r.push(v[1]),y=null,m?(y=m,m=null):(u=this.lexer.yyleng,a=this.lexer.yytext,c=this.lexer.yylineno,p=this.lexer.yylloc,l>0&&l--);break;case 2:if(_=this.productions_[v[1]][1],E.$=i[i.length-_],E._$={first_line:o[o.length-(_||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(_||1)].first_column,last_column:o[o.length-1].last_column},d&&(E._$.range=[o[o.length-(_||1)].range[0],o[o.length-1].range[1]]),b=this.performAction.call(E,a,u,c,this.yy,v[1],i,o),"undefined"!=typeof b)return b;_&&(r=r.slice(0,-1*_*2),i=i.slice(0,-1*_),o=o.slice(0,-1*_)),r.push(this.productions_[v[1]][0]),i.push(E.$),o.push(E._$),S=s[r[r.length-2]][r[r.length-1]],r.push(S);break;case 3:return!0}}return!0}},i=function(){var e={EOF:1,parseError:function(e,t){if(!this.yy.parser)throw new Error(e);this.yy.parser.parseError(e,t)},setInput:function(e){return this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var e=this._input[0];this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e;var t=e.match(/(?:\r\n?|\n).*/g);return t?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},unput:function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t-1),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(e){this.unput(this.match.slice(e))},pastInput:function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?"...":"")+e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var e=this.pastInput(),t=new Array(e.length+1).join("-");return e+this.upcomingInput()+"\n"+t+"^"},test_match:function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var o in i)this[o]=i[o];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),o=0;ot[0].length)){if(t=n,r=o,this.options.backtrack_lexer){if(e=this.test_match(n,i[o]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var e=this.next();return e?e:this.lex()},begin:function(e){this.conditionStack.push(e)},popState:function(){var e=this.conditionStack.length-1;return e>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:"INITIAL"},pushState:function(e){this.begin(e)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(e,t,n,r){switch(n){case 0:return 26;case 1:return 26;case 2:return 26;case 3:return 26;case 4:return 26;case 5:return 26;case 6:return 26;case 7:return e.depth++,22;case 8:return 0==e.depth?this.begin("trail"):e.depth--,24;case 9:return 12;case 10:return this.popState(),29;case 11:return 31;case 12:return 30;case 13:break;case 14:break;case 15:this.begin("indented");break;case 16:return this.begin("code"),5;case 17:return 56;case 18:e.options[t.yytext]=!0;break;case 19:this.begin("INITIAL");break;case 20:this.begin("INITIAL");break;case 21:break;case 22:return 18;case 23:this.begin("INITIAL");break;case 24:this.begin("INITIAL");break;case 25:break;case 26:this.begin("rules");break;case 27:return e.depth=0,this.begin("action"),22;case 28:return this.begin("trail"),t.yytext=t.yytext.substr(2,t.yytext.length-4),11;case 29:return t.yytext=t.yytext.substr(2,t.yytext.length-4),11;case 30:return this.begin("rules"),11;case 31:break;case 32:break;case 33:break;case 34:break;case 35:return 12;case 36:return t.yytext=t.yytext.replace(/\\"/g,'"'),55;case 37:return t.yytext=t.yytext.replace(/\\'/g,"'"),55;case 38:return 33;case 39:return 52;case 40:return 38;case 41:return 38;case 42:return 38;case 43:return 36;case 44:return 37;case 45:return 39;case 46:return 30;case 47:return 40;case 48:return 47;case 49:return 31;case 50:return 48;case 51:return this.begin("conditions"),27;case 52:return 42;case 53:return 41;case 54:return 53;case 55:return t.yytext=t.yytext.replace(/^\\/g,""),53;case 56:return 48;case 57:return 46;case 58:e.options={},this.begin("options");break;case 59:return this.begin("start_condition"),14;case 60:return this.begin("start_condition"),16;case 61:return this.begin("rules"),5;case 62:return 54;case 63:return 51;case 64:return 22;case 65:return 24;case 66:break;case 67:return 8;case 68:return 9}},rules:[/^(?:\/\*(.|\n|\r)*?\*\/)/,/^(?:\/\/.*)/,/^(?:\/[^ \/]*?['"{}'][^ ]*?\/)/,/^(?:"(\\\\|\\"|[^"])*")/,/^(?:'(\\\\|\\'|[^'])*')/,/^(?:[\/"'][^{}\/"']+)/,/^(?:[^{}\/"']+)/,/^(?:\{)/,/^(?:\})/,/^(?:([a-zA-Z_][a-zA-Z0-9_-]*))/,/^(?:>)/,/^(?:,)/,/^(?:\*)/,/^(?:(\r\n|\n|\r)+)/,/^(?:\s+(\r\n|\n|\r)+)/,/^(?:\s+)/,/^(?:%%)/,/^(?:[a-zA-Z0-9_]+)/,/^(?:([a-zA-Z_][a-zA-Z0-9_-]*))/,/^(?:(\r\n|\n|\r)+)/,/^(?:\s+(\r\n|\n|\r)+)/,/^(?:\s+)/,/^(?:([a-zA-Z_][a-zA-Z0-9_-]*))/,/^(?:(\r\n|\n|\r)+)/,/^(?:\s+(\r\n|\n|\r)+)/,/^(?:\s+)/,/^(?:.*(\r\n|\n|\r)+)/,/^(?:\{)/,/^(?:%\{(.|(\r\n|\n|\r))*?%\})/,/^(?:%\{(.|(\r\n|\n|\r))*?%\})/,/^(?:.+)/,/^(?:\/\*(.|\n|\r)*?\*\/)/,/^(?:\/\/.*)/,/^(?:(\r\n|\n|\r)+)/,/^(?:\s+)/,/^(?:([a-zA-Z_][a-zA-Z0-9_-]*))/,/^(?:"(\\\\|\\"|[^"])*")/,/^(?:'(\\\\|\\'|[^'])*')/,/^(?:\|)/,/^(?:\[(\\\\|\\\]|[^\]])*\])/,/^(?:\(\?:)/,/^(?:\(\?=)/,/^(?:\(\?!)/,/^(?:\()/,/^(?:\))/,/^(?:\+)/,/^(?:\*)/,/^(?:\?)/,/^(?:\^)/,/^(?:,)/,/^(?:<>)/,/^(?:<)/,/^(?:\/!)/,/^(?:\/)/,/^(?:\\([0-7]{1,3}|[rfntvsSbBwWdD\\*+()${}|[\]\/.^?]|c[A-Z]|x[0-9A-F]{2}|u[a-fA-F0-9]{4}))/,/^(?:\\.)/,/^(?:\$)/,/^(?:\.)/,/^(?:%options\b)/,/^(?:%s\b)/,/^(?:%x\b)/,/^(?:%%)/,/^(?:\{\d+(,\s?\d+|,)?\})/,/^(?:\{([a-zA-Z_][a-zA-Z0-9_-]*)\})/,/^(?:\{)/,/^(?:\})/,/^(?:.)/,/^(?:$)/,/^(?:(.|(\r\n|\n|\r))+)/],conditions:{code:{rules:[67,68],inclusive:!1},start_condition:{rules:[22,23,24,25,67],inclusive:!1},options:{rules:[18,19,20,21,67],inclusive:!1},conditions:{rules:[9,10,11,12,67],inclusive:!1},action:{rules:[0,1,2,3,4,5,6,7,8,67],inclusive:!1},indented:{rules:[27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67],inclusive:!0},trail:{rules:[26,29,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67],inclusive:!0},rules:{rules:[13,14,15,16,17,29,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67],inclusive:!0},INITIAL:{rules:[29,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67],inclusive:!0}}};return e}();return r.lexer=i,n.prototype=r,r.Parser=n,new n}();t.parser=i,t.Parser=i.Parser,t.parse=function(){return i.parse.apply(i,arguments)},t.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),e.exit(1));var i=n(336).readFileSync(n(337).normalize(r[1]),"utf8");return t.parser.parse(i)},"undefined"!=typeof r&&n.c[0]===r&&t.main(e.argv.slice(1))}).call(t,n(330),n(335)(e))},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children=[],e.webpackPolyfill=1),e}},function(e,t){},function(e,t,n){(function(e){function n(e,t){for(var n=0,r=e.length-1;r>=0;r--){var i=e[r];"."===i?e.splice(r,1):".."===i?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}function r(e,t){if(e.filter)return e.filter(t);for(var n=[],r=0;r=-1&&!i;o--){var s=o>=0?arguments[o]:e.cwd();if("string"!=typeof s)throw new TypeError("Arguments to path.resolve must be strings");s&&(t=s+"/"+t,i="/"===s.charAt(0))}return t=n(r(t.split("/"),function(e){return!!e}),!i).join("/"),(i?"/":"")+t||"."},t.normalize=function(e){var i=t.isAbsolute(e),o="/"===s(e,-1);return e=n(r(e.split("/"),function(e){return!!e}),!i).join("/"),e||i||(e="."),e&&o&&(e+="/"),(i?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(r(e,function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e}).join("/"))},t.relative=function(e,n){function r(e){for(var t=0;t=0&&""===e[n];n--);return t>n?[]:e.slice(t,n-t+1)}e=t.resolve(e).substr(1),n=t.resolve(n).substr(1);for(var i=r(e.split("/")),o=r(n.split("/")),s=Math.min(i.length,o.length),a=s,c=0;c=0.4"},homepage:"http://jison.org",keywords:["jison","parser","generator","lexer","flex","tokenizer"],main:"regexp-lexer",name:"jison-lex",repository:{type:"git",url:"git://github.com/zaach/jison-lex.git"},scripts:{test:"node tests/all-tests.js"},version:"0.3.4"}},function(e,t,n){var r=n(340).parser,i=n(341),o=n(334);t.parse=function(e){return r.parse(e)},t.transform=i.transform,r.yy.addDeclaration=function(e,t){if(t.start)e.start=t.start;else if(t.lex)e.lex=s(t.lex);else if(t.operator)e.operators||(e.operators=[]),e.operators.push(t.operator);else if(t.parseParam)e.parseParams||(e.parseParams=[]),e.parseParams=e.parseParams.concat(t.parseParam);else if(t.include)e.moduleInclude||(e.moduleInclude=""),e.moduleInclude+=t.include;else if(t.options){e.options||(e.options={});for(var n=0;nh&&E.push("'"+this.terminals_[_]+"'");A=this.lexer.showPosition?"Parse error on line "+(c+1)+":\n"+this.lexer.showPosition()+"\nExpecting "+E.join(", ")+", got '"+(this.terminals_[m]||m)+"'":"Parse error on line "+(c+1)+": Unexpected "+(m==f?"end of input":"'"+(this.terminals_[m]||m)+"'"),this.parseError(A,{text:this.lexer.match,token:this.terminals_[m]||m,line:this.lexer.yylineno,loc:d,expected:E})}if(b[0]instanceof Array&&b.length>1)throw new Error("Parse Error: multiple actions possible at state: "+v+", token: "+m);switch(b[0]){case 1:r.push(m),i.push(this.lexer.yytext),o.push(this.lexer.yylloc),r.push(b[1]),m=null,g?(m=g,g=null):(u=this.lexer.yyleng,a=this.lexer.yytext,c=this.lexer.yylineno,d=this.lexer.yylloc,l>0&&l--);break;case 2:if(S=this.productions_[b[1]][1],k.$=i[i.length-S],k._$={first_line:o[o.length-(S||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(S||1)].first_column,last_column:o[o.length-1].last_column},y&&(k._$.range=[o[o.length-(S||1)].range[0],o[o.length-1].range[1]]),x=this.performAction.apply(k,[a,u,c,this.yy,b[1],i,o].concat(p)),"undefined"!=typeof x)return x;S&&(r=r.slice(0,-1*S*2),i=i.slice(0,-1*S),o=o.slice(0,-1*S)),r.push(this.productions_[b[1]][0]),i.push(k.$),o.push(k._$),w=s[r[r.length-2]][r[r.length-1]],r.push(w);break;case 3:return!0}}return!0}},i=n(341).transform,o=!1,s=function(){var e={EOF:1,parseError:function(e,t){if(!this.yy.parser)throw new Error(e);this.yy.parser.parseError(e,t)},setInput:function(e){return this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var e=this._input[0];this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e;var t=e.match(/(?:\r\n?|\n).*/g);return t?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},unput:function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t-1),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(e){this.unput(this.match.slice(e))},pastInput:function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?"...":"")+e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var e=this.pastInput(),t=new Array(e.length+1).join("-");return e+this.upcomingInput()+"\n"+t+"^"},test_match:function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var o in i)this[o]=i[o];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),o=0;ot[0].length)){if(t=n,r=o,this.options.backtrack_lexer){if(e=this.test_match(n,i[o]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null, +line:this.yylineno})},lex:function(){var e=this.next();return e?e:this.lex()},begin:function(e){this.conditionStack.push(e)},popState:function(){var e=this.conditionStack.length-1;return e>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:"INITIAL"},pushState:function(e){this.begin(e)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(e,t,n,r){switch(n){case 0:return this.pushState("code"),5;case 1:return 43;case 2:return 44;case 3:return 45;case 4:return 46;case 5:return 47;case 6:break;case 7:break;case 8:break;case 9:return t.yytext=t.yytext.substr(1,t.yyleng-2),40;case 10:return 41;case 11:return t.yytext=t.yytext.substr(1,t.yyleng-2),42;case 12:return t.yytext=t.yytext.substr(1,t.yyleng-2),42;case 13:return 28;case 14:return 30;case 15:return 31;case 16:return this.pushState(o?"ebnf":"bnf"),5;case 17:e.options||(e.options={}),o=e.options.ebnf=!0;break;case 18:return 48;case 19:return 11;case 20:return 22;case 21:return 23;case 22:return 24;case 23:return 20;case 24:return 18;case 25:return 13;case 26:break;case 27:break;case 28:return t.yytext=t.yytext.substr(2,t.yyleng-4),15;case 29:return t.yytext=t.yytext.substr(2,t.yytext.length-4),15;case 30:return e.depth=0,this.pushState("action"),49;case 31:return t.yytext=t.yytext.substr(2,t.yyleng-2),52;case 32:break;case 33:return 8;case 34:return 54;case 35:return 54;case 36:return 54;case 37:return 54;case 38:return 54;case 39:return 54;case 40:return 54;case 41:return e.depth++,49;case 42:return 0==e.depth?this.begin(o?"ebnf":"bnf"):e.depth--,51;case 43:return 9}},rules:[/^(?:%%)/,/^(?:\()/,/^(?:\))/,/^(?:\*)/,/^(?:\?)/,/^(?:\+)/,/^(?:\s+)/,/^(?:\/\/.*)/,/^(?:\/\*(.|\n|\r)*?\*\/)/,/^(?:\[([a-zA-Z][a-zA-Z0-9_-]*)\])/,/^(?:([a-zA-Z][a-zA-Z0-9_-]*))/,/^(?:"[^"]+")/,/^(?:'[^']+')/,/^(?::)/,/^(?:;)/,/^(?:\|)/,/^(?:%%)/,/^(?:%ebnf\b)/,/^(?:%prec\b)/,/^(?:%start\b)/,/^(?:%left\b)/,/^(?:%right\b)/,/^(?:%nonassoc\b)/,/^(?:%parse-param\b)/,/^(?:%options\b)/,/^(?:%lex[\w\W]*?\/lex\b)/,/^(?:%[a-zA-Z]+[^\r\n]*)/,/^(?:<[a-zA-Z]*>)/,/^(?:\{\{[\w\W]*?\}\})/,/^(?:%\{(.|\r|\n)*?%\})/,/^(?:\{)/,/^(?:->.*)/,/^(?:.)/,/^(?:$)/,/^(?:\/\*(.|\n|\r)*?\*\/)/,/^(?:\/\/.*)/,/^(?:\/[^ \/]*?['"{}'][^ ]*?\/)/,/^(?:"(\\\\|\\"|[^"])*")/,/^(?:'(\\\\|\\'|[^'])*')/,/^(?:[\/"'][^{}\/"']+)/,/^(?:[^{}\/"']+)/,/^(?:\{)/,/^(?:\})/,/^(?:(.|\n|\r)+)/],conditions:{bnf:{rules:[0,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33],inclusive:!0},ebnf:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33],inclusive:!0},action:{rules:[33,34,35,36,37,38,39,40,41,42],inclusive:!1},code:{rules:[33,43],inclusive:!1},INITIAL:{rules:[6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33],inclusive:!0}}};return e}();return r.lexer=s,t.prototype=r,r.Parser=t,new t}();t.parser=i,t.Parser=i.Parser,t.parse=function(){return i.parse.apply(i,arguments)},t.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),e.exit(1));var i=n(336).readFileSync(n(337).normalize(r[1]),"utf8");return t.parser.parse(i)},"undefined"!=typeof r&&n.c[0]===r&&t.main(e.argv.slice(1))}).call(t,n(330),n(335)(e))},function(e,t,n){var r=function(){var e=n(342),t=function(e,t,n){var o=e[0],s=e[1],a=!1;if("xalias"===o&&(o=e[1],s=e[2],a=e[3],o?e=e.slice(1,2):(e=s,o=e[0],s=e[1])),"symbol"===o){var c;c="\\"===e[1][0]?e[1][1]:"'"===e[1][0]?e[1].substring(1,e[1].length-1):e[1],n(c+(a?"["+a+"]":""))}else if("+"===o){a||(a=t.production+"_repetition_plus"+t.repid++),n(a),t=i(a,t.grammar);var u=r([s],t);t.grammar[a]=[[u,"$$ = [$1];"],[a+" "+u,"$1.push($2);"]]}else"*"===o?(a||(a=t.production+"_repetition"+t.repid++),n(a),t=i(a,t.grammar),t.grammar[a]=[["","$$ = [];"],[a+" "+r([s],t),"$1.push($2);"]]):"?"===o?(a||(a=t.production+"_option"+t.optid++),n(a),t=i(a,t.grammar),t.grammar[a]=["",r([s],t)]):"()"===o&&(1==s.length?n(r(s[0],t)):(a||(a=t.production+"_group"+t.groupid++),n(a),t=i(a,t.grammar),t.grammar[a]=s.map(function(e){return r(e,t)})))},r=function(e,n){return e.reduce(function(e,r){return t(r,n,function(t){e.push(t)}),e},[]).join(" ")},i=function(e,t){return{production:e,repid:0,groupid:0,optid:0,grammar:t}},o=function(t,n,o){var s=i(t,o);return n.map(function(t){var n=null,i=null;"string"!=typeof t&&(n=t[1],i=t[2],t=t[0]);var o=e.parse(t);t=r(o,s);var a=[t];return n&&a.push(n),i&&a.push(i),1==a.length?a[0]:a})},s=function(e){Object.keys(e).forEach(function(t){e[t]=o(t,e[t],e)})};return{transform:function(e){return s(e),e}}}();t.transform=r.transform},function(e,t,n){(function(e,r){var i=function(){function e(){this.yy={}}var t={trace:function(){},yy:{},symbols_:{error:2,production:3,handle:4,EOF:5,handle_list:6,"|":7,expression_suffix:8,expression:9,suffix:10,ALIAS:11,symbol:12,"(":13,")":14,"*":15,"?":16,"+":17,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",7:"|",11:"ALIAS",12:"symbol",13:"(",14:")",15:"*",16:"?",17:"+"},productions_:[0,[3,2],[6,1],[6,3],[4,0],[4,2],[8,3],[8,2],[9,1],[9,3],[10,0],[10,1],[10,1],[10,1]],performAction:function(e,t,n,r,i,o,s){var a=o.length-1;switch(i){case 1:return o[a-1];case 2:this.$=[o[a]];break;case 3:o[a-2].push(o[a]);break;case 4:this.$=[];break;case 5:o[a-1].push(o[a]);break;case 6:this.$=["xalias",o[a-1],o[a-2],o[a]];break;case 7:o[a]?this.$=[o[a],o[a-1]]:this.$=o[a-1];break;case 8:this.$=["symbol",o[a]];break;case 9:this.$=["()",o[a-1]]}},table:[{3:1,4:2,5:[2,4],12:[2,4],13:[2,4]},{1:[3]},{5:[1,3],8:4,9:5,12:[1,6],13:[1,7]},{1:[2,1]},{5:[2,5],7:[2,5],12:[2,5],13:[2,5],14:[2,5]},{5:[2,10],7:[2,10],10:8,11:[2,10],12:[2,10],13:[2,10],14:[2,10],15:[1,9],16:[1,10],17:[1,11]},{5:[2,8],7:[2,8],11:[2,8],12:[2,8],13:[2,8],14:[2,8],15:[2,8],16:[2,8],17:[2,8]},{4:13,6:12,7:[2,4],12:[2,4],13:[2,4],14:[2,4]},{5:[2,7],7:[2,7],11:[1,14],12:[2,7],13:[2,7],14:[2,7]},{5:[2,11],7:[2,11],11:[2,11],12:[2,11],13:[2,11],14:[2,11]},{5:[2,12],7:[2,12],11:[2,12],12:[2,12],13:[2,12],14:[2,12]},{5:[2,13],7:[2,13],11:[2,13],12:[2,13],13:[2,13],14:[2,13]},{7:[1,16],14:[1,15]},{7:[2,2],8:4,9:5,12:[1,6],13:[1,7],14:[2,2]},{5:[2,6],7:[2,6],12:[2,6],13:[2,6],14:[2,6]},{5:[2,9],7:[2,9],11:[2,9],12:[2,9],13:[2,9],14:[2,9],15:[2,9],16:[2,9],17:[2,9]},{4:17,7:[2,4],12:[2,4],13:[2,4],14:[2,4]},{7:[2,3],8:4,9:5,12:[1,6],13:[1,7],14:[2,3]}],defaultActions:{3:[2,1]},parseError:function(e,t){if(!t.recoverable)throw new Error(e);this.trace(e)},parse:function(e){function t(){var e;return e=n.lexer.lex()||f,"number"!=typeof e&&(e=n.symbols_[e]||e),e}var n=this,r=[0],i=[null],o=[],s=this.table,a="",c=0,u=0,l=0,h=2,f=1,p=o.slice.call(arguments,1);this.lexer.setInput(e),this.lexer.yy=this.yy,this.yy.lexer=this.lexer,this.yy.parser=this,"undefined"==typeof this.lexer.yylloc&&(this.lexer.yylloc={});var d=this.lexer.yylloc;o.push(d);var y=this.lexer.options&&this.lexer.options.ranges;"function"==typeof this.yy.parseError?this.parseError=this.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var m,g,v,b,x,_,S,w,E,k={};;){if(v=r[r.length-1],this.defaultActions[v]?b=this.defaultActions[v]:(null!==m&&"undefined"!=typeof m||(m=t()),b=s[v]&&s[v][m]),"undefined"==typeof b||!b.length||!b[0]){var A="";E=[];for(_ in s[v])this.terminals_[_]&&_>h&&E.push("'"+this.terminals_[_]+"'");A=this.lexer.showPosition?"Parse error on line "+(c+1)+":\n"+this.lexer.showPosition()+"\nExpecting "+E.join(", ")+", got '"+(this.terminals_[m]||m)+"'":"Parse error on line "+(c+1)+": Unexpected "+(m==f?"end of input":"'"+(this.terminals_[m]||m)+"'"),this.parseError(A,{text:this.lexer.match,token:this.terminals_[m]||m,line:this.lexer.yylineno,loc:d,expected:E})}if(b[0]instanceof Array&&b.length>1)throw new Error("Parse Error: multiple actions possible at state: "+v+", token: "+m);switch(b[0]){case 1:r.push(m),i.push(this.lexer.yytext),o.push(this.lexer.yylloc),r.push(b[1]),m=null,g?(m=g,g=null):(u=this.lexer.yyleng,a=this.lexer.yytext,c=this.lexer.yylineno,d=this.lexer.yylloc,l>0&&l--);break;case 2:if(S=this.productions_[b[1]][1],k.$=i[i.length-S],k._$={first_line:o[o.length-(S||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(S||1)].first_column,last_column:o[o.length-1].last_column},y&&(k._$.range=[o[o.length-(S||1)].range[0],o[o.length-1].range[1]]),x=this.performAction.apply(k,[a,u,c,this.yy,b[1],i,o].concat(p)),"undefined"!=typeof x)return x;S&&(r=r.slice(0,-1*S*2),i=i.slice(0,-1*S),o=o.slice(0,-1*S)),r.push(this.productions_[b[1]][0]),i.push(k.$),o.push(k._$),w=s[r[r.length-2]][r[r.length-1]],r.push(w);break;case 3:return!0}}return!0}},n=function(){var e={EOF:1,parseError:function(e,t){if(!this.yy.parser)throw new Error(e);this.yy.parser.parseError(e,t)},setInput:function(e){return this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var e=this._input[0];this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e;var t=e.match(/(?:\r\n?|\n).*/g);return t?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},unput:function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t-1),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(e){this.unput(this.match.slice(e))},pastInput:function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?"...":"")+e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var e=this.pastInput(),t=new Array(e.length+1).join("-");return e+this.upcomingInput()+"\n"+t+"^"},test_match:function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var o in i)this[o]=i[o];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),o=0;ot[0].length)){if(t=n,r=o,this.options.backtrack_lexer){if(e=this.test_match(n,i[o]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var e=this.next();return e?e:this.lex()},begin:function(e){this.conditionStack.push(e)},popState:function(){var e=this.conditionStack.length-1;return e>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:"INITIAL"},pushState:function(e){this.begin(e)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(e,t,n,r){switch(n){case 0:break;case 1:return 12;case 2:return t.yytext=t.yytext.substr(1,t.yyleng-2),11;case 3:return 12;case 4:return 12;case 5:return"bar";case 6:return 13;case 7:return 14;case 8:return 15;case 9:return 16;case 10:return 7;case 11:return 17;case 12:return 5}},rules:[/^(?:\s+)/,/^(?:([a-zA-Z][a-zA-Z0-9_-]*))/,/^(?:\[([a-zA-Z][a-zA-Z0-9_-]*)\])/,/^(?:'[^']*')/,/^(?:\.)/,/^(?:bar\b)/,/^(?:\()/,/^(?:\))/,/^(?:\*)/,/^(?:\?)/,/^(?:\|)/,/^(?:\+)/,/^(?:$)/],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12],inclusive:!0}}};return e}();return t.lexer=n,e.prototype=t,t.Parser=e,new e}();t.parser=i,t.Parser=i.Parser,t.parse=function(){return i.parse.apply(i,arguments)},t.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),e.exit(1));var i=n(336).readFileSync(n(337).normalize(r[1]),"utf8");return t.parser.parse(i)},"undefined"!=typeof r&&n.c[0]===r&&t.main(e.argv.slice(1))}).call(t,n(330),n(335)(e))},function(e,t,n){/*! Copyright (c) 2011, Lloyd Hilaiel, ISC License */ +!function(e){function t(e){try{return JSON&&JSON.parse?JSON.parse(e):new Function("return "+e)()}catch(e){n("ijs",e.message)}}function n(e,t){throw new Error(_[e]+(t&&" in '"+t+"'"))}function r(e,r){r||(r=0);var i=w.exec(e.substr(r));if(i){r+=i[0].length;var o;return i[1]?o=[r," "]:i[2]?o=[r,i[0]]:i[3]?o=[r,S.typ,i[0]]:i[4]?o=[r,S.psc,i[0]]:i[5]?o=[r,S.psf,i[0]]:i[6]?n("upc",e):i[8]?o=[r,i[7]?S.ide:S.str,t(i[8])]:i[9]?n("ujs",e):i[10]&&(o=[r,S.ide,i[10].replace(/\\([^\r\n\f0-9a-fA-F])/g,"$1")]),o}}function i(e,t){return typeof e===t}function o(e,n){var r,i=k.exec(e.substr(n));if(i)return n+=i[0].length,r=i[1]||i[2]||i[3]||i[5]||i[6],i[1]||i[2]||i[3]?[n,0,t(r)]:i[4]?[n,0,void 0]:[n,r]}function s(e,t){t||(t=0);var r,i=o(e,t);if(i&&"("===i[1]){r=s(e,i[0]);var a=o(e,r[0]);a&&")"===a[1]||n("epex",e),t=a[0],r=["(",r[1]]}else!i||i[1]&&"x"!=i[1]?n("ee",e+" - "+(i[1]&&i[1])):(r="x"===i[1]?void 0:i[2],t=i[0]);var c=o(e,t);if(!c||")"==c[1])return[t,r];"x"!=c[1]&&c[1]||n("bop",e+" - "+(c[1]&&c[1]));var u=s(e,c[0]);t=u[0],u=u[1];var l;if("object"!=typeof u||"("===u[0]||A[c[1]][0]=A[u[0][1]][0];)u=u[0];u[0]=[r,c[1],u[0]]}return[t,l]}function a(e,t){function n(e){return"object"!=typeof e||null===e?e:"("===e[0]?n(e[1]):[n(e[0]),e[1],n(e[2])]}var r=s(e,t?t:0);return[r[0],n(r[1])]}function c(e,t){if(void 0===e)return t;if(null===e||"object"!=typeof e)return e;var n=c(e[0],t),r=c(e[2],t);return A[e[1]][1](n,r)}function u(e,t,i,o){i||(o={});var s,a,c=[];for(t||(t=0);;){var u=f(e,t,o);if(c.push(u[1]),u=r(e,t=u[0]),u&&" "===u[1]&&(u=r(e,t=u[0])),!u)break;if(">"===u[1]||"~"===u[1])"~"===u[1]&&(o.usesSiblingOp=!0),c.push(u[1]),t=u[0];else if(","===u[1])void 0===s?s=[",",c]:s.push(c),c=[],t=u[0];else if(")"===u[1]){i||n("ucp",u[1]),a=1,t=u[0];break}}i&&!a&&n("mcp",e),s&&s.push(c);var l;return l=!i&&o.usesSiblingOp?h(s?s:c):s?s:c,[t,l]}function l(e){for(var t,n=[],r=0;r"!=e[r-2])&&(t=e.slice(0,r-1),t=t.concat([{has:[[{pc:":root"},">",e[r-1]]]},">"]),t=t.concat(e.slice(r+1)),n.push(t)),r>1){var i=">"===e[r-2]?r-3:r-2;t=e.slice(0,i);var o={};for(var s in e[i])e[i].hasOwnProperty(s)&&(o[s]=e[i][s]);o.has||(o.has=[]),o.has.push([{pc:":root"},">",e[r-1]]),t=t.concat(o,">",e.slice(r+1)),n.push(t)}break}return r==e.length?e:n.length>1?[","].concat(n):n[0]}function h(e){if(","===e[0]){for(var t=[","],n=n;n"===t[0]?t[1]:t[0],u=!0;if(a.type&&(u=u&&a.type===d(e)),a.id&&(u=u&&a.id===n),u&&a.pf&&(":nth-last-child"===a.pf?r=i-r:r++,0===a.a?u=a.b===r:(o=(r-a.b)%a.a,u=!o&&r*a.a+a.b>=0)),u&&a.has)for(var l=function(){throw 42},h=0;h"!==t[0]&&":root"!==t[0].pc&&s.push(t),u&&(">"===t[0]?t.length>2&&(u=!1,s.push(t.slice(2))):t.length>1&&(u=!1,s.push(t.slice(1)))),[u,s]}function m(e,t,n,r,i,o){var s,a,c=","===e[0]?e.slice(1):[e],u=[],l=!1,h=0,f=0;for(h=0;h=1&&u.unshift(","),p(t))for(h=0;h\\)\\(])|(string|boolean|null|array|object|number)|(:(?:root|first-child|last-child|only-child))|(:(?:nth-child|nth-last-child|has|expr|val|contains))|(:\\w+)|(?:(\\.)?(\\"(?:[^\\\\\\"]|\\\\[^\\"])*\\"))|(\\")|\\.((?:[_a-zA-Z]|[^\\0-\\0177]|\\\\[^\\r\\n\\f0-9a-fA-F])(?:[_a-zA-Z0-9\\-]|[^\\u0000-\\u0177]|(?:\\\\[^\\r\\n\\f0-9a-fA-F]))*))'),E=/^\s*\(\s*(?:([+\-]?)([0-9]*)n\s*(?:([+\-])\s*([0-9]))?|(odd|even)|([+\-]?[0-9]+))\s*\)/,k=new RegExp('^\\s*(?:(true|false|null)|(-?\\d+(?:\\.\\d*)?(?:[eE][+\\-]?\\d+)?)|("(?:[^\\]|\\[^"])*")|(x)|(&&|\\|\\||[\\$\\^<>!\\*]=|[=+\\-*/%<>])|([\\(\\)]))'),A={"*":[9,function(e,t){return e*t}],"/":[9,function(e,t){return e/t}],"%":[9,function(e,t){return e%t}],"+":[7,function(e,t){return e+t}],"-":[7,function(e,t){return e-t}],"<=":[5,function(e,t){return i(e,"number")&&i(t,"number")&&e<=t}],">=":[5,function(e,t){return i(e,"number")&&i(t,"number")&&e>=t}],"$=":[5,function(e,t){return i(e,"string")&&i(t,"string")&&e.lastIndexOf(t)===e.length-t.length}],"^=":[5,function(e,t){return i(e,"string")&&i(t,"string")&&0===e.indexOf(t)}],"*=":[5,function(e,t){return i(e,"string")&&i(t,"string")&&e.indexOf(t)!==-1}],">":[5,function(e,t){return i(e,"number")&&i(t,"number")&&e>t}],"<":[5,function(e,t){return i(e,"number")&&i(t,"number")&&e=48&&e<=57}function r(e){return"0123456789abcdefABCDEF".indexOf(e)>=0}function i(e){return"01234567".indexOf(e)>=0}function o(e){return 32===e||9===e||11===e||12===e||160===e||e>=5760&&[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].indexOf(e)>=0}function s(e){return 10===e||13===e||8232===e||8233===e}function a(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||92===e||e>=128&&nt.NonAsciiIdentifierStart.test(String.fromCharCode(e))}function c(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||92===e||e>=128&&nt.NonAsciiIdentifierPart.test(String.fromCharCode(e))}function u(e){switch(e){case"class":case"enum":case"export":case"extends":case"import":case"super":return!0;default:return!1}}function l(e){switch(e){case"implements":case"interface":case"package":case"private":case"protected":case"public":case"static":case"yield":case"let":return!0;default:return!1}}function h(e){return"eval"===e||"arguments"===e}function f(e){if(ot&&l(e))return!0;switch(e.length){case 2:return"if"===e||"in"===e||"do"===e;case 3:return"var"===e||"for"===e||"new"===e||"try"===e||"let"===e;case 4:return"this"===e||"else"===e||"case"===e||"void"===e||"with"===e||"enum"===e;case 5:return"while"===e||"break"===e||"catch"===e||"throw"===e||"const"===e||"yield"===e||"class"===e||"super"===e;case 6:return"return"===e||"typeof"===e||"delete"===e||"switch"===e||"export"===e||"import"===e;case 7:return"default"===e||"finally"===e||"extends"===e;case 8:return"function"===e||"continue"===e||"debugger"===e;case 10:return"instanceof"===e;default:return!1}}function p(e,n,r,i,o){var s,a;t("number"==typeof r,"Comment must have valid position"),ft.lastCommentStart>=r||(ft.lastCommentStart=r,s={type:e,value:n},pt.range&&(s.range=[r,i]),pt.loc&&(s.loc=o),pt.comments.push(s),pt.attachComment&&(a={comment:s,leading:null,trailing:null,range:[r,i]},pt.pendingComments.push(a)))}function d(e){var t,n,r,i;for(t=st-e,n={start:{line:at,column:st-ct-e}};st=ut&&M({},tt.UnexpectedToken,"ILLEGAL");else if(42===n){if(47===it.charCodeAt(st+1))return++st,++st,void(pt.comments&&(r=it.slice(e+2,st-2),t.end={line:at,column:st-ct},p("Block",r,e,st,t)));++st}else++st;M({},tt.UnexpectedToken,"ILLEGAL")}function m(){var e,t;for(t=0===st;st"===s&&">"===t&&">"===n&&"="===r?(st+=4,{type:He.Punctuator,value:">>>=",lineNumber:at,lineStart:ct,range:[i,st]}):">"===s&&">"===t&&">"===n?(st+=3,{type:He.Punctuator,value:">>>",lineNumber:at,lineStart:ct,range:[i,st]}):"<"===s&&"<"===t&&"="===n?(st+=3,{type:He.Punctuator,value:"<<=",lineNumber:at,lineStart:ct,range:[i,st]}):">"===s&&">"===t&&"="===n?(st+=3,{type:He.Punctuator,value:">>=",lineNumber:at,lineStart:ct,range:[i,st]}):s===t&&"+-<>&|".indexOf(s)>=0?(st+=2,{type:He.Punctuator,value:s+t,lineNumber:at,lineStart:ct,range:[i,st]}):"<>=!+-*%&|^/".indexOf(s)>=0?(++st,{type:He.Punctuator,value:s,lineNumber:at,lineStart:ct,range:[i,st]}):void M({},tt.UnexpectedToken,"ILLEGAL")}function S(e){for(var t="";st=0&&st0&&(r=pt.tokens[pt.tokens.length-1],r.range[0]===e&&"Punctuator"===r.type&&("/"!==r.value&&"/="!==r.value||pt.tokens.pop())),pt.tokens.push({type:"RegularExpression",value:n.literal,range:[e,st],loc:t})),n}function O(e){return e.type===He.Identifier||e.type===He.Keyword||e.type===He.BooleanLiteral||e.type===He.NullLiteral}function I(){var e,t;if(e=pt.tokens[pt.tokens.length-1],!e)return C();if("Punctuator"===e.type){if("]"===e.value)return _();if(")"===e.value)return t=pt.tokens[pt.openParenToken-1],!t||"Keyword"!==t.type||"if"!==t.value&&"while"!==t.value&&"for"!==t.value&&"with"!==t.value?_():C();if("}"===e.value){if(pt.tokens[pt.openCurlyToken-3]&&"Keyword"===pt.tokens[pt.openCurlyToken-3].type){if(t=pt.tokens[pt.openCurlyToken-4],!t)return _()}else{if(!pt.tokens[pt.openCurlyToken-4]||"Keyword"!==pt.tokens[pt.openCurlyToken-4].type)return _();if(t=pt.tokens[pt.openCurlyToken-5],!t)return C()}return Xe.indexOf(t.value)>=0?_():C()}return C()}return"Keyword"===e.type?C():_()}function N(){var e;return m(),st>=ut?{type:He.EOF,lineNumber:at,lineStart:ct,range:[st,st]}:(e=it.charCodeAt(st),40===e||41===e||58===e?_():39===e||34===e?k():a(e)?x():46===e?n(it.charCodeAt(st+1))?E():_():n(e)?E():pt.tokenize&&47===e?I():_())}function L(){var e,t,n,r,i;return m(),e=st,t={start:{line:at,column:st-ct}},n=N(),t.end={line:at,column:st-ct},n.type!==He.EOF&&(r=[n.range[0],n.range[1]],i=it.slice(n.range[0],n.range[1]),pt.tokens.push({type:Ke[n.type],value:i,range:r,loc:t})),n}function P(){var e;return e=ht,st=e.range[1],at=e.lineNumber,ct=e.lineStart,ht="undefined"!=typeof pt.tokens?L():N(),st=e.range[1],at=e.lineNumber,ct=e.lineStart,e}function T(){var e,t,n;e=st,t=at,n=ct,ht="undefined"!=typeof pt.tokens?L():N(),st=e,at=t,ct=n}function $(){var e,t,n,r;return e=st,t=at,n=ct,m(),r=at!==t,st=e,at=t,ct=n,r}function M(e,n){var r,i=Array.prototype.slice.call(arguments,2),o=n.replace(/%(\d)/g,function(e,n){return t(n>="===e||">>>="===e||"&="===e||"^="===e||"|="===e)}function U(){var e;return 59===it.charCodeAt(st)?void P():(e=at,m(),at===e?B(";")?void P():void(ht.type===He.EOF||B("}")||R(ht)):void 0)}function z(e){return e.type===Qe.Identifier||e.type===Qe.MemberExpression}function V(){var e=[];for(F("[");!B("]");)B(",")?(P(),e.push(null)):(e.push(le()),B("]")||F(","));return F("]"),lt.createArrayExpression(e)}function W(e,t){var n,r;return n=ot,lt.markStart(),r=Re(),t&&ot&&h(e[0].name)&&j(t,tt.StrictParamName),ot=n,lt.markEnd(lt.createFunctionExpression(null,e,[],r))}function J(){var e;return lt.markStart(),e=P(),e.type===He.StringLiteral||e.type===He.NumericLiteral?(ot&&e.octal&&j(e,tt.StrictOctalLiteral),lt.markEnd(lt.createLiteral(e))):lt.markEnd(lt.createIdentifier(e.value))}function Y(){var e,t,n,r,i;return e=ht,lt.markStart(),e.type===He.Identifier?(n=J(),"get"!==e.value||B(":")?"set"!==e.value||B(":")?(F(":"),r=le(),lt.markEnd(lt.createProperty("init",n,r))):(t=J(),F("("),e=ht,e.type!==He.Identifier?(F(")"),j(e,tt.UnexpectedToken,e.value),r=W([])):(i=[de()],F(")"),r=W(i,e)),lt.markEnd(lt.createProperty("set",t,r))):(t=J(),F("("),F(")"),r=W([]),lt.markEnd(lt.createProperty("get",t,r)))):e.type!==He.EOF&&e.type!==He.Punctuator?(t=J(),F(":"),r=le(),lt.markEnd(lt.createProperty("init",t,r))):void R(e)}function Z(){var e,t,n,r,i=[],o={},s=String;for(F("{");!B("}");)e=Y(),t=e.key.type===Qe.Identifier?e.key.name:s(e.key.value),r="init"===e.kind?et.Data:"get"===e.kind?et.Get:et.Set,n="$"+t,Object.prototype.hasOwnProperty.call(o,n)?(o[n]===et.Data?ot&&r===et.Data?j({},tt.StrictDuplicateProperty):r!==et.Data&&j({},tt.AccessorDataProperty):r===et.Data?j({},tt.AccessorDataProperty):o[n]&r&&j({},tt.AccessorGetSet),o[n]|=r):o[n]=r,i.push(e),B("}")||F(",");return F("}"),lt.createObjectExpression(i)}function H(){var e;return F("("),e=he(),F(")"),e}function K(){var e,t,n;return B("(")?H():(e=ht.type,lt.markStart(),e===He.Identifier?n=lt.createIdentifier(P().value):e===He.StringLiteral||e===He.NumericLiteral?(ot&&ht.octal&&j(ht,tt.StrictOctalLiteral),n=lt.createLiteral(P())):e===He.Keyword?G("this")?(P(),n=lt.createThisExpression()):G("function")&&(n=Be()):e===He.BooleanLiteral?(t=P(),t.value="true"===t.value,n=lt.createLiteral(t)):e===He.NullLiteral?(t=P(),t.value=null,n=lt.createLiteral(t)):B("[")?n=V():B("{")?n=Z():(B("/")||B("/="))&&(n="undefined"!=typeof pt.tokens?lt.createLiteral(C()):lt.createLiteral(A()),T()),n?lt.markEnd(n):void R(P()))}function X(){var e=[];if(F("("),!B(")"))for(;st":case"<=":case">=":case"instanceof":n=7;break;case"in":n=t?7:0;break;case"<<":case">>":case">>>":n=8;break;case"+":case"-":n=9;break;case"*":case"/":case"%":n=11}return n}function ce(){var e,t,n,r,i,o,s,a,c,u;if(e=Je(),c=se(),r=ht,i=ae(r,ft.allowIn),0===i)return c;for(r.prec=i,P(),t=[e,Je()],s=se(),o=[c,r,s];(i=ae(ht,ft.allowIn))>0;){for(;o.length>2&&i<=o[o.length-2].prec;)s=o.pop(),a=o.pop().value,c=o.pop(),n=lt.createBinaryExpression(a,c,s),t.pop(),e=t.pop(),e&&e.apply(n),o.push(n),t.push(e);r=P(),r.prec=i,o.push(r),t.push(Je()),n=se(),o.push(n)}for(u=o.length-1,n=o[u],t.pop();u>1;)n=lt.createBinaryExpression(o[u-1].value,o[u-2],n),u-=2,e=t.pop(),e&&e.apply(n);return n}function ue(){var e,t,n,r;return lt.markStart(),e=ce(),B("?")?(P(),t=ft.allowIn,ft.allowIn=!0,n=le(),ft.allowIn=t,F(":"),r=le(),e=lt.markEnd(lt.createConditionalExpression(e,n,r))):lt.markEnd({}),e}function le(){var e,t,n,r;return e=ht,lt.markStart(),r=t=ue(),q()&&(z(t)||j({},tt.InvalidLHSInAssignment),ot&&t.type===Qe.Identifier&&h(t.name)&&j(e,tt.StrictLHSAssignment),e=P(),n=le(),r=lt.createAssignmentExpression(e.value,t,n)),lt.markEndIf(r)}function he(){var e;if(lt.markStart(),e=le(),B(","))for(e=lt.createSequenceExpression([e]);st0?1:0,ct=0,ut=it.length,ht=null,ft={allowIn:!0,labelSet:{},inFunctionBody:!1,inIteration:!1,inSwitch:!1,lastCommentStart:-1},pt={},t=t||{},t.tokens=!0,pt.tokens=[],pt.tokenize=!0,pt.openParenToken=-1,pt.openCurlyToken=-1,pt.range="boolean"==typeof t.range&&t.range,pt.loc="boolean"==typeof t.loc&&t.loc,"boolean"==typeof t.comment&&t.comment&&(pt.comments=[]),"boolean"==typeof t.tolerant&&t.tolerant&&(pt.errors=[]),ut>0&&"undefined"==typeof it[0]&&e instanceof String&&(it=e.valueOf());try{if(T(),ht.type===He.EOF)return pt.tokens;for(r=P();ht.type!==He.EOF;)try{r=P()}catch(e){if(r=ht,pt.errors){pt.errors.push(e);break}throw e}Ve(),i=pt.tokens,"undefined"!=typeof pt.comments&&(i.comments=pt.comments),"undefined"!=typeof pt.errors&&(i.errors=pt.errors)}catch(e){throw e}finally{pt={}}return i}function Ze(e,t){var n,r;r=String,"string"==typeof e||e instanceof String||(e=r(e)),lt=rt,it=e,st=0,at=it.length>0?1:0,ct=0,ut=it.length,ht=null,ft={allowIn:!0,labelSet:{},inFunctionBody:!1,inIteration:!1,inSwitch:!1,lastCommentStart:-1,markerStack:[]},pt={},"undefined"!=typeof t&&(pt.range="boolean"==typeof t.range&&t.range,pt.loc="boolean"==typeof t.loc&&t.loc,pt.attachComment="boolean"==typeof t.attachComment&&t.attachComment,pt.loc&&null!==t.source&&void 0!==t.source&&(pt.source=r(t.source)),"boolean"==typeof t.tokens&&t.tokens&&(pt.tokens=[]),"boolean"==typeof t.comment&&t.comment&&(pt.comments=[]),"boolean"==typeof t.tolerant&&t.tolerant&&(pt.errors=[]),pt.attachComment&&(pt.range=!0,pt.pendingComments=[],pt.comments=[])),ut>0&&"undefined"==typeof it[0]&&e instanceof String&&(it=e.valueOf());try{n=Ue(),"undefined"!=typeof pt.comments&&(n.comments=pt.comments),"undefined"!=typeof pt.tokens&&(Ve(),n.tokens=pt.tokens),"undefined"!=typeof pt.errors&&(n.errors=pt.errors),pt.attachComment&&ze()}catch(e){throw e}finally{pt={}}return n}var He,Ke,Xe,Qe,et,tt,nt,rt,it,ot,st,at,ct,ut,lt,ht,ft,pt;He={BooleanLiteral:1,EOF:2,Identifier:3,Keyword:4,NullLiteral:5,NumericLiteral:6,Punctuator:7,StringLiteral:8,RegularExpression:9},Ke={},Ke[He.BooleanLiteral]="Boolean",Ke[He.EOF]="",Ke[He.Identifier]="Identifier",Ke[He.Keyword]="Keyword",Ke[He.NullLiteral]="Null",Ke[He.NumericLiteral]="Numeric",Ke[He.Punctuator]="Punctuator",Ke[He.StringLiteral]="String",Ke[He.RegularExpression]="RegularExpression",Xe=["(","{","[","in","typeof","instanceof","new","return","case","delete","throw","void","=","+=","-=","*=","/=","%=","<<=",">>=",">>>=","&=","|=","^=",",","+","-","*","/","%","++","--","<<",">>",">>>","&","|","^","!","~","&&","||","?",":","===","==",">=","<=","<",">","!=","!=="],Qe={AssignmentExpression:"AssignmentExpression",ArrayExpression:"ArrayExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DoWhileStatement:"DoWhileStatement",DebuggerStatement:"DebuggerStatement",EmptyStatement:"EmptyStatement",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForInStatement:"ForInStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",Identifier:"Identifier",IfStatement:"IfStatement",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",Program:"Program",Property:"Property",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SwitchStatement:"SwitchStatement",SwitchCase:"SwitchCase",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement"},et={Data:1,Get:2,Set:4},tt={UnexpectedToken:"Unexpected token %0",UnexpectedNumber:"Unexpected number",UnexpectedString:"Unexpected string",UnexpectedIdentifier:"Unexpected identifier",UnexpectedReserved:"Unexpected reserved word",UnexpectedEOS:"Unexpected end of input",NewlineAfterThrow:"Illegal newline after throw",InvalidRegExp:"Invalid regular expression",UnterminatedRegExp:"Invalid regular expression: missing /",InvalidLHSInAssignment:"Invalid left-hand side in assignment",InvalidLHSInForIn:"Invalid left-hand side in for-in",MultipleDefaultsInSwitch:"More than one default clause in switch statement",NoCatchOrFinally:"Missing catch or finally after try",UnknownLabel:"Undefined label '%0'",Redeclaration:"%0 '%1' has already been declared",IllegalContinue:"Illegal continue statement",IllegalBreak:"Illegal break statement",IllegalReturn:"Illegal return statement",StrictModeWith:"Strict mode code may not include a with statement",StrictCatchVariable:"Catch variable may not be eval or arguments in strict mode",StrictVarName:"Variable name may not be eval or arguments in strict mode",StrictParamName:"Parameter name eval or arguments is not allowed in strict mode",StrictParamDupe:"Strict mode function may not have duplicate parameter names",StrictFunctionName:"Function name may not be eval or arguments in strict mode",StrictOctalLiteral:"Octal literals are not allowed in strict mode.",StrictDelete:"Delete of an unqualified identifier in strict mode.",StrictDuplicateProperty:"Duplicate data property in object literal not allowed in strict mode",AccessorDataProperty:"Object literal may not have data and accessor property with the same name",AccessorGetSet:"Object literal may not have multiple get/set accessors with the same name",StrictLHSAssignment:"Assignment to eval or arguments is not allowed in strict mode",StrictLHSPostfix:"Postfix increment/decrement may not have eval or arguments operand in strict mode",StrictLHSPrefix:"Prefix increment/decrement may not have eval or arguments operand in strict mode",StrictReservedWord:"Use of future reserved word in strict mode"},nt={NonAsciiIdentifierStart:new RegExp("[ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԧԱ-Ֆՙա-ևא-תװ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࢠࢢ-ࢬऄ-हऽॐक़-ॡॱ-ॷॹ-ॿঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-ళవ-హఽౘౙౠౡಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೞೠೡೱೲഅ-ഌഎ-ഐഒ-ഺഽൎൠൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛰᜀ-ᜌᜎ-ᜑᜠ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤜᥐ-ᥭᥰ-ᥴᦀ-ᦫᧁ-ᧇᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭋᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᳩ-ᳬᳮ-ᳱᳵᳶᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⸯ々-〇〡-〩〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚗꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞓꞠ-Ɦꟸ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꪀ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꯀ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ]"),NonAsciiIdentifierPart:new RegExp("[ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮ̀-ʹͶͷͺ-ͽΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁ҃-҇Ҋ-ԧԱ-Ֆՙա-և֑-ׇֽֿׁׂׅׄא-תװ-ײؐ-ؚؠ-٩ٮ-ۓە-ۜ۟-۪ۨ-ۼۿܐ-݊ݍ-ޱ߀-ߵߺࠀ-࠭ࡀ-࡛ࢠࢢ-ࢬࣤ-ࣾऀ-ॣ०-९ॱ-ॷॹ-ॿঁ-ঃঅ-ঌএঐও-নপ-রলশ-হ়-ৄেৈো-ৎৗড়ঢ়য়-ৣ০-ৱਁ-ਃਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹ਼ਾ-ੂੇੈੋ-੍ੑਖ਼-ੜਫ਼੦-ੵઁ-ઃઅ-ઍએ-ઑઓ-નપ-રલળવ-હ઼-ૅે-ૉો-્ૐૠ-ૣ૦-૯ଁ-ଃଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହ଼-ୄେୈୋ-୍ୖୗଡ଼ଢ଼ୟ-ୣ୦-୯ୱஂஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹா-ூெ-ைொ-்ௐௗ௦-௯ఁ-ఃఅ-ఌఎ-ఐఒ-నప-ళవ-హఽ-ౄె-ైొ-్ౕౖౘౙౠ-ౣ౦-౯ಂಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹ಼-ೄೆ-ೈೊ-್ೕೖೞೠ-ೣ೦-೯ೱೲംഃഅ-ഌഎ-ഐഒ-ഺഽ-ൄെ-ൈൊ-ൎൗൠ-ൣ൦-൯ൺ-ൿංඃඅ-ඖක-නඳ-රලව-ෆ්ා-ුූෘ-ෟෲෳก-ฺเ-๎๐-๙ກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ູົ-ຽເ-ໄໆ່-ໍ໐-໙ໜ-ໟༀ༘༙༠-༩༹༵༷༾-ཇཉ-ཬཱ-྄྆-ྗྙ-ྼ࿆က-၉ၐ-ႝႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፝-፟ᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛰᜀ-ᜌᜎ-᜔ᜠ-᜴ᝀ-ᝓᝠ-ᝬᝮ-ᝰᝲᝳក-៓ៗៜ៝០-៩᠋-᠍᠐-᠙ᠠ-ᡷᢀ-ᢪᢰ-ᣵᤀ-ᤜᤠ-ᤫᤰ-᤻᥆-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉ᧐-᧙ᨀ-ᨛᨠ-ᩞ᩠-᩿᩼-᪉᪐-᪙ᪧᬀ-ᭋ᭐-᭙᭫-᭳ᮀ-᯳ᰀ-᰷᱀-᱉ᱍ-ᱽ᳐-᳔᳒-ᳶᴀ-ᷦ᷼-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼ‌‍‿⁀⁔ⁱⁿₐ-ₜ⃐-⃥⃜⃡-⃰ℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯ⵿-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⷠ-ⷿⸯ々-〇〡-〯〱-〵〸-〼ぁ-ゖ゙゚ゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘫꙀ-꙯ꙴ-꙽ꙿ-ꚗꚟ-꛱ꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞓꞠ-Ɦꟸ-ꠧꡀ-ꡳꢀ-꣄꣐-꣙꣠-ꣷꣻ꤀-꤭ꤰ-꥓ꥠ-ꥼꦀ-꧀ꧏ-꧙ꨀ-ꨶꩀ-ꩍ꩐-꩙ꩠ-ꩶꩺꩻꪀ-ꫂꫛ-ꫝꫠ-ꫯꫲ-꫶ꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꯀ-ꯪ꯬꯭꯰-꯹가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻ︀-️︠-︦︳︴﹍-﹏ﹰ-ﹴﹶ-ﻼ0-9A-Z_a-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ]")},rt={name:"SyntaxTree",markStart:function(){m(),pt.loc&&(ft.markerStack.push(st-ct),ft.markerStack.push(at)),pt.range&&ft.markerStack.push(st)},processComment:function(e){var t,n,r,i,o;if("undefined"!=typeof e.type&&e.type!==Qe.Program)for(T(),t=0;t=n.comment.range[1]&&(o=n.leading,o?(r=o.range[0],i=o.range[1]-r,e.range[0]<=r&&e.range[1]-e.range[0]>=i&&(n.leading=e)):n.leading=e),e.range[1]<=n.comment.range[0]&&(o=n.trailing,o?(r=o.range[0],i=o.range[1]-r,e.range[0]<=r&&e.range[1]-e.range[0]>=i&&(n.trailing=e)):n.trailing=e)},markEnd:function(e){return pt.range&&(e.range=[ft.markerStack.pop(),st]),pt.loc&&(e.loc={start:{line:ft.markerStack.pop(),column:ft.markerStack.pop()},end:{line:at,column:st-ct}},this.postProcess(e)),pt.attachComment&&this.processComment(e),e},markEndIf:function(e){return e.range||e.loc?(pt.loc&&(ft.markerStack.pop(),ft.markerStack.pop()),pt.range&&ft.markerStack.pop()):this.markEnd(e),e},postProcess:function(e){return pt.source&&(e.loc.source=pt.source),e},createArrayExpression:function(e){return{type:Qe.ArrayExpression,elements:e}},createAssignmentExpression:function(e,t,n){return{type:Qe.AssignmentExpression,operator:e,left:t,right:n}},createBinaryExpression:function(e,t,n){var r="||"===e||"&&"===e?Qe.LogicalExpression:Qe.BinaryExpression;return{type:r,operator:e,left:t,right:n}},createBlockStatement:function(e){return{type:Qe.BlockStatement,body:e}},createBreakStatement:function(e){return{type:Qe.BreakStatement,label:e}},createCallExpression:function(e,t){return{type:Qe.CallExpression,callee:e,arguments:t}},createCatchClause:function(e,t){return{type:Qe.CatchClause,param:e,body:t}},createConditionalExpression:function(e,t,n){return{type:Qe.ConditionalExpression,test:e,consequent:t,alternate:n}},createContinueStatement:function(e){return{type:Qe.ContinueStatement,label:e}},createDebuggerStatement:function(){return{type:Qe.DebuggerStatement}},createDoWhileStatement:function(e,t){return{type:Qe.DoWhileStatement,body:e,test:t}},createEmptyStatement:function(){return{type:Qe.EmptyStatement}},createExpressionStatement:function(e){return{type:Qe.ExpressionStatement,expression:e}},createForStatement:function(e,t,n,r){return{type:Qe.ForStatement,init:e,test:t,update:n,body:r}},createForInStatement:function(e,t,n){return{type:Qe.ForInStatement,left:e,right:t,body:n,each:!1}},createFunctionDeclaration:function(e,t,n,r){return{type:Qe.FunctionDeclaration,id:e,params:t,defaults:n,body:r,rest:null,generator:!1,expression:!1}},createFunctionExpression:function(e,t,n,r){return{type:Qe.FunctionExpression,id:e,params:t,defaults:n,body:r,rest:null,generator:!1,expression:!1}},createIdentifier:function(e){return{type:Qe.Identifier,name:e}},createIfStatement:function(e,t,n){return{type:Qe.IfStatement,test:e,consequent:t,alternate:n}},createLabeledStatement:function(e,t){return{type:Qe.LabeledStatement,label:e,body:t}},createLiteral:function(e){return{type:Qe.Literal,value:e.value,raw:it.slice(e.range[0],e.range[1])}},createMemberExpression:function(e,t,n){return{type:Qe.MemberExpression,computed:"["===e,object:t,property:n}},createNewExpression:function(e,t){return{type:Qe.NewExpression,callee:e,arguments:t}},createObjectExpression:function(e){return{type:Qe.ObjectExpression,properties:e}},createPostfixExpression:function(e,t){return{type:Qe.UpdateExpression,operator:e,argument:t,prefix:!1}},createProgram:function(e){return{type:Qe.Program,body:e}},createProperty:function(e,t,n){return{type:Qe.Property,key:t,value:n,kind:e}},createReturnStatement:function(e){return{type:Qe.ReturnStatement,argument:e}},createSequenceExpression:function(e){return{type:Qe.SequenceExpression,expressions:e}},createSwitchCase:function(e,t){return{type:Qe.SwitchCase,test:e,consequent:t}},createSwitchStatement:function(e,t){return{type:Qe.SwitchStatement,discriminant:e,cases:t}},createThisExpression:function(){return{type:Qe.ThisExpression}},createThrowStatement:function(e){return{type:Qe.ThrowStatement,argument:e}},createTryStatement:function(e,t,n,r){return{type:Qe.TryStatement,block:e,guardedHandlers:t,handlers:n,finalizer:r}},createUnaryExpression:function(e,t){return"++"===e||"--"===e?{type:Qe.UpdateExpression,operator:e,argument:t,prefix:!0}:{type:Qe.UnaryExpression,operator:e,argument:t,prefix:!0}},createVariableDeclaration:function(e,t){return{type:Qe.VariableDeclaration,declarations:e,kind:t}},createVariableDeclarator:function(e,t){return{type:Qe.VariableDeclarator,id:e,init:t}},createWhileStatement:function(e,t){return{type:Qe.WhileStatement,test:e,body:t}},createWithStatement:function(e,t){return{type:Qe.WithStatement,object:e,body:t}}},We.prototype={constructor:We,apply:function(e){pt.range&&(e.range=[this.startIndex,st]),pt.loc&&(e.loc={start:{line:this.startLine,column:this.startColumn},end:{line:at,column:st-ct}},e=lt.postProcess(e)),pt.attachComment&<.processComment(e)}},e.version="1.1.1",e.tokenize=Ye,e.parse=Ze,e.Syntax=function(){var e,t={};"function"==typeof Object.create&&(t=Object.create(null));for(e in Qe)Qe.hasOwnProperty(e)&&(t[e]=Qe[e]);return"function"==typeof Object.freeze&&Object.freeze(t),t}()})},function(e,t,n){(function(e){!function(){"use strict";function r(){return{indent:null,base:null,parse:null,comment:!1,format:{indent:{style:" ",base:0,adjustMultilineComment:!1},newline:"\n",space:" ",json:!1,renumber:!1,hexadecimal:!1,quotes:"single",escapeless:!1,compact:!1,parentheses:!0,semicolons:!0,safeConcatenation:!1},moz:{comprehensionExpressionStartsWithAssignment:!1,starlessGenerator:!1,parenthesizedComprehensionBlock:!1},sourceMap:null,sourceMapRoot:null,sourceMapWithCode:!1,directive:!1,raw:!0,verbatim:null}}function i(e,t){var n="";for(t|=0;t>0;t>>>=1,e+=e)1&t&&(n+=e);return n}function o(e){return/[\r\n]/g.test(e)}function s(e){var t=e.length;return t&&U.code.isLineTerminator(e.charCodeAt(t-1))}function a(e,t){function n(e){return"object"==typeof e&&e instanceof Object&&!(e instanceof RegExp)}var r,i;for(r in t)t.hasOwnProperty(r)&&(i=t[r],n(i)?n(e[r])?a(e[r],i):e[r]=a({},i):e[r]=i);return e}function c(e){var t,n,r,i,o;if(e!==e)throw new Error("Numeric literal whose value is NaN");if(e<0||0===e&&1/e<0)throw new Error("Numeric literal whose value is negative");if(e===1/0)return J?"null":Y?"1e400":"1e+400";if(t=""+e,!Y||t.length<3)return t;for(n=t.indexOf("."),J||48!==t.charCodeAt(0)||1!==n||(n=0,t=t.slice(1)),r=t,t=t.replace("e+","e"),i=0,(o=r.indexOf("e"))>0&&(i=+r.slice(o+1),r=r.slice(0,o)),n>=0&&(i-=r.length-n-1,r=+(r.slice(0,n)+r.slice(n+1))+""),o=0;48===r.charCodeAt(r.length+o-1);)--o;return 0!==o&&(i-=o,r=r.slice(0,o)),0!==i&&(r+="e"+i),(r.length1e12&&Math.floor(e)===e&&(r="0x"+e.toString(16)).length255?"u"+"0000".slice(n.length)+n:0!==e||U.code.isDecimalDigit(t)?11===e?"x0B":"x"+"00".slice(n.length)+n:"0"}return r}function f(e){var t="\\";switch(e){case 92:t+="\\";break;case 10:t+="n";break;case 13:t+="r";break;case 8232:t+="u2028";break;case 8233:t+="u2029";break;default:throw new Error("Incorrectly classified character")}return t}function p(e){var t,n,r,i;for(i="double"===H?'"':"'",t=0,n=e.length;t=32&&r<=126)){s+=h(r,e.charCodeAt(t+1));continue}}s+=String.fromCharCode(r)}if(i=!("double"===H||"auto"===H&&c=0&&!U.code.isLineTerminator(e.charCodeAt(t));--t);return e.length-1-t}function S(e,t){var n,r,i,o,s,a,c,u;for(n=e.split(/\r\n|[\r\n]/),a=Number.MAX_VALUE,r=1,i=n.length;rs&&(a=s)}for("undefined"!=typeof t?(c=V,"*"===n[1][a]&&(t+=" "),V=t):(1&a&&--a,c=V),r=1,i=n.length;r0){for(a=t,o=e.leadingComments[0],t=[],ne&&e.type===F.Program&&0===e.body.length&&t.push("\n"),t.push(w(o)),s(m(t).toString())||t.push("\n"),n=1,r=e.leadingComments.length;n")),e.expression?(t.push(Q),i=M(e.body,{precedence:D.Assignment,allowIn:!0,allowCall:!0}),"{"===i.toString().charAt(0)&&(i=["(",i,")"]),t.push(i)):t.push(A(e.body,!1,!0)),t}function T(e,t,n){var r=["for"+Q+"("];return x(function(){t.left.type===F.VariableDeclaration?x(function(){r.push(t.left.kind+g()),r.push(j(t.left.declarations[0],{allowIn:!1}))}):r.push(M(t.left,{precedence:D.Call,allowIn:!0,allowCall:!0})),r=v(r,e),r=[v(r,M(t.right,{precedence:D.Sequence,allowIn:!0,allowCall:!0})),")"]}),r.push(A(t.body,n)),r}function $(e){var t;if(e.hasOwnProperty("raw")&&oe&&ie.raw)try{if(t=oe(e.raw).body[0].expression,t.type===F.Literal&&t.value===e.value)return e.raw}catch(e){}return null===e.value?"null":"string"==typeof e.value?d(e.value):"number"==typeof e.value?c(e.value):"boolean"==typeof e.value?e.value?"true":"false":l(e.value)}function M(e,t){var n,r,i,a,c,u,l,h,f,p,d,y,b,_,S,w;if(r=t.precedence,y=t.allowIn,b=t.allowCall,i=e.type||t.type,ie.verbatim&&e.hasOwnProperty(ie.verbatim))return I(e,t);switch(i){case F.SequenceExpression:for(n=[],y|=D.Sequence0){for(n.push("("),c=0;c=2&&48===l.charCodeAt(0))&&n.push(".")),n.push("."),n.push(N(e.property))),n=k(n,D.Member,r);break;case F.UnaryExpression:l=M(e.argument,{precedence:D.Unary,allowIn:!0,allowCall:!0}),""===Q?n=v(e.operator,l):(n=[e.operator],e.operator.length>2?n=v(n,l):(p=m(n).toString(),f=p.charCodeAt(p.length-1),d=l.toString().charCodeAt(0),(43===f||45===f)&&f===d||U.code.isIdentifierPart(f)&&U.code.isIdentifierPart(d)?(n.push(g()),n.push(l)):n.push(l))),n=k(n,D.Unary,r);break;case F.YieldExpression:n=e.delegate?"yield*":"yield",e.argument&&(n=v(n,M(e.argument,{precedence:D.Yield,allowIn:!0,allowCall:!0}))),n=k(n,D.Yield,r);break;case F.UpdateExpression:n=e.prefix?k([e.operator,M(e.argument,{precedence:D.Unary,allowIn:!0,allowCall:!0})],D.Unary,r):k([M(e.argument,{precedence:D.Postfix,allowIn:!0,allowCall:!0}),e.operator],D.Postfix,r);break;case F.FunctionExpression:w=e.generator&&!ie.moz.starlessGenerator,n=w?"function*":"function",n=e.id?[n,w?Q:g(),N(e.id),P(e)]:[n+Q,P(e)];break;case F.ArrayPattern:case F.ArrayExpression:if(!e.elements.length){n="[]";break}h=e.elements.length>1,n=["[",h?X:""],x(function(t){for(c=0,u=e.elements.length;c1,x(function(){l=M(e.properties[0],{precedence:D.Sequence,allowIn:!0,allowCall:!0,type:F.Property})}),!h&&!o(m(l).toString())){n=["{",Q,l,Q,"}"];break}x(function(t){if(n=["{",X,t,l],h)for(n.push(","+X),c=1,u=e.properties.length;c0||ie.moz.comprehensionExpressionStartsWithAssignment?n=v(n,l):n.push(l)}),e.filter&&(n=v(n,"if"+Q),l=M(e.filter,{precedence:D.Sequence,allowIn:!0,allowCall:!0}),n=ie.moz.parenthesizedComprehensionBlock?v(n,["(",l,")"]):v(n,l)),ie.moz.comprehensionExpressionStartsWithAssignment||(l=M(e.body,{precedence:D.Assignment,allowIn:!0,allowCall:!0}),n=v(n,l)),n.push(i===F.GeneratorExpression?")":"]");break;case F.ComprehensionBlock:l=e.left.type===F.VariableDeclaration?[e.left.kind,g(),j(e.left.declarations[0],{allowIn:!1})]:M(e.left,{precedence:D.Call,allowIn:!0,allowCall:!0}),l=v(l,e.of?"of":"in"),l=v(l,M(e.right,{precedence:D.Sequence,allowIn:!0,allowCall:!0})),n=ie.moz.parenthesizedComprehensionBlock?["for"+Q+"(",l,")"]:v("for"+Q,l);break;default:throw new Error("Unknown expression type: "+e.type)}return ie.comment&&(n=E(e,n)),m(n,e)}function j(e,t){var n,r,i,o,a,c,u,l,h,f,d;switch(c=!0,f=";",u=!1,l=!1,t&&(c=void 0===t.allowIn||t.allowIn,te||t.semicolonOptional!==!0||(f=""),u=t.functionBody,l=t.directiveContext),e.type){case F.BlockStatement:i=["{",X],x(function(){for(n=0,r=e.body.length;n=0||re&&l&&e.expression.type===F.Literal&&"string"==typeof e.expression.value?i=["(",i,")"+f]:i.push(f);break;case F.ImportDeclaration:0===e.specifiers.length?i=["import",Q,$(e.source)]:("default"===e.kind?i=["import",g(),e.specifiers[0].id.name,g()]:(i=["import",Q,"{"],1===e.specifiers.length?(a=e.specifiers[0],i.push(Q+a.id.name),a.name&&i.push(g()+"as"+g()+a.name.name),i.push(Q+"}"+Q)):(x(function(t){var n,r;for(i.push(X),n=0,r=e.specifiers.length;n0?"\n":""],n=0;n":D.Relational,"<=":D.Relational,">=":D.Relational,in:D.Relational,instanceof:D.Relational,"<<":D.BitwiseSHIFT,">>":D.BitwiseSHIFT,">>>":D.BitwiseSHIFT,"+":D.Additive,"-":D.Additive,"*":D.Multiplicative,"%":D.Multiplicative,"/":D.Multiplicative},z=Array.isArray,z||(z=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),ae={indent:{style:"",base:0},renumber:!0,hexadecimal:!0,quotes:"auto",escapeless:!0,compact:!0,parentheses:!1,semicolons:!1},ce=r().format,t.version=n(360).version,t.generate=R,t.attachComments=q.attachComments,t.Precedence=a({},D),t.browser=!1,t.FORMAT_MINIFY=ae,t.FORMAT_DEFAULTS=ce}()}).call(t,function(){return this}())},function(e,t,n){var r,i,o;!function(n,s){"use strict";i=[t],r=s,o="function"==typeof r?r.apply(t,i):r,!(void 0!==o&&(e.exports=o))}(this,function(e){"use strict";function t(){}function n(e){var t,r,i={};for(t in e)e.hasOwnProperty(t)&&(r=e[t],"object"==typeof r&&null!==r?i[t]=n(r):i[t]=r);return i}function r(e){var t,n={};for(t in e)e.hasOwnProperty(t)&&(n[t]=e[t]);return n}function i(e,t){var n,r,i,o;for(r=e.length,i=0;r;)n=r>>>1,o=i+n,t(e[o])?r=n:(i=o+1,r-=n+1);return i}function o(e,t){var n,r,i,o;for(r=e.length,i=0;r;)n=r>>>1,o=i+n,t(e[o])?(i=o+1,r-=n+1):r=n;return i}function s(e,t){this.parent=e,this.key=t}function a(e,t,n,r){this.node=e,this.path=t,this.wrap=n,this.ref=r}function c(){}function u(e,t){var n=new c;return n.traverse(e,t)}function l(e,t){var n=new c;return n.replace(e,t)}function h(e,t){var n;return n=i(t,function(t){return t.range[0]>e.range[0]}),e.extendedRange=[e.range[0],e.range[1]],n!==t.length&&(e.extendedRange[1]=t[n].range[0]),n-=1,n>=0&&(e.extendedRange[0]=t[n].range[1]),e}function f(e,t,r){var i,o,s,a,c=[];if(!e.range)throw new Error("attachComments needs range information");if(!r.length){if(t.length){for(s=0,o=t.length;se.range[0]));)t.extendedRange[1]===e.range[0]?(e.leadingComments||(e.leadingComments=[]),e.leadingComments.push(t),c.splice(a,1)):a+=1;return a===c.length?y.Break:c[a].extendedRange[0]>e.range[1]?y.Skip:void 0}}),a=0,u(e,{leave:function(e){for(var t;ae.range[1]?y.Skip:void 0}}),e}var p,d,y,m,g,v;p={AssignmentExpression:"AssignmentExpression",ArrayExpression:"ArrayExpression",ArrayPattern:"ArrayPattern",ArrowFunctionExpression:"ArrowFunctionExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ClassBody:"ClassBody",ClassDeclaration:"ClassDeclaration",ClassExpression:"ClassExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DebuggerStatement:"DebuggerStatement",DirectiveStatement:"DirectiveStatement",DoWhileStatement:"DoWhileStatement",EmptyStatement:"EmptyStatement",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForInStatement:"ForInStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",Identifier:"Identifier",IfStatement:"IfStatement",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",MethodDefinition:"MethodDefinition",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",ObjectPattern:"ObjectPattern",Program:"Program",Property:"Property",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SwitchStatement:"SwitchStatement",SwitchCase:"SwitchCase",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement",YieldExpression:"YieldExpression"},d=Array.isArray,d||(d=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),t(r),t(o),m={AssignmentExpression:["left","right"],ArrayExpression:["elements"],ArrayPattern:["elements"],ArrowFunctionExpression:["params","defaults","rest","body"],BlockStatement:["body"],BinaryExpression:["left","right"],BreakStatement:["label"],CallExpression:["callee","arguments"],CatchClause:["param","body"],ClassBody:["body"],ClassDeclaration:["id","body","superClass"],ClassExpression:["id","body","superClass"],ConditionalExpression:["test","consequent","alternate"],ContinueStatement:["label"],DebuggerStatement:[],DirectiveStatement:[],DoWhileStatement:["body","test"],EmptyStatement:[],ExpressionStatement:["expression"],ForStatement:["init","test","update","body"],ForInStatement:["left","right","body"],ForOfStatement:["left","right","body"],FunctionDeclaration:["id","params","defaults","rest","body"],FunctionExpression:["id","params","defaults","rest","body"],Identifier:[],IfStatement:["test","consequent","alternate"],Literal:[],LabeledStatement:["label","body"],LogicalExpression:["left","right"],MemberExpression:["object","property"],MethodDefinition:["key","value"],NewExpression:["callee","arguments"],ObjectExpression:["properties"],ObjectPattern:["properties"],Program:["body"],Property:["key","value"],ReturnStatement:["argument"],SequenceExpression:["expressions"],SwitchStatement:["discriminant","cases"],SwitchCase:["test","consequent"],ThisExpression:[],ThrowStatement:["argument"],TryStatement:["block","handlers","handler","guardedHandlers","finalizer"],UnaryExpression:["argument"],UpdateExpression:["argument"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],WhileStatement:["test","body"],WithStatement:["object","body"],YieldExpression:["argument"]},g={},v={},y={Break:g,Skip:v},s.prototype.replace=function(e){this.parent[this.key]=e},c.prototype.path=function(){function e(e,t){if(d(t))for(r=0,i=t.length;r=0;)if(u=f[l],y=o[u])if(d(y))for(h=y.length;(h-=1)>=0;)y[h]&&(i=s!==p.ObjectExpression&&s!==p.ObjectPattern||"properties"!==f[l]?new a(y[h],[u,h],null,null):new a(y[h],[u,h],"Property",null),n.push(i));else n.push(new a(y,u,null,null))}}else if(i=r.pop(),c=this.__execute(t.leave,i),this.__state===g||c===g)return},c.prototype.replace=function(e,t){var n,r,i,o,c,u,l,h,f,y,b,x,_;for(this.__initialize(e,t),b={},n=this.__worklist,r=this.__leavelist,x={root:e},u=new a(e,null,null,new s(x,"root")),n.push(u),r.push(u);n.length;)if(u=n.pop(),u!==b){if(c=this.__execute(t.enter,u),void 0!==c&&c!==g&&c!==v&&(u.ref.replace(c),u.node=c),this.__state===g||c===g)return x.root;if(i=u.node,i&&(n.push(b),r.push(u),this.__state!==v&&c!==v))for(o=u.wrap||i.type,f=m[o],l=f.length;(l-=1)>=0;)if(_=f[l],y=i[_])if(d(y))for(h=y.length;(h-=1)>=0;)y[h]&&(u=o===p.ObjectExpression&&"properties"===f[l]?new a(y[h],[_,h],"Property",new s(y,h)):new a(y[h],[_,h],null,new s(y,h)),n.push(u));else n.push(new a(y,_,null,new s(i,_)))}else if(u=r.pop(),c=this.__execute(t.leave,u),void 0!==c&&c!==g&&c!==v&&u.ref.replace(c),this.__state===g||c===g)return x.root;return x.root},e.version="1.5.1-dev",e.Syntax=p,e.traverse=u,e.replace=l,e.attachComments=f,e.VisitorKeys=m,e.VisitorOption=y,e.Controller=c})},function(e,t,n){!function(){"use strict";t.code=n(348),t.keyword=n(349)}()},function(e,t){!function(){"use strict";function t(e){return e>=48&&e<=57}function n(e){return t(e)||97<=e&&e<=102||65<=e&&e<=70}function r(e){return e>=48&&e<=55}function i(e){return 32===e||9===e||11===e||12===e||160===e||e>=5760&&[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].indexOf(e)>=0}function o(e){return 10===e||13===e||8232===e||8233===e}function s(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||92===e||e>=128&&c.NonAsciiIdentifierStart.test(String.fromCharCode(e))}function a(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||92===e||e>=128&&c.NonAsciiIdentifierPart.test(String.fromCharCode(e))}var c;c={NonAsciiIdentifierStart:new RegExp("[ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԧԱ-Ֆՙա-ևא-תװ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࢠࢢ-ࢬऄ-हऽॐक़-ॡॱ-ॷॹ-ॿঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-ళవ-హఽౘౙౠౡಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೞೠೡೱೲഅ-ഌഎ-ഐഒ-ഺഽൎൠൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛰᜀ-ᜌᜎ-ᜑᜠ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤜᥐ-ᥭᥰ-ᥴᦀ-ᦫᧁ-ᧇᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭋᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᳩ-ᳬᳮ-ᳱᳵᳶᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⸯ々-〇〡-〩〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚗꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞓꞠ-Ɦꟸ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꪀ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꯀ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ]"),NonAsciiIdentifierPart:new RegExp("[ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮ̀-ʹͶͷͺ-ͽΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁ҃-҇Ҋ-ԧԱ-Ֆՙա-և֑-ׇֽֿׁׂׅׄא-תװ-ײؐ-ؚؠ-٩ٮ-ۓە-ۜ۟-۪ۨ-ۼۿܐ-݊ݍ-ޱ߀-ߵߺࠀ-࠭ࡀ-࡛ࢠࢢ-ࢬࣤ-ࣾऀ-ॣ०-९ॱ-ॷॹ-ॿঁ-ঃঅ-ঌএঐও-নপ-রলশ-হ়-ৄেৈো-ৎৗড়ঢ়য়-ৣ০-ৱਁ-ਃਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹ਼ਾ-ੂੇੈੋ-੍ੑਖ਼-ੜਫ਼੦-ੵઁ-ઃઅ-ઍએ-ઑઓ-નપ-રલળવ-હ઼-ૅે-ૉો-્ૐૠ-ૣ૦-૯ଁ-ଃଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହ଼-ୄେୈୋ-୍ୖୗଡ଼ଢ଼ୟ-ୣ୦-୯ୱஂஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹா-ூெ-ைொ-்ௐௗ௦-௯ఁ-ఃఅ-ఌఎ-ఐఒ-నప-ళవ-హఽ-ౄె-ైొ-్ౕౖౘౙౠ-ౣ౦-౯ಂಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹ಼-ೄೆ-ೈೊ-್ೕೖೞೠ-ೣ೦-೯ೱೲംഃഅ-ഌഎ-ഐഒ-ഺഽ-ൄെ-ൈൊ-ൎൗൠ-ൣ൦-൯ൺ-ൿංඃඅ-ඖක-නඳ-රලව-ෆ්ා-ුූෘ-ෟෲෳก-ฺเ-๎๐-๙ກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ູົ-ຽເ-ໄໆ່-ໍ໐-໙ໜ-ໟༀ༘༙༠-༩༹༵༷༾-ཇཉ-ཬཱ-྄྆-ྗྙ-ྼ࿆က-၉ၐ-ႝႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፝-፟ᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛰᜀ-ᜌᜎ-᜔ᜠ-᜴ᝀ-ᝓᝠ-ᝬᝮ-ᝰᝲᝳក-៓ៗៜ៝០-៩᠋-᠍᠐-᠙ᠠ-ᡷᢀ-ᢪᢰ-ᣵᤀ-ᤜᤠ-ᤫᤰ-᤻᥆-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉ᧐-᧙ᨀ-ᨛᨠ-ᩞ᩠-᩿᩼-᪉᪐-᪙ᪧᬀ-ᭋ᭐-᭙᭫-᭳ᮀ-᯳ᰀ-᰷᱀-᱉ᱍ-ᱽ᳐-᳔᳒-ᳶᴀ-ᷦ᷼-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼ‌‍‿⁀⁔ⁱⁿₐ-ₜ⃐-⃥⃜⃡-⃰ℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯ⵿-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⷠ-ⷿⸯ々-〇〡-〯〱-〵〸-〼ぁ-ゖ゙゚ゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘫꙀ-꙯ꙴ-꙽ꙿ-ꚗꚟ-꛱ꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞓꞠ-Ɦꟸ-ꠧꡀ-ꡳꢀ-꣄꣐-꣙꣠-ꣷꣻ꤀-꤭ꤰ-꥓ꥠ-ꥼꦀ-꧀ꧏ-꧙ꨀ-ꨶꩀ-ꩍ꩐-꩙ꩠ-ꩶꩺꩻꪀ-ꫂꫛ-ꫝꫠ-ꫯꫲ-꫶ꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꯀ-ꯪ꯬꯭꯰-꯹가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻ︀-️︠-︦︳︴﹍-﹏ﹰ-ﹴﹶ-ﻼ0-9A-Z_a-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ]")},e.exports={isDecimalDigit:t,isHexDigit:n,isOctalDigit:r,isWhiteSpace:i,isLineTerminator:o,isIdentifierStart:s,isIdentifierPart:a}}()},function(e,t,n){!function(){"use strict";function t(e){switch(e){case"implements":case"interface":case"package":case"private":case"protected":case"public":case"static":case"let":return!0;default:return!1}}function r(e,t){return!(!t&&"yield"===e)&&i(e,t)}function i(e,n){if(n&&t(e))return!0;switch(e.length){case 2:return"if"===e||"in"===e||"do"===e;case 3:return"var"===e||"for"===e||"new"===e||"try"===e;case 4:return"this"===e||"else"===e||"case"===e||"void"===e||"with"===e||"enum"===e;case 5:return"while"===e||"break"===e||"catch"===e||"throw"===e||"const"===e||"yield"===e||"class"===e||"super"===e;case 6:return"return"===e||"typeof"===e||"delete"===e||"switch"===e||"export"===e||"import"===e;case 7:return"default"===e||"finally"===e||"extends"===e;case 8:return"function"===e||"continue"===e||"debugger"===e;case 10:return"instanceof"===e;default:return!1}}function o(e){return"eval"===e||"arguments"===e}function s(e){var t,n,r;if(0===e.length)return!1;if(r=e.charCodeAt(0),!a.isIdentifierStart(r)||92===r)return!1;for(t=1,n=e.length;t0&&e.column>=0)||t||n||r)&&!(e&&"line"in e&&"column"in e&&t&&"line"in t&&"column"in t&&e.line>0&&e.column>=0&&t.line>0&&t.column>=0&&n))throw new Error("Invalid mapping: "+JSON.stringify({generated:e,source:n,original:t,name:r}))},i.prototype._serializeMappings=function(){for(var e,t=0,n=1,r=0,i=0,a=0,c=0,u="",l=this._mappings.toArray(),h=0,f=l.length;h0){if(!s.compareByGeneratedPositions(e,l[h-1]))continue;u+=","}u+=o.encode(e.generatedColumn-t),t=e.generatedColumn,null!=e.source&&(u+=o.encode(this._sources.indexOf(e.source)-c),c=this._sources.indexOf(e.source),u+=o.encode(e.originalLine-1-i),i=e.originalLine-1,u+=o.encode(e.originalColumn-r),r=e.originalColumn,null!=e.name&&(u+=o.encode(this._names.indexOf(e.name)-a),a=this._names.indexOf(e.name)))}return u},i.prototype._generateSourcesContent=function(e,t){return e.map(function(e){if(!this._sourcesContents)return null;null!=t&&(e=s.relative(t,e));var n=s.toSetString(e);return Object.prototype.hasOwnProperty.call(this._sourcesContents,n)?this._sourcesContents[n]:null},this)},i.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return null!=this._file&&(e.file=this._file),null!=this._sourceRoot&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e},i.prototype.toString=function(){return JSON.stringify(this)},t.SourceMapGenerator=i}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))},function(e,t,n){var r;r=function(e,t,r){function i(e){return e<0?(-e<<1)+1:(e<<1)+0}function o(e){var t=1===(1&e),n=e>>1;return t?-n:n}var s=n(353),a=5,c=1<>>=a,r>0&&(t|=l),n+=s.encode(t);while(r>0);return n},t.decode=function(e,t){var n,r,i=0,c=e.length,h=0,f=0;do{if(i>=c)throw new Error("Expected more digits in base 64 VLQ value.");r=s.decode(e.charAt(i++)),n=!!(r&l),r&=u,h+=r<=0;u--)r=a[u],"."===r?a.splice(u,1):".."===r?c++:c>0&&(""===r?(a.splice(u+1,c),c=0):(a.splice(u,2),c--));return t=a.join("/"),""===t&&(t=s?"/":"."),n?(n.path=t,o(n)):t}function a(e,t){""===e&&(e="."),""===t&&(t=".");var n=i(t),r=i(e);if(r&&(e=r.path||"/"),n&&!n.scheme)return r&&(n.scheme=r.scheme),o(n);if(n||t.match(y))return t;if(r&&!r.host&&!r.path)return r.host=t,o(r);var a="/"===t.charAt(0)?t:s(e.replace(/\/+$/,"")+"/"+t);return r?(r.path=a,o(r)):a}function c(e,t){""===e&&(e="."),e=e.replace(/\/$/,"");var n=i(e);return"/"==t.charAt(0)&&n&&"/"==n.path?t.slice(1):0===t.indexOf(e+"/")?t.substr(e.length+1):t}function u(e){return"$"+e}function l(e){return e.substr(1)}function h(e,t){var n=e||"",r=t||"";return(n>r)-(n=0&&en||r==n&&o>=i||s.compareByGeneratedPositions(e,t)<=0}function o(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}var s=n(354);o.prototype.unsortedForEach=function(e,t){this._array.forEach(e,t)},o.prototype.add=function(e){i(this._last,e)?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))},o.prototype.toArray=function(){return this._sorted||(this._array.sort(s.compareByGeneratedPositions),this._sorted=!0),this._array},t.MappingList=o}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))},function(e,t,n){var r;r=function(e,t,r){function i(e){var t=e;"string"==typeof e&&(t=JSON.parse(e.replace(/^\)\]\}'/,"")));var n=o.getArg(t,"version"),r=o.getArg(t,"sources"),i=o.getArg(t,"names",[]),s=o.getArg(t,"sourceRoot",null),c=o.getArg(t,"sourcesContent",null),u=o.getArg(t,"mappings"),l=o.getArg(t,"file",null);if(n!=this._version)throw new Error("Unsupported version: "+n);r=r.map(o.normalize),this._names=a.fromArray(i,!0),this._sources=a.fromArray(r,!0),this.sourceRoot=s,this.sourcesContent=c,this._mappings=u,this.file=l}var o=n(354),s=n(358),a=n(355).ArraySet,c=n(352);i.fromSourceMap=function(e){var t=Object.create(i.prototype);return t._names=a.fromArray(e._names.toArray(),!0),t._sources=a.fromArray(e._sources.toArray(),!0),t.sourceRoot=e._sourceRoot,t.sourcesContent=e._generateSourcesContent(t._sources.toArray(),t.sourceRoot),t.file=e._file,t.__generatedMappings=e._mappings.toArray().slice(),t.__originalMappings=e._mappings.toArray().slice().sort(o.compareByOriginalPositions),t},i.prototype._version=3,Object.defineProperty(i.prototype,"sources",{get:function(){return this._sources.toArray().map(function(e){return null!=this.sourceRoot?o.join(this.sourceRoot,e):e},this)}}),i.prototype.__generatedMappings=null,Object.defineProperty(i.prototype,"_generatedMappings",{get:function(){return this.__generatedMappings||(this.__generatedMappings=[],this.__originalMappings=[],this._parseMappings(this._mappings,this.sourceRoot)),this.__generatedMappings}}),i.prototype.__originalMappings=null,Object.defineProperty(i.prototype,"_originalMappings",{get:function(){return this.__originalMappings||(this.__generatedMappings=[],this.__originalMappings=[],this._parseMappings(this._mappings,this.sourceRoot)),this.__originalMappings}}),i.prototype._nextCharIsMappingSeparator=function(e){var t=e.charAt(0);return";"===t||","===t},i.prototype._parseMappings=function(e,t){for(var n,r=1,i=0,s=0,a=0,u=0,l=0,h=e,f={};h.length>0;)if(";"===h.charAt(0))r++,h=h.slice(1),i=0;else if(","===h.charAt(0))h=h.slice(1);else{if(n={},n.generatedLine=r,c.decode(h,f),n.generatedColumn=i+f.value,i=n.generatedColumn,h=f.rest,h.length>0&&!this._nextCharIsMappingSeparator(h)){if(c.decode(h,f),n.source=this._sources.at(u+f.value),u+=f.value,h=f.rest,0===h.length||this._nextCharIsMappingSeparator(h))throw new Error("Found a source, but no line and column");if(c.decode(h,f),n.originalLine=s+f.value,s=n.originalLine,n.originalLine+=1,h=f.rest,0===h.length||this._nextCharIsMappingSeparator(h))throw new Error("Found a source and line, but no column");c.decode(h,f),n.originalColumn=a+f.value,a=n.originalColumn,h=f.rest, +h.length>0&&!this._nextCharIsMappingSeparator(h)&&(c.decode(h,f),n.name=this._names.at(l+f.value),l+=f.value,h=f.rest)}this.__generatedMappings.push(n),"number"==typeof n.originalLine&&this.__originalMappings.push(n)}this.__generatedMappings.sort(o.compareByGeneratedPositions),this.__originalMappings.sort(o.compareByOriginalPositions)},i.prototype._findMapping=function(e,t,n,r,i){if(e[n]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[n]);if(e[r]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[r]);return s.search(e,t,i)},i.prototype.computeColumnSpans=function(){for(var e=0;e=0){var r=this._generatedMappings[n];if(r.generatedLine===t.generatedLine){var i=o.getArg(r,"source",null);return null!=i&&null!=this.sourceRoot&&(i=o.join(this.sourceRoot,i)),{source:i,line:o.getArg(r,"originalLine",null),column:o.getArg(r,"originalColumn",null),name:o.getArg(r,"name",null)}}}return{source:null,line:null,column:null,name:null}},i.prototype.sourceContentFor=function(e){if(!this.sourcesContent)return null;if(null!=this.sourceRoot&&(e=o.relative(this.sourceRoot,e)),this._sources.has(e))return this.sourcesContent[this._sources.indexOf(e)];var t;if(null!=this.sourceRoot&&(t=o.urlParse(this.sourceRoot))){var n=e.replace(/^file:\/\//,"");if("file"==t.scheme&&this._sources.has(n))return this.sourcesContent[this._sources.indexOf(n)];if((!t.path||"/"==t.path)&&this._sources.has("/"+e))return this.sourcesContent[this._sources.indexOf("/"+e)]}throw new Error('"'+e+'" is not in the SourceMap.')},i.prototype.generatedPositionFor=function(e){var t={source:o.getArg(e,"source"),originalLine:o.getArg(e,"line"),originalColumn:o.getArg(e,"column")};null!=this.sourceRoot&&(t.source=o.relative(this.sourceRoot,t.source));var n=this._findMapping(t,this._originalMappings,"originalLine","originalColumn",o.compareByOriginalPositions);if(n>=0){var r=this._originalMappings[n];return{line:o.getArg(r,"generatedLine",null),column:o.getArg(r,"generatedColumn",null),lastColumn:o.getArg(r,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}},i.prototype.allGeneratedPositionsFor=function(e){var t={source:o.getArg(e,"source"),originalLine:o.getArg(e,"line"),originalColumn:1/0};null!=this.sourceRoot&&(t.source=o.relative(this.sourceRoot,t.source));var n=[],r=this._findMapping(t,this._originalMappings,"originalLine","originalColumn",o.compareByOriginalPositions);if(r>=0)for(var i=this._originalMappings[r];i&&i.originalLine===t.originalLine;)n.push({line:o.getArg(i,"generatedLine",null),column:o.getArg(i,"generatedColumn",null),lastColumn:o.getArg(i,"lastGeneratedColumn",null)}),i=this._originalMappings[--r];return n.reverse()},i.GENERATED_ORDER=1,i.ORIGINAL_ORDER=2,i.prototype.eachMapping=function(e,t,n){var r,s=t||null,a=n||i.GENERATED_ORDER;switch(a){case i.GENERATED_ORDER:r=this._generatedMappings;break;case i.ORIGINAL_ORDER:r=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}var c=this.sourceRoot;r.map(function(e){var t=e.source;return null!=t&&null!=c&&(t=o.join(c,t)),{source:t,generatedLine:e.generatedLine,generatedColumn:e.generatedColumn,originalLine:e.originalLine,originalColumn:e.originalColumn,name:e.name}}).forEach(e,s)},t.SourceMapConsumer=i}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))},function(e,t,n){var r;r=function(e,t,n){function r(e,t,n,i,o){var s=Math.floor((t-e)/2)+e,a=o(n,i[s],!0);return 0===a?s:a>0?t-s>1?r(s,t,n,i,o):s:s-e>1?r(e,s,n,i,o):e<0?-1:e}t.search=function(e,t,n){return 0===t.length?-1:r(-1,t.length,e,t,n)}}.call(t,n,t,e),!(void 0!==r&&(e.exports=r))},function(e,t,n){var r;r=function(e,t,r){function i(e,t,n,r,i){this.children=[],this.sourceContents={},this.line=null==e?null:e,this.column=null==t?null:t,this.source=null==n?null:n,this.name=null==i?null:i,this[u]=!0,null!=r&&this.add(r)}var o=n(351).SourceMapGenerator,s=n(354),a=/(\r?\n)/,c=10,u="$$$isSourceNode$$$";i.fromStringWithSourceMap=function(e,t,n){function r(e,t){if(null===e||void 0===e.source)o.add(t);else{var r=n?s.join(n,e.source):e.source;o.add(new i(e.originalLine,e.originalColumn,r,t,e.name))}}var o=new i,c=e.split(a),u=function(){var e=c.shift(),t=c.shift()||"";return e+t},l=1,h=0,f=null;return t.eachMapping(function(e){if(null!==f){if(!(l0&&(f&&r(f,u()),o.add(c.join(""))),t.sources.forEach(function(e){var r=t.sourceContentFor(e);null!=r&&(null!=n&&(e=s.join(n,e)),o.setSourceContent(e,r))}),o},i.prototype.add=function(e){if(Array.isArray(e))e.forEach(function(e){this.add(e)},this);else{if(!e[u]&&"string"!=typeof e)throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);e&&this.children.push(e)}return this},i.prototype.prepend=function(e){if(Array.isArray(e))for(var t=e.length-1;t>=0;t--)this.prepend(e[t]);else{if(!e[u]&&"string"!=typeof e)throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);this.children.unshift(e)}return this},i.prototype.walk=function(e){for(var t,n=0,r=this.children.length;n0){for(t=[],n=0;n=0.10.0"},homepage:"http://github.com/Constellation/escodegen",licenses:[{type:"BSD",url:"http://github.com/Constellation/escodegen/raw/master/LICENSE.BSD"}],main:"escodegen.js",maintainers:[{name:"Yusuke Suzuki",email:"utatane.tea@gmail.com",url:"http://github.com/Constellation"}],name:"escodegen",optionalDependencies:{"source-map":"~0.1.33"},repository:{type:"git",url:"git+ssh://git@github.com/Constellation/escodegen.git"},scripts:{build:"cjsify -a path: tools/entry-point.js > escodegen.browser.js","build-min":"cjsify -ma path: tools/entry-point.js > escodegen.browser.min.js",lint:"gulp lint",release:"node tools/release.js",test:"gulp travis","unit-test":"gulp test"},version:"1.3.3"}},function(e,t){e.exports={_args:[["jison@0.4.18","/Users/hayley/Dev/bondage.js"]],_from:"jison@0.4.18",_id:"jison@0.4.18",_inBundle:!1,_integrity:"sha512-FKkCiJvozgC7VTHhMJ00a0/IApSxhlGsFIshLW6trWJ8ONX2TQJBBz6DlcO1Gffy4w9LT+uL+PA+CVnUSJMF7w==",_location:"/jison",_phantomChildren:{},_requested:{type:"version",registry:!0,raw:"jison@0.4.18",name:"jison",escapedName:"jison",rawSpec:"0.4.18",saveSpec:null,fetchSpec:"0.4.18"},_requiredBy:["/"],_resolved:"https://registry.npmjs.org/jison/-/jison-0.4.18.tgz",_spec:"0.4.18",_where:"/Users/hayley/Dev/bondage.js",author:{name:"Zach Carter",email:"zach@carter.name",url:"http://zaa.ch"},bin:{jison:"lib/cli.js"},bugs:{url:"http://github.com/zaach/jison/issues",email:"jison@librelist.com"},dependencies:{JSONSelect:"0.4.0",cjson:"0.3.0","ebnf-parser":"0.1.10",escodegen:"1.3.x",esprima:"1.1.x","jison-lex":"0.3.x","lex-parser":"~0.1.3",nomnom:"1.5.2"},description:"A parser generator with Bison's API",devDependencies:{browserify:"2.x.x",jison:"0.4.x",test:"0.6.x","uglify-js":"~2.4.0"},engines:{node:">=0.4"},homepage:"http://jison.org",keywords:["jison","bison","yacc","parser","generator","lexer","flex","tokenizer","compiler"],license:"MIT",main:"lib/jison",name:"jison",preferGlobal:!0,repository:{type:"git",url:"git://github.com/zaach/jison.git"},scripts:{test:"node tests/all-tests.js"},version:"0.4.18"}},function(e,t){"use strict";function n(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function r(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=function e(){i(this,e)},s=function e(){i(this,e)},a=function e(){i(this,e)},c=function e(){i(this,e)},u=function e(){i(this,e)},l=function e(){i(this,e)},h=function e(){i(this,e)},f=function e(){i(this,e)};e.exports={types:{Text:o,Shortcut:s,Link:a,Conditional:c,Assignment:u,Literal:l,Expression:h,Command:f},RootNode:function e(t){i(this,e),this.name="RootNode",this.dialogNodes=t||[]},DialogNode:function e(t,n){i(this,e),this.type="DialogNode",this.name=n||null,this.content=t},DialogOptionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="DialogOptionNode",o.text=e,o.content=r,o}return r(t,e),t}(s),ConditionalDialogOptionNode:function(e){function t(e,r,o){i(this,t);var s=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return s.type="ConditionalDialogOptionNode",s.text=e,s.content=r,s.conditionalExpression=o,s}return r(t,e),t}(s),IfNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="IfNode",o.expression=e,o.statement=r,o}return r(t,e),t}(c),IfElseNode:function(e){function t(e,r,o){i(this,t);var s=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return s.type="IfElseNode",s.expression=e,s.statement=r,s.elseStatement=o,s}return r(t,e),t}(c),ElseNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="ElseNode",r.statement=e,r}return r(t,e),t}(c),ElseIfNode:function(e){function t(e,r,o){i(this,t);var s=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return s.type="ElseIfNode",s.expression=e,s.statement=r,s.elseStatement=o,s}return r(t,e),t}(c),TextNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="TextNode",r.text=e,r}return r(t,e),t}(o),LinkNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="LinkNode",o.text=e||null,o.identifier=r||o.text,o.selectable=!0,o}return r(t,e),t}(a),NumericLiteralNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="NumericLiteralNode",r.numericLiteral=e,r}return r(t,e),t}(l),StringLiteralNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="StringLiteralNode",r.stringLiteral=e,r}return r(t,e),t}(l),BooleanLiteralNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="BooleanLiteralNode",r.booleanLiteral=e,r}return r(t,e),t}(l),VariableNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="VariableNode",r.variableName=e,r}return r(t,e),t}(l),UnaryMinusExpressionNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="UnaryMinusExpressionNode",r.expression=e,r}return r(t,e),t}(h),ArithmeticExpressionNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="ArithmeticExpressionNode",r.expression=e,r}return r(t,e),t}(h),ArithmeticExpressionAddNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="ArithmeticExpressionAddNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),ArithmeticExpressionMinusNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="ArithmeticExpressionMinusNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),ArithmeticExpressionMultiplyNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="ArithmeticExpressionMultiplyNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),ArithmeticExpressionDivideNode:function e(t,n){i(this,e),this.type="ArithmeticExpressionDivideNode",this.expression1=t,this.expression2=n},BooleanExpressionNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="BooleanExpressionNode",r.booleanExpression=e,r}return r(t,e),t}(h),NegatedBooleanExpressionNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="NegatedBooleanExpressionNode",r.booleanExpression=e,r}return r(t,e),t}(h),BooleanOrExpressionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="BooleanOrExpressionNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),BooleanAndExpressionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="BooleanAndExpressionNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),BooleanXorExpressionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="BooleanXorExpressionNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),EqualToExpressionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="EqualToExpressionNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),NotEqualToExpressionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="EqualToExpressionNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),GreaterThanExpressionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="GreaterThanExpressionNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),GreaterThanOrEqualToExpressionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="GreaterThanOrEqualToExpressionNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),LessThanExpressionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="LessThanExpressionNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),LessThanOrEqualToExpressionNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="LessThanOrEqualToExpressionNode",o.expression1=e,o.expression2=r,o}return r(t,e),t}(h),SetVariableEqualToNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="SetVariableEqualToNode",o.variableName=e,o.expression=r,o}return r(t,e),t}(u),SetVariableAddNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="SetVariableAddNode",o.variableName=e,o.expression=r,o}return r(t,e),t}(u),SetVariableMinusNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="SetVariableMinusNode",o.variableName=e,o.expression=r,o}return r(t,e),t}(u),SetVariableMultipyNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="SetVariableMultipyNode",o.variableName=e,o.expression=r,o}return r(t,e),t}(u),SetVariableDivideNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="SetVariableDivideNode",o.variableName=e,o.expression=r,o}return r(t,e),t}(u),FunctionResultNode:function(e){function t(e,r){i(this,t);var o=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.type="FunctionResultNode",o.functionName=e,o.args=r,o}return r(t,e),t}(l),CommandNode:function(e){function t(e){i(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.type="CommandNode",r.command=e,r}return r(t,e),t}(f)}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=function(){function e(e,t){for(var n=0;nthis.previousLevelOfIndentation)return this.indentation.push([e,!0]),this.shouldTrackNextIndentation=!1,this.yylloc.first_column=this.yylloc.last_column,this.yylloc.last_column+=e,this.yytext="","Indent";if(e=this.lines.length}},{key:"isAtTheEndOfLine",value:function(){return this.yylloc.last_column>=this.getCurrentLine().length}}]),e}();e.exports=s},function(e,t,n){"use strict";function r(){return{base:(new i).addTransition("BeginCommand","command",!0).addTransition("OptionStart","link",!0).addTransition("ShortcutOption","shortcutOption").addTextRule("Text"),shortcutOption:(new i).setTrackNextIndentation(!0).addTransition("BeginCommand","expression",!0).addTextRule("Text","base"),command:(new i).addTransition("If","expression").addTransition("Else").addTransition("ElseIf","expression").addTransition("EndIf").addTransition("Set","assignment").addTransition("EndCommand","base",!0).addTransition("CommandCall","commandOrExpression").addTextRule("Text"),commandOrExpression:(new i).addTransition("EndCommand","base",!0).addTextRule("Text"),assignment:(new i).addTransition("Variable").addTransition("EqualToOrAssign","expression").addTransition("AddAssign","expression").addTransition("MinusAssign","expression").addTransition("MultiplyAssign","expression").addTransition("DivideAssign","expression"),expression:(new i).addTransition("EndCommand","base").addTransition("Number").addTransition("String").addTransition("LeftParen").addTransition("RightParen").addTransition("EqualTo").addTransition("EqualToOrAssign").addTransition("NotEqualTo").addTransition("GreaterThanOrEqualTo").addTransition("GreaterThan").addTransition("LessThanOrEqualTo").addTransition("LessThan").addTransition("Add").addTransition("Minus").addTransition("Multiply").addTransition("Divide").addTransition("And").addTransition("Or").addTransition("Xor").addTransition("Not").addTransition("Variable").addTransition("Comma").addTransition("True").addTransition("False").addTransition("Null").addTransition("Identifier").addTextRule(),link:(new i).addTransition("OptionEnd","base",!0).addTransition("OptionDelimit","linkDestination",!0).addTextRule("Text"),linkDestination:(new i).addTransition("Identifier").addTransition("OptionEnd","base")}}var i=n(365);e.exports={makeStates:r}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=function(){function e(e,t){for(var n=0;n>/,Variable:/\$([A-Za-z0-9_.])+/,ShortcutOption:/->/,OptionStart:/\[\[/,OptionDelimit:/\|/,OptionEnd:/\]\]/,If:/if(?!\w)/,ElseIf:/elseif(?!\w)/,Else:/else(?!\w)/,EndIf:/endif(?!\w)/,Set:/set(?!\w)/,True:/true(?!\w)/,False:/false(?!\w)/,Null:/null(?!\w)/,LeftParen:/\(/,RightParen:/\)/,Comma:/,/,EqualTo:/(==|is(?!\w)|eq(?!\w))/,GreaterThan:/(>|gt(?!\w))/,GreaterThanOrEqualTo:/(>=|gte(?!\w))/,LessThan:/(<|lt(?!\w))/,LessThanOrEqualTo:/(<=|lte(?!\w))/,NotEqualTo:/(!=|neq(?!\w))/,Or:/(\|\||or(?!\w))/,And:/(&&|and(?!\w))/,Xor:/(\^|xor(?!\w))/,Not:/(!|not(?!\w))/,EqualToOrAssign:/(=|to(?!\w))/,Add:/\+/,Minus:/-/,Multiply:/\*/,Divide:/\//,AddAssign:/\+=/,MinusAssign:/-=/,MultiplyAssign:/\*=/,DivideAssign:/\/=/,Comment:"//",Identifier:/[a-zA-Z0-9_:.]+/,CommandCall:/([^>]|(?!>)[^>]+>)+(?=>>)/,Text:/.*/};e.exports=n},function(e,t){"use strict";function n(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function r(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=function(){function e(e,t){for(var n=0;n=this.options.length)throw new Error("Cannot select option #"+e+", there are only "+this.options.length+" options");this.selected=e}}]),t}(s);e.exports={Result:s,TextResult:a,CommandResult:c,OptionsResult:u}},function(e,t){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var r=function(){function e(e,t){for(var n=0;n story.next()); + return 'async'; + } + return false; + }; + const extendWithCtFunctions = function(bondage) { + const fs = bondage.functions; + fs.sound = playSound; + fs.room = switchRoom; + }; + class YarnStory extends PIXI.utils.EventEmitter { + /** + * Creates a new YarnStory + * @param {Object} data The exported, inlined Yarn's .json file + * @param {String} [first] The starting node's name from which to run the story. Defaults to "Start" + * @returns {YarnStory} self + */ + constructor(data, first) { + super(); + this.bondage = new bondage.Runner(); + extendWithCtFunctions(this.bondage); + this.bondage.load(data); + + this.nodes = this.bondage.yarnNodes; + this.startingNode = first? this.nodes[first] : this.nodes.Start; + } + + /** + * Starts the story, essentially jumping to a starting node + * @returns {void} + */ + start() { + this.jump(this.startingNode.title); + this.emit('start', this.scene); + } + /** + * "Says" the given option, advancing the story further on a taken branch, if this dialogue option exists. + * @param {String} line The line to say + * @returns {void} + */ + say(line) { + const ind = this.options.indexOf(line); + if (ind === -1) { + throw new Error(`There is no line "${line}". Is it a typo?`); + } + this.currentStep.select(ind); + this.next(); + } + /** + * Manually moves the story to a node with a given title + * + * @param {String} title The title of the needed node + * @returns {void} + */ + jump(title) { + if (!(title in this.nodes)) { + throw new Error(`Could not find a node called "${title}".`); + } + this.position = 0; + this.scene = this.bondage.run(title); + this.next(); + } + /** + * Moves back to the previous node, but just once + * + * @returns {void} + */ + back() { + this.jump(this.previousNode.title); + } + /** + * Naturally advances in the story, if no options are available + * @returns {void} + */ + next() { + this.currentStep = this.scene.next().value; + if (this.currentStep instanceof bondage.TextResult || + this.currentStep instanceof bondage.CommandResult) { + if (this.raw !== this.currentStep.data) { + this.previousNode = this.raw; + this.raw = this.currentStep.data; + this.emit('newnode', this.currentStep); + } + } + if (this.currentStep) { + if (this.currentStep instanceof bondage.TextResult) { + // Optionally, skip empty lines + if ([/*%skipEmpty%*/][0] && !this.text.trim()) { + this.next(); + return; + } + this.emit('text', this.text); + } else if (this.currentStep instanceof bondage.CommandResult) { + if ([/*%magic%*/][0]) { + const commandStatus = ctCommandParser(this.command.trim(), this); + if (commandStatus && commandStatus !== 'async') { + this.next(); // Automatically advance the story after magic commands + // Async commands should call `this.next()` by themselves + return; + } else if (commandStatus === 'async') { + return; + } + } + this.emit('command', this.command.trim()); + } else if (this.currentStep instanceof bondage.OptionsResult) { + this.emit('options', this.options); + } + this.emit('next', this.currentStep); + } else { + this.emit('drained', this.currentStep); + } + } + + /** + * Returns the current text line, including the character's name + * + * @returns {String|Boolean} Returns `false` if the current position is not a speech line, + * otherwise returns the current line. + */ + get text() { + if (this.currentStep instanceof bondage.TextResult) { + return this.currentStep.text; + } + return false; + } + /** + * Returns the character's name that says the current text line. + * It is expected that your character's names will be in one word, + * otherwise they will be detected as parts of the speech line. + * E.g. `Cat: Hello!` will return `'Cat'`, but `Kitty cat: Hello!` + * will return `undefined`. + * + * @return {Boolean|String|undefined} Returns `false` if the current position is not a speech line, + * `undefined` if the line does not have a character specified, and a string of your character + * if it was specified. + */ + get character() { + return this.text && characterLine.exec(this.text)[1]; + } + + /** + * Returns the the current text line, without a character. + * It is expected that your character's names will be in one word, + * otherwise they will be detected as parts of the speech line. + * E.g. `Cat: Hello!` will return `'Cat'`, but `Kitty cat: Hello!` + * will return `undefined`. + * + * @return {String|Boolean} The speech line or `false` if the current position + * is not a speech line. + */ + get body() { + return this.text && characterLine.exec(this.text)[2]; + } + /** + * Returns the title of the current node + * + * @returns {String} The title of the current node + */ + get title() { + return this.raw.title; + } + /** + * Returns the current command + * + * @returns {String|Boolean} The current command, or `false` if the current + * position is not a command. + */ + get command() { + if (this.currentStep instanceof bondage.CommandResult) { + return this.currentStep.text; + } + return false; + } + /** + * Returns the tags of the current node + * + * @returns {String} The tags of the current node. + */ + get tags() { + return this.raw.tags; + } + /** + * Returns currently possible dialogue options, if there are any. + * @returns {Array} An array of possible dialogue lines. + */ + get options() { + if (this.currentStep instanceof bondage.OptionsResult) { + return this.currentStep.options; + } + return false; + } + /** + * Current variables + * @type {Object} + */ + get variables() { + return this.bondage.variables; + } + /** + * Checks whether a given node was visited + * @param {String} title The node's title to check against + * @returns {Boolean} Returns `true` if the specified node was visited, `false` otherwise. + */ + visited(title) { + return (title in this.bondage.visited && this.bondage.visited[title]); + } + } + + ct.yarn = { + /** + * Opens the given JSON object and returns a YarnStory object, ready for playing. + * @param {Object} data The JSON object of a Yarn story + * @returns {YarnStory} The YarnStory object + */ + openStory(data) { + return new YarnStory(data); + }, + /** + * Opens the given JSON object and returns a promise that resolves into a YarnStory. + * @param {String} url The link to the JSON file, relative or absolute. Use `myProject.json` + * for stories stored in your `project/include` directory. + * @returns {Promise} A promise that resolves into a YarnStory object after downloading the story + */ + openFromFile(url) { + return fetch(url) + .then(data => data.json()) + .then(json => new YarnStory(json)); + } + }; +})(); + diff --git a/app/data/ct.libs/yarn/injects/htmltop.html b/app/data/ct.libs/yarn/injects/htmltop.html new file mode 100644 index 000000000..7ca4667d2 --- /dev/null +++ b/app/data/ct.libs/yarn/injects/htmltop.html @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/app/data/ct.libs/yarn/module.json b/app/data/ct.libs/yarn/module.json new file mode 100644 index 000000000..bb145affe --- /dev/null +++ b/app/data/ct.libs/yarn/module.json @@ -0,0 +1,25 @@ +{ + "main": { + "name": "ct.yarn", + "version": "0.0.0", + "authors": [{ + "name": "Cosmo Myzrail Gorynych", + "mail": "admin@nersta.ru" + }] + }, + "fields": [{ + "name": "Skip empty lines", + "help": "Allows you to write empty lines in YarnEditor for better readability.", + "key": "skipEmpty", + "id": "skipEmpty", + "default": true, + "type": "checkbox" + }, { + "name": "Use magic commands", + "help": "Automatically execute commands `<>`, `<>` and `<>` and call `next()` after them.", + "key": "magic", + "id": "magic", + "default": true, + "type": "checkbox" + }] +} \ No newline at end of file diff --git a/app/data/ct.release/main.js b/app/data/ct.release/main.js index 175daf947..387c6ad3c 100644 --- a/app/data/ct.release/main.js +++ b/app/data/ct.release/main.js @@ -1,5 +1,6 @@ /* Made with ct.js http://ctjs.rocks/ */ -var deadPool = []; // a pool of `kill`-ed copies for delaying frequent garbage collection +const deadPool = []; // a pool of `kill`-ed copies for delaying frequent garbage collection +const copyTypeSymbol = Symbol('I am a ct.js copy'); setInterval(function () { deadPool.length = 0; }, 1000 * 60); @@ -93,9 +94,11 @@ ct.u = { return ct.u.rotateRad(x, y, ct.u.degToRad(deg)); }, rotateRad(x, y, rad) { + const sin = Math.sin(rad), + cos = Math.cos(rad); return [ - Math.cos(rad) * x - Math.sin(rad) * y, - Math.sin(rad) * x - Math.cos(rad) * y + cos * x - sin * y, + cos * y + sin * x ]; }, deltaDir(dir1, dir2) { @@ -179,7 +182,7 @@ ct.u = { }, time)); } }; -ct.u.ext(ct.u, { // make aliases +ct.u.ext(ct.u, {// make aliases lengthDirX: ct.u.ldx, lengthDirY: ct.u.ldy, pointDirection: ct.u.pdn, @@ -188,6 +191,28 @@ ct.u.ext(ct.u, { // make aliases pointCircle: ct.u.pcircle, extend: ct.u.ext }); + +const removeKilledCopies = (array) => { + let j = 0; + for (let i = 0; i < array.length; i++) { + if (!array[i].kill) { + array[j++] = array[i]; + } + } + + array.length = j; + return array; +}; +const killRecursive = copy => { + copy.kill = true; + ct.types.onDestroy.apply(copy); + copy.onDestroy.apply(copy); + for (const child of copy.children) { + if (child[copyTypeSymbol]) { + killRecursive(child); + } + } +}; ct.loop = function(delta) { ct.delta = delta; ct.inputs.updateActions(); @@ -201,28 +226,24 @@ ct.loop = function(delta) { ct.room.onStep.apply(ct.room); ct.rooms.afterStep.apply(ct.room); // copies - for (let i = 0, li = ct.stack.length; i < li;) { - if (ct.stack[i].kill) { - ct.types.onDestroy.apply(ct.stack[i]); - ct.stack[i].onDestroy.apply(ct.stack[i]); - ct.stack[i].destroy({ - children: true - }); - deadPool.push(ct.stack.splice(i, 1)); - li--; - } else { - i++; + for (let i = 0; i < ct.stack.length; i++) { + // eslint-disable-next-line no-underscore-dangle + if (ct.stack[i].kill && !ct.stack[i]._destroyed) { + killRecursive(ct.stack[i]); // This will also allow a parent to eject children to a new container before they are destroyed as well + ct.stack[i].destroy({children: true}); + } + } + for (const copy of ct.stack) { + // eslint-disable-next-line no-underscore-dangle + if (copy._destroyed) { + deadPool.push(copy); } } + removeKilledCopies(ct.stack); // ct.types.list[type: String] for (const i in ct.types.list) { - for (let k = 0, lk = ct.types.list[i].length; k < lk; k++) { - if (ct.types.list[i][k].kill) { - ct.types.list[i].splice(k, 1); - k--; lk--; - } - } + removeKilledCopies(ct.types.list[i]); } for (const cont of ct.stage.children) { @@ -266,7 +287,9 @@ ct.loop = function(delta) { r.x = Math.round(r.x); r.y = Math.round(r.y); + // console.log("loop") for (let i = 0, li = ct.stack.length; i < li; i++) { + // console.log(ct.stack[i].type); ct.types.beforeDraw.apply(ct.stack[i]); ct.stack[i].onDraw.apply(ct.stack[i]); ct.types.afterDraw.apply(ct.stack[i]); diff --git a/app/data/ct.release/res.js b/app/data/ct.release/res.js index e39f806ad..949cf5e76 100644 --- a/app/data/ct.release/res.js +++ b/app/data/ct.release/res.js @@ -10,6 +10,7 @@ soundsError: 0, sounds: {}, registry: [/*@textureregistry@*/][0], + atlases: [/*@textureatlases@*/][0], skelRegistry: [/*@skeletonregistry@*/][0], fetchImage(url, callback) { loader.add(url, url); @@ -66,12 +67,17 @@ reg.textures = []; if (reg.frames) { for (let i = 0; i < reg.frames; i++) { - const tex = PIXI.Loader.shared.resources[reg.atlas].textures[`${texture}_frame${i}`]; + const frame = `${texture}@frame${i}`; + const atlas = PIXI.Loader.shared.resources[ct.res.atlases.find(atlas => + frame in PIXI.Loader.shared.resources[atlas].textures + )]; + const tex = atlas.textures[frame]; tex.defaultAnchor = new PIXI.Point(reg.anchor.x, reg.anchor.y); reg.textures.push(tex); } } else { const texture = PIXI.Loader.shared.resources[reg.atlas].texture; + texture.defaultAnchor = new PIXI.Point(reg.anchor.x, reg.anchor.y); reg.textures.push(texture); } } diff --git a/app/data/ct.release/types.js b/app/data/ct.release/types.js index ebbff03fd..b99b21746 100644 --- a/app/data/ct.release/types.js +++ b/app/data/ct.release/types.js @@ -27,6 +27,9 @@ } else { super([PIXI.Texture.EMPTY]); } + // it is defined in main.js + // eslint-disable-next-line no-undef + this[copyTypeSymbol] = true; if (exts) { ct.u.ext(this, exts); if (exts.tx) { @@ -158,6 +161,7 @@ } super(ct.res.getTexture(bgName, frame || 0), width, height); ct.types.list.BACKGROUND.push(this); + this.anchor.x = this.anchor.y = 0; this.depth = depth; this.shiftX = this.shiftY = this.movementX = this.movementY = 0; this.parallaxX = this.parallaxY = 1; @@ -205,6 +209,7 @@ for (let i = 0, l = data.tiles.length; i < l; i++) { const textures = ct.res.getTexture(data.tiles[i].texture); const sprite = new PIXI.Sprite(textures[data.tiles[i].frame]); + sprite.anchor.x = sprite.anchor.y = 0; this.addChild(sprite); sprite.x = data.tiles[i].x; sprite.y = data.tiles[i].y; diff --git a/app/data/fonts/iosevka-bold.woff2 b/app/data/fonts/iosevka-bold.woff2 new file mode 100644 index 000000000..6cd46da09 Binary files /dev/null and b/app/data/fonts/iosevka-bold.woff2 differ diff --git a/app/data/fonts/iosevka-bolditalic.woff2 b/app/data/fonts/iosevka-bolditalic.woff2 new file mode 100644 index 000000000..bd326d272 Binary files /dev/null and b/app/data/fonts/iosevka-bolditalic.woff2 differ diff --git a/app/data/fonts/iosevka-light.woff2 b/app/data/fonts/iosevka-light.woff2 new file mode 100644 index 000000000..1bbd7385d Binary files /dev/null and b/app/data/fonts/iosevka-light.woff2 differ diff --git a/app/data/fonts/iosevka-lightitalic.woff2 b/app/data/fonts/iosevka-lightitalic.woff2 new file mode 100644 index 000000000..786e8898d Binary files /dev/null and b/app/data/fonts/iosevka-lightitalic.woff2 differ diff --git a/app/data/i18n/Brazilian Portuguese.json b/app/data/i18n/Brazilian Portuguese.json new file mode 100644 index 000000000..f8a17d5f6 --- /dev/null +++ b/app/data/i18n/Brazilian Portuguese.json @@ -0,0 +1,364 @@ +{ + "me": { + "id": "Pt-Br", + "native": "Portugais Brésilien", + "eng": "Brazilian Portuguese" + }, + "colorPicker": { + "current": "Novo", + "globalPalette": "Paleta Global", + "old": "Antigo", + "projectPalette": "Paleta do Projeto" + }, + "common": { + "add": "Adicionar", + "addtonotes": "Adicionar às notas", + "apply": "Aplicar", + "cancel": "Cancelar", + "confirmDelete": "Você tem certeza que deseja remover {0}? Não poderá ser desfeita.", + "copy": "Copiar", + "copyName": "Copiar o nome", + "ctsite": "Página inicial do ct.js", + "cut": "Recortar", + "delete": "Apagar", + "donate": "Doar ❤️", + "done": "Feito!", + "duplicate": "Duplicar", + "exit": "Sair", + "exitconfirm": "Você tem certeza que deseja sair?
Todas as alterações que não foram salvas serão perdidas!", + "fastimport": "Importação Rápida", + "language": "Língua", + "name": "Nome:", + "nametaken": "Este nome já está em uso", + "newname": "Novo nome:", + "no": "Não", + "none": "Nenhum", + "norooms": "Você precisa de pelo menos um room para compilar seu app", + "notfoundorunknown": "Arquivo desconhecido. Tenha certeza de que o arquivo realmente exista", + "ok": "Ok", + "open": "Abrir", + "openproject": "Abrir projeto...", + "paste": "Colar", + "reallyexit": "Você tem certeza que deseja sair? Todas as alterações que não foram salvas serão perdidas!", + "rename": "Renomear", + "save": "Salvar", + "savedcomm": "Seu projeto foi salvo", + "saveproject": "Salvar projeto", + "sort": "Ordenar:", + "tilelayer": "Camada de tile", + "wrongFormat": "Formato de arquivo incorreto", + "yes": "Sim", + "cannotBeEmpty": "", + "contribute": "", + "translateToYourLanguage": "" + }, + "exportPanel": { + "hide": "Ocultar", + "working": "Em progresso...", + "debug": "Versão do debug", + "export": "Exportar", + "exportPanel": "Exportar o Projeto", + "firstrunnotice": "A primeira execução para cada plataforma será lenta, já que o ct.js fará o download e salvará bibliotecas adicionais necessárias para o empacotamento. Levará algum tempo, mas as próximas vezes serão quase instantâneas.", + "log": "Log de Mensagens" + }, + "intro": { + "loading": "Por favor, aguarde: gatinhos estão adquirindo a velocidade da luz!", + "newProject": { + "button": "Criar", + "input": "Nome do projeto (letras e dígitos)", + "text": "Criar novo", + "nameerr": "Nome errado do projeto." + }, + "recovery": { + "message": "

Recuperação

ct.js encontrou um arquivo de recuperação. Possivelmente seu projeto não foi salvo corretamente ou o ct.js foi fechado por conta de alguma emergência. Aqui está a última vez em que estes arquivos foram modificados:

Seu arquivo escolhido: {0} {1}
Recuperar arquivo: {2} {3}

Qual arquivo o ct.js deveria abrir?

", + "loadTarget": "Arquivo de Destino", + "loadRecovery": "Recuperar", + "newer": "(mais novo)", + "older": "(mais antigo)" + }, + "homepage": "Página inicial", + "latestVersion": "Versão $1 está disponível", + "forgetProject": "Esquecer este projeto", + "browse": "Procurar", + "latest": "Projetos mais recentes", + "twitter": "Canal no Twitter", + "discord": "Comunidade no Discord", + "loadingProject": "", + "loadingProjectError": "", + "unableToWriteToFolders": "" + }, + "licensepanel": { + "ctjslicense": "" + }, + "menu": { + "ctIDE": "ct.IDE", + "exportDesktop": "Exportar para a área de trabalho", + "texture": "Gráficos", + "launch": "Compilar", + "license": "Licença", + "min": "Modo janela", + "modules": "Catmods", + "recentProjects": "Projetos recentes", + "rooms": "Salas", + "save": "Salvar projeto", + "startScreen": "Retornar à tela inicial", + "settings": "Configurações", + "sounds": "Sons", + "ui": "UI", + "theme": "Tema", + "themeDay": "Claro", + "themeNight": "Escuro", + "types": "Tipos", + "zipExport": "Exportar para .zip", + "zipProject": "Empacotar projeto para .zip", + "successZipExport": "", + "successZipProject": "", + "codeFontDefault": "", + "codeFontOldSchool": "", + "codeFontSystem": "", + "codeFontCustom": "", + "newFont": "", + "codeFont": "", + "codeLigatures": "", + "codeDense": "" + }, + "settings": { + "author": "Nome do autor:", + "authoring": "Autoria", + "cover": "Capa", + "exportparams": "Exportar parâmetros", + "framerate": "Taxa de quadros", + "getfile": "Escolher", + "minifyhtmlcss": "Compactar HTML e CSS", + "minifyjs": "Compactar Javascript e converter para ES5 (lento; usar para releases)", + "pixelatedrender": "Desabilitar suavização de imagem aqui e no projeto exportado (preserva pixels nítidos)", + "renderoptions": "Opções de Renderização", + "settings": "Configurações do Projeto", + "site": "Página inicial", + "title": "Nome:", + "version": "Versão:", + "versionpostfix": "Postfix:", + "scripts": { + "addNew": "Adicionar um Novo Script", + "deleteScript": "Apagar o script", + "header": "Scripts", + "newScriptComment": "Usar scripts para definir funções frequentes e importar pequenas bibliotecas" + }, + "actions": "", + "editActions": "", + "highDensity": "", + "maxFPS": "" + }, + "modules": { + "author": "Autor deste catmod", + "hasfields": "Configurável", + "hasinjects": "Tem injeções", + "help": "Referência", + "info": "Info", + "license": "Licença", + "logs": "Logs", + "methods": "Métodos", + "parameters": "Parâmetros", + "logs2": "Logs", + "settings": "Configurações ", + "hasinputmethods": "" + }, + "texture": { + "create": "Criar", + "import": "Importar", + "skeletons": "Animação Esquelética" + }, + "textureview": { + "bgcolor": "Mudar cor de fundo", + "center": "Eixo:", + "cols": "Colunas:", + "done": "Aplicar", + "fill": "Preencher", + "form": "Forma de colisão:", + "frames": "Contagem de quadros:", + "isometrify": "Isometrificar: Mover o eixo para o ponto inferior central, preencher o sprite inteiro com a máscara de colisão", + "name": "Nome:", + "radius": "Raio:", + "rectangle": "Retângulo", + "reimport": "Reimportar", + "round": "Círculo", + "rows": "Linhas:", + "setcenter": "Centro da imagem", + "speed": "Taxa de quadros:", + "tiled": "Esta textura repete nas duas direções?", + "replacetexture": "Substituir...", + "corrupted": "Arquivo está corrompido ou não existe! Fechando agora.", + "showmask": "Mostrar máscara", + "width": "Largura:", + "height": "Altura:", + "marginx": "Margem X:", + "marginy": "Margem Y:", + "offx": "Offset X:", + "offy": "Offset Y:", + "strip": "Polígono", + "removePoint": "Remover o ponto", + "closeShape": "Fechar a forma", + "addPoint": "Adicionar um ponto", + "moveCenter": "Mover o eixo", + "movePoint": "Mover este ponto", + "symmetryTool": "" + }, + "sounds": { + "create": "Criar" + }, + "soundview": { + "import": "Importar", + "name": "Nome:", + "save": "Salvar", + "isMusicFile": "Esta é uma faixa musical", + "poolSize": "Tamanho da coleção:" + }, + "styles": { + "create": "Criar", + "styles": "Estilos de Texto" + }, + "styleview": { + "active": "Ativo", + "alignment": "Alinhamento:", + "apply": "Aplicar", + "fill": "Preencher", + "fillcolor": "Cor:", + "fillcolor1": "Cor 1:", + "fillcolor2": "Cor 2:", + "fillgrad": "Gradiente", + "fillgradtype": "Tipo de gradiente:", + "fillhorisontal": "Horizontal", + "fillsolid": "Diffuse", + "filltype": "Tipo de preenchimento:", + "fillvertical": "Vertical", + "font": "Fonte", + "fontweight": "Densidade:", + "fontsize": "Tamanho da fonte:", + "fontfamily": "Font family:", + "italic": "Itálico", + "lineHeight": "Altura da linha:", + "shadow": "Sombreamento", + "shadowblur": "Blur:", + "shadowcolor": "Cor do sombreamento:", + "shadowshift": "Trocar:", + "stroke": "Traço:", + "strokecolor": "Cor do traço:", + "strokeweight": "Espessura da linha:", + "testtext": "Teste texto 0123 +", + "textWrap": "Quebra de linha", + "textWrapWidth": "Largura máxima:" + }, + "fonts": { + "fonts": "Fontes", + "import": "Importar TTF", + "italic": "Itálico" + }, + "fontview": { + "typefacename": "Nome do typeface:", + "fontweight": "Espessura da fonte:", + "italic": "É itálico?", + "reimport": "Reimportar" + }, + "types": { + "create": "Criar" + }, + "typeview": { + "change": "Alterar sprite", + "create": "Ao Criar", + "depth": "Profundidade:", + "destroy": "Ao Destruir", + "done": "Feito", + "draw": "Desenhar", + "name": "Nome:", + "step": "Passo", + "learnAboutTypes": "" + }, + "rooms": { + "create": "Adicionar novo", + "makestarting": "Definir como sala inicial" + }, + "roombackgrounds": { + "add": "Adicionar um plano de fundo", + "depth": "Profundidade:", + "movement": "Velocidade de movimento (X, Y):", + "parallax": "Parallax (X, Y):", + "repeat": "Repetir:", + "scale": "Escala (X, Y):", + "shift": "Trocar (X, Y):" + }, + "roomtiles": { + "moveTileLayer": "Mover para uma nova profundidade:", + "show": "Mostrar a camada", + "hide": "Ocultar a camada", + "findTileset": "Encontrar um conjunto de tiles" + }, + "roomview": { + "name": "Nome:", + "width": "Largura da view:", + "height": "Altura da view:", + "events": "Eventos da sala", + "copies": "Cópias", + "backgrounds": "Planos de fundo", + "tiles": "Tiles", + "add": "Adicionar", + "none": "Nada", + "done": "Feito", + "zoom": "Zoom:", + "grid": "Definir grade", + "gridoff": "Desabilitar grade", + "gridsize": "Tamanho da grade:", + "hotkeysNotice": "Ctrl = Apagar, Alt = Sem grade, Shift = Múltiplo", + "hotkeysNoticeMovement": "Ctrl = Apagar, Shift = Selecionar", + "tocenter": "Centralizar", + "selectbg": "Selecionar um conjunto de tiles", + "shift": "Trocar a view", + "shifttext": "Trocar por:", + "step": "Passo", + "create": "Ao Criar", + "leave": "Ao Sair", + "draw": "Desenhar", + "newdepth": "Nova profundidade:", + "deletecopy": "Remover cópia {0}", + "deleteCopies": "Remover cópias", + "shiftCopies": "Trocar cópias", + "selectAndMove": "Selecionar e Mover", + "changecopyscale": "Trocar escala", + "shiftcopy": "Definir coordenadas", + "deletetile": "Remover um tile", + "deletetiles": "Remover tiles", + "movetilestolayer": "Mover para camada", + "shifttiles": "Trocar tiles", + "findTileset": "" + }, + "notepad": { + "local": "Bloco de notas do projeto", + "global": "Bloco de notas global", + "helppages": "Ajuda", + "backToHome": "Voltar para a página inicial da documentação" + }, + "preview": { + "reload": "Recarregar", + "roomRestart": "Reiniciar a sala", + "openExternal": "Abrir no navegador", + "getQR": "QR codes e URL de servidor local" + }, + "actionsEditor": { + "actions": "", + "actionsEditor": "", + "addAction": "", + "addMethod": "", + "deleteAction": "", + "deleteMethod": "", + "inputActionNamePlaceholder": "", + "methodModuleMissing": "", + "methods": "", + "multiplier": "", + "noActionsYet": "" + }, + "docsShortcut": { + "openDocs": "" + }, + "inputMethodSelector": { + "select": "" + } +} \ No newline at end of file diff --git a/app/data/i18n/Comments.json b/app/data/i18n/Comments.json new file mode 100644 index 000000000..b233a8cdd --- /dev/null +++ b/app/data/i18n/Comments.json @@ -0,0 +1,364 @@ +{ + "me": { + "id": "This is a language ID. It should be different for each file", + "native": "The name of a language, in this particular language.", + "eng": "The name of a language, in English" + }, + "common": { + "add": "", + "addtonotes": "", + "apply": "Usually in modal dialogues, in the meaning \"to apply a change\", \"apply settings\"", + "cancel": "", + "cannotBeEmpty": "", + "confirmDelete": "", + "contribute": "", + "copy": "A verb, \"to create a duplicate\" (not a ct.js Copy!).", + "copyName": "", + "ctsite": "", + "cut": "", + "delete": "", + "donate": "", + "done": "", + "duplicate": "A verb", + "exit": "", + "exitconfirm": "", + "fastimport": "", + "language": "", + "translateToYourLanguage": "", + "name": "", + "nametaken": "", + "newname": "", + "no": "", + "none": "", + "norooms": "", + "notfoundorunknown": "", + "ok": "", + "open": "A verb", + "openproject": "", + "paste": "", + "reallyexit": "", + "rename": "", + "save": "", + "savedcomm": "", + "saveproject": "", + "sort": "", + "tilelayer": "", + "wrongFormat": "", + "yes": "" + }, + "actionsEditor": { + "actions": "", + "actionsEditor": "", + "addAction": "", + "addMethod": "", + "deleteAction": "", + "deleteMethod": "", + "inputActionNamePlaceholder": "", + "methodModuleMissing": "", + "methods": "", + "multiplier": "", + "noActionsYet": "" + }, + "colorPicker": { + "current": "", + "globalPalette": "", + "old": "", + "projectPalette": "" + }, + "docsShortcut": { + "openDocs": "" + }, + "exportPanel": { + "hide": "", + "working": "", + "debug": "", + "export": "A verb", + "exportPanel": "", + "firstrunnotice": "", + "log": "" + }, + "inputMethodSelector": { + "select": "" + }, + "intro": { + "loading": "", + "newProject": { + "button": "", + "input": "", + "text": "", + "nameerr": "" + }, + "recovery": { + "message": "", + "loadTarget": "", + "loadRecovery": "", + "newer": "", + "older": "" + }, + "loadingProject": "", + "loadingProjectError": "", + "homepage": "", + "latestVersion": "", + "forgetProject": "", + "browse": "", + "latest": "", + "unableToWriteToFolders": "", + "twitter": "", + "discord": "" + }, + "licensepanel": { + "ctjslicense": "" + }, + "menu": { + "ctIDE": "", + "exportDesktop": "", + "texture": "", + "launch": "", + "license": "", + "min": "", + "modules": "", + "recentProjects": "", + "rooms": "", + "save": "", + "startScreen": "", + "settings": "", + "sounds": "", + "successZipExport": "", + "successZipProject": "", + "ui": "", + "theme": "", + "themeDay": "", + "themeNight": "", + "types": "", + "zipExport": "", + "zipProject": "", + "codeFontDefault": "", + "codeFontOldSchool": "", + "codeFontSystem": "", + "codeFontCustom": "", + "newFont": "", + "codeFont": "", + "codeLigatures": "", + "codeDense": "" + }, + "settings": { + "actions": "", + "author": "", + "authoring": "", + "cover": "", + "editActions": "", + "exportparams": "", + "framerate": "", + "getfile": "", + "highDensity": "", + "maxFPS": "", + "minifyhtmlcss": "", + "minifyjs": "", + "pixelatedrender": "", + "renderoptions": "", + "settings": "", + "site": "", + "title": "", + "version": "", + "versionpostfix": "", + "scripts": { + "addNew": "", + "deleteScript": "", + "header": "", + "newScriptComment": "" + } + }, + "modules": { + "author": "", + "hasfields": "", + "hasinjects": "", + "hasinputmethods": "", + "help": "", + "info": "", + "license": "", + "logs": "A title of a tab that shows a changelof of a module, when clicked. It can be shorter than modules.log2", + "methods": "", + "parameters": "", + "logs2": "A title for a changelog of a module.", + "settings": "" + }, + "texture": { + "create": "", + "import": "A verb", + "skeletons": "" + }, + "textureview": { + "bgcolor": "", + "center": "", + "cols": "", + "done": "", + "fill": "", + "form": "", + "frames": "", + "isometrify": "", + "name": "", + "radius": "", + "rectangle": "", + "reimport": "", + "round": "", + "rows": "", + "setcenter": "", + "speed": "", + "tiled": "", + "replacetexture": "", + "corrupted": "", + "showmask": "", + "width": "", + "height": "", + "marginx": "", + "marginy": "", + "offx": "", + "offy": "", + "strip": "", + "removePoint": "", + "closeShape": "", + "addPoint": "", + "moveCenter": "", + "movePoint": "", + "symmetryTool": "" + }, + "sounds": { + "create": "" + }, + "soundview": { + "import": "", + "name": "", + "save": "", + "isMusicFile": "", + "poolSize": "" + }, + "styles": { + "create": "", + "styles": "" + }, + "styleview": { + "active": "", + "alignment": "", + "apply": "", + "fill": "", + "fillcolor": "", + "fillcolor1": "", + "fillcolor2": "", + "fillgrad": "", + "fillgradtype": "", + "fillhorisontal": "", + "fillsolid": "", + "filltype": "", + "fillvertical": "", + "font": "", + "fontweight": "", + "fontsize": "", + "fontfamily": "", + "italic": "", + "lineHeight": "", + "shadow": "", + "shadowblur": "", + "shadowcolor": "", + "shadowshift": "", + "stroke": "", + "strokecolor": "", + "strokeweight": "", + "testtext": "It is recommended that you include both a string in your language and in English, as it will help with picking fonts that have multilingual support.", + "textWrap": "", + "textWrapWidth": "" + }, + "fonts": { + "fonts": "", + "import": "", + "italic": "" + }, + "fontview": { + "typefacename": "", + "fontweight": "", + "italic": "", + "reimport": "" + }, + "types": { + "create": "" + }, + "typeview": { + "change": "", + "create": "", + "depth": "", + "destroy": "", + "done": "", + "draw": "", + "learnAboutTypes": "", + "name": "", + "step": "" + }, + "rooms": { + "create": "", + "makestarting": "" + }, + "roombackgrounds": { + "add": "", + "depth": "", + "movement": "", + "parallax": "", + "repeat": "", + "scale": "", + "shift": "" + }, + "roomtiles": { + "moveTileLayer": "", + "show": "", + "hide": "", + "findTileset": "" + }, + "roomview": { + "name": "", + "width": "", + "height": "", + "events": "", + "copies": "", + "backgrounds": "", + "tiles": "", + "add": "", + "none": "", + "done": "", + "zoom": "", + "grid": "", + "gridoff": "", + "gridsize": "", + "hotkeysNotice": "", + "hotkeysNoticeMovement": "", + "tocenter": "", + "selectbg": "", + "shift": "", + "shifttext": "", + "step": "", + "create": "", + "leave": "", + "draw": "", + "newdepth": "", + "deletecopy": "", + "deleteCopies": "", + "shiftCopies": "", + "selectAndMove": "", + "changecopyscale": "", + "shiftcopy": "", + "deletetile": "", + "deletetiles": "", + "movetilestolayer": "", + "shifttiles": "", + "findTileset": "" + }, + "notepad": { + "local": "", + "global": "", + "helppages": "", + "backToHome": "" + }, + "preview": { + "reload": "", + "roomRestart": "", + "openExternal": "", + "getQR": "" + } +} \ No newline at end of file diff --git a/app/data/i18n/Debug.json b/app/data/i18n/Debug.json new file mode 100644 index 000000000..bc190bd8a --- /dev/null +++ b/app/data/i18n/Debug.json @@ -0,0 +1,364 @@ +{ + "me": { + "id": "me.id", + "native": "me.native", + "eng": "me.eng" + }, + "common": { + "add": "common.add", + "addtonotes": "common.addtonotes", + "apply": "common.apply", + "cancel": "common.cancel", + "cannotBeEmpty": "common.cannotBeEmpty", + "confirmDelete": "common.confirmDelete", + "contribute": "common.contribute", + "copy": "common.copy", + "copyName": "common.copyName", + "ctsite": "common.ctsite", + "cut": "common.cut", + "delete": "common.delete", + "donate": "common.donate", + "done": "common.done", + "duplicate": "common.duplicate", + "exit": "common.exit", + "exitconfirm": "common.exitconfirm", + "fastimport": "common.fastimport", + "language": "common.language", + "translateToYourLanguage": "common.translateToYourLanguage", + "name": "common.name", + "nametaken": "common.nametaken", + "newname": "common.newname", + "no": "common.no", + "none": "common.none", + "norooms": "common.norooms", + "notfoundorunknown": "common.notfoundorunknown", + "ok": "common.ok", + "open": "common.open", + "openproject": "common.openproject", + "paste": "common.paste", + "reallyexit": "common.reallyexit", + "rename": "common.rename", + "save": "common.save", + "savedcomm": "common.savedcomm", + "saveproject": "common.saveproject", + "sort": "common.sort", + "tilelayer": "common.tilelayer", + "wrongFormat": "common.wrongFormat", + "yes": "common.yes" + }, + "actionsEditor": { + "actions": "actionsEditor.actions", + "actionsEditor": "actionsEditor.actionsEditor", + "addAction": "actionsEditor.addAction", + "addMethod": "actionsEditor.addMethod", + "deleteAction": "actionsEditor.deleteAction", + "deleteMethod": "actionsEditor.deleteMethod", + "inputActionNamePlaceholder": "actionsEditor.inputActionNamePlaceholder", + "methodModuleMissing": "actionsEditor.methodModuleMissing", + "methods": "actionsEditor.methods", + "multiplier": "actionsEditor.multiplier", + "noActionsYet": "actionsEditor.noActionsYet" + }, + "colorPicker": { + "current": "colorPicker.current", + "globalPalette": "colorPicker.globalPalette", + "old": "colorPicker.old", + "projectPalette": "colorPicker.projectPalette" + }, + "docsShortcut": { + "openDocs": "docsShortcut.openDocs" + }, + "exportPanel": { + "hide": "exportPanel.hide", + "working": "exportPanel.working", + "debug": "exportPanel.debug", + "export": "exportPanel.export", + "exportPanel": "exportPanel.exportPanel", + "firstrunnotice": "exportPanel.firstrunnotice", + "log": "exportPanel.log" + }, + "inputMethodSelector": { + "select": "inputMethodSelector.select" + }, + "intro": { + "loading": "intro.loading", + "newProject": { + "button": "intro.newProject.button", + "input": "intro.newProject.input", + "text": "intro.newProject.text", + "nameerr": "intro.newProject.nameerr" + }, + "recovery": { + "message": "intro.recovery.message", + "loadTarget": "intro.recovery.loadTarget", + "loadRecovery": "intro.recovery.loadRecovery", + "newer": "intro.recovery.newer", + "older": "intro.recovery.older" + }, + "loadingProject": "intro.loadingProject", + "loadingProjectError": "intro.loadingProjectError", + "homepage": "intro.homepage", + "latestVersion": "intro.latestVersion", + "forgetProject": "intro.forgetProject", + "browse": "intro.browse", + "latest": "intro.latest", + "unableToWriteToFolders": "intro.unableToWriteToFolders", + "twitter": "intro.twitter", + "discord": "intro.discord" + }, + "licensepanel": { + "ctjslicense": "licensepanel.ctjslicense" + }, + "menu": { + "ctIDE": "menu.ctIDE", + "exportDesktop": "menu.exportDesktop", + "texture": "menu.texture", + "launch": "menu.launch", + "license": "menu.license", + "min": "menu.min", + "modules": "menu.modules", + "recentProjects": "menu.recentProjects", + "rooms": "menu.rooms", + "save": "menu.save", + "startScreen": "menu.startScreen", + "settings": "menu.settings", + "sounds": "menu.sounds", + "successZipExport": "menu.successZipExport", + "successZipProject": "menu.successZipProject", + "ui": "menu.ui", + "theme": "menu.theme", + "themeDay": "menu.themeDay", + "themeNight": "menu.themeNight", + "types": "menu.types", + "zipExport": "menu.zipExport", + "zipProject": "menu.zipProject", + "codeFontDefault": "menu.codeFontDefault", + "codeFontOldSchool": "menu.codeFontOldSchool", + "codeFontSystem": "menu.codeFontSystem", + "codeFontCustom": "menu.codeFontCustom", + "newFont": "menu.newFont", + "codeFont": "menu.codeFont", + "codeLigatures": "menu.codeLigatures", + "codeDense": "menu.codeDense" + }, + "settings": { + "actions": "settings.actions", + "author": "settings.author", + "authoring": "settings.authoring", + "cover": "settings.cover", + "editActions": "settings.editActions", + "exportparams": "settings.exportparams", + "framerate": "settings.framerate", + "getfile": "settings.getfile", + "highDensity": "settings.highDensity", + "maxFPS": "settings.maxFPS", + "minifyhtmlcss": "settings.minifyhtmlcss", + "minifyjs": "settings.minifyjs", + "pixelatedrender": "settings.pixelatedrender", + "renderoptions": "settings.renderoptions", + "settings": "settings.settings", + "site": "settings.site", + "title": "settings.title", + "version": "settings.version", + "versionpostfix": "settings.versionpostfix", + "scripts": { + "addNew": "settings.scripts.addNew", + "deleteScript": "settings.scripts.deleteScript", + "header": "settings.scripts.header", + "newScriptComment": "settings.scripts.newScriptComment" + } + }, + "modules": { + "author": "modules.author", + "hasfields": "modules.hasfields", + "hasinjects": "modules.hasinjects", + "hasinputmethods": "modules.hasinputmethods", + "help": "modules.help", + "info": "modules.info", + "license": "modules.license", + "logs": "modules.logs", + "methods": "modules.methods", + "parameters": "modules.parameters", + "logs2": "modules.logs2", + "settings": "modules.settings" + }, + "texture": { + "create": "texture.create", + "import": "texture.import", + "skeletons": "texture.skeletons" + }, + "textureview": { + "bgcolor": "textureview.bgcolor", + "center": "textureview.center", + "cols": "textureview.cols", + "done": "textureview.done", + "fill": "textureview.fill", + "form": "textureview.form", + "frames": "textureview.frames", + "isometrify": "textureview.isometrify", + "name": "textureview.name", + "radius": "textureview.radius", + "rectangle": "textureview.rectangle", + "reimport": "textureview.reimport", + "round": "textureview.round", + "rows": "textureview.rows", + "setcenter": "textureview.setcenter", + "speed": "textureview.speed", + "tiled": "textureview.tiled", + "replacetexture": "textureview.replacetexture", + "corrupted": "textureview.corrupted", + "showmask": "textureview.showmask", + "width": "textureview.width", + "height": "textureview.height", + "marginx": "textureview.marginx", + "marginy": "textureview.marginy", + "offx": "textureview.offx", + "offy": "textureview.offy", + "strip": "textureview.strip", + "removePoint": "textureview.removePoint", + "closeShape": "textureview.closeShape", + "addPoint": "textureview.addPoint", + "moveCenter": "textureview.moveCenter", + "movePoint": "textureview.movePoint", + "symmetryTool": "textureview.symmetryTool" + }, + "sounds": { + "create": "sounds.create" + }, + "soundview": { + "import": "soundview.import", + "name": "soundview.name", + "save": "soundview.save", + "isMusicFile": "soundview.isMusicFile", + "poolSize": "soundview.poolSize" + }, + "styles": { + "create": "styles.create", + "styles": "styles.styles" + }, + "styleview": { + "active": "styleview.active", + "alignment": "styleview.alignment", + "apply": "styleview.apply", + "fill": "styleview.fill", + "fillcolor": "styleview.fillcolor", + "fillcolor1": "styleview.fillcolor1", + "fillcolor2": "styleview.fillcolor2", + "fillgrad": "styleview.fillgrad", + "fillgradtype": "styleview.fillgradtype", + "fillhorisontal": "styleview.fillhorisontal", + "fillsolid": "styleview.fillsolid", + "filltype": "styleview.filltype", + "fillvertical": "styleview.fillvertical", + "font": "styleview.font", + "fontweight": "styleview.fontweight", + "fontsize": "styleview.fontsize", + "fontfamily": "styleview.fontfamily", + "italic": "styleview.italic", + "lineHeight": "styleview.lineHeight", + "shadow": "styleview.shadow", + "shadowblur": "styleview.shadowblur", + "shadowcolor": "styleview.shadowcolor", + "shadowshift": "styleview.shadowshift", + "stroke": "styleview.stroke", + "strokecolor": "styleview.strokecolor", + "strokeweight": "styleview.strokeweight", + "testtext": "styleview.testtext", + "textWrap": "styleview.textWrap", + "textWrapWidth": "styleview.textWrapWidth" + }, + "fonts": { + "fonts": "fonts.fonts", + "import": "fonts.import", + "italic": "fonts.italic" + }, + "fontview": { + "typefacename": "fontview.typefacename", + "fontweight": "fontview.fontweight", + "italic": "fontview.italic", + "reimport": "fontview.reimport" + }, + "types": { + "create": "types.create" + }, + "typeview": { + "change": "typeview.change", + "create": "typeview.create", + "depth": "typeview.depth", + "destroy": "typeview.destroy", + "done": "typeview.done", + "draw": "typeview.draw", + "learnAboutTypes": "typeview.learnAboutTypes", + "name": "typeview.name", + "step": "typeview.step" + }, + "rooms": { + "create": "rooms.create", + "makestarting": "rooms.makestarting" + }, + "roombackgrounds": { + "add": "roombackgrounds.add", + "depth": "roombackgrounds.depth", + "movement": "roombackgrounds.movement", + "parallax": "roombackgrounds.parallax", + "repeat": "roombackgrounds.repeat", + "scale": "roombackgrounds.scale", + "shift": "roombackgrounds.shift" + }, + "roomtiles": { + "moveTileLayer": "roomtiles.moveTileLayer", + "show": "roomtiles.show", + "hide": "roomtiles.hide", + "findTileset": "roomtiles.findTileset" + }, + "roomview": { + "name": "roomview.name", + "width": "roomview.width", + "height": "roomview.height", + "events": "roomview.events", + "copies": "roomview.copies", + "backgrounds": "roomview.backgrounds", + "tiles": "roomview.tiles", + "add": "roomview.add", + "none": "roomview.none", + "done": "roomview.done", + "zoom": "roomview.zoom", + "grid": "roomview.grid", + "gridoff": "roomview.gridoff", + "gridsize": "roomview.gridsize", + "hotkeysNotice": "roomview.hotkeysNotice", + "hotkeysNoticeMovement": "roomview.hotkeysNoticeMovement", + "tocenter": "roomview.tocenter", + "selectbg": "roomview.selectbg", + "shift": "roomview.shift", + "shifttext": "roomview.shifttext", + "step": "roomview.step", + "create": "roomview.create", + "leave": "roomview.leave", + "draw": "roomview.draw", + "newdepth": "roomview.newdepth", + "deletecopy": "roomview.deletecopy", + "deleteCopies": "roomview.deleteCopies", + "shiftCopies": "roomview.shiftCopies", + "selectAndMove": "roomview.selectAndMove", + "changecopyscale": "roomview.changecopyscale", + "shiftcopy": "roomview.shiftcopy", + "deletetile": "roomview.deletetile", + "deletetiles": "roomview.deletetiles", + "movetilestolayer": "roomview.movetilestolayer", + "shifttiles": "roomview.shifttiles", + "findTileset": "roomview.findTileset" + }, + "notepad": { + "local": "notepad.local", + "global": "notepad.global", + "helppages": "notepad.helppages", + "backToHome": "notepad.backToHome" + }, + "preview": { + "reload": "preview.reload", + "roomRestart": "preview.roomRestart", + "openExternal": "preview.openExternal", + "getQR": "preview.getQR" + } +} \ No newline at end of file diff --git a/app/data/i18n/English.json b/app/data/i18n/English.json index 3db2f1870..08dc80392 100644 --- a/app/data/i18n/English.json +++ b/app/data/i18n/English.json @@ -1,365 +1,365 @@ -{ - "me": { - "id": "Eng", - "native": "English", - "eng": "English" - }, - - "common": { - "add": "Add", - "addtonotes": "Add to notes", - "apply": "Apply", - "cancel": "Cancel", - "cannotBeEmpty": "This cannot be empty", - "confirmDelete": "Are you sure you want to delete {0}? It cannot be undone.", - "contribute": "Contribute 💻", - "copy": "Copy", - "copyName": "Copy the name", - "ctsite": "ct.js homepage", - "cut": "Cut", - "delete": "Delete", - "donate": "Donate ❤️", - "done": "Done!", - "duplicate": "Duplicate", - "exit": "Exit", - "exitconfirm": "Are you sure you want to exit?
All the unsaved changes will be lost!", - "fastimport": "Fast Import", - "language": "Language", - "translateToYourLanguage": "Translate ct.js to your language!", - "name": "Name:", - "nametaken": "This name is already taken", - "newname": "New name:", - "newversion": "# New version is avaliable\n", - "no": "No", - "none": "None", - "norooms": "You need at least one room to compile your app.", - "notfoundorunknown": "Unknown file. Make sure the file really exists", - "ok": "Ok", - "open": "Open", - "openproject": "Open project...", - "paste": "Paste", - "reallyexit": "Are you sure you want to exit? All unsaved changes will be lost.", - "rename": "Rename", - "save": "Save", - "savedcomm": "Your project was succesfully saved.", - "saveproject": "Save project", - "sort": "Sort:", - "tilelayer": "tile layer", - "wrongFormat": "Wrong file format", - "yes": "Yes" - }, - - "actionsEditor": { - "actions": "Actions", - "actionsEditor": "Actions editor", - "addAction": "Add an action", - "addMethod": "Add an input method", - "deleteAction": "Delete this action", - "deleteMethod": "Delete this method", - "inputActionNamePlaceholder": "Action name", - "methodModuleMissing": "The required module for this method is missing", - "methods": "Input methods", - "multiplier": "Multiplier", - "noActionsYet": "Actions allow developers to listen to numerous input methods at once and dynamically change them, all with one uniform API. Read more by clicking on the docs icon above." - }, - "colorPicker": { - "current": "New", - "globalPalette": "Global Palette", - "old": "Old", - "projectPalette": "Project's Palette" - }, - "docsShortcut": { - "openDocs": "Open the documentation" - }, - "exportPanel": { - "hide": "Hide", - "working": "Working…", - "debug": "Debug version", - "export": "Export", - "exportPanel": "Export the Project", - "firstrunnotice": "The first run for each platform will be slow as ct.js will download and save additional libraries needed for packing. It will take some time, but next times will be almost instant.", - "log": "Message Log" - }, - "inputMethodSelector": { - "select": "Select" - }, - "intro": { - "loading": "Please wait: kittens are gathering speed of light!", - "newProject": { - "button": "Create", - "input": "Project's name (letters and digits)", - "text": "Create new", - "nameerr": "Wrong project name." - }, - "recovery": { - "message": "

Recovery

ct.js has found a recovery file. Possibly, your project was not saved correctly or ct.js was shut down in case of some emergency. Here is when these files were lastly modified:

Your chosen file: {0} {1}
Recovery file: {2} {3}

What file should ct.js open?

", - "loadTarget": "Target File", - "loadRecovery": "Recovery", - "newer": "(newer)", - "older": "(older)" - }, - "loadingProject": "Loading the project…", - "loadingProjectError" : "Cannot open this project because of the following error: ", - "homepage": "Homepage", - "latestVersion": "Version $1 is available", - "forgetProject": "Forget this project", - "browse": "Browse", - "latest": "Latest projects", - "unableToWriteToFolders": "Ct.js could not find an appropriate place for projects! Make sure you store ct.js app inside a folder you have access to write to.", - "twitter": "Twitter channel", - "discord": "Discord community" - }, - "licensepanel": { - "ctjslicense": "Ct.js License (MIT)" - }, - "menu": { - "ctIDE": "ct.IDE", - "exportDesktop": "Export for desktop", - "texture": "Textures", - "launch": "Compile", - "license": "License", - "min": "Windowed", - "modules": "Catmods", - "recentProjects": "Recent projects", - "rooms": "Rooms", - "save": "Save project", - "startScreen": "Return to the starting screen", - "settings": "Settings", - "sounds": "Sounds", - "successZipExport": "Successfully exported to {0}.", - "successZipProject": "Successfully zipped the project to {0}.", - "ui": "UI", - "theme": "Theme", - "themeDay": "Light", - "themeNight": "Dark", - "types": "Types", - "zipExport": "Export to .zip", - "zipProject": "Pack project to .zip" - }, - "settings": { - "actions": "Actions and input methods", - "author": "Author name:", - "authoring": "Authoring", - "cover": "Cover:", - "editActions": "Edit actions", - "exportparams": "Export parameters", - "framerate": "Framerate:", - "getfile": "Choose", - "highDensity": "Support high pixel density (e.g. on retina screens)", - "maxFPS": "Max framerate:", - "minifyhtmlcss": "Compress HTML and CSS", - "minifyjs": "Compress JavaScript and convert it to ES5 (slow; use for releases)", - "pixelatedrender": "Disable image smoothing here and in exported project (preserve crisp pixels)", - "preloader": "Preloader", - "renderoptions": "Render Options", - "settings": "Project settings", - "site": "Homepage:", - "title": "Name:", - "version": "Version:", - "versionpostfix": "Postfix:", - "preloaders": { - "circular": "Circular", - "bar": "Progress bar", - "no": "No preloader" - }, - "scripts": { - "addNew": "Add a New Script", - "deleteScript": "Delete the script", - "header": "Scripts", - "newScriptComment": "Use scripts to define frequent functions and import small libraries" - } - }, - "modules": { - "author": "Author of this catmod", - "hasfields": "Configurable", - "hasinjects": "Has injections", - "hasinputmethods": "Provides additional input methods", - "help": "Reference", - "info": "Info", - "license": "License", - "logs": "Changelog", - "methods": "Methods", - "parameters": "Parameters", - "nomethods": "This module hasn't its own methods.", - "noparameters": "This module hasn't its own parameters.", - "logs2": "Changelog", - "settings": "Settings" - }, - "texture": { - "create": "Create", - "import": "Import", - "skeletons": "Skeletal Animation" - }, - "textureview": { - "bgcolor": "Change bg color", - "center": "Axis:", - "cols": "Columns:", - "done": "Apply", - "fill": "Fill", - "form": "Collision shape:", - "frames": "Frame count:", - "isometrify": "Isometrify: Move the axis to the middle bottom point, fill the whole sprite with a collision mask", - "name": "Name:", - "radius": "Radius:", - "rectangle": "Rectangle", - "reimport": "Reimport", - "round": "Circle", - "rows": "Rows:", - "setcenter": "Image's center", - "speed": "Framerate:", - "tiled": "Is it tiled?", - "replacetexture": "Replace…", - "corrupted": "File is corrupted or missing! Closing now.", - "showmask": "Show mask", - "width": "Width:", - "height": "Height:", - "marginx": "Margin X:", - "marginy": "Margin Y:", - "offx": "Offset X:", - "offy": "Offset Y:", - "strip": "Line Strip / Polygon", - "removePoint": "Remove the point", - "closeShape": "Close the shape", - "addPoint": "Add a point", - "moveCenter": "Move axis", - "movePoint": "Move this point" - }, - "sounds": { - "create": "Create" - }, - "soundview": { - "import": "Import", - "name": "Name:", - "save": "Save", - "isMusicFile": "This is a musical track", - "poolSize": "Pool size:" - }, - "styles": { - "create": "Create", - "styles": "Text Styles" - }, - "styleview": { - "active": "Active", - "alignment": "Alignment:", - "apply": "Apply", - "fill": "Fill", - "fillcolor": "Color:", - "fillcolor1": "Color 1:", - "fillcolor2": "Color 2:", - "fillgrad": "Gradient", - "fillgradtype": "Gradient type:", - "fillhorisontal": "Horizontal", - "fillsolid": "Diffuse", - "filltype": "Fill type:", - "fillvertical": "Vertical", - "font": "Font", - "fontweight": "Weight:", - "fontsize": "Font size:", - "fontfamily": "Font family:", - "italic": "Italic", - "lineHeight": "Line height:", - "shadow": "Shadow", - "shadowblur": "Blur:", - "shadowcolor": "Shadow color:", - "shadowshift": "Shift:", - "stroke": "Stroke", - "strokecolor": "Stroke color:", - "strokeweight": "Line weight:", - "testtext" : "Test text 0123 +", - "textWrap": "Word wrap", - "textWrapWidth": "Max width:" - }, - "fonts": { - "fonts": "Fonts", - "import": "Import TTF", - "italic": "Italic" - }, - "fontview": { - "typefacename": "Typeface name:", - "fontweight": "Font weight:", - "italic": "Is italic?", - "reimport": "Reimport" - }, - "types": { - "create": "Create" - }, - "typeview": { - "change": "Change sprite", - "create": "On Create", - "depth": "Depth:", - "destroy": "On Destroy", - "done": "Done", - "draw": "Draw", - "learnAboutTypes": "Learn about coding types", - "name": "Name:", - "step": "On Step" - }, - "rooms": { - "create": "Add new", - "makestarting": "Set as the starting room" - }, - "roombackgrounds": { - "add": "Add a Background", - "depth": "Depth:", - "movement": "Movement speed (X, Y):", - "parallax": "Parallax (X, Y):", - "repeat": "Repeat:", - "scale": "Scaling (X, Y):", - "shift": "Shift (X, Y):" - }, - "roomtiles": { - "moveTileLayer": "Move to a new depth", - "show": "Show the layer", - "hide": "Hide the layer", - "findTileset": "Find a Tileset" - }, - "roomview": { - "name": "Name:", - "width": "View width:", - "height": "View height:", - "events": "Room events", - "copies": "Copies", - "backgrounds": "Backgrounds", - "tiles": "Tiles", - "add": "Add", - "none": "Nothing", - "done": "Done", - "zoom": "Zoom:", - "grid": "Set grid", - "gridoff": "Disable grid", - "gridsize": "Grid size:", - "hotkeysNotice": "Ctrl = Delete, Alt = No grid, Shift = Multiple", - "hotkeysNoticeMovement": "Ctrl = Delete, Shift = Select", - "tocenter": "To center", - "selectbg": "Select tileset", - "shift": "Shift the view", - "shifttext": "Shift by:", - "step": "On Step", - "create": "On Create", - "leave": "On Leave", - "draw": "Draw", - "newdepth": "New depth:", - "deletecopy": "Delete copy {0}", - "deleteCopies": "Delete copies", - "shiftCopies": "Shift copies", - "selectAndMove": "Select and Move", - "changecopyscale": "Change scale", - "shiftcopy": "Set coordinates", - "deletetile": "Delete a tile", - "deletetiles": "Delete tiles", - "movetilestolayer": "Move to layer", - "shifttiles": "Shift tiles" - }, - "notepad": { - "local": "Project's notepad", - "global": "Global notepad", - "helppages": "Help", - "backToHome": "Back to docs' homepage" - }, - "preview": { - "reload": "Reload", - "roomRestart": "Restart the room", - "openExternal": "Open in browser", - "getQR": "QR codes and local server URL" - } -} +{ + "me": { + "id": "Eng", + "native": "English", + "eng": "English" + }, + "common": { + "add": "Add", + "addtonotes": "Add to notes", + "apply": "Apply", + "cancel": "Cancel", + "cannotBeEmpty": "This cannot be empty", + "confirmDelete": "Are you sure you want to delete {0}? It cannot be undone.", + "contribute": "Contribute 💻", + "copy": "Copy", + "copyName": "Copy the name", + "ctsite": "ct.js homepage", + "cut": "Cut", + "delete": "Delete", + "donate": "Donate ❤️", + "done": "Done!", + "duplicate": "Duplicate", + "exit": "Exit", + "exitconfirm": "Are you sure you want to exit?
All the unsaved changes will be lost!", + "fastimport": "Fast Import", + "language": "Language", + "translateToYourLanguage": "Translate ct.js to your language!", + "name": "Name:", + "nametaken": "This name is already taken", + "newname": "New name:", + "no": "No", + "none": "None", + "norooms": "You need at least one room to compile your app.", + "notfoundorunknown": "Unknown file. Make sure the file really exists", + "ok": "Ok", + "open": "Open", + "openproject": "Open project...", + "paste": "Paste", + "reallyexit": "Are you sure you want to exit? All unsaved changes will be lost.", + "rename": "Rename", + "save": "Save", + "savedcomm": "Your project was succesfully saved.", + "saveproject": "Save project", + "sort": "Sort:", + "tilelayer": "tile layer", + "wrongFormat": "Wrong file format", + "yes": "Yes" + }, + "actionsEditor": { + "actions": "Actions", + "actionsEditor": "Actions editor", + "addAction": "Add an action", + "addMethod": "Add an input method", + "deleteAction": "Delete this action", + "deleteMethod": "Delete this method", + "inputActionNamePlaceholder": "Action name", + "methodModuleMissing": "The required module for this method is missing", + "methods": "Input methods", + "multiplier": "Multiplier", + "noActionsYet": "Actions allow developers to listen to numerous input methods at once and dynamically change them, all with one uniform API. Read more by clicking on the docs icon above." + }, + "colorPicker": { + "current": "New", + "globalPalette": "Global Palette", + "old": "Old", + "projectPalette": "Project's Palette" + }, + "docsShortcut": { + "openDocs": "Open the documentation" + }, + "exportPanel": { + "hide": "Hide", + "working": "Working…", + "debug": "Debug version", + "export": "Export", + "exportPanel": "Export the Project", + "firstrunnotice": "The first run for each platform will be slow as ct.js will download and save additional libraries needed for packing. It will take some time, but next times will be almost instant.", + "log": "Message Log" + }, + "inputMethodSelector": { + "select": "Select" + }, + "intro": { + "loading": "Please wait: kittens are gathering speed of light!", + "newProject": { + "button": "Create", + "input": "Project's name (letters and digits)", + "text": "Create new", + "nameerr": "Wrong project name." + }, + "recovery": { + "message": "

Recovery

ct.js has found a recovery file. Possibly, your project was not saved correctly or ct.js was shut down in case of some emergency. Here is when these files were lastly modified:

Your chosen file: {0} {1}
Recovery file: {2} {3}

What file should ct.js open?

", + "loadTarget": "Target File", + "loadRecovery": "Recovery", + "newer": "(newer)", + "older": "(older)" + }, + "loadingProject": "Loading the project…", + "loadingProjectError": "Cannot open this project because of the following error: ", + "homepage": "Homepage", + "latestVersion": "Version $1 is available", + "forgetProject": "Forget this project", + "browse": "Browse", + "latest": "Latest projects", + "unableToWriteToFolders": "Ct.js could not find an appropriate place for projects! Make sure you store ct.js app inside a folder you have access to write to.", + "twitter": "Twitter channel", + "discord": "Discord community" + }, + "licensepanel": { + "ctjslicense": "Ct.js License (MIT)" + }, + "menu": { + "ctIDE": "ct.IDE", + "exportDesktop": "Export for desktop", + "texture": "Textures", + "launch": "Compile", + "license": "License", + "min": "Windowed", + "modules": "Catmods", + "recentProjects": "Recent projects", + "rooms": "Rooms", + "save": "Save project", + "startScreen": "Return to the starting screen", + "settings": "Settings", + "sounds": "Sounds", + "successZipExport": "Successfully exported to {0}.", + "successZipProject": "Successfully zipped the project to {0}.", + "ui": "UI", + "theme": "Theme", + "themeDay": "Light", + "themeNight": "Dark", + "types": "Types", + "zipExport": "Export to .zip", + "zipProject": "Pack project to .zip", + "codeFontDefault": "Default (Iosevka Light)", + "codeFontOldSchool": "Old school", + "codeFontSystem": "System", + "codeFontCustom": "Custom…", + "newFont": "New font:", + "codeFont": "Font for code", + "codeLigatures": "Ligatures", + "codeDense": "Dense layout", + "openIncludeFolder": "Open \"include\" folder" + }, + "settings": { + "actions": "Actions and input methods", + "author": "Author name:", + "authoring": "Authoring", + "cover": "Cover:", + "editActions": "Edit actions", + "exportparams": "Export parameters", + "framerate": "Framerate:", + "getfile": "Choose", + "highDensity": "Support high pixel density (e.g. on retina screens)", + "maxFPS": "Max framerate:", + "minifyhtmlcss": "Compress HTML and CSS", + "minifyjs": "Compress JavaScript and convert it to ES5 (slow; use for releases)", + "pixelatedrender": "Disable image smoothing here and in exported project (preserve crisp pixels)", + "renderoptions": "Render Options", + "settings": "Project settings", + "site": "Homepage:", + "title": "Name:", + "version": "Version:", + "versionpostfix": "Postfix:", + "scripts": { + "addNew": "Add a New Script", + "deleteScript": "Delete the script", + "header": "Scripts", + "newScriptComment": "Use scripts to define frequent functions and import small libraries" + } + }, + "modules": { + "author": "Author of this catmod", + "hasfields": "Configurable", + "hasinjects": "Has injections", + "hasinputmethods": "Provides additional input methods", + "help": "Reference", + "info": "Info", + "license": "License", + "logs": "Changelog", + "methods": "Methods", + "parameters": "Parameters", + "logs2": "Changelog", + "settings": "Settings" + }, + "texture": { + "create": "Create", + "import": "Import", + "skeletons": "Skeletal Animation" + }, + "textureview": { + "bgcolor": "Change bg color", + "center": "Axis:", + "cols": "Columns:", + "done": "Apply", + "fill": "Fill", + "form": "Collision shape:", + "frames": "Frame count:", + "isometrify": "Isometrify: Move the axis to the middle bottom point, fill the whole sprite with a collision mask", + "name": "Name:", + "radius": "Radius:", + "rectangle": "Rectangle", + "reimport": "Reimport", + "round": "Circle", + "rows": "Rows:", + "setcenter": "Image's center", + "speed": "Framerate:", + "tiled": "Use as a background?", + "replacetexture": "Replace…", + "corrupted": "File is corrupted or missing! Closing now.", + "showmask": "Show mask", + "width": "Width:", + "height": "Height:", + "marginx": "Margin X:", + "marginy": "Margin Y:", + "offx": "Offset X:", + "offy": "Offset Y:", + "strip": "Line Strip / Polygon", + "removePoint": "Remove the point", + "closeShape": "Close the shape", + "addPoint": "Add a point", + "moveCenter": "Move axis", + "movePoint": "Move this point", + "symmetryTool": "Symmetry tool" + }, + "sounds": { + "create": "Create" + }, + "soundview": { + "import": "Import", + "name": "Name:", + "save": "Save", + "isMusicFile": "This is a musical track", + "poolSize": "Pool size:" + }, + "styles": { + "create": "Create", + "styles": "Text Styles" + }, + "styleview": { + "active": "Active", + "alignment": "Alignment:", + "apply": "Apply", + "fill": "Fill", + "fillcolor": "Color:", + "fillcolor1": "Color 1:", + "fillcolor2": "Color 2:", + "fillgrad": "Gradient", + "fillgradtype": "Gradient type:", + "fillhorisontal": "Horizontal", + "fillsolid": "Diffuse", + "filltype": "Fill type:", + "fillvertical": "Vertical", + "font": "Font", + "fontweight": "Weight:", + "fontsize": "Font size:", + "fontfamily": "Font family:", + "italic": "Italic", + "lineHeight": "Line height:", + "shadow": "Shadow", + "shadowblur": "Blur:", + "shadowcolor": "Shadow color:", + "shadowshift": "Shift:", + "stroke": "Stroke", + "strokecolor": "Stroke color:", + "strokeweight": "Line weight:", + "testtext": "Test text 0123 +", + "textWrap": "Word wrap", + "textWrapWidth": "Max width:" + }, + "fonts": { + "fonts": "Fonts", + "import": "Import TTF", + "italic": "Italic" + }, + "fontview": { + "typefacename": "Typeface name:", + "fontweight": "Font weight:", + "italic": "Is italic?", + "reimport": "Reimport" + }, + "types": { + "create": "Create" + }, + "typeview": { + "change": "Change sprite", + "create": "On Create", + "depth": "Depth:", + "destroy": "On Destroy", + "done": "Done", + "draw": "Draw", + "learnAboutTypes": "Learn about coding types", + "name": "Name:", + "step": "On Step" + }, + "rooms": { + "create": "Add new", + "makestarting": "Set as the starting room" + }, + "roombackgrounds": { + "add": "Add a Background", + "depth": "Depth:", + "movement": "Movement speed (X, Y):", + "parallax": "Parallax (X, Y):", + "repeat": "Repeat:", + "scale": "Scaling (X, Y):", + "shift": "Shift (X, Y):" + }, + "roomtiles": { + "moveTileLayer": "Move to a new depth", + "show": "Show the layer", + "hide": "Hide the layer", + "findTileset": "Find a Tileset" + }, + "roomview": { + "name": "Name:", + "width": "View width:", + "height": "View height:", + "events": "Room events", + "copies": "Copies", + "backgrounds": "Backgrounds", + "tiles": "Tiles", + "add": "Add", + "none": "Nothing", + "done": "Done", + "zoom": "Zoom:", + "grid": "Set grid", + "gridoff": "Disable grid", + "gridsize": "Grid size:", + "hotkeysNotice": "Ctrl = Delete, Alt = No grid, Shift = Multiple", + "hotkeysNoticeMovement": "Ctrl = Delete, Shift = Select", + "tocenter": "To center", + "selectbg": "Select tileset", + "shift": "Shift the view", + "shifttext": "Shift by:", + "step": "On Step", + "create": "On Create", + "leave": "On Leave", + "draw": "Draw", + "newdepth": "New depth:", + "deletecopy": "Delete copy {0}", + "deleteCopies": "Delete copies", + "shiftCopies": "Shift copies", + "selectAndMove": "Select and Move", + "changecopyscale": "Change scale", + "shiftcopy": "Set coordinates", + "deletetile": "Delete a tile", + "deletetiles": "Delete tiles", + "movetilestolayer": "Move to layer", + "shifttiles": "Shift tiles", + "findTileset": "Find a tileset" + }, + "notepad": { + "local": "Project's notepad", + "global": "Global notepad", + "helppages": "Help", + "backToHome": "Back to docs' homepage" + }, + "preview": { + "reload": "Reload", + "roomRestart": "Restart the room", + "openExternal": "Open in browser", + "getQR": "QR codes and local server URL" + } +} \ No newline at end of file diff --git a/app/data/i18n/French.json b/app/data/i18n/French.json index 7416a0c7c..46794062a 100644 --- a/app/data/i18n/French.json +++ b/app/data/i18n/French.json @@ -1,332 +1,364 @@ { "me": { - "id": "Fr", - "native": "Française", - "eng": "French" + "id": "Fr", + "native": "Française", + "eng": "French" }, "colorPicker": { - "current": "Nouveau", - "globalPalette": "Palette Globale", - "old": "Vieux", - "projectPalette": "Palette de Projets" + "current": "Nouveau", + "globalPalette": "Palette Globale", + "old": "Vieux", + "projectPalette": "Palette de Projets" }, "common": { - "add": "Ajouter", - "addtonotes": "Ajouter aux notes", - "apply": "Appliquer", - "cancel": "Annuler", - "confirmDelete": "Êtes-vous certain de vouloir supprimer {0} ? C'est irréversible.", - "contribute": "Contribute 💻", - "copy": "Copier", - "copyName": "Copier le nom", - "ctsite": "Page d'accueil de ct.js", - "cut": "Couper", - "delete": "Supprimer", - "donate": "Faire un Don ❤", - "done": "Fini!", - "duplicate": "Dupliquer", - "exit": "Quitter", - "exitconfirm": "Êtes-vous sur de vouloir quitter ?
Tout les changements non sauvegardé seront perdu!", - "fastimport": "Import Rapide", - "language": "Langue", - "name": "Nom:", - "nametaken": "Ce nom est déjà pris", - "newname": "Nouveau nom:", - "newversion": "# Une nouvelle version est disponible\n", - "no": "Non", - "none": "Aucune", - "norooms": "Nécessite au moins une \"room\" pour compiler l'application", - "notfoundorunknown": "Fichier inconnu. Soyez sur que le fichier existe vraiment", - "ok": "Valider", - "open": "Ouvrir", - "openproject": "Ouvrir un projet...", - "paste": "Coller", - "reallyexit": "Êtes-vous sur de vouloir quitter ? Tout les changements non sauvegardé seront perdu!", - "rename": "Renommer", - "save": "Enregistrer", - "savedcomm": "Votre projet a été enregistré.", - "saveproject": "Sauvegarder le projet", - "sort": "Trier:", - "tilelayer": "Couche de Tuile", - "wrongFormat": "Mauvais format de fichier", - "yes": "Oui" + "add": "Ajouter", + "addtonotes": "Ajouter aux notes", + "apply": "Appliquer", + "cancel": "Annuler", + "confirmDelete": "Êtes-vous certain de vouloir supprimer {0} ? C'est irréversible.", + "contribute": "", + "copy": "Copier", + "copyName": "Copier le nom", + "ctsite": "Page d'accueil de ct.js", + "cut": "Couper", + "delete": "Supprimer", + "donate": "Faire un Don ❤️", + "done": "Fini!", + "duplicate": "Dupliquer", + "exit": "Quitter", + "exitconfirm": "Êtes-vous sur de vouloir quitter ?
Tout les changements non sauvegardé seront perdu!", + "fastimport": "Import Rapide", + "language": "Langue", + "name": "Nom:", + "nametaken": "Ce nom est déjà pris", + "newname": "Nouveau nom:", + "no": "Non", + "none": "Aucune", + "norooms": "Nécessite au moins une \"room\" pour compiler l'application", + "notfoundorunknown": "Fichier inconnu. Soyez sur que le fichier existe vraiment", + "ok": "Valider", + "open": "Ouvrir", + "openproject": "Ouvrir un projet...", + "paste": "Coller", + "reallyexit": "Êtes-vous sur de vouloir quitter ? Tout les changements non sauvegardé seront perdu!", + "rename": "Renommer", + "save": "Enregistrer", + "savedcomm": "Votre projet a été enregistré.", + "saveproject": "Sauvegarder le projet", + "sort": "Trier:", + "tilelayer": "Couche de Tuile", + "wrongFormat": "Mauvais format de fichier", + "yes": "Oui", + "cannotBeEmpty": "", + "translateToYourLanguage": "" }, "exportPanel": { - "hide": "Cacher", - "working": "En train de travailler...", - "debug": "Version de débogage", - "export": "Exporter", - "exportPanel": "Exporter le Projet", - "firstrunnotice": "Le premier lancement pour chaque plateforme sera lent car ct.js va télécharger et sauvegarder les librairies additionnels requises pour les rassembler. Cela va prendre un certain temps, mais les prochaines fois ce sera presque instantané.", - "log": "Journal de Message" + "hide": "Cacher", + "working": "En train de travailler...", + "debug": "Version de débogage", + "export": "Exporter", + "exportPanel": "Exporter le Projet", + "firstrunnotice": "Le premier lancement pour chaque plateforme sera lent car ct.js va télécharger et sauvegarder les librairies additionnels requises pour les rassembler. Cela va prendre un certain temps, mais les prochaines fois ce sera presque instantané.", + "log": "Journal de Message" }, "intro": { - "loading": "Veuillez patientez: des chatons ", - "newProject": { - "button": "Créer", - "input": "Nom du projet (Lettres et chiffres)", - "text": "Créer un nouveau", - "nameerr": "Mauvais nom de projet." - }, - "recovery": { - "message": "

Recovery

ct.js has found a recovery file. Possibly, your project was not saved correctly or ct.js was shut down in case of some emergency. Here is when these files were lastly modified:

Your chosen file: {0} {1}
Recovery file: {2} {3}

What file should ct.js open?

", - "loadTarget": "Fichier cible", - "loadRecovery": "Récupération", - "newer": "(récent)", - "older": "(ancien)" - }, - "homepage": "Page d'accueil", - "latestVersion": "La version 1$ est disponible", - "forgetProject": "Oublier ce projet", - "browse": "Parcourir", - "latest": "Derniers projets", - "twitter": "Chaîne Twitter", - "discord": "Communauté Discord" + "loading": "Veuillez patientez: des chatons ", + "newProject": { + "button": "Créer", + "input": "Nom du projet (Lettres et chiffres)", + "text": "Créer un nouveau", + "nameerr": "Mauvais nom de projet." + }, + "recovery": { + "message": "

Recovery

ct.js has found a recovery file. Possibly, your project was not saved correctly or ct.js was shut down in case of some emergency. Here is when these files were lastly modified:

Your chosen file: {0} {1}
Recovery file: {2} {3}

What file should ct.js open?

", + "loadTarget": "Fichier cible", + "loadRecovery": "Récupération", + "newer": "(récent)", + "older": "(ancien)" + }, + "homepage": "Page d'accueil", + "latestVersion": "La version 1$ est disponible", + "forgetProject": "Oublier ce projet", + "browse": "Parcourir", + "latest": "Derniers projets", + "twitter": "Chaîne Twitter", + "discord": "Communauté Discord", + "loadingProject": "", + "loadingProjectError": "", + "unableToWriteToFolders": "" }, "licensepanel": { "ctjslicense": "Ct.js License (MIT)" }, "menu": { - "ctIDE": "ct.IDE", - "exportDesktop": "Exporter pour le bureau", - "texture": "Graphiques", - "launch": "Compiler", - "license": "Licence", - "min": "Fenêtré", - "modules": "Catmods", - "recentProjects": "Projets récents", - "rooms": "Salons", - "save": "Sauvegarder le projet", - "startScreen": "Retourner à l'écran de démarrage", - "settings": "Paramètres", - "sounds": "Sons", - "ui": "IU", - "theme": "Thème", - "themeDay": "Clair", - "themeNight": "Sombre", - "types": "Types", - "zipExport": "Exporter en .zip", - "zipProject": "Compresser le projet en .zip" + "ctIDE": "ct.IDE", + "exportDesktop": "Exporter pour le bureau", + "texture": "Graphiques", + "launch": "Compiler", + "license": "Licence", + "min": "Fenêtré", + "modules": "Catmods", + "recentProjects": "Projets récents", + "rooms": "Salons", + "save": "Sauvegarder le projet", + "startScreen": "Retourner à l'écran de démarrage", + "settings": "Paramètres", + "sounds": "Sons", + "ui": "IU", + "theme": "Thème", + "themeDay": "Clair", + "themeNight": "Sombre", + "types": "Types", + "zipExport": "Exporter en .zip", + "zipProject": "Compresser le projet en .zip", + "successZipExport": "", + "successZipProject": "", + "codeFontDefault": "", + "codeFontOldSchool": "", + "codeFontSystem": "", + "codeFontCustom": "", + "newFont": "", + "codeFont": "", + "codeLigatures": "", + "codeDense": "" }, "settings": { - "author": "Nom de l'auteur:", - "authoring": "Auteur", - "cover": "Couverture:", - "exportparams": "Exporter les paramètres", - "framerate": "Taux d'image:", - "getfile": "Choisir", - "maxFPS": "Max framerate:", - "minifyhtmlcss": "Compresser HTML et CSS", - "minifyjs": "Compresser le JavaScript et convertir vers ES5 (lent; utilisé pour la publication)", - "pixelatedrender": "Disable image smoothing here and in exported project (preserve crisp pixels)", - "preloader": "Preloader", - "renderoptions": "Render Options", - "settings": "Project settings", - "site": "Homepage:", - "title": "Name:", - "version": "Version:", - "versionpostfix": "Postfix:", - "preloaders": { - "circular": "Circular", - "bar": "Progress bar", - "no": "No preloader" - }, - "scripts": { - "addNew": "Add a New Script", - "deleteScript": "Delete the script", - "header": "Scripts", - "newScriptComment": "Use scripts to define frequent functions and import small libraries" - } + "author": "Nom de l'auteur:", + "authoring": "Auteur", + "cover": "Couverture:", + "exportparams": "Exporter les paramètres", + "framerate": "Taux d'image:", + "getfile": "Choisir", + "maxFPS": "Max framerate:", + "minifyhtmlcss": "Compresser HTML et CSS", + "minifyjs": "Compresser le JavaScript et convertir vers ES5 (lent; utilisé pour la publication)", + "pixelatedrender": "", + "renderoptions": "", + "settings": "", + "site": "", + "title": "", + "version": "Version:", + "versionpostfix": "Postfix:", + "scripts": { + "addNew": "", + "deleteScript": "", + "header": "", + "newScriptComment": "" + }, + "actions": "", + "editActions": "", + "highDensity": "" }, "modules": { - "author": "Author of this catmod", - "hasfields": "Configurable", - "hasinjects": "Has injections", - "help": "Reference", - "info": "Info", - "license": "License", - "logs": "Logs", - "methods": "Methods", - "parameters": "Parameters", - "nomethods": "This module hasn't its own methods.", - "noparameters": "This module hasn't its own parameters.", - "logs2": "Logs", - "settings": "Settings" + "author": "Author of this catmod", + "hasfields": "Configurable", + "hasinjects": "Has injections", + "help": "Reference", + "info": "Info", + "license": "License", + "logs": "", + "methods": "", + "parameters": "", + "logs2": "", + "settings": "", + "hasinputmethods": "" }, "texture": { - "create": "Create", - "import": "Import", - "skeletons": "Skeletal Animation" + "create": "", + "import": "", + "skeletons": "" }, "textureview": { - "bgcolor": "Change bg color", - "center": "Axis:", - "cols": "Columns:", - "done": "Apply", - "fill": "Fill", - "form": "Collision shape:", - "frames": "Frame count:", - "isometrify": "Isometrify: Move the axis to the middle bottom point, fill the whole sprite with a collision mask", - "name": "Name:", - "radius": "Radius:", - "rectangle": "Rectangle", - "reimport": "Reimport", - "round": "Circle", - "rows": "Rows:", - "setcenter": "Image's center", - "speed": "Framerate:", - "tiled": "Is it tiled?", - "replacetexture": "Replace…", - "corrupted": "File is corrupted or missing! Closing now.", - "showmask": "Show mask", - "width": "Width:", - "height": "Height:", - "marginx": "Margin X:", - "marginy": "Margin Y:", - "offx": "Offset X:", - "offy": "Offset Y:", - "strip": "Line Strip / Polygon", - "removePoint": "Remove the point", - "closeShape": "Close the shape", - "addPoint": "Add a point", - "moveCenter": "Move axis", - "movePoint": "Move this point" + "bgcolor": "", + "center": "", + "cols": "", + "done": "", + "fill": "", + "form": "", + "frames": "", + "isometrify": "", + "name": "", + "radius": "", + "rectangle": "", + "reimport": "", + "round": "", + "rows": "Rows:", + "setcenter": "", + "speed": "", + "tiled": "", + "replacetexture": "", + "corrupted": "", + "showmask": "", + "width": "", + "height": "", + "marginx": "", + "marginy": "", + "offx": "", + "offy": "", + "strip": "", + "removePoint": "", + "closeShape": "", + "addPoint": "", + "moveCenter": "", + "movePoint": "", + "symmetryTool": "Outil de symétrie" }, "sounds": { - "create": "Create" + "create": "" }, "soundview": { - "import": "Import", - "name": "Name:", - "save": "Save", - "isMusicFile": "This is a musical track", - "poolSize": "Pool size:" + "import": "", + "name": "", + "save": "", + "isMusicFile": "", + "poolSize": "" }, "styles": { - "create": "Create", - "styles": "Text Styles" + "create": "", + "styles": "" }, "styleview": { - "active": "Active", - "alignment": "Alignment:", - "apply": "Apply", - "fill": "Fill", - "fillcolor": "Color:", - "fillcolor1": "Color 1:", - "fillcolor2": "Color 2:", - "fillgrad": "Gradient", - "fillgradtype": "Gradient type:", - "fillhorisontal": "Horizontal", - "fillsolid": "Diffuse", - "filltype": "Fill type:", - "fillvertical": "Vertical", - "font": "Font", - "fontweight": "Weight:", - "fontsize": "Font size:", - "fontfamily": "Font family:", - "italic": "Italic", - "lineHeight": "Line height:", - "shadow": "Shadow", - "shadowblur": "Blur:", - "shadowcolor": "Shadow color:", - "shadowshift": "Shift:", - "stroke": "Stroke", - "strokecolor": "Stroke color:", - "strokeweight": "Line weight:", - "testtext": "Test text 0123 +", - "textWrap": "Word wrap", - "textWrapWidth": "Max width:" + "active": "", + "alignment": "", + "apply": "", + "fill": "", + "fillcolor": "", + "fillcolor1": "", + "fillcolor2": "", + "fillgrad": "", + "fillgradtype": "", + "fillhorisontal": "", + "fillsolid": "", + "filltype": "", + "fillvertical": "Vertical", + "font": "", + "fontweight": "", + "fontsize": "", + "fontfamily": "", + "italic": "", + "lineHeight": "", + "shadow": "", + "shadowblur": "", + "shadowcolor": "", + "shadowshift": "", + "stroke": "", + "strokecolor": "", + "strokeweight": "", + "testtext": "", + "textWrap": "", + "textWrapWidth": "" }, "fonts": { - "fonts": "Fonts", - "import": "Import TTF", - "italic": "Italic" + "fonts": "Fonts", + "import": "Import TTF", + "italic": "Italic" }, "fontview": { - "typefacename": "Typeface name:", - "fontweight": "Font weight:", - "italic": "Is italic?", - "reimport": "Reimport" + "typefacename": "", + "fontweight": "", + "italic": "", + "reimport": "" }, "types": { - "create": "Create" + "create": "" }, "typeview": { - "change": "Change sprite", - "create": "On Create", - "depth": "Depth:", - "destroy": "On Destroy", - "done": "Done", - "draw": "Draw", - "name": "Name:", - "step": "On Step" + "change": "", + "create": "", + "depth": "", + "destroy": "", + "done": "", + "draw": "", + "name": "", + "step": "", + "learnAboutTypes": "" }, "rooms": { - "create": "Add new", - "makestarting": "Set as starting room" + "create": "", + "makestarting": "" }, "roombackgrounds": { - "add": "Add a Background", - "depth": "Depth:", - "movement": "Movement speed (X, Y):", - "parallax": "Parallax (X, Y):", - "repeat": "Repeat:", - "scale": "Scaling (X, Y):", - "shift": "Shift (X, Y):" + "add": "", + "depth": "", + "movement": "", + "parallax": "", + "repeat": "", + "scale": "", + "shift": "" }, "roomtiles": { - "moveTileLayer": "Move to a new depth", - "show": "Show the layer", - "hide": "Hide the layer", - "findTileset": "Find a Tileset" + "moveTileLayer": "", + "show": "", + "hide": "", + "findTileset": "" }, "roomview": { - "name": "Name:", - "width": "View width:", - "height": "View height:", - "events": "Room events", - "copies": "Copies", - "backgrounds": "Backgrounds", - "tiles": "Tiles", - "add": "Add", - "none": "Nothing", - "done": "Done", - "zoom": "Zoom:", - "grid": "Set grid", - "gridoff": "Disable grid", - "gridsize": "Grid size:", - "hotkeysNotice": "Ctrl = Delete, Alt = No grid, Shift = Multiple", - "hotkeysNoticeMovement": "Ctrl = Delete, Shift = Select", - "tocenter": "To center", - "selectbg": "Select tileset", - "shift": "Shift the view", - "shifttext": "Shift by:", - "step": "On Step", - "create": "On Create", - "leave": "On Leave", - "draw": "Draw", - "newdepth": "New depth:", - "deletecopy": "Delete copy {0}", - "deleteCopies": "Delete copies", - "shiftCopies": "Shift copies", - "selectAndMove": "Select and Move", - "changecopyscale": "Change scale", - "shiftcopy": "Set coordinates", - "deletetile": "Delete a tile", - "deletetiles": "Delete tiles", - "movetilestolayer": "Move to layer", - "shifttiles": "Shift tiles" + "name": "", + "width": "", + "height": "", + "events": "", + "copies": "", + "backgrounds": "", + "tiles": "", + "add": "", + "none": "", + "done": "", + "zoom": "", + "grid": "", + "gridoff": "", + "gridsize": "", + "hotkeysNotice": "", + "hotkeysNoticeMovement": "", + "tocenter": "", + "selectbg": "", + "shift": "", + "shifttext": "", + "step": "", + "create": "", + "leave": "", + "draw": "", + "newdepth": "", + "deletecopy": "", + "deleteCopies": "", + "shiftCopies": "", + "selectAndMove": "", + "changecopyscale": "", + "shiftcopy": "", + "deletetile": "", + "deletetiles": "", + "movetilestolayer": "", + "shifttiles": "", + "findTileset": "" }, "notepad": { - "local": "Project's notepad", - "global": "Global notepad", - "helppages": "Help", - "backToHome": "Back to docs' homepage" + "local": "", + "global": "", + "helppages": "", + "backToHome": "" }, "preview": { - "reload": "Reload", - "roomRestart": "Restart the room", - "openExternal": "Open in browser", - "getQR": "QR codes and local server URL" + "reload": "", + "roomRestart": "", + "openExternal": "", + "getQR": "" + }, + "actionsEditor": { + "actions": "", + "actionsEditor": "", + "addAction": "", + "addMethod": "", + "deleteAction": "", + "deleteMethod": "", + "inputActionNamePlaceholder": "", + "methodModuleMissing": "", + "methods": "", + "multiplier": "", + "noActionsYet": "" + }, + "docsShortcut": { + "openDocs": "" + }, + "inputMethodSelector": { + "select": "" } - } \ No newline at end of file +} \ No newline at end of file diff --git a/app/data/i18n/German.json b/app/data/i18n/German.json index 676e6bcc4..94ea824f7 100755 --- a/app/data/i18n/German.json +++ b/app/data/i18n/German.json @@ -1,364 +1,364 @@ { - "me": { - "id": "De", - "native": "Deutsch", - "eng": "German" - }, - - "common": { - "add": "Hinzufügen", - "addtonotes": "Zu Notizen hinzufügen", - "apply": "Anwenden", - "cancel": "Abbrechen", - "cannotBeEmpty": "Dies darf nicht leer sein", - "confirmDelete": "Möchten Sie {0} wirklich löschen? Dies kann nicht rückgängig gemacht werden.", - "contribute": "Mitwirken 💻", - "copy": "Kopieren", - "copyName": "Namen kopieren", - "ctsite": "ct.js Homepage", - "cut": "Ausschneiden", - "delete": "Löschen", - "donate": "Spenden ❤️", - "done": "Fertig!", - "duplicate": "Duplizieren", - "exit": "Beenden", - "exitconfirm": "Möchten Sie das Programm wirklich beenden?
Alle ungespeicherten Änderungen gehen dabei verlohren!", - "fastimport": "Schneller Import", - "language": "Sprache", - "translateToYourLanguage": "Übersetzen Sie ct.js in Ihre Sprache!", - "name": "Name:", - "nametaken": "Dieser Name wird bereits verwendet", - "newname": "Neuer Name:", - "newversion": "# Eine neue Version ist verfügbar\n", - "no": "Nein", - "none": "Nichts", - "norooms": "Sie benötigen mindestens einen Raum um die App zu kompilieren.", - "notfoundorunknown": "Unbekannte Datei. Stellen Sie sicher, dass die Datei wirklich existiert", - "ok": "Ok", - "open": "Öffnen", - "openproject": "Project öffnen...", - "paste": "Einfügen", - "reallyexit": "Möchten Sie das Programm wirklich beenden? Alle ungespeicherten Änderungen gehen dabei verlohren!", - "rename": "Umbenennen", - "save": "Speichern", - "savedcomm": "Das Projekt wurde erfolgreich gespeichert.", - "saveproject": "Project speichern", - "sort": "Sortieren:", - "tilelayer": "Tile Ebene", - "wrongFormat": "Falsches Dateiformat", - "yes": "Ja" - }, - - "actionsEditor": { - "actions": "Actions", - "actionsEditor": "Actions Editor", - "addAction": "Eine Action hinzufügen", - "addMethod": "Eine Eingabemethode hinzufügen", - "deleteAction": "Diese Action löschen", - "deleteMethod": "Diese Method löschen", - "inputActionNamePlaceholder": "Action Name", - "methodModuleMissing": "Das für diese Methode benötigte Modul existiert nicht", - "methods": "Eingabemethoden", - "multiplier": "Multiplier", - "noActionsYet": "Actions erlauben Entwicklern auf zahlreiche Eingabemethoden gleichzeitig zu zuzugreifen und sie dynamisch zu verändern. Alles mit der gleichen API. Klicken Sie oben auf das Doks-Icon um mehr darüber zu erfahren." - }, - "colorPicker": { - "current": "Neu", - "globalPalette": "Globale Palette", - "old": "Alt", - "projectPalette": "Projekt Palette" - }, - "docsShortcut": { - "openDocs": "Dokumentation öffnen" - }, - "exportPanel": { - "hide": "Verbergen", - "working": "In Bearbeitung…", - "debug": "Debug Version", - "export": "Export", - "exportPanel": "Projekt exportieren", - "firstrunnotice": "Die erste Ausführung wird pro Plattform etwas länger dauern, da ct.js zusätzliche Bibliotheken zum Paketieren herunterladen muss. Dies wird einige Zeit dauern, beim nächsten Mal geht es deutlich schneller.", - "log": "Nachrichten Log" - }, - "inputMethodSelector": { - "select": "Auswählen" - }, - "intro": { - "loading": "Bitte warten: Kätzchen werden auf Lichtgeschwindigkeit beschleunigt!", - "loadingProject": "Projekt wird geladen...", - "newProject": { - "button": "Erstellen", - "input": "Projektname (Buchstaben und Zahlen)", - "text": "Neues Projekt erstellen", - "nameerr": "Falscher Projektname." - }, - "recovery": { - "message": "

Wiederherstellung

ct.js hat eine Wiederherstellungsdatei gefunden. Ihr Projekt wurde möglicherweise nicht richtig gespeichert oder ct.js wurde unerwartet beendet. Letzte Änderung der Datei:

Wählen Sie eine Datei: {0} {1}
Wiederherstellungs Datei: {2} {3}

Welche Datei soll ct.js öffnen?

", - "loadTarget": "Ziel Datei", - "loadRecovery": "Wiederherstellung", - "newer": "(neuer)", - "older": "(älter)" - }, - "homepage": "Homepage", - "latestVersion": "Version $1 ist verfügbar", - "forgetProject": "Vergiss dieses Projekt", - "browse": "Durchsuchen", - "latest": "Letzte Projekte", - "unableToWriteToFolders": "Ct.js konnte keinen geeigneten Ort zum speichern der Projekte finden! Bitte stellen Sie sicher, dass Sie die ct.js App in einem Verzeichnis ablegen in dem Sie über Schreibrechte verfügen.", - "twitter": "Twitter Channel", - "discord": "Discord Community" - }, - "licensepanel": { - "ctjslicense": "Ct.js Lizenz (MIT)" - }, - "menu": { - "ctIDE": "ct.IDE", - "exportDesktop": "Desktop Export", - "texture": "Texturen", - "launch": "Kompilieren", - "license": "Lizenz", - "min": "Fenster", - "modules": "Catmods", - "recentProjects": "Letzte Projekte", - "rooms": "Räume", - "save": "Projekt speichern", - "startScreen": "Zum Startbildschirm zurückkehren", - "settings": "Einstellungen", - "sounds": "Sounds", - "successZipExport": "Erfolgreich exportiert nach {0}.", - "successZipProject": "Projekt erfolgreich gezippt nach {0}.", - "ui": "UI", - "theme": "Thema", - "themeDay": "Hell", - "themeNight": "Dunkel", - "types": "Types", - "zipExport": "Als .zip Exportieren", - "zipProject": "Projekt als .zip komprimieren" - }, - "settings": { - "actions": "Actions und Eingabemethoden", - "author": "Name des Autors:", - "authoring": "Autor", - "cover": "Cover:", - "editActions": "Actions bearbeiten", - "exportparams": "Export Parameter", - "framerate": "Framerate:", - "getfile": "Auswählen", - "highDensity": "Hochauflösende Bildschirme unterstützen (z.B. Retina Displays)", - "maxFPS": "Max Framerate:", - "minifyhtmlcss": "HTML and CSS komprimieren", - "minifyjs": "JavaScript komprimieren und in ES5 konvertieren (langsam; Sinnvoll für das Release)", - "pixelatedrender": "Image Smoothing hier und im exportierten Projekt deaktivieren (scharfe Pixel beibehalten)", - "preloader": "Preloader", - "renderoptions": "Render Optionen", - "settings": "Project Einstellungen", - "site": "Homepage:", - "title": "Name:", - "version": "Version:", - "versionpostfix": "Postfix:", - "preloaders": { - "circular": "Kreisförmig", - "bar": "Fortschrittsbalken", - "no": "Kein Preloader" - }, - "scripts": { - "addNew": "Neues Skript hinzufügen", - "deleteScript": "Skript löschen", - "header": "Skripte", - "newScriptComment": "Nutzen Sie Skripte um häufige Funktionen zu definieren und Bibliotheken zu importieren" - } - }, - "modules": { - "author": "Autor dieses Catmods", - "hasfields": "Konfigurierbar", - "hasinjects": "Nutzt Injections", - "hasinputmethods": "Bietet zusätzliche Eingabemethoden", - "help": "Hilfe", - "info": "Info", - "license": "Lizenz", - "logs": "Changelog", - "methods": "Methods", - "parameters": "Parameter", - "nomethods": "Dieses Modul besitzt keine eigenen Methods.", - "noparameters": "Dieses Modul besitzt keine eigenen Parameter.", - "logs2": "Changelog", - "settings": "Einstellungen" - }, - "texture": { - "create": "Erstellen", - "import": "Importieren", - "skeletons": "Skelett Animation" - }, - "textureview": { - "bgcolor": "Hintergrundfarbe ändern", - "center": "Achse:", - "cols": "Spalten:", - "done": "Anwenden", - "fill": "Füllung", - "form": "Collision Shape:", - "frames": "Anzahl Frames:", - "isometrify": "Isometrifizieren: Die Achse auf den Punkt in der unteren Mitte bewegen un das gesamte Sprite mit einer Collision Mask füllen", - "name": "Name:", - "radius": "Radius:", - "rectangle": "Rechteck", - "reimport": "Reimport", - "round": "Kreis", - "rows": "Reihen:", - "setcenter": "Bildmittelpunkt", - "speed": "Framerate:", - "tiled": "Ist es getiled?", - "replacetexture": "Ersetzen...", - "corrupted": "Die Datei ist korrupt oder fehlt. Wird geschlossen.", - "showmask": "Maske zeigen", - "width": "Breite:", - "height": "Höhe:", - "marginx": "Rand X:", - "marginy": "Rand Y:", - "offx": "Abstand X:", - "offy": "Abstand Y:", - "strip": "Line Strip / Polygon", - "removePoint": "Punkt entfernen", - "closeShape": "Shape schließen", - "addPoint": "Punkt hinzufügen", - "moveCenter": "Achse verschieben", - "movePoint": "Punkt verschieben" - }, - "sounds": { - "create": "Erstellen" - }, - "soundview": { - "import": "Importieren", - "name": "Name:", - "save": "Speichern", - "isMusicFile": "Dies ist ein Musikstück", - "poolSize": "Pool Größe:" - }, - "styles": { - "create": "Erstellen", - "styles": "Text Styles" - }, - "styleview": { - "active": "Aktiv", - "alignment": "Ausrichtung:", - "apply": "Anwenden", - "fill": "Füllen", - "fillcolor": "Farbe:", - "fillcolor1": "Farbe 1:", - "fillcolor2": "Farbe 2:", - "fillgrad": "Farbverlauf", - "fillgradtype": "Farbverlauf Typ:", - "fillhorisontal": "Horizontal", - "fillsolid": "Einfarbig", - "filltype": "Fülltyp:", - "fillvertical": "Vertikal", - "font": "Schrift", - "fontweight": "Stärke:", - "fontsize": "Schriftgröße:", - "fontfamily": "Schriftfamilie:", - "italic": "Kursiv", - "lineHeight": "Zeilenhöhe:", - "shadow": "Schatten", - "shadowblur": "Unschärfe:", - "shadowcolor": "Schattenfarbe:", - "shadowshift": "Versatz:", - "stroke": "Kontur", - "strokecolor": "Konturfarbe:", - "strokeweight": "Konturstärke:", - "testtext" : "Test Text 0123 +", - "textWrap": "Zeilenumbruch", - "textWrapWidth": "Max Breite:" - }, - "fonts": { - "fonts": "Schriften", - "import": "TTF importieren", - "italic": "Kursiv" - }, - "fontview": { - "typefacename": "Typeface Name:", - "fontweight": "Schriftstärke:", - "italic": "Ist kursiv?", - "reimport": "Reimport" - }, - "types": { - "create": "Erstellen" - }, - "typeview": { - "change": "Sprite tauschen", - "create": "On Create", - "depth": "Ebene:", - "destroy": "On Destroy", - "done": "Fertig", - "draw": "Draw", - "learnAboutTypes": "Lernen Sie Types zu programmieren", - "name": "Name:", - "step": "On Step" - }, - "rooms": { - "create": "Neuer Raum", - "makestarting": "Als Startraum festlegen" - }, - "roombackgrounds": { - "add": "Hintergrund hinzufügen", - "depth": "Ebene:", - "movement": "Bewegungsgeschwindigkeit (X, Y):", - "parallax": "Parallax (X, Y):", - "repeat": "Wiederholen:", - "scale": "Skallieren (X, Y):", - "shift": "Verschieben (X, Y):" - }, - "roomtiles": { - "moveTileLayer": "Auf andere Ebene verschieben", - "show": "Ebene zeigen", - "hide": "Ebene ausblenden", - "findTileset": "Tileset finden" - }, - "roomview": { - "name": "Name:", - "width": "Sicht Breite:", - "height": "Sicht Höhe:", - "events": "Raum Events", - "copies": "Kopien", - "backgrounds": "Hintergründe", - "tiles": "Tiles", - "add": "Hinzufügen", - "none": "Nichts", - "done": "Fertig", - "zoom": "Zoom:", - "grid": "Raster konfigurieren", - "gridoff": "Raster deaktivieren", - "gridsize": "Rastergröße:", - "hotkeysNotice": "Strg = Entfernen, Alt = Kein Raster, Hochstelltaste = Mehrfach", - "hotkeysNoticeMovement": "Strg = Löschen, Hochstelltaste = Auswahl", - "tocenter": "zum Zentrum", - "selectbg": "Tileset auswählen", - "shift": "Sicht verschieben", - "shifttext": "Verschieben um:", - "step": "On Step", - "create": "On Create", - "leave": "On Leave", - "draw": "Draw", - "newdepth": "Neue Ebene:", - "deletecopy": "Kopie {0} löschen", - "deleteCopies": "Kopien löschen", - "shiftCopies": "Kopien verschieben", - "selectAndMove": "Auswählen und bewegen", - "changecopyscale": "Skallierung ändern", - "shiftcopy": "Koordinaten setzen", - "deletetile": "Tile löschen", - "deletetiles": "Tiles löschen ", - "movetilestolayer": "Auf Ebene verschieben", - "shifttiles": "Tiles verschieben" - }, - "notepad": { - "local": "Projekt Notizen", - "global": "Globale Notizen", - "helppages": "Hilfe", - "backToHome": "Zurück zu Doks' Homepage" - }, - "preview": { - "reload": "Neu laden", - "roomRestart": "Raum neu starten", - "openExternal": "Im Browser öffnen", - "getQR": "QR Codes und lokale Server URL" - } + "me": { + "id": "De", + "native": "Deutsch", + "eng": "German" + }, + "common": { + "add": "Hinzufügen", + "addtonotes": "Zu Notizen hinzufügen", + "apply": "Anwenden", + "cancel": "Abbrechen", + "cannotBeEmpty": "Dies darf nicht leer sein", + "confirmDelete": "Möchten Sie {0} wirklich löschen? Dies kann nicht rückgängig gemacht werden.", + "contribute": "Mitwirken 💻", + "copy": "Kopieren", + "copyName": "Namen kopieren", + "ctsite": "ct.js Homepage", + "cut": "Ausschneiden", + "delete": "Löschen", + "donate": "Spenden ❤️", + "done": "Fertig!", + "duplicate": "Duplizieren", + "exit": "Beenden", + "exitconfirm": "Möchten Sie das Programm wirklich beenden?
Alle ungespeicherten Änderungen gehen dabei verlohren!", + "fastimport": "Schneller Import", + "language": "Sprache", + "translateToYourLanguage": "Übersetzen Sie ct.js in Ihre Sprache!", + "name": "Name:", + "nametaken": "Dieser Name wird bereits verwendet", + "newname": "Neuer Name:", + "no": "Nein", + "none": "Nichts", + "norooms": "Sie benötigen mindestens einen Raum um die App zu kompilieren.", + "notfoundorunknown": "Unbekannte Datei. Stellen Sie sicher, dass die Datei wirklich existiert", + "ok": "Ok", + "open": "Öffnen", + "openproject": "Project öffnen...", + "paste": "Einfügen", + "reallyexit": "Möchten Sie das Programm wirklich beenden? Alle ungespeicherten Änderungen gehen dabei verlohren!", + "rename": "Umbenennen", + "save": "Speichern", + "savedcomm": "Das Projekt wurde erfolgreich gespeichert.", + "saveproject": "Project speichern", + "sort": "Sortieren:", + "tilelayer": "Tile Ebene", + "wrongFormat": "Falsches Dateiformat", + "yes": "Ja" + }, + "actionsEditor": { + "actions": "Actions", + "actionsEditor": "Actions Editor", + "addAction": "Eine Action hinzufügen", + "addMethod": "Eine Eingabemethode hinzufügen", + "deleteAction": "Diese Action löschen", + "deleteMethod": "Diese Method löschen", + "inputActionNamePlaceholder": "Action Name", + "methodModuleMissing": "Das für diese Methode benötigte Modul existiert nicht", + "methods": "Eingabemethoden", + "multiplier": "Multiplier", + "noActionsYet": "Actions erlauben Entwicklern auf zahlreiche Eingabemethoden gleichzeitig zu zuzugreifen und sie dynamisch zu verändern. Alles mit der gleichen API. Klicken Sie oben auf das Doks-Icon um mehr darüber zu erfahren." + }, + "colorPicker": { + "current": "Neu", + "globalPalette": "Globale Palette", + "old": "Alt", + "projectPalette": "Projekt Palette" + }, + "docsShortcut": { + "openDocs": "Dokumentation öffnen" + }, + "exportPanel": { + "hide": "Verbergen", + "working": "In Bearbeitung…", + "debug": "Debug Version", + "export": "Export", + "exportPanel": "Projekt exportieren", + "firstrunnotice": "Die erste Ausführung wird pro Plattform etwas länger dauern, da ct.js zusätzliche Bibliotheken zum Paketieren herunterladen muss. Dies wird einige Zeit dauern, beim nächsten Mal geht es deutlich schneller.", + "log": "Nachrichten Log" + }, + "inputMethodSelector": { + "select": "Auswählen" + }, + "intro": { + "loading": "Bitte warten: Kätzchen werden auf Lichtgeschwindigkeit beschleunigt!", + "loadingProject": "Projekt wird geladen...", + "newProject": { + "button": "Erstellen", + "input": "Projektname (Buchstaben und Zahlen)", + "text": "Neues Projekt erstellen", + "nameerr": "Falscher Projektname." + }, + "recovery": { + "message": "

Wiederherstellung

ct.js hat eine Wiederherstellungsdatei gefunden. Ihr Projekt wurde möglicherweise nicht richtig gespeichert oder ct.js wurde unerwartet beendet. Letzte Änderung der Datei:

Wählen Sie eine Datei: {0} {1}
Wiederherstellungs Datei: {2} {3}

Welche Datei soll ct.js öffnen?

", + "loadTarget": "Ziel Datei", + "loadRecovery": "Wiederherstellung", + "newer": "(neuer)", + "older": "(älter)" + }, + "homepage": "Homepage", + "latestVersion": "Version $1 ist verfügbar", + "forgetProject": "Vergiss dieses Projekt", + "browse": "Durchsuchen", + "latest": "Letzte Projekte", + "unableToWriteToFolders": "Ct.js konnte keinen geeigneten Ort zum speichern der Projekte finden! Bitte stellen Sie sicher, dass Sie die ct.js App in einem Verzeichnis ablegen in dem Sie über Schreibrechte verfügen.", + "twitter": "Twitter Channel", + "discord": "Discord Community", + "loadingProjectError": "" + }, + "licensepanel": { + "ctjslicense": "Ct.js Lizenz (MIT)" + }, + "menu": { + "ctIDE": "ct.IDE", + "exportDesktop": "Desktop Export", + "texture": "Texturen", + "launch": "Kompilieren", + "license": "Lizenz", + "min": "Fenster", + "modules": "Catmods", + "recentProjects": "Letzte Projekte", + "rooms": "Räume", + "save": "Projekt speichern", + "startScreen": "Zum Startbildschirm zurückkehren", + "settings": "Einstellungen", + "sounds": "Sounds", + "successZipExport": "Erfolgreich exportiert nach {0}.", + "successZipProject": "Projekt erfolgreich gezippt nach {0}.", + "ui": "UI", + "theme": "Thema", + "themeDay": "Hell", + "themeNight": "Dunkel", + "types": "Types", + "zipExport": "Als .zip Exportieren", + "zipProject": "Projekt als .zip komprimieren", + "codeFontDefault": "", + "codeFontOldSchool": "", + "codeFontSystem": "", + "codeFontCustom": "", + "newFont": "", + "codeFont": "", + "codeLigatures": "", + "codeDense": "" + }, + "settings": { + "actions": "Actions und Eingabemethoden", + "author": "Name des Autors:", + "authoring": "Autor", + "cover": "Cover:", + "editActions": "Actions bearbeiten", + "exportparams": "Export Parameter", + "framerate": "Framerate:", + "getfile": "Auswählen", + "highDensity": "Hochauflösende Bildschirme unterstützen (z.B. Retina Displays)", + "maxFPS": "Max Framerate:", + "minifyhtmlcss": "HTML and CSS komprimieren", + "minifyjs": "JavaScript komprimieren und in ES5 konvertieren (langsam; Sinnvoll für das Release)", + "pixelatedrender": "Image Smoothing hier und im exportierten Projekt deaktivieren (scharfe Pixel beibehalten)", + "renderoptions": "Render Optionen", + "settings": "Project Einstellungen", + "site": "Homepage:", + "title": "Name:", + "version": "Version:", + "versionpostfix": "Postfix:", + "scripts": { + "addNew": "Neues Skript hinzufügen", + "deleteScript": "Skript löschen", + "header": "Skripte", + "newScriptComment": "Nutzen Sie Skripte um häufige Funktionen zu definieren und Bibliotheken zu importieren" + } + }, + "modules": { + "author": "Autor dieses Catmods", + "hasfields": "Konfigurierbar", + "hasinjects": "Nutzt Injections", + "hasinputmethods": "Bietet zusätzliche Eingabemethoden", + "help": "Hilfe", + "info": "Info", + "license": "Lizenz", + "logs": "Changelog", + "methods": "Methods", + "parameters": "Parameter", + "logs2": "Changelog", + "settings": "Einstellungen" + }, + "texture": { + "create": "Erstellen", + "import": "Importieren", + "skeletons": "Skelett Animation" + }, + "textureview": { + "bgcolor": "Hintergrundfarbe ändern", + "center": "Achse:", + "cols": "Spalten:", + "done": "Anwenden", + "fill": "Füllung", + "form": "Collision Shape:", + "frames": "Anzahl Frames:", + "isometrify": "Isometrifizieren: Die Achse auf den Punkt in der unteren Mitte bewegen un das gesamte Sprite mit einer Collision Mask füllen", + "name": "Name:", + "radius": "Radius:", + "rectangle": "Rechteck", + "reimport": "Reimport", + "round": "Kreis", + "rows": "Reihen:", + "setcenter": "Bildmittelpunkt", + "speed": "Framerate:", + "tiled": "Als Hintergrund verwenden?", + "replacetexture": "Ersetzen...", + "corrupted": "Die Datei ist korrupt oder fehlt. Wird geschlossen.", + "showmask": "Maske zeigen", + "width": "Breite:", + "height": "Höhe:", + "marginx": "Rand X:", + "marginy": "Rand Y:", + "offx": "Abstand X:", + "offy": "Abstand Y:", + "strip": "Line Strip / Polygon", + "removePoint": "Punkt entfernen", + "closeShape": "Shape schließen", + "addPoint": "Punkt hinzufügen", + "moveCenter": "Achse verschieben", + "movePoint": "Punkt verschieben", + "symmetryTool": "Symmetrie-Werkzeug" + }, + "sounds": { + "create": "Erstellen" + }, + "soundview": { + "import": "Importieren", + "name": "Name:", + "save": "Speichern", + "isMusicFile": "Dies ist ein Musikstück", + "poolSize": "Pool Größe:" + }, + "styles": { + "create": "Erstellen", + "styles": "Text Styles" + }, + "styleview": { + "active": "Aktiv", + "alignment": "Ausrichtung:", + "apply": "Anwenden", + "fill": "Füllen", + "fillcolor": "Farbe:", + "fillcolor1": "Farbe 1:", + "fillcolor2": "Farbe 2:", + "fillgrad": "Farbverlauf", + "fillgradtype": "Farbverlauf Typ:", + "fillhorisontal": "Horizontal", + "fillsolid": "Einfarbig", + "filltype": "Fülltyp:", + "fillvertical": "Vertikal", + "font": "Schrift", + "fontweight": "Stärke:", + "fontsize": "Schriftgröße:", + "fontfamily": "Schriftfamilie:", + "italic": "Kursiv", + "lineHeight": "Zeilenhöhe:", + "shadow": "Schatten", + "shadowblur": "Unschärfe:", + "shadowcolor": "Schattenfarbe:", + "shadowshift": "Versatz:", + "stroke": "Kontur", + "strokecolor": "Konturfarbe:", + "strokeweight": "Konturstärke:", + "testtext": "Test Text 0123 +", + "textWrap": "Zeilenumbruch", + "textWrapWidth": "Max Breite:" + }, + "fonts": { + "fonts": "Schriften", + "import": "TTF importieren", + "italic": "Kursiv" + }, + "fontview": { + "typefacename": "Typeface Name:", + "fontweight": "Schriftstärke:", + "italic": "Ist kursiv?", + "reimport": "Reimport" + }, + "types": { + "create": "Erstellen" + }, + "typeview": { + "change": "Sprite tauschen", + "create": "On Create", + "depth": "Ebene:", + "destroy": "On Destroy", + "done": "Fertig", + "draw": "Draw", + "learnAboutTypes": "Lernen Sie Types zu programmieren", + "name": "Name:", + "step": "On Step" + }, + "rooms": { + "create": "Neuer Raum", + "makestarting": "Als Startraum festlegen" + }, + "roombackgrounds": { + "add": "Hintergrund hinzufügen", + "depth": "Ebene:", + "movement": "Bewegungsgeschwindigkeit (X, Y):", + "parallax": "Parallax (X, Y):", + "repeat": "Wiederholen:", + "scale": "Skallieren (X, Y):", + "shift": "Verschieben (X, Y):" + }, + "roomtiles": { + "moveTileLayer": "Auf andere Ebene verschieben", + "show": "Ebene zeigen", + "hide": "Ebene ausblenden", + "findTileset": "Tileset finden" + }, + "roomview": { + "name": "Name:", + "width": "Sicht Breite:", + "height": "Sicht Höhe:", + "events": "Raum Events", + "copies": "Kopien", + "backgrounds": "Hintergründe", + "tiles": "Tiles", + "add": "Hinzufügen", + "none": "Nichts", + "done": "Fertig", + "zoom": "Zoom:", + "grid": "Raster konfigurieren", + "gridoff": "Raster deaktivieren", + "gridsize": "Rastergröße:", + "hotkeysNotice": "Strg = Entfernen, Alt = Kein Raster, Hochstelltaste = Mehrfach", + "hotkeysNoticeMovement": "Strg = Löschen, Hochstelltaste = Auswahl", + "tocenter": "zum Zentrum", + "selectbg": "Tileset auswählen", + "shift": "Sicht verschieben", + "shifttext": "Verschieben um:", + "step": "On Step", + "create": "On Create", + "leave": "On Leave", + "draw": "Draw", + "newdepth": "Neue Ebene:", + "deletecopy": "Kopie {0} löschen", + "deleteCopies": "Kopien löschen", + "shiftCopies": "Kopien verschieben", + "selectAndMove": "Auswählen und bewegen", + "changecopyscale": "Skallierung ändern", + "shiftcopy": "Koordinaten setzen", + "deletetile": "Tile löschen", + "deletetiles": "Tiles löschen ", + "movetilestolayer": "Auf Ebene verschieben", + "shifttiles": "Tiles verschieben", + "findTileset": "" + }, + "notepad": { + "local": "Projekt Notizen", + "global": "Globale Notizen", + "helppages": "Hilfe", + "backToHome": "Zurück zu Doks' Homepage" + }, + "preview": { + "reload": "Neu laden", + "roomRestart": "Raum neu starten", + "openExternal": "Im Browser öffnen", + "getQR": "QR Codes und lokale Server URL" + } } diff --git a/app/data/i18n/Readme.md b/app/data/i18n/Readme.md new file mode 100644 index 000000000..cdc743057 --- /dev/null +++ b/app/data/i18n/Readme.md @@ -0,0 +1,9 @@ +# Translating ct.js + +This folder contains translation files for ct.js. To create a translation, create a new `.json` file and edit its keys. You can use any text editor to translate it, or use [JSONBabel](https://comigo.itch.io/jsonbabel) or other tools to make life easier. JSONBabel is free, doesn't require installation and is made by Comigo (who created ct.js as well). For this exact tool, import files `Comments.json` and `English.json` — you don't need other files to translate ct.js. + +Use the `Debug` translation in ct.js to see which keys are used across the app. + +When you finish your translation, open a pull request to add it to the main repo so it becomes available to everyone. If you are not familiar with GitHub and source control systems in general, you can post your translation file at our [Discord server](https://discord.gg/CggbPkb). + +For translating the docs site (docs.ctjs.rocks), see [this repo](https://github.com/ct-js/docs.ctjs.rocks). diff --git a/app/data/i18n/Romanian.json b/app/data/i18n/Romanian.json index 8fd115249..bcb38815d 100644 --- a/app/data/i18n/Romanian.json +++ b/app/data/i18n/Romanian.json @@ -4,7 +4,6 @@ "native": "Română", "eng": "Romanian" }, - "common": { "add": "Adaugă", "addtonotes": "Adaugă la notițe", @@ -28,7 +27,6 @@ "name": "Nume:", "nametaken": "Acest nume este deja în uz", "newname": "Nume nou:", - "newversion": "# O nouă versiune este disponibilă\n", "no": "Nu", "none": "Nimic", "norooms": "Ai nevoie de cel puțin o cameră pentru a compila aplicația.", @@ -45,9 +43,9 @@ "sort": "Sortează:", "tilelayer": "tile layer", "wrongFormat": "Format de fișier greșit", - "yes": "Da" + "yes": "Da", + "contribute": "" }, - "actionsEditor": { "actions": "Acțiuni", "actionsEditor": "Editor de acțiuni", @@ -103,15 +101,13 @@ "browse": "Navighează", "latest": "Proiecte recente", "twitter": "Pagina de Twitter", - "discord": "Comunitatea pe Discord" + "discord": "Comunitatea pe Discord", + "loadingProject": "", + "loadingProjectError": "", + "unableToWriteToFolders": "" }, "licensepanel": { - "tldr": [ - "Tu deții bunurile, proiectele și catmod-urile tale.", - "Poți folosi aplicația în scop comercial (și în alte scopuri);", - "Nu ai dreptul să modifici ct.js în moduri care nu au fost prevăzute de autor;", - "Nu oferim garanții și nu suntem responsabili pentru orice pagubă." - ] + "ctjslicense": "" }, "menu": { "ctIDE": "ct.IDE", @@ -135,7 +131,15 @@ "themeNight": "Întunecată", "types": "Tipuri", "zipExport": "Exportă .zip", - "zipProject": "Împachetază proiectul în .zip" + "zipProject": "Împachetază proiectul în .zip", + "codeFontDefault": "", + "codeFontOldSchool": "", + "codeFontSystem": "", + "codeFontCustom": "", + "newFont": "", + "codeFont": "", + "codeLigatures": "", + "codeDense": "" }, "settings": { "actions": "Acțiuni și metode de introducere", @@ -149,24 +153,20 @@ "minifyhtmlcss": "Comprimă HTML și CSS", "minifyjs": "Comprimă JavaScript și convertește în ES5 (lent; folosește pentru lansări)", "pixelatedrender": "Dezactivează netezirea imaginii aici și în proiectul exportat (conservă pixelii clari)", - "preloader": "Preloader", "renderoptions": "Opțiuni de randare", "settings": "Setările proiectului", "site": "Pagină principală:", "title": "Nume:", "version": "Versiune:", "versionpostfix": "Postfix:", - "preloaders": { - "circular": "Circular", - "bar": "Bară de progres", - "no": "Fară preloader" - }, "scripts": { "addNew": "Adaugă un nou script", "deleteScript": "Șterge script-ul", "header": "Script-uri", "newScriptComment": "Folosește script-uri pentru a defini funcții frecvente și pentru a importa biblioteci mici" - } + }, + "highDensity": "", + "maxFPS": "" }, "modules": { "author": "Autorul acestui catmod", @@ -179,8 +179,6 @@ "logs": "Jurnalul schimbărilor", "methods": "Metode", "parameters": "Parametri", - "nomethods": "Acest modul nu are propriile metode.", - "noparameters": "Acest modul nu are proprii parametri.", "logs2": "Jurnalul schimbărilor", "settings": "Setări" }, @@ -221,7 +219,8 @@ "closeShape": "Închide forma", "addPoint": "Adaugă un punct", "moveCenter": "Mută axa", - "movePoint": "Mută punctul" + "movePoint": "Mută punctul", + "symmetryTool": "Instrument de simetrie" }, "sounds": { "create": "Crează" @@ -264,7 +263,7 @@ "stroke": "Contur", "strokecolor": "Culoarea conturului:", "strokeweight": "Greutatea liniei:", - "testtext" : "Test text 0123 +", + "testtext": "Test text 0123 +", "textWrap": "Word wrap", "textWrapWidth": "Lățime maximă:" }, @@ -347,7 +346,8 @@ "deletetile": "Șterge un tile", "deletetiles": "Șterge tile-urile", "movetilestolayer": "Mută în layer", - "shifttiles": "Deplasează tile-urile" + "shifttiles": "Deplasează tile-urile", + "findTileset": "" }, "notepad": { "local": "Carnețelul Proiectului", @@ -361,4 +361,4 @@ "openExternal": "Deschide în browser", "getQR": "Coduri QR și URL-ul server-ului local" } -} +} \ No newline at end of file diff --git a/app/data/i18n/Russian.json b/app/data/i18n/Russian.json index ddea1ef88..676a4d525 100644 --- a/app/data/i18n/Russian.json +++ b/app/data/i18n/Russian.json @@ -4,7 +4,6 @@ "native": "Русский", "eng": "Russian" }, - "common": { "add": "Добавить", "addtonotes": "Добавить в заметки", @@ -29,7 +28,6 @@ "name": "Название:", "nametaken": "Это имя уже занято", "newname": "Новое имя:", - "newversion": "# Доступна новая версия\n", "no": "Нет", "none": "Ничего", "norooms": "Как бы это ни было печально, вам необходима как минимум одна комната для экспорта :)", @@ -48,7 +46,6 @@ "wrongFormat": "Неверный формат файла", "yes": "Да" }, - "actionsEditor": { "actions": "Действия", "actionsEditor": "Редактор действий", @@ -105,7 +102,9 @@ "browse": "Обзор…", "latest": "Последние проекты", "twitter": "Канал в Twitter", - "discord": "Сообщество в Discord" + "discord": "Сообщество в Discord", + "loadingProjectError": "Не удаётся открыть проект из-за следующей ошибки:", + "unableToWriteToFolders": "Ct.js не удалось найти подходящее место для проектов! Убедитесь, что папка ct.js находится в каталоге, доступном для чтения." }, "licensepanel": { "ctjslicense": "Лицензия Ct.js (MIT)" @@ -113,7 +112,7 @@ "menu": { "ctIDE": "ct.IDE", "exportDesktop": "Экспортировать для ПК", - "texture": "Графика", + "texture": "Текстуры", "launch": "Скомпилировать и запустить", "license": "Лицензия", "min": "Переключить полноэкранный режим", @@ -132,7 +131,16 @@ "themeNight": "Тёмная", "types": "Типы", "zipExport": "Экспорт в .zip", - "zipProject": "Упаковать проект в .zip" + "zipProject": "Упаковать проект в .zip", + "codeFontDefault": "По умолчанию (Iosevka Light)", + "codeFontOldSchool": "Старый-добрый", + "codeFontSystem": "Системный", + "codeFontCustom": "Пользовательский…", + "newFont": "Новый шрифт:", + "codeFont": "Шрифт для кода", + "codeLigatures": "Лигатуры", + "codeDense": "Меньшая высота линии", + "openIncludeFolder": "Открыть папку include" }, "settings": { "actions": "Действия и методы ввода", @@ -148,18 +156,12 @@ "minifyhtmlcss": "Сжать HTML и CSS", "minifyjs": "Сжать JavaScript и преобразовать в ES5 (медленная операция, используйте для релиза)", "pixelatedrender": "Здесь и в проекте отключать сглаживание (сохранять пиксели)", - "preloader": "Прелоадер", "renderoptions": "Настройки графики", "settings": "Настройки проекта", "site": "Сайт автора:", "title": "Название:", "version": "Версия:", "versionpostfix": "Постфикс:", - "preloaders": { - "circular": "Спиннер", - "bar": "Полоса загрузки", - "no": "Нет прелоадера" - }, "scripts": { "addNew": "Добавить новый скрипт", "deleteScript": "Удалить этот скрипт", @@ -175,8 +177,6 @@ "help": "Документация", "methods": "Методы", "parameters": "Параметры", - "nomethods": "Нет собственных метов", - "noparameters": "Нет собственных параметров", "info": "Инфо", "license": "Лицензия", "logs": "Ченджлог", @@ -204,7 +204,7 @@ "rows": "Строк:", "setcenter": "По центру", "speed": "Скорость превью:", - "tiled": "Повторяющийся тайл?", + "tiled": "Использовать как фон?", "replacetexture": "Заменить…", "corrupted": "Файл изображения повреждён или отсутствует! Невозможно открыть спрайт.", "showmask": "Показать маску", @@ -220,7 +220,8 @@ "addPoint": "Добавить точку", "moveCenter": "Переместить ось вращения", "movePoint": "Переместить точку", - "reimport": "Обновить" + "reimport": "Обновить", + "symmetryTool": "Симметрия" }, "sounds": { "create": "Создать" @@ -263,7 +264,7 @@ "stroke": "Обводка", "strokecolor": "Цвет обводки", "strokeweight": "Толщина обводки:", - "testtext" : "Тест Test 0123 +", + "testtext": "Тест Test 0123 +", "textWrap": "Перенос текста", "textWrapWidth": "Позиция для переноса:" }, @@ -349,7 +350,7 @@ "movetilestolayer": "Переместить в другой слой", "shifttiles": "Сместить плитки" }, - "notepad" : { + "notepad": { "local": "Блокнот проекта", "global": "Общий блокнот", "helppages": "Справка", @@ -361,4 +362,4 @@ "openExternal": "Открыть в браузере", "getQR": "QR-коды и адрес локального сервера" } -} +} \ No newline at end of file diff --git a/app/data/i18n/Spanish.json b/app/data/i18n/Spanish.json index 88da0ace0..f827446fd 100644 --- a/app/data/i18n/Spanish.json +++ b/app/data/i18n/Spanish.json @@ -4,7 +4,6 @@ "native": "Spanish", "eng": "Spanish" }, - "common": { "add": "Añadir", "addtonotes": "Agregar a notas", @@ -28,7 +27,6 @@ "name": "Nombre:", "nametaken": "Este nombre ya ha sido tomado", "newname": "Nuevo nombre:", - "newversion": "# Nueva versión disponible\n", "no": "No", "none": "None", "norooms": "You need at least one room to compile your app.", @@ -45,9 +43,9 @@ "sort": "Ordenar:", "tilelayer": "capa de baldosas", "wrongFormat": "Formato de archivo incorrecto", - "yes": "Si" + "yes": "Si", + "contribute": "" }, - "actionsEditor": { "actions": "Acciones", "actionsEditor": "Editor de acciones", @@ -103,15 +101,13 @@ "browse": "Vistazo", "latest": "Últimos proyectos", "twitter": "Canal de Twitter", - "discord": "Comunidad de Discord" + "discord": "Comunidad de Discord", + "loadingProject": "", + "loadingProjectError": "", + "unableToWriteToFolders": "" }, "licensepanel": { - "tldr": [ - "Usted es dueño de sus activos, proyectos, catmods;", - "Puede usar la aplicación para uso comercial (y otros usos también);", - "No debe modificar los ct.js de ninguna manera que no haya sido diseñada por el autor;", - "No damos ninguna garantía y no somos responsables de ningún daño." - ] + "ctjslicense": "" }, "menu": { "ctIDE": "ct.IDE", @@ -135,7 +131,15 @@ "themeNight": "Dark", "types": "Tipos", "zipExport": "Exportar a .zip", - "zipProject": "Paquete de proyecto a .zip" + "zipProject": "Paquete de proyecto a .zip", + "codeFontDefault": "", + "codeFontOldSchool": "", + "codeFontSystem": "", + "codeFontCustom": "", + "newFont": "", + "codeFont": "", + "codeLigatures": "", + "codeDense": "" }, "settings": { "actions": "Acciones y métodos de entrada", @@ -149,24 +153,20 @@ "minifyhtmlcss": "Comprimir HTML y CSS", "minifyjs": "Comprima JavaScript y conviértalo a ES5 (lento; uso para versiones)", "pixelatedrender": "Deshabilite el suavizado de imagen aquí y en el proyecto exportado (conserve píxeles nítidos)", - "preloader": "Preloader", "renderoptions": "Opciones de render", "settings": "Configuración del proyecto", "site": "Página principal:", "title": "Nombre:", "version": "Version:", "versionpostfix": "Sufijo:", - "preloaders": { - "circular": "Circular", - "bar": "Barra de progreso", - "no": "Sin precargador" - }, "scripts": { "addNew": "Agregar un nuevo script", "deleteScript": "Eliminar el script", "header": "Scripts", "newScriptComment": "Use scripts para definir funciones frecuentes e importar pequeñas bibliotecas" - } + }, + "highDensity": "", + "maxFPS": "" }, "modules": { "author": "Autor de este catmod", @@ -179,8 +179,6 @@ "logs": "Changelog", "methods": "Metodos", "parameters": "Parametros", - "nomethods": "Este módulo no tiene sus propios métodos.", - "noparameters": "Este módulo no tiene sus propios parámetros.", "logs2": "Changelog", "settings": "Configuraciones" }, @@ -221,7 +219,8 @@ "closeShape": "Cerrar la forma", "addPoint": "Agrega un punto", "moveCenter": "Mover eje", - "movePoint": "Mueve este punto" + "movePoint": "Mueve este punto", + "symmetryTool": "Herramienta de simetría" }, "sounds": { "create": "Crear" @@ -264,7 +263,7 @@ "stroke": "Trazo", "strokecolor": "Color del trazo:", "strokeweight": "Grosor de línea:", - "testtext" : "Texto de prueba 0123 +", + "testtext": "Texto de prueba 0123 +", "textWrap": "Ajuste de línea", "textWrapWidth": "Anchura máxima:" }, @@ -347,7 +346,8 @@ "deletetile": "Eliminar un tile", "deletetiles": "Eliminar tiles", "movetilestolayer": "Mover a capa", - "shifttiles": "Cambiar tiles" + "shifttiles": "Cambiar tiles", + "findTileset": "" }, "notepad": { "local": "Bloc de notas del proyecto", diff --git a/app/package-lock.json b/app/package-lock.json index c26bc397b..ab5a3e9a7 100644 --- a/app/package-lock.json +++ b/app/package-lock.json @@ -1,6 +1,6 @@ { "name": "ctjs", - "version": "1.0.2", + "version": "1.1.0", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -1167,6 +1167,11 @@ "resolved": "https://registry.npmjs.org/he/-/he-1.1.1.tgz", "integrity": "sha1-k0EP0hsAlzUVH4howvJx80J+I/0=" }, + "highlight.js": { + "version": "9.15.10", + "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-9.15.10.tgz", + "integrity": "sha512-RoV7OkQm0T3os3Dd2VHLNMoaoDVx77Wygln3n9l5YV172XonWG6rgQD3XnF/BuFFZw9A0TJgmMSO8FEWQgvcXw==" + }, "html-minifier": { "version": "3.5.19", "resolved": "https://registry.npmjs.org/html-minifier/-/html-minifier-3.5.19.tgz", @@ -1478,9 +1483,9 @@ } }, "maxrects-packer": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/maxrects-packer/-/maxrects-packer-1.2.0.tgz", - "integrity": "sha1-fDrl/pBtiI9rOfzzdeyrsul7Cmk=" + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/maxrects-packer/-/maxrects-packer-2.5.0.tgz", + "integrity": "sha512-5c7dEU4CBqBzttjm0OThRwGnIzmHrpZIjRHRqWYk4ltJahoU3eXOeEDxafOoHT1Cp0sy2tEZFSjwi08Wh5odYw==" }, "mdurl": { "version": "1.0.1", diff --git a/app/package.json b/app/package.json index 4ab23e29d..dc9a433ad 100644 --- a/app/package.json +++ b/app/package.json @@ -2,7 +2,7 @@ "main": "index.html", "name": "ctjs", "description": "ctjs", - "version": "1.0.2", + "version": "1.1.0", "homepage": "https://ctjs.rocks/", "license": "MIT", "user-agent": "ct.js game engine %name/%ver (%osinfo) NW.js/%nwver AppleWebkit/%webkit_ver Chromium/%chromium_ver", @@ -33,6 +33,7 @@ "webkit": { "plugin": false }, + "chromium-args": "--force-color-profile=srgb --disable-features=ColorCorrectRendering", "webview": { "partitions": [ { @@ -49,9 +50,10 @@ "fs-extra": "^7.0.0", "fuse.js": "^3.2.1", "google-closure-compiler-js": "^20180610.0.0", + "highlight.js": "^9.15.10", "html-minifier": "^3.5.19", "markdown-it": "3.1.0", - "maxrects-packer": "^1.2.0", + "maxrects-packer": "^2.5.0", "node-static": "^0.7.10", "nw-builder": "^3.5.7", "pixi.js": "^5.1.2", diff --git a/comigojiChangelog.js b/comigojiChangelog.js new file mode 100644 index 000000000..2e0c74df2 --- /dev/null +++ b/comigojiChangelog.js @@ -0,0 +1,78 @@ +const gitCommand = 'git log --max-count=1 --tags --simplify-by-decoration --pretty="format:%cI"'; +const {exec} = require('child_process'); + +const miscEmojis = [ + '😱', '🙀', '👻', '🤖', '👾', '👽', '😜', '👀', '✌️', '🦄', '🐉', '🌝', '🌚', '🌻', '☄️', '🎲', '🎁', '😺' +]; + +module.exports = new Promise((resolve, reject) => { + exec(gitCommand, function (err, stdout, stderr) { + if (err) { + reject(err); + return; + } + if (stderr) { + reject(new Error(stderr)); + return; + } + const since = new Date(stdout.trim()); + resolve({ + repos: [{ + since, + repo: './', + branch: 'develop' + }, { + since, + repo: './../docs.ctjs.rocks', + branch: 'master', + forceCategory: 'docs', + forceCategoryStrip: /^:(books|pencil|pencil2|memo):/ + }, { + since, + repo: './../ctjs-site', + branch: 'master', + forceCategory: 'website' + }], + categories: { + rollback: { + pattern: /^:(roller_coaster|rewind):/, + header: '### 🎢 Rollbacked' + }, + feature: { + pattern: /^:(rainbow|sparkles):/, + header: '### ✨ New Features' + }, + improvement: { + pattern: /^:(zap|wrench):/, + header: '### ⚡️ General Improvements' + }, + bug: { + pattern: /^:bug:/, + header: '### 🐛 Bug Fixes' + }, + assets: { + pattern: /^:(briefcase|bento):/, + header: '### 🍱 Demos and Stuff' + }, + docs: { + pattern: /^:(books|pencil|pencil2|memo):/, + header: '### 📝 Docs' + }, + website: { + header: '### 🌐 Website' + }, + default: { + header: `### ${miscEmojis[Math.floor(Math.random() * miscEmojis.length)]} Misc` + }, + ignore: { + pattern: /^:(construction|doughnut|rocket|bookmark):/, + skip: true + }, + merges: { + pattern: 'Merge pull request #', + skip: true + } + } + }); + }); +}); diff --git a/docs b/docs index 13d9efbea..9212e94a6 160000 --- a/docs +++ b/docs @@ -1 +1 @@ -Subproject commit 13d9efbeadc3a1d3ddf981a813bf78528835aba5 +Subproject commit 9212e94a6702fca64c6226a46315fdb391d04f79 diff --git a/gulpfile.js b/gulpfile.js index 2fbe67f8c..6c0c6acff 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -78,7 +78,8 @@ const compileStylus = () => gulp.src('./src/styl/theme*.styl') .pipe(sourcemaps.init()) .pipe(stylus({ - compress: true + compress: true, + 'include css': true })) .pipe(sourcemaps.write()) .pipe(gulp.dest('./app/data/')); diff --git a/package-lock.json b/package-lock.json index 1ccb3e488..5fcc2e511 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "ctjsbuildenvironment", - "version": "1.0.2", + "version": "1.1.0", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 16756c2a4..eafed9686 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ctjsbuildenvironment", - "version": "1.0.2", + "version": "1.1.0", "description": "", "directories": { "doc": "docs" diff --git a/src/examples/yarn.ict b/src/examples/yarn.ict new file mode 100644 index 000000000..c1eb41fd7 --- /dev/null +++ b/src/examples/yarn.ict @@ -0,0 +1,411 @@ +{ + "ctjsVersion": "1.0.2", + "notes": "There is a number of interesting places to start learning the demo:\n\n— rooms' OnCreate events\n— Settings > Scripts > storyEngine\n— OptionButton and NextButton types, as they advance the story by player's interactions.", + "libs": { + "place": { + "gridX": 512, + "gridY": 512 + }, + "fittoscreen": { + "mode": "scaleFit" + }, + "mouse": {}, + "keyboard": {}, + "keyboard.polyfill": {}, + "sound.howler": {}, + "akatemplate": { + "csscss": "body {\n background: #fff;\n}" + }, + "yarn": { + "skipEmpty": true, + "magic": true + }, + "tween": {} + }, + "textures": [ + { + "name": "CatThoughtful", + "untill": 0, + "grid": [ + 1, + 1 + ], + "axis": [ + 396, + 462 + ], + "marginx": 0, + "marginy": 0, + "imgWidth": 793, + "imgHeight": 924, + "width": 793, + "height": 924, + "offx": 0, + "offy": 0, + "origname": "i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png", + "source": "/home/comigo/Рабочий стол/CatThoughtful.png", + "shape": "rect", + "left": 396, + "right": 397, + "top": 462, + "bottom": 462, + "uid": "5aabca45-bbbd-4792-b3a9-ba79bd4a66fd", + "lastmod": 1569837312550 + }, + { + "name": "CatNormal", + "untill": 0, + "grid": [ + 1, + 1 + ], + "axis": [ + 396, + 462 + ], + "marginx": 0, + "marginy": 0, + "imgWidth": 793, + "imgHeight": 924, + "width": 793, + "height": 924, + "offx": 0, + "offy": 0, + "origname": "iec75835b-2afd-4f96-9373-804b4f80a84d.png", + "source": "/home/comigo/Рабочий стол/CatNormal.png", + "shape": "rect", + "left": 396, + "right": 397, + "top": 462, + "bottom": 462, + "uid": "ec75835b-2afd-4f96-9373-804b4f80a84d", + "lastmod": 1569837308602 + }, + { + "name": "CatHappy", + "untill": 0, + "grid": [ + 1, + 1 + ], + "axis": [ + 396, + 462 + ], + "marginx": 0, + "marginy": 0, + "imgWidth": 793, + "imgHeight": 924, + "width": 793, + "height": 924, + "offx": 0, + "offy": 0, + "origname": "i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png", + "source": "/home/comigo/Рабочий стол/CatHappy.png", + "shape": "rect", + "left": 396, + "right": 397, + "top": 462, + "bottom": 462, + "uid": "4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835", + "lastmod": 1569837304762 + }, + { + "name": "Button", + "untill": 0, + "grid": [ + 1, + 1 + ], + "axis": [ + 512, + 50 + ], + "marginx": 0, + "marginy": 0, + "imgWidth": 1024, + "imgHeight": 100, + "width": 1024, + "height": 100, + "offx": 0, + "offy": 0, + "origname": "ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png", + "source": "/home/comigo/Рабочий стол/Button.png", + "shape": "rect", + "left": 512, + "right": 512, + "top": 50, + "bottom": 50, + "uid": "e0cbccef-93ee-4c8a-ab19-4fcef639963c", + "lastmod": 1569837505628 + }, + { + "name": "TheGirl", + "untill": 0, + "grid": [ + 1, + 1 + ], + "axis": [ + 173, + 800 + ], + "marginx": 0, + "marginy": 0, + "imgWidth": 346, + "imgHeight": 800, + "width": 346, + "height": 800, + "offx": 0, + "offy": 0, + "origname": "ibc65f552-4e0c-407e-aee0-9dedd834b727.png", + "source": "C:\\Users\\Master\\Desktop\\TheGirl.png", + "shape": "rect", + "left": 173, + "right": 173, + "top": 800, + "bottom": 0, + "uid": "bc65f552-4e0c-407e-aee0-9dedd834b727", + "lastmod": 1570088487141 + } + ], + "skeletons": [], + "types": [ + { + "name": "TheCat", + "depth": 0, + "oncreate": "", + "onstep": "this.move();", + "ondraw": "", + "ondestroy": "", + "uid": "9e7aec96-1ad3-4679-a248-01180284e78e", + "texture": "ec75835b-2afd-4f96-9373-804b4f80a84d", + "extends": {}, + "lastmod": 1569837324744 + }, + { + "name": "OptionButton", + "depth": 0, + "oncreate": "this.text = new PIXI.Text(this.option, {\n fill: 0x446ADB,\n fontWeight: 600,\n fontSize: 32,\n wordWrap: true,\n wordWrapWidth: 900,\n align: 'center'\n});\nthis.text.anchor.x = this.text.anchor.y = 0.5;\nthis.addChild(this.text);\n\nthis.scale.x = this.scale.y = 0;\nct.tween.add({\n obj: this.scale,\n fields: {\n x: 1,\n y: 1\n },\n duration: 350,\n curve: ct.tween.easeOutQuad\n});\n ", + "onstep": "if (ct.mouse.hovers(this)) {\n if (ct.mouse.pressed) {\n ct.room.story.say(this.option);\n }\n}", + "ondraw": "", + "ondestroy": "", + "uid": "cf5c44b2-f55a-4e18-a941-f7cdf5aecd0f", + "texture": "e0cbccef-93ee-4c8a-ab19-4fcef639963c", + "extends": {}, + "lastmod": 1570008110224 + }, + { + "name": "NextButton", + "depth": 0, + "oncreate": "this.text = new PIXI.Text(this.option, {\n fill: 0x446ADB,\n fontWeight: 600,\n fontSize: 32,\n wordWrap: true,\n wordWrapWidth: 900,\n align: 'center'\n});\nthis.text.anchor.x = this.text.anchor.y = 0.5;\nthis.addChild(this.text);\n\nthis.scale.x = this.scale.y = 0;\nct.tween.add({\n obj: this.scale,\n fields: {\n x: 1,\n y: 1\n },\n duration: 350,\n curve: ct.tween.easeOutQuad\n});\n ", + "onstep": "if (ct.mouse.hovers(this)) {\n if (ct.mouse.pressed) {\n ct.room.story.next();\n this.kill = true;\n }\n}", + "ondraw": "", + "ondestroy": "", + "uid": "4340a6a4-65fa-4bcf-b950-38716097f29e", + "texture": "e0cbccef-93ee-4c8a-ab19-4fcef639963c", + "extends": {}, + "lastmod": 1570008068600 + }, + { + "name": "Blurb", + "depth": 0, + "oncreate": "this.text = new PIXI.Text(this.blurb, {\n fill: this.blurbColor || 0x446ADB,\n fontSize: 32,\n wordWrap: true,\n wordWrapWidth: this.blurbWidth || 1024\n});\nthis.addChild(this.text);\nthis.alpha = 0;\nthis.y += 50;\n\nct.tween.add({\n obj: this,\n fields: {\n y: this.y - 50,\n alpha: 1\n },\n duration: 500,\n curve: ct.tween.easeOutQuad\n})\n.then(() => {\n ct.room.story.next();\n});", + "onstep": "this.move();", + "ondraw": "", + "ondestroy": "", + "uid": "04a0aea0-f448-4920-97ad-f98906ac0d7c", + "texture": -1, + "extends": {}, + "lastmod": 1570089644788 + }, + { + "name": "RestartButton", + "depth": 0, + "oncreate": "this.text = new PIXI.Text('Restart', {\n fill: 0x446ADB,\n fontWeight: 600,\n fontSize: 32,\n wordWrap: true,\n wordWrapWidth: 900,\n align: 'center'\n});\nthis.text.anchor.x = this.text.anchor.y = 0.5;\nthis.addChild(this.text);\n\nthis.scale.x = this.scale.y = 0;\nct.tween.add({\n obj: this.scale,\n fields: {\n x: 1,\n y: 1\n },\n duration: 350,\n curve: ct.tween.easeOutQuad\n});\n ", + "onstep": "if (ct.mouse.hovers(this)) {\n if (ct.mouse.pressed) {\n ct.rooms.switch(ct.room.name);\n this.kill = true;\n }\n}", + "ondraw": "", + "ondestroy": "", + "uid": "9a5d6ecd-82b4-4b26-827b-08904fbaf962", + "texture": "e0cbccef-93ee-4c8a-ab19-4fcef639963c", + "extends": {}, + "lastmod": 1570008107016 + }, + { + "name": "TheGirl", + "depth": 0, + "oncreate": "ct.tween.add({\n obj: this,\n fields: {\n x: ct.viewWidth * 0.15\n },\n duration: 500,\n curve: ct.tween.easeOutQuad\n});\n\nthis.scale.x = this.scale.y = 1.2;", + "onstep": "this.move();", + "ondraw": "", + "ondestroy": "", + "uid": "3c91a07b-0497-4623-a244-071a4e1951d8", + "texture": "bc65f552-4e0c-407e-aee0-9dedd834b727", + "extends": {}, + "lastmod": 1570089992509 + } + ], + "sounds": [ + { + "name": "Hehe", + "uid": "0bd4a1eb-b5f1-4047-a8dd-56feca282803", + "origname": "s0bd4a1eb-b5f1-4047-a8dd-56feca282803.mp3", + "lastmod": 1570005238168 + } + ], + "styles": [], + "rooms": [ + { + "name": "Main", + "oncreate": "var latestBlurb; // we will need it to accurately position text lines\n\nct.yarn.openFromFile('theStory.json?q=' + Math.random())\n.then(story => {\n this.story = story;\n storyEngine(story); // see it in the Settings tab -> Scripts\n});\n\n\nthis.nodeTitle = new PIXI.Text('Loading the awesomeness…', {\n fill: 0x446ADB,\n fontSize: 24,\n wordWrap: true,\n wordWrapWidth: 1024\n});\nthis.nodeTitle.x = 100;\nthis.nodeTitle.y = 50;\nthis.addChild(this.nodeTitle);", + "onstep": "", + "ondraw": "", + "onleave": "", + "width": 1920, + "height": 1080, + "backgrounds": [], + "copies": [ + { + "x": 1536, + "y": 576, + "uid": "9e7aec96-1ad3-4679-a248-01180284e78e", + "tx": 0.75, + "ty": 0.75 + } + ], + "tiles": [ + { + "depth": -10, + "tiles": [] + } + ], + "uid": "d21d2804-d690-4c65-9657-7a1486b7f1d9", + "thumbnail": "7a1486b7f1d9", + "gridX": 64, + "gridY": 64, + "lastmod": 1570007451105 + }, + { + "name": "Micro", + "oncreate": "var latestBlurb; // we will need it to accurately position text lines\n\nct.yarn.openFromFile('micro.json?q=' + Math.random())\n.then(story => {\n this.story = story;\n storyEngine(story); // see it in the Settings tab -> Scripts\n});\n\n\nthis.nodeTitle = new PIXI.Text('Loading the awesomeness…', {\n fill: 0x446ADB,\n fontSize: 24,\n wordWrap: true,\n wordWrapWidth: 1024\n});\nthis.nodeTitle.x = 100;\nthis.nodeTitle.y = 50;\nthis.addChild(this.nodeTitle);", + "onstep": "", + "ondraw": "", + "onleave": "", + "width": 1920, + "height": 1080, + "backgrounds": [], + "copies": [ + { + "x": 1536, + "y": 448, + "uid": "9e7aec96-1ad3-4679-a248-01180284e78e", + "tx": 0.75, + "ty": 0.75 + } + ], + "tiles": [ + { + "depth": -10, + "tiles": [] + } + ], + "uid": "cb9565fc-6666-4f0c-bc6c-b49f813ea9ce", + "thumbnail": "b49f813ea9ce", + "gridX": 64, + "gridY": 64, + "lastmod": 1570007519025 + }, + { + "name": "Stop", + "oncreate": "var latestBlurb; // we will need it to accurately position text lines\n\nct.yarn.openFromFile('stop.json?q=' + Math.random())\n.then(story => {\n this.story = story;\n storyEngine(story); // see it in the Settings tab -> Scripts\n});\n\n\nthis.nodeTitle = new PIXI.Text('Loading the awesomeness…', {\n fill: 0x446ADB,\n fontSize: 24,\n wordWrap: true,\n wordWrapWidth: 1024\n});\nthis.nodeTitle.x = 100;\nthis.nodeTitle.y = 50;\nthis.addChild(this.nodeTitle);", + "onstep": "", + "ondraw": "", + "onleave": "", + "width": 1920, + "height": 1080, + "backgrounds": [], + "copies": [ + { + "x": 1536, + "y": 448, + "uid": "9e7aec96-1ad3-4679-a248-01180284e78e", + "tx": 0.75, + "ty": 0.75 + } + ], + "tiles": [ + { + "depth": -10, + "tiles": [] + } + ], + "uid": "95f73a99-6402-4848-81a7-d96488130d15", + "thumbnail": "d96488130d15", + "gridX": 64, + "gridY": 64, + "lastmod": 1570013323128 + }, + { + "name": "Wait", + "oncreate": "var latestBlurb; // we will need it to accurately position text lines\n\nct.yarn.openFromFile('wait.json?q=' + Math.random())\n.then(story => {\n this.story = story;\n storyEngine(story); // see it in the Settings tab -> Scripts\n});\n\n\nthis.nodeTitle = new PIXI.Text('Loading the awesomeness…', {\n fill: 0x446ADB,\n fontSize: 24,\n wordWrap: true,\n wordWrapWidth: 1024\n});\nthis.nodeTitle.x = 100;\nthis.nodeTitle.y = 50;\nthis.addChild(this.nodeTitle);", + "onstep": "", + "ondraw": "", + "onleave": "", + "width": 1920, + "height": 1080, + "backgrounds": [], + "copies": [ + { + "x": 1536, + "y": 448, + "uid": "9e7aec96-1ad3-4679-a248-01180284e78e", + "tx": 0.75, + "ty": 0.75 + } + ], + "tiles": [ + { + "depth": -10, + "tiles": [] + } + ], + "uid": "48b25b49-58b8-44ee-b4c5-cc6b9ea24c38", + "thumbnail": "cc6b9ea24c38", + "gridX": 64, + "gridY": 64, + "lastmod": 1570056924685 + } + ], + "actions": [], + "starting": 0, + "settings": { + "minifyhtmlcss": false, + "minifyjs": false, + "fps": 30, + "version": [ + 0, + 0, + 0 + ], + "versionPostfix": "", + "export": { + "windows64": true, + "windows32": true, + "linux64": true, + "linux32": true, + "mac64": true, + "debug": false + } + }, + "scripts": [ + { + "name": "storyEngine", + "code": "var storyEngine = function (story) {\n var latestBlurb; // used to position lines nicely, see below at story.on('options')\n var spacing = true;\n\n story.on('newnode', () => {\n // Clear the previous buttons and blurbs\n for (const button of ct.types.list['NextButton']) {\n button.kill = true;\n }\n for (const button of ct.types.list['OptionButton']) {\n button.kill = true;\n }\n for (const blurb of ct.types.list['Blurb']) {\n blurb.kill = true;\n }\n // Update the node's title\n ct.room.nodeTitle.text = story.title;\n });\n\n story.on('text', text => {\n // Yarn does not support single dialogue options, but we will fake\n // them to add a better feeling of authority\n if (story.character === 'Player') {\n // Clear the previous buttons\n for (const button of ct.types.list['NextButton']) {\n button.kill = true;\n }\n ct.types.copy('NextButton', ct.viewWidth / 2, ct.viewHeight - 60, {\n option: story.body // it will appear in button's OnCreate event as this.option\n });\n } else {\n let blurbY = 150; // the default blurb location\n // Get the latest blurb's bottom line, if any\n if (latestBlurb && !latestBlurb.kill) {\n blurbY = latestBlurb.y + latestBlurb.text.height + (spacing? 32 : 0);\n }\n if (story.character === 'Girl') {\n latestBlurb = ct.types.copy('Blurb', 500, blurbY, {\n blurb: story.body, // it will appear in Blurb's OnCreate event as this.blurb\n blurbColor: 0xDB449A,\n blurbWidth: 800\n });\n } else {\n // Assume it is the cat's line\n latestBlurb = ct.types.copy('Blurb', 100, blurbY, {\n blurb: story.body // it will appear in Blurb's OnCreate event as this.blurb\n });\n }\n }\n });\n\n story.on('options', options => {\n let buttonY = ct.viewHeight - 60;\n for (const option of options) {\n ct.types.copy('OptionButton', ct.viewWidth / 2, buttonY, {\n option: option // it will appear in button's OnCreate event as this.option\n });\n buttonY -= 120;\n }\n });\n\n story.on('command', command => {\n const cat = ct.types.list['TheCat'][0];\n if (command === 'cat happy') {\n cat.tex = 'CatHappy';\n } else if (command === 'cat thoughtful') {\n cat.tex = 'CatThoughtful';\n } else if (command === 'cat normal') {\n cat.tex = 'CatNormal';\n } else if (command === 'disable spacing') {\n spacing = false;\n } else if (command === 'enable spacing') {\n spacing = true;\n } else if (command === 'a girl walks in') {\n // Create it offscreen. The copy has an animation in its \n // OnCreate code and will roll in \n ct.types.copy('TheGirl', -200, ct.viewHeight);\n } else if (command === 'a girl walks out') {\n const theGirl = ct.types.list['TheGirl'][0];\n ct.tween.add({\n obj: theGirl,\n fields: {\n x: -200\n },\n duration: 500\n }).then(() => {\n theGirl.kill = true;\n });\n } else {\n console.warn(`Unknown command \"${command}\"`);\n }\n story.next();\n });\n\n // The story has enden\n story.on('drained', () => {\n // Clear the previous buttons and blurbs\n for (const button of ct.types.list['NextButton']) {\n button.kill = true;\n }\n for (const button of ct.types.list['OptionButton']) {\n button.kill = true;\n }\n for (const blurb of ct.types.list['Blurb']) {\n blurb.kill = true;\n }\n ct.types.copy('RestartButton', ct.viewWidth / 2, ct.viewHeight - 60);\n });\n \n story.start();\n}" + }, + { + "name": "Background color", + "code": "ct.pixiApp.renderer.backgroundColor = 0xffffff;" + } + ], + "fonts": [], + "startroom": "d21d2804-d690-4c65-9657-7a1486b7f1d9" +} diff --git a/src/examples/yarn/img/i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png b/src/examples/yarn/img/i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png new file mode 100644 index 000000000..0548b4562 Binary files /dev/null and b/src/examples/yarn/img/i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png differ diff --git a/src/examples/yarn/img/i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png_prev.png b/src/examples/yarn/img/i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png_prev.png new file mode 100644 index 000000000..9c9950909 Binary files /dev/null and b/src/examples/yarn/img/i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png_prev.png differ diff --git a/src/examples/yarn/img/i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png_prev@2.png b/src/examples/yarn/img/i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png_prev@2.png new file mode 100644 index 000000000..252341b05 Binary files /dev/null and b/src/examples/yarn/img/i4a04ffe6-c92a-428e-9fe4-5e8d2ce9c835.png_prev@2.png differ diff --git a/src/examples/yarn/img/i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png b/src/examples/yarn/img/i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png new file mode 100644 index 000000000..e5f524917 Binary files /dev/null and b/src/examples/yarn/img/i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png differ diff --git a/src/examples/yarn/img/i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png_prev.png b/src/examples/yarn/img/i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png_prev.png new file mode 100644 index 000000000..7647caae3 Binary files /dev/null and b/src/examples/yarn/img/i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png_prev.png differ diff --git a/src/examples/yarn/img/i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png_prev@2.png b/src/examples/yarn/img/i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png_prev@2.png new file mode 100644 index 000000000..ea57bfd33 Binary files /dev/null and b/src/examples/yarn/img/i5aabca45-bbbd-4792-b3a9-ba79bd4a66fd.png_prev@2.png differ diff --git a/src/examples/yarn/img/ibc65f552-4e0c-407e-aee0-9dedd834b727.png b/src/examples/yarn/img/ibc65f552-4e0c-407e-aee0-9dedd834b727.png new file mode 100644 index 000000000..33b2970cd Binary files /dev/null and b/src/examples/yarn/img/ibc65f552-4e0c-407e-aee0-9dedd834b727.png differ diff --git a/src/examples/yarn/img/ibc65f552-4e0c-407e-aee0-9dedd834b727.png_prev.png b/src/examples/yarn/img/ibc65f552-4e0c-407e-aee0-9dedd834b727.png_prev.png new file mode 100644 index 000000000..f40fa03fd Binary files /dev/null and b/src/examples/yarn/img/ibc65f552-4e0c-407e-aee0-9dedd834b727.png_prev.png differ diff --git a/src/examples/yarn/img/ibc65f552-4e0c-407e-aee0-9dedd834b727.png_prev@2.png b/src/examples/yarn/img/ibc65f552-4e0c-407e-aee0-9dedd834b727.png_prev@2.png new file mode 100644 index 000000000..17a967e28 Binary files /dev/null and b/src/examples/yarn/img/ibc65f552-4e0c-407e-aee0-9dedd834b727.png_prev@2.png differ diff --git a/src/examples/yarn/img/ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png b/src/examples/yarn/img/ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png new file mode 100644 index 000000000..fe459a171 Binary files /dev/null and b/src/examples/yarn/img/ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png differ diff --git a/src/examples/yarn/img/ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png_prev.png b/src/examples/yarn/img/ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png_prev.png new file mode 100644 index 000000000..5d457e814 Binary files /dev/null and b/src/examples/yarn/img/ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png_prev.png differ diff --git a/src/examples/yarn/img/ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png_prev@2.png b/src/examples/yarn/img/ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png_prev@2.png new file mode 100644 index 000000000..598b19b38 Binary files /dev/null and b/src/examples/yarn/img/ie0cbccef-93ee-4c8a-ab19-4fcef639963c.png_prev@2.png differ diff --git a/src/examples/yarn/img/iec75835b-2afd-4f96-9373-804b4f80a84d.png b/src/examples/yarn/img/iec75835b-2afd-4f96-9373-804b4f80a84d.png new file mode 100644 index 000000000..da99ab450 Binary files /dev/null and b/src/examples/yarn/img/iec75835b-2afd-4f96-9373-804b4f80a84d.png differ diff --git a/src/examples/yarn/img/iec75835b-2afd-4f96-9373-804b4f80a84d.png_prev.png b/src/examples/yarn/img/iec75835b-2afd-4f96-9373-804b4f80a84d.png_prev.png new file mode 100644 index 000000000..d82e5f7ce Binary files /dev/null and b/src/examples/yarn/img/iec75835b-2afd-4f96-9373-804b4f80a84d.png_prev.png differ diff --git a/src/examples/yarn/img/iec75835b-2afd-4f96-9373-804b4f80a84d.png_prev@2.png b/src/examples/yarn/img/iec75835b-2afd-4f96-9373-804b4f80a84d.png_prev@2.png new file mode 100644 index 000000000..9bf49dfaf Binary files /dev/null and b/src/examples/yarn/img/iec75835b-2afd-4f96-9373-804b4f80a84d.png_prev@2.png differ diff --git a/src/examples/yarn/img/r7a1486b7f1d9.png b/src/examples/yarn/img/r7a1486b7f1d9.png new file mode 100644 index 000000000..d6513cef2 Binary files /dev/null and b/src/examples/yarn/img/r7a1486b7f1d9.png differ diff --git a/src/examples/yarn/img/rb49f813ea9ce.png b/src/examples/yarn/img/rb49f813ea9ce.png new file mode 100644 index 000000000..d6513cef2 Binary files /dev/null and b/src/examples/yarn/img/rb49f813ea9ce.png differ diff --git a/src/examples/yarn/img/rcc6b9ea24c38.png b/src/examples/yarn/img/rcc6b9ea24c38.png new file mode 100644 index 000000000..9b3409daf Binary files /dev/null and b/src/examples/yarn/img/rcc6b9ea24c38.png differ diff --git a/src/examples/yarn/img/rd96488130d15.png b/src/examples/yarn/img/rd96488130d15.png new file mode 100644 index 000000000..9b3409daf Binary files /dev/null and b/src/examples/yarn/img/rd96488130d15.png differ diff --git a/src/examples/yarn/img/splash.png b/src/examples/yarn/img/splash.png new file mode 100644 index 000000000..9b3409daf Binary files /dev/null and b/src/examples/yarn/img/splash.png differ diff --git a/src/examples/yarn/include/micro.json b/src/examples/yarn/include/micro.json new file mode 100644 index 000000000..0644b6557 --- /dev/null +++ b/src/examples/yarn/include/micro.json @@ -0,0 +1,12 @@ +[ + { + "title": "Start", + "tags": "", + "body": "The beginning\nAnd the end", + "position": { + "x": 815, + "y": 180 + }, + "colorID": 0 + } +] \ No newline at end of file diff --git a/src/examples/yarn/include/stop.json b/src/examples/yarn/include/stop.json new file mode 100644 index 000000000..29c774911 --- /dev/null +++ b/src/examples/yarn/include/stop.json @@ -0,0 +1,12 @@ +[ + { + "title": "Start", + "tags": "", + "body": "A line 1/3\nA line 2/3\n<>\nA line 3/3", + "position": { + "x": 2780, + "y": 1798 + }, + "colorID": 0 + } +] \ No newline at end of file diff --git a/src/examples/yarn/include/theStory.json b/src/examples/yarn/include/theStory.json new file mode 100644 index 000000000..25bba6079 --- /dev/null +++ b/src/examples/yarn/include/theStory.json @@ -0,0 +1,272 @@ +[ + { + "title": "CommandsExample", + "tags": "", + "body": "<< cat normal >>\n\nI use them to change my texture and play sounds!\n\n<< cat happy >>\n<< sound(\"Hehe\")>> \n\nPlayer: Whoa! *O* Anything else??\n\n[[ExtraFunctions]]", + "position": { + "x": 4371, + "y": 2306 + }, + "colorID": 1 + }, + { + "title": "Conditionals", + "tags": "", + "body": "Make your stories data-driven!\n\nYarn has math variables, functions, comparisons and complex conditionals. For the full guide, see https://bit.ly/2p8LI6n\n\n[[Wonderful!|FAQ]]\n[[I want to see it in action.|SeeConditionals]]", + "position": { + "x": 4117, + "y": 4490 + }, + "colorID": 0 + }, + { + "title": "ExportProject", + "tags": "", + "body": "<< cat normal >> \n\nCat: Yarn is available at yarnspinnertool.github.io/YarnEditor/\nCat: Design your dialogue, then open the File menu → Save as JSON.\nPlayer: Done.\n\n[[ImportingToCt]]", + "position": { + "x": 4695, + "y": 879 + }, + "colorID": 0 + }, + { + "title": "Extending", + "tags": "", + "body": "<< cat happy >>\nThat's up to you! You have the power of ct.js, the flexibility of JavaScript and the exploitability of this module.\nYou can split your stories into scenes, load them into ct.js, and then create a room for each one, with nifty backgrounds and decorations. Much like in visual novels! *U*\nYou can use ct.room.story.raw instead of e.g. ct.room.story.text to get the source of a node and get extra variables that you put in the body of your node.\n\nIf you struggle, though, check out the source of this edutational demo!\n\nPlayer: Thanks!\n\n[[FAQ]]", + "position": { + "x": 3576, + "y": 4484 + }, + "colorID": 0 + }, + { + "title": "ExtraFunctions", + "tags": "", + "body": "<< cat normal >>\nYes, there are some extra variables that may help you:\n\nct.room.story.nodes is a map of all the nodes in your story. E.g. ct.room.story.nodes['ExtraFunctions'] will return the current node.\nct.room.story.raw is an object with the unprocessed body and other meta information exported by Yarn.\nct.room.story.startingNode is the name of, well, the starting node.\n\nPlayer: How do I combine it into a working game or dialogue system?\n\n[[TyingTogether]]", + "position": { + "x": 4650, + "y": 2441 + }, + "colorID": 0 + }, + { + "title": "FAQ", + "tags": "", + "body": "<>\n <>\n See? I don't have the default line now.\n <> \n<>\n <>\n Ask me anything. Well, anything that was hardcoded by Comigo.\n<>\n\n[[I'm done|Fin]]\n[[Projects…|FAQProjects]]\n[[Writing stories…|FAQStories]]\n[[More than text…|FAQMore]]", + "position": { + "x": 4689, + "y": 3666 + }, + "colorID": 6 + }, + { + "title": "FormatStory", + "tags": "", + "body": "<< cat normal >>\n\nct.yarn is based on bondage.js and has all its perks and issues. Generally, you can write however you want, but single dialogue options are not supported. There is a workaround, though, as you could already guess! ;) See the demo's source! \n\nPlayer: Oh, ok!\n\n[[FAQ]]", + "position": { + "x": 5359, + "y": 3910 + }, + "colorID": 0 + }, + { + "title": "GettingScene", + "tags": "tag1 tag2", + "body": "<< cat thoughtful >> \n\nThe details of the current node can be read by these variables:\n\nstory.character is the name of the current character. E.g. if you write \"John: Hey there!\" in Yarn, story.character will be \"John\". Names cannot contain spaces! \nstory.body is what I'm saying right now :)\nstory.text is character's name and body combined, in case it comes in handy.\nstory.title is the name of a node. You can view it in the top-left corner there.\nstory.command is the code of the current command, if any.\nstory.tags is an array of strings with tags written at Yarn Editor. Use them however you want!\n\n<>\n\n[[How do you use tags, though?|CommandsExample]]\n[[Are there any special variables?|ExtraFunctions]]", + "position": { + "x": 4659, + "y": 2087 + }, + "colorID": 0 + }, + { + "title": "ImportingToCt", + "tags": "", + "body": "<< cat normal >> \n\nOpen the downloaded JSON file and copy its contents. Now open ct.js. Click the \"Settings\" tab, and create a new script. Write the beginning of a line:\nvar myStory = \nand then paste the JSON file. That's enough, you can save the script and move on.\n\n[[Wait, where do I get this JSON file, again?|ExportProject]]\n[[Got it.|OpeningStory]]", + "position": { + "x": 4692, + "y": 1164 + }, + "colorID": 0 + }, + { + "title": "LoadingFile", + "tags": "", + "body": "<< cat thoughtful >>\n\nYou can use this code to load a story from an external file:\n\nct.yarn.openFromFile('myStory.json')\n.then(story => {\n ct.room.story = story;\n});\n\nJSON files are better placed into your projects folder → 'include' subdirectory.\n\nPlayer: Thanks!\n\n[[FAQ]]", + "position": { + "x": 4956, + "y": 4509 + }, + "colorID": 0 + }, + { + "title": "MultipleFiles", + "tags": "", + "body": "<< cat happy >>\n\nThat's actually easy. Export each one to JSON, create one Script in ct's Settings tab, and give them different variable names. E.g.\nvar detectiveMystery = {/*yarn json goes here*/};\n/*in the other Script*/\nvar bossMonologue = {/* another yarn json */};\n/* and in the other */\nvar iLoveChocolate = {/* here ct bursts into tears and eats all the chocolate */};\n\nAnd so on.\n\nYou can also use files in the `include` folder.\n\n[[Thanks!|FAQ]]\n[[Aaaand how do I use these files?|LoadingFile]]", + "position": { + "x": 5288, + "y": 4380 + }, + "colorID": 0 + }, + { + "title": "NavigatingStory", + "tags": "", + "body": "<< cat happy>>\n\nCat: I will use just \"story\" instead of ct.room.story from now, ok?\n\nPlayer: Of course!\n\n<< cat thoughtful >> \n\nWe should use story in our function calls:\nstory.start() will put us in the beginning of it.\nstory.next() will advance the story. It will pull new speech lines, new options, and load commands, but one thing at a time.\nstory.back() will switch to the previous story node. It works just once, though, like in ye olde MS Paint.\nstory.options is an array of strings with currently available dialogue options, if there are any.\nstory.say(string) will navigate the story further. The string must match with entries from ct.room.story.options.\n\n<< cat normal >> \n\n[[But what about the speech of NPCs and stuff?|GettingScene]]\n[[Can I jump to a specific position in story, by code?|StoryJump]]", + "position": { + "x": 4686, + "y": 1761 + }, + "colorID": 0 + }, + { + "title": "OpeningStory", + "tags": "", + "body": "The JSON file is still a raw product, though. In order to use your story, you should first load it in your game's code. For example, we can write the following to a room's OnCreate code:\nct.room.story = ct.yarn.openStory(myStory);\nBy default, ct.yarn will look for the 'Start' node. If you want to provide another default title, use ct.yarn.openStory(myStory, 'Specific title');\nct.yarn will read your JSON and structure it in a more useful format. You can now use other methods of ct.yarn to navigate your story, search for its nodes and get dialogue options.\n\nPlayer: Mhm…\n\n[[NavigatingStory]]", + "position": { + "x": 4695, + "y": 1455 + }, + "colorID": 0 + }, + { + "title": "SeeConditionals", + "tags": "", + "body": "Then go to FAQ page ;)\n\n<< set $seeConditional = true>> \n\nPlayer: Eh, ok…\n\n[[FAQ]]", + "position": { + "x": 4116, + "y": 4777 + }, + "colorID": 1 + }, + { + "title": "Sources", + "tags": "", + "body": "They are bundled with each fresh ct.js version. Check the ct.js folder > examples > yarn.ict.\n\nPlayer: Thanks!\n\n[[FAQ]]", + "position": { + "x": 3846, + "y": 4491 + }, + "colorID": 0 + }, + { + "title": "Start", + "tags": "", + "body": "<> \nCat: Hello, fellow game developer! You are playing the demo of using Yarn Editor for creating interactive dialogues in ct.js!\nCat: Due to the lack of writing skills of Comigo, it will be a purely educational experience, with no cute girls.\nPlayer: Such wow. I'm in.\n[[WhatIsYarn]]", + "position": { + "x": 4695, + "y": 312 + }, + "colorID": 4 + }, + { + "title": "StoryJump", + "tags": "", + "body": "<< cat happy >> \nYes! All nodes in Yarn are named, and you can use them to instantly jump to a specific node, out of your story's flow.\nThe function is ct.room.story.jump('SomeNode');\n<< cat thoughtful >> \nJust think about its debugging capabilities 👀\nIf you haven't specifically named all your story nodes in Yarn Editor, they all are probably just Node1, Node2, Node3… nothing fancy, really.\n\n<>\n\nPlayer: Ok, I got ya\n\n[[GettingScene]]", + "position": { + "x": 4361, + "y": 1967 + }, + "colorID": 1 + }, + { + "title": "WhatIsYarn", + "tags": "", + "body": "<> \nCat: Yarn Editor is an open-source tool for writing game dialogues.\n<> \nCat: Its license is MIT, much like ct.js, and it means that you can use Yarn Editor in any of your projects, be they commercial or not. For free.\nPlayer: Cool! So, how to use Yarn projects in ct.js?\n[[ExportProject]]", + "position": { + "x": 4699, + "y": 587 + }, + "colorID": 0 + }, + { + "title": "TyingTogether", + "tags": "", + "body": "There are two main ways:\n— by reading and utilizing variables like story.text or story.options,\n— or by listening story's events.\n\nPlayer: Let's see them.\n\n[[ByVariables]]", + "position": { + "x": 4654, + "y": 2711 + }, + "colorID": 0 + }, + { + "title": "ByVariables", + "tags": "", + "body": "<>\nIn the first case, you should check story.command, story.text and story.options.\n\nPlayer: Let's see an example.\n\n<>\n\nvar story = ct.room.story;\n<>\nif (ct.actions.Next.pressed) {\n if (story.text) { /* advance by buttons only when someone is talking */\n story.next();\n if (story.text) {\n /* create new blurbs */\n } else if (story.options) {\n /* create dialogue options */\n } else if (story.command) {\n /* custom logic goes here */\n }\n }\n}\n<>\n\nPlayer: Good, and by events?\n\n[[ByEvents]]", + "position": { + "x": 4650, + "y": 2983 + }, + "colorID": 0 + }, + { + "title": "ByEvents", + "tags": "", + "body": "<>\nIt is a bit simpler as you always execute the needed code:\n<>\n\nstory.on('text', text => {\n<>\n /* Someone said something, let's create a blurb for `text` variable */\n});\nstory.on('options', options => {\n /* we are now presented with dialogue options! We need to create reply buttons… */\n});\nstory.on('command', command => {\n /* custom actions may appear here */\n});\n<>\n\nPlayer: Now I feel immense power in my hands! But I still have questions…\n\n[[FAQ]]", + "position": { + "x": 4673, + "y": 3280 + }, + "colorID": 0 + }, + { + "title": "FAQProjects", + "tags": "", + "body": "Yes?\n\n[[How do I use multiple Yarn projects?|MultipleFiles]]\n[[Scripts are not that handy, especially when updating the story. Other options??|LoadingFile]]", + "position": { + "x": 4959, + "y": 4191 + }, + "colorID": 2 + }, + { + "title": "FAQStories", + "tags": "", + "body": "Yes?\n\n\n[[Any special formatting in the Yarn Editor?|FormatStory]]\n[[Can there be several characters at once?|MultipleCharacters]]", + "position": { + "x": 5428, + "y": 3522 + }, + "colorID": 2 + }, + { + "title": "FAQMore", + "tags": "", + "body": "Yes?\n\n[[This demo is cool! Where are its sources?|Sources]]\n[[What about conditionals and variables?|Conditionals]]\n[[How do I make transitions, effects and stuff?|Extending]]", + "position": { + "x": 3899, + "y": 3989 + }, + "colorID": 2 + }, + { + "title": "Fin", + "tags": "", + "body": "<>\n\nOk. Go make some great games now!\n\n<>", + "position": { + "x": 4678, + "y": 5327 + }, + "colorID": 0 + }, + { + "title": "MultipleCharacters", + "tags": "", + "body": "<>\n<>\n<> \n<>\n<> \n\n<>\nGirl: Kon'nichiwa!\n<>\nGirl: ct no Yarn mojūru wa hijō ni jūnandeari, fukusū no moji no enjin o kijutsu suru no wa hijō ni kantandesu.\n<>\nGirl: Kokode wa, komando o shiyō shite hyōji oyobi shūryō shi,-iro wa hensū story. Kyarakutā o shiyō shite settei shimasu.\n<>\n\nPlayer: ❤️_❤️\n\n<> \n\n<< wait(2000) >> \n\n[[DirtyLies]]\n", + "position": { + "x": 5424, + "y": 3135 + }, + "colorID": 3 + }, + { + "title": "DirtyLies", + "tags": "", + "body": "<> \n\nWell, ok, I lied about cute girls.\n\nPlayer: ❤️_❤️\n\n[[FAQ]]", + "position": { + "x": 5138, + "y": 3129 + }, + "colorID": 3 + } +] \ No newline at end of file diff --git a/src/examples/yarn/include/wait.json b/src/examples/yarn/include/wait.json new file mode 100644 index 000000000..f9751f78a --- /dev/null +++ b/src/examples/yarn/include/wait.json @@ -0,0 +1,12 @@ +[ + { + "title": "Start", + "tags": "", + "body": "First line…\nPause…\n<>\nSecond line…", + "position": { + "x": 477, + "y": 2188 + }, + "colorID": 0 + } +] \ No newline at end of file diff --git a/src/examples/yarn/snd/s0bd4a1eb-b5f1-4047-a8dd-56feca282803.mp3 b/src/examples/yarn/snd/s0bd4a1eb-b5f1-4047-a8dd-56feca282803.mp3 new file mode 100644 index 000000000..5488154b3 Binary files /dev/null and b/src/examples/yarn/snd/s0bd4a1eb-b5f1-4047-a8dd-56feca282803.mp3 differ diff --git a/src/js/aceHelpers.js b/src/js/aceHelpers.js index 00155ea18..7bdfb93cb 100644 --- a/src/js/aceHelpers.js +++ b/src/js/aceHelpers.js @@ -195,7 +195,6 @@ aceEditor.tag = tag; aceEditor.session = aceEditor.getSession(); tag.style.fontSize = localStorage.fontSize + 'px'; - tag.style.fontFamily = localStorage.fontFamily || 'Monaco, Menlo, "Ubuntu Mono", Consolas, source-code-pro, monospace'; aceEditor.session.setMode('ace/mode/' + options.mode || defaultOptions.mode); aceEditor.setOptions({ enableBasicAutocompletion: true, diff --git a/src/node_requires/exporter.js b/src/node_requires/exporter.js index 41b5d2381..88dabc8a5 100644 --- a/src/node_requires/exporter.js +++ b/src/node_requires/exporter.js @@ -75,7 +75,8 @@ const getTextureShape = texture => { if (texture.shape === 'strip') { return { type: 'strip', - points: texture.stripPoints + points: texture.stripPoints, + closedStrip: texture.closedStrip }; } return { @@ -83,33 +84,58 @@ const getTextureShape = texture => { }; }; const packImages = () => { - var blocks = [], - tiledImages = []; - for (let i = 0, li = currentProject.textures.length; i < li; i++) { - if (!currentProject.textures[i].tiled) { - blocks.push({ - data: { - origname: currentProject.textures[i].origname, - g: currentProject.textures[i] - }, - width: currentProject.textures[i].imgWidth+2, - height: currentProject.textures[i].imgHeight+2, - }); + const blocks = []; + const tiledImages = []; + const keys = {}; // a collection of frame names for each texture name + for (const tex of currentProject.textures) { + if (!tex.tiled) { + keys[tex.origname] = []; + for (var yy = 0; yy < tex.grid[1]; yy++) { + for (var xx = 0; xx < tex.grid[0]; xx++) { + const key = `${tex.name}@frame${tex.grid[0] * yy + xx}`; // PIXI.Texture's name in a shared loader + // Put each frame individually, with 1px padding on each side + blocks.push({ + data: { + name: tex.name, + tex, + frame: {// A crop from the source texture + x: tex.offx + xx * (tex.width + tex.marginx), + y: tex.offy + yy * (tex.height + tex.marginy), + width: tex.width, + height: tex.height + }, + key, + }, + width: tex.width + 2, + height: tex.height + 2, + }); + keys[tex.origname].push(key); + // skip unnecessary frames when tex.untill is set + if (yy * tex.grid[0] + xx >= tex.untill && tex.untill > 0) { + break; + } + } + } } else { tiledImages.push({ - origname: currentProject.textures[i].origname, - g: currentProject.textures[i] + origname: tex.origname, + tex }); } } + // eager sort blocks.sort((a, b) => Math.max(b.height, b.width) > Math.max(a.height, a.width)); + // this is the beginning of a resulting string that will be written to res.js let res = 'PIXI.Loader.shared'; let registry = {}; - const Packer = require('maxrects-packer'); + const atlases = []; // names of atlases' json files + const Packer = require('maxrects-packer').MaxRectsPacker; const atlasWidth = 2048, atlasHeight = 2048; - const pack = new Packer(atlasWidth, atlasHeight, 1); + const pack = new Packer(atlasWidth, atlasHeight, 0); + // pack all the frames pack.addArray(blocks); + // get all atlases pack.bins.forEach((bin, binInd) => { const atlas = document.createElement('canvas'); atlas.width = bin.width; @@ -118,7 +144,7 @@ const packImages = () => { const atlasJSON = { meta: { - app: 'http://ctjs.rocks/', + app: 'https://ctjs.rocks/', version: nw.App.manifest.version, image: `a${binInd}.png`, format: 'RGBA8888', @@ -131,80 +157,98 @@ const packImages = () => { frames: {}, animations: {} }; - for (let i = 0, li = bin.rects.length; i < li; i++) { - const block = bin.rects[i], - {g} = block.data, - img = glob.texturemap[g.uid]; - atlas.x.drawImage(img, block.x+1, block.y+1); + for (const block of bin.rects) { + const {tex} = block.data, + {frame} = block.data, + {key} = block.data, + img = glob.texturemap[tex.uid]; + // draw the main crop rectangle + atlas.x.drawImage(img, + frame.x, frame.y, frame.width, frame.height, + block.x+1, block.y+1, frame.width, frame.height + ); + // repeat the left side of the image + atlas.x.drawImage(img, + frame.x, frame.y, 1, frame.height, + block.x, block.y+1, 1, frame.height + ); + // repeat the right side of the image + atlas.x.drawImage(img, + frame.x+frame.width-1, frame.y, 1, frame.height, + block.x+frame.width+1, block.y+1, 1, frame.height + ); + // repeat the top side of the image + atlas.x.drawImage(img, + frame.x, frame.y, frame.width, 1, + block.x+1, block.y, frame.width, 1 + ); + // repeat the bottom side of the image + atlas.x.drawImage(img, + frame.x, frame.y+frame.height-1, frame.width, 1, + block.x+1, block.y+frame.height+1, frame.width, 1 + ); // A multi-frame sprite const keys = []; - for (var yy = 0; yy < g.grid[1]; yy++) { - for (var xx = 0; xx < g.grid[0]; xx++) { - const key = `${g.name}_frame${g.grid[0] * yy + xx}`; - keys.push(key); - atlasJSON.frames[key] = { - frame: { - x: block.x+1 + g.offx + xx * (g.width + g.marginx), - y: block.y+1 + g.offy + yy * (g.height + g.marginy), - w: g.width, - h: g.height - }, - rotated: false, - trimmed: false, - spriteSourceSize: { - x: 0, - y: 0, - w: g.width, - h: g.height - }, - sourceSize: { - w: g.width, - h: g.height - }, - anchor: { - x: g.axis[0] / g.width, - y: g.axis[1] / g.height - } - }; - if (yy * g.grid[0] + xx >= g.untill && g.untill > 0) { - break; - } + keys.push(key); + atlasJSON.frames[key] = { + frame: { + x: block.x+1, + y: block.y+1, + w: frame.width, + h: frame.height + }, + rotated: false, + trimmed: false, + spriteSourceSize: { + x: 0, + y: 0, + w: tex.width, + h: tex.height + }, + sourceSize: { + w: tex.width, + h: tex.height + }, + anchor: { + x: tex.axis[0] / tex.width, + y: tex.axis[1] / tex.height } - registry[g.name] = { - atlas: `./img/a${binInd}.json`, - frames: g.untill > 0? Math.min(g.untill, g.grid[0]*g.grid[1]) : g.grid[0]*g.grid[1], - shape: getTextureShape(g), - anchor: { - x: g.axis[0] / g.width, - y: g.axis[1] / g.height - } - }; - atlasJSON.animations[g.name] = keys; - } + }; } fs.outputJSONSync(`${writeDir}/img/a${binInd}.json`, atlasJSON); res += `\n.add('./img/a${binInd}.json')`; var data = atlas.toDataURL().replace(/^data:image\/\w+;base64,/, ''); var buf = new Buffer(data, 'base64'); fs.writeFileSync(`${writeDir}/img/a${binInd}.png`, buf); + atlases.push(`./img/a${binInd}.json`); }); + for (const tex of currentProject.textures) { + registry[tex.name] = { + frames: tex.untill > 0? Math.min(tex.untill, tex.grid[0]*tex.grid[1]) : tex.grid[0]*tex.grid[1], + shape: getTextureShape(tex), + anchor: { + x: tex.axis[0] / tex.width, + y: tex.axis[1] / tex.height + } + }; + } for (let i = 0, l = tiledImages.length; i < l; i++) { const atlas = document.createElement('canvas'), - {g} = tiledImages[i], - img = glob.texturemap[g.uid]; + {tex} = tiledImages[i], + img = glob.texturemap[tex.uid]; atlas.x = atlas.getContext('2d'); - atlas.width = g.width; - atlas.height = g.height; + atlas.width = tex.width; + atlas.height = tex.height; atlas.x.drawImage(img, 0, 0); var buf = new Buffer(atlas.toDataURL().replace(/^data:image\/\w+;base64,/, ''), 'base64'); fs.writeFileSync(`${writeDir}/img/t${i}.png`, buf); - registry[g.name] = { + registry[tex.name] = { atlas: `./img/t${i}.png`, frames: 0, - shape: getTextureShape(g), + shape: getTextureShape(tex), anchor: { - x: g.axis[0] / g.width, - y: g.axis[1] / g.height + x: tex.axis[0] / tex.width, + y: tex.axis[1] / tex.height } }; res += `\n.add('./img/t${i}.png')`; @@ -213,7 +257,8 @@ const packImages = () => { registry = JSON.stringify(registry); return { res, - registry + registry, + atlases }; }; const packSkeletons = (projdir) => { @@ -539,6 +584,7 @@ const runCtProject = async (project, projdir) => { .replace('/*@sndtotal@*/', currentProject.sounds.length) .replace('/*@res@*/', textures.res + '\n' + skeletons.loaderScript) .replace('/*@textureregistry@*/', textures.registry) + .replace('/*@textureatlases@*/', JSON.stringify(textures.atlases)) .replace('/*@skeletonregistry@*/', skeletons.registry) .replace('/*%resload%*/', injects.resload + '\n' + skeletons.startScript) .replace('/*%res%*/', injects.res); diff --git a/src/node_requires/i18n.js b/src/node_requires/i18n.js index cc47ed58a..73bd187da 100644 --- a/src/node_requires/i18n.js +++ b/src/node_requires/i18n.js @@ -1,14 +1,20 @@ const fs = require('fs-extra'); -const {extend} = require('./objectUtils'); +const {extendValid} = require('./objectUtils'); const vocDefault = fs.readJSONSync('./data/i18n/English.json'); var i18n; const loadLanguage = lang => { - const voc = fs.readJSONSync(`./data/i18n/${lang}.json`); + var voc; + try { + voc = fs.readJSONSync(`./data/i18n/${lang}.json`); + } catch (e) { + console.error(`An error occured while reading the language file ${lang}.json.`); + throw e; + } // eslint-disable-next-line no-console console.debug(`Loaded a language file ${lang}.json`); - i18n.languageJSON = extend({}, extend(vocDefault, voc)); + i18n.languageJSON = extendValid(vocDefault, voc); return i18n.languageJSON; }; diff --git a/src/node_requires/objectUtils.js b/src/node_requires/objectUtils.js index f7c02d1e7..9c063c637 100644 --- a/src/node_requires/objectUtils.js +++ b/src/node_requires/objectUtils.js @@ -18,6 +18,34 @@ const extend = function(destination, source) { return destination; }; +/** + * Similar to regular `extend`, but skips empty strings + * @param {Object|Array} destination The object to which to copy new properties + * @param {Object|Array} source The object from which to copy new properties + * @returns {Object|Array} The extended destination object + */ +const extendValid = function(destination, source) { + /* Considering JSON-valid objects */ + for (const key in source) { + // it is either a generic object or an array + if (typeof source[key] === 'object' && + source[key] !== null + ) { + if (!(key in destination)) { + if (Array.isArray(source[key])) { + destination[key] = []; + } else { + destination[key] = {}; + } + } + extendValid(destination[key], source[key]); + } else if (source[key] !== '') { // Skip empty lines + destination[key] = source[key]; // it is a primitive, copy it as is + } + } + return destination; +}; + const equal = function(one, two) { for (const property in one) { if (one[property] !== two[property]) { @@ -34,5 +62,6 @@ const equal = function(one, two) { module.exports = { extend, + extendValid, equal }; diff --git a/src/pug/index.pug b/src/pug/index.pug index 32f94d0f4..7986c0ee0 100644 --- a/src/pug/index.pug +++ b/src/pug/index.pug @@ -23,6 +23,13 @@ html } catch (e) { void e; } + script(src="node_modules/pixi.js/dist/pixi.min.js") + script. + /* So that WebGL contexts are taken from one page, + even if PIXI was called from the background page, + which is used for node modules + */ + global.PIXI = PIXI; include includes/footer.pug script. 'use strict'; diff --git a/src/riotTags/color-input.tag b/src/riotTags/color-input.tag index 0c3b5a047..fae732ca7 100644 --- a/src/riotTags/color-input.tag +++ b/src/riotTags/color-input.tag @@ -6,8 +6,10 @@ color-input color="{value}" onapply="{applyColor}" onchanged="{changeColor}" oncancel="{cancelColor}" ) script. + const Color = net.brehaut.Color; this.opened = false; - this.value = this.lastValue = this.opts.color || '#FFFFFF'; + this.value = this.lastValue = this.opts.color || '#FFFFFF'; + this.dark = Color(this.value).getLuminance() < 0.5; this.openPicker = e => { this.opened = !this.opened; }; diff --git a/src/riotTags/font-editor.tag b/src/riotTags/font-editor.tag index 827fd98c8..9a8c0b00e 100644 --- a/src/riotTags/font-editor.tag +++ b/src/riotTags/font-editor.tag @@ -11,7 +11,7 @@ font-editor.panel.view select(value="{fontobj.weight}" onchange="{wire('this.fontobj.weight')}") each val in [100, 200, 300, 400, 500, 600, 700, 800, 900] option(value=val)= val - label.block + label.checkbox input(type="checkbox" checked="{fontobj.italic}" onchange="{wire('this.fontobj.italic')}") b {voc.italic} .flexfix-footer diff --git a/src/riotTags/license-panel.tag b/src/riotTags/license-panel.tag index 2b3a9d7d4..d945226cf 100644 --- a/src/riotTags/license-panel.tag +++ b/src/riotTags/license-panel.tag @@ -150,22 +150,49 @@ license-panel.modal.pad 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. - h2 Lato Font by Łukasz Dziedzic + h2 Open Sans font by Steve Matteson + p Released under #[a(href="http://www.apache.org/licenses/LICENSE-2.0") Apache License 2.0]. + + h2 Iosevka Font by Belleve Invis pre code. - Copyright (c) 2010-2015, Łukasz Dziedzic (dziedzic@typoland.com), - with Reserved Font Name Lato. + The font is licensed under SIL OFL Version 1.1. + + The support code is licensed under Berkeley Software Distribution license. + + --- + --- + + Copyright (c) 2015-2019 Belleve Invis (belleve@typeof.net). + + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + * Neither the name of Belleve Invis nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BELLEVE INVIS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + ----------------------- + + --- + + Copyright 2015-2019, Belleve Invis (belleve@typeof.net). This Font Software is licensed under the SIL Open Font License, Version 1.1. + This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL + -------------------------- + - ----------------------------------------------------------- - SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 - ----------------------------------------------------------- + SIL Open Font License v1.1 + ==================================================== + + + Preamble + ---------- - PREAMBLE The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and @@ -174,79 +201,91 @@ license-panel.modal.pad The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The - fonts, including any derivative works, can be bundled, embedded, + fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives. - DEFINITIONS - "Font Software" refers to the set of files released by the Copyright + + Definitions + ------------- + + `"Font Software"` refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation. - "Reserved Font Name" refers to any names specified as such after the + `"Reserved Font Name"` refers to any names specified as such after the copyright statement(s). - "Original Version" refers to the collection of Font Software components as + `"Original Version"` refers to the collection of Font Software components as distributed by the Copyright Holder(s). - "Modified Version" refers to any derivative made by adding to, deleting, + `"Modified Version"` refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment. - "Author" refers to any designer, engineer, programmer, technical + `"Author"` refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software. - PERMISSION & CONDITIONS + + Permission & Conditions + ------------------------ + Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions: - 1) Neither the Font Software nor any of its individual components, + 1. Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself. - 2) Original or Modified Versions of the Font Software may be bundled, + 2. Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user. - 3) No Modified Version of the Font Software may use the Reserved Font + 3. No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users. - 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font + 4. The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission. - 5) The Font Software, modified or unmodified, in part or in whole, + 5. The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software. - TERMINATION + + + Termination + ----------- + This license becomes null and void if any of the above conditions are not met. - DISCLAIMER - THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, - EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF - MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT - OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE - COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, - INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL - DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING - FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM - OTHER DEALINGS IN THE FONT SOFTWARE. + + DISCLAIMER + + THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF + MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT + OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE + COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, + INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL + DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM + OTHER DEALINGS IN THE FONT SOFTWARE. h2 long-press-event.js by John Doherty pre diff --git a/src/riotTags/main-menu.tag b/src/riotTags/main-menu.tag index b5db74b92..68c805059 100644 --- a/src/riotTags/main-menu.tag +++ b/src/riotTags/main-menu.tag @@ -1,7 +1,7 @@ main-menu.flexcol nav.nogrow.flexrow(if="{window.currentProject}") ul#fullscreen.nav - li(onclick="{toggleFullscreen}" title="{voc.min}") + li.nbr(onclick="{toggleFullscreen}" title="{voc.min}") i(class="icon-{fullscreen? 'minimize-2' : 'maximize-2'}") ul#app.nav.tabs @@ -9,7 +9,7 @@ main-menu.flexcol i.icon-menu li.it30(onclick="{saveProject}" title="{voc.save}") i.icon-save - li.it30(onclick="{runProject}" title="{voc.launch}") + li.nbr.it30(onclick="{runProject}" title="{voc.launch}") i.icon-play ul#mainnav.nav.tabs @@ -244,6 +244,12 @@ main-menu.flexcol label: window.languageJSON.common.save, click: this.saveProject })); + catMenu.append(new gui.MenuItem({ + label: this.voc.openIncludeFolder, + click: e => { + nw.Shell.openItem(path.join(sessionStorage.projdir, '/include')); + } + })) catMenu.append(new gui.MenuItem({ label: this.voc.zipProject, click: this.zipProject @@ -259,6 +265,9 @@ main-menu.flexcol this.update(); } })); + catMenu.append(new gui.MenuItem({ + type: 'separator' + })); catMenu.append(new gui.MenuItem({ label: window.languageJSON.menu.startScreen, click: (e) => { @@ -315,6 +324,66 @@ main-menu.flexcol }; localStorage.UItheme = localStorage.UItheme || 'Day'; + var fontSubmenu = new nw.Menu(); + fontSubmenu.append(new gui.MenuItem({ + label: window.languageJSON.menu.codeFontDefault, + click: () => { + localStorage.fontFamily = ''; + window.signals.trigger('codeFontUpdated'); + } + })); + fontSubmenu.append(new gui.MenuItem({ + label: window.languageJSON.menu.codeFontOldSchool, + click: () => { + localStorage.fontFamily = 'Monaco, Menlo, "Ubuntu Mono", Consolas, source-code-pro, monospace'; + window.signals.trigger('codeFontUpdated'); + } + })); + fontSubmenu.append(new gui.MenuItem({ + label: window.languageJSON.menu.codeFontSystem, + click: () => { + localStorage.fontFamily = 'monospace'; + window.signals.trigger('codeFontUpdated'); + } + })); + fontSubmenu.append(new gui.MenuItem({ + label: window.languageJSON.menu.codeFontCustom, + click: () => { + alertify + .defaultValue(localStorage.fontFamily || '') + .prompt(window.languageJSON.menu.newFont) + .then(e => { + if (e.inputValue && e.buttonClicked !== 'cancel') { + localStorage.fontFamily = `"${e.inputValue}", monospace`; + } + window.signals.trigger('codeFontUpdated'); + }); + } + })); + fontSubmenu.append(new gui.MenuItem({type: 'separator'})); + fontSubmenu.append(new gui.MenuItem({ + label: window.languageJSON.menu.codeLigatures, + type: 'checkbox', + checked: localStorage.codeLigatures !== 'off', + click: () => { + localStorage.codeLigatures = localStorage.codeLigatures === 'off'? 'on' : 'off'; + window.signals.trigger('codeFontUpdated'); + } + })); + fontSubmenu.append(new gui.MenuItem({ + label: window.languageJSON.menu.codeDense, + type: 'checkbox', + checked: localStorage.codeDense === 'on', + click: () => { + localStorage.codeDense = localStorage.codeDense === 'off'? 'on' : 'off'; + window.signals.trigger('codeFontUpdated'); + } + })); + + catMenu.append(new gui.MenuItem({ + label: window.languageJSON.menu.codeFont, + submenu: fontSubmenu + })); catMenu.append(new gui.MenuItem({type: 'separator'})); @@ -337,6 +406,7 @@ main-menu.flexcol this.update(); } })); + catMenu.append(new gui.MenuItem({ label: window.languageJSON.common.donate, click: function () { @@ -375,7 +445,13 @@ main-menu.flexcol fs.readdir('./data/i18n/') .then(files => { files.forEach(filename => { + if (path.extname(filename) !== '.json') { + return; + } var file = filename.slice(0, -5); + if (file === 'Comments') { + return; + } languageSubmenu.append(new nw.MenuItem({ label: file, click: function() { @@ -389,7 +465,7 @@ main-menu.flexcol languageSubmenu.append(new nw.MenuItem({ label: window.languageJSON.common.translateToYourLanguage, click: function() { - gui.Shell.openExternal('https://translate.zanata.org/iteration/view/ct-js/v1/documents?docId=English.json&dswid=8629'); + gui.Shell.openExternal('https://github.com/ct-js/ct-js/tree/develop/app/data/i18n'); } })); }) diff --git a/src/riotTags/modules-panel.tag b/src/riotTags/modules-panel.tag index 37caff3ac..de5ff55e4 100644 --- a/src/riotTags/modules-panel.tag +++ b/src/riotTags/modules-panel.tag @@ -1,5 +1,5 @@ modules-panel.panel.view - .flexrow + .flexrow.tall .c3.borderright.tall ul#moduleincluded li(each="{module in enabledModules}" onclick="{renderModule(module)}") @@ -9,8 +9,8 @@ modules-panel.panel.view li(each="{module in allModules}" onclick="{renderModule(module)}") i.icon(class="icon-{(module in window.currentProject.libs)? 'confirm on' : 'mod off'}") span {module} - .c9.tall(if="{currentModule}") - ul.nav.tabs + .c9.tall.flexfix(if="{currentModule}") + ul.nav.tabs.flexfix-header.noshrink li#modinfo(onclick="{changeTab('moduleinfo')}" class="{active: tab === 'moduleinfo'}") i.icon-info span {voc.info} @@ -23,8 +23,8 @@ modules-panel.panel.view li#modlogs(if="{currentModuleLogs}" onclick="{changeTab('modulelogs')}" class="{active: tab === 'modulelogs'}") i.icon-list span {voc.logs} - div - #moduleinfo.tabbed(show="{tab === 'moduleinfo'}") + div.flexfix-body + #moduleinfo.tabbed.nbt(show="{tab === 'moduleinfo'}") label.bigpower(onclick="{toggleModule(currentModuleName)}" class="{off: !(currentModuleName in currentProject.libs)}") i(class="icon-{currentModuleName in currentProject.libs? 'confirm' : 'delete'}") span @@ -44,10 +44,10 @@ modules-panel.panel.view pre(if="{currentModuleLicense}") code {currentModuleLicense} - #modulesettings.tabbed(show="{tab === 'modulesettings'}" if="{currentModule.fields && currentModuleName in currentProject.libs}") + #modulesettings.tabbed.nbt(show="{tab === 'modulesettings'}" if="{currentModule.fields && currentModuleName in currentProject.libs}") dl(each="{field in currentModule.fields}") dt - label(if="{field.type === 'checkbox'}") + label.block.checkbox(if="{field.type === 'checkbox'}") input( type="checkbox" checked="{window.currentProject.libs[currentModuleName][field.id]}" @@ -68,7 +68,7 @@ modules-panel.panel.view value="{window.currentProject.libs[currentModuleName][field.id]}" onchange="{wire('window.currentProject.libs.' + escapeDots(currentModuleName) + '.' + field.id)}" ) - label.block(if="{field.type === 'radio'}" each="{option in field.options}") + label.block.checkbox(if="{field.type === 'radio'}" each="{option in field.options}") input( type="radio" value="{option.value}" @@ -87,9 +87,9 @@ modules-panel.panel.view //- That's a bad idea!!! div(class="desc" if="{field.help}") raw(ref="raw" content="{md.render(field.help)}") - #modulehelp.tabbed(show="{tab === 'modulehelp'}" if="{currentModuleDocs}") + #modulehelp.tabbed.nbt(show="{tab === 'modulehelp'}" if="{currentModuleDocs}") raw(ref="raw" content="{currentModuleDocs}") - #modulelogs.tabbed(show="{tab === 'modulelogs'}" if="{currentModuleLogs}") + #modulelogs.tabbed.nbt(show="{tab === 'modulelogs'}" if="{currentModuleLogs}") h1 {voc.logs2} raw(ref="raw" content="{currentModuleLogs}") script. @@ -98,8 +98,17 @@ modules-panel.panel.view gui = require('nw.gui'); const md = require('markdown-it')({ html: false, - linkify: true + linkify: true, + highlight: function (str, lang) { + if (lang && hljs.getLanguage(lang)) { + try { + return hljs.highlight(lang, str).value; + } catch (__) {} + } + return ''; // use external default escaping + } }); + const hljs = require('highlight.js'); const glob = require('./data/node_requires/glob'); const libsDir = './data/ct.libs'; this.md = md; diff --git a/src/riotTags/root-tag.tag b/src/riotTags/root-tag.tag index df096657b..0ab6eb6b3 100644 --- a/src/riotTags/root-tag.tag +++ b/src/riotTags/root-tag.tag @@ -9,3 +9,19 @@ root-tag this.selectorVisible = true; riot.update(); }); + + const stylesheet = document.createElement('style'); + document.head.appendChild(stylesheet); + const updateStylesheet = () => { + stylesheet.innerHTML = ` + code, pre, .ace_editor.ace_editor { + font-family: ${localStorage.fontFamily || 'Iosevka, monospace'}; + font-variant-ligatures: ${localStorage.codeLigatures === 'off'? 'none' : 'normal'}; + } + .ace_editor.ace_editor { + line-height: ${localStorage.codeDense === 'on'? 1.5 : 1.75}; + } + `; + }; + updateStylesheet(); + window.signals.on('codeFontUpdated', updateStylesheet); \ No newline at end of file diff --git a/src/riotTags/settings-panel.tag b/src/riotTags/settings-panel.tag index 08f5b68bd..2c464f0d3 100644 --- a/src/riotTags/settings-panel.tag +++ b/src/riotTags/settings-panel.tag @@ -1,71 +1,55 @@ settings-panel.panel.view .tall.fifty.npl.npt.npb h1 {voc.settings} - h2 {voc.authoring} - b {voc.title} - br - input#gametitle(type="text" value="{currentProject.settings.title}" onchange="{changeTitle}") - br - b {voc.author} - br - input#gameauthor(type="text" value="{currentProject.settings.author}" onchange="{wire('this.currentProject.settings.author')}") - br - b {voc.site} - br - input#gamesite(type="text" value="{currentProject.settings.site}" onchange="{wire('this.currentProject.settings.site')}") - br - b {voc.version} - br - input(type="number" style="width: 1.5rem;" value="{currentProject.settings.version[0]}" length="3" min="0" onchange="{wire('this.currentProject.settings.version.0')}") - | . - input(type="number" style="width: 1.5rem;" value="{currentProject.settings.version[1]}" length="3" min="0" onchange="{wire('this.currentProject.settings.version.1')}") - | . - input(type="number" style="width: 1.5rem;" value="{currentProject.settings.version[2]}" length="3" min="0" onchange="{wire('this.currentProject.settings.version.2')}") - | {voc.versionpostfix} - input(type="text" style="width: 3rem;" value="{currentProject.settings.versionPostfix}" length="5" onchange="{wire('this.currentProject.settings.versionPostfix')}") - - h2 {voc.actions} - p + fieldset + h2 {voc.authoring} + b {voc.title} + br + input#gametitle(type="text" value="{currentProject.settings.title}" onchange="{changeTitle}") + br + b {voc.author} + br + input#gameauthor(type="text" value="{currentProject.settings.author}" onchange="{wire('this.currentProject.settings.author')}") + br + b {voc.site} + br + input#gamesite(type="text" value="{currentProject.settings.site}" onchange="{wire('this.currentProject.settings.site')}") + br + b {voc.version} + br + input(type="number" style="width: 1.5rem;" value="{currentProject.settings.version[0]}" length="3" min="0" onchange="{wire('this.currentProject.settings.version.0')}") + | . + input(type="number" style="width: 1.5rem;" value="{currentProject.settings.version[1]}" length="3" min="0" onchange="{wire('this.currentProject.settings.version.1')}") + | . + input(type="number" style="width: 1.5rem;" value="{currentProject.settings.version[2]}" length="3" min="0" onchange="{wire('this.currentProject.settings.version.2')}") + | {voc.versionpostfix} + input(type="text" style="width: 3rem;" value="{currentProject.settings.versionPostfix}" length="5" onchange="{wire('this.currentProject.settings.versionPostfix')}") + fieldset + h2 {voc.actions} button.nml(onclick="{openActionsEditor}") i.icon-airplay span {voc.editActions} - actions-editor(if="{editingActions}") - - h2 {voc.renderoptions} - label.block - input(type="checkbox" value="{currentProject.settings.pixelatedrender}" checked="{currentProject.settings.pixelatedrender}" onchange="{wire('this.currentProject.settings.pixelatedrender')}") - span {voc.pixelatedrender} - label.block - input(type="checkbox" value="{currentProject.settings.highDensity}" checked="{currentProject.settings.highDensity}" onchange="{wire('this.currentProject.settings.highDensity')}") - span {voc.highDensity} - label.block - span {voc.maxFPS} - | - input.short(type="number" min="1" value="{currentProject.settings.maxFPS || 60}" onchange="{wire('this.currentProject.settings.maxFPS')}") + fieldset + h2 {voc.renderoptions} + label.block.checkbox + input(type="checkbox" value="{currentProject.settings.pixelatedrender}" checked="{currentProject.settings.pixelatedrender}" onchange="{wire('this.currentProject.settings.pixelatedrender')}") + span {voc.pixelatedrender} + label.block.checkbox + input(type="checkbox" value="{currentProject.settings.highDensity}" checked="{currentProject.settings.highDensity}" onchange="{wire('this.currentProject.settings.highDensity')}") + span {voc.highDensity} + label.block + span {voc.maxFPS} + | + input.short(type="number" min="1" value="{currentProject.settings.maxFPS || 60}" onchange="{wire('this.currentProject.settings.maxFPS')}") + fieldset + h2 {voc.exportparams} + label.block.checkbox(style="margin-right: 2.5rem;") + input(type="checkbox" value="{currentProject.settings.minifyhtmlcss}" checked="{currentProject.settings.minifyhtmlcss}" onchange="{wire('this.currentProject.settings.minifyhtmlcss')}") + span {voc.minifyhtmlcss} + label.block.checkbox + input(type="checkbox" value="{currentProject.settings.minifyjs}" checked="{currentProject.settings.minifyjs}" onchange="{wire('this.currentProject.settings.minifyjs')}") + span {voc.minifyjs} - h2 {voc.exportparams} - label.block(style="margin-right: 2.5rem;") - input(type="checkbox" value="{currentProject.settings.minifyhtmlcss}" checked="{currentProject.settings.minifyhtmlcss}" onchange="{wire('this.currentProject.settings.minifyhtmlcss')}") - span {voc.minifyhtmlcss} - label.block - input(type="checkbox" value="{currentProject.settings.minifyjs}" checked="{currentProject.settings.minifyjs}" onchange="{wire('this.currentProject.settings.minifyjs')}") - span {voc.minifyjs} - - //span - h2 {voc.preloader} - select#gamepreloader.select(value="{currentProject.preloader}" onchange="{wire('this.currentProject.preloader')}") - option(value="0") {voc.preloaders.circular} - option(value="1") {voc.preloaders.bar} - option(value="-1") {voc.preloaders.no} - br - br - b {voc.cover} - label.file - button.inline - i.icon.icon-folder - span {voc.getfile} - input#gamepreloaderfile(type="file" accept=".png, .jpg, .gif") - #preloaderpreview.pt40.tall .tall.fifty.flexfix.npr.npt.npb h1.flexfix-header {voc.scripts.header} ul.menu.flexfix-body @@ -76,6 +60,7 @@ settings-panel.panel.view button.flexfix-footer(onclick="{addNewScript}") i.icon-add span {voc.scripts.addNew} + actions-editor(if="{editingActions}") script-editor(if="{currentScript}" script="{currentScript}") script. this.namespace = 'settings'; diff --git a/src/riotTags/style-editor.tag b/src/riotTags/style-editor.tag index a99e0a1a8..5fdaeb571 100644 --- a/src/riotTags/style-editor.tag +++ b/src/riotTags/style-editor.tag @@ -14,127 +14,116 @@ style-editor.panel.view li(onclick="{changeTab('styleshadow')}" class="{active: tab === 'styleshadow'}") {voc.shadow} #stylefont.tabbed(show="{tab === 'stylefont'}") #stylefontinner - .fifty.npl.npt.npr + fieldset b {voc.fontfamily} input#fontfamily.wide(type="text" value="{styleobj.font.family || 'sans-serif'}" onchange="{wire('this.styleobj.font.family')}") - br - .fifty.npr.npt - b {voc.fontsize} - br - input#fontsize.wide(type="number" value="{styleobj.font.size || '12'}" onchange="{wire('this.styleobj.font.size')}" oninput="{wire('this.styleobj.font.size')}" step="1") - .clear - .fifty.npl.npt - label + .fifty.npl.npt + b {voc.fontsize} + br + input#fontsize.wide(type="number" value="{styleobj.font.size || '12'}" onchange="{wire('this.styleobj.font.size')}" oninput="{wire('this.styleobj.font.size')}" step="1") + .fifty.npr.npt b {voc.fontweight} br - select(value="{styleobj.font.weight}" onchange="{wire('this.styleobj.font.weight')}") + select.wide(value="{styleobj.font.weight}" onchange="{wire('this.styleobj.font.weight')}") each val in [100, 200, 300, 400, 500, 600, 700, 800, 900] option(value=val)= val - .fifty.npr - label + .clear + label.checkbox input(type="checkbox" checked="{styleobj.font.italic}" onchange="{wire('this.styleobj.font.italic')}") - span {voc.italic} - .clear - b {voc.alignment} - .align.buttonselect - button#middleleft.inline(onclick="{styleSetAlign('left')}" class="{active: this.styleobj.font.halign === 'left'}") - i.icon.icon-align-left - button#middlecenter.inline(onclick="{styleSetAlign('center')}" class="{active: this.styleobj.font.halign === 'center'}") - i.icon.icon-align-center - button#middleright.inline(onclick="{styleSetAlign('right')}" class="{active: this.styleobj.font.halign === 'right'}") - i.icon.icon-align-right - br - label - b {voc.lineHeight} - br - input(type="number" step="1" min="0" value="{styleobj.font.lineHeight || 0}" oninput="{wire('this.styleobj.font.lineHeight')}") - br - br - label - input(type="checkbox" checked="{styleobj.font.wrap}" onchange="{wire('this.styleobj.font.wrap')}") - b {voc.textWrap} - label(if="{styleobj.font.wrap}") - br - span {voc.textWrapWidth} - br - input(type="number" step="8" min="1" value="{styleobj.font.wrapPosition || 100}" oninput="{wire('this.styleobj.font.wrapPosition')}") + span {voc.italic} + fieldset + b {voc.alignment} + .align.buttonselect + button#middleleft.inline.nml(onclick="{styleSetAlign('left')}" class="{active: this.styleobj.font.halign === 'left'}") + i.icon.icon-align-left + button#middlecenter.inline(onclick="{styleSetAlign('center')}" class="{active: this.styleobj.font.halign === 'center'}") + i.icon.icon-align-center + button#middleright.inline(onclick="{styleSetAlign('right')}" class="{active: this.styleobj.font.halign === 'right'}") + i.icon.icon-align-right + label + b {voc.lineHeight} + br + input(type="number" step="1" min="0" value="{styleobj.font.lineHeight || 0}" oninput="{wire('this.styleobj.font.lineHeight')}") + fieldset + label.checkbox + input(type="checkbox" checked="{styleobj.font.wrap}" onchange="{wire('this.styleobj.font.wrap')}") + b {voc.textWrap} + label(if="{styleobj.font.wrap}").block.nmt + b {voc.textWrapWidth} + input.wide(type="number" step="8" min="1" value="{styleobj.font.wrapPosition || 100}" oninput="{wire('this.styleobj.font.wrapPosition')}") #stylefill.tabbed(show="{tab === 'stylefill'}") - label + label.checkbox input#iftochangefill(type="checkbox" checked="{'fill' in styleobj}" onchange="{styleToggleFill}") span {voc.active} #stylefillinner(if="{styleobj.fill}") - b {voc.filltype} - br - label - input(type="radio" value="0" name="filltype" checked="{styleobj.fill.type == 0}" onchange="{wire('this.styleobj.fill.type')}") - span {voc.fillsolid} - br - label - input(type="radio" value="1" name="filltype" checked="{styleobj.fill.type == 1}" onchange="{wire('this.styleobj.fill.type')}") - span {voc.fillgrad} - br - .solidfill(if="{styleobj.fill.type == 0}") - b {voc.fillcolor} - br - color-input(onchange="{wire('this.styleobj.fill.color', true)}" color="{styleobj.fill.color}") - .gradientfill(if="{styleobj.fill.type == 1}") - .fifty.npl - b {voc.fillcolor1} - color-input(onchange="{wire('this.styleobj.fill.color1', true)}" color="{styleobj.fill.color1}") - .fifty.npr - b {voc.fillcolor2} - color-input(onchange="{wire('this.styleobj.fill.color2', true)}" color="{styleobj.fill.color2}") - br - b {voc.fillgradtype} - br - label - input(type="radio" value="2" name="fillgradtype" onchange="{wire('this.styleobj.fill.gradtype')}") - span {voc.fillhorisontal} - br - label - input(type="radio" value="1" name="fillgradtype" onchange="{wire('this.styleobj.fill.gradtype')}") - span {voc.fillvertical} + fieldset + b {voc.filltype} + label.checkbox + input(type="radio" value="0" name="filltype" checked="{styleobj.fill.type == 0}" onchange="{wire('this.styleobj.fill.type')}") + span {voc.fillsolid} + label.checkbox + input(type="radio" value="1" name="filltype" checked="{styleobj.fill.type == 1}" onchange="{wire('this.styleobj.fill.type')}") + span {voc.fillgrad} + fieldset + .solidfill(if="{styleobj.fill.type == 0}") + b {voc.fillcolor} + br + color-input(onchange="{wire('this.styleobj.fill.color', true)}" color="{styleobj.fill.color}") + .gradientfill(if="{styleobj.fill.type == 1}") + .fifty.npl.npt + b {voc.fillcolor1} + color-input(onchange="{wire('this.styleobj.fill.color1', true)}" color="{styleobj.fill.color1}") + .fifty.npr.npt + b {voc.fillcolor2} + color-input(onchange="{wire('this.styleobj.fill.color2', true)}" color="{styleobj.fill.color2}") + .clear + b {voc.fillgradtype} + label.checkbox + input(type="radio" value="2" name="fillgradtype" onchange="{wire('this.styleobj.fill.gradtype')}") + span {voc.fillhorisontal} + label.checkbox + input(type="radio" value="1" name="fillgradtype" onchange="{wire('this.styleobj.fill.gradtype')}") + span {voc.fillvertical} #stylestroke.tabbed(show="{tab === 'stylestroke'}") - label + label.checkbox input#iftochangestroke(type="checkbox" checked="{'stroke' in styleobj}" onchange="{styleToggleStroke}") span {voc.active} #stylestrokeinner(if="{styleobj.stroke}") - b {voc.strokecolor} - color-input(onchange="{wire('this.styleobj.stroke.color', true)}" color="{styleobj.stroke.color}") - b {voc.strokeweight} - br - input#strokeweight(type="number" value="{styleobj.stroke.weight}" onchange="{wire('this.styleobj.stroke.weight')}" oninput="{wire('this.styleobj.stroke.weight')}") + fieldset + b {voc.strokecolor} + color-input(onchange="{wire('this.styleobj.stroke.color', true)}" color="{styleobj.stroke.color}") + fieldset + b {voc.strokeweight} + br + input#strokeweight(type="number" value="{styleobj.stroke.weight}" onchange="{wire('this.styleobj.stroke.weight')}" oninput="{wire('this.styleobj.stroke.weight')}") #strokeweightslider #styleshadow.tabbed(show="{tab === 'styleshadow'}") - label + label.checkbox input#iftochangeshadow(type="checkbox" checked="{'shadow' in styleobj}" onchange="{styleToggleShadow}") span {voc.active} #styleshadowinner(if="{styleobj.shadow}") - b {voc.shadowcolor} - color-input(onchange="{wire('this.styleobj.shadow.color', true)}" color="{styleobj.shadow.color}") - br - b {voc.shadowshift} - br - input#shadowx.short(type="number" value="{styleobj.shadow.x}" onchange="{wire('this.styleobj.shadow.x')}" oninput="{wire('this.styleobj.shadow.x')}") - | × - input#shadowy.short(type="number" value="{styleobj.shadow.y}" onchange="{wire('this.styleobj.shadow.y')}" oninput="{wire('this.styleobj.shadow.y')}") - br - br - b {voc.shadowblur} - br - input#shadowblur(type="number" value="{styleobj.shadow.blur}" min="0" onchange="{wire('this.styleobj.shadow.blur')}" oninput="{wire('this.styleobj.shadow.blur')}") - #shadowblurslider + fieldset + b {voc.shadowcolor} + color-input(onchange="{wire('this.styleobj.shadow.color', true)}" color="{styleobj.shadow.color}") + fieldset + b {voc.shadowshift} + br + input#shadowx.short(type="number" value="{styleobj.shadow.x}" onchange="{wire('this.styleobj.shadow.x')}" oninput="{wire('this.styleobj.shadow.x')}") + | × + input#shadowy.short(type="number" value="{styleobj.shadow.y}" onchange="{wire('this.styleobj.shadow.y')}" oninput="{wire('this.styleobj.shadow.y')}") + fieldset + b {voc.shadowblur} + br + input#shadowblur(type="number" value="{styleobj.shadow.blur}" min="0" onchange="{wire('this.styleobj.shadow.blur')}" oninput="{wire('this.styleobj.shadow.blur')}") .flexfix-footer button.wide.nogrow.noshrink(onclick="{styleSave}") i.icon.icon-confirm span {voc.apply} - #stylepreview.tall - canvas(width="550" height="400" ref="canvas") + #stylepreview.tall(ref="canvasSlot") texture-selector(if="{selectingTexture}" onselected="{applyTexture}" ref="textureselector") script. const fs = require('fs-extra'); - const PIXI = require('pixi.js'); this.namespace = 'styleview'; this.mixin(window.riotVoc); @@ -153,10 +142,16 @@ style-editor.panel.view this.tab = tab; }; this.on('mount', e => { - this.pixiApp = new PIXI.Application(640, 480, { - view: this.refs.canvas, + const width = 800; + const height = 500; + this.pixiApp = new PIXI.Application({ + width, + height, transparent: true }); + this.refs.canvasSlot.appendChild(this.pixiApp.view); + + console.log(this.pixiApp); var labelShort = languageJSON.styleview.testtext, labelMultiline = languageJSON.styleview.testtext.repeat(2) + '\n' + languageJSON.styleview.testtext.repeat(3) + '\n' + languageJSON.styleview.testtext, labelLong = 'A quick blue cat jumps over the lazy frog. 0123456789 '.repeat(3), @@ -171,7 +166,7 @@ style-editor.panel.view label.anchor.x = 0.5; label.anchor.y = 0.5; this.pixiApp.stage.addChild(label); - label.x = 320; + label.x = width / 2; } this.labelShort.y = 60; this.labelMultiline.y = 60 * 3; diff --git a/src/riotTags/texture-editor.tag b/src/riotTags/texture-editor.tag index a3e6a6dbb..9458b2e1f 100644 --- a/src/riotTags/texture-editor.tag +++ b/src/riotTags/texture-editor.tag @@ -1,174 +1,193 @@ texture-editor.panel.view - .column.borderright.tall.column1.flexfix - .flexfix-body - b {voc.name} - br - input.wide(type="text" value="{opts.texture.name}" onchange="{wire('this.texture.name')}") - .anErrorNotice(if="{nameTaken}") {vocGlob.nametaken} - br - b {voc.center} - .flexrow - input.short(type="number" value="{opts.texture.axis[0]}" onchange="{wire('this.texture.axis.0')}" oninput="{wire('this.texture.axis.0')}") - span.center × - input.short(type="number" value="{opts.texture.axis[1]}" onchange="{wire('this.texture.axis.1')}" oninput="{wire('this.texture.axis.1')}") - br - .flexrow - button.wide(onclick="{textureCenter}") - span {voc.setcenter} - button.square(onclick="{textureIsometrify}" title="{voc.isometrify}") - i.icon-map-pin - br - b {voc.form} - br - label - input(type="radio" name="collisionform" checked="{opts.texture.shape === 'circle'}" onclick="{textureSelectCircle}") - span {voc.round} - br - label - input(type="radio" name="collisionform" checked="{opts.texture.shape === 'rect'}" onclick="{textureSelectRect}") - span {voc.rectangle} - br - label - input(type="radio" name="collisionform" checked="{opts.texture.shape === 'strip'}" onclick="{textureSelectStrip}") - span {voc.strip} - br - div(if="{opts.texture.shape === 'circle'}") - b {voc.radius} - br - input.wide(type="number" value="{opts.texture.r}" onchange="{wire('this.texture.r')}" oninput="{wire('this.texture.r')}") - div(if="{opts.texture.shape === 'rect'}") - .center - input.short(type="number" value="{opts.texture.top}" onchange="{wire('this.texture.top')}" oninput="{wire('this.texture.top')}") + .flexrow.tall + .column.borderright.tall.column1.flexfix.nogrow.noshrink + .flexfix-body + fieldset + b {voc.name} br - input.short(type="number" value="{opts.texture.left}" onchange="{wire('this.texture.left')}" oninput="{wire('this.texture.left')}") - span × - input.short(type="number" value="{opts.texture.right}" onchange="{wire('this.texture.right')}" oninput="{wire('this.texture.right')}") + input.wide(type="text" value="{opts.texture.name}" onchange="{wire('this.texture.name')}") + .anErrorNotice(if="{nameTaken}") {vocGlob.nametaken} + label.checkbox + input#texturetiled(type="checkbox" checked="{opts.texture.tiled}" onchange="{wire('this.texture.tiled')}") + span {voc.tiled} + fieldset + b {voc.center} + .flexrow + input.short(type="number" value="{opts.texture.axis[0]}" onchange="{wire('this.texture.axis.0')}" oninput="{wire('this.texture.axis.0')}") + span.center × + input.short(type="number" value="{opts.texture.axis[1]}" onchange="{wire('this.texture.axis.1')}" oninput="{wire('this.texture.axis.1')}") + .flexrow + button.wide.nml(onclick="{textureCenter}") + span {voc.setcenter} + button.square.nmr(onclick="{textureIsometrify}" title="{voc.isometrify}") + i.icon-map-pin + fieldset + b {voc.form} + label.checkbox + input(type="radio" name="collisionform" checked="{opts.texture.shape === 'circle'}" onclick="{textureSelectCircle}") + span {voc.round} + label.checkbox + input(type="radio" name="collisionform" checked="{opts.texture.shape === 'rect'}" onclick="{textureSelectRect}") + span {voc.rectangle} + label.checkbox + input(type="radio" name="collisionform" checked="{opts.texture.shape === 'strip'}" onclick="{textureSelectStrip}") + span {voc.strip} + fieldset(if="{opts.texture.shape === 'circle'}") + b {voc.radius} br - input.short(type="number" value="{opts.texture.bottom}" onchange="{wire('this.texture.bottom')}" oninput="{wire('this.texture.bottom')}") - br - button.wide(onclick="{textureFillRect}") - i.icon-maximize - span {voc.fill} - div(if="{opts.texture.shape === 'strip'}") - .flexrow(each="{point, ind in opts.texture.stripPoints}") - input.short(type="number" value="{point.x}" oninput="{wire('this.texture.stripPoints.'+ ind + '.x')}") - span × - input.short(type="number" value="{point.y}" oninput="{wire('this.texture.stripPoints.'+ ind + '.y')}") - button.square.inline(title="{voc.removePoint}" onclick="{removeStripPoint}") - i.icon-minus - input(type="checkbox" checked="{opts.texture.closedStrip}") - span {voc.closeShape} - button.wide(onclick="{addStripPoint}") - i.icon-plus - span {voc.addPoint} - br - label - input(checked="{prevShowMask}" onchange="{wire('this.prevShowMask')}" type="checkbox") - span {voc.showmask} - .flexfix-footer - button.wide(onclick="{textureSave}") - i.icon-save - span {window.languageJSON.common.save} - .column.column2.borderleft.tall.flexfix - .flexfix-body - .fifty.np - b {voc.cols} - br - input.wide(type="number" value="{opts.texture.grid[0]}" onchange="{wire('this.texture.grid.0')}" oninput="{wire('this.texture.grid.0')}") - .fifty.np - b {voc.rows} - br - input.wide(type="number" value="{opts.texture.grid[1]}" onchange="{wire('this.texture.grid.1')}" oninput="{wire('this.texture.grid.1')}") - .clear - .fifty.np - b {voc.width} - br - input.wide(type="number" value="{opts.texture.width}" onchange="{wire('this.texture.width')}" oninput="{wire('this.texture.width')}") - .fifty.np - b {voc.height} - br - input.wide(type="number" value="{opts.texture.height}" onchange="{wire('this.texture.height')}" oninput="{wire('this.texture.height')}") - .clear - .fifty.np - b {voc.marginx} - br - input.wide(type="number" value="{opts.texture.marginx}" onchange="{wire('this.texture.marginx')}" oninput="{wire('this.texture.marginx')}") - .fifty.np - b {voc.marginy} - br - input.wide(type="number" value="{opts.texture.marginy}" onchange="{wire('this.texture.marginy')}" oninput="{wire('this.texture.marginy')}") - .clear - .fifty.np - b {voc.offx} - br - input.wide(type="number" value="{opts.texture.offx}" onchange="{wire('this.texture.offx')}" oninput="{wire('this.texture.offx')}") - .fifty.np - b {voc.offy} - br - input.wide(type="number" value="{opts.texture.offy}" onchange="{wire('this.texture.offy')}" oninput="{wire('this.texture.offy')}") - .clear - b {voc.frames} - br - input#textureframes.wide(type="number" value="{opts.texture.untill}" onchange="{wire('this.texture.untill')}" oninput="{wire('this.texture.untill')}") - br - label - input#texturetiled(type="checkbox" checked="{opts.texture.tiled}" onchange="{wire('this.texture.tiled')}") - span {voc.tiled} - .preview.bordertop.flexfix-footer - #preview(ref="preview" style="background-color: {previewColor};") - canvas(ref="grprCanvas") - div - button#textureplay.square.inline(onclick="{currentTexturePreviewPlay}") - i(class="icon-{this.prevPlaying? 'pause' : 'play'}") - button#textureviewback.square.inline(onclick="{currentTexturePreviewBack}") - i.icon-back - button#textureviewnext.square.inline(onclick="{currentTexturePreviewNext}") - i.icon-next - span(ref="textureviewframe") 0 / 1 + input.wide(type="number" value="{opts.texture.r}" onchange="{wire('this.texture.r')}" oninput="{wire('this.texture.r')}") + fieldset(if="{opts.texture.shape === 'rect'}") + .center + input.short(type="number" value="{opts.texture.top}" onchange="{wire('this.texture.top')}" oninput="{wire('this.texture.top')}") + br + input.short(type="number" value="{opts.texture.left}" onchange="{wire('this.texture.left')}" oninput="{wire('this.texture.left')}") + span × + input.short(type="number" value="{opts.texture.right}" onchange="{wire('this.texture.right')}" oninput="{wire('this.texture.right')}") + br + input.short(type="number" value="{opts.texture.bottom}" onchange="{wire('this.texture.bottom')}" oninput="{wire('this.texture.bottom')}") + button.wide(onclick="{textureFillRect}") + i.icon-maximize + span {voc.fill} + fieldset(if="{opts.texture.shape === 'strip'}") + .flexrow.aStripPointRow(each="{point, ind in getMovableStripPoints()}") + input.short(type="number" value="{point.x}" oninput="{wire('this.texture.stripPoints.'+ ind + '.x')}") + span × + input.short(type="number" value="{point.y}" oninput="{wire('this.texture.stripPoints.'+ ind + '.y')}") + button.square.inline(title="{voc.removePoint}" onclick="{removeStripPoint}") + i.icon-minus + label.checkbox + input(type="checkbox" checked="{opts.texture.closedStrip}" onchange="{onClosedStripChange}" ) + span {voc.closeShape} + label.checkbox + input(type="checkbox" checked="{opts.texture.symmetryStrip}" onchange="{onSymmetryChange}") + span {voc.symmetryTool} + button.wide(onclick="{addStripPoint}") + i.icon-plus + span {voc.addPoint} + fieldset + label.checkbox + input(checked="{prevShowMask}" onchange="{wire('this.prevShowMask')}" type="checkbox") + span {voc.showmask} + .flexfix-footer + button.wide(onclick="{textureSave}") + i.icon-save + span {window.languageJSON.common.save} + .texture-editor-anAtlas.tall( + if="{opts.texture}" + style="background-color: {previewColor};" + onmousewheel="{onMouseWheel}" + ) + .texture-editor-aCanvasWrap + canvas.texture-editor-aCanvas(ref="textureCanvas" style="transform: scale({zoomFactor}); image-rendering: {zoomFactor > 1? 'pixelated' : '-webkit-optimize-contrast'}; transform-origin: 0% 0%;") + // This div is needed to cause elements' reflow so the scrollbars update on canvas' size change + div(style="width: {zoomFactor}px; height: {zoomFactor}px;") + .aClicker( + if="{prevShowMask && opts.texture.shape === 'strip'}" + each="{seg, ind in getStripSegments()}" + style="left: {seg.left}px; top: {seg.top}px; width: {seg.width}px; transform: translate(0, -50%) rotate({seg.angle}deg);" + title="{voc.addPoint}" + onclick="{addStripPointOnSegment}" + ) + .aDragger( + if="{prevShowMask}" + style="left: {opts.texture.axis[0] * zoomFactor}px; top: {opts.texture.axis[1] * zoomFactor}px; border-radius: 0;" + title="{voc.moveCenter}" + onmousedown="{startMoving('axis')}" + ) + .aDragger( + if="{prevShowMask && opts.texture.shape === 'strip'}" + each="{point, ind in getMovableStripPoints()}" + style="left: {(point.x + texture.axis[0]) * zoomFactor}px; top: {(point.y + texture.axis[1]) * zoomFactor}px;" + title="{voc.movePoint}" + onmousedown="{startMoving('point')}" + ) + .textureview-tools + .toright + label.file(title="{voc.replacetexture}") + input(type="file" ref="textureReplacer" accept=".png,.jpg,.jpeg,.bmp,.gif" onchange="{textureReplace}") + .button.inline + i.icon-folder + span {voc.replacetexture} + .button.inline(title="{voc.reimport}" if="{opts.texture.source}" onclick="{reimport}") + i.icon-refresh-ccw + .textureview-zoom + div.button-stack.inlineblock + button#texturezoom25.inline(onclick="{textureToggleZoom(0.25)}" class="{active: zoomFactor === 0.25}") 25% + button#texturezoom50.inline(onclick="{textureToggleZoom(0.5)}" class="{active: zoomFactor === 0.5}") 50% + button#texturezoom100.inline(onclick="{textureToggleZoom(1)}" class="{active: zoomFactor === 1}") 100% + button#texturezoom200.inline(onclick="{textureToggleZoom(2)}" class="{active: zoomFactor === 2}") 200% + button#texturezoom400.inline(onclick="{textureToggleZoom(4)}" class="{active: zoomFactor === 4}") 400% + .column.column2.borderleft.tall.flexfix.nogrow.noshrink(show="{!opts.texture.tiled}") + .flexfix-body + .flexrow + div + b {voc.cols} + br + input.wide(type="number" value="{opts.texture.grid[0]}" onchange="{wire('this.texture.grid.0')}" oninput="{wire('this.texture.grid.0')}") + span   + div + b {voc.rows} + br + input.wide(type="number" value="{opts.texture.grid[1]}" onchange="{wire('this.texture.grid.1')}" oninput="{wire('this.texture.grid.1')}") + .flexrow + div + b {voc.width} + br + input.wide(type="number" value="{opts.texture.width}" onchange="{wire('this.texture.width')}" oninput="{wire('this.texture.width')}") + span   + div + b {voc.height} + br + input.wide(type="number" value="{opts.texture.height}" onchange="{wire('this.texture.height')}" oninput="{wire('this.texture.height')}") + .flexrow + div + b {voc.marginx} + br + input.wide(type="number" value="{opts.texture.marginx}" onchange="{wire('this.texture.marginx')}" oninput="{wire('this.texture.marginx')}") + span   + div + b {voc.marginy} + br + input.wide(type="number" value="{opts.texture.marginy}" onchange="{wire('this.texture.marginy')}" oninput="{wire('this.texture.marginy')}") + .flexrow + div + b {voc.offx} + br + input.wide(type="number" value="{opts.texture.offx}" onchange="{wire('this.texture.offx')}" oninput="{wire('this.texture.offx')}") + span   + div + b {voc.offy} + br + input.wide(type="number" value="{opts.texture.offy}" onchange="{wire('this.texture.offy')}" oninput="{wire('this.texture.offy')}") + b {voc.frames} br - b {voc.speed} - input#grahpspeed.short(type="number" min="1" value="{prevSpeed}" onchange="{wire('this.prevSpeed')}" oninput="{wire('this.prevSpeed')}") - .relative - button#texturecolor.inline.wide(onclick="{changeTexturePreviewColor}") - i.icon-drop - span {voc.bgcolor} - input.color.rgb#previewbgcolor + input#textureframes.wide(type="number" value="{opts.texture.untill}" onchange="{wire('this.texture.untill')}" oninput="{wire('this.texture.untill')}") + .preview.bordertop.flexfix-footer + #preview(ref="preview" style="background-color: {previewColor};") + canvas(ref="grprCanvas") + .flexrow + button#textureplay.square.inline(onclick="{currentTexturePreviewPlay}") + i(class="icon-{this.prevPlaying? 'pause' : 'play'}") + span(ref="textureviewframe") 0 / 1 + .filler + button#textureviewback.square.inline(onclick="{currentTexturePreviewBack}") + i.icon-back + button#textureviewnext.square.inline.nmr(onclick="{currentTexturePreviewNext}") + i.icon-next + .flexrow + b {voc.speed} + .filler + input#grahpspeed.short(type="number" min="1" value="{prevSpeed}" onchange="{wire('this.prevSpeed')}" oninput="{wire('this.prevSpeed')}") + .relative + button#texturecolor.inline.wide(onclick="{changeTexturePreviewColor}") + i.icon-drop + span {voc.bgcolor} + input.color.rgb#previewbgcolor color-picker( ref="previewBackgroundColor" if="{changingTexturePreviewColor}" color="{previewColor}" onapply="{updatePreviewColor}" onchanged="{updatePreviewColor}" oncancel="{cancelPreviewColor}" ) - .texture-editor-anAtlas(style="background-color: {previewColor};") - .textureview-tools - .toright - label.file(title="{voc.replacetexture}") - input(type="file" ref="textureReplacer" accept=".png,.jpg,.jpeg,.bmp,.gif" onchange="{textureReplace}") - .button.inline - i.icon-folder - span {voc.replacetexture} - .button.inline(title="{voc.reimport}" if="{opts.texture.source}" onclick="{reimport}") - i.icon-refresh-ccw - .textureview-zoom - div.button-stack.inlineblock - button#texturezoom25.inline(onclick="{textureToggleZoom(0.25)}" class="{active: zoomFactor === 0.25}") 25% - button#texturezoom50.inline(onclick="{textureToggleZoom(0.5)}" class="{active: zoomFactor === 0.5}") 50% - button#texturezoom100.inline(onclick="{textureToggleZoom(1)}" class="{active: zoomFactor === 1}") 100% - button#texturezoom200.inline(onclick="{textureToggleZoom(2)}" class="{active: zoomFactor === 2}") 200% - button#texturezoom400.inline(onclick="{textureToggleZoom(4)}" class="{active: zoomFactor === 4}") 400% - - canvas(ref="textureCanvas" onmousewheel="{onCanvasWheel}" style="transform: scale({zoomFactor}); image-rendering: {zoomFactor > 1? 'pixelated' : '-webkit-optimize-contrast'}; transform-origin: 0% 0%;") - .aDragger( - style="left: {opts.texture.axis[0] * zoomFactor}px; top: {opts.texture.axis[1] * zoomFactor}px;" - title="{voc.moveCenter}" - onmousedown="{startMoving('axis')}" - ) - .aDragger( - if="{opts.texture.shape === 'strip'}" - each="{point, ind in opts.texture.stripPoints}" - style="left: {(point.x + texture.axis[0]) * zoomFactor}px; top: {(point.y + texture.axis[1]) * zoomFactor}px;" - title="{voc.movePoint}" - onmousedown="{startMoving('point')}" - ) script. const path = require('path'), fs = require('fs-extra'); @@ -216,6 +235,7 @@ texture-editor.panel.view } else { this.nameTaken = false; } + this.updateSymmetricalPoints(); }); this.on('updated', () => { this.refreshTextureCanvas(); @@ -287,7 +307,7 @@ texture-editor.panel.view this.zoomFactor = zoom; }; /** Change zoomFactor on mouse wheel roll */ - this.onCanvasWheel = e => { + this.onMouseWheel = e => { if (e.wheelDelta > 0) { // in if (this.zoomFactor === 2) { @@ -311,6 +331,7 @@ texture-editor.panel.view this.zoomFactor = 0.25; } } + e.preventDefault(); this.update(); }; @@ -425,13 +446,13 @@ texture-editor.panel.view } }; /** - * Остановить предпросмотр анимации + * Stops the animated preview */ this.stopTexturePreview = () => { window.clearTimeout(this.prevTime); }; /** - * Запустить предпросмотр анимации + * Starts the preview of a framed animation */ this.launchTexturePreview = () => { var texture = this.texture; @@ -453,7 +474,9 @@ texture-editor.panel.view this.prevPos = 0; } this.refs.textureviewframe.innerHTML = `${this.prevPos} / ${total}`; - this.refreshPreviewCanvas(); + if (!this.texture.tiled) { + this.refreshPreviewCanvas(); + } this.stepTexturePreview(); }, ~~(1000 / this.prevSpeed)); }; @@ -492,10 +515,13 @@ texture-editor.panel.view y: -Math.round(Math.cos(twoPi / 5 * i) * this.texture.height / 2) }); } - console.log(this.texture); } }; this.removeStripPoint = function (e) { + if(this.texture.symmetryStrip) { + // Remove an extra point + this.texture.stripPoints.pop(); + } this.texture.stripPoints.splice(e.item.ind, 1); }; this.addStripPoint = function () { @@ -504,6 +530,55 @@ texture-editor.panel.view y: 16 }); }; + this.addStripPointOnSegment = e => { + const { top, left } = textureCanvas.getBoundingClientRect(); + this.texture.stripPoints.splice(e.item.ind+1, 0, { + x: (e.pageX - left) / this.zoomFactor - this.texture.axis[0], + y: (e.pageY - top) / this.zoomFactor - this.texture.axis[1] + }); + if(this.texture.symmetryStrip) { + // Add an extra point (the symetrical point) + this.addStripPoint(); + } + }; + this.pointToLine = (linePoint1, linePoint2, point) => { + const dlx = linePoint2.x - linePoint1.x; + const dly = linePoint2.y - linePoint1.y; + const lineLength = Math.sqrt(dlx*dlx + dly*dly); + const lineAngle = Math.atan2(dly, dlx); + + const dpx = point.x - linePoint1.x; + const dpy = point.y - linePoint1.y; + const toPointLength = Math.sqrt(dpx*dpx + dpy*dpy); + const toPointAngle = Math.atan2(dpy, dpx); + + const distance = toPointLength * Math.cos(toPointAngle - lineAngle); + + return { + x: linePoint1.x + distance * dlx / lineLength, + y: linePoint1.y + distance * dly / lineLength + }; + }; + this.onClosedStripChange = e => { + this.texture.closedStrip = !this.texture.closedStrip; + if(!this.texture.closedStrip && this.texture.symmetryStrip) { + this.onSymmetryChange(); + } + }; + this.onSymmetryChange = e => { + if(this.texture.symmetryStrip) { + this.texture.stripPoints = this.getMovableStripPoints(); + } else { + const nbPointsToAdd = this.texture.stripPoints.length - 2; + for(let i = 0; i < nbPointsToAdd; i++) { + this.addStripPoint(); + } + this.texture.closedStrip = true; // Force closedStrip to true + } + + this.texture.symmetryStrip = !this.texture.symmetryStrip; + this.update(); + } this.startMoving = which => e => { const startX = e.screenX, startY = e.screenY; @@ -524,11 +599,19 @@ texture-editor.panel.view const point = e.item.point, oldX = point.x, oldY = point.y; + let hasMoved = false; const func = e => { + if(!hasMoved && (e.screenX !== startX || e.screenY !== startY)) { + hasMoved = true; + } point.x = (e.screenX - startX) / this.zoomFactor + oldX; point.y = (e.screenY - startY) / this.zoomFactor + oldY; this.update(); }, func2 = () => { + if(!hasMoved) { + this.removeStripPoint(e); + this.update(); + } document.removeEventListener('mousemove', func); document.removeEventListener('mouseup', func2); }; @@ -537,7 +620,7 @@ texture-editor.panel.view } }; /** - * Перерисовывает канвас со спрайтом со всеми масками и делениями + * Redraws the canvas with the full image, its collision mask, and its slicing grid */ this.refreshTextureCanvas = () => { textureCanvas.width = textureCanvas.img.width; @@ -548,14 +631,16 @@ texture-editor.panel.view textureCanvas.x.clearRect(0, 0, textureCanvas.width, textureCanvas.height); textureCanvas.x.drawImage(textureCanvas.img, 0, 0); textureCanvas.x.globalAlpha = 0.5; - for (let i = 0, l = Math.min(this.texture.grid[0] * this.texture.grid[1], this.texture.untill || Infinity); i < l; i++) { - let xx = i % this.texture.grid[0], - yy = Math.floor(i / this.texture.grid[0]), - x = this.texture.offx + xx * (this.texture.marginx + this.texture.width), - y = this.texture.offy + yy * (this.texture.marginy + this.texture.height), - w = this.texture.width, - h = this.texture.height; - textureCanvas.x.strokeRect(x, y, w, h); + if (!this.texture.tiled) { + for (let i = 0, l = Math.min(this.texture.grid[0] * this.texture.grid[1], this.texture.untill || Infinity); i < l; i++) { + let xx = i % this.texture.grid[0], + yy = Math.floor(i / this.texture.grid[0]), + x = this.texture.offx + xx * (this.texture.marginx + this.texture.width), + y = this.texture.offy + yy * (this.texture.marginy + this.texture.height), + w = this.texture.width, + h = this.texture.height; + textureCanvas.x.strokeRect(x, y, w, h); + } } if (this.prevShowMask) { textureCanvas.x.fillStyle = '#ff0'; @@ -582,6 +667,20 @@ texture-editor.panel.view textureCanvas.x.closePath(); } textureCanvas.x.stroke(); + + if(this.texture.symmetryStrip) { + const movablePoints = this.getMovableStripPoints(); + const axisPoint1 = movablePoints[0]; + const axisPoint2 = movablePoints[movablePoints.length - 1]; + + // Draw symmetry axis + textureCanvas.x.strokeStyle = '#f00'; + textureCanvas.x.lineWidth = 3; + textureCanvas.x.beginPath(); + textureCanvas.x.moveTo(axisPoint1.x + this.texture.axis[0], axisPoint1.y + this.texture.axis[1]); + textureCanvas.x.lineTo(axisPoint2.x + this.texture.axis[0], axisPoint2.y + this.texture.axis[1]); + textureCanvas.x.stroke(); + } } } }; @@ -657,3 +756,63 @@ texture-editor.panel.view this.previewColor = this.oldPreviewColor; this.update(); }; + this.getMovableStripPoints = () => { + if(!this.texture) return; + if(!this.texture.symmetryStrip) { + return this.texture.stripPoints; + } else { + return this.texture.stripPoints.slice(0, 2 + Math.round((this.texture.stripPoints.length - 2) / 2)); + } + }; + this.getStripSegments = () => { + if(!this.texture) { + return; + } + if (this.texture.shape !== 'strip') { + return; + } + + const points = this.getMovableStripPoints(); + const segs = []; + + for(let i = 0; i < points.length; i++) { + const point1 = points[i]; + const point2 = points[(i + 1) % points.length]; + + const x1 = (point1.x + this.texture.axis[0]) * this.zoomFactor; + const y1 = (point1.y + this.texture.axis[1]) * this.zoomFactor; + const x2 = (point2.x + this.texture.axis[0]) * this.zoomFactor; + const y2 = (point2.y + this.texture.axis[1]) * this.zoomFactor; + const dx = x2 - x1; + const dy = y2 - y1; + + const length = Math.sqrt(dx*dx + dy*dy); + const cssAngle = Math.atan2(dy, dx) * 180 / Math.PI; + + segs.push({ + left: x1, + top: y1, + width: length, + angle: cssAngle + }); + } + + return segs; + }; + this.updateSymmetricalPoints = () => { + if(this.texture && this.texture.symmetryStrip) { + const movablePoints = this.getMovableStripPoints(); + const axisPoint1 = movablePoints[0]; + const axisPoint2 = movablePoints[movablePoints.length - 1]; + for(let i = 1; i < movablePoints.length - 1; i++) { + const j = this.texture.stripPoints.length - i; + const point = movablePoints[i]; + const axisPoint = this.pointToLine(axisPoint1, axisPoint2, point); + this.texture.stripPoints[j] = { + x: 2 * axisPoint.x - point.x, + y: 2 * axisPoint.y - point.y + } + } + } + }; + diff --git a/src/riotTags/textures-panel.tag b/src/riotTags/textures-panel.tag index 8d12f6ed1..87a5b336d 100644 --- a/src/riotTags/textures-panel.tag +++ b/src/riotTags/textures-panel.tag @@ -381,7 +381,6 @@ textures-panel.panel.view .defaultValue(this.currentTexture.name) .prompt(window.languageJSON.common.newname) .then(e => { - console.log(e); if (e.inputValue && e.inputValue != '' && e.buttonClicked !== 'cancel') { this.currentTexture.name = e.inputValue; this.update(); diff --git a/src/styl/3rdParty/fonts.styl b/src/styl/3rdParty/fonts.styl index 21727c67e..33d5f496a 100644 --- a/src/styl/3rdParty/fonts.styl +++ b/src/styl/3rdParty/fonts.styl @@ -47,4 +47,29 @@ font-weight: 600; font-style: italic; } + + @font-face { + font-family: 'Iosevka'; + src: url('../data/fonts/iosevka-light.woff2') format('woff2'); + font-weight: 400; + font-style: normal; + } + @font-face { + font-family: 'Iosevka'; + src: url('../data/fonts/iosevka-bold.woff2') format('woff2'); + font-weight: 600; + font-style: normal; + } + @font-face { + font-family: 'Iosevka'; + src: url('../data/fonts/iosevka-lightitalic.woff2') format('woff2'); + font-weight: 400; + font-style: italic; + } + @font-face { + font-family: 'Iosevka'; + src: url('../data/fonts/iosevka-bolditalic.woff2') format('woff2'); + font-weight: 600; + font-style: italic; + } } \ No newline at end of file diff --git a/src/styl/buildingBlocks.styl b/src/styl/buildingBlocks.styl index b81e853bd..258416a8a 100644 --- a/src/styl/buildingBlocks.styl +++ b/src/styl/buildingBlocks.styl @@ -45,8 +45,11 @@ position absolute left 0 right 0 - top -1px + top 0 bottom 0 + border-top 0 + .view + border 0 .inset background bl @@ -203,4 +206,17 @@ sounds-panel, rooms-panel height 0.5rem border-left 1px solid error border-top 1px solid error - transform rotate(45deg) \ No newline at end of file + transform rotate(45deg) + +.nicetable, #moduleinfo table, #modulesettings table, #modulehelp table + margin 1rem 0 + border 1px solid bd + border-radius br + border-spacing 0 + {shadamb} + td, th + padding 0.5rem 1.5rem + margin 0 + th + border-bottom 1px solid bd + text-align left \ No newline at end of file diff --git a/src/styl/common.styl b/src/styl/common.styl index 12d264192..7d251de16 100644 --- a/src/styl/common.styl +++ b/src/styl/common.styl @@ -109,5 +109,4 @@ div#loading left 0 top 0 width 100% - height 100% - line-height 1.5 !important + height 100% \ No newline at end of file diff --git a/src/styl/hvost.styl b/src/styl/hvost.styl index 54eb7c5a7..9d2c10529 100644 --- a/src/styl/hvost.styl +++ b/src/styl/hvost.styl @@ -28,6 +28,13 @@ body min-height 100vh position relative +html + scroll-behavior smooth +@media (prefers-reduced-motion: reduce) + html + scroll-behavior auto + + .big font-size 125% .small @@ -138,7 +145,8 @@ noblah = { } shortNames = { m: 'margin', - p: 'padding' + p: 'padding', + b: 'border' } for key, val in shortNames for skey, sval in noblah diff --git a/src/styl/inputs.styl b/src/styl/inputs.styl index 56af042d3..2fb1c71a9 100644 --- a/src/styl/inputs.styl +++ b/src/styl/inputs.styl @@ -219,6 +219,9 @@ input[type="reset"], select, label cursor pointer +select + line-height 2 + height calc(2.2rem + 2px) .selectbox width 10em position relative @@ -250,7 +253,6 @@ select, label right 0.5em top 50% -// выбор файла label & + & margin-top 0.5rem @@ -259,6 +261,55 @@ label position relative [type="file"] display none + &.checkbox + position relative + padding-left 1.5rem + margin-top 0 + display block + [type="checkbox"], [type="radio"] + -webkit-appearance none + appearance none + margin 0 + width 1rem + height 1rem + left 0 + top 0.5rem + border 1px solid act + box-sizing border-box + position absolute + border-radius br + {trans} + &::after + @extends .icon-check:before + font-family 'icomoon' !important + font-size 1rem + position absolute + top -0.025rem + left -0.05rem + line-height 1 + color white + opacity 0 + {trans} + &:checked + background act + border-color accent1 + {transshort} + &::after + {transshort} + opacity 1 + [type="radio"] + border-radius 100% +fieldset + border 0 + padding 0 + margin 0 + & + fieldset + margin-top 1rem + button + margin-top 0.5rem + & > button + &:first-child + margin-top 0 input[type="range"] -webkit-appearance none @@ -315,6 +366,14 @@ input[type="range"] margin 1rem {shad} +.aClicker + height 0.75rem + position absolute + transform translate(0, -50%) + transform-origin left center + cursor copy + margin 1rem + .aDropzone @extends .middle position fixed diff --git a/src/styl/tags/color-input.styl b/src/styl/tags/color-input.styl index 454f1c69d..4dbcbacef 100644 --- a/src/styl/tags/color-input.styl +++ b/src/styl/tags/color-input.styl @@ -6,7 +6,7 @@ box-sizing border-box max-width 10rem height 2rem - margin-top 0.5rem + margin-top 0 padding 0 0.5rem font-family mono font-size 0.75rem diff --git a/src/styl/tags/main-menu.styl b/src/styl/tags/main-menu.styl index 31d388d6c..2979b74ad 100644 --- a/src/styl/tags/main-menu.styl +++ b/src/styl/tags/main-menu.styl @@ -1,33 +1,33 @@ main-menu - position fixed - top 0 - left 0 - right 0 - bottom 0 - & > .flexrow > nav - flex-flow row wrap + position fixed + top 0 + left 0 + right 0 + bottom 0 + & > .flexrow > nav + flex-flow row wrap #fullscreen - flex 0 0 3rem + flex 0 0 3rem #app - flex 1 1 12rem + flex 1 1 12rem #mainnav - flex 1 1 60rem + flex 1 1 60rem body.maximized #mainnav - @media (max-width 1000px) - flex-wrap wrap + @media (max-width 1000px) + flex-wrap wrap body.restored - #mainnav - right 0 - #app - display none + #mainnav + right 0 + #app + display none -#mainnav, #app - border-radius 0 +#mainnav, #app, #fullscreen + border-radius 0 @media (max-width 1000px) - #mainnav span - display none - #mainnav i:first-child - margin-right 0 + #mainnav span + display none + #mainnav i:first-child + margin-right 0 diff --git a/src/styl/tags/texture-editor.styl b/src/styl/tags/texture-editor.styl index 4f8eca446..95f2abf3c 100644 --- a/src/styl/tags/texture-editor.styl +++ b/src/styl/tags/texture-editor.styl @@ -1,14 +1,9 @@ texture-editor .column width 16em - flex 1 .column, #atlas - position absolute - top 0 - bottom 0 padding 1em .column2 - right 0 .flexfix-body margin -1rem -1rem 0 padding 1rem @@ -21,6 +16,11 @@ texture-editor right 0 padding 0.5em 1em margin 0 -1rem -1rem +.texture-editor-aCanvasWrap + width 100% + height 100% + overflow scroll + position relative #textureviewdone bottom 0.5em @@ -36,6 +36,8 @@ texture-editor @media (max-height 680px) height 6em +#grahpspeed + margin-top 0.25rem #previewbgcolor position absolute @@ -48,12 +50,12 @@ texture-editor .textureview-tools position absolute - left 0 top 0.5em right 0.5em + .file + display inline-block .textureview-zoom position absolute - left 0 bottom 0.5em right 0.5em text-align right @@ -79,11 +81,15 @@ texture-editor #texturecolor margin-top 0.5em .texture-editor-anAtlas + position relative overflow auto - position absolute - top 0 - left 16em - right 16em - bottom 0 canvas - margin 1rem \ No newline at end of file + margin 1rem + +.aStripPointRow + * + margin 0 0.25rem 0 0 + &:last-child + margin 0 + & + & + margin-top 0.25rem \ No newline at end of file diff --git a/src/styl/themeDay.styl b/src/styl/themeDay.styl index 064e10618..58fdc46f2 100644 --- a/src/styl/themeDay.styl +++ b/src/styl/themeDay.styl @@ -14,7 +14,7 @@ shadamb = /* шрифты */ fonts = font = 'Open Sans', sans-serif, serif -font-mono = mono = Consolas, monospace +font-mono = mono = Iosevka, monospace br = 0.2rem iconsize = 1.5rem @@ -64,6 +64,7 @@ snow = #fafafa @require 'hvost.styl' @require '3rdParty/*.styl' +@require './../../app/node_modules/highlight.js/styles/tomorrow.css' @require 'common.styl' @require 'inputs.styl' diff --git a/src/styl/themeHorizon.styl b/src/styl/themeHorizon.styl index 8551ab49f..b9f3c8adf 100644 --- a/src/styl/themeHorizon.styl +++ b/src/styl/themeHorizon.styl @@ -1,102 +1,103 @@ -@charset "utf-8" - -// The minimum width of ct.js = 380px - -/* handy blocks */ -trans = - transition 0.35s ease all -transshort = - transition 0.15s ease all -shad = - box-shadow 0 0.1rem 0.2rem rgba(0, 0, 0, 0.5) -shadamb = - box-shadow 0 0 0.35rem rgba(0, 0, 0, 0.5) - -/* Fonts */ -fonts = font = 'Open Sans', sans-serif, serif -font-mono = mono = Consolas, monospace - -br = 0.2rem -iconsize = 1.5rem - -/* Basic colors & accents */ -black = #fff -white = #1C1E26 -act = #E9436D -acttext = act -accent1 = #E9436D -accent2 = #E95378 -error = #E95678 -red = error -success = #29D398 -green = success -warning = #FAB795 -orange = warning -blue = #26BBD9 -cyan = #59E1E3 - -theme = 'Horizon' -themeDark = true - -.error - color error -.success - color success -.warning - color warning - -bl = #252732 -bd = #2F3038 - -text = #D5D8DA -snow = mix(white, bl, 50%) - -/* Animations */ -@keyframes rotate - 100% - transform rotate(360deg) -@keyframes fadeOut - from - opacity 1 - visibility visible - to - opacity 0 - visibility hidden -.fadeout - animation forwards 0.5s linear fadeOut - -@require 'hvost.styl' - -@require '3rdParty/*.styl' - -@require 'common.styl' -@require 'inputs.styl' -@require 'typography.styl' -@require 'buildingBlocks.styl' -@require 'tabs.styl' - -button, -input[type="button"], -input[type="submit"], -input[type="reset"], -.button, -.selectbox - border-width 2px - -.view - background white - -.tabbed, .nav - border 0 -.nav li - border-right 0 - border-left 0 - &:hover, &.active - color black - -#moduleinfo .bigpower:not(.off) - border-color success - &:after - background success - +@charset "utf-8" + +// The minimum width of ct.js = 380px + +/* handy blocks */ +trans = + transition 0.35s ease all +transshort = + transition 0.15s ease all +shad = + box-shadow 0 0.1rem 0.2rem rgba(0, 0, 0, 0.5) +shadamb = + box-shadow 0 0 0.35rem rgba(0, 0, 0, 0.5) + +/* Fonts */ +fonts = font = 'Open Sans', sans-serif, serif +font-mono = mono = Iosevka, monospace + +br = 0.2rem +iconsize = 1.5rem + +/* Basic colors & accents */ +black = #fff +white = #1C1E26 +act = #E95378 +acttext = act +accent1 = #E95378 +accent2 = #E95378 +error = #E9436D +red = error +success = #29D398 +green = success +warning = #FAB795 +orange = warning +blue = #26BBD9 +cyan = #59E1E3 + +theme = 'Horizon' +themeDark = true + +.error + color error +.success + color success +.warning + color warning + +bl = #252732 +bd = #2F3038 + +text = #D5D8DA +snow = mix(white, bl, 50%) + +/* Animations */ +@keyframes rotate + 100% + transform rotate(360deg) +@keyframes fadeOut + from + opacity 1 + visibility visible + to + opacity 0 + visibility hidden +.fadeout + animation forwards 0.5s linear fadeOut + +@require 'hvost.styl' + +@require '3rdParty/*.styl' +@require './../../app/node_modules/highlight.js/styles/atom-one-dark.css' + +@require 'common.styl' +@require 'inputs.styl' +@require 'typography.styl' +@require 'buildingBlocks.styl' +@require 'tabs.styl' + +button, +input[type="button"], +input[type="submit"], +input[type="reset"], +.button, +.selectbox + border-width 2px + +.view + background white + +.tabbed, .nav + border 0 +.nav li + border-right 0 + border-left 0 + &:hover, &.active + color black + +#moduleinfo .bigpower:not(.off) + border-color success + &:after + background success + @require 'tags/*.styl' \ No newline at end of file diff --git a/src/styl/themeNight.styl b/src/styl/themeNight.styl index a0eb60604..4a0045afc 100644 --- a/src/styl/themeNight.styl +++ b/src/styl/themeNight.styl @@ -14,7 +14,7 @@ shadamb = /* шрифты */ fonts = font = 'Open Sans', sans-serif, serif -font-mono = mono = Consolas, monospace +font-mono = mono = Iosevka, monospace br = 0.2rem iconsize = 1.5rem @@ -66,6 +66,7 @@ snow = mix(white, bl, 50%) @require 'hvost.styl' @require '3rdParty/*.styl' +@require './../../app/node_modules/highlight.js/styles/atom-one-dark.css' @require 'common.styl' @require 'inputs.styl' diff --git a/src/styl/typography.styl b/src/styl/typography.styl index be72368b9..e360b1b9f 100644 --- a/src/styl/typography.styl +++ b/src/styl/typography.styl @@ -27,7 +27,7 @@ pre max-height 30rem code font-family font-mono - &.inline + &.inline, p > &, li > & padding 1.5px 0.5rem margin 0 0.25rem border-radius br