@vaadin/message-input 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 +10 -13
- package/src/styles/vaadin-message-input-base-styles.js +3 -40
- package/src/styles/{vaadin-message-input-core-styles.d.ts → vaadin-message-input-button-styles.d.ts} +1 -1
- package/src/styles/vaadin-message-input-button-styles.js +19 -0
- package/src/vaadin-message-input-button.d.ts +21 -0
- package/src/vaadin-message-input-button.js +49 -0
- package/src/vaadin-message-input-mixin.d.ts +1 -1
- package/src/vaadin-message-input-mixin.js +4 -4
- package/src/vaadin-message-input.d.ts +19 -0
- package/src/vaadin-message-input.js +21 -2
- package/vaadin-message-input.js +1 -1
- package/web-types.json +3 -3
- package/web-types.lit.json +3 -3
- package/src/styles/vaadin-message-input-core-styles.js +0 -30
- package/theme/lumo/vaadin-message-input-styles.d.ts +0 -4
- package/theme/lumo/vaadin-message-input-styles.js +0 -19
- package/theme/lumo/vaadin-message-input.d.ts +0 -4
- package/theme/lumo/vaadin-message-input.js +0 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vaadin/message-input",
|
|
3
|
-
"version": "25.0.0-
|
|
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",
|
|
@@ -37,22 +34,22 @@
|
|
|
37
34
|
],
|
|
38
35
|
"dependencies": {
|
|
39
36
|
"@open-wc/dedupe-mixin": "^1.3.0",
|
|
40
|
-
"@vaadin/button": "25.0.0-
|
|
41
|
-
"@vaadin/component-base": "25.0.0-
|
|
42
|
-
"@vaadin/text-area": "25.0.0-
|
|
43
|
-
"@vaadin/vaadin-
|
|
44
|
-
"@vaadin/vaadin-themable-mixin": "25.0.0-alpha9",
|
|
37
|
+
"@vaadin/button": "25.0.0-beta2",
|
|
38
|
+
"@vaadin/component-base": "25.0.0-beta2",
|
|
39
|
+
"@vaadin/text-area": "25.0.0-beta2",
|
|
40
|
+
"@vaadin/vaadin-themable-mixin": "25.0.0-beta2",
|
|
45
41
|
"lit": "^3.0.0"
|
|
46
42
|
},
|
|
47
43
|
"devDependencies": {
|
|
48
|
-
"@vaadin/chai-plugins": "25.0.0-
|
|
49
|
-
"@vaadin/test-runner-commands": "25.0.0-
|
|
44
|
+
"@vaadin/chai-plugins": "25.0.0-beta2",
|
|
45
|
+
"@vaadin/test-runner-commands": "25.0.0-beta2",
|
|
50
46
|
"@vaadin/testing-helpers": "^2.0.0",
|
|
51
|
-
"
|
|
47
|
+
"@vaadin/vaadin-lumo-styles": "25.0.0-beta2",
|
|
48
|
+
"sinon": "^21.0.0"
|
|
52
49
|
},
|
|
53
50
|
"web-types": [
|
|
54
51
|
"web-types.json",
|
|
55
52
|
"web-types.lit.json"
|
|
56
53
|
],
|
|
57
|
-
"gitHead": "
|
|
54
|
+
"gitHead": "e078f8371ae266f05c7ca1ec25686cc489c83f24"
|
|
58
55
|
}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
4
4
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5
5
|
*/
|
|
6
|
-
import '@vaadin/component-base/src/style-props.js';
|
|
6
|
+
import '@vaadin/component-base/src/styles/style-props.js';
|
|
7
7
|
import { css } from 'lit';
|
|
8
8
|
|
|
9
9
|
export const messageInputStyles = css`
|
|
@@ -13,7 +13,7 @@ export const messageInputStyles = css`
|
|
|
13
13
|
max-height: 50vh;
|
|
14
14
|
flex-shrink: 0;
|
|
15
15
|
border: var(--vaadin-input-field-border-width, 1px) solid
|
|
16
|
-
var(--vaadin-input-field-border-color, var(--vaadin-border-color
|
|
16
|
+
var(--vaadin-input-field-border-color, var(--vaadin-border-color));
|
|
17
17
|
border-radius: var(--vaadin-input-field-border-radius, var(--vaadin-radius-m));
|
|
18
18
|
background: var(--vaadin-input-field-background, var(--vaadin-background-color));
|
|
19
19
|
}
|
|
@@ -28,7 +28,7 @@ export const messageInputStyles = css`
|
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
:host([disabled]) {
|
|
31
|
-
--vaadin-input-field-value-color: var(--vaadin-input-field-disabled-text-color, var(--vaadin-color-disabled));
|
|
31
|
+
--vaadin-input-field-value-color: var(--vaadin-input-field-disabled-text-color, var(--vaadin-text-color-disabled));
|
|
32
32
|
--vaadin-input-field-background: var(
|
|
33
33
|
--vaadin-input-field-disabled-background,
|
|
34
34
|
var(--vaadin-background-container-strong)
|
|
@@ -42,41 +42,4 @@ export const messageInputStyles = css`
|
|
|
42
42
|
--vaadin-focus-ring-width: 0;
|
|
43
43
|
--vaadin-input-field-background: transparent !important;
|
|
44
44
|
}
|
|
45
|
-
|
|
46
|
-
::slotted([slot='button']) {
|
|
47
|
-
flex: none;
|
|
48
|
-
align-self: end;
|
|
49
|
-
margin: var(--vaadin-input-field-padding, var(--vaadin-padding-container));
|
|
50
|
-
--vaadin-button-border-width: 0;
|
|
51
|
-
--vaadin-button-background: transparent;
|
|
52
|
-
--vaadin-button-text-color: var(--vaadin-color);
|
|
53
|
-
--vaadin-button-padding: 0;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
:host([theme~='icon-button']) ::slotted([slot='button']) {
|
|
57
|
-
width: var(--vaadin-icon-size, 1lh);
|
|
58
|
-
height: var(--vaadin-icon-size, 1lh);
|
|
59
|
-
color: transparent;
|
|
60
|
-
position: relative;
|
|
61
|
-
contain: strict;
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
:host([theme~='icon-button']) ::slotted([slot='button'])::before {
|
|
65
|
-
content: '';
|
|
66
|
-
position: absolute;
|
|
67
|
-
inset: 0;
|
|
68
|
-
mask-image: var(--_vaadin-icon-paper-airplane);
|
|
69
|
-
background: var(--vaadin-button-text-color);
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
:host([dir='rtl'][theme~='icon-button']) ::slotted([slot='button'])::before {
|
|
73
|
-
scale: -1;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
@media (forced-colors: active) {
|
|
77
|
-
:host([theme~='icon-button']) ::slotted([slot='button']) {
|
|
78
|
-
forced-color-adjust: none;
|
|
79
|
-
--vaadin-button-text-color: CanvasText;
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
45
|
`;
|
|
@@ -0,0 +1,19 @@
|
|
|
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/component-base/src/styles/style-props.js';
|
|
7
|
+
import { css } from 'lit';
|
|
8
|
+
|
|
9
|
+
export const messageInputButtonStyles = css`
|
|
10
|
+
:host {
|
|
11
|
+
flex: none;
|
|
12
|
+
align-self: end;
|
|
13
|
+
margin: var(--vaadin-input-field-padding, var(--vaadin-padding-container));
|
|
14
|
+
--vaadin-button-border-width: 0;
|
|
15
|
+
--vaadin-button-background: transparent;
|
|
16
|
+
--vaadin-button-text-color: var(--vaadin-text-color);
|
|
17
|
+
--vaadin-button-padding: 0;
|
|
18
|
+
}
|
|
19
|
+
`;
|
|
@@ -0,0 +1,21 @@
|
|
|
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 { ButtonMixin } from '@vaadin/button/src/vaadin-button-mixin.js';
|
|
7
|
+
import { DirMixin } from '@vaadin/component-base/src/dir-mixin.js';
|
|
8
|
+
import { ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* An element used internally by `<vaadin-message-input>`. Not intended to be used separately.
|
|
12
|
+
*/
|
|
13
|
+
declare class MessageInputButton extends ButtonMixin(DirMixin(ThemableMixin(HTMLElement))) {}
|
|
14
|
+
|
|
15
|
+
declare global {
|
|
16
|
+
interface HTMLElementTagNameMap {
|
|
17
|
+
'vaadin-message-input-button': MessageInputButton;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export { MessageInputButton };
|
|
@@ -0,0 +1,49 @@
|
|
|
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 { html, LitElement } from 'lit';
|
|
7
|
+
import { buttonStyles } from '@vaadin/button/src/styles/vaadin-button-base-styles.js';
|
|
8
|
+
import { ButtonMixin } from '@vaadin/button/src/vaadin-button-mixin.js';
|
|
9
|
+
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
10
|
+
import { DirMixin } from '@vaadin/component-base/src/dir-mixin.js';
|
|
11
|
+
import { PolylitMixin } from '@vaadin/component-base/src/polylit-mixin.js';
|
|
12
|
+
import { LumoInjectionMixin } from '@vaadin/vaadin-themable-mixin/lumo-injection-mixin.js';
|
|
13
|
+
import { ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
14
|
+
import { messageInputButtonStyles } from './styles/vaadin-message-input-button-styles.js';
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* An element used internally by `<vaadin-message-input>`. Not intended to be used separately.
|
|
18
|
+
*
|
|
19
|
+
* @customElement
|
|
20
|
+
* @extends HTMLElement
|
|
21
|
+
* @mixes ButtonMixin
|
|
22
|
+
* @mixes DirMixin
|
|
23
|
+
* @mixes ThemableMixin
|
|
24
|
+
* @private
|
|
25
|
+
*/
|
|
26
|
+
class MessageInputButton extends ButtonMixin(DirMixin(ThemableMixin(PolylitMixin(LumoInjectionMixin(LitElement))))) {
|
|
27
|
+
static get is() {
|
|
28
|
+
return 'vaadin-message-input-button';
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
static get styles() {
|
|
32
|
+
return [buttonStyles, messageInputButtonStyles];
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/** @protected */
|
|
36
|
+
render() {
|
|
37
|
+
return html`
|
|
38
|
+
<div class="vaadin-button-container">
|
|
39
|
+
<span part="label">
|
|
40
|
+
<slot></slot>
|
|
41
|
+
</span>
|
|
42
|
+
</div>
|
|
43
|
+
`;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
defineCustomElement(MessageInputButton);
|
|
48
|
+
|
|
49
|
+
export { MessageInputButton };
|
|
@@ -67,7 +67,7 @@ export const MessageInputMixin = (superClass) =>
|
|
|
67
67
|
* just the individual properties you want to change.
|
|
68
68
|
*
|
|
69
69
|
* The object has the following JSON structure and default values:
|
|
70
|
-
* ```
|
|
70
|
+
* ```js
|
|
71
71
|
* {
|
|
72
72
|
* // Used as the button label
|
|
73
73
|
* send: 'Send',
|
|
@@ -90,7 +90,7 @@ export const MessageInputMixin = (superClass) =>
|
|
|
90
90
|
ready() {
|
|
91
91
|
super.ready();
|
|
92
92
|
|
|
93
|
-
this._buttonController = new SlotController(this, 'button', 'vaadin-button', {
|
|
93
|
+
this._buttonController = new SlotController(this, 'button', 'vaadin-message-input-button', {
|
|
94
94
|
initializer: (btn) => {
|
|
95
95
|
btn.addEventListener('click', () => {
|
|
96
96
|
this.__submit();
|
|
@@ -127,9 +127,9 @@ export const MessageInputMixin = (superClass) =>
|
|
|
127
127
|
this.addController(this._tooltipController);
|
|
128
128
|
}
|
|
129
129
|
|
|
130
|
-
focus() {
|
|
130
|
+
focus(options) {
|
|
131
131
|
if (this._textArea) {
|
|
132
|
-
this._textArea.focus();
|
|
132
|
+
this._textArea.focus(options);
|
|
133
133
|
}
|
|
134
134
|
}
|
|
135
135
|
|
|
@@ -32,6 +32,25 @@ export type MessageInputEventMap = HTMLElementEventMap & MessageInputCustomEvent
|
|
|
32
32
|
* ```html
|
|
33
33
|
* <vaadin-message-input></vaadin-message-input>
|
|
34
34
|
* ```
|
|
35
|
+
*
|
|
36
|
+
* ### Styling
|
|
37
|
+
*
|
|
38
|
+
* The following state attributes are available for styling:
|
|
39
|
+
*
|
|
40
|
+
* Attribute | Description
|
|
41
|
+
* ---------------|---------------------------------
|
|
42
|
+
* `disabled` | Set when the element is disabled
|
|
43
|
+
* `has-tooltip` | Set when the element has a slotted tooltip
|
|
44
|
+
*
|
|
45
|
+
* ### Internal components
|
|
46
|
+
*
|
|
47
|
+
* In addition to `<vaadin-message-input>` itself, the following internal
|
|
48
|
+
* components are themable:
|
|
49
|
+
*
|
|
50
|
+
* - `<vaadin-message-input-button>` - has the same API as `<vaadin-button>`
|
|
51
|
+
* - `<vaadin-text-area>`
|
|
52
|
+
*
|
|
53
|
+
* See [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.
|
|
35
54
|
*/
|
|
36
55
|
declare class MessageInput extends MessageInputMixin(ThemableMixin(ElementMixin(HTMLElement))) {
|
|
37
56
|
addEventListener<K extends keyof MessageInputEventMap>(
|
|
@@ -3,15 +3,15 @@
|
|
|
3
3
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
4
4
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5
5
|
*/
|
|
6
|
-
import '@vaadin/button/src/vaadin-button.js';
|
|
7
6
|
import '@vaadin/text-area/src/vaadin-text-area.js';
|
|
7
|
+
import './vaadin-message-input-button.js';
|
|
8
8
|
import { html, LitElement } from 'lit';
|
|
9
9
|
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
10
10
|
import { ElementMixin } from '@vaadin/component-base/src/element-mixin.js';
|
|
11
11
|
import { PolylitMixin } from '@vaadin/component-base/src/polylit-mixin.js';
|
|
12
12
|
import { LumoInjectionMixin } from '@vaadin/vaadin-themable-mixin/lumo-injection-mixin.js';
|
|
13
13
|
import { ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
14
|
-
import { messageInputStyles } from './styles/vaadin-message-input-
|
|
14
|
+
import { messageInputStyles } from './styles/vaadin-message-input-base-styles.js';
|
|
15
15
|
import { MessageInputMixin } from './vaadin-message-input-mixin.js';
|
|
16
16
|
|
|
17
17
|
/**
|
|
@@ -26,6 +26,25 @@ import { MessageInputMixin } from './vaadin-message-input-mixin.js';
|
|
|
26
26
|
* <vaadin-message-input></vaadin-message-input>
|
|
27
27
|
* ```
|
|
28
28
|
*
|
|
29
|
+
* ### Styling
|
|
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-tooltip` | Set when the element has a slotted tooltip
|
|
37
|
+
*
|
|
38
|
+
* ### Internal components
|
|
39
|
+
*
|
|
40
|
+
* In addition to `<vaadin-message-input>` itself, the following internal
|
|
41
|
+
* components are themable:
|
|
42
|
+
*
|
|
43
|
+
* - `<vaadin-message-input-button>` - has the same API as `<vaadin-button>`
|
|
44
|
+
* - `<vaadin-text-area>`
|
|
45
|
+
*
|
|
46
|
+
* See [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.
|
|
47
|
+
*
|
|
29
48
|
* @customElement
|
|
30
49
|
* @extends HTMLElement
|
|
31
50
|
* @mixes MessageInputMixin
|
package/vaadin-message-input.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import './
|
|
1
|
+
import './src/vaadin-message-input.js';
|
|
2
2
|
export * from './src/vaadin-message-input.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/message-input",
|
|
4
|
-
"version": "25.0.0-
|
|
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-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
|
|
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```\n\n### Styling\n\nThe following state attributes are available for styling:\n\nAttribute | Description\n---------------|---------------------------------\n`disabled` | Set when the element is disabled\n`has-tooltip` | Set when the element has a slotted tooltip\n\n### Internal components\n\nIn addition to `<vaadin-message-input>` itself, the following internal\ncomponents are themable:\n\n- `<vaadin-message-input-button>` - has the same API as `<vaadin-button>`\n- `<vaadin-text-area>`\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.",
|
|
12
12
|
"attributes": [
|
|
13
13
|
{
|
|
14
14
|
"name": "i18n",
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"properties": [
|
|
56
56
|
{
|
|
57
57
|
"name": "i18n",
|
|
58
|
-
"description": "The object used to localize this component. To change the default\nlocalization, replace this with an object that provides all properties, or\njust the individual properties you want to change.\n\nThe object has the following JSON structure and default values:\n
|
|
58
|
+
"description": "The object used to localize this component. To change the default\nlocalization, replace this with an object that provides all properties, or\njust the individual properties you want to change.\n\nThe object has the following JSON structure and default values:\n```js\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```",
|
|
59
59
|
"value": {
|
|
60
60
|
"type": [
|
|
61
61
|
"MessageInputI18n"
|
package/web-types.lit.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/web-types",
|
|
3
3
|
"name": "@vaadin/message-input",
|
|
4
|
-
"version": "25.0.0-
|
|
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-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
|
|
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```\n\n### Styling\n\nThe following state attributes are available for styling:\n\nAttribute | Description\n---------------|---------------------------------\n`disabled` | Set when the element is disabled\n`has-tooltip` | Set when the element has a slotted tooltip\n\n### Internal components\n\nIn addition to `<vaadin-message-input>` itself, the following internal\ncomponents are themable:\n\n- `<vaadin-message-input-button>` - has the same API as `<vaadin-button>`\n- `<vaadin-text-area>`\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.",
|
|
20
20
|
"extension": true,
|
|
21
21
|
"attributes": [
|
|
22
22
|
{
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
},
|
|
29
29
|
{
|
|
30
30
|
"name": ".i18n",
|
|
31
|
-
"description": "The object used to localize this component. To change the default\nlocalization, replace this with an object that provides all properties, or\njust the individual properties you want to change.\n\nThe object has the following JSON structure and default values:\n
|
|
31
|
+
"description": "The object used to localize this component. To change the default\nlocalization, replace this with an object that provides all properties, or\njust the individual properties you want to change.\n\nThe object has the following JSON structure and default values:\n```js\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```",
|
|
32
32
|
"value": {
|
|
33
33
|
"kind": "expression"
|
|
34
34
|
}
|
|
@@ -1,30 +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
|
-
export const messageInputStyles = css`
|
|
9
|
-
:host {
|
|
10
|
-
align-items: flex-start;
|
|
11
|
-
box-sizing: border-box;
|
|
12
|
-
display: flex;
|
|
13
|
-
max-height: 50vh;
|
|
14
|
-
overflow: hidden;
|
|
15
|
-
flex-shrink: 0;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
:host([hidden]) {
|
|
19
|
-
display: none !important;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
::slotted([slot='button']) {
|
|
23
|
-
flex-shrink: 0;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
::slotted([slot='textarea']) {
|
|
27
|
-
align-self: stretch;
|
|
28
|
-
flex-grow: 1;
|
|
29
|
-
}
|
|
30
|
-
`;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import '@vaadin/vaadin-lumo-styles/color.js';
|
|
2
|
-
import '@vaadin/vaadin-lumo-styles/sizing.js';
|
|
3
|
-
import '@vaadin/vaadin-lumo-styles/spacing.js';
|
|
4
|
-
import '@vaadin/vaadin-lumo-styles/style.js';
|
|
5
|
-
import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
6
|
-
|
|
7
|
-
registerStyles(
|
|
8
|
-
'vaadin-message-input',
|
|
9
|
-
css`
|
|
10
|
-
:host {
|
|
11
|
-
padding: var(--lumo-space-s) var(--lumo-space-m);
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
::slotted([slot='textarea']) {
|
|
15
|
-
margin-inline-end: var(--lumo-space-s);
|
|
16
|
-
}
|
|
17
|
-
`,
|
|
18
|
-
{ moduleId: 'lumo-message-input' },
|
|
19
|
-
);
|