{"id":17351234,"url":"https://github.com/youngwind/jquery.cursor","last_synced_at":"2025-12-12T04:21:03.344Z","repository":{"id":58230234,"uuid":"53203499","full_name":"youngwind/jquery.cursor","owner":"youngwind","description":"灵活运用光标的jquery插件","archived":false,"fork":false,"pushed_at":"2016-03-05T18:00:49.000Z","size":132,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-11T21:03:41.919Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/youngwind.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}},"created_at":"2016-03-05T13:49:46.000Z","updated_at":"2016-09-30T10:35:08.000Z","dependencies_parsed_at":"2022-08-31T09:21:28.155Z","dependency_job_id":null,"html_url":"https://github.com/youngwind/jquery.cursor","commit_stats":null,"previous_names":["smartfe/jquery.cursor"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/youngwind%2Fjquery.cursor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/youngwind%2Fjquery.cursor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/youngwind%2Fjquery.cursor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/youngwind%2Fjquery.cursor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/youngwind","download_url":"https://codeload.github.com/youngwind/jquery.cursor/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245842683,"owners_count":20681382,"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":[],"created_at":"2024-10-15T17:09:22.200Z","updated_at":"2025-12-12T04:21:03.294Z","avatar_url":"https://github.com/youngwind.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 项目说明\n此插件基于jquery，主要用途\n\n1. 操作光标在文本中的位置（textarea和input）\n2. 在制定位置插入文字，选中制定的文字片段\n\n![用法实力](./doc/demo.gif)\n\n# 使用方法\n## 1. 安装\n```\nbower install jquery --save\nbower install jquery-cursor --save\n```\n\n## 2. 引入\n```\n\u003cscript src=\"jquery.js\"\u003e\u003cscript\u003e\n\u003cscript src=\"jquery-cursor.js\"\u003e\u003cscript\u003e\n```\n## 3. 使用\n### 3.1 基本用法\n```\n$('#textAreaId').cursor({\n  \"text\":\"这是插入的一些文字，哪些位置被选中由下面两个参数决定\",\n  \"beginPos\":2,  // 开头从0开始计数\n  \"endPos\":5    // 如果省略，则从beginPos一直选中到text的结尾\n);\n```\n//todo\n1. 添加IE兼容性\n2. 添加tab切换在多个位置跳转选中","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyoungwind%2Fjquery.cursor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyoungwind%2Fjquery.cursor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyoungwind%2Fjquery.cursor/lists"}