diff --git a/src/StarcounterClientFiles/bower-list.txt b/src/StarcounterClientFiles/bower-list.txt index 3d9f6e5..e3f22f1 100644 --- a/src/StarcounterClientFiles/bower-list.txt +++ b/src/StarcounterClientFiles/bower-list.txt @@ -14,7 +14,7 @@ starcounter-clientfiles D:\repos\apps\StarcounterClientFiles\src\StarcounterClie │ ├─┬ iron-resizable-behavior#2.1.1 (latest is 3.0.1) │ │ └── polymer not installed │ └── polymer not installed -├─┬ palindrom-client#7.2.0 (7.2.1 available) +├─┬ palindrom-client#7.2.1 │ └── Palindrom#5.1.3 ├── palindrom-error-catcher#1.1.0 ├── palindrom-redirect#1.0.1 @@ -26,10 +26,10 @@ starcounter-clientfiles D:\repos\apps\StarcounterClientFiles\src\StarcounterClie ├─┬ starcounter-include#5.2.0 │ └─┬ imported-template#3.4.0 │ └── juicy-html#4.0.0 -├─┬ uniform.css#0.8.0 (latest is 0.9.0) -│ ├── juicy-popover#2.1.0 (2.1.1 available) +├─┬ uniform.css#0.9.0 +│ ├── juicy-popover#2.1.1 │ ├── polymer not installed -│ ├─┬ vaadin-date-picker#3.3.0 (3.3.1 available) +│ ├─┬ vaadin-date-picker#3.3.1 │ │ ├─┬ iron-a11y-announcer#2.1.0 (latest is 3.0.2) │ │ │ └── polymer not installed │ │ ├─┬ iron-a11y-keys-behavior#2.1.1 (latest is 3.0.1) @@ -41,14 +41,14 @@ starcounter-clientfiles D:\repos\apps\StarcounterClientFiles\src\StarcounterClie │ │ ├── polymer not installed │ │ ├─┬ vaadin-button#2.1.0 │ │ │ ├── polymer not installed -│ │ │ ├─┬ vaadin-control-state-mixin#2.1.1 +│ │ │ ├─┬ vaadin-control-state-mixin#2.1.2 │ │ │ │ └── polymer not installed │ │ │ ├─┬ vaadin-element-mixin#2.1.2 │ │ │ │ ├── polymer not installed │ │ │ │ ├── vaadin-development-mode-detector#2.0.0 │ │ │ │ └─┬ vaadin-usage-statistics#2.0.1 │ │ │ │ └── vaadin-development-mode-detector#2.0.0 -│ │ │ ├─┬ vaadin-lumo-styles#1.3.1 (1.3.3 available) +│ │ │ ├─┬ vaadin-lumo-styles#1.3.3 │ │ │ │ ├─┬ iron-icon#2.1.0 (latest is 3.0.1) │ │ │ │ │ ├─┬ iron-flex-layout#2.0.3 (latest is 3.0.1) │ │ │ │ │ │ └── polymer not installed @@ -64,6 +64,7 @@ starcounter-clientfiles D:\repos\apps\StarcounterClientFiles\src\StarcounterClie │ │ │ │ └── polymer not installed │ │ │ └─┬ vaadin-themable-mixin#1.3.2 │ │ │ └── polymer not installed +│ │ ├─┬ vaadin-control-state-mixin#2.1.2 │ │ ├─┬ vaadin-control-state-mixin#2.1.1 (2.1.2 available) │ │ │ └── polymer not installed │ │ ├─┬ vaadin-element-mixin#2.1.2 @@ -71,49 +72,49 @@ starcounter-clientfiles D:\repos\apps\StarcounterClientFiles\src\StarcounterClie │ │ │ ├── vaadin-development-mode-detector#2.0.0 │ │ │ └─┬ vaadin-usage-statistics#2.0.1 │ │ │ └── vaadin-development-mode-detector#2.0.0 -│ │ ├── vaadin-lumo-styles#1.3.1 (1.3.3 available) +│ │ ├── vaadin-lumo-styles#1.3.3 │ │ ├── vaadin-material-styles#1.2.0 │ │ ├─┬ vaadin-overlay#3.2.1 │ │ │ ├── polymer not installed -│ │ │ ├── vaadin-lumo-styles#1.3.1 +│ │ │ ├── vaadin-lumo-styles#1.3.3 │ │ │ ├── vaadin-material-styles#1.2.0 │ │ │ └── vaadin-themable-mixin#1.3.2 -│ │ ├─┬ vaadin-text-field#2.1.3 (2.3.0-alpha1 available) +│ │ ├─┬ vaadin-text-field#2.1.4 │ │ │ ├── polymer not installed -│ │ │ ├─┬ vaadin-control-state-mixin#2.1.1 +│ │ │ ├─┬ vaadin-control-state-mixin#2.1.2 │ │ │ │ └── polymer not installed │ │ │ ├─┬ vaadin-element-mixin#2.1.2 │ │ │ │ ├── polymer not installed │ │ │ │ ├── vaadin-development-mode-detector#2.0.0 │ │ │ │ └─┬ vaadin-usage-statistics#2.0.1 │ │ │ │ └── vaadin-development-mode-detector#2.0.0 -│ │ │ ├── vaadin-lumo-styles#1.3.1 (1.3.3 available) +│ │ │ ├── vaadin-lumo-styles#1.3.3 │ │ │ ├── vaadin-material-styles#1.2.0 │ │ │ └── vaadin-themable-mixin#1.3.2 │ │ └── vaadin-themable-mixin#1.3.2 -│ ├─┬ vaadin-grid#5.2.1 (5.3.0-alpha3 available) +│ ├─┬ vaadin-grid#5.2.3 (5.3.0-alpha3 available) │ │ ├── iron-a11y-announcer#2.1.0 (latest is 3.0.2) │ │ ├── iron-a11y-keys-behavior#2.1.1 (latest is 3.0.1) │ │ ├── iron-resizable-behavior#2.1.1 (latest is 3.0.1) │ │ ├─┬ iron-scroll-target-behavior#2.1.1 (latest is 3.0.1) │ │ │ └── polymer not installed │ │ ├── polymer not installed -│ │ ├─┬ vaadin-checkbox#2.2.3 (2.2.4 available) +│ │ ├─┬ vaadin-checkbox#2.2.4 │ │ │ ├── polymer not installed -│ │ │ ├─┬ vaadin-control-state-mixin#2.1.1 +│ │ │ ├─┬ vaadin-control-state-mixin#2.1.2 │ │ │ │ └── polymer not installed │ │ │ ├─┬ vaadin-element-mixin#2.1.2 │ │ │ │ ├── polymer not installed │ │ │ │ ├── vaadin-development-mode-detector#2.0.0 │ │ │ │ └─┬ vaadin-usage-statistics#2.0.1 │ │ │ │ └── vaadin-development-mode-detector#2.0.0 -│ │ │ ├── vaadin-lumo-styles#1.3.1 +│ │ │ ├── vaadin-lumo-styles#1.3.3 │ │ │ ├── vaadin-material-styles#1.2.0 │ │ │ └── vaadin-themable-mixin#1.3.2 │ │ ├── vaadin-element-mixin#2.1.2 -│ │ ├── vaadin-lumo-styles#1.3.1 +│ │ ├── vaadin-lumo-styles#1.3.3 │ │ ├── vaadin-material-styles#1.2.0 -│ │ ├── vaadin-text-field#2.1.3 (2.3.0-alpha1 available) +│ │ ├── vaadin-text-field#2.1.4 │ │ └── vaadin-themable-mixin#1.3.2 │ └── webcomponentsjs#1.2.7 └── webcomponentsjs#1.2.7 (latest is 2.2.0) diff --git a/src/StarcounterClientFiles/bower.json b/src/StarcounterClientFiles/bower.json index 4b1ba87..efbc18a 100644 --- a/src/StarcounterClientFiles/bower.json +++ b/src/StarcounterClientFiles/bower.json @@ -8,7 +8,7 @@ "starcounter-include": "^5.2.0", "polymer-source": "polymer#^2.6.1", "webcomponentsjs": "^1.2.7", - "uniform.css": "Starcounter/uniform#^0.8.0", + "uniform.css": "Starcounter/uniform#^0.9.0", "enlighted-link": "^0.1.0", "palindrom-error-catcher": "^1.0.0", "slot-all": "^0.1.0" diff --git a/src/StarcounterClientFiles/wwwroot/sys/iron-a11y-keys-behavior/.bower.json b/src/StarcounterClientFiles/wwwroot/sys/iron-a11y-keys-behavior/.bower.json index ffa1fc6..5d8f1f6 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/iron-a11y-keys-behavior/.bower.json +++ b/src/StarcounterClientFiles/wwwroot/sys/iron-a11y-keys-behavior/.bower.json @@ -59,6 +59,6 @@ "commit": "b7e78a4a8bdd857780ecd8b54852bb27dbf8f216" }, "_source": "https://github.com/PolymerElements/iron-a11y-keys-behavior.git", - "_target": "^2.0.0", - "_originalSource": "iron-a11y-keys-behavior" + "_target": "1 - 2", + "_originalSource": "PolymerElements/iron-a11y-keys-behavior" } \ No newline at end of file diff --git a/src/StarcounterClientFiles/wwwroot/sys/iron-resizable-behavior/.bower.json b/src/StarcounterClientFiles/wwwroot/sys/iron-resizable-behavior/.bower.json index 69f5694..9581700 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/iron-resizable-behavior/.bower.json +++ b/src/StarcounterClientFiles/wwwroot/sys/iron-resizable-behavior/.bower.json @@ -53,6 +53,6 @@ "commit": "719d68affd8293b026c6456e754773b31a27712f" }, "_source": "https://github.com/PolymerElements/iron-resizable-behavior.git", - "_target": "^2.0.0", - "_originalSource": "iron-resizable-behavior" + "_target": "1 - 2", + "_originalSource": "PolymerElements/iron-resizable-behavior" } \ No newline at end of file diff --git a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/.bower.json b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/.bower.json index 8775318..5f4a3c3 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/.bower.json +++ b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/.bower.json @@ -1,6 +1,6 @@ { "name": "juicy-popover", - "version": "2.1.0", + "version": "2.1.1", "description": "Custom Element that expands an area when clicked on a handle", "homepage": "https://github.com/Juicy/juicy-popover", "license": "MIT", @@ -22,11 +22,11 @@ "webcomponentsjs": "^1.0.0", "web-component-tester": "^6.4.1" }, - "_release": "2.1.0", + "_release": "2.1.1", "_resolution": { "type": "version", - "tag": "2.1.0", - "commit": "289ad22eb555a8f02e024d14e94856dd3d9fb5c6" + "tag": "2.1.1", + "commit": "a0c84347aef4c51d7480e48a5b543357401fd742" }, "_source": "https://github.com/Juicy/juicy-popover.git", "_target": "^2.1.0", diff --git a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/CONTRIBUTING.md b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/CONTRIBUTING.md index beb83f1..6e13280 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/CONTRIBUTING.md +++ b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/CONTRIBUTING.md @@ -33,4 +33,26 @@ In order to develop it locally we suggest to use [polyserve](https://npmjs.com/p 3. Commit your changes: `git commit -m 'Add some feature'` 4. Push to the branch: `git push origin my-new-feature` 5. Open corresponding issue if needed -6. Submit a pull request :D \ No newline at end of file +6. Submit a pull request :D + +## Unit tests + +All Juicy custom elements projects use [`web-component-tester`](https://github.com/Polymer/web-component-tester) for unit tests. +The [`polyserve`](https://github.com/PolymerLabs/polyserve) utility is helpful for [running tests in the browser](#developing-the-element). + +### Running element unit tests from CLI + +To run the element unit tests from CLI, you need to: + +0. Install `web-component-tester` globally: `npm install -g web-component-tester` +1. Clone the element repo. +2. Install the dependencies. `bower install` +3. Run the tests: `wct` (be patient - the first run might take 5 minutes to download the Selenium framework) + +#### Configuring `web-component-tester` + +By default, `web-component-tester` runs tests on all installed browsers. You can configure it +to run tests on a subset of available browsers, or to run tests remotely using Sauce Labs. + +See the [`web-component-tester` README](https://github.com/Polymer/web-component-tester) for +information on configuring the tool. diff --git a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/bower.json b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/bower.json index 96e8df5..cafd951 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/bower.json +++ b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/bower.json @@ -1,6 +1,6 @@ { "name": "juicy-popover", - "version": "2.1.0", + "version": "2.1.1", "description": "Custom Element that expands an area when clicked on a handle", "homepage": "https://github.com/Juicy/juicy-popover", "license": "MIT", diff --git a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/package.json b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/package.json index a772993..c9320ad 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/package.json +++ b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/package.json @@ -1,17 +1,14 @@ { "name": "juicy-popover", - "version": "2.1.0", + "version": "2.1.1", "description": "Custom Element that expands an area when clicked on a handle", "main": "src/juicy-popover.html", "dependencies": { - "grunt": "^1.0.1", + "grunt": "^1.0.3", "grunt-bump": "^0.8.0" }, "scripts": { - "test": "wct --skip-plugin sauce" - }, - "devDependencies": { - "web-component-tester": "^6.4.1" + "test": "wct --skip-plugin sauce" }, "repository": { "type": "git", diff --git a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/src/juicy-popover.html b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/src/juicy-popover.html index a946635..cf86915 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/src/juicy-popover.html +++ b/src/StarcounterClientFiles/wwwroot/sys/juicy-popover/src/juicy-popover.html @@ -1,7 +1,7 @@ - + + + - - - + // `params.filters` format: [{path: 'lastName', direction: 'asc'}, ...]; + params.filters.forEach(function(filter) { + url += '&filters[' + filter.path + ']=' + encodeURIComponent(filter.value); + }); + xhr.open('GET', url, true); + xhr.send(); + }; + }); + + + - - - + } + customElements.define(GridFilteringDemos.is, GridFilteringDemos); + + diff --git a/src/StarcounterClientFiles/wwwroot/sys/vaadin-grid/demo/grid-row-details-demos.html b/src/StarcounterClientFiles/wwwroot/sys/vaadin-grid/demo/grid-row-details-demos.html index 95392b6..0d1751c 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/vaadin-grid/demo/grid-row-details-demos.html +++ b/src/StarcounterClientFiles/wwwroot/sys/vaadin-grid/demo/grid-row-details-demos.html @@ -6,7 +6,7 @@ } -

Row Details

+

Row Details

Set a rowDetailsRenderer to enable row details feature. Adding items to grid.detailsOpenedItems array or invoking openItemDetails(item) @@ -138,10 +138,6 @@

Row Details with Polymer Template

- - - - @@ -110,7 +112,9 @@

Asynchronous Custom Validator

} } - customElements.define(ChemicalElement.is, ChemicalElement); + if (!customElements.get(ChemicalElement.is)) { + customElements.define(ChemicalElement.is, ChemicalElement); + } }); diff --git a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/package.json b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/package.json index 78faa59..6800db9 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/package.json +++ b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/package.json @@ -1,6 +1,6 @@ { "name": "@vaadin/vaadin-text-field", - "version": "2.1.3", + "version": "2.1.4", "description": "vaadin-text-field", "main": "vaadin-text-field.html", "repository": "vaadin/vaadin-text-field", diff --git a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-password-field.html b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-password-field.html index dc5e495..aa34b3d 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-password-field.html +++ b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-password-field.html @@ -80,7 +80,7 @@ } static get version() { - return '2.1.3'; + return '2.1.4'; } static get properties() { diff --git a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-area.html b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-area.html index ae1d1f9..45ee0b5 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-area.html +++ b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-area.html @@ -141,7 +141,7 @@ } static get version() { - return '2.1.3'; + return '2.1.4'; } static get observers() { @@ -186,7 +186,23 @@ input.style.removeProperty('max-width'); inputField.style.removeProperty('display'); inputField.scrollTop = scrollTop; + + if (this.__previousInputHeight && this.__previousInputHeight !== inputHeight) { + this.dispatchEvent( + new CustomEvent('iron-resize', { + bubbles: true + }) + ); + } + + this.__previousInputHeight = inputHeight; } + + /** + * Fired when the text-area height changes. + * + * @event iron-resize + */ } customElements.define(TextAreaElement.is, TextAreaElement); diff --git a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-field-mixin.html b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-field-mixin.html index 601ab30..3d90c22 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-field-mixin.html +++ b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-field-mixin.html @@ -236,7 +236,7 @@ } get focusElement() { - return this.root.querySelector('[part=value]'); + return this.root && this.root.querySelector('[part=value]'); } _onInput(e) { diff --git a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-field.html b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-field.html index 18b3572..72e56a0 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-field.html +++ b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/src/vaadin-text-field.html @@ -127,7 +127,7 @@ } static get version() { - return '2.1.3'; + return '2.1.4'; } static get properties() { diff --git a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/test/text-area.html b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/test/text-area.html index 422267c..38fc419 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/test/text-area.html +++ b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/test/text-area.html @@ -291,5 +291,36 @@ )); }); }); + + describe('resize', () => { + let textArea, spy; + + beforeEach(() => { + textArea = fixture('default'); + spy = sinon.spy(); + textArea.addEventListener('iron-resize', spy); + }); + + it('should not dispatch `iron-resize` event on init', () => { + expect(spy.callCount).to.equal(0); + }); + + it('should dispatch `iron-resize` event on height change', () => { + textArea.value = ` + there + should + be + a + lot + of + rows`; + expect(spy.callCount).to.equal(1); + }); + + it('should not dispatch `iron-resize` event on value change if height did not change', () => { + textArea.value = 'just 1 row'; + expect(spy.callCount).to.equal(0); + }); + }); diff --git a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/test/text-field.html b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/test/text-field.html index c9d821d..0918428 100644 --- a/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/test/text-field.html +++ b/src/StarcounterClientFiles/wwwroot/sys/vaadin-text-field/test/text-field.html @@ -226,5 +226,12 @@ }); }); }); + + describe('methods', function() { + it('should not throw an error when using focus() to a newly created element', () => { + // No expect needed as an error is thrown when focusing undefined element + document.createElement('vaadin-text-field').focus(); + }); + });