index.html 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675
  1. <!DOCTYPE html>
  2. <html lang="en-us">
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>Emojione-area by mervick</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1">
  7. <link rel='stylesheet' type='text/css' href='https://fonts.googleapis.com/css?family=Open+Sans:400,700'>
  8. <link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/3.0.3/normalize.min.css" media="screen">
  9. <!--<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/emojione/1.5.2/assets/sprites/emojione.sprites.css" media="screen">-->
  10. <link rel="stylesheet" type="text/css" href="stylesheet.css" media="screen">
  11. <link rel="stylesheet" type="text/css" href="../dist/emojionearea.min.css" media="screen">
  12. <link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.5.0/css/font-awesome.min.css" media="screen">
  13. <link rel="stylesheet" type="text/css" href="http://mervick.github.io/lib/google-code-prettify/skins/tomorrow.css" media="screen">
  14. <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>
  15. <!--<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/emojione/1.5.2/lib/js/emojione.min.js"></script>-->
  16. <script type="text/javascript" src="http://mervick.github.io/lib/google-code-prettify/prettify.js"></script>
  17. <script type="text/javascript" src="../dist/emojionearea.js"></script>
  18. <style>
  19. .clearfix:after {
  20. content: " ";
  21. display: table;
  22. clear: both;
  23. }
  24. </style>
  25. </head>
  26. <body onload="prettyPrint()">
  27. <section class="page-header">
  28. <a href="/emojionearea/">
  29. <h1 class="logo">Emoji One Area</h1>
  30. </a>
  31. <!--<h1 class="project-name">Emojione-area</h1>-->
  32. <h2 class="project-tagline">Simple jQuery WYSIWYG editor with emojione smiles for use in replies and comments</h2>
  33. <a href="https://github.com/mervick/emojionearea" class="btn"><i class="fa fa-github"></i>View on GitHub</a>
  34. <a href="https://github.com/mervick/emojionearea/zipball/master" class="btn"><i class="fa fa-download"></i>Download .zip</a>
  35. <a href="https://github.com/mervick/emojionearea/tarball/master" class="btn"><i class="fa fa-download"></i>Download .tar.gz</a>
  36. </section>
  37. <section class="main-content">
  38. <h2>Emoji One Area</h2>
  39. <p>Emojione-area is a small jQuery plugin that allows you to transform any html element into simple WYSIWYG editor
  40. with ability to use Emojione icons. The end result is a secure text/plain in which the image icons will be replaced
  41. with their Unicode analogues.</p>
  42. <h2 id="demo"><a href="#demo">Demo</a></h2>
  43. <div class="clearfix">
  44. <div class="row">
  45. <div class="col-6">
  46. <p>From:</p>
  47. <textarea id="demo1">
  48. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  49. </textarea>
  50. </div>
  51. <div class="col-6">
  52. <p>To:</p>
  53. <div id="container"></div>
  54. </div>
  55. </div>
  56. </div>
  57. <script type="text/javascript">
  58. $(document).ready(function() {
  59. $("#demo1").emojioneArea({
  60. container: "#container",
  61. hideSource: false,
  62. useSprite: false
  63. });
  64. });
  65. </script>
  66. <p>Code:</p>
  67. <pre class="prettyprint linenums">
  68. &lt;div class=&quot;row&quot;&gt;
  69. &lt;div class=&quot;col-6&quot;&gt;
  70. &lt;p&gt;From:&lt;/p&gt;
  71. &lt;textarea id=&quot;demo1&quot;&gt;
  72. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  73. &lt;/textarea&gt;
  74. &lt;/div&gt;
  75. &lt;div class=&quot;col-6&quot;&gt;
  76. &lt;p&gt;To:&lt;/p&gt;
  77. &lt;div id=&quot;container&quot;&gt;&lt;/div&gt;
  78. &lt;/div&gt;
  79. &lt;/div&gt;
  80. &lt;script type=&quot;text/javascript&quot;&gt;
  81. $(document).ready(function() {
  82. $(&quot;#demo1&quot;).emojioneArea({
  83. container: &quot;#container&quot;,
  84. hideSource: false,
  85. });
  86. });
  87. &lt;/script&gt;
  88. </pre>
  89. <h2>Standalone mode</h2>
  90. <p>Allows a single emoji to be picked without a text input, useful for emoji reactions or as an addition to another WYSIWYG editor. Can be initialised with an initial value or a placeholder.</p>
  91. <div id="standalone" data-emoji-placeholder=":grimacing:"></div>
  92. <script type="text/javascript">
  93. $(document).ready(function() {
  94. $("#standalone").emojioneArea({
  95. standalone: true,
  96. autocomplete: false
  97. });
  98. });
  99. </script>
  100. <pre class="prettyprint linenums">
  101. &lt;div id=&quot;standalone&quot; data-emoji-placeholder=&quot;:smiley:&quot;&gt;&lt;/div&gt;
  102. &lt;script type=&quot;text/javascript&quot;&gt;
  103. $(document).ready(function() {
  104. $(&quot;#standalone&quot;).emojioneArea({
  105. standalone: true,
  106. autocomplete: false
  107. });
  108. });
  109. &lt;/script&gt;
  110. </pre>
  111. <h2 id="installation"><a href="#installation">Installation</a></h2>
  112. <p>The preferred way to install is via <code>bower</code>, <code>npm</code> or <code>Composer</code>.</p>
  113. <p>Using <a href="http://bower.io">Bower</a>:</p>
  114. <pre class="prettyprint lang-bash ">bower install emojionearea</pre>
  115. <p>Using <a href="https://www.npmjs.com/">npm</a>:</p>
  116. <pre class="prettyprint lang-bash">npm install emojionearea</pre>
  117. <p>Using <a href="https://getcomposer.org/">Composer</a>:</p>
  118. <pre class="">composer require mervick/emojionearea</pre>
  119. <p>Also you can download source files directly from <a href="https://github.com/mervick/emojionearea">Github</a>.</p>
  120. <style>
  121. a > .com {
  122. color: blue!important;
  123. }
  124. </style>
  125. <h2 id="options"><a href="#options">Options</a></h2>
  126. <p>Customize emojione version</p>
  127. <pre class="prettyprint">
  128. // version by default is 1.5.2
  129. <!--window.emojioneVersion = "2.1.1";-->
  130. </pre>
  131. <p>Default options</p>
  132. <pre class="prettyprint">
  133. var default_options = {
  134. template : "&lt;editor/&gt;&lt;filters/&gt;&lt;tabs/&gt;", // plugin template
  135. dir : "ltr", // direction <a class="link" href="http://www.w3schools.com/tags/att_global_dir.asp">http://www.w3schools.com/tags/att_global_dir.asp</a>
  136. spellcheck : false, // spellcheck <a href="http://www.w3schools.com/tags/att_global_spellcheck.asp">http://www.w3schools.com/tags/att_global_spellcheck.asp</a>
  137. autocomplete : "off", // autocomplete <a href="http://www.w3schools.com/tags/att_input_autocomplete.asp">http://www.w3schools.com/tags/att_input_autocomplete.asp</a>
  138. autocorrect : "off", // autocorrect <a href="https://davidwalsh.name/disable-autocorrect">https://davidwalsh.name/disable-autocorrect</a>
  139. autocapitalize : "off", // autocapitalize <a href="http://www.w3schools.com/tags/att_input_autocomplete.asp">http://www.w3schools.com/tags/att_input_autocomplete.asp</a>
  140. placeholder : null, // placeholder
  141. container : null, // by default, emojionearea container created directly under source,
  142. // in this option you can specify custom {jQuery|selector} container
  143. hideSource : true, // hide source element after binding
  144. autoHideFilters : false, // auto hide filters panel
  145. useSprite : true, // use sprite instead of images, is awesome, but not works in old browsers
  146. shortnames : false, // if true - will converts emojis to short names,
  147. // by default converts emojis to unicode characters
  148. filters: {
  149. // customize filters & emoji buttons
  150. // see in <a href="https://raw.githubusercontent.com/mervick/emojionearea/master/src/var/default_options.js">source file</a>
  151. },
  152. events: {
  153. // events handlers
  154. // see <a href="#events">events</a> below
  155. }
  156. };
  157. </pre>
  158. <h2 id="api"><a href="#api">Api</a></h2>
  159. <pre class="prettyprint">
  160. .on(events, handler);
  161. // - events
  162. // Type: String
  163. // One or more space-separated event types and optional namespaces
  164. // - handler
  165. // Type: Function(jQuery Element, Event eventObject [, Anything extraParameter ] [, ... ] )
  166. // A function to execute when the event is triggered.
  167. .off(events[, handler]);
  168. // - events
  169. // Type: String
  170. // One or more space-separated event types and optional namespaces
  171. // - handler
  172. // Type: Function(jQuery Element, Event eventObject [, Anything extraParameter ] [, ... ] )
  173. // A handler function previously attached for the event(s)
  174. // built-in events:
  175. // "mousedown", "mouseup", "click", "keyup", "keydown", "keypress"
  176. // "filter.click", "emojibtn.click", "arrowLeft.click", "arrowRight.click",
  177. // "focus", "blur", "paste", "resize", "change"
  178. .setText(str);
  179. // - str
  180. // Type: String
  181. // Set text
  182. .getText();
  183. // Get text
  184. // Usage methods, example:
  185. var el = $("selector").emojioneArea();
  186. el[0].emojioneArea.on("emojibtn.click", function(btn) {
  187. console.log(btn.html());
  188. });
  189. </pre>
  190. <h2 id="events"><a href="#events">Events</a></h2>
  191. <p>Two ways to set events, in options:</p>
  192. <pre class="prettyprint">
  193. $("selector").emojioneArea({
  194. events: {
  195. /**
  196. * @param {jQuery} editor EmojioneArea input
  197. * @param {Event} event jQuery Event object
  198. */
  199. focus: function (editor, event) {
  200. console.log('event:focus');
  201. },
  202. /**
  203. * @param {jQuery} editor EmojioneArea input
  204. * @param {Event} event jQuery Event object
  205. */
  206. blur: function (editor, event) {
  207. console.log('event:blur');
  208. },
  209. /**
  210. * @param {jQuery} editor EmojioneArea input
  211. * @param {Event} event jQuery Event object
  212. */
  213. mousedown: function (editor, event) {
  214. console.log('event:mousedown');
  215. },
  216. /**
  217. * @param {jQuery} editor EmojioneArea input
  218. * @param {Event} event jQuery Event object
  219. */
  220. mouseup: function (editor, event) {
  221. console.log('event:mouseup');
  222. },
  223. /**
  224. * @param {jQuery} editor EmojioneArea input
  225. * @param {Event} event jQuery Event object
  226. */
  227. click: function (editor, event) {
  228. console.log('event:click');
  229. },
  230. /**
  231. * @param {jQuery} editor EmojioneArea input
  232. * @param {Event} event jQuery Event object
  233. */
  234. keyup: function (editor, event) {
  235. console.log('event:keyup');
  236. },
  237. /**
  238. * @param {jQuery} editor EmojioneArea input
  239. * @param {Event} event jQuery Event object
  240. */
  241. keydown: function (editor, event) {
  242. console.log('event:keydown');
  243. },
  244. /**
  245. * @param {jQuery} editor EmojioneArea input
  246. * @param {Event} event jQuery Event object
  247. */
  248. keypress: function (editor, event) {
  249. console.log('event:keypress');
  250. },
  251. /**
  252. * @param {jQuery} editor EmojioneArea input
  253. * @param {Event} event jQuery Event object
  254. */
  255. paste: function (editor, event) {
  256. console.log('event:paste');
  257. },
  258. /**
  259. * @param {jQuery} editor EmojioneArea input
  260. * @param {Event} event jQuery Event object
  261. */
  262. change: function (editor, event) {
  263. console.log('event:change');
  264. },
  265. /**
  266. * @param {jQuery} filter EmojioneArea filter
  267. * @param {Event} event jQuery Event object
  268. */
  269. filter_click: function (filter, event) {
  270. console.log('event:filter.click, filter=' + filter.data("filter"));
  271. },
  272. /**
  273. * @param {jQuery} button EmojioneArea emoji button
  274. * @param {Event} event jQuery Event object
  275. */
  276. emojibtn_click: function (button, event) {
  277. console.log('event:emojibtn.click, emoji=' + button.children().data("name"));
  278. },
  279. /**
  280. * @param {jQuery} button EmojioneArea left arrow button
  281. * @param {Event} event jQuery Event object
  282. */
  283. arrowLeft_click: function (button, event) {
  284. console.log('event:arrowLeft.click');
  285. },
  286. /**
  287. * @param {jQuery} button EmojioneArea right arrow button
  288. * @param {Event} event jQuery Event object
  289. */
  290. arrowRight_click: function (button, event) {
  291. console.log('event:arrowRight.click');
  292. }
  293. }
  294. });
  295. </pre>
  296. <p>or by <code>.on()</code> & <code>.off()</code> methods:</p>
  297. <pre class="prettyprint">
  298. var el = $("selector").emojioneArea();
  299. // attach event handler
  300. el[0].emojioneArea.on("emojibtn.click", function(button, event) {
  301. console.log('event:emojibtn.click, emoji=' + button.children().data("name"));
  302. });
  303. // unset all handlers attached to event
  304. el[0].emojioneArea.off("emojibtn.click");
  305. // like in jQuery you can specify few events separated by space
  306. el[0].emojioneArea.off("focus blur");
  307. // set & unset custom handler
  308. var eventHandler1 = function(button, event) {
  309. console.log('event1');
  310. };
  311. var eventHandler2 = function(button, event) {
  312. console.log('event2');
  313. };
  314. // attach event handlers
  315. el[0].emojioneArea.on("click", eventHandler1);
  316. el[0].emojioneArea.on("click", eventHandler2);
  317. // unset eventHandler1
  318. el[0].emojioneArea.off("click", eventHandler1);
  319. </pre>
  320. <style>
  321. #events-panels {
  322. width: 100%;
  323. }
  324. #events-panels:after,
  325. #events-panels:before {
  326. content: " ";
  327. display: block;
  328. clear: both;
  329. }
  330. #events-panels .source-panel {
  331. float: left;
  332. width: 49%;
  333. margin-right: 2%;
  334. }
  335. #events-panels .console-panel {
  336. float: left;
  337. width: 49%;
  338. background-color: #333;
  339. color: #ccc!important;
  340. padding: 5px 10px 10px;
  341. border-radius: 2px;
  342. height: 300px;
  343. max-height: 300px;
  344. overflow: auto;
  345. }
  346. #events-panels .console-panel p {
  347. color: #ccc!important;
  348. font-size: 11px;
  349. margin: 0 0 2px 0;
  350. }
  351. </style>
  352. <p>Events listener example</p>
  353. <div id="events-panels">
  354. <div class="source-panel">
  355. <textarea id="example_events">
  356. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  357. </textarea>
  358. </div>
  359. <div class="console-panel">
  360. <p><span style="color: #df4545;font-size: 14px;">EmojioneArea Events</span></p>
  361. </div>
  362. </div>
  363. <script type="text/javascript">
  364. var console_panel = $("#events-panels .console-panel");
  365. function console_log($str) {
  366. console_panel.append($("<p/>").text($str))
  367. .animate({scrollTop: console_panel[0].scrollHeight + 1000}, 0);
  368. }
  369. $(document).ready(function() {
  370. $("#example_events").emojioneArea({
  371. autoHideFilters: false,
  372. events: {
  373. /**
  374. * @param {jQuery} editor EmojioneArea input
  375. * @param {Event} event jQuery Event object
  376. */
  377. focus: function (editor, event) {
  378. console_log('event:focus');
  379. },
  380. /**
  381. * @param {jQuery} editor EmojioneArea input
  382. * @param {Event} event jQuery Event object
  383. */
  384. blur: function (editor, event) {
  385. console_log('event:blur');
  386. },
  387. /**
  388. * @param {jQuery} editor EmojioneArea input
  389. * @param {Event} event jQuery Event object
  390. */
  391. mousedown: function (editor, event) {
  392. console_log('event:mousedown');
  393. },
  394. /**
  395. * @param {jQuery} editor EmojioneArea input
  396. * @param {Event} event jQuery Event object
  397. */
  398. mouseup: function (editor, event) {
  399. console_log('event:mouseup');
  400. },
  401. /**
  402. * @param {jQuery} editor EmojioneArea input
  403. * @param {Event} event jQuery Event object
  404. */
  405. click: function (editor, event) {
  406. console_log('event:click');
  407. },
  408. /**
  409. * @param {jQuery} editor EmojioneArea input
  410. * @param {Event} event jQuery Event object
  411. */
  412. keyup: function (editor, event) {
  413. console_log('event:keyup');
  414. },
  415. /**
  416. * @param {jQuery} editor EmojioneArea input
  417. * @param {Event} event jQuery Event object
  418. */
  419. keydown: function (editor, event) {
  420. console_log('event:keydown');
  421. },
  422. /**
  423. * @param {jQuery} editor EmojioneArea input
  424. * @param {Event} event jQuery Event object
  425. */
  426. keypress: function (editor, event) {
  427. console_log('event:keypress');
  428. },
  429. /**
  430. * @param {jQuery} editor EmojioneArea input
  431. * @param {Event} event jQuery Event object
  432. */
  433. paste: function (editor, event) {
  434. console_log('event:paste');
  435. },
  436. /**
  437. * @param {jQuery} editor EmojioneArea input
  438. * @param {Event} event jQuery Event object
  439. */
  440. change: function (editor, event) {
  441. console_log('event:change');
  442. },
  443. /**
  444. * @param {jQuery} filter EmojioneArea filter
  445. * @param {Event} event jQuery Event object
  446. */
  447. filter_click: function (filter, event) {
  448. console_log('event:filter.click, filter=' + filter.data("filter"));
  449. },
  450. /**
  451. * @param {jQuery} button EmojioneArea emoji button
  452. * @param {Event} event jQuery Event object
  453. */
  454. emojibtn_click: function (button, event) {
  455. console_log('event:emojibtn.click, emoji=' + button.children().data("name"));
  456. },
  457. /**
  458. * @param {jQuery} button EmojioneArea left arrow button
  459. * @param {Event} event jQuery Event object
  460. */
  461. arrowLeft_click: function (button, event) {
  462. console_log('event:arrowLeft.click');
  463. },
  464. /**
  465. * @param {jQuery} button EmojioneArea right arrow button
  466. * @param {Event} event jQuery Event object
  467. */
  468. arrowRight_click: function (button, event) {
  469. console_log('event:arrowRight.click');
  470. }
  471. }
  472. });
  473. });
  474. </script>
  475. <h2 id="examples"><a href="#examples">Examples</a></h2>
  476. <p>Auto hide filters</p>
  477. <textarea id="example1">
  478. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  479. </textarea>
  480. <script type="text/javascript">
  481. $(document).ready(function() {
  482. $("#example1").emojioneArea({
  483. autoHideFilters: true
  484. });
  485. });
  486. </script>
  487. <p></p>
  488. <pre class="prettyprint linenums">
  489. &lt;textarea id=&quot;example1&quot;&gt;
  490. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  491. &lt;/textarea&gt;
  492. &lt;script type=&quot;text/javascript&quot;&gt;
  493. $(document).ready(function() {
  494. $(&quot;#example1&quot;).emojioneArea({
  495. autoHideFilters: true
  496. });
  497. });
  498. &lt;/script&gt;
  499. </pre>
  500. <p></p>
  501. <p>Using <code>div</code></p>
  502. <div id="example2">Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.</div>
  503. <script type="text/javascript">
  504. $(document).ready(function() {
  505. $("#example2").emojioneArea();
  506. });
  507. </script>
  508. <p></p>
  509. <pre class="prettyprint linenums">
  510. &lt;div id=&quot;example2&quot;&gt;
  511. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  512. &lt;/div&gt;
  513. &lt;script type=&quot;text/javascript&quot;&gt;
  514. $(document).ready(function() {
  515. $(&quot;#example2&quot;).emojioneArea();
  516. });
  517. &lt;/script&gt;
  518. </pre>
  519. <p></p>
  520. <p>Using <code>input</code></p>
  521. <input id="example3" value="Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.">
  522. <script type="text/javascript">
  523. $(document).ready(function() {
  524. $("#example3").emojioneArea();
  525. });
  526. </script>
  527. <p></p>
  528. <pre class="prettyprint linenums:1">
  529. &lt;input id=&quot;example3&quot; value=&quot;Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.&quot;&gt;
  530. &lt;script type=&quot;text/javascript&quot;&gt;
  531. $(document).ready(function() {
  532. $(&quot;#example3&quot;).emojioneArea();
  533. });
  534. &lt;/script&gt;
  535. </pre>
  536. <p>Images instead of the sprite</p>
  537. <textarea id="example4">
  538. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  539. </textarea>
  540. <script type="text/javascript">
  541. $(document).ready(function() {
  542. $("#example4").emojioneArea({
  543. useSprite: false
  544. });
  545. });
  546. </script>
  547. <p></p>
  548. <pre class="prettyprint linenums">
  549. &lt;textarea id=&quot;example4&quot;&gt;
  550. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  551. &lt;/textarea&gt;
  552. &lt;script type=&quot;text/javascript&quot;&gt;
  553. $(document).ready(function() {
  554. $(&quot;#example3&quot;).emojioneArea({
  555. useSprite: false
  556. });
  557. });
  558. &lt;/script&gt;
  559. </pre>
  560. <p>Customize layout</p>
  561. <textarea id="example5">
  562. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  563. </textarea>
  564. <script type="text/javascript">
  565. $(document).ready(function() {
  566. $("#example5").emojioneArea({
  567. template: "<filters/><tabs/><editor/>"
  568. });
  569. });
  570. </script>
  571. <p></p>
  572. <pre class="prettyprint linenums">
  573. &lt;textarea id=&quot;example5&quot;&gt;
  574. Lorem ipsum dolor 😍 sit amet, consectetur 👻 adipiscing elit, 🖐 sed do eiusmod tempor ☔ incididunt ut labore et dolore magna aliqua 🐬.
  575. &lt;/textarea&gt;
  576. &lt;script type=&quot;text/javascript&quot;&gt;
  577. $(document).ready(function() {
  578. $(&quot;#example5&quot;).emojioneArea({
  579. template: &quot;&lt;filters/&gt;&lt;tabs/&gt;&lt;editor/&gt;&quot;
  580. });
  581. });
  582. &lt;/script&gt;
  583. </pre>
  584. <p></p>
  585. <h2 id="requirements"><a href="#requirements">Requirements</a></h2>
  586. <ul>
  587. <li><a href="https://jquery.com/">jQuery</a> &gt;= 1.8.2</li>
  588. <li><a href="https://github.com/Ranks/emojione">EmojiOne</a> &gt;= 1.5.0</li>
  589. </ul>
  590. <h2 id="license"><a href="#license">License</a></h2>
  591. <p>EmojiOneArea is released under the MIT license.</p>
  592. <footer class="site-footer">
  593. <span class="site-footer-owner"><a href="https://github.com/mervick/emojionearea">EmojiOneArea</a> is maintained by <a href="https://github.com/mervick">mervick</a>.</span>
  594. <span class="site-footer-credits">This page was generated by <a href="https://pages.github.com">GitHub Pages</a>.</span>
  595. </footer>
  596. </section>
  597. </body>
  598. </html>