{"id":13518660,"url":"https://github.com/usablica/widearea","last_synced_at":"2025-04-12T21:33:56.089Z","repository":{"id":58239494,"uuid":"10192511","full_name":"usablica/widearea","owner":"usablica","description":"Create expandable textarea and write large amount of text easily.","archived":false,"fork":false,"pushed_at":"2015-06-25T17:21:54.000Z","size":275,"stargazers_count":1135,"open_issues_count":12,"forks_count":70,"subscribers_count":57,"default_branch":"master","last_synced_at":"2024-10-30T00:32:56.823Z","etag":null,"topics":["javascript","textarea"],"latest_commit_sha":null,"homepage":"http://usablica.github.io/widearea/","language":"JavaScript","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/usablica.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":"2013-05-21T09:47:35.000Z","updated_at":"2024-10-07T16:35:45.000Z","dependencies_parsed_at":"2022-08-31T03:02:01.776Z","dependency_job_id":null,"html_url":"https://github.com/usablica/widearea","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/usablica%2Fwidearea","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/usablica%2Fwidearea/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/usablica%2Fwidearea/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/usablica%2Fwidearea/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/usablica","download_url":"https://codeload.github.com/usablica/widearea/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248636815,"owners_count":21137527,"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":["javascript","textarea"],"created_at":"2024-08-01T05:01:47.421Z","updated_at":"2025-04-12T21:33:56.066Z","avatar_url":"https://github.com/usablica.png","language":"JavaScript","readme":"Widearea\n========\n\n\u003e Lightweight, easy-to-use JavaScript/CSS library to create expandable textarea and write large amount of text easily.\n\n## How to use\n\nReally simple. Just include both `widearea.js` and `widearea.css` in your page (use minified version for production) and then call this JavaScript function:\n\n    wideArea();\n\nSee online [demo](http://usablica.github.io/widearea/).\n\n## API\n\n###wideArea([selector])\n\nCreating a Widearea object.\n\n**Available since**: v0.1.0\n\n**Parameters:**\n - selector : String (optional)\n   Should be defined to search for `textarea`s in a specific container\n\n**Returns:**\n - wideArea object.\n\n**Example:**\n```javascript\nwideArea() //without selector, to search all textarea(s) in the page\nwideArea(\"#writingContainer\") //search for textarea(s) only in #writingContainer\n````\n\n-----\n\n###wideArea.setOption(option, value)\n\nSet a single option to wideArea object.\n\n**Available since**: v0.1.0\n\n**Parameters:**\n - option : String\n   Option key name.\n\n - value : String/Number\n   Value of the option.\n\n**Returns:**\n - wideArea object.\n\n**Example:**\n```javascript\nwideArea().setOption(\"defaultColorScheme\", \"dark\");\n````\n\n----\n\n###wideArea.setOptions(options)\n\nSet a group of options to the wideArea object.\n\n**Available since**: v0.1.0\n\n**Parameters:**\n - options : Object\n   Object that contains option keys with values.\n\n**Returns:**\n - wideArea object.\n\n**Example:**\n```javascript\nwideArea().setOptions({ defaultColorScheme: \"dark\", closeIconLabel: \"Exit\" });\n````\n\n-----\n\n###wideArea.clearData(value)\n\nClear the textarea value from localStorage\n\n**Available since**: v0.3.0\n\n**Parameters:**\n - value : Object | String | Number\n   This method accept parameter with different types\n     1. `Object` for clearing data using DOM object\n     2. `String` for clearing data using CSS selector\n     3. `Number` for clearing data using the widearea id\n\n**Returns:**\n - wideArea object.\n\n**Example:**\n```javascript\nwideArea().clearData(1); //clear textarea data with `data-widearea-id` == 1\nwideArea().clearData(\"#first\"); //clear textarea data with `#first` selector\nwideArea().clearData($(\"#first\")); //get DOM object with jQuery and pass it to clearData()\n````\n\n-----\n\n###Options:\n\n - `wideAreaAttr`: Extra attribute name for detecting `textarea`s that uses Widearea, default is `data-widearea`\n - `exitOnEsc`: Close Fullscreen mode when pressing Escape, default is `true`\n - `defaultColorScheme`: Default color scheme, default is `light`\n - `closeIconLabel`: Close icon label, default is `Close WideArea`.\n - `changeThemeIconLabel`: Change color scheme icon label, default is `Toggle Color Scheme`\n - `fullScreenIconLabel`: Fullscreen mode icon label, default is `WideArea Mode`\n - `autoSaveKeyPrefix`: Prefix key for localStorage items\n\n\n## Build\n\nFirst you should install `nodejs` and `npm`, then first run this command: `npm install` to install all dependencies.\n\nNow you can run this command to minify all static resources:\n\n    make build\n\n## Roadmap\n- More browser compatibility\n- Provide more examples\n- Add templating option\n\n## Release History\n\n * **v0.3.0** - 2013-07-26 \n   - Add auto-save option for all textareas\n   - Bug fixes\n\n * **v0.2.0** - 2013-06-07 \n   - Basic changes in initiating WideArea\n   - Remove WideArea div wrapper\n   - Code refactoring\n\n * **v0.1.1** - 2013-05-26 \n   - Adding tab-key support while typing\n   - Fix some bugs in multiple textareas\n   - Fix bug when textarea has an existing value\n\n * **v0.1.0** - 2013-05-22 \n   - First commit. \n\n## Author\n**Afshin Mehrabani**\n\n- [Twitter](https://twitter.com/afshinmeh)\n- [Github](https://github.com/afshinm)\n- [Personal page](http://afshinm.name/)  \n\n**Ehsan Arasteh**\n\n- [Twitter](https://twitter.com/ehsandotnet)\n- [Github](https://github.com/ehsandotnet)  \n\n## License\n\u003e Copyright (C) 2012 Afshin Mehrabani (afshin.meh@gmail.com)\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated \ndocumentation files (the \"Software\"), to deal in the Software without restriction, including without limitation \nthe rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, \nand to permit persons to whom the Software is furnished to do so, subject to the following conditions:\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions \nof the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED \nTO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL \nTHE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF \nCONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS \nIN THE SOFTWARE.\n","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fusablica%2Fwidearea","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fusablica%2Fwidearea","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fusablica%2Fwidearea/lists"}