@vaadin/email-field 25.0.0-alpha9 → 25.0.0-beta2

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vaadin/email-field",
3
- "version": "25.0.0-alpha9",
3
+ "version": "25.0.0-beta2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -21,9 +21,6 @@
21
21
  "type": "module",
22
22
  "files": [
23
23
  "src",
24
- "!src/styles/*-base-styles.d.ts",
25
- "!src/styles/*-base-styles.js",
26
- "theme",
27
24
  "vaadin-*.d.ts",
28
25
  "vaadin-*.js",
29
26
  "web-types.json",
@@ -36,21 +33,21 @@
36
33
  "web-component"
37
34
  ],
38
35
  "dependencies": {
39
- "@vaadin/component-base": "25.0.0-alpha9",
40
- "@vaadin/text-field": "25.0.0-alpha9",
41
- "@vaadin/vaadin-lumo-styles": "25.0.0-alpha9",
42
- "@vaadin/vaadin-themable-mixin": "25.0.0-alpha9",
36
+ "@vaadin/component-base": "25.0.0-beta2",
37
+ "@vaadin/text-field": "25.0.0-beta2",
38
+ "@vaadin/vaadin-themable-mixin": "25.0.0-beta2",
43
39
  "lit": "^3.0.0"
44
40
  },
45
41
  "devDependencies": {
46
- "@vaadin/chai-plugins": "25.0.0-alpha9",
47
- "@vaadin/test-runner-commands": "25.0.0-alpha9",
42
+ "@vaadin/chai-plugins": "25.0.0-beta2",
43
+ "@vaadin/test-runner-commands": "25.0.0-beta2",
48
44
  "@vaadin/testing-helpers": "^2.0.0",
49
- "sinon": "^18.0.0"
45
+ "@vaadin/vaadin-lumo-styles": "25.0.0-beta2",
46
+ "sinon": "^21.0.0"
50
47
  },
51
48
  "web-types": [
52
49
  "web-types.json",
53
50
  "web-types.lit.json"
54
51
  ],
55
- "gitHead": "bbe4720721e0955ffc87a79b412bee38b1f0eb1e"
52
+ "gitHead": "e078f8371ae266f05c7ca1ec25686cc489c83f24"
56
53
  }
@@ -48,8 +48,35 @@ export interface EmailFieldEventMap extends HTMLElementEventMap, EmailFieldCusto
48
48
  *
49
49
  * ### Styling
50
50
  *
51
- * `<vaadin-email-field>` provides the same set of shadow DOM parts and state attributes as `<vaadin-text-field>`.
52
- * See [`<vaadin-text-field>`](#/elements/vaadin-text-field) for the styling documentation.
51
+ * The following shadow DOM parts are available for styling:
52
+ *
53
+ * Part name | Description
54
+ * ---------------------|----------------
55
+ * `label` | The label element
56
+ * `input-field` | The element that wraps prefix, value and suffix
57
+ * `field-button` | Set on the clear button
58
+ * `clear-button` | The clear button
59
+ * `error-message` | The error message element
60
+ * `helper-text` | The helper text element wrapper
61
+ * `required-indicator` | The `required` state indicator element
62
+ *
63
+ * The following state attributes are available for styling:
64
+ *
65
+ * Attribute | Description
66
+ * ---------------------|---------------------------------
67
+ * `disabled` | Set when the element is disabled
68
+ * `has-value` | Set when the element has a value
69
+ * `has-label` | Set when the element has a label
70
+ * `has-helper` | Set when the element has helper text or slot
71
+ * `has-error-message` | Set when the element has an error message
72
+ * `has-tooltip` | Set when the element has a slotted tooltip
73
+ * `invalid` | Set when the element is invalid
74
+ * `input-prevented` | Temporarily set when invalid input is prevented
75
+ * `focused` | Set when the element is focused
76
+ * `focus-ring` | Set when the element is keyboard focused
77
+ * `readonly` | Set when the element is readonly
78
+ *
79
+ * Note, the `input-prevented` state attribute is only supported when `allowedCharPattern` is set.
53
80
  *
54
81
  * See [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.
55
82
  *
@@ -5,7 +5,7 @@
5
5
  */
6
6
  import { defineCustomElement } from '@vaadin/component-base/src/define.js';
7
7
  import { TextField } from '@vaadin/text-field/src/vaadin-text-field.js';
8
- import { emailFieldStyles } from './styles/vaadin-email-field-core-styles.js';
8
+ import { emailFieldStyles } from './styles/vaadin-email-field-base-styles.js';
9
9
 
10
10
  /**
11
11
  * `<vaadin-email-field>` is a Web Component for email field control in forms.
@@ -16,8 +16,35 @@ import { emailFieldStyles } from './styles/vaadin-email-field-core-styles.js';
16
16
  *
17
17
  * ### Styling
18
18
  *
19
- * `<vaadin-email-field>` provides the same set of shadow DOM parts and state attributes as `<vaadin-text-field>`.
20
- * See [`<vaadin-text-field>`](#/elements/vaadin-text-field) for the styling documentation.
19
+ * The following shadow DOM parts are available for styling:
20
+ *
21
+ * Part name | Description
22
+ * ---------------------|----------------
23
+ * `label` | The label element
24
+ * `input-field` | The element that wraps prefix, value and suffix
25
+ * `field-button` | Set on the clear button
26
+ * `clear-button` | The clear button
27
+ * `error-message` | The error message element
28
+ * `helper-text` | The helper text element wrapper
29
+ * `required-indicator` | The `required` state indicator element
30
+ *
31
+ * The following state attributes are available for styling:
32
+ *
33
+ * Attribute | Description
34
+ * ---------------------|---------------------------------
35
+ * `disabled` | Set when the element is disabled
36
+ * `has-value` | Set when the element has a value
37
+ * `has-label` | Set when the element has a label
38
+ * `has-helper` | Set when the element has helper text or slot
39
+ * `has-error-message` | Set when the element has an error message
40
+ * `has-tooltip` | Set when the element has a slotted tooltip
41
+ * `invalid` | Set when the element is invalid
42
+ * `input-prevented` | Temporarily set when invalid input is prevented
43
+ * `focused` | Set when the element is focused
44
+ * `focus-ring` | Set when the element is keyboard focused
45
+ * `readonly` | Set when the element is readonly
46
+ *
47
+ * Note, the `input-prevented` state attribute is only supported when `allowedCharPattern` is set.
21
48
  *
22
49
  * See [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.
23
50
  *
@@ -1,3 +1,3 @@
1
- import './theme/lumo/vaadin-email-field.js';
1
+ import './src/vaadin-email-field.js';
2
2
 
3
3
  export * from './src/vaadin-email-field.js';
package/web-types.json CHANGED
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/email-field",
4
- "version": "25.0.0-alpha9",
4
+ "version": "25.0.0-beta2",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
8
8
  "elements": [
9
9
  {
10
10
  "name": "vaadin-email-field",
11
- "description": "`<vaadin-email-field>` is a Web Component for email field control in forms.\n\n```html\n<vaadin-email-field label=\"Email\"></vaadin-email-field>\n```\n\n### Styling\n\n`<vaadin-email-field>` provides the same set of shadow DOM parts and state attributes as `<vaadin-text-field>`.\nSee [`<vaadin-text-field>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha9/#/elements/vaadin-text-field) for the styling documentation.\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.",
11
+ "description": "`<vaadin-email-field>` is a Web Component for email field control in forms.\n\n```html\n<vaadin-email-field label=\"Email\"></vaadin-email-field>\n```\n\n### Styling\n\nThe following shadow DOM parts are available for styling:\n\nPart name | Description\n---------------------|----------------\n`label` | The label element\n`input-field` | The element that wraps prefix, value and suffix\n`field-button` | Set on the clear button\n`clear-button` | The clear button\n`error-message` | The error message element\n`helper-text` | The helper text element wrapper\n`required-indicator` | The `required` state indicator element\n\nThe following state attributes are available for styling:\n\nAttribute | Description\n---------------------|---------------------------------\n`disabled` | Set when the element is disabled\n`has-value` | Set when the element has a value\n`has-label` | Set when the element has a label\n`has-helper` | Set when the element has helper text or slot\n`has-error-message` | Set when the element has an error message\n`has-tooltip` | Set when the element has a slotted tooltip\n`invalid` | Set when the element is invalid\n`input-prevented` | Temporarily set when invalid input is prevented\n`focused` | Set when the element is focused\n`focus-ring` | Set when the element is keyboard focused\n`readonly` | Set when the element is readonly\n\nNote, the `input-prevented` state attribute is only supported when `allowedCharPattern` is set.\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.",
12
12
  "attributes": [
13
13
  {
14
14
  "name": "disabled",
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/email-field",
4
- "version": "25.0.0-alpha9",
4
+ "version": "25.0.0-beta2",
5
5
  "description-markup": "markdown",
6
6
  "framework": "lit",
7
7
  "framework-config": {
@@ -16,7 +16,7 @@
16
16
  "elements": [
17
17
  {
18
18
  "name": "vaadin-email-field",
19
- "description": "`<vaadin-email-field>` is a Web Component for email field control in forms.\n\n```html\n<vaadin-email-field label=\"Email\"></vaadin-email-field>\n```\n\n### Styling\n\n`<vaadin-email-field>` provides the same set of shadow DOM parts and state attributes as `<vaadin-text-field>`.\nSee [`<vaadin-text-field>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha9/#/elements/vaadin-text-field) for the styling documentation.\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.",
19
+ "description": "`<vaadin-email-field>` is a Web Component for email field control in forms.\n\n```html\n<vaadin-email-field label=\"Email\"></vaadin-email-field>\n```\n\n### Styling\n\nThe following shadow DOM parts are available for styling:\n\nPart name | Description\n---------------------|----------------\n`label` | The label element\n`input-field` | The element that wraps prefix, value and suffix\n`field-button` | Set on the clear button\n`clear-button` | The clear button\n`error-message` | The error message element\n`helper-text` | The helper text element wrapper\n`required-indicator` | The `required` state indicator element\n\nThe following state attributes are available for styling:\n\nAttribute | Description\n---------------------|---------------------------------\n`disabled` | Set when the element is disabled\n`has-value` | Set when the element has a value\n`has-label` | Set when the element has a label\n`has-helper` | Set when the element has helper text or slot\n`has-error-message` | Set when the element has an error message\n`has-tooltip` | Set when the element has a slotted tooltip\n`invalid` | Set when the element is invalid\n`input-prevented` | Temporarily set when invalid input is prevented\n`focused` | Set when the element is focused\n`focus-ring` | Set when the element is keyboard focused\n`readonly` | Set when the element is readonly\n\nNote, the `input-prevented` state attribute is only supported when `allowedCharPattern` is set.\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.",
20
20
  "extension": true,
21
21
  "attributes": [
22
22
  {
@@ -1,8 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright (c) 2021 - 2025 Vaadin Ltd.
4
- * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
- */
6
- import type { CSSResult } from 'lit';
7
-
8
- export const emailFieldStyles: CSSResult;
@@ -1,18 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright (c) 2021 - 2025 Vaadin Ltd.
4
- * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
- */
6
- import { css } from 'lit';
7
-
8
- // See https://github.com/vaadin/vaadin-text-field/issues/466
9
- export const emailFieldStyles = css`
10
- :host([dir='rtl']) [part='input-field'] {
11
- direction: ltr;
12
- }
13
-
14
- :host([dir='rtl']) [part='input-field'] ::slotted(input)::placeholder {
15
- direction: rtl;
16
- text-align: left;
17
- }
18
- `;
@@ -1 +0,0 @@
1
- export {};
@@ -1,21 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright (c) 2021 - 2025 Vaadin Ltd.
4
- * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
- */
6
- import { inputFieldShared } from '@vaadin/vaadin-lumo-styles/mixins/input-field-shared.js';
7
- import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
8
-
9
- const emailField = css`
10
- :host([dir='rtl']) [part='input-field'] ::slotted(input) {
11
- --_lumo-text-field-overflow-mask-image: linear-gradient(to left, transparent, #000 1.25em);
12
- }
13
-
14
- :host([dir='rtl']) [part='input-field'] ::slotted(input:placeholder-shown) {
15
- --_lumo-text-field-overflow-mask-image: none;
16
- }
17
- `;
18
-
19
- registerStyles('vaadin-email-field', [inputFieldShared, emailField], {
20
- moduleId: 'lumo-email-field',
21
- });
@@ -1,8 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright (c) 2021 - 2025 Vaadin Ltd.
4
- * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
- */
6
- import '@vaadin/text-field/theme/lumo/vaadin-text-field.js';
7
- import './vaadin-email-field-styles.js';
8
- import '../../src/vaadin-email-field.js';
@@ -1,8 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright (c) 2021 - 2025 Vaadin Ltd.
4
- * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
- */
6
- import '@vaadin/text-field/theme/lumo/vaadin-text-field.js';
7
- import './vaadin-email-field-styles.js';
8
- import '../../src/vaadin-email-field.js';