@vaadin/avatar-group 23.0.0-alpha1 → 23.0.0-alpha2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +10 -11
- package/src/vaadin-avatar-group.js +13 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vaadin/avatar-group",
|
|
3
|
-
"version": "23.0.0-
|
|
3
|
+
"version": "23.0.0-alpha2",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -34,21 +34,20 @@
|
|
|
34
34
|
],
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@polymer/iron-a11y-announcer": "^3.0.0",
|
|
37
|
-
"@polymer/iron-resizable-behavior": "^3.0.0",
|
|
38
37
|
"@polymer/polymer": "^3.0.0",
|
|
39
|
-
"@vaadin/avatar": "23.0.0-
|
|
40
|
-
"@vaadin/component-base": "23.0.0-
|
|
41
|
-
"@vaadin/item": "23.0.0-
|
|
42
|
-
"@vaadin/list-box": "23.0.0-
|
|
43
|
-
"@vaadin/vaadin-lumo-styles": "23.0.0-
|
|
44
|
-
"@vaadin/vaadin-material-styles": "23.0.0-
|
|
45
|
-
"@vaadin/vaadin-overlay": "23.0.0-
|
|
46
|
-
"@vaadin/vaadin-themable-mixin": "23.0.0-
|
|
38
|
+
"@vaadin/avatar": "23.0.0-alpha2",
|
|
39
|
+
"@vaadin/component-base": "23.0.0-alpha2",
|
|
40
|
+
"@vaadin/item": "23.0.0-alpha2",
|
|
41
|
+
"@vaadin/list-box": "23.0.0-alpha2",
|
|
42
|
+
"@vaadin/vaadin-lumo-styles": "23.0.0-alpha2",
|
|
43
|
+
"@vaadin/vaadin-material-styles": "23.0.0-alpha2",
|
|
44
|
+
"@vaadin/vaadin-overlay": "23.0.0-alpha2",
|
|
45
|
+
"@vaadin/vaadin-themable-mixin": "23.0.0-alpha2"
|
|
47
46
|
},
|
|
48
47
|
"devDependencies": {
|
|
49
48
|
"@esm-bundle/chai": "^4.3.4",
|
|
50
49
|
"@vaadin/testing-helpers": "^0.3.2",
|
|
51
50
|
"sinon": "^9.2.1"
|
|
52
51
|
},
|
|
53
|
-
"gitHead": "
|
|
52
|
+
"gitHead": "070f586dead02ca41b66717820c647f48bf1665f"
|
|
54
53
|
}
|
|
@@ -8,8 +8,6 @@ import '@vaadin/item/src/vaadin-item.js';
|
|
|
8
8
|
import './vaadin-avatar-group-list-box.js';
|
|
9
9
|
import './vaadin-avatar-group-overlay.js';
|
|
10
10
|
import { IronA11yAnnouncer } from '@polymer/iron-a11y-announcer/iron-a11y-announcer.js';
|
|
11
|
-
import { IronResizableBehavior } from '@polymer/iron-resizable-behavior/iron-resizable-behavior.js';
|
|
12
|
-
import { mixinBehaviors } from '@polymer/polymer/lib/legacy/class.js';
|
|
13
11
|
import { calculateSplices } from '@polymer/polymer/lib/utils/array-splice.js';
|
|
14
12
|
import { afterNextRender } from '@polymer/polymer/lib/utils/render-status.js';
|
|
15
13
|
import { html, PolymerElement } from '@polymer/polymer/polymer-element.js';
|
|
@@ -61,7 +59,7 @@ const MINIMUM_DISPLAYED_AVATARS = 2;
|
|
|
61
59
|
* @mixes ElementMixin
|
|
62
60
|
* @mixes ThemableMixin
|
|
63
61
|
*/
|
|
64
|
-
class AvatarGroup extends ElementMixin(ThemableMixin(
|
|
62
|
+
class AvatarGroup extends ElementMixin(ThemableMixin(PolymerElement)) {
|
|
65
63
|
static get template() {
|
|
66
64
|
return html`
|
|
67
65
|
<style>
|
|
@@ -284,7 +282,8 @@ class AvatarGroup extends ElementMixin(ThemableMixin(mixinBehaviors([IronResizab
|
|
|
284
282
|
|
|
285
283
|
this.__boundSetPosition = this.__setPosition.bind(this);
|
|
286
284
|
|
|
287
|
-
this.
|
|
285
|
+
this.__resizeObserver = new ResizeObserver(() => this._onResize());
|
|
286
|
+
this.__resizeObserver.observe(this);
|
|
288
287
|
|
|
289
288
|
this._overlayElement = this.shadowRoot.querySelector('vaadin-avatar-group-overlay');
|
|
290
289
|
|
|
@@ -594,6 +593,16 @@ class AvatarGroup extends ElementMixin(ThemableMixin(mixinBehaviors([IronResizab
|
|
|
594
593
|
this._overlayElement.style.top = btnRect.bottom + 'px';
|
|
595
594
|
}
|
|
596
595
|
}
|
|
596
|
+
|
|
597
|
+
/**
|
|
598
|
+
* @deprecated Since Vaadin 23, `notifyResize()` is deprecated. The component uses a
|
|
599
|
+
* ResizeObserver internally and doesn't need to be explicitly notified of resizes.
|
|
600
|
+
*/
|
|
601
|
+
notifyResize() {
|
|
602
|
+
console.warn(
|
|
603
|
+
`WARNING: Since Vaadin 23, notifyResize() is deprecated. The component uses a ResizeObserver internally and doesn't need to be explicitly notified of resizes.`
|
|
604
|
+
);
|
|
605
|
+
}
|
|
597
606
|
}
|
|
598
607
|
|
|
599
608
|
customElements.define(AvatarGroup.is, AvatarGroup);
|