{"id":19057427,"url":"https://github.com/femessage/el-semver-input","last_synced_at":"2026-05-12T06:30:17.965Z","repository":{"id":56377966,"uuid":"164073012","full_name":"FEMessage/el-semver-input","owner":"FEMessage","description":"🖊Semantic version input component","archived":false,"fork":false,"pushed_at":"2020-11-11T10:31:12.000Z","size":6309,"stargazers_count":8,"open_issues_count":20,"forks_count":8,"subscribers_count":2,"default_branch":"dev","last_synced_at":"2025-02-02T18:47:28.846Z","etag":null,"topics":["autocomplete","input","semver"],"latest_commit_sha":null,"homepage":"https://femessage.github.io/el-semver-input/","language":"Vue","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/FEMessage.png","metadata":{"files":{"readme":"README-zh.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":"2019-01-04T07:22:21.000Z","updated_at":"2023-12-01T07:34:13.000Z","dependencies_parsed_at":"2022-08-15T17:40:23.742Z","dependency_job_id":null,"html_url":"https://github.com/FEMessage/el-semver-input","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FEMessage%2Fel-semver-input","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FEMessage%2Fel-semver-input/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FEMessage%2Fel-semver-input/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FEMessage%2Fel-semver-input/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FEMessage","download_url":"https://codeload.github.com/FEMessage/el-semver-input/tar.gz/refs/heads/dev","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240113944,"owners_count":19749829,"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":["autocomplete","input","semver"],"created_at":"2024-11-08T23:57:20.134Z","updated_at":"2026-05-12T06:30:17.926Z","avatar_url":"https://github.com/FEMessage.png","language":"Vue","funding_links":[],"categories":[],"sub_categories":[],"readme":"# el-semver-input\n\n[![Build Status](https://travis-ci.com/FEMessage/el-semver-input.svg?branch=master)](https://travis-ci.com/FEMessage/el-semver-input)\n[![NPM Download](https://img.shields.io/npm/dm/@femessage/el-semver-input.svg)](https://www.npmjs.com/package/@femessage/el-semver-input)\n[![NPM Version](https://img.shields.io/npm/v/@femessage/el-semver-input.svg)](https://www.npmjs.com/package/@femessage/el-semver-input)\n[![NPM License](https://img.shields.io/npm/l/@femessage/el-semver-input.svg)](https://github.com/FEMessage/el-semver-input/blob/master/LICENSE)\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](https://github.com/FEMessage/el-semver-input/pulls)\n[![Automated Release Notes by gren](https://img.shields.io/badge/%F0%9F%A4%96-release%20notes-00B2EE.svg)](https://github-tools.github.io/github-release-notes/)\n\n语义化版本输入框：失去焦点可以补全。\n\n[](https://cdn.nlark.com/yuque/0/2019/gif/224563/1561953196140-1fec3064-560c-4001-9f88-366be556cab8.gif#align=left\u0026display=inline\u0026height=87\u0026originHeight=87\u0026originWidth=1131\u0026size=0\u0026status=done\u0026width=1131)\n\n## Introduction\n\n**What is `el-semver-input`**\n\n`el-semver-input`组件基于`el-input`,在保留了`el-input`原本的属性以及方法的基础上进行了拓展，对输入值的格式进行校验，并可以自动修正错误输入。\n\n**Why**\n\n使用`el-semver-input`，您将享受到以下便捷之处：\n\n* 上手简单，默认开启全部功能\n* 可自定义格式检验规则\n* 可自定义自动填充规则\n\n## Table of Contents \u003c!-- omit in toc --\u003e\n\n* [Introduction](#introduction)\n* [Feature](#feature)\n* [Documentation](#documentation)\n* [Pre Install](#pre-install)\n* [Quick Start](#quick-start)\n* [Example](#example)\n* [Contributors](#contributors)\n\n## Feature\n\n* 可选是否携带 v 前缀\n* 阻止不合法字符串输入\n* 可根据默认或自定义的规则进行自动填充\n* 失去焦点时格式错误重置为默认值\n* 自定义检验规则,自动填充规则\n* 根据匹配到的规则尝试自动修复\n\n**[⬆ Back to Top](#table-of-contents)**\n\n## Documentation\n\n* [doc and online demo](https://femessage.github.io/el-semver-input/)\n\n**[⬆ Back to Top](#table-of-contents)**\n\n## Pre Install\n\n```sh\n# 确保提前安装了element-ui\nyarn add element-ui\n\n# 且全局注册了el-input\n```\n\n## Quick Start\n\n```sh\n# Step1 安装\nyarn add @femessage/el-semver-input\n```\n\n```vue\n// Step2 在需要的.vue 文件中\n\u003ctemplate\u003e\n  \u003cel-semver-input v-model=\"version\" /\u003e\n\u003c/template\u003e\n\u003cscript\u003e\nimport ElSemverInput from 'el-semver-input'\nexport default {\n  components: {\n    ElSemverInput\n  },\n  data() {\n    return {\n      version: ''\n    }\n  }\n}\n\u003c/script\u003e\n```\n\n**[⬆ Back to Top](#table-of-contents)**\n\n## Example\n\n* 自动修复\n  ![](https://cdn.nlark.com/yuque/0/2019/gif/224563/1561953196250-1506ad60-6111-48b6-a4ca-0cdb17fc8b06.gif#align=left\u0026display=inline\u0026height=603\u0026originHeight=603\u0026originWidth=1261\u0026size=0\u0026status=done\u0026width=1261)\n\n* 自定义自动填充规则\n  ![](https://cdn.nlark.com/yuque/0/2019/gif/224563/1561953196274-3c1fd76a-f0f8-4706-a3af-c8ae0b606d79.gif#align=left\u0026display=inline\u0026height=603\u0026originHeight=603\u0026originWidth=1261\u0026size=0\u0026status=done\u0026width=1261)\n\n* 阻止不合法的输入\n  ![](https://cdn.nlark.com/yuque/0/2019/gif/224563/1561953196218-47085f92-e8e3-4ddb-8596-c7d3b0b2f6f9.gif#align=left\u0026display=inline\u0026height=603\u0026originHeight=603\u0026originWidth=1261\u0026size=0\u0026status=done\u0026width=1261)\n\n**[⬆ Back to Top](#table-of-contents)**\n\n## Contributors\n\nThanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --\u003e\n\n\u003c!-- prettier-ignore --\u003e\n\u003c!-- ALL-CONTRIBUTORS-LIST:END --\u003e\n\nThis project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!\n\n**[⬆ Back to Top](#table-of-contents)**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffemessage%2Fel-semver-input","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffemessage%2Fel-semver-input","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffemessage%2Fel-semver-input/lists"}