@vaadin/message-input 24.4.0-dev.b3e1d14600 → 24.5.0-alpha1
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 +8 -8
- package/src/vaadin-message-input.d.ts +1 -1
- package/src/vaadin-message-input.js +7 -1
- package/theme/lumo/vaadin-message-input-styles.d.ts +4 -0
- package/theme/lumo/vaadin-message-input.d.ts +4 -0
- package/theme/material/vaadin-message-input-styles.d.ts +2 -0
- package/theme/material/vaadin-message-input.d.ts +4 -0
- package/web-types.json +88 -0
- package/web-types.lit.json +55 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vaadin/message-input",
|
|
3
|
-
"version": "24.
|
|
3
|
+
"version": "24.5.0-alpha1",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -36,12 +36,12 @@
|
|
|
36
36
|
],
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"@polymer/polymer": "^3.0.0",
|
|
39
|
-
"@vaadin/button": "24.
|
|
40
|
-
"@vaadin/component-base": "24.
|
|
41
|
-
"@vaadin/text-area": "24.
|
|
42
|
-
"@vaadin/vaadin-lumo-styles": "24.
|
|
43
|
-
"@vaadin/vaadin-material-styles": "24.
|
|
44
|
-
"@vaadin/vaadin-themable-mixin": "24.
|
|
39
|
+
"@vaadin/button": "24.5.0-alpha1",
|
|
40
|
+
"@vaadin/component-base": "24.5.0-alpha1",
|
|
41
|
+
"@vaadin/text-area": "24.5.0-alpha1",
|
|
42
|
+
"@vaadin/vaadin-lumo-styles": "24.5.0-alpha1",
|
|
43
|
+
"@vaadin/vaadin-material-styles": "24.5.0-alpha1",
|
|
44
|
+
"@vaadin/vaadin-themable-mixin": "24.5.0-alpha1"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@esm-bundle/chai": "^4.3.4",
|
|
@@ -52,5 +52,5 @@
|
|
|
52
52
|
"web-types.json",
|
|
53
53
|
"web-types.lit.json"
|
|
54
54
|
],
|
|
55
|
-
"gitHead": "
|
|
55
|
+
"gitHead": "57806caac5468532a3b4e3dbdda730cd0fca193a"
|
|
56
56
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
|
-
* Copyright (c) 2021 -
|
|
3
|
+
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4
4
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5
5
|
*/
|
|
6
6
|
import { ControllerMixin } from '@vaadin/component-base/src/controller-mixin.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
|
-
* Copyright (c) 2021 -
|
|
3
|
+
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4
4
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5
5
|
*/
|
|
6
6
|
import '@vaadin/button/src/vaadin-button.js';
|
|
@@ -183,6 +183,12 @@ class MessageInput extends ElementMixin(ThemableMixin(ControllerMixin(PolymerEle
|
|
|
183
183
|
this.addController(this._tooltipController);
|
|
184
184
|
}
|
|
185
185
|
|
|
186
|
+
focus() {
|
|
187
|
+
if (this._textArea) {
|
|
188
|
+
this._textArea.focus();
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
|
|
186
192
|
/** @private */
|
|
187
193
|
__buttonPropsChanged(button, disabled, i18n) {
|
|
188
194
|
if (button) {
|
package/web-types.json
ADDED
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json.schemastore.org/web-types",
|
|
3
|
+
"name": "@vaadin/message-input",
|
|
4
|
+
"version": "24.5.0-alpha1",
|
|
5
|
+
"description-markup": "markdown",
|
|
6
|
+
"contributions": {
|
|
7
|
+
"html": {
|
|
8
|
+
"elements": [
|
|
9
|
+
{
|
|
10
|
+
"name": "vaadin-message-input",
|
|
11
|
+
"description": "`<vaadin-message-input>` is a Web Component for sending messages.\nIt consists of a text area that grows on along with the content, and a send button to send message.\n\nThe message can be sent by one of the following actions:\n- by pressing Enter (use Shift + Enter to add a new line)\n- by clicking `submit` button.\n\n```html\n<vaadin-message-input></vaadin-message-input>\n```",
|
|
12
|
+
"attributes": [
|
|
13
|
+
{
|
|
14
|
+
"name": "value",
|
|
15
|
+
"description": "Current content of the text input field",
|
|
16
|
+
"value": {
|
|
17
|
+
"type": [
|
|
18
|
+
"string",
|
|
19
|
+
"null",
|
|
20
|
+
"undefined"
|
|
21
|
+
]
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"name": "disabled",
|
|
26
|
+
"description": "Set to true to disable this element.",
|
|
27
|
+
"value": {
|
|
28
|
+
"type": [
|
|
29
|
+
"boolean"
|
|
30
|
+
]
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
"name": "theme",
|
|
35
|
+
"description": "The theme variants to apply to the component.",
|
|
36
|
+
"value": {
|
|
37
|
+
"type": [
|
|
38
|
+
"string",
|
|
39
|
+
"null",
|
|
40
|
+
"undefined"
|
|
41
|
+
]
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
],
|
|
45
|
+
"js": {
|
|
46
|
+
"properties": [
|
|
47
|
+
{
|
|
48
|
+
"name": "value",
|
|
49
|
+
"description": "Current content of the text input field",
|
|
50
|
+
"value": {
|
|
51
|
+
"type": [
|
|
52
|
+
"string",
|
|
53
|
+
"null",
|
|
54
|
+
"undefined"
|
|
55
|
+
]
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"name": "i18n",
|
|
60
|
+
"description": "The object used to localize this component.\nFor changing the default localization, change the entire\n`i18n` object.\n\nThe object has the following JSON structure and default values:\n\n```\n{\n // Used as the button label\n send: 'Send',\n\n // Used as the input field's placeholder and aria-label\n message: 'Message'\n}\n```",
|
|
61
|
+
"value": {
|
|
62
|
+
"type": [
|
|
63
|
+
"MessageInputI18n"
|
|
64
|
+
]
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"name": "disabled",
|
|
69
|
+
"description": "Set to true to disable this element.",
|
|
70
|
+
"value": {
|
|
71
|
+
"type": [
|
|
72
|
+
"boolean"
|
|
73
|
+
]
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
],
|
|
77
|
+
"events": [
|
|
78
|
+
{
|
|
79
|
+
"name": "submit",
|
|
80
|
+
"description": "Fired when a new message is submitted with `<vaadin-message-input>`, either\nby clicking the \"send\" button, or pressing the Enter key."
|
|
81
|
+
}
|
|
82
|
+
]
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
]
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json.schemastore.org/web-types",
|
|
3
|
+
"name": "@vaadin/message-input",
|
|
4
|
+
"version": "24.5.0-alpha1",
|
|
5
|
+
"description-markup": "markdown",
|
|
6
|
+
"framework": "lit",
|
|
7
|
+
"framework-config": {
|
|
8
|
+
"enable-when": {
|
|
9
|
+
"node-packages": [
|
|
10
|
+
"lit"
|
|
11
|
+
]
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
"contributions": {
|
|
15
|
+
"html": {
|
|
16
|
+
"elements": [
|
|
17
|
+
{
|
|
18
|
+
"name": "vaadin-message-input",
|
|
19
|
+
"description": "`<vaadin-message-input>` is a Web Component for sending messages.\nIt consists of a text area that grows on along with the content, and a send button to send message.\n\nThe message can be sent by one of the following actions:\n- by pressing Enter (use Shift + Enter to add a new line)\n- by clicking `submit` button.\n\n```html\n<vaadin-message-input></vaadin-message-input>\n```",
|
|
20
|
+
"extension": true,
|
|
21
|
+
"attributes": [
|
|
22
|
+
{
|
|
23
|
+
"name": "?disabled",
|
|
24
|
+
"description": "Set to true to disable this element.",
|
|
25
|
+
"value": {
|
|
26
|
+
"kind": "expression"
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"name": ".value",
|
|
31
|
+
"description": "Current content of the text input field",
|
|
32
|
+
"value": {
|
|
33
|
+
"kind": "expression"
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"name": ".i18n",
|
|
38
|
+
"description": "The object used to localize this component.\nFor changing the default localization, change the entire\n`i18n` object.\n\nThe object has the following JSON structure and default values:\n\n```\n{\n // Used as the button label\n send: 'Send',\n\n // Used as the input field's placeholder and aria-label\n message: 'Message'\n}\n```",
|
|
39
|
+
"value": {
|
|
40
|
+
"kind": "expression"
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"name": "@submit",
|
|
45
|
+
"description": "Fired when a new message is submitted with `<vaadin-message-input>`, either\nby clicking the \"send\" button, or pressing the Enter key.",
|
|
46
|
+
"value": {
|
|
47
|
+
"kind": "expression"
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
]
|
|
51
|
+
}
|
|
52
|
+
]
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|