Skip to content

Commit 743f517

Browse files
authored
refactor(item): remove deprecated apis (#29102)
BREAKING CHANGE: - The `helper` slot has been removed. Developers should use the `helperText` property on `ion-input` and `ion-textarea`. - The `error` slot has been removed. Developers should use the `errorText` property on `ion-input` and `ion-textarea`. - Counter functionality has been removed including the `counter` and `counterFormatter` properties. Developers should use the properties of the same name on `ion-input` and `ion-textarea`. - The `fill` property has been removed. Developers should use the property of the same name on `ion-input`, `ion-select`, and `ion-textarea`. - The `shape` property has been removed. Developers should use the property of the same name on `ion-input`, `ion-select`, and `ion-textarea`.
1 parent 6852719 commit 743f517

File tree

60 files changed

+21
-917
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+21
-917
lines changed

BREAKING.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ This is a comprehensive list of the breaking changes introduced in the major ver
2121
- [Checkbox](#version-8x-checkbox)
2222
- [Content](#version-8x-content)
2323
- [Datetime](#version-8x-datetime)
24+
- [Item](#version-8x-item)
2425
- [Input](#version-8x-input)
2526
- [Item](#version-8x-item)
2627
- [Modal](#version-8x-modal)
@@ -162,6 +163,13 @@ For more information on the dynamic font, refer to the [Dynamic Font Scaling doc
162163
+ background: red;
163164
}
164165
```
166+
<h4 id="version-8x-item">Item</h4>
167+
168+
- The `helper` slot has been removed. Developers should use the `helperText` property on `ion-input` and `ion-textarea`.
169+
- The `error` slot has been removed. Developers should use the `errorText` property on `ion-input` and `ion-textarea`.
170+
- Counter functionality has been removed including the `counter` and `counterFormatter` properties. Developers should use the properties of the same name on `ion-input` and `ion-textarea`.
171+
- The `fill` property has been removed. Developers should use the property of the same name on `ion-input`, `ion-select`, and `ion-textarea`.
172+
- The `shape` property has been removed. Developers should use the property of the same name on `ion-input`, `ion-select`, and `ion-textarea`.
165173

166174
<h4 id="version-8x-input">Input</h4>
167175

core/api.txt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -608,20 +608,16 @@ ion-input,css-prop,--placeholder-opacity
608608
ion-item,shadow
609609
ion-item,prop,button,boolean,false,false,false
610610
ion-item,prop,color,"danger" | "dark" | "light" | "medium" | "primary" | "secondary" | "success" | "tertiary" | "warning" | string & Record<never, never> | undefined,undefined,false,true
611-
ion-item,prop,counter,boolean,false,false,false
612-
ion-item,prop,counterFormatter,((inputLength: number, maxLength: number) => string) | undefined,undefined,false,false
613611
ion-item,prop,detail,boolean | undefined,undefined,false,false
614612
ion-item,prop,detailIcon,string,chevronForward,false,false
615613
ion-item,prop,disabled,boolean,false,false,false
616614
ion-item,prop,download,string | undefined,undefined,false,false
617-
ion-item,prop,fill,"outline" | "solid" | undefined,undefined,false,false
618615
ion-item,prop,href,string | undefined,undefined,false,false
619616
ion-item,prop,lines,"full" | "inset" | "none" | undefined,undefined,false,false
620617
ion-item,prop,mode,"ios" | "md",undefined,false,false
621618
ion-item,prop,rel,string | undefined,undefined,false,false
622619
ion-item,prop,routerAnimation,((baseEl: any, opts?: any) => Animation) | undefined,undefined,false,false
623620
ion-item,prop,routerDirection,"back" | "forward" | "root",'forward',false,false
624-
ion-item,prop,shape,"round" | undefined,undefined,false,false
625621
ion-item,prop,target,string | undefined,undefined,false,false
626622
ion-item,prop,type,"button" | "reset" | "submit",'button',false,false
627623
ion-item,css-prop,--background

core/src/components.d.ts

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ import { ScrollBaseDetail, ScrollDetail } from "./components/content/content-int
1818
import { DatetimeChangeEventDetail, DatetimeHighlight, DatetimeHighlightCallback, DatetimeHourCycle, DatetimePresentation, TitleSelectedDatesFormatter } from "./components/datetime/datetime-interface";
1919
import { SpinnerTypes } from "./components/spinner/spinner-configs";
2020
import { InputChangeEventDetail, InputInputEventDetail } from "./components/input/input-interface";
21-
import { CounterFormatter } from "./components/item/item-interface";
2221
import { MenuChangeEventDetail, Side } from "./components/menu/menu-interface";
2322
import { ModalBreakpointChangeEventDetail, ModalHandleBehavior } from "./components/modal/modal-interface";
2423
import { NavComponent, NavComponentWithProps, NavOptions, RouterOutletOptions, SwipeGestureHandler, TransitionDoneFn, TransitionInstruction } from "./components/nav/nav-interface";
@@ -54,7 +53,6 @@ export { ScrollBaseDetail, ScrollDetail } from "./components/content/content-int
5453
export { DatetimeChangeEventDetail, DatetimeHighlight, DatetimeHighlightCallback, DatetimeHourCycle, DatetimePresentation, TitleSelectedDatesFormatter } from "./components/datetime/datetime-interface";
5554
export { SpinnerTypes } from "./components/spinner/spinner-configs";
5655
export { InputChangeEventDetail, InputInputEventDetail } from "./components/input/input-interface";
57-
export { CounterFormatter } from "./components/item/item-interface";
5856
export { MenuChangeEventDetail, Side } from "./components/menu/menu-interface";
5957
export { ModalBreakpointChangeEventDetail, ModalHandleBehavior } from "./components/modal/modal-interface";
6058
export { NavComponent, NavComponentWithProps, NavOptions, RouterOutletOptions, SwipeGestureHandler, TransitionDoneFn, TransitionInstruction } from "./components/nav/nav-interface";
@@ -1294,16 +1292,6 @@ export namespace Components {
12941292
* The color to use from your application's color palette. Default options are: `"primary"`, `"secondary"`, `"tertiary"`, `"success"`, `"warning"`, `"danger"`, `"light"`, `"medium"`, and `"dark"`. For more information on colors, see [theming](/docs/theming/basics).
12951293
*/
12961294
"color"?: Color;
1297-
/**
1298-
* If `true`, a character counter will display the ratio of characters used and the total character limit. Only applies when the `maxlength` property is set on the inner `ion-input` or `ion-textarea`.
1299-
* @deprecated Use the `counter` property on `ion-input` or `ion-textarea` instead.
1300-
*/
1301-
"counter": boolean;
1302-
/**
1303-
* A callback used to format the counter text. By default the counter text is set to "itemLength / maxLength".
1304-
* @deprecated Use the `counterFormatter` property on `ion-input` or `ion-textarea` instead.
1305-
*/
1306-
"counterFormatter"?: CounterFormatter;
13071295
/**
13081296
* If `true`, a detail arrow will appear on the item. Defaults to `false` unless the `mode` is `ios` and an `href` or `button` property is present.
13091297
*/
@@ -1320,11 +1308,6 @@ export namespace Components {
13201308
* This attribute instructs browsers to download a URL instead of navigating to it, so the user will be prompted to save it as a local file. If the attribute has a value, it is used as the pre-filled file name in the Save prompt (the user can still change the file name if they want).
13211309
*/
13221310
"download": string | undefined;
1323-
/**
1324-
* The fill for the item. If `"solid"` the item will have a background. If `"outline"` the item will be transparent with a border. Only available in `md` mode.
1325-
* @deprecated Use the `fill` property on `ion-input` or `ion-textarea` instead.
1326-
*/
1327-
"fill"?: 'outline' | 'solid';
13281311
/**
13291312
* Contains a URL or a URL fragment that the hyperlink points to. If this property is set, an anchor tag will be rendered.
13301313
*/
@@ -1349,10 +1332,6 @@ export namespace Components {
13491332
* When using a router, it specifies the transition direction when navigating to another page using `href`.
13501333
*/
13511334
"routerDirection": RouterDirection;
1352-
/**
1353-
* The shape of the item. If "round" it will have increased border radius.
1354-
*/
1355-
"shape"?: 'round';
13561335
/**
13571336
* Specifies where to display the linked URL. Only applies when an `href` is provided. Special keywords: `"_blank"`, `"_self"`, `"_parent"`, `"_top"`.
13581337
*/
@@ -6009,16 +5988,6 @@ declare namespace LocalJSX {
60095988
* The color to use from your application's color palette. Default options are: `"primary"`, `"secondary"`, `"tertiary"`, `"success"`, `"warning"`, `"danger"`, `"light"`, `"medium"`, and `"dark"`. For more information on colors, see [theming](/docs/theming/basics).
60105989
*/
60115990
"color"?: Color;
6012-
/**
6013-
* If `true`, a character counter will display the ratio of characters used and the total character limit. Only applies when the `maxlength` property is set on the inner `ion-input` or `ion-textarea`.
6014-
* @deprecated Use the `counter` property on `ion-input` or `ion-textarea` instead.
6015-
*/
6016-
"counter"?: boolean;
6017-
/**
6018-
* A callback used to format the counter text. By default the counter text is set to "itemLength / maxLength".
6019-
* @deprecated Use the `counterFormatter` property on `ion-input` or `ion-textarea` instead.
6020-
*/
6021-
"counterFormatter"?: CounterFormatter;
60225991
/**
60235992
* If `true`, a detail arrow will appear on the item. Defaults to `false` unless the `mode` is `ios` and an `href` or `button` property is present.
60245993
*/
@@ -6035,11 +6004,6 @@ declare namespace LocalJSX {
60356004
* This attribute instructs browsers to download a URL instead of navigating to it, so the user will be prompted to save it as a local file. If the attribute has a value, it is used as the pre-filled file name in the Save prompt (the user can still change the file name if they want).
60366005
*/
60376006
"download"?: string | undefined;
6038-
/**
6039-
* The fill for the item. If `"solid"` the item will have a background. If `"outline"` the item will be transparent with a border. Only available in `md` mode.
6040-
* @deprecated Use the `fill` property on `ion-input` or `ion-textarea` instead.
6041-
*/
6042-
"fill"?: 'outline' | 'solid';
60436007
/**
60446008
* Contains a URL or a URL fragment that the hyperlink points to. If this property is set, an anchor tag will be rendered.
60456009
*/
@@ -6064,10 +6028,6 @@ declare namespace LocalJSX {
60646028
* When using a router, it specifies the transition direction when navigating to another page using `href`.
60656029
*/
60666030
"routerDirection"?: RouterDirection;
6067-
/**
6068-
* The shape of the item. If "round" it will have increased border radius.
6069-
*/
6070-
"shape"?: 'round';
60716031
/**
60726032
* Specifies where to display the linked URL. Only applies when an `href` is provided. Special keywords: `"_blank"`, `"_self"`, `"_parent"`, `"_top"`.
60736033
*/

core/src/components/item/item.ios.scss

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333
--highlight-color-focused: #{$item-ios-input-highlight-color};
3434
--highlight-color-valid: #{$item-ios-input-highlight-color-valid};
3535
--highlight-color-invalid: #{$item-ios-input-highlight-color-invalid};
36-
--bottom-padding-start: 0px;
3736

3837
font-size: $item-ios-font-size;
3938
}
@@ -149,7 +148,6 @@
149148
@include margin($item-ios-label-slot-end-margin-top, $item-ios-label-slot-end-margin-end, $item-ios-label-slot-end-margin-bottom, $item-ios-label-slot-end-margin-start);
150149
}
151150

152-
153151
// iOS Item Button
154152
// --------------------------------------------------
155153

@@ -204,18 +202,10 @@
204202
@include margin(10px, 8px, 10px, 0);
205203
}
206204

207-
208205
// iOS Stacked & Floating Inputs
209206
// --------------------------------------------------
210207

211208
:host(.item-label-floating),
212209
:host(.item-label-stacked) {
213210
--min-height: 68px;
214211
}
215-
216-
// iOS Fixed Labels
217-
// --------------------------------------------------
218-
219-
:host(.item-label-fixed) ::slotted(ion-datetime) {
220-
--padding-start: 0;
221-
}

0 commit comments

Comments
 (0)