@fundamental-styles/mcp 0.41.7-rc.8 → 0.41.7
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/data/AI_USAGE.md +425 -0
- package/data/CHANGELOG.md +53 -3
- package/data/component-catalog.json +62 -209
- package/data/components/README.md +281 -0
- package/data/components/action-bar.md +443 -0
- package/data/components/ai-busy-indicator.md +79 -0
- package/data/components/ai-loading-bar.md +66 -0
- package/data/components/avatar-btp.md +198 -0
- package/data/components/avatar-group.md +2660 -0
- package/data/components/avatar-product-switch.md +476 -0
- package/data/components/avatar.md +993 -0
- package/data/components/bar.md +574 -0
- package/data/components/border-radius.md +148 -0
- package/data/components/border.md +412 -0
- package/data/components/breadcrumb.md +546 -0
- package/data/components/button-2.md +440 -0
- package/data/components/button-action-sheet.md +292 -0
- package/data/components/button-ai.md +730 -0
- package/data/components/button-btp.md +223 -0
- package/data/components/button-button.md +233 -0
- package/data/components/button-counter.md +176 -0
- package/data/components/button-patterns.md +731 -0
- package/data/components/button-split.md +459 -0
- package/data/components/button.md +469 -0
- package/data/components/calendar.md +5784 -0
- package/data/components/card-card-media.md +707 -0
- package/data/components/card-card.md +2426 -0
- package/data/components/card-layouts.md +1201 -0
- package/data/components/card.md +2404 -0
- package/data/components/carousel.md +1506 -0
- package/data/components/code.md +139 -0
- package/data/components/component-reset.md +272 -0
- package/data/components/components-icons-businesssuiteinappsymbol-icons.md +85 -0
- package/data/components/components-icons-sap-icons.md +147 -0
- package/data/components/components-icons-tnt-icons.md +85 -0
- package/data/components/container-queries.md +221 -0
- package/data/components/container.md +227 -0
- package/data/components/dialog-docs-static-busy-indicator.md +165 -0
- package/data/components/dialog-docs-static-dialog.md +949 -0
- package/data/components/dialog-docs-static-patterns.md +147 -0
- package/data/components/dialog-docs-static-settings.md +528 -0
- package/data/components/dialog-docs-static.md +982 -0
- package/data/components/dialog.md +606 -0
- package/data/components/dynamic-page-dynamic-page.md +1914 -0
- package/data/components/dynamic-page.md +973 -0
- package/data/components/dynamic-side.md +197 -0
- package/data/components/elevation.md +110 -0
- package/data/components/feed-input.md +346 -0
- package/data/components/feed-list.md +580 -0
- package/data/components/fieldset-2.md +292 -0
- package/data/components/fieldset-forms.md +169 -0
- package/data/components/fieldset.md +381 -0
- package/data/components/flexible-column-layout.md +205 -0
- package/data/components/form-group.md +287 -0
- package/data/components/form-header.md +71 -0
- package/data/components/form-item-2.md +98 -0
- package/data/components/form-item-3.md +134 -0
- package/data/components/form-item-4.md +556 -0
- package/data/components/form-item-5.md +182 -0
- package/data/components/form-item-6.md +539 -0
- package/data/components/form-item-7.md +239 -0
- package/data/components/form-item-ai.md +158 -0
- package/data/components/form-item-file-uploader.md +445 -0
- package/data/components/form-item-forms.md +234 -0
- package/data/components/form-item-patterns.md +426 -0
- package/data/components/form-item.md +464 -0
- package/data/components/form-label-ai.md +126 -0
- package/data/components/form-label-layouts.md +306 -0
- package/data/components/form-label-patterns.md +1175 -0
- package/data/components/form-label-status-indicator.md +1083 -0
- package/data/components/form-label-step-input.md +620 -0
- package/data/components/form-label.md +2876 -0
- package/data/components/generic-tag.md +747 -0
- package/data/components/grid-list-grid-list.md +1185 -0
- package/data/components/grid-list.md +1449 -0
- package/data/components/heading.md +66 -0
- package/data/components/horizontal-navigation.md +568 -0
- package/data/components/icon-tab-bar-dev.md +190 -0
- package/data/components/icon-tab-bar.md +2620 -0
- package/data/components/icon.md +171 -0
- package/data/components/iconBusinessSuite.md +92 -0
- package/data/components/iconTnt.md +92 -0
- package/data/components/illustrated-message.md +439 -0
- package/data/components/info-label.md +348 -0
- package/data/components/input-group.md +2068 -0
- package/data/components/label.md +66 -0
- package/data/components/layout-grid.md +447 -0
- package/data/components/layout-panel.md +261 -0
- package/data/components/layouts-layout-grid.md +608 -0
- package/data/components/layouts-paddings.md +133 -0
- package/data/components/layouts-section.md +287 -0
- package/data/components/list-2.md +148 -0
- package/data/components/list-3.md +735 -0
- package/data/components/list-list.md +790 -0
- package/data/components/list-object-list.md +1225 -0
- package/data/components/list.md +1286 -0
- package/data/components/media-queries.md +168 -0
- package/data/components/menu.md +946 -0
- package/data/components/message-box-docs-static-ai.md +149 -0
- package/data/components/message-box-docs-static.md +527 -0
- package/data/components/message-page-upload-collection.md +678 -0
- package/data/components/message-page.md +256 -0
- package/data/components/message-strip.md +977 -0
- package/data/components/message-toast.md +119 -0
- package/data/components/micro-process-flow.md +991 -0
- package/data/components/navigation-menu.md +366 -0
- package/data/components/navigation-navigation.md +1245 -0
- package/data/components/navigation.md +2604 -0
- package/data/components/numeric-content.md +317 -0
- package/data/components/object-attribute.md +96 -0
- package/data/components/object-identifier.md +227 -0
- package/data/components/object-marker.md +202 -0
- package/data/components/object-number.md +327 -0
- package/data/components/object-status.md +1538 -0
- package/data/components/off-screen.md +87 -0
- package/data/components/overflow.md +97 -0
- package/data/components/padding.md +122 -0
- package/data/components/paddings.md +130 -0
- package/data/components/page.md +300 -0
- package/data/components/pagination.md +672 -0
- package/data/components/panel-layouts.md +345 -0
- package/data/components/panel.md +514 -0
- package/data/components/patterns-label.md +74 -0
- package/data/components/popover-2.md +906 -0
- package/data/components/popover-ai.md +466 -0
- package/data/components/popover-btp.md +886 -0
- package/data/components/popover-deprecated.md +308 -0
- package/data/components/popover-message-popover.md +683 -0
- package/data/components/popover-notification.md +1511 -0
- package/data/components/popover-patterns.md +1100 -0
- package/data/components/popover-popover.md +1862 -0
- package/data/components/popover-quick-view.md +385 -0
- package/data/components/popover-timepicker.md +1836 -0
- package/data/components/popover-user-menu.md +1303 -0
- package/data/components/popover.md +1938 -0
- package/data/components/progress-indicator.md +351 -0
- package/data/components/prompt-input-ai.md +226 -0
- package/data/components/prompt-input.md +226 -0
- package/data/components/rating-indicator.md +1469 -0
- package/data/components/resizable-card-layout.md +951 -0
- package/data/components/scrollbar.md +86 -0
- package/data/components/search-field.md +287 -0
- package/data/components/section.md +250 -0
- package/data/components/segmented-button.md +324 -0
- package/data/components/shellbar.md +2183 -0
- package/data/components/side-nav.md +1562 -0
- package/data/components/skeleton.md +243 -0
- package/data/components/slider.md +395 -0
- package/data/components/splitter.md +353 -0
- package/data/components/table.md +2749 -0
- package/data/components/tabs.md +658 -0
- package/data/components/text-text.md +380 -0
- package/data/components/text.md +253 -0
- package/data/components/tile.md +1132 -0
- package/data/components/time.md +818 -0
- package/data/components/title.md +153 -0
- package/data/components/titles.md +83 -0
- package/data/components/token.md +311 -0
- package/data/components/tokenizer.md +398 -0
- package/data/components/tool-header.md +1352 -0
- package/data/components/tool-layout.md +199 -0
- package/data/components/toolbar-ai.md +174 -0
- package/data/components/toolbar-btp.md +526 -0
- package/data/components/toolbar-title-bar.md +473 -0
- package/data/components/toolbar.md +432 -0
- package/data/components/tree.md +1031 -0
- package/data/components/typography.md +435 -0
- package/data/components/variant-management.md +360 -0
- package/data/components/vertical-nav.md +589 -0
- package/data/components/wizard.md +1429 -0
- package/data/examples/Components/dialog/device-specifications.example.html +39 -30
- package/data/examples/Components/shellbar/optional-items.example.html +210 -157
- package/data/examples/Components/shellbar/overflow-toolbar.example.html +202 -177
- package/data/examples/Components/shellbar/responsive-paddings.example.html +217 -146
- package/data/examples/Components/shellbar/responsiveness.example.html +825 -613
- package/data/examples/Components/user-menu/default.example.html +241 -83
- package/data/schemas/badge.schema.json +1 -1
- package/data/schemas/button-split.schema.json +1 -1
- package/data/schemas/component-frontmatter.schema.json +123 -0
- package/data/schemas/component-markdown.schema.json +81 -0
- package/data/schemas/counter.schema.json +1 -1
- package/data/schemas/dynamic-page.schema.json +1 -1
- package/data/schemas/dynamic-side-content.schema.json +1 -1
- package/data/schemas/facet.schema.json +1 -1
- package/data/schemas/fieldset.schema.json +1 -1
- package/data/schemas/flexible-column-layout.schema.json +1 -1
- package/data/schemas/form-group.schema.json +3 -2
- package/data/schemas/form-header.schema.json +1 -1
- package/data/schemas/form-label.schema.json +1 -0
- package/data/schemas/form-message.schema.json +1 -1
- package/data/schemas/grid-list.schema.json +1 -1
- package/data/schemas/input-group.schema.json +1 -1
- package/data/schemas/layout-panel.schema.json +1 -1
- package/data/schemas/page.schema.json +1 -1
- package/data/schemas/quick-view.schema.json +2 -1
- package/data/schemas/section.schema.json +1 -1
- package/data/schemas/side-nav.schema.json +1 -1
- package/data/schemas/splitter.schema.json +1 -1
- package/data/schemas/tabs.schema.json +1 -1
- package/data/schemas/tile.schema.json +1 -1
- package/data/schemas/tool-layout.schema.json +1 -1
- package/data/schemas/user-menu.schema.json +10 -0
- package/data/schemas/wizard.schema.json +1 -1
- package/package.json +1 -1
- package/src/data/load-catalog.d.ts +2 -0
- package/src/data/load-catalog.js +5 -1
- package/src/data/load-catalog.js.map +1 -1
- package/src/data/load-markdown-docs.d.ts +44 -0
- package/src/data/load-markdown-docs.js +179 -0
- package/src/data/load-markdown-docs.js.map +1 -0
- package/src/data/markdown-cache.d.ts +60 -0
- package/src/data/markdown-cache.js +218 -0
- package/src/data/markdown-cache.js.map +1 -0
- package/src/server.js +72 -1
- package/src/server.js.map +1 -1
|
@@ -0,0 +1,556 @@
|
|
|
1
|
+
---
|
|
2
|
+
component: fd-form-item
|
|
3
|
+
title: Components/Forms/Input Group
|
|
4
|
+
category: Components
|
|
5
|
+
selector: fd-form-item
|
|
6
|
+
cssFile: form-item.css
|
|
7
|
+
sourcePath: packages/styles/stories/Components/Forms/input-group/input-group.stories.js
|
|
8
|
+
tags: []
|
|
9
|
+
dependencies: []
|
|
10
|
+
relatedComponents: []
|
|
11
|
+
stability: stable
|
|
12
|
+
generatedAt: 2026-06-09T18:29:01.581Z
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
# Components/Forms/Input Group
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
## Installation
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
npm install fundamental-styles
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
```html
|
|
26
|
+
<!-- Include theme -->
|
|
27
|
+
<link href="node_modules/fundamental-styles/dist/theming/sap_horizon.css" rel="stylesheet">
|
|
28
|
+
|
|
29
|
+
<!-- Include component CSS -->
|
|
30
|
+
<link href="node_modules/fundamental-styles/dist/form-item.css" rel="stylesheet">
|
|
31
|
+
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Basic Usage
|
|
35
|
+
|
|
36
|
+
```html
|
|
37
|
+
<div class="fd-form-item">
|
|
38
|
+
<label class="fd-form-label" for="aqwsde111">Amount</label>
|
|
39
|
+
<div class="fd-input-group">
|
|
40
|
+
<span class="fd-input-group__addon" aria-hidden="true">$</span>
|
|
41
|
+
<input
|
|
42
|
+
class="fd-input fd-input-group__input"
|
|
43
|
+
type="text"
|
|
44
|
+
placeholder="Placeholder"
|
|
45
|
+
id="aqwsde111"
|
|
46
|
+
name="amount"
|
|
47
|
+
value="100.00"
|
|
48
|
+
autocomplete="off"
|
|
49
|
+
aria-describedby="input-group-note"
|
|
50
|
+
>
|
|
51
|
+
<div class="fd-input-group__sr-only" id="input-group-note">Enter amount in US dollars</div>
|
|
52
|
+
</div>
|
|
53
|
+
</div>
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
## States
|
|
57
|
+
|
|
58
|
+
| Class | Description |
|
|
59
|
+
|-------|-------------|
|
|
60
|
+
| `is-disabled` | Disabled state |
|
|
61
|
+
| `is-error` | Error state |
|
|
62
|
+
| `is-focus` | Focus state |
|
|
63
|
+
| `is-information` | Information state |
|
|
64
|
+
| `is-readonly` | Readonly state |
|
|
65
|
+
| `is-success` | Success state |
|
|
66
|
+
| `is-warning` | Warning state |
|
|
67
|
+
|
|
68
|
+
## Examples
|
|
69
|
+
|
|
70
|
+
### Default
|
|
71
|
+
|
|
72
|
+
Basic Input Group with no additional elements or value state modifiers.
|
|
73
|
+
|
|
74
|
+
```html
|
|
75
|
+
<div class="fd-form-item">
|
|
76
|
+
<label class="fd-form-label" for="aqwsde111">Amount</label>
|
|
77
|
+
<div class="fd-input-group">
|
|
78
|
+
<span class="fd-input-group__addon" aria-hidden="true">$</span>
|
|
79
|
+
<input
|
|
80
|
+
class="fd-input fd-input-group__input"
|
|
81
|
+
type="text"
|
|
82
|
+
placeholder="Placeholder"
|
|
83
|
+
id="aqwsde111"
|
|
84
|
+
name="amount"
|
|
85
|
+
value="100.00"
|
|
86
|
+
autocomplete="off"
|
|
87
|
+
aria-describedby="input-group-note"
|
|
88
|
+
>
|
|
89
|
+
<div class="fd-input-group__sr-only" id="input-group-note">Enter amount in US dollars</div>
|
|
90
|
+
</div>
|
|
91
|
+
</div>
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
### TextAddOn
|
|
95
|
+
|
|
96
|
+
An Input Group with a text add-on (e.g., currency or unit). The add-on can be positioned before, after, or on both sides of the input field to clarify the expected value format.
|
|
97
|
+
|
|
98
|
+
```html
|
|
99
|
+
<!-- Left Aligned Text Add-on -->
|
|
100
|
+
<div class="fd-form-item">
|
|
101
|
+
<label class="fd-form-label" for="amount-usd-left">Left Aligned Text Add-on</label>
|
|
102
|
+
<div class="fd-input-group">
|
|
103
|
+
<span class="fd-input-group__addon" aria-hidden="true">$</span>
|
|
104
|
+
<input
|
|
105
|
+
class="fd-input fd-input-group__input"
|
|
106
|
+
type="text"
|
|
107
|
+
id="amount-usd-left"
|
|
108
|
+
name="amount-usd-left"
|
|
109
|
+
placeholder="Placeholder"
|
|
110
|
+
value="100"
|
|
111
|
+
autocomplete="off"
|
|
112
|
+
aria-describedby="amount-usd-left-note">
|
|
113
|
+
<div class="fd-input-group__sr-only" id="amount-usd-left-note">
|
|
114
|
+
Enter amount in US dollars
|
|
115
|
+
</div>
|
|
116
|
+
</div>
|
|
117
|
+
</div>
|
|
118
|
+
|
|
119
|
+
<!-- Right Aligned Text Add-on -->
|
|
120
|
+
<div class="fd-form-item">
|
|
121
|
+
<label class="fd-form-label" for="amount-euro-right">Right Aligned Text Add-on</label>
|
|
122
|
+
<div class="fd-input-group">
|
|
123
|
+
<input
|
|
124
|
+
class="fd-input fd-input-group__input"
|
|
125
|
+
type="text"
|
|
126
|
+
id="amount-euro-right"
|
|
127
|
+
name="amount-euro-right"
|
|
128
|
+
placeholder="Placeholder"
|
|
129
|
+
value="100"
|
|
130
|
+
autocomplete="off"
|
|
131
|
+
aria-describedby="amount-euro-right-note">
|
|
132
|
+
<span class="fd-input-group__addon" aria-hidden="true">€</span>
|
|
133
|
+
<div class="fd-input-group__sr-only" id="amount-euro-right-note">
|
|
134
|
+
Enter amount in euro
|
|
135
|
+
</div>
|
|
136
|
+
</div>
|
|
137
|
+
</div>
|
|
138
|
+
|
|
139
|
+
<!-- Right Aligned Text Add-on With Right Aligned Input Text -->
|
|
140
|
+
<div class="fd-form-item">
|
|
141
|
+
<label class="fd-form-label" for="amount-euro-right-align">Right Aligned Text Add-on With Right Aligned Input Text</label>
|
|
142
|
+
<div class="fd-input-group">
|
|
143
|
+
<input
|
|
144
|
+
class="fd-input fd-input-group__input right-align"
|
|
145
|
+
type="text"
|
|
146
|
+
id="amount-euro-right-align"
|
|
147
|
+
name="amount-euro-right-align"
|
|
148
|
+
value="100"
|
|
149
|
+
autocomplete="off"
|
|
150
|
+
aria-describedby="amount-euro-right-align-note">
|
|
151
|
+
<span class="fd-input-group__addon" aria-hidden="true">€</span>
|
|
152
|
+
<div class="fd-input-group__sr-only" id="amount-euro-right-align-note">
|
|
153
|
+
Enter amount in euro
|
|
154
|
+
</div>
|
|
155
|
+
</div>
|
|
156
|
+
</div>
|
|
157
|
+
|
|
158
|
+
<!-- Left and Right Aligned Text Add-ons -->
|
|
159
|
+
<div class="fd-form-item">
|
|
160
|
+
<label class="fd-form-label" for="amount-usd-both">Left and Right Aligned Text Add-ons</label>
|
|
161
|
+
<div class="fd-input-group">
|
|
162
|
+
<span class="fd-input-group__addon" aria-hidden="true">$</span>
|
|
163
|
+
<input
|
|
164
|
+
class="fd-input fd-input-group__input"
|
|
165
|
+
type="text"
|
|
166
|
+
id="amount-usd-both"
|
|
167
|
+
name="amount-usd-both"
|
|
168
|
+
placeholder="Placeholder"
|
|
169
|
+
value="65"
|
|
170
|
+
autocomplete="off"
|
|
171
|
+
aria-describedby="amount-usd-both-note">
|
|
172
|
+
<span class="fd-input-group__addon" aria-hidden="true">.00</span>
|
|
173
|
+
<div class="fd-input-group__sr-only" id="amount-usd-both-note">
|
|
174
|
+
Enter amount in US dollars
|
|
175
|
+
</div>
|
|
176
|
+
</div>
|
|
177
|
+
</div>
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
### InputWithIcons
|
|
181
|
+
|
|
182
|
+
Demonstrates how to use an icon as an add-on. Typically used for visual cues like visibility toggles, status, or type indication.
|
|
183
|
+
|
|
184
|
+
```html
|
|
185
|
+
<!-- Input with icon on the left -->
|
|
186
|
+
<div class="fd-form-item">
|
|
187
|
+
<label class="fd-form-label" for="input-icon-left">Input with icon on the left</label>
|
|
188
|
+
<div class="fd-input-group">
|
|
189
|
+
<span class="fd-input-group__addon">
|
|
190
|
+
<span class="sap-icon--employee" role="presentation" aria-hidden="true"></span>
|
|
191
|
+
</span>
|
|
192
|
+
<input
|
|
193
|
+
class="fd-input fd-input-group__input"
|
|
194
|
+
type="text"
|
|
195
|
+
id="input-icon-left"
|
|
196
|
+
name="employee-name"
|
|
197
|
+
placeholder="Name"
|
|
198
|
+
autocomplete="off"
|
|
199
|
+
aria-describedby="input-icon-left-note">
|
|
200
|
+
<div class="fd-input-group__sr-only" id="input-icon-left-note">
|
|
201
|
+
Employee name
|
|
202
|
+
</div>
|
|
203
|
+
</div>
|
|
204
|
+
</div>
|
|
205
|
+
|
|
206
|
+
<!-- Input with icon on the right -->
|
|
207
|
+
<div class="fd-form-item">
|
|
208
|
+
<label class="fd-form-label" for="input-icon-right">Input with icon on the right</label>
|
|
209
|
+
<div class="fd-input-group">
|
|
210
|
+
<input
|
|
211
|
+
class="fd-input fd-input-group__input"
|
|
212
|
+
type="text"
|
|
213
|
+
id="input-icon-right"
|
|
214
|
+
name="visibility-toggle"
|
|
215
|
+
placeholder="Enter content"
|
|
216
|
+
autocomplete="off"
|
|
217
|
+
aria-describedby="input-icon-right-note">
|
|
218
|
+
<span class="fd-input-group__addon">
|
|
219
|
+
<span class="sap-icon--hide" role="presentation" aria-hidden="true"></span>
|
|
220
|
+
</span>
|
|
221
|
+
<div class="fd-input-group__sr-only" id="input-icon-right-note">
|
|
222
|
+
Enter content to toggle visibility
|
|
223
|
+
</div>
|
|
224
|
+
</div>
|
|
225
|
+
</div>
|
|
226
|
+
|
|
227
|
+
<!-- Input with icon on the right and right-aligned text -->
|
|
228
|
+
<div class="fd-form-item">
|
|
229
|
+
<label class="fd-form-label" for="input-icon-right-align">Input with icon on the right and right aligned input text</label>
|
|
230
|
+
<div class="fd-input-group">
|
|
231
|
+
<input
|
|
232
|
+
class="fd-input fd-input-group__input right-align"
|
|
233
|
+
type="text"
|
|
234
|
+
id="input-icon-right-align"
|
|
235
|
+
name="secure-entry"
|
|
236
|
+
placeholder="Enter content"
|
|
237
|
+
autocomplete="off"
|
|
238
|
+
aria-describedby="input-icon-right-align-note">
|
|
239
|
+
<span class="fd-input-group__addon">
|
|
240
|
+
<span class="sap-icon--hide" role="presentation" aria-hidden="true"></span>
|
|
241
|
+
</span>
|
|
242
|
+
<div class="fd-input-group__sr-only" id="input-icon-right-align-note">
|
|
243
|
+
Right-aligned input for secure entry
|
|
244
|
+
</div>
|
|
245
|
+
</div>
|
|
246
|
+
</div>
|
|
247
|
+
```
|
|
248
|
+
|
|
249
|
+
### InputWithActions
|
|
250
|
+
|
|
251
|
+
An Input Group with a button add-on. Supports buttons with either text or icons, typically used for actions like submit, search, or trigger.
|
|
252
|
+
|
|
253
|
+
```html
|
|
254
|
+
<!-- Input with text add-on button (right) -->
|
|
255
|
+
<div class="fd-form-item">
|
|
256
|
+
<label class="fd-form-label" for="input-text-action-right">Input with text add-on</label>
|
|
257
|
+
<div class="fd-input-group">
|
|
258
|
+
<input
|
|
259
|
+
class="fd-input fd-input-group__input"
|
|
260
|
+
type="text"
|
|
261
|
+
id="input-text-action-right"
|
|
262
|
+
name="text-action-right"
|
|
263
|
+
placeholder="Placeholder"
|
|
264
|
+
autocomplete="off"
|
|
265
|
+
value="100">
|
|
266
|
+
<span class="fd-input-group__addon fd-input-group__addon--button">
|
|
267
|
+
<button
|
|
268
|
+
class="fd-input-group__button fd-button fd-button--transparent"
|
|
269
|
+
type="button"
|
|
270
|
+
aria-label="Submit value">
|
|
271
|
+
Submit
|
|
272
|
+
</button>
|
|
273
|
+
</span>
|
|
274
|
+
</div>
|
|
275
|
+
</div>
|
|
276
|
+
|
|
277
|
+
<!-- Input with icon action (right) -->
|
|
278
|
+
<div class="fd-form-item">
|
|
279
|
+
<label class="fd-form-label" for="input-icon-action-right">Input with icon action</label>
|
|
280
|
+
<div class="fd-input-group">
|
|
281
|
+
<input
|
|
282
|
+
class="fd-input fd-input-group__input"
|
|
283
|
+
type="text"
|
|
284
|
+
id="input-icon-action-right"
|
|
285
|
+
name="icon-action-right"
|
|
286
|
+
placeholder="Placeholder"
|
|
287
|
+
autocomplete="off"
|
|
288
|
+
value="100">
|
|
289
|
+
<span class="fd-input-group__addon fd-input-group__addon--button">
|
|
290
|
+
<button
|
|
291
|
+
class="fd-input-group__button fd-button fd-button--icon fd-button--transparent"
|
|
292
|
+
type="button"
|
|
293
|
+
aria-label="Show options">
|
|
294
|
+
<i class="sap-icon--navigation-down-arrow" aria-hidden="true" role="presentation"></i>
|
|
295
|
+
</button>
|
|
296
|
+
</span>
|
|
297
|
+
</div>
|
|
298
|
+
</div>
|
|
299
|
+
|
|
300
|
+
<!-- Input with two icon actions (right) -->
|
|
301
|
+
<div class="fd-form-item">
|
|
302
|
+
<label class="fd-form-label" for="input-two-icon-actions">Input with 2 icon actions</label>
|
|
303
|
+
<div class="fd-input-group">
|
|
304
|
+
<input
|
|
305
|
+
class="fd-input fd-input-group__input"
|
|
306
|
+
type="text"
|
|
307
|
+
id="input-two-icon-actions"
|
|
308
|
+
name="two-icon-actions"
|
|
309
|
+
placeholder="Placeholder"
|
|
310
|
+
autocomplete="off"
|
|
311
|
+
value="100">
|
|
312
|
+
<span class="fd-input-group__addon fd-input-group__addon--button">
|
|
313
|
+
<button
|
|
314
|
+
class="fd-input-group__button fd-button fd-button--icon fd-button--transparent"
|
|
315
|
+
type="button"
|
|
316
|
+
aria-label="Clear input">
|
|
317
|
+
<i class="sap-icon--decline" aria-hidden="true" role="presentation"></i>
|
|
318
|
+
</button>
|
|
319
|
+
</span>
|
|
320
|
+
<span class="fd-input-group__addon fd-input-group__addon--button">
|
|
321
|
+
<button
|
|
322
|
+
class="fd-input-group__button fd-button fd-button--icon fd-button--transparent"
|
|
323
|
+
type="button"
|
|
324
|
+
aria-label="Search value">
|
|
325
|
+
<i class="sap-icon--search" aria-hidden="true" role="presentation"></i>
|
|
326
|
+
</button>
|
|
327
|
+
</span>
|
|
328
|
+
</div>
|
|
329
|
+
</div>
|
|
330
|
+
|
|
331
|
+
<!-- Input with text action on the left -->
|
|
332
|
+
<div class="fd-form-item">
|
|
333
|
+
<label class="fd-form-label" for="input-text-action-left">Input with text action on left</label>
|
|
334
|
+
<div class="fd-input-group">
|
|
335
|
+
<span class="fd-input-group__addon fd-input-group__addon--button">
|
|
336
|
+
<button
|
|
337
|
+
class="fd-input-group__button fd-button fd-button--transparent"
|
|
338
|
+
type="button"
|
|
339
|
+
aria-label="Submit value">
|
|
340
|
+
Action
|
|
341
|
+
</button>
|
|
342
|
+
</span>
|
|
343
|
+
<input
|
|
344
|
+
class="fd-input fd-input-group__input"
|
|
345
|
+
type="text"
|
|
346
|
+
id="input-text-action-left"
|
|
347
|
+
name="text-action-left"
|
|
348
|
+
placeholder="Placeholder"
|
|
349
|
+
autocomplete="off"
|
|
350
|
+
value="100">
|
|
351
|
+
</div>
|
|
352
|
+
</div>
|
|
353
|
+
```
|
|
354
|
+
|
|
355
|
+
### States
|
|
356
|
+
|
|
357
|
+
Input Groups can visually represent different validation or feedback states such as success, error, warning, and information. Use modifier classes like `.is-success`, `.is-error`, `.is-warning`, or `.is-information` on the `.fd-input-group` container.
|
|
358
|
+
|
|
359
|
+
```html
|
|
360
|
+
<div class="fd-form-item">
|
|
361
|
+
<label class="fd-form-label" for="input-success-1">Success</label>
|
|
362
|
+
<div class="fd-input-group is-success">
|
|
363
|
+
<span class="fd-input-group__addon" aria-hidden="true">$</span>
|
|
364
|
+
<input class="fd-input fd-input-group__input" type="text" id="input-success-1" name="amountSuccess"
|
|
365
|
+
value="100" placeholder="Enter amount" autocomplete="off" aria-describedby="input-success-1-note" />
|
|
366
|
+
<div class="fd-input-group__sr-only" id="input-success-1-note">Value State Success</div>
|
|
367
|
+
</div>
|
|
368
|
+
</div>
|
|
369
|
+
|
|
370
|
+
<div class="fd-form-item">
|
|
371
|
+
<label class="fd-form-label" for="input-error-1">Error</label>
|
|
372
|
+
<div class="fd-input-group is-error">
|
|
373
|
+
<input class="fd-input fd-input-group__input" type="text" id="input-error-1" name="amountError" value="100"
|
|
374
|
+
placeholder="Enter value" autocomplete="off" aria-describedby="input-error-1-note" />
|
|
375
|
+
<span class="fd-input-group__addon" aria-hidden="true">
|
|
376
|
+
<span class="sap-icon--hide" role="presentation" aria-hidden="true"></span>
|
|
377
|
+
</span>
|
|
378
|
+
<div class="fd-input-group__sr-only" id="input-error-1-note">Value State Error</div>
|
|
379
|
+
</div>
|
|
380
|
+
</div>
|
|
381
|
+
|
|
382
|
+
<div class="fd-form-item">
|
|
383
|
+
<label class="fd-form-label" for="input-warning-1">Warning</label>
|
|
384
|
+
<div class="fd-input-group is-warning">
|
|
385
|
+
<span class="fd-input-group__addon" aria-hidden="true">$</span>
|
|
386
|
+
<input class="fd-input fd-input-group__input" type="text" id="input-warning-1" name="amountWarning" value="100"
|
|
387
|
+
placeholder="Enter value" autocomplete="off" aria-describedby="input-warning-1-note" />
|
|
388
|
+
<div class="fd-input-group__sr-only" id="input-warning-1-note">Value State Warning</div>
|
|
389
|
+
</div>
|
|
390
|
+
</div>
|
|
391
|
+
|
|
392
|
+
<div class="fd-form-item">
|
|
393
|
+
<label class="fd-form-label" for="input-info-1">Information</label>
|
|
394
|
+
<div class="fd-input-group is-information">
|
|
395
|
+
<input class="fd-input fd-input-group__input" type="text" id="input-info-1" name="infoInput" value="100"
|
|
396
|
+
placeholder="Enter info" autocomplete="off" aria-describedby="input-info-1-note" />
|
|
397
|
+
<span class="fd-input-group__addon fd-input-group__addon--button">
|
|
398
|
+
<button class="fd-input-group__button fd-button fd-button--transparent" aria-label="Submit information input">
|
|
399
|
+
Button
|
|
400
|
+
</button>
|
|
401
|
+
</span>
|
|
402
|
+
<div class="fd-input-group__sr-only" id="input-info-1-note">Value State Information</div>
|
|
403
|
+
</div>
|
|
404
|
+
</div>
|
|
405
|
+
|
|
406
|
+
<div class="fd-form-item">
|
|
407
|
+
<label class="fd-form-label" for="input-disabled-1">Disabled</label>
|
|
408
|
+
<div class="fd-input-group is-disabled">
|
|
409
|
+
<span class="fd-input-group__addon" aria-hidden="true">$</span>
|
|
410
|
+
<input class="fd-input fd-input-group__input" disabled type="text" id="input-disabled-1" name="disabledAmount"
|
|
411
|
+
value="100" placeholder="Disabled input" autocomplete="off" aria-describedby="input-disabled-1-note" />
|
|
412
|
+
<div class="fd-input-group__sr-only" id="input-disabled-1-note">This field cannot be edited</div>
|
|
413
|
+
</div>
|
|
414
|
+
</div>
|
|
415
|
+
|
|
416
|
+
<div class="fd-form-item">
|
|
417
|
+
<label class="fd-form-label" for="input-readonly-1">Read-Only</label>
|
|
418
|
+
<div class="fd-input-group is-readonly">
|
|
419
|
+
<input class="fd-input fd-input-group__input" readonly type="text" id="input-readonly-1" name="readonlyAmount"
|
|
420
|
+
value="100" placeholder="Read-only value" autocomplete="off" aria-describedby="input-readonly-1-note" />
|
|
421
|
+
<span class="fd-input-group__addon fd-input-group__addon--button">
|
|
422
|
+
<button class="fd-input-group__button fd-button fd-button--transparent" aria-label="Submit (read-only)">
|
|
423
|
+
Button
|
|
424
|
+
</button>
|
|
425
|
+
</span>
|
|
426
|
+
<div class="fd-input-group__sr-only" id="input-readonly-1-note">Value cannot be changed</div>
|
|
427
|
+
</div>
|
|
428
|
+
</div>
|
|
429
|
+
```
|
|
430
|
+
|
|
431
|
+
### Focus
|
|
432
|
+
|
|
433
|
+
The focussed state of Input Group is achieved by adding the `.is-focus` class to the parent element with class `.fd-input-group`.
|
|
434
|
+
|
|
435
|
+
```html
|
|
436
|
+
<!-- Default -->
|
|
437
|
+
<div class="fd-form-item">
|
|
438
|
+
<label class="fd-form-label" for="input-default">Default</label>
|
|
439
|
+
<div class="fd-input-group is-focus">
|
|
440
|
+
<span class="fd-input-group__addon" aria-hidden="true">$</span>
|
|
441
|
+
<input
|
|
442
|
+
class="fd-input fd-input-group__input"
|
|
443
|
+
type="text"
|
|
444
|
+
id="input-default"
|
|
445
|
+
name="defaultStateFocus"
|
|
446
|
+
value="100"
|
|
447
|
+
placeholder="Placeholder"
|
|
448
|
+
autocomplete="off"
|
|
449
|
+
aria-describedby="input-default-note">
|
|
450
|
+
<div class="fd-input-group__sr-only" id="input-default-note">
|
|
451
|
+
Enter an amount in USD
|
|
452
|
+
</div>
|
|
453
|
+
</div>
|
|
454
|
+
</div>
|
|
455
|
+
|
|
456
|
+
<!-- Error -->
|
|
457
|
+
<div class="fd-form-item">
|
|
458
|
+
<label class="fd-form-label" for="input-error">Error State</label>
|
|
459
|
+
<div class="fd-input-group is-error is-focus">
|
|
460
|
+
<input
|
|
461
|
+
class="fd-input fd-input-group__input"
|
|
462
|
+
type="text"
|
|
463
|
+
id="input-error"
|
|
464
|
+
name="errorStateFocus"
|
|
465
|
+
value="100"
|
|
466
|
+
placeholder="Placeholder"
|
|
467
|
+
autocomplete="off"
|
|
468
|
+
aria-describedby="input-error-note">
|
|
469
|
+
<span class="fd-input-group__addon">
|
|
470
|
+
<span class="sap-icon--hide" role="presentation" aria-hidden="true"></span>
|
|
471
|
+
</span>
|
|
472
|
+
<div class="fd-input-group__sr-only" id="input-error-note">
|
|
473
|
+
Value State Error: The entered value is invalid.
|
|
474
|
+
</div>
|
|
475
|
+
</div>
|
|
476
|
+
</div>
|
|
477
|
+
|
|
478
|
+
<!-- Success -->
|
|
479
|
+
<div class="fd-form-item">
|
|
480
|
+
<label class="fd-form-label" for="input-success">Success State</label>
|
|
481
|
+
<div class="fd-input-group is-success is-focus">
|
|
482
|
+
<input
|
|
483
|
+
class="fd-input fd-input-group__input"
|
|
484
|
+
type="text"
|
|
485
|
+
id="input-success"
|
|
486
|
+
name="successStateFocus"
|
|
487
|
+
value="100"
|
|
488
|
+
placeholder="Placeholder"
|
|
489
|
+
autocomplete="off"
|
|
490
|
+
aria-describedby="input-success-note">
|
|
491
|
+
<span class="fd-input-group__addon">
|
|
492
|
+
<span class="sap-icon--hide" role="presentation" aria-hidden="true"></span>
|
|
493
|
+
</span>
|
|
494
|
+
<div class="fd-input-group__sr-only" id="input-success-note">
|
|
495
|
+
Value State Success: The value entered is valid.
|
|
496
|
+
</div>
|
|
497
|
+
</div>
|
|
498
|
+
</div>
|
|
499
|
+
|
|
500
|
+
<!-- Warning -->
|
|
501
|
+
<div class="fd-form-item">
|
|
502
|
+
<label class="fd-form-label" for="input-warning">Warning State</label>
|
|
503
|
+
<div class="fd-input-group is-warning is-focus">
|
|
504
|
+
<input
|
|
505
|
+
class="fd-input fd-input-group__input"
|
|
506
|
+
type="text"
|
|
507
|
+
id="input-warning"
|
|
508
|
+
name="warningStateFocus"
|
|
509
|
+
value="100"
|
|
510
|
+
placeholder="Placeholder"
|
|
511
|
+
autocomplete="off"
|
|
512
|
+
aria-describedby="input-warning-note">
|
|
513
|
+
<span class="fd-input-group__addon">
|
|
514
|
+
<span class="sap-icon--hide" role="presentation" aria-hidden="true"></span>
|
|
515
|
+
</span>
|
|
516
|
+
<div class="fd-input-group__sr-only" id="input-warning-note">
|
|
517
|
+
Value State Warning: Please double-check this value.
|
|
518
|
+
</div>
|
|
519
|
+
</div>
|
|
520
|
+
</div>
|
|
521
|
+
|
|
522
|
+
<!-- Information -->
|
|
523
|
+
<div class="fd-form-item">
|
|
524
|
+
<label class="fd-form-label" for="input-info">Information State</label>
|
|
525
|
+
<div class="fd-input-group is-information is-focus">
|
|
526
|
+
<input
|
|
527
|
+
class="fd-input fd-input-group__input"
|
|
528
|
+
type="text"
|
|
529
|
+
id="input-info"
|
|
530
|
+
name="infoStateFocus"
|
|
531
|
+
value="100"
|
|
532
|
+
placeholder="Placeholder"
|
|
533
|
+
autocomplete="off"
|
|
534
|
+
aria-describedby="input-info-note">
|
|
535
|
+
<span class="fd-input-group__addon">
|
|
536
|
+
<span class="sap-icon--hide" role="presentation" aria-hidden="true"></span>
|
|
537
|
+
</span>
|
|
538
|
+
<div class="fd-input-group__sr-only" id="input-info-note">
|
|
539
|
+
Value State Information: The input is optional.
|
|
540
|
+
</div>
|
|
541
|
+
</div>
|
|
542
|
+
</div>
|
|
543
|
+
```
|
|
544
|
+
|
|
545
|
+
## Accessibility
|
|
546
|
+
|
|
547
|
+
- Use semantic HTML elements where appropriate
|
|
548
|
+
- Include proper ARIA attributes for interactive elements
|
|
549
|
+
- Ensure keyboard navigation support
|
|
550
|
+
- Provide adequate color contrast
|
|
551
|
+
|
|
552
|
+
## Source
|
|
553
|
+
|
|
554
|
+
This documentation was automatically generated from: `packages/styles/stories/Components/Forms/input-group/input-group.stories.js`
|
|
555
|
+
|
|
556
|
+
For the latest updates and interactive examples, see [Storybook](https://sap.github.io/fundamental-styles/).
|