{"id":23156458,"url":"https://github.com/thecreation/jquery-slidepanel","last_synced_at":"2025-08-17T23:32:35.356Z","repository":{"id":29763487,"uuid":"33307307","full_name":"thecreation/jquery-slidePanel","owner":"thecreation","description":"A jquery plugin that show a slide panel on side.","archived":false,"fork":false,"pushed_at":"2019-01-30T18:14:40.000Z","size":507,"stargazers_count":46,"open_issues_count":15,"forks_count":24,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-12-15T08:17:47.500Z","etag":null,"topics":["jquery-plugin","slide-panel","slidepanel"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thecreation.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-04-02T12:20:52.000Z","updated_at":"2020-12-26T01:26:44.000Z","dependencies_parsed_at":"2022-07-22T08:20:03.825Z","dependency_job_id":null,"html_url":"https://github.com/thecreation/jquery-slidePanel","commit_stats":null,"previous_names":["amazingsurge/jquery-slidepanel"],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecreation%2Fjquery-slidePanel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecreation%2Fjquery-slidePanel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecreation%2Fjquery-slidePanel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecreation%2Fjquery-slidePanel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thecreation","download_url":"https://codeload.github.com/thecreation/jquery-slidePanel/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230181485,"owners_count":18185938,"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":["jquery-plugin","slide-panel","slidepanel"],"created_at":"2024-12-17T21:13:43.784Z","updated_at":"2024-12-17T21:13:44.428Z","avatar_url":"https://github.com/thecreation.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# [jQuery slidePanel](https://github.com/amazingSurge/jquery-slidePanel) ![bower][bower-image] [![NPM version][npm-image]][npm-url] [![Dependency Status][daviddm-image]][daviddm-url] [![prs-welcome]](#contributing)\n\n\u003e A jquery plugin that show a slide panel on side.\n\n## Table of contents\n- [Main files](#main-files)\n- [Quick start](#quick-start)\n- [Requirements](#requirements)\n- [Usage](#usage)\n- [Examples](#examples)\n- [Options](#options)\n- [Methods](#methods)\n- [Events](#events)\n- [No conflict](#no-conflict)\n- [Browser support](#browser-support)\n- [Contributing](#contributing)\n- [Development](#development)\n- [Changelog](#changelog)\n- [Copyright and license](#copyright-and-license)\n\n## Main files\n```\ndist/\n├── jquery-slidePanel.js\n├── jquery-slidePanel.es.js\n├── jquery-slidePanel.min.js\n└── css/\n    ├── slidePanel.css\n    └── slidePanel.min.css\n```\n\n## Quick start\nSeveral quick start options are available:\n#### Download the latest build\n\n * [Development](https://raw.githubusercontent.com/amazingSurge/jquery-slidePanel/master/dist/jquery-slidePanel.js) - unminified\n * [Production](https://raw.githubusercontent.com/amazingSurge/jquery-slidePanel/master/dist/jquery-slidePanel.min.js) - minified\n\n#### Install From Bower\n```sh\nbower install jquery-slidePanel --save\n```\n\n#### Install From Npm\n```sh\nnpm install jquery-slidePanel --save\n```\n\n#### Install From Yarn\n```sh\nyarn add jquery-slidePanel\n```\n\n#### Build From Source\nIf you want build from source:\n\n```sh\ngit clone git@github.com:amazingSurge/jquery-slidePanel.git\ncd jquery-slidePanel\nnpm install\nnpm install -g gulp-cli babel-cli\ngulp build\n```\n\nDone!\n\n## Requirements\n`jquery-slidePanel` requires the latest version of [`jQuery`](https://jquery.com/download/).\n\n## Usage\n#### Including files:\n\n```html\n\u003clink rel=\"stylesheet\" href=\"/path/to/slidePanel.css\"\u003e\n\u003cscript src=\"/path/to/jquery.js\"\u003e\u003c/script\u003e\n\u003cscript src=\"/path/to/jquery-slidePanel.js\"\u003e\u003c/script\u003e\n```\n\n#### Required HTML structure\n\n```html\n\u003ca href=\"ajax.html\" class=\"example\" data-direction=\"left\"\u003eTrigger\u003c/a\u003e\n```\n\n#### Initialization\nAll you need to do is call the plugin on the element:\n\n```javascript\njQuery(function($) {\n  $('.example').slidePanel(); \n});\n```\n\n## Examples\nThere are some example usages that you can look at to get started. They can be found in the\n[examples folder](https://github.com/amazingSurge/jquery-slidePanel/tree/master/examples).\n\n## Options\n`jquery-slidePanel` can accept an options object to alter the way it behaves. You can see the default options by call `$.slidePanel.setDefaults()`. The structure of an options object is as follows:\n\n```\n{\n  skin: null,\n\n  classes: {\n    base: 'slidePanel',\n    show: 'slidePanel-show',\n    loading: 'slidePanel-loading',\n    content: 'slidePanel-content',\n    dragging: 'slidePanel-dragging',\n    willClose: 'slidePanel-will-close'\n  },\n\n  closeSelector: null,\n\n  template(options) {\n    return `\u003cdiv class=\"${options.classes.base} ${options.classes.base}-${options.direction}\"\u003e\u003cdiv class=\"${options.classes.content}\"\u003e\u003c/div\u003e\u003c/div\u003e`;\n  },\n\n  loading: {\n    appendTo: 'panel', // body, panel\n    template(options) {\n      return `\u003cdiv class=\"${options.classes.loading}\"\u003e\u003c/div\u003e`;\n    },\n    showCallback(options) {\n      this.$el.addClass(`${options.classes.loading}-show`);\n    },\n    hideCallback(options) {\n      this.$el.removeClass(`${options.classes.loading}-show`);\n    }\n  },\n\n  contentFilter(content, object) {\n    return content;\n  },\n\n  useCssTransforms3d: true,\n  useCssTransforms: true,\n  useCssTransitions: true,\n\n  dragTolerance: 150,\n\n  mouseDragHandler: null,\n  mouseDrag: true,\n  touchDrag: true,\n  pointerDrag: true,\n\n  direction: 'right', // top, bottom, left, right\n  duration: '500',\n  easing: 'ease', // linear, ease-in, ease-out, ease-in-out\n\n  // callbacks\n  beforeLoad: $.noop, // Before loading\n  afterLoad: $.noop, // After loading\n  beforeShow: $.noop, // Before opening\n  afterShow: $.noop, // After opening\n  onChange: $.noop, // On changing\n  beforeHide: $.noop, // Before closing\n  afterHide: $.noop, // After closing\n  beforeDrag: $.noop, // Before drag\n  afterDrag: $.noop // After drag\n}\n```\n\n## Methods\nMethods are called on slidePanel instances through the slidePanel method itself.\nYou can also save the instances to variable for further use.\n\n```javascript\n// call directly\n$().slidePanel('show');\n\n// or\nvar api = $().data('slidePanel');\napi.show();\n```\n\n#### show()\nShow the slide panel.\n```javascript\n$().slidePanel('show');\n```\n\n#### hide()\nHide the slide panel.\n```javascript\n$().slidePanel('hide');\n```\n\n### Api\nSlidePanel have global api to easy work with.\n\n#### show()\n```javascript\n// show the ajax content within slide panel\n$.slidePanel.show({\n  url: 'ajax.html',\n  settings: {\n    method: 'GET'\n  }\n});\n\n// show the slide panel with options\n$.slidePanel.show({\n  url: 'ajax.html'\n}, {\n  direction: 'top',\n  beforeLoad: function(coming, previous) {\n    console.info('beforeLoad');\n  }\n};\n\n// show the slide panel with contents\n$.slidePanel.show({\n  content: '\u003cdiv\u003e\u003ch2\u003eTitle\u003c/h2\u003e\u003cp\u003econtent here\u003c/p\u003e\u003c/div\u003e'\n});\n```\n\n#### hide()\nHide the current slidepanel.\n\n```javascript\n$.slidePanel.hide();\n```\n\n## Events\n`jquery-slidePanel` provides custom events for the plugin’s unique actions. \n\n```javascript\n$(document).on('slidePanel::beforeShow', function (e) {\n  // on instance ready\n});\n\n```\n\nEvent       | Description\n----------- | -----------\nbeforeLoad  | Fires before loading the content.\nafterLoad   | Fires after the content loaded.\nbeforeShow  | Fires before show the slidepanel.\nafterShow   | Fires after the slidepanel is shown.\nonChange    | Fires when the slidepanel content is changing. \nbeforeHide  | Fires before hide the slidepanel. \nafterHide   | Fires after the slidepanel is hidden. \nbeforeDrag  | Fires before drag the slidepanel.\nafterDrag   | Fires after drag the slidepanel. \n\n## No conflict\nIf you have to use other plugin with the same namespace, just call the `$.slidePanel.noConflict` method to revert to it.\n\n```html\n\u003cscript src=\"other-plugin.js\"\u003e\u003c/script\u003e\n\u003cscript src=\"jquery-slidePanel.js\"\u003e\u003c/script\u003e\n\u003cscript\u003e\n  $.slidePanel.noConflict();\n  // Code that uses other plugin's \"$().slidePanel\" can follow here.\n\u003c/script\u003e\n```\n\n## Browser support\n\nTested on all major browsers.\n\n| \u003cimg src=\"https://raw.githubusercontent.com/alrra/browser-logos/master/safari/safari_32x32.png\" alt=\"Safari\"\u003e | \u003cimg src=\"https://raw.githubusercontent.com/alrra/browser-logos/master/chrome/chrome_32x32.png\" alt=\"Chrome\"\u003e | \u003cimg src=\"https://raw.githubusercontent.com/alrra/browser-logos/master/firefox/firefox_32x32.png\" alt=\"Firefox\"\u003e | \u003cimg src=\"https://raw.githubusercontent.com/alrra/browser-logos/master/edge/edge_32x32.png\" alt=\"Edge\"\u003e | \u003cimg src=\"https://raw.githubusercontent.com/alrra/browser-logos/master/internet-explorer/internet-explorer_32x32.png\" alt=\"IE\"\u003e | \u003cimg src=\"https://raw.githubusercontent.com/alrra/browser-logos/master/opera/opera_32x32.png\" alt=\"Opera\"\u003e |\n|:--:|:--:|:--:|:--:|:--:|:--:|\n| Latest ✓ | Latest ✓ | Latest ✓ | Latest ✓ | 9-11 ✓ | Latest ✓ |\n\nAs a jQuery plugin, you also need to see the [jQuery Browser Support](http://jquery.com/browser-support/).\n\n## Contributing\nAnyone and everyone is welcome to contribute. Please take a moment to\nreview the [guidelines for contributing](CONTRIBUTING.md). Make sure you're using the latest version of `jquery-slidePanel` before submitting an issue. There are several ways to help out:\n\n* [Bug reports](CONTRIBUTING.md#bug-reports)\n* [Feature requests](CONTRIBUTING.md#feature-requests)\n* [Pull requests](CONTRIBUTING.md#pull-requests)\n* Write test cases for open bug issues\n* Contribute to the documentation\n\n## Development\n`jquery-slidePanel` is built modularly and uses Gulp as a build system to build its distributable files. To install the necessary dependencies for the build system, please run:\n\n```sh\nnpm install -g gulp\nnpm install -g babel-cli\nnpm install\n```\n\nThen you can generate new distributable files from the sources, using:\n```\ngulp build\n```\n\nMore gulp tasks can be found [here](CONTRIBUTING.md#available-tasks).\n\n## Changelog\nTo see the list of recent changes, see [Releases section](https://github.com/amazingSurge/jquery-slidePanel/releases).\n\n## Copyright and license\nCopyright (C) 2016 amazingSurge.\n\nLicensed under [the LGPL license](LICENSE).\n\n[⬆ back to top](#table-of-contents)\n\n[bower-image]: https://img.shields.io/bower/v/jquery-slidePanel.svg?style=flat\n[bower-link]: https://david-dm.org/amazingSurge/jquery-slidePanel/dev-status.svg\n[npm-image]: https://badge.fury.io/js/jquery-slidePanel.svg?style=flat\n[npm-url]: https://npmjs.org/package/jquery-slidePanel\n[license]: https://img.shields.io/npm/l/jquery-slidePanel.svg?style=flat\n[prs-welcome]: https://img.shields.io/badge/PRs-welcome-brightgreen.svg\n[daviddm-image]: https://david-dm.org/amazingSurge/jquery-slidePanel.svg?style=flat\n[daviddm-url]: https://david-dm.org/amazingSurge/jquery-slidePanel\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthecreation%2Fjquery-slidepanel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthecreation%2Fjquery-slidepanel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthecreation%2Fjquery-slidepanel/lists"}