{"id":13804853,"url":"https://github.com/thecodrr/boxx","last_synced_at":"2025-04-29T17:30:34.288Z","repository":{"id":41132159,"uuid":"221233905","full_name":"thecodrr/boxx","owner":"thecodrr","description":"📦 Create highly customizable terminal boxes that also look great!","archived":false,"fork":false,"pushed_at":"2023-03-01T03:45:21.000Z","size":1178,"stargazers_count":99,"open_issues_count":0,"forks_count":5,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-05T18:21:48.884Z","etag":null,"topics":["bash","box","console","terminal","v"],"latest_commit_sha":null,"homepage":"","language":"V","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/thecodrr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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},"funding":{"github":null,"patreon":null,"open_collective":null,"ko_fi":"thecodrr","tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2019-11-12T14:12:59.000Z","updated_at":"2024-12-06T06:57:54.000Z","dependencies_parsed_at":"2024-05-03T03:01:21.192Z","dependency_job_id":"52a5206a-3c95-49e5-8c75-b2f0ae309e05","html_url":"https://github.com/thecodrr/boxx","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodrr%2Fboxx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodrr%2Fboxx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodrr%2Fboxx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodrr%2Fboxx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thecodrr","download_url":"https://codeload.github.com/thecodrr/boxx/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251549106,"owners_count":21607351,"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":["bash","box","console","terminal","v"],"created_at":"2024-08-04T01:00:54.627Z","updated_at":"2025-04-29T17:30:32.928Z","avatar_url":"https://github.com/thecodrr.png","language":"V","funding_links":["https://ko-fi.com/thecodrr"],"categories":["V","Libraries"],"sub_categories":["Command line interface (CLI) / Terminal / Shell"],"readme":"\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/example.png\"/\u003e\n\u003c/p\u003e\n\n\u003cdiv align=\"center\"\u003e\n\u003ch1\u003e📦 Boxx\u003c/h1\u003e\n\u003c/div\u003e\n\n\u003cp align=\"center\"\u003e\nCreate highly customizable terminal boxes that also look great!\n\u003c/p\u003e\n\n## Installation:\n\nInstall using `vpkg`\n\n```bash\nvpkg get https://github.com/thecodrr/boxx\n```\n\nInstall using `V`'s builtin `vpm`:\n\n```bash\nv install thecodrr.boxx\n```\n\nInstall using `git`:\n\n```bash\ncd path/to/your/project\ngit clone https://github.com/thecodrr/boxx\n```\n\nAll the awesome **color support** is made possible by [thecodrr.crayon](https://github.com/thecodrr/crayon) so install it:\n\n```\nv install thecodrr.crayon\n```\n\nThen in the wherever you want to use it:\n\n```v\nimport boxx // or with vpm use thecodrr.boxx\n```\n\nAnd that's it!\n\n## Usage\n\n### boxx.new(`Config`)\n\nInitializes a new `Box` with the specified `Config`\n\n```v\n    box := boxx.new(boxx.Config{px: 2, py: 1, typ: \"single\", color: \"green\"})\n    box.print(\"Boxx is a great start for CLI tools.\", \"Welcome to Boxx!\")\n```\n\n### `Config`\n\n`px`: Horizontal Padding\n\n`py`: Vertical Padding\n\n`content_align`: Content Alignment inside the box\n\n`color` :`rgb` or named (see [Crayon](https://github.com/thecodrr/crayon) for possible values \u0026 usage)\n\n`typ`: The type of box (see Box Types below)\n\n`title_position`: choose from one of `inside`, `top` or `bottom`\n\n#### Box Types:\n\n**1. `single`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/square.png\"/\u003e\n\u003c/p\u003e\n\n**2. `single_double`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/single_double.png\"/\u003e\n\u003c/p\u003e\n\n**3. `double_single`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/double_single.png\"/\u003e\n\u003c/p\u003e\n\n**4. `bold`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/bold.png\"/\u003e\n\u003c/p\u003e\n\n**5. `round`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/round.png\"/\u003e\n\u003c/p\u003e\n\n**6. `classic`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/classic.png\"/\u003e\n\u003c/p\u003e\n\n**7. `hidden`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/hidden.png\"/\u003e\n\u003c/p\u003e\n\n**8. `double`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/double.png\"/\u003e\n\u003c/p\u003e\n\n#### Title Positions:\n\n**1. `inside`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/square.png\"/\u003e\n\u003c/p\u003e\n\n**2. `top`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/top.png\"/\u003e\n\u003c/p\u003e\n\n**3. `bottom`**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/thecodrr/boxx/master/Screenshots/bottom.png\"/\u003e\n\u003c/p\u003e\n\n### Boxx `struct`\n\nYou can create your own boxes as well if you want using the following values:\n\n```v\nstruct Boxx {\n    top_right string //the top right corner symbol\n    top_left string //the top left corner symbol\n    vertical string //the symbol used for the vertical bars\n    horizontal string  //the symbol used for the horizontal bars\n    bottom_right string //the bottom right corner symbol\n    bottom_left string //the bottom left corner symbol\n}\n```\n\n**Example:**\n\n```v\nbox := \u0026boxx.Boxx {\n    top_right: \"x\"\n    top_left: \"x\"\n    bottom_right: \"x\"\n    bottom_left: \"x\"\n    vertical: \"+\"\n    horizontal: \"+\"\n}\n```\n\n#### Boxx.print(`string`, `string`)\n\nPrint the box according to the specified config.\n\n**Params:**\n\n`text`: The text that is to appear inside the box\n\n`title`: The title at the top of the box. It is always center aligned. (optional)\n\n### Find this library useful? :heart:\n\nSupport it by joining **[stargazers](https://github.com/thecodrr/boxx/stargazers)** for this repository. :star:or [buy me a cup of coffee](https://ko-fi.com/thecodrr)\nAnd **[follow](https://github.com/thecodrr)** me for my next creations! 🤩\n\n### Much thanks to the developers of these repos:\n\n1. [Atrox/box](https://github.com/Atrox/box)\n2. [sindresorhus/cli-boxes](https://github.com/sindresorhus/cli-boxes)\n\n### License\n\n```\nMIT License\n\nCopyright (c) 2019 Abdullah Atta\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthecodrr%2Fboxx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthecodrr%2Fboxx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthecodrr%2Fboxx/lists"}