{"id":15555007,"url":"https://github.com/ecrax/category_picker","last_synced_at":"2026-04-28T13:35:42.661Z","repository":{"id":61972831,"uuid":"328146223","full_name":"ecrax/category_picker","owner":"ecrax","description":"An input widget to handle selection of category like choices.","archived":false,"fork":false,"pushed_at":"2021-01-10T09:20:05.000Z","size":270,"stargazers_count":0,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-06T10:37:12.916Z","etag":null,"topics":["category-picker","dart","dartlang","flutter","flutter-package","input","widget"],"latest_commit_sha":null,"homepage":"https://pub.dev/packages/category_picker","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ecrax.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-01-09T12:07:02.000Z","updated_at":"2021-01-09T13:35:39.000Z","dependencies_parsed_at":"2022-10-24T13:15:32.668Z","dependency_job_id":null,"html_url":"https://github.com/ecrax/category_picker","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/ecrax/category_picker","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ecrax%2Fcategory_picker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ecrax%2Fcategory_picker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ecrax%2Fcategory_picker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ecrax%2Fcategory_picker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ecrax","download_url":"https://codeload.github.com/ecrax/category_picker/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ecrax%2Fcategory_picker/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262056349,"owners_count":23251665,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["category-picker","dart","dartlang","flutter","flutter-package","input","widget"],"created_at":"2024-10-02T15:05:37.599Z","updated_at":"2026-04-28T13:35:42.634Z","avatar_url":"https://github.com/ecrax.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"# category_picker\n\nAn input widget to handle selection of category like choices.\n\n![](./example.gif)\n\n## Usage\n\nTo use this widget simply add category_picker as a dependency to your project in the pubspec.yaml file and import it if needed.\n\n### Example\n\n(Barebone)\n\n```dart\nimport 'package:category_picker/category_picker.dart';\nimport 'package:category_picker/category_picker_item.dart';\n```\n\n```dart\n@override\n  Widget build(BuildContext context) {\n    return Scaffold(\n      body: Center(\n        child: CategoryPicker(\n          items: [\n            CategoryPickerItem(\n              value: \"Test\",\n            ),\n            CategoryPickerItem(\n              value: \"Test2\",\n            ),\n            CategoryPickerItem(\n              value: \"Test3\",\n            ),\n          ],\n          onValueChanged: (value) {\n            print(value.label);\n          },\n        ),\n      ),\n    );\n  }\n```\n\nA more detailed example is available in the [example](https://github.com/ecrax/category_picker/tree/master/example) folder\n\n### CategoryPickerItem() parameters\n\n| PropName   | Description                                  | Default value                   |\n| ---------- | -------------------------------------------- | ------------------------------- |\n| isSelected | Determines if the item is currently selected | false (not in constructor)      |\n| value      | The value of the item                        | required                        |\n| label      | String to be displayed on the item itself    | String value of `value` if null |\n\n### CategoryPicker() parameters\n\n| PropName                          | Description                                                              | Default value                                     |\n| --------------------------------- | ------------------------------------------------------------------------ | ------------------------------------------------- |\n| items                             | List of children to be displayed                                         | required                                          |\n| defaultSelected                   | Default selected item in range of `0` - `items.length`                   | 0                                                 |\n| onValueChanged                    | Callback with entire item when user switches selection.                  | `() =\u003e {}`                                        |\n| backgroundColor                   | Background color of entire category picker                               | Colors.transparent                                |\n| selectedItemColor                 | Background color of selected item                                        | Theme.of(context).accentColor                     |\n| unselectedItemColor               | Background color of all items that are not selected                      | Colors.transparent                                |\n| selectedItemBorderColor           | Border color of the selected item                                        | Colors.transparent                                |\n| unselectedItemBorderColor         | Border color of all unselected items                                     | Colors.grey[800]                                  |\n| selectedItemTextDarkThemeColor    | Text color of the text for light theme inside an item while selected     | Colors.white                                      |\n| selectedItemTextLightThemeColor   | Text color of the text for light theme inside an item while not selected | Colors.black                                      |\n| unselectedItemTextDarkThemeColor  | Text color of the text for dark theme inside an item while selected      | Colors.white                                      |\n| unselectedItemTextLightThemeColor | Text color of the text for dark theme inside an item while not selected  | Colors.white                                      |\n| itemBorderRadius                  | Border radius for all items                                              | BorderRadius.circular(30)                         |\n| itemHeight                        | Height of all items                                                      | 32.0                                              |\n| itemLabelFontSize                 | Font size of the text inside of all items                                | 16.0                                              |\n| categoryPickerMargin              | Margin of the entire category picker                                     | EdgeInsets.symmetric(vertical: 11)                |\n| categoryPickerPadding             | Padding of the entire category picker                                    | EdgeInsets.symmetric(horizontal: 16, vertical: 8) |\n| itemMargin                        | Margin applied to each individual item                                   | EdgeInsets.symmetric(horizontal: 4)               |\n| itemPadding                       | Padding applied to each individual item                                  | EdgeInsets.symmetric(horizontal: 12)              |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fecrax%2Fcategory_picker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fecrax%2Fcategory_picker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fecrax%2Fcategory_picker/lists"}