@ui5/webcomponents-ai 2.0.0-rc.5 → 2.0.0
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/CHANGELOG.md +28 -0
- package/README.md +1 -4
- package/dist/Button.d.ts +76 -6
- package/dist/Button.js +170 -14
- package/dist/Button.js.map +1 -1
- package/dist/ButtonState.d.ts +60 -0
- package/dist/ButtonState.js +51 -0
- package/dist/ButtonState.js.map +1 -0
- package/dist/PromptInput.d.ts +108 -7
- package/dist/PromptInput.js +174 -9
- package/dist/PromptInput.js.map +1 -1
- package/dist/bundle.esm.js +1 -0
- package/dist/bundle.esm.js.map +1 -1
- package/dist/css/themes/Button.css +1 -0
- package/dist/css/themes/PromptInput.css +1 -0
- package/dist/custom-elements-internal.json +423 -7
- package/dist/custom-elements.json +371 -7
- package/dist/generated/assets/i18n/messagebundle_ar.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_bg.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_ca.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_cnr.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_cs.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_cy.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_da.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_de.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_el.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_en.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_en_GB.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_en_US_saprigi.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_es.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_es_MX.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_et.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_fi.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_fr.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_fr_CA.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_hi.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_hr.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_hu.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_it.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_iw.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_ja.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_kk.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_ko.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_lt.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_lv.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_mk.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_ms.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_nl.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_no.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_pl.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_pt.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_pt_PT.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_ro.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_ru.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_sh.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_sk.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_sl.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_sr.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_sv.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_th.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_tr.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_uk.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_vi.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_zh_CN.json +1 -0
- package/dist/generated/assets/i18n/messagebundle_zh_TW.json +1 -0
- package/dist/generated/i18n/i18n-defaults.d.ts +4 -1
- package/dist/generated/i18n/i18n-defaults.js +3 -0
- package/dist/generated/i18n/i18n-defaults.js.map +1 -1
- package/dist/generated/json-imports/i18n.d.ts +1 -0
- package/dist/generated/json-imports/i18n.js +113 -1
- package/dist/generated/json-imports/i18n.js.map +1 -1
- package/dist/generated/templates/ButtonTemplate.lit.js +2 -1
- package/dist/generated/templates/ButtonTemplate.lit.js.map +1 -1
- package/dist/generated/templates/PromptInputTemplate.lit.d.ts +4 -0
- package/dist/generated/templates/PromptInputTemplate.lit.js +8 -0
- package/dist/generated/templates/PromptInputTemplate.lit.js.map +1 -0
- package/dist/generated/themes/Button.css.js +2 -1
- package/dist/generated/themes/Button.css.js.map +1 -1
- package/dist/generated/themes/PromptInput.css.d.ts +3 -0
- package/dist/generated/themes/PromptInput.css.js +9 -0
- package/dist/generated/themes/PromptInput.css.js.map +1 -0
- package/dist/vscode.html-custom-data.json +93 -3
- package/dist/web-types.json +219 -8
- package/package.json +7 -7
- package/src/Button.hbs +17 -3
- package/src/PromptInput.hbs +31 -0
- package/src/i18n/messagebundle.properties +6 -0
- package/src/i18n/messagebundle_ar.properties +4 -0
- package/src/i18n/messagebundle_bg.properties +4 -0
- package/src/i18n/messagebundle_ca.properties +4 -0
- package/src/i18n/messagebundle_cnr.properties +4 -0
- package/src/i18n/messagebundle_cs.properties +4 -0
- package/src/i18n/messagebundle_cy.properties +4 -0
- package/src/i18n/messagebundle_da.properties +4 -0
- package/src/i18n/messagebundle_de.properties +4 -0
- package/src/i18n/messagebundle_el.properties +4 -0
- package/src/i18n/messagebundle_en.properties +4 -0
- package/src/i18n/messagebundle_en_GB.properties +4 -0
- package/src/i18n/messagebundle_en_US_saprigi.properties +4 -0
- package/src/i18n/messagebundle_es.properties +4 -0
- package/src/i18n/messagebundle_es_MX.properties +4 -0
- package/src/i18n/messagebundle_et.properties +4 -0
- package/src/i18n/messagebundle_fi.properties +4 -0
- package/src/i18n/messagebundle_fr.properties +4 -0
- package/src/i18n/messagebundle_fr_CA.properties +4 -0
- package/src/i18n/messagebundle_hi.properties +4 -0
- package/src/i18n/messagebundle_hr.properties +4 -0
- package/src/i18n/messagebundle_hu.properties +4 -0
- package/src/i18n/messagebundle_id.properties +4 -0
- package/src/i18n/messagebundle_it.properties +4 -0
- package/src/i18n/messagebundle_iw.properties +4 -0
- package/src/i18n/messagebundle_ja.properties +4 -0
- package/src/i18n/messagebundle_kk.properties +4 -0
- package/src/i18n/messagebundle_ko.properties +4 -0
- package/src/i18n/messagebundle_lt.properties +4 -0
- package/src/i18n/messagebundle_lv.properties +4 -0
- package/src/i18n/messagebundle_mk.properties +4 -0
- package/src/i18n/messagebundle_ms.properties +4 -0
- package/src/i18n/messagebundle_nl.properties +4 -0
- package/src/i18n/messagebundle_no.properties +4 -0
- package/src/i18n/messagebundle_pl.properties +4 -0
- package/src/i18n/messagebundle_pt.properties +4 -0
- package/src/i18n/messagebundle_pt_PT.properties +4 -0
- package/src/i18n/messagebundle_ro.properties +4 -0
- package/src/i18n/messagebundle_ru.properties +4 -0
- package/src/i18n/messagebundle_sh.properties +4 -0
- package/src/i18n/messagebundle_sk.properties +4 -0
- package/src/i18n/messagebundle_sl.properties +4 -0
- package/src/i18n/messagebundle_sr.properties +4 -0
- package/src/i18n/messagebundle_sv.properties +4 -0
- package/src/i18n/messagebundle_th.properties +4 -0
- package/src/i18n/messagebundle_tr.properties +4 -0
- package/src/i18n/messagebundle_uk.properties +4 -0
- package/src/i18n/messagebundle_vi.properties +4 -0
- package/src/i18n/messagebundle_zh_CN.properties +4 -0
- package/src/i18n/messagebundle_zh_TW.properties +4 -0
- package/src/themes/Button.css +88 -0
- package/src/themes/PromptInput.css +30 -0
package/dist/web-types.json
CHANGED
@@ -1,29 +1,123 @@
|
|
1
1
|
{
|
2
2
|
"$schema": "https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json",
|
3
3
|
"name": "@ui5/webcomponents-ai",
|
4
|
-
"version": "2.0.0
|
4
|
+
"version": "2.0.0",
|
5
5
|
"description-markup": "markdown",
|
6
6
|
"contributions": {
|
7
7
|
"html": {
|
8
8
|
"elements": [
|
9
9
|
{
|
10
10
|
"name": "ui5-ai-button",
|
11
|
-
"description": "### Overview\n\nThe `ui5-ai-button` component represents a button used in AI-related scenarios.\nIt enables users to trigger actions by clicking or tapping the `ui5-ai-button`, or by pressing\ncertain keyboard keys, such as Enter.\n\n### Usage\n\nFor the `ui5-ai-button` UI, you can define one or more states of the button by placing `ai-button-state` components in its default slot.\nEach state have a
|
11
|
+
"description": "### Overview\n\nThe `ui5-ai-button` component represents a button used in AI-related scenarios.\nIt enables users to trigger actions by clicking or tapping the `ui5-ai-button`, or by pressing\ncertain keyboard keys, such as Enter.\n\n### Usage\n\nFor the `ui5-ai-button` UI, you can define one or more states of the button by placing `ai-button-state` components in its default slot.\nEach state have a name that identifies it and can have text, icon and end icon defined (in any combination) depending on the state purpose.\n\nYou can choose from a set of predefined designs (the same as for regular `ui5-button` component) that allow different styling to correspond to the triggered action.\n\n`ui5-ai-button` can be activated by clicking or tapping it. The state can be changed in `click` event handler.\n\n### ES6 Module Import\n\n`import \"@ui5/webcomponents-ai/dist/Button.js\";`\n---\n\n\n### **Events:**\n - **click** - Fired when the component is activated either with a\nmouse/tap or by using the Enter or Space key.\n\n### **Slots:**\n - **default** - Defines the available states of the component.\n**Note:** Although this slot accepts HTML Elements, it is strongly recommended that you only use `ui5-ai-button-state` components in order to preserve the intended design.",
|
12
12
|
"doc-url": "",
|
13
13
|
"attributes": [
|
14
|
+
{
|
15
|
+
"name": "design",
|
16
|
+
"description": "Defines the component design.",
|
17
|
+
"value": {
|
18
|
+
"type": "\"Default\" | \"Positive\" | \"Negative\" | \"Transparent\" | \"Emphasized\" | \"Attention\" | undefined",
|
19
|
+
"default": "\"Default\""
|
20
|
+
}
|
21
|
+
},
|
14
22
|
{
|
15
23
|
"name": "disabled",
|
16
24
|
"description": "Defines whether the component is disabled.\nA disabled component can't be pressed or\nfocused, and it is not in the tab chain.",
|
17
25
|
"value": { "type": "boolean", "default": "false" }
|
26
|
+
},
|
27
|
+
{
|
28
|
+
"name": "state",
|
29
|
+
"description": "Defines the current state of the component.",
|
30
|
+
"value": { "type": "string | undefined", "default": "undefined" }
|
31
|
+
}
|
32
|
+
],
|
33
|
+
"slots": [
|
34
|
+
{
|
35
|
+
"name": "default",
|
36
|
+
"description": "Defines the available states of the component.\n**Note:** Although this slot accepts HTML Elements, it is strongly recommended that you only use `ui5-ai-button-state` components in order to preserve the intended design."
|
37
|
+
}
|
38
|
+
],
|
39
|
+
"events": [
|
40
|
+
{
|
41
|
+
"name": "click",
|
42
|
+
"description": "Fired when the component is activated either with a\nmouse/tap or by using the Enter or Space key."
|
18
43
|
}
|
19
44
|
],
|
20
|
-
"events": [],
|
21
45
|
"js": {
|
22
46
|
"properties": [
|
47
|
+
{
|
48
|
+
"name": "design",
|
49
|
+
"description": "Defines the component design.",
|
50
|
+
"value": {
|
51
|
+
"type": "\"Default\" | \"Positive\" | \"Negative\" | \"Transparent\" | \"Emphasized\" | \"Attention\" | undefined"
|
52
|
+
}
|
53
|
+
},
|
23
54
|
{
|
24
55
|
"name": "disabled",
|
25
56
|
"description": "Defines whether the component is disabled.\nA disabled component can't be pressed or\nfocused, and it is not in the tab chain.",
|
26
57
|
"value": { "type": "boolean" }
|
58
|
+
},
|
59
|
+
{
|
60
|
+
"name": "state",
|
61
|
+
"description": "Defines the current state of the component.",
|
62
|
+
"value": { "type": "string | undefined" }
|
63
|
+
}
|
64
|
+
],
|
65
|
+
"events": [
|
66
|
+
{
|
67
|
+
"name": "click",
|
68
|
+
"description": "Fired when the component is activated either with a\nmouse/tap or by using the Enter or Space key."
|
69
|
+
}
|
70
|
+
]
|
71
|
+
}
|
72
|
+
},
|
73
|
+
{
|
74
|
+
"name": "ui5-ai-button-state",
|
75
|
+
"description": "### Overview\n\n`ui5-ai-button-state` is the item to use for defining states of `ui5-ai-button` components.\n\n### Usage\n\n`ui5-si-button-state` is an abstract element, representing a state of `ui5-ai-button`. It is meant to be used in the `states` slot\nof `ui5-ai-button` and should be used as standalone component.\n\n### ES6 Module Import\n\n`import \"@ui5/webcomponents/dist/AiButtonState.js\";`\n---\n",
|
76
|
+
"doc-url": "",
|
77
|
+
"attributes": [
|
78
|
+
{
|
79
|
+
"name": "name",
|
80
|
+
"description": "Defines the name of the button state.",
|
81
|
+
"value": { "type": "string | undefined", "default": "undefined" }
|
82
|
+
},
|
83
|
+
{
|
84
|
+
"name": "text",
|
85
|
+
"description": "Defines the text of the button in this state.",
|
86
|
+
"value": { "type": "string | undefined", "default": "undefined" }
|
87
|
+
},
|
88
|
+
{
|
89
|
+
"name": "icon",
|
90
|
+
"description": "Defines the icon to be displayed as graphical element within the component before the text.\nThe SAP-icons font provides numerous options.\n\n**Example:**\n\nSee all the available icons in the [Icon Explorer](https://sdk.openui5.org/test-resources/sap/m/demokit/iconExplorer/webapp/index.html).",
|
91
|
+
"value": { "type": "string | undefined", "default": "undefined" }
|
92
|
+
},
|
93
|
+
{
|
94
|
+
"name": "end-icon",
|
95
|
+
"description": "Defines the icon to be displayed as graphical element within the component after the text.\nThe SAP-icons font provides numerous options.\n\n**Example:**\n\nSee all the available icons in the [Icon Explorer](https://sdk.openui5.org/test-resources/sap/m/demokit/iconExplorer/webapp/index.html).",
|
96
|
+
"value": { "type": "string | undefined", "default": "undefined" }
|
97
|
+
}
|
98
|
+
],
|
99
|
+
"events": [],
|
100
|
+
"js": {
|
101
|
+
"properties": [
|
102
|
+
{
|
103
|
+
"name": "name",
|
104
|
+
"description": "Defines the name of the button state.",
|
105
|
+
"value": { "type": "string | undefined" }
|
106
|
+
},
|
107
|
+
{
|
108
|
+
"name": "text",
|
109
|
+
"description": "Defines the text of the button in this state.",
|
110
|
+
"value": { "type": "string | undefined" }
|
111
|
+
},
|
112
|
+
{
|
113
|
+
"name": "icon",
|
114
|
+
"description": "Defines the icon to be displayed as graphical element within the component before the text.\nThe SAP-icons font provides numerous options.\n\n**Example:**\n\nSee all the available icons in the [Icon Explorer](https://sdk.openui5.org/test-resources/sap/m/demokit/iconExplorer/webapp/index.html).",
|
115
|
+
"value": { "type": "string | undefined" }
|
116
|
+
},
|
117
|
+
{
|
118
|
+
"name": "end-icon",
|
119
|
+
"description": "Defines the icon to be displayed as graphical element within the component after the text.\nThe SAP-icons font provides numerous options.\n\n**Example:**\n\nSee all the available icons in the [Icon Explorer](https://sdk.openui5.org/test-resources/sap/m/demokit/iconExplorer/webapp/index.html).",
|
120
|
+
"value": { "type": "string | undefined" }
|
27
121
|
}
|
28
122
|
],
|
29
123
|
"events": []
|
@@ -31,25 +125,142 @@
|
|
31
125
|
},
|
32
126
|
{
|
33
127
|
"name": "ui5-ai-prompt-input",
|
34
|
-
"description": "### Overview\n\nThe
|
128
|
+
"description": "### Overview\n\nThe `ui5-ai-prompt-input` component allows the user to write custom instructions in natural language, so that AI is guided to generate content tailored to user needs.\n\n**Note:** The web component is in an experimental state\n\n### ES6 Module Import\n\n`import \"@ui5/webcomponents-ai/dist/PromptInput.js\n---\n\n\n### **Events:**\n - **submit** - Fired when the input operation has finished by pressing Enter\nor AI button is clicked.\n- **input** - Fired when the value of the component changes at each keystroke,\nand when a suggestion item has been selected.\n- **change** - Fired when the input operation has finished by pressing Enter\nor on focusout.\n\n### **Slots:**\n - **valueStateMessage** - Defines the value state message that will be displayed as pop up under the component.\nThe value state message slot should contain only one root element.\n\n**Note:** If not specified, a default text (in the respective language) will be displayed.\n\n**Note:** The `valueStateMessage` would be displayed,\nwhen the component is in `Information`, `Critical` or `Negative` value state.",
|
35
129
|
"doc-url": "",
|
36
130
|
"attributes": [
|
37
131
|
{
|
38
132
|
"name": "value",
|
39
|
-
"description": "Defines the value of the
|
133
|
+
"description": "Defines the value of the component.",
|
40
134
|
"value": { "type": "string", "default": "\"\"" }
|
135
|
+
},
|
136
|
+
{
|
137
|
+
"name": "placeholder",
|
138
|
+
"description": "Defines a short hint intended to aid the user with data entry when the\ncomponent has no value.",
|
139
|
+
"value": { "type": "string | undefined", "default": "undefined" }
|
140
|
+
},
|
141
|
+
{
|
142
|
+
"name": "label",
|
143
|
+
"description": "Defines the label of the input field.",
|
144
|
+
"value": { "type": "string | undefined", "default": "undefined" }
|
145
|
+
},
|
146
|
+
{
|
147
|
+
"name": "show-clear-icon",
|
148
|
+
"description": "Defines whether the clear icon of the input will be shown.",
|
149
|
+
"value": { "type": "boolean", "default": "false" }
|
150
|
+
},
|
151
|
+
{
|
152
|
+
"name": "show-exceeded-text",
|
153
|
+
"description": "Determines whether the characters exceeding the maximum allowed character count are visible\nin the component.\n\nIf set to `false`, the user is not allowed to enter more characters than what is set in the\n`maxlength` property.\nIf set to `true` the characters exceeding the `maxlength` value are selected on\npaste and the counter below the component displays their number.",
|
154
|
+
"value": { "type": "boolean", "default": "false" }
|
155
|
+
},
|
156
|
+
{
|
157
|
+
"name": "disabled",
|
158
|
+
"description": "Defines whether the component is in disabled state.\n\n**Note:** A disabled component is completely noninteractive.",
|
159
|
+
"value": { "type": "boolean", "default": "false" }
|
160
|
+
},
|
161
|
+
{
|
162
|
+
"name": "readonly",
|
163
|
+
"description": "Defines whether the component is read-only.\n\n**Note:** A read-only component is not editable,\nbut still provides visual feedback upon user interaction.",
|
164
|
+
"value": { "type": "boolean", "default": "false" }
|
165
|
+
},
|
166
|
+
{
|
167
|
+
"name": "maxlength",
|
168
|
+
"description": "Sets the maximum number of characters available in the input field.",
|
169
|
+
"value": { "type": "number | undefined", "default": "undefined" }
|
170
|
+
},
|
171
|
+
{
|
172
|
+
"name": "value-state",
|
173
|
+
"description": "Defines the value state of the component.",
|
174
|
+
"value": {
|
175
|
+
"type": "\"Positive\" | \"Negative\" | \"None\" | \"Critical\" | \"Information\"",
|
176
|
+
"default": "\"None\""
|
177
|
+
}
|
178
|
+
}
|
179
|
+
],
|
180
|
+
"slots": [
|
181
|
+
{
|
182
|
+
"name": "valueStateMessage",
|
183
|
+
"description": "Defines the value state message that will be displayed as pop up under the component.\nThe value state message slot should contain only one root element.\n\n**Note:** If not specified, a default text (in the respective language) will be displayed.\n\n**Note:** The `valueStateMessage` would be displayed,\nwhen the component is in `Information`, `Critical` or `Negative` value state."
|
184
|
+
}
|
185
|
+
],
|
186
|
+
"events": [
|
187
|
+
{
|
188
|
+
"name": "submit",
|
189
|
+
"description": "Fired when the input operation has finished by pressing Enter\nor AI button is clicked."
|
190
|
+
},
|
191
|
+
{
|
192
|
+
"name": "input",
|
193
|
+
"description": "Fired when the value of the component changes at each keystroke,\nand when a suggestion item has been selected."
|
194
|
+
},
|
195
|
+
{
|
196
|
+
"name": "change",
|
197
|
+
"description": "Fired when the input operation has finished by pressing Enter\nor on focusout."
|
41
198
|
}
|
42
199
|
],
|
43
|
-
"events": [],
|
44
200
|
"js": {
|
45
201
|
"properties": [
|
46
202
|
{
|
47
203
|
"name": "value",
|
48
|
-
"description": "Defines the value of the
|
204
|
+
"description": "Defines the value of the component.",
|
49
205
|
"value": { "type": "string" }
|
206
|
+
},
|
207
|
+
{
|
208
|
+
"name": "placeholder",
|
209
|
+
"description": "Defines a short hint intended to aid the user with data entry when the\ncomponent has no value.",
|
210
|
+
"value": { "type": "string | undefined" }
|
211
|
+
},
|
212
|
+
{
|
213
|
+
"name": "label",
|
214
|
+
"description": "Defines the label of the input field.",
|
215
|
+
"value": { "type": "string | undefined" }
|
216
|
+
},
|
217
|
+
{
|
218
|
+
"name": "show-clear-icon",
|
219
|
+
"description": "Defines whether the clear icon of the input will be shown.",
|
220
|
+
"value": { "type": "boolean" }
|
221
|
+
},
|
222
|
+
{
|
223
|
+
"name": "show-exceeded-text",
|
224
|
+
"description": "Determines whether the characters exceeding the maximum allowed character count are visible\nin the component.\n\nIf set to `false`, the user is not allowed to enter more characters than what is set in the\n`maxlength` property.\nIf set to `true` the characters exceeding the `maxlength` value are selected on\npaste and the counter below the component displays their number.",
|
225
|
+
"value": { "type": "boolean" }
|
226
|
+
},
|
227
|
+
{
|
228
|
+
"name": "disabled",
|
229
|
+
"description": "Defines whether the component is in disabled state.\n\n**Note:** A disabled component is completely noninteractive.",
|
230
|
+
"value": { "type": "boolean" }
|
231
|
+
},
|
232
|
+
{
|
233
|
+
"name": "readonly",
|
234
|
+
"description": "Defines whether the component is read-only.\n\n**Note:** A read-only component is not editable,\nbut still provides visual feedback upon user interaction.",
|
235
|
+
"value": { "type": "boolean" }
|
236
|
+
},
|
237
|
+
{
|
238
|
+
"name": "maxlength",
|
239
|
+
"description": "Sets the maximum number of characters available in the input field.",
|
240
|
+
"value": { "type": "number | undefined" }
|
241
|
+
},
|
242
|
+
{
|
243
|
+
"name": "value-state",
|
244
|
+
"description": "Defines the value state of the component.",
|
245
|
+
"value": {
|
246
|
+
"type": "\"Positive\" | \"Negative\" | \"None\" | \"Critical\" | \"Information\""
|
247
|
+
}
|
50
248
|
}
|
51
249
|
],
|
52
|
-
"events": [
|
250
|
+
"events": [
|
251
|
+
{
|
252
|
+
"name": "submit",
|
253
|
+
"description": "Fired when the input operation has finished by pressing Enter\nor AI button is clicked."
|
254
|
+
},
|
255
|
+
{
|
256
|
+
"name": "input",
|
257
|
+
"description": "Fired when the value of the component changes at each keystroke,\nand when a suggestion item has been selected."
|
258
|
+
},
|
259
|
+
{
|
260
|
+
"name": "change",
|
261
|
+
"description": "Fired when the input operation has finished by pressing Enter\nor on focusout."
|
262
|
+
}
|
263
|
+
]
|
53
264
|
}
|
54
265
|
}
|
55
266
|
]
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@ui5/webcomponents-ai",
|
3
|
-
"version": "2.0.0
|
3
|
+
"version": "2.0.0",
|
4
4
|
"description": "UI5 Web Components: webcomponents.ai",
|
5
5
|
"ui5": {
|
6
6
|
"webComponentsPackage": true
|
@@ -45,14 +45,14 @@
|
|
45
45
|
"directory": "packages/ai"
|
46
46
|
},
|
47
47
|
"dependencies": {
|
48
|
-
"@ui5/webcomponents": "2.0.0
|
49
|
-
"@ui5/webcomponents-base": "2.0.0
|
50
|
-
"@ui5/webcomponents-icons": "2.0.0
|
51
|
-
"@ui5/webcomponents-theming": "2.0.0
|
48
|
+
"@ui5/webcomponents": "2.0.0",
|
49
|
+
"@ui5/webcomponents-base": "2.0.0",
|
50
|
+
"@ui5/webcomponents-icons": "2.0.0",
|
51
|
+
"@ui5/webcomponents-theming": "2.0.0"
|
52
52
|
},
|
53
53
|
"devDependencies": {
|
54
|
-
"@ui5/webcomponents-tools": "2.0.0
|
54
|
+
"@ui5/webcomponents-tools": "2.0.0",
|
55
55
|
"chromedriver": "^125.0.0"
|
56
56
|
},
|
57
|
-
"gitHead": "
|
57
|
+
"gitHead": "2960694d66c4b62d4240e3d45e1401dd94f61aec"
|
58
58
|
}
|
package/src/Button.hbs
CHANGED
@@ -1,3 +1,17 @@
|
|
1
|
-
<ui5-button
|
2
|
-
|
3
|
-
|
1
|
+
<ui5-button
|
2
|
+
class="ui5-ai-button-inner"
|
3
|
+
design="{{design}}"
|
4
|
+
icon={{_stateIcon}}
|
5
|
+
end-icon={{_stateEndIcon}}
|
6
|
+
?disabled="{{disabled}}"
|
7
|
+
@click={{_onclick}}
|
8
|
+
>
|
9
|
+
{{#if _hasText}}
|
10
|
+
<div class="ui5-ai-button-text">{{_stateText}}</div>
|
11
|
+
{{/if}}
|
12
|
+
</ui5-button>
|
13
|
+
|
14
|
+
<ui5-button
|
15
|
+
class="ui5-ai-button-hidden"
|
16
|
+
design="{{design}}"
|
17
|
+
></ui5-button>
|
@@ -0,0 +1,31 @@
|
|
1
|
+
<div class="ai-prompt-input-wrapper">
|
2
|
+
{{#if label}}
|
3
|
+
<ui5-label for="input">{{label}}</ui5-label>
|
4
|
+
{{/if}}
|
5
|
+
|
6
|
+
<div class="ai-prompt-input-form-wrapper">
|
7
|
+
<div class="ai-prompt-inner-input-wrapper">
|
8
|
+
<ui5-input
|
9
|
+
id="input"
|
10
|
+
.value="{{value}}"
|
11
|
+
placeholder="{{placeholder}}"
|
12
|
+
value-state="{{valueState}}"
|
13
|
+
?show-clear-icon={{showClearIcon}}
|
14
|
+
?disabled="{{disabled}}"
|
15
|
+
?readonly="{{readonly}}"
|
16
|
+
@keydown="{{_onkeydown}}"
|
17
|
+
@ui5-input="{{_onInnerInput}}"
|
18
|
+
@ui5-change="{{_onInnerChange}}"
|
19
|
+
>
|
20
|
+
{{#if valueStateMessage.length}}
|
21
|
+
<slot name="valueStateMessage" slot="valueStateMessage"></slot>
|
22
|
+
{{/if}}
|
23
|
+
</ui5-input>
|
24
|
+
|
25
|
+
{{#if showExceededText}}
|
26
|
+
<ui5-label class="ai-prompt-input-counter">{{_exceededText}}</ui5-label>
|
27
|
+
{{/if}}
|
28
|
+
</div>
|
29
|
+
<ui5-button ?disabled={{_submitButtonDisabled}} class="ai-prompt-input-button" design="Emphasized" icon="paper-plane" @click="{{_onButtonClick}}"></ui5-button>
|
30
|
+
</div>
|
31
|
+
</div>
|
@@ -1,2 +1,8 @@
|
|
1
1
|
#This is the resource bundle for the UI5 Web Components
|
2
2
|
#__ldi.translation.uuid=96bea51a-d5e3-46f0-b1d1-514d97be02ec
|
3
|
+
|
4
|
+
#XTXT: Text for characters left
|
5
|
+
PROMPT_INPUT_CHARACTERS_LEFT={0} characters remaining
|
6
|
+
|
7
|
+
#XTXT: Text for characters over
|
8
|
+
PROMPT_INPUT_CHARACTERS_EXCEEDED={0} characters over limit
|