Skip to content

Commit fd4b62f

Browse files
committed
Docs : Update README.md
1 parent 05f412d commit fd4b62f

File tree

1 file changed

+39
-18
lines changed

1 file changed

+39
-18
lines changed

README.md

Lines changed: 39 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ It also provides full localization support and event handling for custom behavio
1919
## Features
2020

2121
#### 1. Customizable Styling
22-
- **AM/PM Configuration**: Customize the text style, color, and layout for AM and PM labels.
23-
- **Time Configuration**: Adjust the styling for hours, minutes, and seconds (for the 24-hour format).
24-
- **Picker Selector Configuration**: Customize the appearance of the time picker using background colors, border shapes, and more.
25-
- **Label Styling**: Fully customize the labels for hours, minutes, and AM/PM text, including text size, font, color.
26-
- **Visible Items Count**: Control the number of visible items in the time picker, allowing for a more compact or expansive display depending on the user’s preferences.
22+
- **AM/PM Configuration**: Customize AM/PM label text style, color, and layout.
23+
- **Time Label Styling**: Adjust hour and minute text styles, colors, and item spacing via `PickerStyle`.
24+
- **Picker Selector Configuration**: Modify the appearance of the picker selector, including background color, shape, and border.
25+
- **Curve Effect**: Apply a curve effect to the picker list for a 3D cylindrical visual. Options include alpha fading and vertical scaling.
26+
- **Visible Items Count**: Control the number of visible items for compact or expansive display.
2727

2828
#### 2. Localization Support
2929
- Supports both English (EN) and Korean (KO) locales.
@@ -89,29 +89,26 @@ TimePicker(
8989

9090
### Customized Options
9191

92-
#### 1. Time Label Configuration
92+
#### 1. Picker Style Configuration
9393

94-
```kotlin
95-
TimePicker(
96-
// ...
97-
itemLabel = TimePickerDefaults.itemLabel().copy(
98-
style = MaterialTheme.typography.bodyLarge
99-
),
100-
// ...
101-
)
94+
PickerStyle allows you to customize text styles, colors, and item spacing.
10295

96+
```kotlin
10397
TimePicker(
10498
// ...
105-
itemLabel = ItemLabel(
106-
style = MaterialTheme.typography.titleMedium,
107-
color = Color.White
99+
style = TimePickerDefaults.pickerStyle(
100+
textStyle = MaterialTheme.typography.bodyLarge,
101+
textColor = Color.White,
102+
itemSpacing = 12.dp
108103
),
109104
// ...
110105
)
111106
```
112107

113108
#### 2. AM/PM Locale Configuraiton
114109

110+
Configure the time picker to display AM/PM labels in either English or Korean.
111+
115112
```kotlin
116113
TimePicker(
117114
// ...
@@ -126,7 +123,9 @@ TimePicker(
126123
)
127124
```
128125

129-
#### 3. Selector Configuration
126+
#### 3. Picker Selector Configuration
127+
128+
Modify selector color, shape, and border.
130129

131130
```kotlin
132131
TimePicker(
@@ -142,6 +141,8 @@ TimePicker(
142141

143142
#### 4. Visible Items Count Configuration
144143

144+
Control how many items are shown in the picker at once.
145+
145146
```kotlin
146147
TimePicker(
147148
// ...
@@ -150,6 +151,26 @@ TimePicker(
150151
)
151152
```
152153

154+
#### 5. Curve Effect Configuration
155+
156+
Apply a curve effect to the picker for a 3D cylindrical visual.
157+
Options include:
158+
- Enable/disable alpha fading (alphaEnabled, minAlpha)
159+
- Enable/disable vertical scaling (scaleYEnabled, minScaleY)
160+
161+
```kotlin
162+
TimePicker(
163+
// ...
164+
curveEffect = TimePickerDefaults.curveEffect(
165+
alphaEnabled = true,
166+
minAlpha = 0.3f,
167+
scaleYEnabled = true,
168+
minScaleY = 0.85f
169+
)
170+
// ...
171+
)
172+
```
173+
153174
## License
154175
This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.
155176

0 commit comments

Comments
 (0)