{"id":20484014,"url":"https://github.com/nuxy/vue-baraja-js","last_synced_at":"2026-01-08T14:05:30.871Z","repository":{"id":57394629,"uuid":"358795845","full_name":"nuxy/vue-baraja-js","owner":"nuxy","description":":file_folder: The / baraja-js / plugin Vue 3 component wrapper. ","archived":false,"fork":false,"pushed_at":"2024-08-03T18:21:59.000Z","size":1818,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-22T20:42:11.395Z","etag":null,"topics":["animations","cards-game","carousel","components","shuffling","vuejs","wrapper-library"],"latest_commit_sha":null,"homepage":"http://baraja-js.nuxy.dev","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nuxy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2021-04-17T05:45:56.000Z","updated_at":"2024-08-03T18:21:38.000Z","dependencies_parsed_at":"2024-08-03T19:44:02.163Z","dependency_job_id":null,"html_url":"https://github.com/nuxy/vue-baraja-js","commit_stats":{"total_commits":23,"total_committers":1,"mean_commits":23.0,"dds":0.0,"last_synced_commit":"4444693d44988d2f7db8a83bdafc6d26640f2cb3"},"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuxy%2Fvue-baraja-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuxy%2Fvue-baraja-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuxy%2Fvue-baraja-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuxy%2Fvue-baraja-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nuxy","download_url":"https://codeload.github.com/nuxy/vue-baraja-js/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246352562,"owners_count":20763491,"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":["animations","cards-game","carousel","components","shuffling","vuejs","wrapper-library"],"created_at":"2024-11-15T16:19:29.782Z","updated_at":"2026-01-08T14:05:30.816Z","avatar_url":"https://github.com/nuxy.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Vue Baraja-JS\n\n[![npm version](https://badge.fury.io/js/vue-baraja-js.svg)](https://badge.fury.io/js/vue-baraja-js) [![](https://img.shields.io/npm/dm/vue-baraja-js)](https://www.npmjs.com/package/vue-baraja-js) [![Install size](https://packagephobia.com/badge?p=vue-baraja-js)](https://packagephobia.com/result?p=vue-baraja-js) [![](https://img.shields.io/github/v/release/nuxy/vue-baraja-js)](https://github.com/nuxy/vue-baraja-js/releases)\n\n![Preview](https://raw.githubusercontent.com/nuxy/baraja-js/master/package.gif)\n\n_Baraja_ is a JavaScript plugin that allows to move elements in a card-like fashion and spreads them like one would spread a deck of cards on a table.  It uses CSS transforms for rotating and translating the items.\n\nThere are several options available that will create various spreading possibilities of the items, for example, moving the items laterally or rotating them in a fan-like way.\n\nCheckout the [demo](https://nuxy.github.io/baraja-js) for examples of use.\n\n## Dependencies\n\n- [Node.js](https://nodejs.org)\n\n## Installation\n\nAdd to an existing [Vue](https://vuejs.org) project using [YARN](https://yarnpkg.com).\n\n    $ yarn add vue-baraja-js\n\n## Usage\n\n```javascript\nimport * as Vue from 'vue'\nimport BarajaJS from 'vue-baraja-js'; // or '../dist/vue-baraja-js';\n\nconst cards = [\n  {\n    imageSrc: 'path/to/image1.png',\n    title: 'card 1',\n    details: 'this is card 1'\n  },\n  {\n    imageSrc: 'path/to/image2.png',\n    title: 'card 2',\n    details: 'this is card 2'\n  },\n  {\n    imageSrc: 'path/to/image3.png',\n    title: 'card 3',\n    details: 'this is card 3'\n  },\n  {\n    imageSrc: 'path/to/image4.png',\n    title: 'card 4',\n    details: 'this is card 4'\n  },\n\n  // add more cards ...\n]\n\nconst app = Vue.createApp({\n  data() {\n    return {\n      fan: {}\n    };\n  },\n\n  methods: {\n\n    // Fan right\n    fanEvent() {\n      this.fan = {\n        direction: 'right',\n        easing: 'ease-out',\n        origin: {\n          x: 25,\n          y: 100\n        },\n        speed: 500,\n        range: 90,\n        center: true\n      };\n    }\n  },\n\n  template: `\n    \u003cbaraja-js id=\"baraja-el\" v-bind:fan=\"fan\"\u003e\n      \u003cli v-for=\"({imageSrc, title, details}, index) in cards\" :key=\"index\"\u003e\n        \u003cimg v-bind:src=\"imageSrc\" v-bind:alt=\"title\" /\u003e\n        \u003ch4\u003e{{title}}\u003c/h4\u003e\n        \u003cp\u003e{{details}}\u003c/p\u003e\n      \u003c/li\u003e\n    \u003c/baraja-js\u003e\n\n    \u003cbutton id=\"fan-button\" v-on:click=\"fanEvent\"\u003eFan right\u003c/button\u003e\n  `\n});\n\napp.component('baraja-js', BarajaJS).mount('#main');\n```\n\n## Component Props\n\n| Name     | Type     | Description              |\n|----------|----------|--------------------------|\n| id       | String   | Default `baraja-js`      |\n| options  | Object   | Override animation [defaults](https://github.com/nuxy/baraja-js#global-options). |\n| add      | String   | Card item [HTML markup](https://github.com/nuxy/baraja-js#html-markup). |\n| fan      | Object   | Configure [fan options](https://github.com/nuxy/baraja-js#fan-options). |\n| close    | Boolean  | Close the deck if `true` |\n| last     | Boolean  | Show last card if `true` |\n| next     | Boolean  | Show next card if `true` |\n\n## Documentation\n\n- [Methods](https://github.com/nuxy/baraja-js#methods)\n- [Fan options](https://github.com/nuxy/baraja-js#fan-options)\n\n## Developers\n\n### CLI options\n\nRun [ESLint](https://eslint.org) on project sources:\n\n    $ npm run lint\n\nTranspile ES6 sources (using [Babel](https://babeljs.io)) and minify to a distribution:\n\n    $ npm run build\n\nBundle [demo](https://github.com/nuxy/vue-baraja-js/tree/master/demo) sources (using [Webpack](https://webpack.js.org)):\n\n    $ npm run webpack\n\n## Contributions\n\nIf you fix a bug, or have a code you want to contribute, please send a pull-request with your changes. (Note: Before committing your code please ensure that you are following the [Node.js style guide](https://github.com/felixge/node-style-guide))\n\n## Versioning\n\nThis package is maintained under the [Semantic Versioning](https://semver.org) guidelines.\n\n## License and Warranty\n\nThis package is distributed in the hope that it will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose.\n\n_Baraja-JS_ is provided under the terms of the [MIT license](http://www.opensource.org/licenses/mit-license.php)\n\nDemo and proof-of-concept by [Codrops](https://www.codrops.com) [[LICENSE](http://tympanus.net/codrops/licensing)]\n\nDemo background patterns by [Subtle Patterns](https://subtlepatterns.com) [[LICENSE](http://creativecommons.org/licenses/by-sa/3.0/deed.en_US\n)]\n\nDemo card illustrations by [Jason Custer](http://dribbble.com/jdelamancha)\n\n## Author\n\n[Marc S. Brooks](https://github.com/nuxy)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnuxy%2Fvue-baraja-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnuxy%2Fvue-baraja-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnuxy%2Fvue-baraja-js/lists"}