{"id":13611214,"url":"https://github.com/rafsanjani/datepickertimeline","last_synced_at":"2026-01-18T14:18:13.576Z","repository":{"id":39614071,"uuid":"430346246","full_name":"rafsanjani/datepickertimeline","owner":"rafsanjani","description":"Linear date picker for Jetpack compose ","archived":false,"fork":false,"pushed_at":"2026-01-16T15:04:58.000Z","size":604,"stargazers_count":57,"open_issues_count":7,"forks_count":4,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-17T04:49:30.683Z","etag":null,"topics":["android","calendar-view","compose-multiplatform","datepicker","jetpack-compose"],"latest_commit_sha":null,"homepage":"","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rafsanjani.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2021-11-21T11:25:35.000Z","updated_at":"2025-11-17T01:36:56.000Z","dependencies_parsed_at":"2025-12-14T04:01:55.778Z","dependency_job_id":null,"html_url":"https://github.com/rafsanjani/datepickertimeline","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/rafsanjani/datepickertimeline","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafsanjani%2Fdatepickertimeline","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafsanjani%2Fdatepickertimeline/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafsanjani%2Fdatepickertimeline/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafsanjani%2Fdatepickertimeline/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rafsanjani","download_url":"https://codeload.github.com/rafsanjani/datepickertimeline/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafsanjani%2Fdatepickertimeline/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28537498,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-18T13:04:05.990Z","status":"ssl_error","status_checked_at":"2026-01-18T13:01:44.092Z","response_time":98,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","calendar-view","compose-multiplatform","datepicker","jetpack-compose"],"created_at":"2024-08-01T19:01:52.917Z","updated_at":"2026-01-18T14:18:13.550Z","avatar_url":"https://github.com/rafsanjani.png","language":"Kotlin","funding_links":[],"categories":["Kotlin"],"sub_categories":[],"readme":"\n\n\n# DatePickerTimeline ![Android CI](https://github.com/Rafsanjani/datepickertimeline/actions/workflows/android.yml/badge.svg?branch=main) ![Maven Central Version](https://img.shields.io/maven-central/v/io.github.rafsanjani/datepickertimeline)\n\n\n\nA linear date picker for compose multiplatform.\u003cbr\u003e Inspired by https://pub.dev/packages/date_picker_timeline\n\n\n\n\u003cimg height=\"500\" width=\"250\" src=\"https://user-images.githubusercontent.com/9197459/146689659-647e230a-57ef-45e6-be76-c1cb2bb8b0c1.gif\"\u003e  \u003cimg height=\"500\" width=\"250\" src=\"https://user-images.githubusercontent.com/9197459/146690796-5a979f20-a7be-4956-a991-36750cdcf0ab.gif\"\u003e\n\n\n## Installation \nAdd the dependency to your `build.gradle` or `build.gradle.kts` file\n\n```groovy\nrepositories {\n    mavenCentral()\n}\n\ndependencies{\n    implementation (\"io.github.rafsanjani:datepickertimeline:\u003clatest_version\u003e\")\n}\n```\n## Usage \n### For a horizontal date picker with no customization\n```kotlin \nDatePickerTimeLine(\n\tmodifier = Modifier,\n\tonDateSelected = {selectedDate: LocalDate-\u003e\n\t\t//do something with selected date\n\t}\n) \n```\n### For a vertical date picker with no customization\n\n```kotlin \nimport com.foreverrafs.datepicker.Orientation\n\nDatePickerTimeLine(\n\tmodifier = Modifier,\n\torientation = Orientation.Vertical,\n\tonDateSelected = {selectedDate: LocalDate-\u003e\n\t\t//do something with selected date\n\t}\n) \n```\n\n### You can pass an optional state to the picker and specify the initial selected date\n\n```kotlin \nDatePickerTimeLine(\n\tmodifier = Modifier,\n\tstate = rememberDatePickerState(initialDate = LocalDate.now()),\n\tonDateSelected = { selectedDate: LocalDate -\u003e\n\t\t//do something with selected date\n\t}\n) \n```\n\n### To customize the full list of properties\n```kotlin \nimport com.foreverrafs.datepicker.Orientation\n\nval today = LocalDate.now()\nval datePickerState =  \n    rememberDatePickerState(initialDate = LocalDate.now())\n    \nDatePickerTimeline(\n  modifier = Modifier.wrapContentSize(),  \n  onDateSelected = { selectedDate: LocalDate -\u003e\n\t\t// do something with the selected date\n  },  \n  backgroundColor = Color.Yellow,  // the main background color\n  state = datePickerState,  \n  orientation = Orientation.Horizontal,  \n  selectedBackgroundColor = Color.Green, // The background of the currently selected date  \n  selectedTextColor = Color.White,  // Text color of currently selected date\n  dateTextColor = Color.Black, //Text color of all dates  \n  eventDates = listOf(  \n        today.plusDays(1),  \n        today.plusDays(3),  \n        today.plusDays(5),  \n        today.plusDays(8),  \n  ),   \n  todayLabel = {  \n      Text(  \n          modifier = Modifier.padding(10.dp),  \n          text = \"Today\",  \n          color = Color.White,  \n          style = MaterialTheme.typography.h6  \n      )\n    },  \n  pastDaysCount = 10,  // The number of previous dates to display, relative to the initial date. Defaults to 120\n  eventIndicatorColor = Color.Brown // Indicator color for marked event dates.\n)\n```\n\n### Scrolling to different dates\nYou can store the `DatePickerState` object into a variable and use it to perform smooth scrolling to any date. This is very similar to how `LazyListState` works. If you try to scroll to an invalid date as constrained by the `pastDaysCount` property, you are scrolled to the first valid date in the calendar instead.  \n\n```kotlin\nval today = LocalDate.now()\nval datePickerState =  \n    rememberDatePickerState(initialDate = LocalDate.now())\n    \nColumn{\n  DatePickerTimeline(\n    state = datePickerState\n  )\n  \n  Button(\n    onClick = {\n      // Scroll to Jan 01, 2022\n      datePickerState.smoothScrollTodate(LocalDate.of(2022, 1, 1)\n    }\n  ){\n    Text(\"Go to different date\")\n  }\n}\n```\n\n### Credits\n - https://github.com/godaddy/compose-color-picker for the beautiful color picker library used in the samples\n\n\nLicense\n--------\n\n   \tMIT License\n\n\tCopyright (c) 2021 Rafsanjani Aziz\n\n\tPermission is hereby granted, free of charge, to any person obtaining a copy\n\tof this software and associated documentation files (the \"Software\"), to deal\n\tin the Software without restriction, including without limitation the rights\n\tto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n\tcopies of the Software, and to permit persons to whom the Software is\n\tfurnished to do so, subject to the following conditions:\n\n\tThe above copyright notice and this permission notice shall be included in all\n\tcopies or substantial portions of the Software.\n\n\tTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n\tIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n\tFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n\tAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n\tLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n\tOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\n\tSOFTWARE.\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frafsanjani%2Fdatepickertimeline","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frafsanjani%2Fdatepickertimeline","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frafsanjani%2Fdatepickertimeline/lists"}