{"id":15506110,"url":"https://github.com/chenjiahan/relect","last_synced_at":"2025-04-23T01:55:48.061Z","repository":{"id":3008715,"uuid":"47412509","full_name":"chenjiahan/relect","owner":"chenjiahan","description":"A Tiny React Single Select Component.","archived":false,"fork":false,"pushed_at":"2024-03-28T17:56:54.000Z","size":1152,"stargazers_count":36,"open_issues_count":7,"forks_count":4,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-23T01:55:40.233Z","etag":null,"topics":["react","select"],"latest_commit_sha":null,"homepage":"http://chenjiahan.github.io/relect/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/chenjiahan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2015-12-04T15:35:16.000Z","updated_at":"2024-11-07T13:15:48.000Z","dependencies_parsed_at":"2023-07-05T20:46:25.595Z","dependency_job_id":"996d4018-0c4e-4a7a-a424-a909fe01940a","html_url":"https://github.com/chenjiahan/relect","commit_stats":{"total_commits":71,"total_committers":5,"mean_commits":14.2,"dds":"0.45070422535211263","last_synced_commit":"e1162fbb1687dfae0b73ec422f88bd2e252e25eb"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chenjiahan%2Frelect","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chenjiahan%2Frelect/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chenjiahan%2Frelect/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chenjiahan%2Frelect/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chenjiahan","download_url":"https://codeload.github.com/chenjiahan/relect/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250354301,"owners_count":21416751,"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":["react","select"],"created_at":"2024-10-02T09:25:37.049Z","updated_at":"2025-04-23T01:55:48.046Z","avatar_url":"https://github.com/chenjiahan.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Relect\nA Tiny React Single Select Component.    \n[Example](http://chenjiahan.github.io/relect/)\n\n## Install\n\n    npm i relect -S\n\n## Usage\n``` javascript\nimport React  from 'react';\nimport Relect from 'relect';\n\n// include styles\nimport 'relect/lib/relect.css';\n\nconst options = [\n    { text: 'one', value: 1 },\n    { text: 'two', value: 2 }\n];\n\nclass App extends React.Component {\n\n    constructor(props) {\n        super(props);\n        this.state = { chosen : null }\n    }\n    \n    onChange(index) {\n        this.setState({ chosen : index });\n    }\n\n    render() {\n        return (\n            \u003cRelect options={options}\n                    chosen={this.state.chosen}\n                    onChange={this.onChange.bind(this)}\n            /\u003e\n        )\n    }\n}\n```\n## Props\n\nProperty|Type|Default|Description\n---|---|---|---\nwidth|number|240|width of select\nheight|number|36|height of select\noptions|array|/|options\nchosen|number|/|index of chosen option\ntabIndex|number|-1|tab order\ndisabled|bool|false|whether to disable select\nautoBlur|bool|false|auto blur after selection \nplaceholder|string|/|placeholder text\noptionHeight|number|30|height of option\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchenjiahan%2Frelect","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchenjiahan%2Frelect","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchenjiahan%2Frelect/lists"}