Skip to content

Commit bf2a978

Browse files
committed
feat!: vaadin 24 compatible version
1 parent 5ae3823 commit bf2a978

File tree

5 files changed

+19
-20
lines changed

5 files changed

+19
-20
lines changed

demo/demo-icons.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
/* eslint-disable max-len */
22
import { html } from '@polymer/polymer/polymer-element.js';
33
import { registerStyles, css } from '@vaadin/vaadin-themable-mixin/register-styles.js';
4-
import '@polymer/iron-iconset-svg';
4+
import '@vaadin/vaadin-lumo-styles/vaadin-iconset.js'
55

66
registerStyles(
77
'vaadin-button',
88
css`
9-
[part] ::slotted(iron-icon[icon^='vcf-demo:']) {
9+
[part] ::slotted(vaadin-icon[icon^='vcf-demo:']) {
1010
padding: 0.25em;
1111
box-sizing: border-box !important;
1212
}
1313
`
1414
);
1515

1616
const template = html`
17-
<iron-iconset-svg name="vcf-demo" size="16">
17+
<vaadin-iconset name="vcf-demo" size="16">
1818
<svg>
1919
<defs>
2020
<g id="copy">
@@ -27,7 +27,7 @@ const template = html`
2727
</g>
2828
</defs>
2929
</svg>
30-
</iron-iconset-svg>
30+
</vaadin-iconset>
3131
`;
3232

3333
document.head.appendChild(template.content);

demo/demo.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ window.addEventListener('WebComponentsReady', () => {
1818
if (window.innerWidth > 768) {
1919
const codeContainerStyles = document.createElement('style');
2020
const copyVaadinButton = document.createElement('vaadin-button');
21-
const copyIcon = document.createElement('iron-icon');
21+
const copyIcon = document.createElement('vaadin-icon');
2222
// Custom <demo-snippet> styles
2323
element.shadowRoot.appendChild(codeContainerStyles);
2424
codeContainerStyles.innerHTML = mainCodeContainerStyles.innerHTML;
@@ -30,7 +30,7 @@ window.addEventListener('WebComponentsReady', () => {
3030
copyVaadinButton.addEventListener('click', () => {
3131
document
3232
.querySelectorAll('demo-snippet')
33-
.forEach(element => element.shadowRoot.querySelector('iron-icon').setAttribute('icon', 'vcf-demo:copy'));
33+
.forEach(element => element.shadowRoot.querySelector('vaadin-icon').setAttribute('icon', 'vcf-demo:copy'));
3434
copyButton.click();
3535
copyIcon.setAttribute('icon', 'lumo:checkmark');
3636
});

demo/index.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@
162162
<p>Go to <a href="./foo.html">foo</a></p>
163163
<a id="api" slot="header" href="/api/#/elements/Vaadin.VcfAnchorNav">
164164
<vaadin-button theme="tertiary" class="nav-btn">
165-
<iron-icon icon="lumo:angle-right" slot="suffix"></iron-icon>
165+
<vaadin-icon icon="lumo:angle-right" slot="suffix"></vaadin-icon>
166166
API
167167
</vaadin-button>
168168
</a>
@@ -321,14 +321,14 @@ <h2 slot="header" class="main">Custom Tabs</h2>
321321
<!-- Create custom <vaadin-tab> with "id" equal to "tab-id" of the linked section. -->
322322
<vaadin-tab id="custom-tab-3">
323323
<div class="vertical-tab">
324-
<iron-icon icon="lumo:chevron-up"></iron-icon>
324+
<vaadin-icon icon="lumo:chevron-up"></vaadin-icon>
325325
Custom Tab 3
326326
</div>
327327
</vaadin-tab>
328328
<vaadin-tab id="custom-tab-4">
329329
<div class="vertical-tab">
330330
Custom Tab 4
331-
<iron-icon icon="lumo:chevron-down"></iron-icon>
331+
<vaadin-icon icon="lumo:chevron-down"></vaadin-icon>
332332
</div>
333333
</vaadin-tab>
334334
</vaadin-tabs>
@@ -337,13 +337,13 @@ <h2 slot="header" class="main">Custom Tabs</h2>
337337
<!-- Create custom tabs using the "tab" slot of the section. -->
338338
<vaadin-tab slot="tab">
339339
Custom Tab 1
340-
<iron-icon icon="lumo:chevron-right"></iron-icon>
340+
<vaadin-icon icon="lumo:chevron-right"></vaadin-icon>
341341
</vaadin-tab>
342342
Section 1 content.
343343
</vcf-anchor-nav-section>
344344
<vcf-anchor-nav-section>
345345
<vaadin-tab slot="tab">
346-
<iron-icon icon="lumo:chevron-left"></iron-icon>
346+
<vaadin-icon icon="lumo:chevron-left"></vaadin-icon>
347347
Custom Tab 2
348348
</vaadin-tab>
349349
Section 2 content.

package.json

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@vaadin-component-factory/vcf-anchor-nav",
3-
"version": "23.4.0",
3+
"version": "3.0.0",
44
"description": "Component with tabs used as anchor navigation and content sections. Automates the linking of tabs and sections.",
55
"main": "vcf-anchor-nav.js",
66
"author": "Vaadin Ltd",
@@ -45,10 +45,10 @@
4545
"dependencies": {
4646
"@juggle/resize-observer": "^3.1.3",
4747
"@polymer/polymer": "^3.0.0",
48-
"@vaadin/component-base": "^23.3.1",
49-
"@vaadin/tabs": "^23.3.1",
50-
"@vaadin/vaadin-lumo-styles": "^23.3.1",
51-
"@vaadin/vaadin-themable-mixin": "^23.3.1",
48+
"@vaadin/component-base": "^24.1.1",
49+
"@vaadin/tabs": "^24.1.1",
50+
"@vaadin/vaadin-lumo-styles": "^24.1.1",
51+
"@vaadin/vaadin-themable-mixin": "^24.1.1",
5252
"intersection-observer": "^0.10.0",
5353
"smoothscroll-polyfill": "^0.4.4",
5454
"stickyfilljs": "^2.1.0"
@@ -59,13 +59,12 @@
5959
"@babel/preset-env": "^7.5.5",
6060
"@polymer/iron-component-page": "^4.0.1",
6161
"@polymer/iron-demo-helpers": "^3.0.0-pre.19",
62-
"@polymer/iron-iconset-svg": "^3.0.1",
6362
"@polymer/test-fixture": "^4.0.2",
6463
"@rollup/plugin-commonjs": "^11.1.0",
6564
"@rollup/plugin-node-resolve": "^7.1.3",
6665
"@vaadin-component-factory/vcf-element-util": "^0.2.8",
67-
"@vaadin/button": "^23.3.1",
68-
"@vaadin/text-field": "^23.3.1",
66+
"@vaadin/button": "^24.1.1",
67+
"@vaadin/text-field": "^24.1.1",
6968
"@webcomponents/webcomponentsjs": "^2.0.0",
7069
"babel-eslint": "^10.0.2",
7170
"babel-loader": "^8.0.6",

src/vcf-anchor-nav.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ export class AnchorNavElement extends ElementMixin(ThemableMixin(PolymerElement)
148148
}
149149

150150
static get version() {
151-
return '23.4.0';
151+
return '3.0.0';
152152
}
153153

154154
static get properties() {

0 commit comments

Comments
 (0)