You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/api/select.md
+22-10Lines changed: 22 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -70,7 +70,7 @@ import SingleSelectionExample from '@site/static/usage/v8/select/basic/single-se
70
70
71
71
## Multiple Selection
72
72
73
-
By adding the `multiple` attribute to select, users are able to select multiple options. When multiple options can be selected, the alertor popover overlay presents users with a checkbox styled list of options. The select component's value receives an array of all of the selected option values.
73
+
By adding the `multiple` attribute to select, users are able to select multiple options. When multiple options can be selected, the alert, popover, or modal overlay presents users with a checkbox styled list of options. The select component's value receives an array of all of the selected option values.
74
74
75
75
:::note
76
76
@@ -86,7 +86,7 @@ import MultipleSelectionExample from '@site/static/usage/v8/select/basic/multipl
86
86
87
87
## Interfaces
88
88
89
-
By default, select uses [ion-alert](alert.md) to open up the overlay of options in an alert. The interface can be changed to use [ion-action-sheet](action-sheet.md) or [ion-popover](popover.md)by passing `action-sheet`or `popover`, respectively, to the `interface` property. Read on to the other sections for the limitations of the different interfaces.
89
+
By default, select uses [ion-alert](alert.md) to open up the overlay of options in an alert. The interface can be changed to use [ion-action-sheet](action-sheet.md), [ion-popover](popover.md), or [ion-modal](modal.md)by passing `action-sheet`, `popover`, or `modal`, respectively, to the `interface` property. Read on to the other sections for the limitations of the different interfaces.
90
90
91
91
### Alert
92
92
@@ -107,6 +107,12 @@ import PopoverExample from '@site/static/usage/v8/select/interfaces/popover/inde
107
107
108
108
<PopoverExample />
109
109
110
+
### Modal
111
+
112
+
import ModalExample from '@site/static/usage/v8/select/interfaces/modal/index.md';
113
+
114
+
<ModalExample />
115
+
110
116
## Responding to Interaction
111
117
112
118
The main ways of handling user interaction with the select are the `ionChange`, `ionDismiss`, and `ionCancel` events. See [Events](#events) for more details on these and other events that select fires.
@@ -161,15 +167,19 @@ The alert supports two buttons: `Cancel` and `OK`. Each button's text can be cus
161
167
162
168
The `action-sheet` and `popover` interfaces do not have an `OK` button, clicking on any of the options will automatically close the overlay and select that value. The `popover` interface does not have a `Cancel` button, clicking on the backdrop will close the overlay.
163
169
170
+
The `modal` interface has a single `Close` button in the header. This button is only responsible for dismissing the modal. Any selections made will persist
171
+
after clicking this button or if the modal is dismissed using an alternative method.
172
+
164
173
import ButtonTextExample from '@site/static/usage/v8/select/customization/button-text/index.md';
165
174
166
175
<ButtonTextExample />
167
176
168
177
## Interface Options
169
178
170
-
Since select uses the alert, action sheetand popover interfaces, options can be passed to these components through the `interfaceOptions` property. This can be used to pass a custom header, subheader, css class, and more.
179
+
Since select uses the alert, action sheet, popover, and modal interfaces, options can be passed to these components through the `interfaceOptions` property. This can be used to pass a custom header, subheader, css class, and more.
171
180
172
-
See the [ion-alert docs](alert.md), [ion-action-sheet docs](action-sheet.md), and [ion-popover docs](popover.md) for the properties that each interface accepts.
181
+
See the [ion-alert docs](alert.md), [ion-action-sheet docs](action-sheet.md), [ion-popover docs](popover.md), and [ion-modal docs](modal.md)
182
+
for the properties that each interface accepts.
173
183
174
184
Note: `interfaceOptions` will not override `inputs` or `buttons` with the `alert` interface.
175
185
@@ -207,11 +217,13 @@ import StylingSelectExample from '@site/static/usage/v8/select/customization/sty
207
217
208
218
### Styling Select Interface
209
219
210
-
Customizing the interface dialog should be done by following the Customization section in that interface's documentation:
220
+
Customizing the interface dialog should be done by following the styling sections (CSS shadow parts, CSS custom properties, and slots) in
However, the Select Option does set a class for easier styling and allows for the ability to pass a class to the overlay option, see the [Select Options documentation](select-option.md) for usage examples of customizing options.
217
229
@@ -304,7 +316,7 @@ These keyboard interactions apply to all `ion-select` elements when the followin
304
316
305
317
Single selection keyboard interaction follows the [ARIA implementation patterns of a radio](https://www.w3.org/WAI/ARIA/apg/patterns/radio/).
306
318
307
-
These keyboard interactions apply to `ion-action-sheet`, `ion-alert`, and `ion-popover` elements when the overlay is presented and focused.
319
+
These keyboard interactions apply to `ion-action-sheet`, `ion-alert`, `ion-popover`, and `ion-modal` elements when the overlay is presented and focused.
@@ -321,7 +333,7 @@ These keyboard interactions apply to `ion-action-sheet`, `ion-alert`, and `ion-p
321
333
322
334
Multiple selection keyboard interaction follows the [ARIA implementation patterns of a checkbox](https://www.w3.org/WAI/ARIA/apg/patterns/checkbox/).
323
335
324
-
These keyboard interactions apply to `ion-alert`and `ion-popover` elements when the overlay is presented and multiple selection is enabled.
336
+
These keyboard interactions apply to `ion-alert`, `ion-popover`, and `ion-modal` elements when the overlay is presented and multiple selection is enabled.
0 commit comments