{"id":18735059,"url":"https://github.com/irontec/angular-bootstrap-simple-chat","last_synced_at":"2025-04-13T06:41:11.326Z","repository":{"id":25176656,"uuid":"28599815","full_name":"irontec/angular-bootstrap-simple-chat","owner":"irontec","description":"Simple AngularJS Chat Directive with Bootstrap","archived":false,"fork":false,"pushed_at":"2016-06-22T18:41:53.000Z","size":89,"stargazers_count":147,"open_issues_count":16,"forks_count":83,"subscribers_count":37,"default_branch":"master","last_synced_at":"2025-03-26T23:07:53.651Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"CSS","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/irontec.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":"2014-12-29T17:19:42.000Z","updated_at":"2024-05-08T22:31:57.000Z","dependencies_parsed_at":"2022-08-23T18:00:38.433Z","dependency_job_id":null,"html_url":"https://github.com/irontec/angular-bootstrap-simple-chat","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/irontec%2Fangular-bootstrap-simple-chat","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/irontec%2Fangular-bootstrap-simple-chat/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/irontec%2Fangular-bootstrap-simple-chat/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/irontec%2Fangular-bootstrap-simple-chat/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/irontec","download_url":"https://codeload.github.com/irontec/angular-bootstrap-simple-chat/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248675434,"owners_count":21143763,"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-11-07T15:15:39.214Z","updated_at":"2025-04-13T06:41:11.301Z","avatar_url":"https://github.com/irontec.png","language":"CSS","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ``\u003cirontec-simple-chat\u003e``\n\nAn AngularJS+Bootstrap Simple Chat Directive\n\n![AngularJS Chat](https://raw.githubusercontent.com/irontec/angular-bootstrap-simple-chat/master/icon.png \"AngularJS Chat\")\n\n# Usage\n## Requirements\n\n```json\n\"dependencies\": {\n  \"angularjs\": \"~1.3.8\",\n  \"bootstrap\": \"~3.3.1\",\n  \"angularjs-scroll-glue\": \"~0.0.1\"\n}\n```\n## Installation\n### Install with Bower\n```bash\nbower install --save angular-bootstrap-simple-chat\n```\n### Add the dependencies to your index.html\n```html\n\u003c!-- Dependencies --\u003e\n\u003clink rel=\"stylesheet\" href=\"bower_components/bootstrap/dist/css/bootstrap.min.css\"\u003e\n\u003cscript src=\"bower_components/angularjs/angular.js\"\u003e\u003c/script\u003e\n\n\u003c!-- Simple Chat --\u003e\n\u003clink rel=\"stylesheet\" href=\"bower_components/angular-bootstrap-simple-chat/src/css/style.css\"\u003e\n\u003cscript src=\"bower_components/angular-bootstrap-simple-chat/src/scripts/index.js\"\u003e\u003c/script\u003e\n\n```\n\n### Load the module in your app\n```javascript\nangular.module('app', ['irontec.simpleChat']);\n```\n\n## Using\n```html\n/** VIEW **/\n\u003cirontec-simple-chat\n  messages=\"vm.messages\"\n  username=\"vm.username\"\n  input-placeholder-text=\"You can write here\"\n  submit-button-text=\"Send your message\"\n  title=\"Super Awesome Chat\"\n  theme=\"material\"\n  submit-function=\"vm.sendMessage\"\n  visible=\"vm.visible\"\n  expand-on-new=\"vm.expandOnNew\"\u003e\n\u003c/irontec-simple-chat\u003e\n```\n\n```javascript\n/** CONTROLLER **/\nangular.module('app').controller('Shell', Shell);\n\nfunction Shell() {\n\n  var vm = this;\n\n  vm.messages = [\n    {\n      'username': 'username1',\n      'content': 'Hi!'\n    },\n    {\n      'username': 'username2',\n      'content': 'Hello!'\n    },\n    {\n      'username': 'username2',\n      'content': 'Hello!'\n    },\n    {\n      'username': 'username2',\n      'content': 'Hello!'\n    },\n    {\n      'username': 'username2',\n      'content': 'Hello!'\n    },\n    {\n      'username': 'username2',\n      'content': 'Hello!'\n    }\n  ];\n\n  vm.username = 'username1';\n\n  vm.sendMessage = function(message, username) {\n    if(message \u0026\u0026 message !== '' \u0026\u0026 username) {\n      vm.messages.push({\n        'username': username,\n        'content': message\n      });\n    }\n  };\n  vm.visible = true;\n  vm.expandOnNew = true;\n}\n```\n\n## Documentation\n### Params\n* messages: array of messages to show.\nMessage Format: {username: 'username', content: 'My message'}\n* username: username of the user using the app\n* input-placeholder-text: String, text in the input placeholder\n* title: String, text in the chat top title\n* theme: String, theme used for the chat\n* submit-function: Function in the controller to be launched on the new message submit. It receives two params: *message \u0026 username*\n* visible: Boolean, controls visibility on the page (required)\n\n## Using themes\n* First, add the themes stylesheet to your index.html\n\n```html\n\u003clink rel=\"stylesheet\" href=\"bower_components/angular-bootstrap-simple-chat/src/css/themes.css\"\u003e\n```\n* Define the theme you will use with the theme property\n* List of themes:\n  * irontec\n  * material\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Firontec%2Fangular-bootstrap-simple-chat","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Firontec%2Fangular-bootstrap-simple-chat","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Firontec%2Fangular-bootstrap-simple-chat/lists"}