Custom Login - Version 4.0.8

Version Description

Download this release

Release Info

Developer austyfrosty
Plugin Icon 128x128 Custom Login
Version 4.0.8
Comparing to
See all releases

Code changes from version 3.2.15 to 4.0.8

Files changed (57) hide show
  1. README.md +97 -198
  2. composer.json +68 -1
  3. config/extensions.php +112 -0
  4. config/import-export.php +52 -0
  5. config/settings.php +549 -0
  6. css/admin.css +0 -442
  7. css/animate.css +0 -3623
  8. css/animate.min.css +0 -11
  9. css/chosen/chosen-sprite.png +0 -0
  10. css/chosen/chosen-sprite@2x.png +0 -0
  11. css/chosen/chosen.css +0 -496
  12. css/chosen/chosen.min.css +0 -11
  13. css/login/login-rtl.css +0 -260
  14. css/login/login.css +0 -270
  15. custom-login.php +82 -351
  16. extensions.json +5 -1
  17. functions.php +127 -0
  18. includes/admin/dashboard.php +0 -299
  19. includes/admin/import-export.php +0 -296
  20. includes/admin/plugins.php +0 -53
  21. includes/admin/tracking.php +0 -284
  22. includes/class-cl-common.php +0 -236
  23. includes/class-cl-cron.php +0 -89
  24. includes/class-cl-extensions.php +0 -282
  25. includes/class-cl-scripts-styles.php +0 -141
  26. includes/class-cl-settings-api.php +0 -954
  27. includes/class-cl-settings-upgrades.php +0 -426
  28. includes/class-cl-templates.php +0 -112
  29. includes/class-cl-wp-login.php +0 -262
  30. includes/default-settings.php +0 -508
  31. includes/functions.php +0 -33
  32. includes/libraries/edd-remote-install-client/EDD_Remote_Install_Client.php +0 -394
  33. includes/libraries/edd-remote-install-client/css/edd-remote-install-admin.css +0 -210
  34. includes/libraries/edd-remote-install-client/js/edd-remote-install-admin.js +0 -364
  35. js/ace/src-min-noconflict/ace.js +0 -11
  36. js/ace/src-min-noconflict/ext-beautify.js +0 -5
  37. js/ace/src-min-noconflict/ext-chromevox.js +0 -5
  38. js/ace/src-min-noconflict/ext-elastic_tabstops_lite.js +0 -5
  39. js/ace/src-min-noconflict/ext-emmet.js +0 -5
  40. js/ace/src-min-noconflict/ext-error_marker.js +0 -5
  41. js/ace/src-min-noconflict/ext-keybinding_menu.js +0 -5
  42. js/ace/src-min-noconflict/ext-language_tools.js +0 -5
  43. js/ace/src-min-noconflict/ext-linking.js +0 -5
  44. js/ace/src-min-noconflict/ext-modelist.js +0 -5
  45. js/ace/src-min-noconflict/ext-old_ie.js +0 -5
  46. js/ace/src-min-noconflict/ext-searchbox.js +0 -5
  47. js/ace/src-min-noconflict/ext-settings_menu.js +0 -5
  48. js/ace/src-min-noconflict/ext-spellcheck.js +0 -5
  49. js/ace/src-min-noconflict/ext-split.js +0 -5
  50. js/ace/src-min-noconflict/ext-static_highlight.js +0 -5
  51. js/ace/src-min-noconflict/ext-statusbar.js +0 -5
  52. js/ace/src-min-noconflict/ext-textarea.js +0 -5
  53. js/ace/src-min-noconflict/ext-themelist.js +0 -5
  54. js/ace/src-min-noconflict/ext-whitespace.js +0 -5
  55. js/ace/src-min-noconflict/keybinding-emacs.js +0 -1
  56. js/ace/src-min-noconflict/keybinding-vim.js +0 -1
  57. js/ace/src-min-noconflict/mode-css.js +0 -1
README.md CHANGED
@@ -1,55 +1,69 @@
1
  # Custom Login #
2
 
3
- [![WordPress plugin](https://img.shields.io/wordpress/plugin/dt/custom-login.svg?style=flat)](https://wordpress.org/plugins/custom-login/)
4
- [![WordPress plugin](https://img.shields.io/wordpress/plugin/v/custom-login.svg?style=flat)](https://wordpress.org/plugins/custom-login/)
5
- [![WordPress Plugin: Required WP Version](https://img.shields.io/wordpress/plugin/wp-version/custom-login)]()
6
- [![WordPress](https://img.shields.io/wordpress/v/custom-login.svg?style=flat)]()
7
- [![WordPress Plugin Required PHP Version](https://img.shields.io/wordpress/plugin/required-php/custom-login)]()
 
8
  [![License](https://img.shields.io/badge/license-GPL--2.0%2B-red.svg)](https://github.com/thefrosty/custom-login/blob/master/license.txt)
9
 
10
- **Contributors:** [austyfrosty](https://profiles.wordpress.org/austyfrosty), [frostymedia](https://profiles.wordpress.org/frostymedia)
 
11
  **Donate link:** [PayPal](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7431290)
12
  **Tags:** admin, branding, customization, custom login, login, logo, error, login error, custom login pro
13
- **Requires at least:** 4.9
14
- **Tested up to:** 5.9
15
- **Requires PHP**: 5.6
16
  **Stable tag:** trunk
17
  **License:** GPLv2 or later
18
- **License URI:** http://www.gnu.org/licenses/gpl-2.0.html
19
 
20
  Custom Login allows you to easily customize your admin login page, works great for client sites!
21
 
22
  ## Description ##
23
 
24
- Custom Login 2.0 was 140% faster than version 1.0, and version 3.0 is now even better! *Minimum WordPress version is 4.9*
25
 
26
  For more information visit the official [Custom Login](https://frosty.media/plugins/custom-login/) page.
27
 
28
  > <strong>Support</strong><br>
29
- > [Austin](http://austin.passy.co) and the [Frosty Media](https://frosty.media/) team will always try our best to support the Custom Login plugin on the WordPress.org forum, but please note that we can not guarantee a response in a timely manner. If you have an issue we would appriciate you using GitHub or purchasing priority support on our site.
 
 
30
  >
31
- > Any extensions purchased on [Frosty Media](https://frosty.media/) (not hosted on WordPress.org) will not be supported on the WordPress.org forum. You can always browse our *small* but growing [documentation](https://frosty.media/docs) for further assistance. You need a valid license key to make support submissions *on our site*. We thank you in advance.
 
 
32
 
33
  > <strong>Bug Reports</strong><br>
34
- > Bug reports for Custom Login are [welcomed on GitHub](https://github.com/thefrosty/custom-login).
35
 
36
  ### Video ###
37
 
38
- [![IMAGE ALT TEXT HERE](https://img.youtube.com/vi/hZkc-t36xYQ/0.jpg)](https://www.youtube.com/watch?v=hZkc-t36xYQ)
39
 
40
  ### Extensions ###
41
 
42
- There are currently 7 premium extensions available, with more coming (suggestions welcome - and *will be offered for free to said user*).
 
43
 
44
  **Extensions available now**
45
 
46
- * [Stealth Login](https://frosty.media/plugins/custom-login-stealth-login/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Stealth Login") - obscure your login URL.
47
- * [Page Template](https://frosty.media/plugins/custom-login-page-template/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Page Template") - add a login form to any WordPress page.
48
- * [Login Redirects](https://frosty.media/plugins/custom-login-redirects/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Redirects") - Manage login redirects.
49
- * [No Password](https://frosty.media/plugins/custom-login-no-password-login/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login No Password logins") - allow users to login without a password.
50
- * [Style Pack #1](https://frosty.media/plugins/custom-login-style-pack-1?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Style Pack #1") - four pre-designed login styles.
51
- * [Style Pack #2](https://frosty.media/plugins/custom-login-style-pack-2?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Style Pack #2") - four pre-designed fun login styles.
52
- * [Style Pack #3](https://frosty.media/plugins/custom-login-style-pack-3?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Style Pack #3") - four pre-designed holiday login styles.
 
 
 
 
 
 
 
53
 
54
  **Extensions in development/extension ideas**
55
 
@@ -58,23 +72,27 @@ There are currently 7 premium extensions available, with more coming (suggestion
58
  * "Super User" only access for client sites.
59
  * **Added in core as of version 3.0** Remove default WordPress login CSS.
60
  * Submit button styles!
61
- * **Added as of version 3.2** Custom Login pre made settings templates *AKA* [Style Packs](https://frosty.media/plugin/tag/style-pack/).
 
62
 
63
  ### More info ###
64
 
65
- Activate the plugin and customize your WordPress login screen. It's as easy as modifying a few settings, there is no need to understand CSS at all. Custom Login even has a HTML, CSS &amp; jQuery textarea for more advanced customizations.
 
66
 
67
  1. Works great for client site installs.
68
- 2. Read more about [Custom Login 3.1](https://frosty.media/2015/custom-login-v3-1-released/)
69
- 2. Read more about [Custom Login 2.0](http://wp.me/pzgsJ-HY)
 
70
 
71
- **For those looking to show off your login screen, check out the [Flickr group](http://flickr.com/groups/custom-login/)! Share you designs with the community!**
 
72
 
73
  ### links ###
74
 
75
  * Premium Plugins: [https://frosty.media/plugins](https://frosty.media/plugins/ "Premium WordPress Plugins by Frosty")
76
- * Austins Blog: [https:/austin.passy.co/](http://austin.passy.co/ "Austin Passy's blog")
77
- * Austin on Twitter: @[TheFrosty](https:/twitter.com/TheFrosty "Austin TheFrosty' Passy on Twitter")
78
  * Frosty Media on Twitter: @[Frosty_Media](https:/twitter.com/Frosty_Media "Frosty Media on Twitter")
79
  * **Development welcomed on [GitHub](https://github.com/thefrosty/custom-login)**
80
 
@@ -95,230 +113,111 @@ Follow the steps below to install the plugin.
95
  ## Frequently Asked Questions ##
96
 
97
  ### What are extensions? ###
98
- They are additional plugins that add/extend functionality to the Custom Login plugin. You can find all Custom Login extensions on [Frosty.Media](http://frosty.media).
99
 
100
- ### My new settings aren't showing up ###
101
- This plugin caches all settings in a transient, try clicking the new 'Update stylesheet' button to delete and refresh the cache. *This will apply to versions < 3.0*.
102
 
103
  ### Is there a PRO version? ###
104
- Well, yes and no. Since version 3.0 of Custom Login the [PRO](http://frosty.media/plugins/custom-login-pro/) version is a completely different plugin. Instead of settings to manage your login design there is a new post type where you can create unlimited "designs" and activate each one as needed. Since version 3.0 all Custom Login extensions no longer work with Custom Login Pro, but will be merged into it in the future.
105
 
106
- ### Why create this plugin? ###
107
- I created this plugin to allow for custom login of any WordPress login screen. See working example on: [Frosty.Media/login](http://frosty.media/wp-login.php).
108
 
109
  ### Where can I upload and share my cool login screen? ###
 
110
  Check out the [Flickr group](http://flickr.com/groups/custom-login/)! Upload and add it to our pool!
111
 
112
  ### I think I want to uninstall ###
 
113
  Just deactivate it. Sad panda is sad.
114
 
115
  ## Screenshots ##
116
 
117
  Custom Login showcase on the [Flickr group](http://flickr.com/groups/custom-login/).
118
 
119
- ###1. Custom Login v3 Design Settings part 1.
 
120
  ###
 
121
  ![Custom Login v3 Design Settings part 1.
122
  ](https://ps.w.org/custom-login/assets/screenshot-1.png)
123
 
 
124
 
125
- ###2. Custom Login v3 Design Settings part 2.
126
  ###
 
127
  ![Custom Login v3 Design Settings part 2.
128
  ](https://ps.w.org/custom-login/assets/screenshot-2.png)
129
 
 
130
 
131
- ###3. Custom Login v3 General Settings.
132
  ###
 
133
  ![Custom Login v3 General Settings.
134
  ](https://ps.w.org/custom-login/assets/screenshot-3.png)
135
 
 
136
 
137
- ###4. Custom Login Extensions Installer (an active license key is required).
138
  ###
 
139
  ![Custom Login Extensions Installer (an active license key is required).
140
  ](https://ps.w.org/custom-login/assets/screenshot-4.png)
141
 
142
-
143
  ## Changelog ##
144
 
145
- ### Version 3.2.15 (2022/03/11) ###
146
-
147
- * Fix settings API Settings: Uncaught Error: Call to undefined method stdClass::get_permalink() (#49)
148
-
149
- ### Version 3.2.14 (2022/03/10) ###
150
-
151
- * Fix settings widget feed for available extensions. Changes from RSS to REST.
152
- * Add auto deploy to WordPress.org GitHub action.
153
-
154
- ### Version 3.2.13 (2022/01/06) ###
155
-
156
- * Change custom CSS settings sanitizer in admin to allow for proper HTML CSS attributes like `>`.
157
-
158
- ### Version 3.2.12 (2021/11/07) ###
159
-
160
- * Change dashboard from RSS feed to REST API endpoint.
161
- * Fix condition for dashboard widget to use `is_blog_admin`.
162
-
163
- ### Version 3.2.11 (2020/12/07) ###
164
- * PHP 8 compatibility fixes.
165
- * Tested on WordPress 5.6
166
-
167
- ### Version 3.2.10 (2020/08/14) ###
168
- * Tested up to WordPress 5.5
169
- * Fix toggle on/off on settings page, incorrect check in AJAX for new installs.
170
- * Enable on activation hook fixed.
171
- * Remove ace.js theme call to non existing theme.
172
-
173
- ### Version 3.2.9 (2019/05/07) ###
174
- * Tested up to WordPress 5.2.
175
- * Update deprecated login text filter in WordPress 5.2.
176
- * Update animate.css to version 3.7.0.
177
- * Update chosen.js to 1.8.7.
178
- * Update jQuery Sticky to 1.0.4.
179
- * Fix spelling error in admin JS on typeof check for ACE JS.
180
-
181
- ### Version 3.2.8 (12/11/17) ###
182
-
183
- * Update notifications URL to current correct location for admin settings page.
184
 
185
- ### Version 3.2.7 (11/13/17) ###
186
 
187
- * Fix duplicate CSS output in head bug.
188
- * Fix empty link URL and title on wp login page when on multisite.
189
 
190
- ### Version 3.2.6 (11/10/17) ###
 
 
 
 
191
 
192
- * Check compatibility with WordPress 4.9.
193
- * Update Settings API to fix `Undefined index: active` message.
194
 
195
- ### Version 3.2.5 (04/13/16) ###
 
 
 
196
 
197
- * WordPress 4.5 compatible update (moves Custom Login css after WordPress' login style sheet).
198
- * Fix issue where toggling the 'active' checkbox in the header doesn't activate or de-activate the plugin settings (updates via AJAX now).
199
 
200
- ### Version 3.2.4 (09/16/15) ###
 
201
 
202
- * Fix PHP Fatal error.
203
- ** PHP Fatal error: Call to a member function get_permalink() on a non-object in /includes/admin/dashboard.php:114
204
 
205
- ### Version 3.2.2 (05/04/15) ###
 
206
 
207
- * May the fourth be with you.
208
- * Cleaned up dashboard JS errors.
209
 
210
- ### Version 3.2.2 (04/29/15) ###
 
 
211
 
212
- * Update version number.
213
- * Fix upgrade notice showing when not needed.
214
- * Add class 'notice' and 'is-dismissible' to notice.
215
- * Cleanup admin dashboard empty ob_get_clean() notice.
216
 
217
- ### Version 3.2.1 (04/20/15) ###
218
 
219
- * Fix: XSS security flaw.
220
- * Fix: Settings page not showing. (Fixes Issue: [#6](https://github.com/thefrosty/custom-login/pull/6) /ht @[DrewAPicture](https://github.com/DrewAPicture).
221
 
222
- ### Version 3.2 (02/09/15) ###
223
 
224
- * Message: Celebrate 500,000 downloads. Visit the settings page or [this post](https://frosty.media/?p=26056) to get any extension for free! *Restrictions may apply.
225
- * Notice: Introduce Custom Login [Style Pack #1](https://frosty.media/plugins/custom-login-style-pack-1)
226
- * Fix: Possible headers_sent() error in some installations [forum](https://wordpress.org/support/topic/update-php-errors-dashboard-errors?replies=2).
227
- * Fix: Setting update script might uncheck (turn off) the activate switch.
228
- * Fix: CSS `#login form` box shadow not accepting opacity settings.
229
- * Update: Default 'activate' setting to 'on'.
230
- * Update: "Save Changes" submit button to "Save {Tab Title}".
231
- * Update: Allow Custom (CSS/HTML/JS) textareas to expand up to 30 lines.
232
- * Update: admin.css
233
- * Update: admin.js
234
- * Add: animate.css (licensed under MIT).
235
- * Add: Global 'active' toggle switch.
236
 
237
- ### Version 3.1 (01/20/15) ###
 
 
238
 
239
- * Update: Disable auth cookie expiration function.
240
- * Update: All prefixed 'cl_' to 'custom_login_'.
241
- * Update: Spelling error 'sanitize'.
242
- * Update: login.css uses core stylesheet to avoid possible conflicts with checkboxes and browser support.
243
- * Tweak: Speed improvements.
244
- * Add: CL_Common::is_settings_page().
245
- * Add: Dashboard widget (off be default).
246
-
247
- ### Version 3.0.8 (01/14/15) ###
248
-
249
- * Add: Auth timout setting when remember me is checked and not.
250
- * Add: filter to wp_remote_get timeout. Use: `cl_wp_remote_get_timeout` to return (int) value, defaults to 15.
251
- * Update: `auth_cookie_expiration` function.
252
- * Update: Removed `post_password_expires` setting in favor of `auth_timeout` &amp; `auth_timeout_remember`.
253
- * Fix: Possible white screen issue, for users who updated to 3.0.7 before a file was uploaded. (version bump).
254
-
255
- ### Version 3.0.7 (01/13/15) ###
256
-
257
- * Update: ace.js to build `20.12.14`.
258
- * Update: admin.css.
259
- * Update: Extensions HTML and settings page location.
260
- * Update: Sanitize the `auth_cookie_expiration` setting with a positive integer.
261
- * Tweak: Remove false positive files from malware scanners; ace editor php.js [forum](https://wordpress.org/support/topic/wordfence-alerta?).
262
- * Tweak: Make sure `auth_cookie_expiration` is greater than 0.
263
-
264
- ### Version 3.0.6 (01/13/15) ###
265
-
266
- * Bug: Misspelled variable returned on `auth_cookie_expiration` caused instant user logout.
267
-
268
- ### Version 3.0.5 (01/13/15) ###
269
-
270
- * Add: Update uninstall.php with all options to delete.
271
- * Add: Disable lost password reset function option.
272
- * Update: Settings prefix with global definition.
273
- * Update: Add missing auth expiration function for setting.
274
- * Fix: Hide tracking notice globally if admin notices are turned off.
275
- * Tweak: Update the hide_wp_logo description since Custom Login removes the WP logo by default.
276
- * Tweak: Better output of update notification on settings page.
277
- * Tweak: Update input fields that are integers to a 'number' input type.
278
- * Tweak: Update readme dates to 2015. :)
279
-
280
- ### Version 3.0.4 (01/12/15) ###
281
-
282
- * Tweak: Add manual update link on settings page if new settings are empty and old settings exist.
283
- * Fix: Make sure tracking is set to "on" before sending.
284
-
285
- ### Version 3.0.3 (01/12/15) ###
286
-
287
- * Fix: Add missing "Remove WP Logo" setting.
288
- * Fix: When "activate" isn't checked disable settings output.
289
- * Fix: foreach error. When `get_editable_roles` fails to return an array. [forum](https://wordpress.org/support/topic/invalid-argument-supplied-for-foreach-error-line-in-wp-dashboard?replies=2#post-6427631)
290
- * Fix: On Logo "insert" getting called on background image insert.
291
- * Tweak: Update chosen JS to version 1.3.0.
292
-
293
- ### Version 3.0.2 (01/12/15) ###
294
-
295
- * Fix: Logo background size width &amp; height settings not transfering over in upgrade process.
296
- * Fix: Checking "Remove lost password text" removes the text instead of the other way around. [forum](https://wordpress.org/support/topic/lost-your-password-1)
297
-
298
- ### Version 3.0.1 (01/11/15) ###
299
-
300
- * New: Add force width option to force width on h1 logo wrapper.
301
- * Bug: Change sanitization of all integer fields to 'int' vs 'absint' to allow empty or no value.
302
- * Bug: Remove is_int function on Logo width and height style output.
303
- * Tweak: On Logo upload and "insert" update the width and height input settings fields for logo with the image size.
304
- * Tweak: Change CSS rule(s) from `#login h1 a` to `.login h1 a`.
305
-
306
- ### Version 3.0.0 (12/01/14) ###
307
-
308
- _REQUIRES WordPress 3.9 or later_
309
 
310
- * New: Complete rewrite.
311
- * New: Settings page UI update, now matches your WordPress admin color scheme.
312
- * New: Extensions installer moved to sparate settings page (hidden).
313
- * New: Removed version [2.x changelog](http://plugins.svn.wordpress.org/custom-login/tags/2.4/readme.txt).
314
 
315
  ## Upgrade Notice ##
316
 
317
- ### 3.2 ###
318
- Celebrate 500,000 downloads w/ a FREE extension! Update to version 3.2 for more info.
319
-
320
- ### 3.0.6 ###
321
- Fixes unable to login to admin site.
322
 
323
- ### 3.0.5 ###
324
- Complete rewrite of Custom Login, be sure to run the update script to keep your old settings.
1
  # Custom Login #
2
 
3
+ [![WordPress plugin](https://img.shields.io/wordpress/plugin/dt/custom-login.svg?style=flat)](https://wordpress.org/plugins/custom-login/)
4
+ [![WordPress plugin](https://img.shields.io/wordpress/plugin/v/custom-login.svg?style=flat)](https://wordpress.org/plugins/custom-login/)
5
+ [![WordPress Plugin: Required WP Version](https://img.shields.io/wordpress/plugin/wp-version/custom-login)]()
6
+ [![WordPress](https://img.shields.io/wordpress/v/custom-login.svg?style=flat)]()
7
+ [![WordPress Plugin Required PHP Version](https://img.shields.io/wordpress/plugin/required-php/custom-login)]()
8
+ [![codecov](https://codecov.io/gh/thefrosty/custom-login/branch/master/graph/badge.svg?token=3R6LKD6RBK)](https://codecov.io/gh/thefrosty/custom-login)
9
  [![License](https://img.shields.io/badge/license-GPL--2.0%2B-red.svg)](https://github.com/thefrosty/custom-login/blob/master/license.txt)
10
 
11
+ **Contributors:** [austyfrosty](https://profiles.wordpress.org/austyfrosty)
12
+ , [frostymedia](https://profiles.wordpress.org/frostymedia)
13
  **Donate link:** [PayPal](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7431290)
14
  **Tags:** admin, branding, customization, custom login, login, logo, error, login error, custom login pro
15
+ **Requires at least:** 5.8
16
+ **Tested up to:** 6.0.1
17
+ **Requires PHP**: 7.4
18
  **Stable tag:** trunk
19
  **License:** GPLv2 or later
20
+ **License URI:** http://www.gnu.org/licenses/gpl-2.0.html
21
 
22
  Custom Login allows you to easily customize your admin login page, works great for client sites!
23
 
24
  ## Description ##
25
 
26
+ Custom Login 2.0 was 140% faster than version 1.0, and version 4.0 is now even better!
27
 
28
  For more information visit the official [Custom Login](https://frosty.media/plugins/custom-login/) page.
29
 
30
  > <strong>Support</strong><br>
31
+ > [Austin](http://austin.passy.co) and the [Frosty Media](https://frosty.media/) team will always try our best to
32
+ > support the Custom Login plugin on the WordPress.org forum, but please note that we can not guarantee a response in a
33
+ > timely manner. If you have an issue we would appriciate you using GitHub or purchasing priority support on our site.
34
  >
35
+ > Any extensions purchased on [Frosty Media](https://frosty.media/) (not hosted on WordPress.org) will not be supported
36
+ > on the WordPress.org forum. You can always browse our *small* but growing [documentation](https://frosty.media/docs) for
37
+ > further assistance. You need a valid license key to make support submissions *on our site*. We thank you in advance.
38
 
39
  > <strong>Bug Reports</strong><br>
40
+ > Bug reports for Custom Login are [welcomed on GitHub](https://github.com/thefrosty/custom-login).
41
 
42
  ### Video ###
43
 
44
+ [![Custom Login v3.0](https://img.youtube.com/vi/hZkc-t36xYQ/0.jpg)](https://www.youtube.com/watch?v=hZkc-t36xYQ)
45
 
46
  ### Extensions ###
47
 
48
+ There are currently 7 premium extensions available, with more coming (suggestions welcome - and *will be offered for
49
+ free to said user*).
50
 
51
  **Extensions available now**
52
 
53
+ * [Stealth Login](https://frosty.media/plugins/custom-login-stealth-login/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Stealth Login")
54
+ - obscure your login URL.
55
+ * [Page Template](https://frosty.media/plugins/custom-login-page-template/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Page Template")
56
+ - add a login form to any WordPress page.
57
+ * [Login Redirects](https://frosty.media/plugins/custom-login-redirects/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Redirects")
58
+ - Manage login redirects.
59
+ * [No Password](https://frosty.media/plugins/custom-login-no-password-login/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login No Password logins")
60
+ - allow users to login without a password.
61
+ * [Style Pack #1](https://frosty.media/plugins/custom-login-style-pack-1?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Style Pack #1") ⭐️
62
+ - four pre-designed login styles.
63
+ * [Style Pack #2](https://frosty.media/plugins/custom-login-style-pack-2?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Style Pack #2") ⭐️
64
+ - four pre-designed fun login styles.
65
+ * [Style Pack #3](https://frosty.media/plugins/custom-login-style-pack-3?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=readme.txt "Custom Login Style Pack #3") ⭐️
66
+ - four pre-designed holiday login styles.
67
 
68
  **Extensions in development/extension ideas**
69
 
72
  * "Super User" only access for client sites.
73
  * **Added in core as of version 3.0** Remove default WordPress login CSS.
74
  * Submit button styles!
75
+ * **Added as of version 3.2** Custom Login pre-made settings templates *
76
+ AKA* [Style Packs](https://frosty.media/plugin/tag/style-pack/).
77
 
78
  ### More info ###
79
 
80
+ Activate the plugin and customize your WordPress login screen. It's as easy as modifying a few settings, there is no
81
+ need to understand CSS at all. Custom Login even has a HTML, CSS &amp; jQuery textarea for more advanced customizations.
82
 
83
  1. Works great for client site installs.
84
+ 2. Read more about [Custom Login 4.0](https://frosty.media/2022/custom-login-4-0-x-released/)
85
+ 3. Read more about [Custom Login 3.1](https://frosty.media/2015/custom-login-v3-1-released/)
86
+ 4. Read more about [Custom Login 2.0](http://wp.me/pzgsJ-HY)
87
 
88
+ **For those looking to show off your login screen, check out the [Flickr group](http://flickr.com/groups/custom-login/)!
89
+ Share you designs with the community!**
90
 
91
  ### links ###
92
 
93
  * Premium Plugins: [https://frosty.media/plugins](https://frosty.media/plugins/ "Premium WordPress Plugins by Frosty")
94
+ * Austins Blog: [https:/austin.passy.co/](http://austin.passy.co/ "Austin's blog")
95
+ * Austin on Twitter: @[TheFrosty](https:/twitter.com/TheFrosty "Austin on Twitter")
96
  * Frosty Media on Twitter: @[Frosty_Media](https:/twitter.com/Frosty_Media "Frosty Media on Twitter")
97
  * **Development welcomed on [GitHub](https://github.com/thefrosty/custom-login)**
98
 
113
  ## Frequently Asked Questions ##
114
 
115
  ### What are extensions? ###
 
116
 
117
+ They are additional plugins that add/extend functionality to the Custom Login plugin. You can find all Custom Login
118
+ extensions on [Frosty.Media](http://frosty.media).
119
 
120
  ### Is there a PRO version? ###
 
121
 
122
+ Not anymore.
 
123
 
124
  ### Where can I upload and share my cool login screen? ###
125
+
126
  Check out the [Flickr group](http://flickr.com/groups/custom-login/)! Upload and add it to our pool!
127
 
128
  ### I think I want to uninstall ###
129
+
130
  Just deactivate it. Sad panda is sad.
131
 
132
  ## Screenshots ##
133
 
134
  Custom Login showcase on the [Flickr group](http://flickr.com/groups/custom-login/).
135
 
136
+ ### 1. Custom Login v3 Design Settings part 1.
137
+
138
  ###
139
+
140
  ![Custom Login v3 Design Settings part 1.
141
  ](https://ps.w.org/custom-login/assets/screenshot-1.png)
142
 
143
+ ### 2. Custom Login v3 Design Settings part 2.
144
 
 
145
  ###
146
+
147
  ![Custom Login v3 Design Settings part 2.
148
  ](https://ps.w.org/custom-login/assets/screenshot-2.png)
149
 
150
+ ### 3. Custom Login v3 General Settings.
151
 
 
152
  ###
153
+
154
  ![Custom Login v3 General Settings.
155
  ](https://ps.w.org/custom-login/assets/screenshot-3.png)
156
 
157
+ ### 4. Custom Login Extensions Installer (an active license key is required).
158
 
 
159
  ###
160
+
161
  ![Custom Login Extensions Installer (an active license key is required).
162
  ](https://ps.w.org/custom-login/assets/screenshot-4.png)
163
 
 
164
  ## Changelog ##
165
 
166
+ ### Version 4.0.8 (2022/08/11) ###
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
167
 
168
+ * Fix: Make sure WordPress' capabilities array keys are string values to avoid `shutdown` action fatal errors.
169
 
170
+ ### Version 4.0.7 (2022/08/09) ###
 
171
 
172
+ * Don't type cast the return value of removeLostPasswordText. [#75](https://github.com/thefrosty/custom-login/pull/75)
173
+ * Uncomment update option to resolve upgrade notice always showing. [#76](https://github.com/thefrosty/custom-login/pull/76)
174
+ * Don't show the tracking notice, when opt-in or opt-out has already been selected. [#77](https://github.com/thefrosty/custom-login/pull/77)
175
+ * Update WpSettingsApi, and use new condition checks for sidebar(s). [#78](https://github.com/thefrosty/custom-login/pull/78)
176
+ * Update missing autoload notice message. [#80](https://github.com/thefrosty/custom-login/pull/80)
177
 
178
+ ### Version 4.0.6 (2022/08/08) ###
 
179
 
180
+ * Fix: Resolve micro regression with `psr/container` issues.
181
+ * Fix: Resolve file (URL) fields breaking on save.
182
+ * Update WP Utilities to 2.8.
183
+ * Update WP Settings API to 3.6.
184
 
185
+ ### Version 4.0.5 (2022/08/06) ###
 
186
 
187
+ * Make sure autoloading is working before loading classes on plugin uninstall.
188
+ * Full Changelog: [4.0.4...4.0.5](https://github.com/thefrosty/custom-login/compare/4.0.4...4.0.5)
189
 
190
+ ### Version 4.0.4 (2022/08/05) ###
 
191
 
192
+ * Change PSR Container package to use version 1 instead of 2 to avoid WooCommerce errors; fixes [#65](https://github.com/thefrosty/custom-login/issues/65)
193
+ * Full Changelog: [4.0.3...4.0.4](https://github.com/thefrosty/custom-login/compare/4.0.3...4.0.4)
194
 
195
+ ### Version 4.0.3 (2022/08/04) ###
 
196
 
197
+ * Update both README's with correct "requires at least", "tested up to", and "requires PHP" header tags.
198
+ * Cleanup admin notice messages when "unable to activate" due to invalid PHP version or missing autoload.
199
+ * Full Changelog: [4.0.2...4.0.3](https://github.com/thefrosty/custom-login/compare/4.0.2...4.0.3)
200
 
201
+ ### Version 4.0.2 (2022/07/15) ###
 
 
 
202
 
203
+ * Don't show error message when not in admin.
204
 
205
+ ### Version 4.0.1 (2022/05/23) ###
 
206
 
207
+ * Version bump, including manually adding missing vendor directory (need to fix GitHub action).
208
 
209
+ ### Version 4.0.0 (2022/05/23) ###
 
 
 
 
 
 
 
 
 
 
 
210
 
211
+ * Complete rewrite.
212
+ * Required PHP >= 7.4.
213
+ * Full Changelog: [3.2.15...4.0.0](https://github.com/thefrosty/custom-login/compare/3.2.15...4.0.0)
214
 
215
+ ### Version 3.2.15 (2022/03/11) ###
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
216
 
217
+ * Fix settings API Settings: Uncaught Error: Call to undefined method stdClass::get_permalink() (#49)
 
 
 
218
 
219
  ## Upgrade Notice ##
220
 
221
+ ### 4.0.1 ###
 
 
 
 
222
 
223
+ Requires WordPress version >= 5.7 and PHP version >= 7.4.
 
composer.json CHANGED
@@ -12,10 +12,77 @@
12
  ],
13
  "config": {
14
  "allow-plugins": {
15
- "composer/installers": true
 
 
16
  },
17
  "optimize-autoloader": true,
18
  "preferred-install": "dist",
19
  "sort-packages": true
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
20
  }
21
  }
12
  ],
13
  "config": {
14
  "allow-plugins": {
15
+ "composer/installers": true,
16
+ "dealerdirect/phpcodesniffer-composer-installer": true,
17
+ "roots/wordpress-core-installer": true
18
  },
19
  "optimize-autoloader": true,
20
  "preferred-install": "dist",
21
  "sort-packages": true
22
+ },
23
+ "require": {
24
+ "php": "^7.4 || ^8.0",
25
+ "ext-json": "*",
26
+ "dwnload/wp-settings-api": "^3.6",
27
+ "opis/closure": "^3.6",
28
+ "pimple/pimple": "^3.5",
29
+ "psr/container": "1.0.0 as 2.0.0",
30
+ "thefrosty/wp-utilities": "^2.8"
31
+ },
32
+ "require-dev": {
33
+ "ext-simplexml": "*",
34
+ "dealerdirect/phpcodesniffer-composer-installer": "^0.7.0",
35
+ "phpcompatibility/php-compatibility": "^9.3",
36
+ "phpunit/php-code-coverage": "^9",
37
+ "phpunit/phpunit": "^9",
38
+ "roots/wordpress": "^6.0",
39
+ "squizlabs/php_codesniffer": "^3.2",
40
+ "wp-phpunit/wp-phpunit": "^6.0",
41
+ "yoast/phpunit-polyfills": "^1.0.2"
42
+ },
43
+ "autoload": {
44
+ "files": [
45
+ "functions.php"
46
+ ],
47
+ "psr-4": {
48
+ "TheFrosty\\CustomLogin\\": "src/"
49
+ }
50
+ },
51
+ "autoload-dev": {
52
+ "psr-4": {
53
+ "TheFrosty\\Tests\\CustomLogin\\": "tests/unit"
54
+ }
55
+ },
56
+ "scripts": {
57
+ "install-codestandards": [
58
+ "Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\Plugin::run"
59
+ ],
60
+ "phpcs": [
61
+ "bash ./vendor/thefrosty/wp-utilities/bin/phpcs.sh --test-version=7.4"
62
+ ],
63
+ "phpunit": [
64
+ "./vendor/bin/phpunit --colors --verbose --coverage-html ./tests/results && php ./tests/clover-results.php ./tests/clover.xml 01"
65
+ ],
66
+ "eslint": [
67
+ "npm run eslint"
68
+ ],
69
+ "tests": [
70
+ "@phpcs",
71
+ "@phpunit",
72
+ "@eslint"
73
+ ]
74
+ },
75
+ "archive": {
76
+ "exclude": [
77
+ ".gitignore",
78
+ "!node_modules/",
79
+ "plugin-build/",
80
+ "!vendor/",
81
+ "composer.lock",
82
+ "package-lock.json",
83
+ "phpcs-ruleset.xml",
84
+ "phpstan.neon.dist",
85
+ "phpunit.xml"
86
+ ]
87
  }
88
  }
config/extensions.php ADDED
@@ -0,0 +1,112 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php declare(strict_types=1);
2
+
3
+ return [
4
+ [
5
+ 'title' => 'Custom Login Stealth Login',
6
+ 'description' => 'Protect your wp-login.php page from brute force attacks.',
7
+ 'url' => 'https://frosty.media/plugins/custom-login-stealth-login/',
8
+ 'image' => 'https://i.imgur.com/mhuymPG.jpg',
9
+ 'download_id' => '108',
10
+ 'links' => [
11
+ [
12
+ 'description' => 'Personal',
13
+ 'download_id' => '108',
14
+ 'price_id' => '1',
15
+ 'price' => '$35',
16
+ ],
17
+ [
18
+ 'description' => 'Plus',
19
+ 'download_id' => '108',
20
+ 'price_id' => '2',
21
+ 'price' => '$95',
22
+ ],
23
+ [
24
+ 'description' => 'Professional',
25
+ 'download_id' => '108',
26
+ 'price_id' => '3',
27
+ 'price' => '$195',
28
+ ],
29
+ ],
30
+ ],
31
+ [
32
+ 'title' => 'Custom Login Page Template',
33
+ 'description' => 'Add a login form to any WordPress page.',
34
+ 'url' => 'https://frosty.media/plugins/custom-login-page-template/',
35
+ 'image' => 'https://i.imgur.com/A0rzS9q.jpg',
36
+ 'download_id' => '120',
37
+ 'links' => [
38
+ [
39
+ 'description' => 'Personal',
40
+ 'download_id' => '120',
41
+ 'price_id' => '1',
42
+ 'price' => '$35',
43
+ ],
44
+ [
45
+ 'description' => 'Plus',
46
+ 'download_id' => '120',
47
+ 'price_id' => '2',
48
+ 'price' => '$95',
49
+ ],
50
+ [
51
+ 'description' => 'Professional',
52
+ 'download_id' => '120',
53
+ 'price_id' => '3',
54
+ 'price' => '$195',
55
+ ],
56
+ ],
57
+ ],
58
+ [
59
+ 'title' => 'Custom Login Redirects',
60
+ 'description' => 'Manage redirects after logging in.',
61
+ 'url' => 'https://extendd.com/plugin/wordpress-login-redirects/',
62
+ 'image' => 'https://i.imgur.com/aNGoyAa.jpg',
63
+ 'download_id' => '124',
64
+ 'links' => [
65
+ [
66
+ 'description' => 'Personal',
67
+ 'download_id' => '124',
68
+ 'price_id' => '1',
69
+ 'price' => '$35',
70
+ ],
71
+ [
72
+ 'description' => 'Plus',
73
+ 'download_id' => '124',
74
+ 'price_id' => '2',
75
+ 'price' => '$95',
76
+ ],
77
+ [
78
+ 'description' => 'Professional',
79
+ 'download_id' => '124',
80
+ 'price_id' => '3',
81
+ 'price' => '$195',
82
+ ],
83
+ ],
84
+ ],
85
+ [
86
+ 'title' => 'Custom Login No Password',
87
+ 'description' => 'Allow users to login without a password.',
88
+ 'url' => 'https://frosty.media/plugins/custom-login-no-passowrd-login/',
89
+ 'image' => 'https://i.imgur.com/7SXIpi5.jpg',
90
+ 'download_id' => '128',
91
+ 'links' => [
92
+ [
93
+ 'description' => 'Personal',
94
+ 'download_id' => '128',
95
+ 'price_id' => '1',
96
+ 'price' => '$35',
97
+ ],
98
+ [
99
+ 'description' => 'Plus',
100
+ 'download_id' => '128',
101
+ 'price_id' => '2',
102
+ 'price' => '$95',
103
+ ],
104
+ [
105
+ 'description' => 'Professional',
106
+ 'download_id' => '128',
107
+ 'price_id' => '3',
108
+ 'price' => '$195',
109
+ ],
110
+ ],
111
+ ],
112
+ ];
config/import-export.php ADDED
@@ -0,0 +1,52 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php declare(strict_types=1);
2
+
3
+ use Dwnload\WpSettingsApi\Api\SettingField;
4
+ use Dwnload\WpSettingsApi\Api\SettingSection;
5
+ use Dwnload\WpSettingsApi\Settings\FieldTypes;
6
+ use TheFrosty\CustomLogin\Settings\Api\Factory;
7
+ use TheFrosty\CustomLogin\Settings\ImportExport;
8
+ use TheFrosty\CustomLogin\Settings\OptionKey;
9
+
10
+ return [
11
+ 'sections' => [
12
+ [
13
+ SettingSection::SECTION_ID => Factory::getSection(Factory::SECTION_IMPORT_EXPORT),
14
+ SettingSection::SECTION_TITLE => __('Import/Export', 'custom-login'),
15
+ ],
16
+ ],
17
+ 'fields' => [
18
+ Factory::getSection(Factory::SECTION_IMPORT_EXPORT) => [
19
+ [
20
+ SettingField::NAME => OptionKey::SETTINGS_IMPORT,
21
+ SettingField::LABEL => esc_html__(OptionKey::SETTINGS_IMPORT, 'custom-login'),
22
+ SettingField::DESC => '',
23
+ SettingField::DEFAULT => '',
24
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_TEXTAREA,
25
+ SettingField::SANITIZE => '__return_empty_string',
26
+ ],
27
+ [
28
+ SettingField::NAME => OptionKey::SETTINGS_EXPORT,
29
+ SettingField::LABEL => esc_html__('Export', 'custom-login'),
30
+ SettingField::DESC => sprintf(
31
+ __(
32
+ 'This textarea is always pre-filled with the current settings. Copy these settings for import at a later time, or <a href="%s">download</a> them.',
33
+ 'custom-login'
34
+ ),
35
+ esc_url(
36
+ wp_nonce_url(
37
+ add_query_arg(['action' => ImportExport::ACTION_DOWNLOAD_EXPORT], admin_url('admin.php')),
38
+ 'export',
39
+ ImportExport::NONCE
40
+ )
41
+ )
42
+ ),
43
+ SettingField::DEFAULT => $this->getEncodedSettings(),
44
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_TEXTAREA,
45
+ SettingField::ATTRIBUTES => [
46
+ 'readonly' => 'readonly',
47
+ ],
48
+ SettingField::SANITIZE => '__return_empty_string',
49
+ ],
50
+ ],
51
+ ],
52
+ ];
config/settings.php ADDED
@@ -0,0 +1,549 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php declare(strict_types=1);
2
+
3
+ use Dwnload\WpSettingsApi\Api\SettingField;
4
+ use Dwnload\WpSettingsApi\Api\SettingSection;
5
+ use Dwnload\WpSettingsApi\Settings\FieldTypes;
6
+ use TheFrosty\CustomLogin\Settings\Api\Factory;
7
+ use TheFrosty\CustomLogin\Settings\OptionKey;
8
+ use TheFrosty\CustomLogin\Settings\OptionValue;
9
+
10
+ return [
11
+ 'sections' => [
12
+ [
13
+ SettingSection::SECTION_ID => Factory::getSection(Factory::SECTION_DESIGN),
14
+ SettingSection::SECTION_TITLE => __('Design Settings', 'custom-login'),
15
+ ],
16
+ [
17
+ SettingSection::SECTION_ID => Factory::getSection(Factory::SECTION_GENERAL),
18
+ SettingSection::SECTION_TITLE => __('General Settings', 'custom-login'),
19
+ ],
20
+ ],
21
+ 'fields' => [
22
+ Factory::getSection(Factory::SECTION_DESIGN) => [
23
+ [
24
+ SettingField::NAME => OptionKey::BREAK_S,
25
+ SettingField::LABEL => sprintf(
26
+ '<h4>%s</h4>',
27
+ __('<abbr title="Hyper Text Markup Language">HTML</abbr>', 'custom-login')
28
+ ),
29
+ SettingField::DESC => '',
30
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
31
+ ],
32
+ [
33
+ SettingField::NAME => OptionKey::HTML_BACKGROUND_COLOR,
34
+ SettingField::LABEL => __('Background color', 'custom-login'),
35
+ SettingField::DESC => '',
36
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_COLOR_ALPHA,
37
+ SettingField::DEFAULT => '',
38
+ ],
39
+ [
40
+ SettingField::NAME => OptionKey::HTML_BACKGROUND_URL,
41
+ SettingField::LABEL => __('Background image', 'custom-login'),
42
+ SettingField::DESC => '',
43
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_FILE,
44
+ SettingField::DEFAULT => '',
45
+ SettingField::SIZE => 'medium',
46
+ SettingField::SANITIZE => '\sanitize_text_field',
47
+ ],
48
+ [
49
+ SettingField::NAME => OptionKey::HTML_BACKGROUND_POSITION,
50
+ SettingField::LABEL => __('Background position', 'custom-login'),
51
+ SettingField::DESC => sprintf(
52
+ '<a href="https://www.w3schools.com/cssref/pr_background-position.asp" target="_blank">%s</a>.',
53
+ __('html background position', 'custom-login')
54
+ ),
55
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
56
+ SettingField::OPTIONS => [
57
+ 'left top' => 'left top',
58
+ 'left center' => 'left center',
59
+ 'left bottom' => 'left bottom',
60
+ 'right top' => 'right top',
61
+ 'right center' => 'right center',
62
+ 'right bottom' => 'right bottom',
63
+ 'center top' => 'center top',
64
+ 'center center' => 'center center',
65
+ 'center bottom' => 'center bottom',
66
+ ],
67
+ ],
68
+ [
69
+ SettingField::NAME => OptionKey::HTML_BACKGROUND_REPEAT,
70
+ SettingField::LABEL => __('Background repeat', 'custom-login'),
71
+ SettingField::DESC => '',
72
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
73
+ SettingField::OPTIONS => [
74
+ 'no-repeat' => 'no-repeat',
75
+ 'repeat' => 'repeat',
76
+ 'repeat-x' => 'repeat-x',
77
+ 'repeat-y' => 'repeat-y',
78
+ ],
79
+ ],
80
+ [
81
+ SettingField::NAME => OptionKey::HTML_BACKGROUND_SIZE,
82
+ SettingField::LABEL => __('Background size', 'custom-login'),
83
+ SettingField::DESC => '',
84
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
85
+ SettingField::OPTIONS => [
86
+ 'none' => 'none',
87
+ 'cover' => 'cover',
88
+ 'contain' => 'contain',
89
+ 'flex' => 'flex',
90
+ ],
91
+ ],
92
+ [
93
+ SettingField::NAME => OptionKey::BREAK_S,
94
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Logo', 'custom-login')),
95
+ SettingField::DESC => '',
96
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
97
+ ],
98
+ [
99
+ SettingField::NAME => OptionKey::HIDE_WP_LOGO,
100
+ SettingField::LABEL => __('Hide the WP logo', 'custom-login'),
101
+ SettingField::DESC => __('This setting hides the h1 element.', 'custom-login'),
102
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
103
+ ],
104
+ [
105
+ SettingField::NAME => OptionKey::LOGO_BACKGROUND_URL,
106
+ SettingField::LABEL => __('Image', 'custom-login'),
107
+ SettingField::DESC => __(
108
+ 'I would suggest a max width of 320px, the default form width. You can widen the width (setting below).',
109
+ 'custom-login'
110
+ ),
111
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_FILE,
112
+ SettingField::DEFAULT => '',
113
+ SettingField::SIZE => 'medium',
114
+ SettingField::SANITIZE => '\sanitize_text_field',
115
+ ],
116
+ [
117
+ SettingField::NAME => OptionKey::LOGO_BACKGROUND_SIZE_WIDTH,
118
+ SettingField::LABEL => __('Image width', 'custom-login'),
119
+ SettingField::DESC => __(
120
+ 'Enter your desired image height (All not integers will be removed).',
121
+ 'custom-login'
122
+ ),
123
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_NUMBER,
124
+ SettingField::SIZE => 'small',
125
+ SettingField::DEFAULT => '',
126
+ SettingField::SANITIZE => 'int',
127
+ ],
128
+ [
129
+ SettingField::NAME => OptionKey::LOGO_BACKGROUND_SIZE_HEIGHT,
130
+ SettingField::LABEL => __('Image height', 'custom-login'),
131
+ SettingField::DESC => __('Enter your desired image height (All not integers will be removed).',
132
+ 'custom-login'),
133
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_NUMBER,
134
+ SettingField::SIZE => 'small',
135
+ SettingField::DEFAULT => '',
136
+ SettingField::SANITIZE => 'int',
137
+ ],
138
+ [
139
+ SettingField::NAME => OptionKey::LOGO_BACKGROUND_POSITION,
140
+ SettingField::LABEL => __('Background position', 'custom-login'),
141
+ SettingField::DESC => sprintf(
142
+ '<a href="https://www.w3schools.com/cssref/pr_background-position.asp" target="_blank">%s</a>',
143
+ __('html background position', 'custom-login')
144
+ ),
145
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
146
+ SettingField::OPTIONS => [
147
+ 'left top' => 'left top',
148
+ 'left center' => 'left center',
149
+ 'left bottom' => 'left bottom',
150
+ 'right top' => 'right top',
151
+ 'right center' => 'right center',
152
+ 'right bottom' => 'right bottom',
153
+ 'center top' => 'center top',
154
+ 'center center' => 'center center',
155
+ 'center bottom' => 'center bottom',
156
+ ],
157
+ ],
158
+ [
159
+ SettingField::NAME => OptionKey::LOGO_BACKGROUND_REPEAT,
160
+ SettingField::LABEL => __('Background repeat', 'custom-login'),
161
+ SettingField::DESC => '',
162
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
163
+ SettingField::OPTIONS => [
164
+ 'no-repeat' => 'no-repeat',
165
+ 'repeat' => 'repeat',
166
+ 'repeat-x' => 'repeat-x',
167
+ 'repeat-y' => 'repeat-y',
168
+ ],
169
+ ],
170
+ [
171
+ SettingField::NAME => OptionKey::LOGO_BACKGROUND_SIZE,
172
+ SettingField::LABEL => __('Background size', 'custom-login'),
173
+ SettingField::DESC => '',
174
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
175
+ SettingField::OPTIONS => [
176
+ 'none' => 'none',
177
+ 'cover' => 'cover',
178
+ 'contain' => 'contain',
179
+ 'flex' => 'flex',
180
+ ],
181
+ ],
182
+ [
183
+ SettingField::NAME => OptionKey::BREAK_S,
184
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Login Form', 'custom-login')),
185
+ SettingField::DESC => '',
186
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
187
+ ],
188
+ [
189
+ SettingField::NAME => OptionKey::LOGO_FORCE_FORM_MAX_WIDTH,
190
+ SettingField::LABEL => __('Force max-width', 'custom-login'),
191
+ SettingField::DESC => __(
192
+ 'If checked and the login form width (set below) is not empty, a CSS rule of <code>width</code> will be applied on the logo wrapper element <code>.login h1</code>. These settings apply to the Logo image (when background size is used).',
193
+ 'custom-login'
194
+ ),
195
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
196
+ ],
197
+ [
198
+ SettingField::NAME => OptionKey::LOGIN_FORM_WIDTH,
199
+ SettingField::LABEL => __('Width', 'custom-login'),
200
+ SettingField::DESC => __('Change the default width of the login form.', 'custom-login'),
201
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_NUMBER,
202
+ SettingField::SIZE => 'small',
203
+ SettingField::DEFAULT => '320',
204
+ SettingField::SANITIZE => 'int',
205
+ ],
206
+ [
207
+ SettingField::NAME => OptionKey::LOGIN_FORM_WIDTH_UNIT,
208
+ SettingField::LABEL => __('Width Unit', 'custom-login'),
209
+ SettingField::DESC => sprintf(
210
+ '<a href="https://www.w3schools.com/cssref/css_units.asp" target="_blank">%s</a>',
211
+ __('login form width unit value.', 'custom-login')
212
+ ),
213
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
214
+ SettingField::DEFAULT => 'px',
215
+ SettingField::OPTIONS => [
216
+ 'px' => 'px',
217
+ 'em' => 'em',
218
+ 'rem' => 'rem',
219
+ 'vw' => 'vw',
220
+ 'vh' => 'vh',
221
+ '%' => '%',
222
+ ],
223
+ ],
224
+ [
225
+ SettingField::NAME => OptionKey::LOGIN_FORM_BACKGROUND_COLOR,
226
+ SettingField::LABEL => __('Background color', 'custom-login'),
227
+ SettingField::DESC => '',
228
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_COLOR_ALPHA,
229
+ SettingField::DEFAULT => '',
230
+ ],
231
+ [
232
+ SettingField::NAME => OptionKey::LOGIN_FORM_BACKGROUND_URL,
233
+ SettingField::LABEL => __('Background URL', 'custom-login'),
234
+ SettingField::DESC => __('Add a background image to the login form.', 'custom-login'),
235
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_FILE,
236
+ SettingField::DEFAULT => '',
237
+ SettingField::SIZE => 'medium',
238
+ SettingField::SANITIZE => '\sanitize_text_field',
239
+ ],
240
+ [
241
+ SettingField::NAME => OptionKey::LOGIN_FORM_BACKGROUND_POSITION,
242
+ SettingField::LABEL => __('Background position', 'custom-login'),
243
+ SettingField::DESC => sprintf(
244
+ '<a href="https://www.w3schools.com/cssref/pr_background-position.asp" target="_blank">%s</a>',
245
+ __('html background position', 'custom-login')
246
+ ),
247
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
248
+ SettingField::OPTIONS => [
249
+ 'left top' => 'left top',
250
+ 'left center' => 'left center',
251
+ 'left bottom' => 'left bottom',
252
+ 'right top' => 'right top',
253
+ 'right center' => 'right center',
254
+ 'right bottom' => 'right bottom',
255
+ 'center top' => 'center top',
256
+ 'center center' => 'center center',
257
+ 'center bottom' => 'center bottom',
258
+ ],
259
+ ],
260
+ [
261
+ SettingField::NAME => OptionKey::LOGIN_FORM_BACKGROUND_REPEAT,
262
+ SettingField::LABEL => __('Background repeat', 'custom-login'),
263
+ SettingField::DESC => '',
264
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
265
+ SettingField::OPTIONS => [
266
+ 'no-repeat' => 'no-repeat',
267
+ 'repeat' => 'repeat',
268
+ 'repeat-x' => 'repeat-x',
269
+ 'repeat-y' => 'repeat-y',
270
+ ],
271
+ ],
272
+ [
273
+ SettingField::NAME => OptionKey::LOGIN_FORM_BACKGROUND_SIZE,
274
+ SettingField::LABEL => __('Background size', 'custom-login'),
275
+ SettingField::DESC => '',
276
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
277
+ SettingField::OPTIONS => [
278
+ 'none' => 'none',
279
+ 'cover' => 'cover',
280
+ 'contain' => 'contain',
281
+ 'flex' => 'flex',
282
+ ],
283
+ ],
284
+ [
285
+ SettingField::NAME => OptionKey::LOGIN_FORM_BORDER_RADIUS,
286
+ SettingField::LABEL => __('Border radius', 'custom-login'),
287
+ SettingField::DESC => '',
288
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_NUMBER,
289
+ SettingField::SIZE => 'small',
290
+ SettingField::DEFAULT => '',
291
+ SettingField::SANITIZE => 'int',
292
+ ],
293
+ [
294
+ SettingField::NAME => OptionKey::LOGIN_FORM_BORDER_SIZE,
295
+ SettingField::LABEL => __('Border size', 'custom-login'),
296
+ SettingField::DESC => '',
297
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_NUMBER,
298
+ SettingField::SIZE => 'small',
299
+ SettingField::DEFAULT => '',
300
+ SettingField::SANITIZE => 'int',
301
+ ],
302
+ [
303
+ SettingField::NAME => OptionKey::LOGIN_FORM_BORDER_COLOR,
304
+ SettingField::LABEL => __('Border color', 'custom-login'),
305
+ SettingField::DESC => '',
306
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_COLOR_ALPHA,
307
+ SettingField::DEFAULT => '',
308
+ ],
309
+ [
310
+ SettingField::NAME => OptionKey::LOGIN_FORM_BOX_SHADOW,
311
+ SettingField::LABEL => __('Box shadow', 'custom-login'),
312
+ SettingField::DESC => sprintf(
313
+ __(
314
+ 'Use <a href="%s" target="_blank">box shadow</a> syntax w/ out color. <code>inset h-shadow v-shadow blur spread</code>',
315
+ 'custom-login'
316
+ ),
317
+ 'https://www.w3schools.com/cssref/css3_pr_box-shadow.asp'
318
+ ),
319
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_TEXT,
320
+ SettingField::SIZE => 'medium',
321
+ SettingField::DEFAULT => '5px 5px 10px',
322
+ ],
323
+ [
324
+ SettingField::NAME => OptionKey::LOGIN_FORM_BOX_SHADOW_COLOR,
325
+ SettingField::LABEL => __('Box shadow color', 'custom-login'),
326
+ SettingField::DESC => '',
327
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_COLOR_ALPHA,
328
+ SettingField::DEFAULT => '',
329
+ ],
330
+ [
331
+ SettingField::NAME => OptionKey::BREAK_S,
332
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Miscellaneous', 'custom-login')),
333
+ SettingField::DESC => '',
334
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
335
+ ],
336
+ [
337
+ SettingField::NAME => OptionKey::LABEL_COLOR,
338
+ SettingField::LABEL => __('Label color', 'custom-login'),
339
+ SettingField::DESC => '',
340
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_COLOR_ALPHA,
341
+ SettingField::DEFAULT => '',
342
+ ],
343
+ [
344
+ SettingField::NAME => OptionKey::BREAK_S,
345
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Below Form anchor', 'custom-login')),
346
+ SettingField::DESC => '',
347
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
348
+ ],
349
+ [
350
+ SettingField::NAME => OptionKey::NAV_COLOR,
351
+ SettingField::LABEL => __('Nav color', 'custom-login'),
352
+ SettingField::DESC => '',
353
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_COLOR_ALPHA,
354
+ SettingField::DEFAULT => '',
355
+ ],
356
+ [
357
+ SettingField::NAME => OptionKey::NAV_TEXT_SHADOW_COLOR,
358
+ SettingField::LABEL => __('Nav text-shadow color', 'custom-login'),
359
+ SettingField::DESC => '',
360
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_COLOR_ALPHA,
361
+ SettingField::DEFAULT => '',
362
+ ],
363
+ [
364
+ SettingField::NAME => OptionKey::NAV_HOVER_COLOR,
365
+ SettingField::LABEL => __('Nav color hover', 'custom-login'),
366
+ SettingField::DESC => '',
367
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_COLOR_ALPHA,
368
+ SettingField::DEFAULT => '',
369
+ ],
370
+ [
371
+ SettingField::NAME => OptionKey::NAV_TEXT_SHADOW_HOVER_COLOR,
372
+ SettingField::LABEL => __('Nav text-shadow hover', 'custom-login'),
373
+ SettingField::DESC => '',
374
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_COLOR_ALPHA,
375
+ SettingField::DEFAULT => '',
376
+ ],
377
+ [
378
+ SettingField::NAME => OptionKey::BREAK_S,
379
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Custom CSS', 'custom-login')),
380
+ SettingField::DESC => '',
381
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
382
+ ],
383
+ [
384
+ SettingField::NAME => OptionKey::CUSTOM_CSS,
385
+ SettingField::LABEL => '',
386
+ SettingField::DEFAULT => '',
387
+ SettingField::DESC => sprintf(
388
+ '%s %s',
389
+ __('Allowed variables:', 'custom-login'),
390
+ '<ul>
391
+ <li>{BSLASH} = "\" (backslash)</li>
392
+ <li><a href="https://wordpress.org/support/topic/quotes-in-custom-css-gets-replaced-with-useless-quote?replies=4">Request others</a></li>
393
+ </ul>'
394
+ ),
395
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_TEXTAREA,
396
+ SettingField::SANITIZE => fn($css): string => wp_specialchars_decode(wp_filter_nohtml_kses($css)),
397
+ SettingField::ATTRIBUTES => [
398
+ 'data-codemirror' => 'css',
399
+ ],
400
+ ],
401
+ [
402
+ SettingField::NAME => OptionKey::ANIMATE_CSS,
403
+ SettingField::LABEL => __('Animate', 'custom-login'),
404
+ SettingField::DESC => sprintf(
405
+ __('Include <a href="%s">animate.css</a>?', 'custom-login'),
406
+ 'https://daneden.github.io/animate.css/'
407
+ ),
408
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
409
+ SettingField::DEFAULT => 'off',
410
+ ],
411
+ [
412
+ SettingField::NAME => OptionKey::BREAK_S,
413
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Custom HTML', 'custom-login')),
414
+ SettingField::DESC => '',
415
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
416
+ ],
417
+ [
418
+ SettingField::NAME => OptionKey::CUSTOM_HTML,
419
+ SettingField::LABEL => '',
420
+ SettingField::DEFAULT => '',
421
+ SettingField::DESC => '',
422
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_TEXTAREA,
423
+ SettingField::SANITIZE => 'wp_kses_post', //Allow HTML
424
+ SettingField::ATTRIBUTES => [
425
+ 'data-codemirror' => 'html',
426
+ ],
427
+ ],
428
+ [
429
+ SettingField::NAME => OptionKey::BREAK_S,
430
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Custom Javascript', 'custom-login')),
431
+ SettingField::DESC => '',
432
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
433
+ ],
434
+ [
435
+ SettingField::NAME => OptionKey::CUSTOM_JQUERY,
436
+ SettingField::LABEL => '',
437
+ SettingField::DEFAULT => '',
438
+ SettingField::DESC => sprintf(
439
+ '<code>%1$s</code>&nbsp;%2$s&nbsp;<code>%3$s</code><br>',
440
+ esc_html('<script type="text/javascript">'),
441
+ __('Your custom javascript will output here', 'custom-login'),
442
+ esc_html('</script>')
443
+ ),
444
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_TEXTAREA,
445
+ SettingField::SANITIZE => 'wp_specialchars_decode',
446
+ SettingField::ATTRIBUTES => [
447
+ 'data-codemirror' => 'javascript',
448
+ ],
449
+ ],
450
+ ],
451
+ Factory::getSection(Factory::SECTION_GENERAL) => [
452
+ [
453
+ SettingField::NAME => OptionKey::ACTIVE,
454
+ SettingField::LABEL => __('Activate', 'custom-login'),
455
+ SettingField::DESC => __('Allow Custom Login to hook into WordPress.', 'custom-login'),
456
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
457
+ SettingField::DEFAULT => OptionValue::ON,
458
+ ],
459
+ [
460
+ SettingField::NAME => OptionKey::CAPABILITY,
461
+ SettingField::LABEL => __('Capability', 'custom-login'),
462
+ SettingField::DESC => sprintf(
463
+ __(
464
+ 'Set the minimum user capability to manage these settings. The default capability is <code>%s</code>',
465
+ 'custom-login'
466
+ ),
467
+ 'manage_options'
468
+ ),
469
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_SELECT,
470
+ SettingField::SIZE => 'medium',
471
+ SettingField::DEFAULT => 'manage_options',
472
+ SettingField::OPTIONS => TheFrosty\CustomLogin\getWpRoles(),
473
+ ],
474
+ [
475
+ SettingField::NAME => OptionKey::BREAK_S,
476
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Tracking Settings', 'custom-login')),
477
+ SettingField::DESC => '',
478
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
479
+ ],
480
+ [
481
+ SettingField::NAME => OptionKey::TRACKING,
482
+ SettingField::LABEL => __('Usage tracking', 'custom-login'),
483
+ SettingField::DESC => __(
484
+ 'Allow Frosty Media to anonymously track how this plugin is used (and help us make the plugin better). Opt-in and receive a 20% discount code for all Custom Login extensions. Get your coupon code <a href="https://frosty.media/?p=21442">here</a>.',
485
+ 'custom-login'
486
+ ),
487
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
488
+ ],
489
+ [
490
+ SettingField::NAME => OptionKey::BREAK_S,
491
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Notices', 'custom-login')),
492
+ SettingField::DESC => '',
493
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
494
+ ],
495
+ [
496
+ SettingField::NAME => OptionKey::ADMIN_NOTICES,
497
+ SettingField::LABEL => __('Admin notices', 'custom-login'),
498
+ SettingField::DESC => sprintf(
499
+ '%s %s',
500
+ __('Allow admin notices everywhere in WordPress.', 'custom-login'),
501
+ __('Unchecked equals "off" (do not allow).', 'custom-login')
502
+ ),
503
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
504
+ SettingField::DEFAULT => OptionValue::ON,
505
+ ],
506
+ [
507
+ SettingField::NAME => OptionKey::DASHBOARD_WIDGET,
508
+ SettingField::LABEL => __('Dashboard widget', 'custom-login'),
509
+ SettingField::DESC => sprintf(
510
+ '%s %s',
511
+ __('Show a dashboard widget, like WordPress news for Frosty Media.', 'custom-login'),
512
+ __('Unchecked equals "off" (do not allow).', 'custom-login')
513
+ ),
514
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
515
+ SettingField::DEFAULT => OptionValue::ON,
516
+ ],
517
+ [
518
+ SettingField::NAME => OptionKey::BREAK_S,
519
+ SettingField::LABEL => sprintf('<h4>%s</h4>', __('Login functions', 'custom-login')),
520
+ SettingField::DESC => '',
521
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_HTML,
522
+ ],
523
+ [
524
+ SettingField::NAME => OptionKey::WP_SHAKE_JS,
525
+ SettingField::LABEL => __('Disable Login shake', 'custom-login'),
526
+ SettingField::DESC => __('Disable the login forms animated "shake" on error.', 'custom-login'),
527
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
528
+ ],
529
+ [
530
+ SettingField::NAME => OptionKey::REMOVE_LOGIN_CSS,
531
+ SettingField::LABEL => __('Remove login CSS', 'custom-login'),
532
+ SettingField::DESC => __(
533
+ 'Remove WordPress\' login CSS. Warning: You\'ll have to add additional styles not set by this plugin.',
534
+ 'custom-login'
535
+ ),
536
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
537
+ ],
538
+ [
539
+ SettingField::NAME => OptionKey::LOSTPASSWORD_TEXT,
540
+ SettingField::LABEL => __('Remove lost password text', 'custom-login'),
541
+ SettingField::DESC => __(
542
+ 'Remove the "Lost Password?" text. This does <strong>not</strong> disable the lost password function.',
543
+ 'custom-login'
544
+ ),
545
+ SettingField::TYPE => FieldTypes::FIELD_TYPE_CHECKBOX,
546
+ ],
547
+ ],
548
+ ],
549
+ ];
css/admin.css DELETED
@@ -1,442 +0,0 @@
1
- .cl-container {
2
- background-color: #f5f5f5;
3
- background-image: -moz-linear-gradient(center top , #f2f2f2 0px, #f5f5f5 100%);
4
- background-repeat: repeat-x;
5
- border: 1px solid #dedede;
6
- box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
7
- margin-top: 5px;
8
- overflow: hidden;
9
- }
10
-
11
- .cl-container * {
12
- transition: all 0.5s ease-in-out;
13
- }
14
- [class^="chosen-"], [class^="chosen-"] * {
15
- transition: none;
16
- }
17
-
18
- .cl-container .cl-header {
19
- box-sizing: border-box;
20
- float: none !important;
21
- position: relative !important;
22
- width: 100% !important;
23
- }
24
-
25
- .cl-header h2,
26
- .cl-header h3 {
27
- display: inline-block;
28
- padding-right: 5px;
29
- }
30
- .cl-header a {
31
- color: inherit;
32
- text-decoration: none;
33
- }
34
-
35
- .cl-container .cl-header, .cl-container .cl-footer {
36
- padding: 6px 10px;
37
- }
38
-
39
- /************ NOTICES *************/
40
- #cl-notices {
41
- }
42
- #cl-notices h2 {
43
- display: none;
44
- }
45
-
46
- #cl-notices div.updated,
47
- #cl-notices div.error {
48
- background-color: transparent;
49
- margin: 0;
50
- }
51
-
52
- /************ STICKY *************/
53
- #cl-sticky {
54
- background: #f3f3f3;
55
- box-shadow: 0 1px 0 #dedede inset;
56
- padding: 0;
57
- position: relative;
58
- z-index: 19;
59
- }
60
- #cl-sticky .wrap {
61
- margin: 0;
62
- padding: 4px 15px;
63
- }
64
- .is-sticky > #cl-sticky {
65
- bottom: 0;
66
- border-top: 1px solid #dedede;
67
- box-shadow: 0 1px 0 #fcfcfc inset;
68
- top: auto !important;
69
- }
70
-
71
- #sticky-admin-notice {
72
- display: inline-block;
73
- }
74
-
75
- #sticky-admin-notice ul.social {
76
- display: none;
77
- margin: 5px 0 0 0;
78
- }
79
- .is-sticky #sticky-admin-notice ul.social {
80
- display: inline-block;
81
- }
82
- #sticky-admin-notice ul li {
83
- display: inline;
84
- margin-right: 8px;
85
- }
86
- #sticky-admin-notice ul li a {
87
- color: #898989;
88
- text-decoration: none;
89
- }
90
- #sticky-admin-notice ul li a:hover {
91
- text-decoration: underline;
92
- }
93
-
94
- /*******SIDEBAR/MAIN *************/
95
- .cl-container .cl-sidebar, .cl-container .cl-main {
96
- min-height: 950px;
97
- }
98
-
99
- /************ SIDEBAR ************/
100
- .cl-sidebar {
101
- float: left;
102
- width: 222px;
103
- }
104
- #wpbody-content .cl-sidebar .metabox-holder {
105
- padding-top: 0;
106
- }
107
-
108
- .cl-sections-menu {
109
- border-top: 1px solid #dedede;
110
- margin-top: 0;
111
- }
112
- .cl-sections-menu li {
113
- }
114
- .cl-sections-menu li > a {
115
- border-bottom: 1px solid #dedede;
116
- box-shadow: 0 1px 0 #fff;
117
- color: #555;
118
- display: block;
119
- padding: 10px 15px;
120
- text-decoration: none;
121
- }
122
- .cl-sections-menu li > a:hover {
123
- color: #222;
124
- padding-left: 20px;
125
- }
126
- .cl-sections-menu li > a.active {
127
- background-color: #0074a2;
128
- color: #efefef;
129
- }
130
- /* Addons */
131
- .cl-sections-menu li > a[href="#custom_login_extensions"] {
132
- background-color: #e7ecef;
133
- color: #474747;
134
- font-weight: bold;
135
- }
136
- .cl-sections-menu li > a.active[href="#custom_login_extensions"] {
137
- }
138
-
139
- .cl-sidebar .postbox {
140
- border-right: none;
141
- border-left: none;
142
- font-size: 80%;
143
- min-width: 222px; /* Same as .cl-sidebar width */
144
- margin-bottom: -1px;
145
- }
146
-
147
- .cl-sidebar .star-rating {
148
- text-decoration: none;
149
- }
150
- .cl-sidebar .star-rating i {
151
- color: #fddb5a;
152
- }
153
-
154
- /************ MAIN ***************/
155
- .cl-main {
156
- background: none repeat scroll 0 0 #fcfcfc;
157
- border-top: 1px solid #dedede;
158
- border-left: 1px solid #d8d8d8;
159
- box-shadow: 0 1px 0 #fff inset;
160
- margin-left: 221px;
161
- padding: 10px 20px;
162
- position: relative;
163
- z-index: 1;
164
- }
165
-
166
- .cl-main > .group {
167
- display: none;
168
- }
169
- .no-js .cl-main > .group {
170
- display: block;
171
- }
172
-
173
- .cl-container .cl-main h3 {
174
- border-bottom: 1px solid #e7e7e7;
175
- line-height: 2em;
176
- margin-top: 0;
177
- }
178
- .cl-main .form-table {
179
- clear: none;
180
- margin-top: 0 !important;
181
- }
182
- .cl-main .form-table th {
183
- font-weight: 400;
184
- width: 33%;
185
- }
186
- .cl-main .form-table th h4 {
187
- font-weight: 600;
188
- font-size: 1.25em;
189
- margin: 0.95em 0;
190
- }
191
-
192
- p.style-pack-img-wrapper img {
193
- height: auto;
194
- max-width: 640px;
195
- width: 100%;
196
- }
197
-
198
- /* CALLBACKS */
199
- .cl-main .checkbox-wrap {
200
- display: inline-block;
201
- float: left;
202
- margin: 0 35px 0 0;
203
- position: relative;
204
- }
205
-
206
- .cl-main .cl-colorpicker-wrap {
207
- position: relative;
208
- }
209
- .cl-main .cl-colorpicker-wrap * {
210
- transition: none;
211
- }
212
-
213
- .cl-main .wp-picker-container {
214
- float: left;
215
- margin-right: 10px;
216
- }
217
-
218
- .cl-main .cl-colorpicker-wrap .checkbox-wrap {
219
- float: left;
220
- }
221
- .cl-main .cl-colorpicker-wrap .checkbox-wrap > input {
222
- float: none;
223
- }
224
-
225
- .cl-container select {
226
- min-width: 120px;
227
- }
228
-
229
- .cl-main .img-wrapper {
230
- height: auto;
231
- margin: 10px 0;
232
- width: 100%;
233
- }
234
- .cl-main .img-wrapper img {
235
- border: 1px solid #aaa;
236
- box-shadow: 0 0 2px 0 #BFBFBF;
237
- height: auto;
238
- width: 250px;
239
- }
240
- .cl-main .img-wrapper a {
241
- display: block;
242
- }
243
-
244
- /* ACE */
245
- div[id$="_ace"] {
246
- min-height: 150px;
247
- position: relative;
248
- }
249
- div[id$="_ace"] * {
250
- transition: none;
251
- }
252
-
253
- /* EDDRI */
254
- .eddri-addon-container {
255
- padding: 1%;
256
- }
257
-
258
- @media screen and (max-width: 600px) {
259
- .cl-sidebar {
260
- float: none;
261
- width: 100%;
262
- }
263
- .cl-main {
264
- float: none;
265
- margin-left: 0;
266
- }
267
- }
268
-
269
- /* SECTIONS */
270
- .section {
271
- clear: both;
272
- padding: 0px;
273
- margin: 0px;
274
- }
275
- .section * {
276
- box-sizing: border-box;
277
- }
278
-
279
- /* COLUMN SETUP */
280
- .col {
281
- display: block;
282
- float: left;
283
- margin: 1% 0 1% 1.6%;
284
- }
285
- .col:nth-child(3n+1) { clear: both; margin-left: 0; }
286
-
287
- /* GRID OF TWO */
288
- .span_2_of_2 {
289
- width: 100%;
290
- }
291
- .span_1_of_2 {
292
- width: 50%;
293
- }
294
-
295
- /* GRID OF THREE */
296
- .span_3_of_3 {
297
- width: 100%;
298
- }
299
- .span_2_of_3 {
300
- width: 66.1%;
301
- }
302
- .span_1_of_3 {
303
- width: 32.2%;
304
- }
305
-
306
- /* GO FULL WIDTH AT LESS THAN 480 PIXELS */
307
- @media only screen and (max-width: 762px) {
308
- .col {
309
- margin: 1% 0 1em;
310
- }
311
- }
312
-
313
- /* GO FULL WIDTH AT LESS THAN 480 PIXELS */
314
- @media only screen and (max-width: 480px) {
315
- .span_1_of_2 {
316
- width: 100%;
317
- }
318
- .span_3_of_3 {
319
- width: 100%;
320
- }
321
- .span_2_of_3 {
322
- width: 100%;
323
- }
324
- .span_1_of_3 {
325
- width: 100%;
326
- }
327
- }
328
-
329
- /* Toggle @ref http://codepen.io/pklada/pen/jEGwMB */
330
- .tgl {
331
- position: relative;
332
- display: inline-block;
333
- height: 25px;
334
- cursor: pointer;
335
- margin: 1px 10px 0 0;
336
- }
337
- .tgl > input {
338
- position: absolute;
339
- opacity: 0;
340
- z-index: -1;
341
- /* Put the input behind the label so it doesn't overlay text */
342
- visibility: hidden;
343
- }
344
- .tgl .tgl_body {
345
- width: 50px;
346
- height: 25px;
347
- background: white;
348
- border: 1px solid #dadde1;
349
- display: inline-block;
350
- position: relative;
351
- border-radius: 50px;
352
- }
353
- .tgl .tgl_switch {
354
- width: 25px;
355
- height: 25px;
356
- display: inline-block;
357
- background-color: white;
358
- position: absolute;
359
- left: -1px;
360
- top: -1px;
361
- border-radius: 50%;
362
- border: 1px solid #ccd0d6;
363
- -moz-box-shadow: 0 2px 2px rgba(0, 0, 0, 0.13);
364
- -webkit-box-shadow: 0 2px 2px rgba(0, 0, 0, 0.13);
365
- box-shadow: 0 2px 2px rgba(0, 0, 0, 0.13);
366
- -moz-transition: left cubic-bezier(0.34, 1.61, 0.7, 1) 250ms, -moz-transform cubic-bezier(0.34, 1.61, 0.7, 1) 250ms;
367
- -o-transition: left cubic-bezier(0.34, 1.61, 0.7, 1) 250ms, -o-transform cubic-bezier(0.34, 1.61, 0.7, 1) 250ms;
368
- -webkit-transition: left cubic-bezier(0.34, 1.61, 0.7, 1), -webkit-transform cubic-bezier(0.34, 1.61, 0.7, 1);
369
- -webkit-transition-delay: 250ms, 250ms;
370
- transition: left cubic-bezier(0.34, 1.61, 0.7, 1) 250ms, transform cubic-bezier(0.34, 1.61, 0.7, 1) 250ms;
371
- z-index: 1;
372
- }
373
- .tgl .tgl_track {
374
- position: absolute;
375
- left: 0;
376
- top: 0;
377
- right: 0;
378
- bottom: 0;
379
- overflow: hidden;
380
- border-radius: 50px;
381
- }
382
- .tgl .tgl_bgd {
383
- position: absolute;
384
- right: -10px;
385
- top: 0;
386
- bottom: 0;
387
- width: 55px;
388
- -moz-transition: left cubic-bezier(0.34, 1.61, 0.7, 1) 250ms, right cubic-bezier(0.34, 1.61, 0.7, 1) 250ms;
389
- -o-transition: left cubic-bezier(0.34, 1.61, 0.7, 1) 250ms, right cubic-bezier(0.34, 1.61, 0.7, 1) 250ms;
390
- -webkit-transition: left cubic-bezier(0.34, 1.61, 0.7, 1), right cubic-bezier(0.34, 1.61, 0.7, 1);
391
- -webkit-transition-delay: 250ms, 250ms;
392
- transition: left cubic-bezier(0.34, 1.61, 0.7, 1) 250ms, right cubic-bezier(0.34, 1.61, 0.7, 1) 250ms;
393
- background: #439fd8;
394
- }
395
- .tgl .tgl_bgd:before {
396
- color: #fff;
397
- content: "\f147";
398
- display: inline-block;
399
- -webkit-font-smoothing: antialiased;
400
- font: normal 20px/1 'dashicons';
401
- position: relative;
402
- right: -20px;
403
- top: 3px;
404
- vertical-align: top;
405
- }
406
- .tgl .tgl_bgd-negative {
407
- right: auto;
408
- left: -45px;
409
- background: white;
410
- }
411
- .tgl .tgl_bgd-negative:before {
412
- color: #CECECE;
413
- content: "\f335";
414
- display: inline-block;
415
- -webkit-font-smoothing: antialiased;
416
- font: normal 20px/1 'dashicons';
417
- left: 14.5px;
418
- vertical-align: top;
419
- }
420
- .tgl:hover .tgl_switch {
421
- border-color: #b5bbc3;
422
- -moz-transform: scale(1.06);
423
- -ms-transform: scale(1.06);
424
- -webkit-transform: scale(1.06);
425
- transform: scale(1.06);
426
- }
427
- .tgl:active .tgl_switch {
428
- -moz-transform: scale(0.95);
429
- -ms-transform: scale(0.95);
430
- -webkit-transform: scale(0.95);
431
- transform: scale(0.95);
432
- }
433
- .tgl > :not(:checked) ~ .tgl_body > .tgl_switch {
434
- left: 25px;
435
- }
436
- .tgl > :not(:checked) ~ .tgl_body .tgl_bgd {
437
- right: -45px;
438
- }
439
- .tgl > :not(:checked) ~ .tgl_body .tgl_bgd.tgl_bgd-negative {
440
- right: auto;
441
- left: -10px;
442
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
css/animate.css DELETED
@@ -1,3623 +0,0 @@
1
- @charset "UTF-8";
2
-
3
- /*!
4
- * animate.css -http://daneden.me/animate
5
- * Version - 3.7.0
6
- * Licensed under the MIT license - http://opensource.org/licenses/MIT
7
- *
8
- * Copyright (c) 2018 Daniel Eden
9
- */
10
-
11
- @-webkit-keyframes bounce {
12
- from,
13
- 20%,
14
- 53%,
15
- 80%,
16
- to {
17
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
18
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
19
- -webkit-transform: translate3d(0, 0, 0);
20
- transform: translate3d(0, 0, 0);
21
- }
22
-
23
- 40%,
24
- 43% {
25
- -webkit-animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
26
- animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
27
- -webkit-transform: translate3d(0, -30px, 0);
28
- transform: translate3d(0, -30px, 0);
29
- }
30
-
31
- 70% {
32
- -webkit-animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
33
- animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
34
- -webkit-transform: translate3d(0, -15px, 0);
35
- transform: translate3d(0, -15px, 0);
36
- }
37
-
38
- 90% {
39
- -webkit-transform: translate3d(0, -4px, 0);
40
- transform: translate3d(0, -4px, 0);
41
- }
42
- }
43
-
44
- @keyframes bounce {
45
- from,
46
- 20%,
47
- 53%,
48
- 80%,
49
- to {
50
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
51
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
52
- -webkit-transform: translate3d(0, 0, 0);
53
- transform: translate3d(0, 0, 0);
54
- }
55
-
56
- 40%,
57
- 43% {
58
- -webkit-animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
59
- animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
60
- -webkit-transform: translate3d(0, -30px, 0);
61
- transform: translate3d(0, -30px, 0);
62
- }
63
-
64
- 70% {
65
- -webkit-animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
66
- animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
67
- -webkit-transform: translate3d(0, -15px, 0);
68
- transform: translate3d(0, -15px, 0);
69
- }
70
-
71
- 90% {
72
- -webkit-transform: translate3d(0, -4px, 0);
73
- transform: translate3d(0, -4px, 0);
74
- }
75
- }
76
-
77
- .bounce {
78
- -webkit-animation-name: bounce;
79
- animation-name: bounce;
80
- -webkit-transform-origin: center bottom;
81
- transform-origin: center bottom;
82
- }
83
-
84
- @-webkit-keyframes flash {
85
- from,
86
- 50%,
87
- to {
88
- opacity: 1;
89
- }
90
-
91
- 25%,
92
- 75% {
93
- opacity: 0;
94
- }
95
- }
96
-
97
- @keyframes flash {
98
- from,
99
- 50%,
100
- to {
101
- opacity: 1;
102
- }
103
-
104
- 25%,
105
- 75% {
106
- opacity: 0;
107
- }
108
- }
109
-
110
- .flash {
111
- -webkit-animation-name: flash;
112
- animation-name: flash;
113
- }
114
-
115
- /* originally authored by Nick Pettit - https://github.com/nickpettit/glide */
116
-
117
- @-webkit-keyframes pulse {
118
- from {
119
- -webkit-transform: scale3d(1, 1, 1);
120
- transform: scale3d(1, 1, 1);
121
- }
122
-
123
- 50% {
124
- -webkit-transform: scale3d(1.05, 1.05, 1.05);
125
- transform: scale3d(1.05, 1.05, 1.05);
126
- }
127
-
128
- to {
129
- -webkit-transform: scale3d(1, 1, 1);
130
- transform: scale3d(1, 1, 1);
131
- }
132
- }
133
-
134
- @keyframes pulse {
135
- from {
136
- -webkit-transform: scale3d(1, 1, 1);
137
- transform: scale3d(1, 1, 1);
138
- }
139
-
140
- 50% {
141
- -webkit-transform: scale3d(1.05, 1.05, 1.05);
142
- transform: scale3d(1.05, 1.05, 1.05);
143
- }
144
-
145
- to {
146
- -webkit-transform: scale3d(1, 1, 1);
147
- transform: scale3d(1, 1, 1);
148
- }
149
- }
150
-
151
- .pulse {
152
- -webkit-animation-name: pulse;
153
- animation-name: pulse;
154
- }
155
-
156
- @-webkit-keyframes rubberBand {
157
- from {
158
- -webkit-transform: scale3d(1, 1, 1);
159
- transform: scale3d(1, 1, 1);
160
- }
161
-
162
- 30% {
163
- -webkit-transform: scale3d(1.25, 0.75, 1);
164
- transform: scale3d(1.25, 0.75, 1);
165
- }
166
-
167
- 40% {
168
- -webkit-transform: scale3d(0.75, 1.25, 1);
169
- transform: scale3d(0.75, 1.25, 1);
170
- }
171
-
172
- 50% {
173
- -webkit-transform: scale3d(1.15, 0.85, 1);
174
- transform: scale3d(1.15, 0.85, 1);
175
- }
176
-
177
- 65% {
178
- -webkit-transform: scale3d(0.95, 1.05, 1);
179
- transform: scale3d(0.95, 1.05, 1);
180
- }
181
-
182
- 75% {
183
- -webkit-transform: scale3d(1.05, 0.95, 1);
184
- transform: scale3d(1.05, 0.95, 1);
185
- }
186
-
187
- to {
188
- -webkit-transform: scale3d(1, 1, 1);
189
- transform: scale3d(1, 1, 1);
190
- }
191
- }
192
-
193
- @keyframes rubberBand {
194
- from {
195
- -webkit-transform: scale3d(1, 1, 1);
196
- transform: scale3d(1, 1, 1);
197
- }
198
-
199
- 30% {
200
- -webkit-transform: scale3d(1.25, 0.75, 1);
201
- transform: scale3d(1.25, 0.75, 1);
202
- }
203
-
204
- 40% {
205
- -webkit-transform: scale3d(0.75, 1.25, 1);
206
- transform: scale3d(0.75, 1.25, 1);
207
- }
208
-
209
- 50% {
210
- -webkit-transform: scale3d(1.15, 0.85, 1);
211
- transform: scale3d(1.15, 0.85, 1);
212
- }
213
-
214
- 65% {
215
- -webkit-transform: scale3d(0.95, 1.05, 1);
216
- transform: scale3d(0.95, 1.05, 1);
217
- }
218
-
219
- 75% {
220
- -webkit-transform: scale3d(1.05, 0.95, 1);
221
- transform: scale3d(1.05, 0.95, 1);
222
- }
223
-
224
- to {
225
- -webkit-transform: scale3d(1, 1, 1);
226
- transform: scale3d(1, 1, 1);
227
- }
228
- }
229
-
230
- .rubberBand {
231
- -webkit-animation-name: rubberBand;
232
- animation-name: rubberBand;
233
- }
234
-
235
- @-webkit-keyframes shake {
236
- from,
237
- to {
238
- -webkit-transform: translate3d(0, 0, 0);
239
- transform: translate3d(0, 0, 0);
240
- }
241
-
242
- 10%,
243
- 30%,
244
- 50%,
245
- 70%,
246
- 90% {
247
- -webkit-transform: translate3d(-10px, 0, 0);
248
- transform: translate3d(-10px, 0, 0);
249
- }
250
-
251
- 20%,
252
- 40%,
253
- 60%,
254
- 80% {
255
- -webkit-transform: translate3d(10px, 0, 0);
256
- transform: translate3d(10px, 0, 0);
257
- }
258
- }
259
-
260
- @keyframes shake {
261
- from,
262
- to {
263
- -webkit-transform: translate3d(0, 0, 0);
264
- transform: translate3d(0, 0, 0);
265
- }
266
-
267
- 10%,
268
- 30%,
269
- 50%,
270
- 70%,
271
- 90% {
272
- -webkit-transform: translate3d(-10px, 0, 0);
273
- transform: translate3d(-10px, 0, 0);
274
- }
275
-
276
- 20%,
277
- 40%,
278
- 60%,
279
- 80% {
280
- -webkit-transform: translate3d(10px, 0, 0);
281
- transform: translate3d(10px, 0, 0);
282
- }
283
- }
284
-
285
- .shake {
286
- -webkit-animation-name: shake;
287
- animation-name: shake;
288
- }
289
-
290
- @-webkit-keyframes headShake {
291
- 0% {
292
- -webkit-transform: translateX(0);
293
- transform: translateX(0);
294
- }
295
-
296
- 6.5% {
297
- -webkit-transform: translateX(-6px) rotateY(-9deg);
298
- transform: translateX(-6px) rotateY(-9deg);
299
- }
300
-
301
- 18.5% {
302
- -webkit-transform: translateX(5px) rotateY(7deg);
303
- transform: translateX(5px) rotateY(7deg);
304
- }
305
-
306
- 31.5% {
307
- -webkit-transform: translateX(-3px) rotateY(-5deg);
308
- transform: translateX(-3px) rotateY(-5deg);
309
- }
310
-
311
- 43.5% {
312
- -webkit-transform: translateX(2px) rotateY(3deg);
313
- transform: translateX(2px) rotateY(3deg);
314
- }
315
-
316
- 50% {
317
- -webkit-transform: translateX(0);
318
- transform: translateX(0);
319
- }
320
- }
321
-
322
- @keyframes headShake {
323
- 0% {
324
- -webkit-transform: translateX(0);
325
- transform: translateX(0);
326
- }
327
-
328
- 6.5% {
329
- -webkit-transform: translateX(-6px) rotateY(-9deg);
330
- transform: translateX(-6px) rotateY(-9deg);
331
- }
332
-
333
- 18.5% {
334
- -webkit-transform: translateX(5px) rotateY(7deg);
335
- transform: translateX(5px) rotateY(7deg);
336
- }
337
-
338
- 31.5% {
339
- -webkit-transform: translateX(-3px) rotateY(-5deg);
340
- transform: translateX(-3px) rotateY(-5deg);
341
- }
342
-
343
- 43.5% {
344
- -webkit-transform: translateX(2px) rotateY(3deg);
345
- transform: translateX(2px) rotateY(3deg);
346
- }
347
-
348
- 50% {
349
- -webkit-transform: translateX(0);
350
- transform: translateX(0);
351
- }
352
- }
353
-
354
- .headShake {
355
- -webkit-animation-timing-function: ease-in-out;
356
- animation-timing-function: ease-in-out;
357
- -webkit-animation-name: headShake;
358
- animation-name: headShake;
359
- }
360
-
361
- @-webkit-keyframes swing {
362
- 20% {
363
- -webkit-transform: rotate3d(0, 0, 1, 15deg);
364
- transform: rotate3d(0, 0, 1, 15deg);
365
- }
366
-
367
- 40% {
368
- -webkit-transform: rotate3d(0, 0, 1, -10deg);
369
- transform: rotate3d(0, 0, 1, -10deg);
370
- }
371
-
372
- 60% {
373
- -webkit-transform: rotate3d(0, 0, 1, 5deg);
374
- transform: rotate3d(0, 0, 1, 5deg);
375
- }
376
-
377
- 80% {
378
- -webkit-transform: rotate3d(0, 0, 1, -5deg);
379
- transform: rotate3d(0, 0, 1, -5deg);
380
- }
381
-
382
- to {
383
- -webkit-transform: rotate3d(0, 0, 1, 0deg);
384
- transform: rotate3d(0, 0, 1, 0deg);
385
- }
386
- }
387
-
388
- @keyframes swing {
389
- 20% {
390
- -webkit-transform: rotate3d(0, 0, 1, 15deg);
391
- transform: rotate3d(0, 0, 1, 15deg);
392
- }
393
-
394
- 40% {
395
- -webkit-transform: rotate3d(0, 0, 1, -10deg);
396
- transform: rotate3d(0, 0, 1, -10deg);
397
- }
398
-
399
- 60% {
400
- -webkit-transform: rotate3d(0, 0, 1, 5deg);
401
- transform: rotate3d(0, 0, 1, 5deg);
402
- }
403
-
404
- 80% {
405
- -webkit-transform: rotate3d(0, 0, 1, -5deg);
406
- transform: rotate3d(0, 0, 1, -5deg);
407
- }
408
-
409
- to {
410
- -webkit-transform: rotate3d(0, 0, 1, 0deg);
411
- transform: rotate3d(0, 0, 1, 0deg);
412
- }
413
- }
414
-
415
- .swing {
416
- -webkit-transform-origin: top center;
417
- transform-origin: top center;
418
- -webkit-animation-name: swing;
419
- animation-name: swing;
420
- }
421
-
422
- @-webkit-keyframes tada {
423
- from {
424
- -webkit-transform: scale3d(1, 1, 1);
425
- transform: scale3d(1, 1, 1);
426
- }
427
-
428
- 10%,
429
- 20% {
430
- -webkit-transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
431
- transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
432
- }
433
-
434
- 30%,
435
- 50%,
436
- 70%,
437
- 90% {
438
- -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
439
- transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
440
- }
441
-
442
- 40%,
443
- 60%,
444
- 80% {
445
- -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
446
- transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
447
- }
448
-
449
- to {
450
- -webkit-transform: scale3d(1, 1, 1);
451
- transform: scale3d(1, 1, 1);
452
- }
453
- }
454
-
455
- @keyframes tada {
456
- from {
457
- -webkit-transform: scale3d(1, 1, 1);
458
- transform: scale3d(1, 1, 1);
459
- }
460
-
461
- 10%,
462
- 20% {
463
- -webkit-transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
464
- transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
465
- }
466
-
467
- 30%,
468
- 50%,
469
- 70%,
470
- 90% {
471
- -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
472
- transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
473
- }
474
-
475
- 40%,
476
- 60%,
477
- 80% {
478
- -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
479
- transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
480
- }
481
-
482
- to {
483
- -webkit-transform: scale3d(1, 1, 1);
484
- transform: scale3d(1, 1, 1);
485
- }
486
- }
487
-
488
- .tada {
489
- -webkit-animation-name: tada;
490
- animation-name: tada;
491
- }
492
-
493
- /* originally authored by Nick Pettit - https://github.com/nickpettit/glide */
494
-
495
- @-webkit-keyframes wobble {
496
- from {
497
- -webkit-transform: translate3d(0, 0, 0);
498
- transform: translate3d(0, 0, 0);
499
- }
500
-
501
- 15% {
502
- -webkit-transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
503
- transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
504
- }
505
-
506
- 30% {
507
- -webkit-transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
508
- transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
509
- }
510
-
511
- 45% {
512
- -webkit-transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
513
- transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
514
- }
515
-
516
- 60% {
517
- -webkit-transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
518
- transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
519
- }
520
-
521
- 75% {
522
- -webkit-transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
523
- transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
524
- }
525
-
526
- to {
527
- -webkit-transform: translate3d(0, 0, 0);
528
- transform: translate3d(0, 0, 0);
529
- }
530
- }
531
-
532
- @keyframes wobble {
533
- from {
534
- -webkit-transform: translate3d(0, 0, 0);
535
- transform: translate3d(0, 0, 0);
536
- }
537
-
538
- 15% {
539
- -webkit-transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
540
- transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
541
- }
542
-
543
- 30% {
544
- -webkit-transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
545
- transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
546
- }
547
-
548
- 45% {
549
- -webkit-transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
550
- transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
551
- }
552
-
553
- 60% {
554
- -webkit-transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
555
- transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
556
- }
557
-
558
- 75% {
559
- -webkit-transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
560
- transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
561
- }
562
-
563
- to {
564
- -webkit-transform: translate3d(0, 0, 0);
565
- transform: translate3d(0, 0, 0);
566
- }
567
- }
568
-
569
- .wobble {
570
- -webkit-animation-name: wobble;
571
- animation-name: wobble;
572
- }
573
-
574
- @-webkit-keyframes jello {
575
- from,
576
- 11.1%,
577
- to {
578
- -webkit-transform: translate3d(0, 0, 0);
579
- transform: translate3d(0, 0, 0);
580
- }
581
-
582
- 22.2% {
583
- -webkit-transform: skewX(-12.5deg) skewY(-12.5deg);
584
- transform: skewX(-12.5deg) skewY(-12.5deg);
585
- }
586
-
587
- 33.3% {
588
- -webkit-transform: skewX(6.25deg) skewY(6.25deg);
589
- transform: skewX(6.25deg) skewY(6.25deg);
590
- }
591
-
592
- 44.4% {
593
- -webkit-transform: skewX(-3.125deg) skewY(-3.125deg);
594
- transform: skewX(-3.125deg) skewY(-3.125deg);
595
- }
596
-
597
- 55.5% {
598
- -webkit-transform: skewX(1.5625deg) skewY(1.5625deg);
599
- transform: skewX(1.5625deg) skewY(1.5625deg);
600
- }
601
-
602
- 66.6% {
603
- -webkit-transform: skewX(-0.78125deg) skewY(-0.78125deg);
604
- transform: skewX(-0.78125deg) skewY(-0.78125deg);
605
- }
606
-
607
- 77.7% {
608
- -webkit-transform: skewX(0.390625deg) skewY(0.390625deg);
609
- transform: skewX(0.390625deg) skewY(0.390625deg);
610
- }
611
-
612
- 88.8% {
613
- -webkit-transform: skewX(-0.1953125deg) skewY(-0.1953125deg);
614
- transform: skewX(-0.1953125deg) skewY(-0.1953125deg);
615
- }
616
- }
617
-
618
- @keyframes jello {
619
- from,
620
- 11.1%,
621
- to {
622
- -webkit-transform: translate3d(0, 0, 0);
623
- transform: translate3d(0, 0, 0);
624
- }
625
-
626
- 22.2% {
627
- -webkit-transform: skewX(-12.5deg) skewY(-12.5deg);
628
- transform: skewX(-12.5deg) skewY(-12.5deg);
629
- }
630
-
631
- 33.3% {
632
- -webkit-transform: skewX(6.25deg) skewY(6.25deg);
633
- transform: skewX(6.25deg) skewY(6.25deg);
634
- }
635
-
636
- 44.4% {
637
- -webkit-transform: skewX(-3.125deg) skewY(-3.125deg);
638
- transform: skewX(-3.125deg) skewY(-3.125deg);
639
- }
640
-
641
- 55.5% {
642
- -webkit-transform: skewX(1.5625deg) skewY(1.5625deg);
643
- transform: skewX(1.5625deg) skewY(1.5625deg);
644
- }
645
-
646
- 66.6% {
647
- -webkit-transform: skewX(-0.78125deg) skewY(-0.78125deg);
648
- transform: skewX(-0.78125deg) skewY(-0.78125deg);
649
- }
650
-
651
- 77.7% {
652
- -webkit-transform: skewX(0.390625deg) skewY(0.390625deg);
653
- transform: skewX(0.390625deg) skewY(0.390625deg);
654
- }
655
-
656
- 88.8% {
657
- -webkit-transform: skewX(-0.1953125deg) skewY(-0.1953125deg);
658
- transform: skewX(-0.1953125deg) skewY(-0.1953125deg);
659
- }
660
- }
661
-
662
- .jello {
663
- -webkit-animation-name: jello;
664
- animation-name: jello;
665
- -webkit-transform-origin: center;
666
- transform-origin: center;
667
- }
668
-
669
- @-webkit-keyframes heartBeat {
670
- 0% {
671
- -webkit-transform: scale(1);
672
- transform: scale(1);
673
- }
674
-
675
- 14% {
676
- -webkit-transform: scale(1.3);
677
- transform: scale(1.3);
678
- }
679
-
680
- 28% {
681
- -webkit-transform: scale(1);
682
- transform: scale(1);
683
- }
684
-
685
- 42% {
686
- -webkit-transform: scale(1.3);
687
- transform: scale(1.3);
688
- }
689
-
690
- 70% {
691
- -webkit-transform: scale(1);
692
- transform: scale(1);
693
- }
694
- }
695
-
696
- @keyframes heartBeat {
697
- 0% {
698
- -webkit-transform: scale(1);
699
- transform: scale(1);
700
- }
701
-
702
- 14% {
703
- -webkit-transform: scale(1.3);
704
- transform: scale(1.3);
705
- }
706
-
707
- 28% {
708
- -webkit-transform: scale(1);
709
- transform: scale(1);
710
- }
711
-
712
- 42% {
713
- -webkit-transform: scale(1.3);
714
- transform: scale(1.3);
715
- }
716
-
717
- 70% {
718
- -webkit-transform: scale(1);
719
- transform: scale(1);
720
- }
721
- }
722
-
723
- .heartBeat {
724
- -webkit-animation-name: heartBeat;
725
- animation-name: heartBeat;
726
- -webkit-animation-duration: 1.3s;
727
- animation-duration: 1.3s;
728
- -webkit-animation-timing-function: ease-in-out;
729
- animation-timing-function: ease-in-out;
730
- }
731
-
732
- @-webkit-keyframes bounceIn {
733
- from,
734
- 20%,
735
- 40%,
736
- 60%,
737
- 80%,
738
- to {
739
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
740
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
741
- }
742
-
743
- 0% {
744
- opacity: 0;
745
- -webkit-transform: scale3d(0.3, 0.3, 0.3);
746
- transform: scale3d(0.3, 0.3, 0.3);
747
- }
748
-
749
- 20% {
750
- -webkit-transform: scale3d(1.1, 1.1, 1.1);
751
- transform: scale3d(1.1, 1.1, 1.1);
752
- }
753
-
754
- 40% {
755
- -webkit-transform: scale3d(0.9, 0.9, 0.9);
756
- transform: scale3d(0.9, 0.9, 0.9);
757
- }
758
-
759
- 60% {
760
- opacity: 1;
761
- -webkit-transform: scale3d(1.03, 1.03, 1.03);
762
- transform: scale3d(1.03, 1.03, 1.03);
763
- }
764
-
765
- 80% {
766
- -webkit-transform: scale3d(0.97, 0.97, 0.97);
767
- transform: scale3d(0.97, 0.97, 0.97);
768
- }
769
-
770
- to {
771
- opacity: 1;
772
- -webkit-transform: scale3d(1, 1, 1);
773
- transform: scale3d(1, 1, 1);
774
- }
775
- }
776
-
777
- @keyframes bounceIn {
778
- from,
779
- 20%,
780
- 40%,
781
- 60%,
782
- 80%,
783
- to {
784
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
785
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
786
- }
787
-
788
- 0% {
789
- opacity: 0;
790
- -webkit-transform: scale3d(0.3, 0.3, 0.3);
791
- transform: scale3d(0.3, 0.3, 0.3);
792
- }
793
-
794
- 20% {
795
- -webkit-transform: scale3d(1.1, 1.1, 1.1);
796
- transform: scale3d(1.1, 1.1, 1.1);
797
- }
798
-
799
- 40% {
800
- -webkit-transform: scale3d(0.9, 0.9, 0.9);
801
- transform: scale3d(0.9, 0.9, 0.9);
802
- }
803
-
804
- 60% {
805
- opacity: 1;
806
- -webkit-transform: scale3d(1.03, 1.03, 1.03);
807
- transform: scale3d(1.03, 1.03, 1.03);
808
- }
809
-
810
- 80% {
811
- -webkit-transform: scale3d(0.97, 0.97, 0.97);
812
- transform: scale3d(0.97, 0.97, 0.97);
813
- }
814
-
815
- to {
816
- opacity: 1;
817
- -webkit-transform: scale3d(1, 1, 1);
818
- transform: scale3d(1, 1, 1);
819
- }
820
- }
821
-
822
- .bounceIn {
823
- -webkit-animation-duration: 0.75s;
824
- animation-duration: 0.75s;
825
- -webkit-animation-name: bounceIn;
826
- animation-name: bounceIn;
827
- }
828
-
829
- @-webkit-keyframes bounceInDown {
830
- from,
831
- 60%,
832
- 75%,
833
- 90%,
834
- to {
835
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
836
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
837
- }
838
-
839
- 0% {
840
- opacity: 0;
841
- -webkit-transform: translate3d(0, -3000px, 0);
842
- transform: translate3d(0, -3000px, 0);
843
- }
844
-
845
- 60% {
846
- opacity: 1;
847
- -webkit-transform: translate3d(0, 25px, 0);
848
- transform: translate3d(0, 25px, 0);
849
- }
850
-
851
- 75% {
852
- -webkit-transform: translate3d(0, -10px, 0);
853
- transform: translate3d(0, -10px, 0);
854
- }
855
-
856
- 90% {
857
- -webkit-transform: translate3d(0, 5px, 0);
858
- transform: translate3d(0, 5px, 0);
859
- }
860
-
861
- to {
862
- -webkit-transform: translate3d(0, 0, 0);
863
- transform: translate3d(0, 0, 0);
864
- }
865
- }
866
-
867
- @keyframes bounceInDown {
868
- from,
869
- 60%,
870
- 75%,
871
- 90%,
872
- to {
873
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
874
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
875
- }
876
-
877
- 0% {
878
- opacity: 0;
879
- -webkit-transform: translate3d(0, -3000px, 0);
880
- transform: translate3d(0, -3000px, 0);
881
- }
882
-
883
- 60% {
884
- opacity: 1;
885
- -webkit-transform: translate3d(0, 25px, 0);
886
- transform: translate3d(0, 25px, 0);
887
- }
888
-
889
- 75% {
890
- -webkit-transform: translate3d(0, -10px, 0);
891
- transform: translate3d(0, -10px, 0);
892
- }
893
-
894
- 90% {
895
- -webkit-transform: translate3d(0, 5px, 0);
896
- transform: translate3d(0, 5px, 0);
897
- }
898
-
899
- to {
900
- -webkit-transform: translate3d(0, 0, 0);
901
- transform: translate3d(0, 0, 0);
902
- }
903
- }
904
-
905
- .bounceInDown {
906
- -webkit-animation-name: bounceInDown;
907
- animation-name: bounceInDown;
908
- }
909
-
910
- @-webkit-keyframes bounceInLeft {
911
- from,
912
- 60%,
913
- 75%,
914
- 90%,
915
- to {
916
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
917
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
918
- }
919
-
920
- 0% {
921
- opacity: 0;
922
- -webkit-transform: translate3d(-3000px, 0, 0);
923
- transform: translate3d(-3000px, 0, 0);
924
- }
925
-
926
- 60% {
927
- opacity: 1;
928
- -webkit-transform: translate3d(25px, 0, 0);
929
- transform: translate3d(25px, 0, 0);
930
- }
931
-
932
- 75% {
933
- -webkit-transform: translate3d(-10px, 0, 0);
934
- transform: translate3d(-10px, 0, 0);
935
- }
936
-
937
- 90% {
938
- -webkit-transform: translate3d(5px, 0, 0);
939
- transform: translate3d(5px, 0, 0);
940
- }
941
-
942
- to {
943
- -webkit-transform: translate3d(0, 0, 0);
944
- transform: translate3d(0, 0, 0);
945
- }
946
- }
947
-
948
- @keyframes bounceInLeft {
949
- from,
950
- 60%,
951
- 75%,
952
- 90%,
953
- to {
954
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
955
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
956
- }
957
-
958
- 0% {
959
- opacity: 0;
960
- -webkit-transform: translate3d(-3000px, 0, 0);
961
- transform: translate3d(-3000px, 0, 0);
962
- }
963
-
964
- 60% {
965
- opacity: 1;
966
- -webkit-transform: translate3d(25px, 0, 0);
967
- transform: translate3d(25px, 0, 0);
968
- }
969
-
970
- 75% {
971
- -webkit-transform: translate3d(-10px, 0, 0);
972
- transform: translate3d(-10px, 0, 0);
973
- }
974
-
975
- 90% {
976
- -webkit-transform: translate3d(5px, 0, 0);
977
- transform: translate3d(5px, 0, 0);
978
- }
979
-
980
- to {
981
- -webkit-transform: translate3d(0, 0, 0);
982
- transform: translate3d(0, 0, 0);
983
- }
984
- }
985
-
986
- .bounceInLeft {
987
- -webkit-animation-name: bounceInLeft;
988
- animation-name: bounceInLeft;
989
- }
990
-
991
- @-webkit-keyframes bounceInRight {
992
- from,
993
- 60%,
994
- 75%,
995
- 90%,
996
- to {
997
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
998
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
999
- }
1000
-
1001
- from {
1002
- opacity: 0;
1003
- -webkit-transform: translate3d(3000px, 0, 0);
1004
- transform: translate3d(3000px, 0, 0);
1005
- }
1006
-
1007
- 60% {
1008
- opacity: 1;
1009
- -webkit-transform: translate3d(-25px, 0, 0);
1010
- transform: translate3d(-25px, 0, 0);
1011
- }
1012
-
1013
- 75% {
1014
- -webkit-transform: translate3d(10px, 0, 0);
1015
- transform: translate3d(10px, 0, 0);
1016
- }
1017
-
1018
- 90% {
1019
- -webkit-transform: translate3d(-5px, 0, 0);
1020
- transform: translate3d(-5px, 0, 0);
1021
- }
1022
-
1023
- to {
1024
- -webkit-transform: translate3d(0, 0, 0);
1025
- transform: translate3d(0, 0, 0);
1026
- }
1027
- }
1028
-
1029
- @keyframes bounceInRight {
1030
- from,
1031
- 60%,
1032
- 75%,
1033
- 90%,
1034
- to {
1035
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
1036
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
1037
- }
1038
-
1039
- from {
1040
- opacity: 0;
1041
- -webkit-transform: translate3d(3000px, 0, 0);
1042
- transform: translate3d(3000px, 0, 0);
1043
- }
1044
-
1045
- 60% {
1046
- opacity: 1;
1047
- -webkit-transform: translate3d(-25px, 0, 0);
1048
- transform: translate3d(-25px, 0, 0);
1049
- }
1050
-
1051
- 75% {
1052
- -webkit-transform: translate3d(10px, 0, 0);
1053
- transform: translate3d(10px, 0, 0);
1054
- }
1055
-
1056
- 90% {
1057
- -webkit-transform: translate3d(-5px, 0, 0);
1058
- transform: translate3d(-5px, 0, 0);
1059
- }
1060
-
1061
- to {
1062
- -webkit-transform: translate3d(0, 0, 0);
1063
- transform: translate3d(0, 0, 0);
1064
- }
1065
- }
1066
-
1067
- .bounceInRight {
1068
- -webkit-animation-name: bounceInRight;
1069
- animation-name: bounceInRight;
1070
- }
1071
-
1072
- @-webkit-keyframes bounceInUp {
1073
- from,
1074
- 60%,
1075
- 75%,
1076
- 90%,
1077
- to {
1078
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
1079
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
1080
- }
1081
-
1082
- from {
1083
- opacity: 0;
1084
- -webkit-transform: translate3d(0, 3000px, 0);
1085
- transform: translate3d(0, 3000px, 0);
1086
- }
1087
-
1088
- 60% {
1089
- opacity: 1;
1090
- -webkit-transform: translate3d(0, -20px, 0);
1091
- transform: translate3d(0, -20px, 0);
1092
- }
1093
-
1094
- 75% {
1095
- -webkit-transform: translate3d(0, 10px, 0);
1096
- transform: translate3d(0, 10px, 0);
1097
- }
1098
-
1099
- 90% {
1100
- -webkit-transform: translate3d(0, -5px, 0);
1101
- transform: translate3d(0, -5px, 0);
1102
- }
1103
-
1104
- to {
1105
- -webkit-transform: translate3d(0, 0, 0);
1106
- transform: translate3d(0, 0, 0);
1107
- }
1108
- }
1109
-
1110
- @keyframes bounceInUp {
1111
- from,
1112
- 60%,
1113
- 75%,
1114
- 90%,
1115
- to {
1116
- -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
1117
- animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
1118
- }
1119
-
1120
- from {
1121
- opacity: 0;
1122
- -webkit-transform: translate3d(0, 3000px, 0);
1123
- transform: translate3d(0, 3000px, 0);
1124
- }
1125
-
1126
- 60% {
1127
- opacity: 1;
1128
- -webkit-transform: translate3d(0, -20px, 0);
1129
- transform: translate3d(0, -20px, 0);
1130
- }
1131
-
1132
- 75% {
1133
- -webkit-transform: translate3d(0, 10px, 0);
1134
- transform: translate3d(0, 10px, 0);
1135
- }
1136
-
1137
- 90% {
1138
- -webkit-transform: translate3d(0, -5px, 0);
1139
- transform: translate3d(0, -5px, 0);
1140
- }
1141
-
1142
- to {
1143
- -webkit-transform: translate3d(0, 0, 0);
1144
- transform: translate3d(0, 0, 0);
1145
- }
1146
- }
1147
-
1148
- .bounceInUp {
1149
- -webkit-animation-name: bounceInUp;
1150
- animation-name: bounceInUp;
1151
- }
1152
-
1153
- @-webkit-keyframes bounceOut {
1154
- 20% {
1155
- -webkit-transform: scale3d(0.9, 0.9, 0.9);
1156
- transform: scale3d(0.9, 0.9, 0.9);
1157
- }
1158
-
1159
- 50%,
1160
- 55% {
1161
- opacity: 1;
1162
- -webkit-transform: scale3d(1.1, 1.1, 1.1);
1163
- transform: scale3d(1.1, 1.1, 1.1);
1164
- }
1165
-
1166
- to {
1167
- opacity: 0;
1168
- -webkit-transform: scale3d(0.3, 0.3, 0.3);
1169
- transform: scale3d(0.3, 0.3, 0.3);
1170
- }
1171
- }
1172
-
1173
- @keyframes bounceOut {
1174
- 20% {
1175
- -webkit-transform: scale3d(0.9, 0.9, 0.9);
1176
- transform: scale3d(0.9, 0.9, 0.9);
1177
- }
1178
-
1179
- 50%,
1180
- 55% {
1181
- opacity: 1;
1182
- -webkit-transform: scale3d(1.1, 1.1, 1.1);
1183
- transform: scale3d(1.1, 1.1, 1.1);
1184
- }
1185
-
1186
- to {
1187
- opacity: 0;
1188
- -webkit-transform: scale3d(0.3, 0.3, 0.3);
1189
- transform: scale3d(0.3, 0.3, 0.3);
1190
- }
1191
- }
1192
-
1193
- .bounceOut {
1194
- -webkit-animation-duration: 0.75s;
1195
- animation-duration: 0.75s;
1196
- -webkit-animation-name: bounceOut;
1197
- animation-name: bounceOut;
1198
- }
1199
-
1200
- @-webkit-keyframes bounceOutDown {
1201
- 20% {
1202
- -webkit-transform: translate3d(0, 10px, 0);
1203
- transform: translate3d(0, 10px, 0);
1204
- }
1205
-
1206
- 40%,
1207
- 45% {
1208
- opacity: 1;
1209
- -webkit-transform: translate3d(0, -20px, 0);
1210
- transform: translate3d(0, -20px, 0);
1211
- }
1212
-
1213
- to {
1214
- opacity: 0;
1215
- -webkit-transform: translate3d(0, 2000px, 0);
1216
- transform: translate3d(0, 2000px, 0);
1217
- }
1218
- }
1219
-
1220
- @keyframes bounceOutDown {
1221
- 20% {
1222
- -webkit-transform: translate3d(0, 10px, 0);
1223
- transform: translate3d(0, 10px, 0);
1224
- }
1225
-
1226
- 40%,
1227
- 45% {
1228
- opacity: 1;
1229
- -webkit-transform: translate3d(0, -20px, 0);
1230
- transform: translate3d(0, -20px, 0);
1231
- }
1232
-
1233
- to {
1234
- opacity: 0;
1235
- -webkit-transform: translate3d(0, 2000px, 0);
1236
- transform: translate3d(0, 2000px, 0);
1237
- }
1238
- }
1239
-
1240
- .bounceOutDown {
1241
- -webkit-animation-name: bounceOutDown;
1242
- animation-name: bounceOutDown;
1243
- }
1244
-
1245
- @-webkit-keyframes bounceOutLeft {
1246
- 20% {
1247
- opacity: 1;
1248
- -webkit-transform: translate3d(20px, 0, 0);
1249
- transform: translate3d(20px, 0, 0);
1250
- }
1251
-
1252
- to {
1253
- opacity: 0;
1254
- -webkit-transform: translate3d(-2000px, 0, 0);
1255
- transform: translate3d(-2000px, 0, 0);
1256
- }
1257
- }
1258
-
1259
- @keyframes bounceOutLeft {
1260
- 20% {
1261
- opacity: 1;
1262
- -webkit-transform: translate3d(20px, 0, 0);
1263
- transform: translate3d(20px, 0, 0);
1264
- }
1265
-
1266
- to {
1267
- opacity: 0;
1268
- -webkit-transform: translate3d(-2000px, 0, 0);
1269
- transform: translate3d(-2000px, 0, 0);
1270
- }
1271
- }
1272
-
1273
- .bounceOutLeft {
1274
- -webkit-animation-name: bounceOutLeft;
1275
- animation-name: bounceOutLeft;
1276
- }
1277
-
1278
- @-webkit-keyframes bounceOutRight {
1279
- 20% {
1280
- opacity: 1;
1281
- -webkit-transform: translate3d(-20px, 0, 0);
1282
- transform: translate3d(-20px, 0, 0);
1283
- }
1284
-
1285
- to {
1286
- opacity: 0;
1287
- -webkit-transform: translate3d(2000px, 0, 0);
1288
- transform: translate3d(2000px, 0, 0);
1289
- }
1290
- }
1291
-
1292
- @keyframes bounceOutRight {
1293
- 20% {
1294
- opacity: 1;
1295
- -webkit-transform: translate3d(-20px, 0, 0);
1296
- transform: translate3d(-20px, 0, 0);
1297
- }
1298
-
1299
- to {
1300
- opacity: 0;
1301
- -webkit-transform: translate3d(2000px, 0, 0);
1302
- transform: translate3d(2000px, 0, 0);
1303
- }
1304
- }
1305
-
1306
- .bounceOutRight {
1307
- -webkit-animation-name: bounceOutRight;
1308
- animation-name: bounceOutRight;
1309
- }
1310
-
1311
- @-webkit-keyframes bounceOutUp {
1312
- 20% {
1313
- -webkit-transform: translate3d(0, -10px, 0);
1314
- transform: translate3d(0, -10px, 0);
1315
- }
1316
-
1317
- 40%,
1318
- 45% {
1319
- opacity: 1;
1320
- -webkit-transform: translate3d(0, 20px, 0);
1321
- transform: translate3d(0, 20px, 0);
1322
- }
1323
-
1324
- to {
1325
- opacity: 0;
1326
- -webkit-transform: translate3d(0, -2000px, 0);
1327
- transform: translate3d(0, -2000px, 0);
1328
- }
1329
- }
1330
-
1331
- @keyframes bounceOutUp {
1332
- 20% {
1333
- -webkit-transform: translate3d(0, -10px, 0);
1334
- transform: translate3d(0, -10px, 0);
1335
- }
1336
-
1337
- 40%,
1338
- 45% {
1339
- opacity: 1;
1340
- -webkit-transform: translate3d(0, 20px, 0);
1341
- transform: translate3d(0, 20px, 0);
1342
- }
1343
-
1344
- to {
1345
- opacity: 0;
1346
- -webkit-transform: translate3d(0, -2000px, 0);
1347
- transform: translate3d(0, -2000px, 0);
1348
- }
1349
- }
1350
-
1351
- .bounceOutUp {
1352
- -webkit-animation-name: bounceOutUp;
1353
- animation-name: bounceOutUp;
1354
- }
1355
-
1356
- @-webkit-keyframes fadeIn {
1357
- from {
1358
- opacity: 0;
1359
- }
1360
-
1361
- to {
1362
- opacity: 1;
1363
- }
1364
- }
1365
-
1366
- @keyframes fadeIn {
1367
- from {
1368
- opacity: 0;
1369
- }
1370
-
1371
- to {
1372
- opacity: 1;
1373
- }
1374
- }
1375
-
1376
- .fadeIn {
1377
- -webkit-animation-name: fadeIn;
1378
- animation-name: fadeIn;
1379
- }
1380
-
1381
- @-webkit-keyframes fadeInDown {
1382
- from {
1383
- opacity: 0;
1384
- -webkit-transform: translate3d(0, -100%, 0);
1385
- transform: translate3d(0, -100%, 0);
1386
- }
1387
-
1388
- to {
1389
- opacity: 1;
1390
- -webkit-transform: translate3d(0, 0, 0);
1391
- transform: translate3d(0, 0, 0);
1392
- }
1393
- }
1394
-
1395
- @keyframes fadeInDown {
1396
- from {
1397
- opacity: 0;
1398
- -webkit-transform: translate3d(0, -100%, 0);
1399
- transform: translate3d(0, -100%, 0);
1400
- }
1401
-
1402
- to {
1403
- opacity: 1;
1404
- -webkit-transform: translate3d(0, 0, 0);
1405
- transform: translate3d(0, 0, 0);
1406
- }
1407
- }
1408
-
1409
- .fadeInDown {
1410
- -webkit-animation-name: fadeInDown;
1411
- animation-name: fadeInDown;
1412
- }
1413
-
1414
- @-webkit-keyframes fadeInDownBig {
1415
- from {
1416
- opacity: 0;
1417
- -webkit-transform: translate3d(0, -2000px, 0);
1418
- transform: translate3d(0, -2000px, 0);
1419
- }
1420
-
1421
- to {
1422
- opacity: 1;
1423
- -webkit-transform: translate3d(0, 0, 0);
1424
- transform: translate3d(0, 0, 0);
1425
- }
1426
- }
1427
-
1428
- @keyframes fadeInDownBig {
1429
- from {
1430
- opacity: 0;
1431
- -webkit-transform: translate3d(0, -2000px, 0);
1432
- transform: translate3d(0, -2000px, 0);
1433
- }
1434
-
1435
- to {
1436
- opacity: 1;
1437
- -webkit-transform: translate3d(0, 0, 0);
1438
- transform: translate3d(0, 0, 0);
1439
- }
1440
- }
1441
-
1442
- .fadeInDownBig {
1443
- -webkit-animation-name: fadeInDownBig;
1444
- animation-name: fadeInDownBig;
1445
- }
1446
-
1447
- @-webkit-keyframes fadeInLeft {
1448
- from {
1449
- opacity: 0;
1450
- -webkit-transform: translate3d(-100%, 0, 0);
1451
- transform: translate3d(-100%, 0, 0);
1452
- }
1453
-
1454
- to {
1455
- opacity: 1;
1456
- -webkit-transform: translate3d(0, 0, 0);
1457
- transform: translate3d(0, 0, 0);
1458
- }
1459
- }
1460
-
1461
- @keyframes fadeInLeft {
1462
- from {
1463
- opacity: 0;
1464
- -webkit-transform: translate3d(-100%, 0, 0);
1465
- transform: translate3d(-100%, 0, 0);
1466
- }
1467
-
1468
- to {
1469
- opacity: 1;
1470
- -webkit-transform: translate3d(0, 0, 0);
1471
- transform: translate3d(0, 0, 0);
1472
- }
1473
- }
1474
-
1475
- .fadeInLeft {
1476
- -webkit-animation-name: fadeInLeft;
1477
- animation-name: fadeInLeft;
1478
- }
1479
-
1480
- @-webkit-keyframes fadeInLeftBig {
1481
- from {
1482
- opacity: 0;
1483
- -webkit-transform: translate3d(-2000px, 0, 0);
1484
- transform: translate3d(-2000px, 0, 0);
1485
- }
1486
-
1487
- to {
1488
- opacity: 1;
1489
- -webkit-transform: translate3d(0, 0, 0);
1490
- transform: translate3d(0, 0, 0);
1491
- }
1492
- }
1493
-
1494
- @keyframes fadeInLeftBig {
1495
- from {
1496
- opacity: 0;
1497
- -webkit-transform: translate3d(-2000px, 0, 0);
1498
- transform: translate3d(-2000px, 0, 0);
1499
- }
1500
-
1501
- to {
1502
- opacity: 1;
1503
- -webkit-transform: translate3d(0, 0, 0);
1504
- transform: translate3d(0, 0, 0);
1505
- }
1506
- }
1507
-
1508
- .fadeInLeftBig {
1509
- -webkit-animation-name: fadeInLeftBig;
1510
- animation-name: fadeInLeftBig;
1511
- }
1512
-
1513
- @-webkit-keyframes fadeInRight {
1514
- from {
1515
- opacity: 0;
1516
- -webkit-transform: translate3d(100%, 0, 0);
1517
- transform: translate3d(100%, 0, 0);
1518
- }
1519
-
1520
- to {
1521
- opacity: 1;
1522
- -webkit-transform: translate3d(0, 0, 0);
1523
- transform: translate3d(0, 0, 0);
1524
- }
1525
- }
1526
-
1527
- @keyframes fadeInRight {
1528
- from {
1529
- opacity: 0;
1530
- -webkit-transform: translate3d(100%, 0, 0);
1531
- transform: translate3d(100%, 0, 0);
1532
- }
1533
-
1534
- to {
1535
- opacity: 1;
1536
- -webkit-transform: translate3d(0, 0, 0);
1537
- transform: translate3d(0, 0, 0);
1538
- }
1539
- }
1540
-
1541
- .fadeInRight {
1542
- -webkit-animation-name: fadeInRight;
1543
- animation-name: fadeInRight;
1544
- }
1545
-
1546
- @-webkit-keyframes fadeInRightBig {
1547
- from {
1548
- opacity: 0;
1549
- -webkit-transform: translate3d(2000px, 0, 0);
1550
- transform: translate3d(2000px, 0, 0);
1551
- }
1552
-
1553
- to {
1554
- opacity: 1;
1555
- -webkit-transform: translate3d(0, 0, 0);
1556
- transform: translate3d(0, 0, 0);
1557
- }
1558
- }
1559
-
1560
- @keyframes fadeInRightBig {
1561
- from {
1562
- opacity: 0;
1563
- -webkit-transform: translate3d(2000px, 0, 0);
1564
- transform: translate3d(2000px, 0, 0);
1565
- }
1566
-
1567
- to {
1568
- opacity: 1;
1569
- -webkit-transform: translate3d(0, 0, 0);
1570
- transform: translate3d(0, 0, 0);
1571
- }
1572
- }
1573
-
1574
- .fadeInRightBig {
1575
- -webkit-animation-name: fadeInRightBig;
1576
- animation-name: fadeInRightBig;
1577
- }
1578
-
1579
- @-webkit-keyframes fadeInUp {
1580
- from {
1581
- opacity: 0;
1582
- -webkit-transform: translate3d(0, 100%, 0);
1583
- transform: translate3d(0, 100%, 0);
1584
- }
1585
-
1586
- to {
1587
- opacity: 1;
1588
- -webkit-transform: translate3d(0, 0, 0);
1589
- transform: translate3d(0, 0, 0);
1590
- }
1591
- }
1592
-
1593
- @keyframes fadeInUp {
1594
- from {
1595
- opacity: 0;
1596
- -webkit-transform: translate3d(0, 100%, 0);
1597
- transform: translate3d(0, 100%, 0);
1598
- }
1599
-
1600
- to {
1601
- opacity: 1;
1602
- -webkit-transform: translate3d(0, 0, 0);
1603
- transform: translate3d(0, 0, 0);
1604
- }
1605
- }
1606
-
1607
- .fadeInUp {
1608
- -webkit-animation-name: fadeInUp;
1609
- animation-name: fadeInUp;
1610
- }
1611
-
1612
- @-webkit-keyframes fadeInUpBig {
1613
- from {
1614
- opacity: 0;
1615
- -webkit-transform: translate3d(0, 2000px, 0);
1616
- transform: translate3d(0, 2000px, 0);
1617
- }
1618
-
1619
- to {
1620
- opacity: 1;
1621
- -webkit-transform: translate3d(0, 0, 0);
1622
- transform: translate3d(0, 0, 0);
1623
- }
1624
- }
1625
-
1626
- @keyframes fadeInUpBig {
1627
- from {
1628
- opacity: 0;
1629
- -webkit-transform: translate3d(0, 2000px, 0);
1630
- transform: translate3d(0, 2000px, 0);
1631
- }
1632
-
1633
- to {
1634
- opacity: 1;
1635
- -webkit-transform: translate3d(0, 0, 0);
1636
- transform: translate3d(0, 0, 0);
1637
- }
1638
- }
1639
-
1640
- .fadeInUpBig {
1641
- -webkit-animation-name: fadeInUpBig;
1642
- animation-name: fadeInUpBig;
1643
- }
1644
-
1645
- @-webkit-keyframes fadeOut {
1646
- from {
1647
- opacity: 1;
1648
- }
1649
-
1650
- to {
1651
- opacity: 0;
1652
- }
1653
- }
1654
-
1655
- @keyframes fadeOut {
1656
- from {
1657
- opacity: 1;
1658
- }
1659
-
1660
- to {
1661
- opacity: 0;
1662
- }
1663
- }
1664
-
1665
- .fadeOut {
1666
- -webkit-animation-name: fadeOut;
1667
- animation-name: fadeOut;
1668
- }
1669
-
1670
- @-webkit-keyframes fadeOutDown {
1671
- from {
1672
- opacity: 1;
1673
- }
1674
-
1675
- to {
1676
- opacity: 0;
1677
- -webkit-transform: translate3d(0, 100%, 0);
1678
- transform: translate3d(0, 100%, 0);
1679
- }
1680
- }
1681
-
1682
- @keyframes fadeOutDown {
1683
- from {
1684
- opacity: 1;
1685
- }
1686
-
1687
- to {
1688
- opacity: 0;
1689
- -webkit-transform: translate3d(0, 100%, 0);
1690
- transform: translate3d(0, 100%, 0);
1691
- }
1692
- }
1693
-
1694
- .fadeOutDown {
1695
- -webkit-animation-name: fadeOutDown;
1696
- animation-name: fadeOutDown;
1697
- }
1698
-
1699
- @-webkit-keyframes fadeOutDownBig {
1700
- from {
1701
- opacity: 1;
1702
- }
1703
-
1704
- to {
1705
- opacity: 0;
1706
- -webkit-transform: translate3d(0, 2000px, 0);
1707
- transform: translate3d(0, 2000px, 0);
1708
- }
1709
- }
1710
-
1711
- @keyframes fadeOutDownBig {
1712
- from {
1713
- opacity: 1;
1714
- }
1715
-
1716
- to {
1717
- opacity: 0;
1718
- -webkit-transform: translate3d(0, 2000px, 0);
1719
- transform: translate3d(0, 2000px, 0);
1720
- }
1721
- }
1722
-
1723
- .fadeOutDownBig {
1724
- -webkit-animation-name: fadeOutDownBig;
1725
- animation-name: fadeOutDownBig;
1726
- }
1727
-
1728
- @-webkit-keyframes fadeOutLeft {
1729
- from {
1730
- opacity: 1;
1731
- }
1732
-
1733
- to {
1734
- opacity: 0;
1735
- -webkit-transform: translate3d(-100%, 0, 0);
1736
- transform: translate3d(-100%, 0, 0);
1737
- }
1738
- }
1739
-
1740
- @keyframes fadeOutLeft {
1741
- from {
1742
- opacity: 1;
1743
- }
1744
-
1745
- to {
1746
- opacity: 0;
1747
- -webkit-transform: translate3d(-100%, 0, 0);
1748
- transform: translate3d(-100%, 0, 0);
1749
- }
1750
- }
1751
-
1752
- .fadeOutLeft {
1753
- -webkit-animation-name: fadeOutLeft;
1754
- animation-name: fadeOutLeft;
1755
- }
1756
-
1757
- @-webkit-keyframes fadeOutLeftBig {
1758
- from {
1759
- opacity: 1;
1760
- }
1761
-
1762
- to {
1763
- opacity: 0;
1764
- -webkit-transform: translate3d(-2000px, 0, 0);
1765
- transform: translate3d(-2000px, 0, 0);
1766
- }
1767
- }
1768
-
1769
- @keyframes fadeOutLeftBig {
1770
- from {
1771
- opacity: 1;
1772
- }
1773
-
1774
- to {
1775
- opacity: 0;
1776
- -webkit-transform: translate3d(-2000px, 0, 0);
1777
- transform: translate3d(-2000px, 0, 0);
1778
- }
1779
- }
1780
-
1781
- .fadeOutLeftBig {
1782
- -webkit-animation-name: fadeOutLeftBig;
1783
- animation-name: fadeOutLeftBig;
1784
- }
1785
-
1786
- @-webkit-keyframes fadeOutRight {
1787
- from {
1788
- opacity: 1;
1789
- }
1790
-
1791
- to {
1792
- opacity: 0;
1793
- -webkit-transform: translate3d(100%, 0, 0);
1794
- transform: translate3d(100%, 0, 0);
1795
- }
1796
- }
1797
-
1798
- @keyframes fadeOutRight {
1799
- from {
1800
- opacity: 1;
1801
- }
1802
-
1803
- to {
1804
- opacity: 0;
1805
- -webkit-transform: translate3d(100%, 0, 0);
1806
- transform: translate3d(100%, 0, 0);
1807
- }
1808
- }
1809
-
1810
- .fadeOutRight {
1811
- -webkit-animation-name: fadeOutRight;
1812
- animation-name: fadeOutRight;
1813
- }
1814
-
1815
- @-webkit-keyframes fadeOutRightBig {
1816
- from {
1817
- opacity: 1;
1818
- }
1819
-
1820
- to {
1821
- opacity: 0;
1822
- -webkit-transform: translate3d(2000px, 0, 0);
1823
- transform: translate3d(2000px, 0, 0);
1824
- }
1825
- }
1826
-
1827
- @keyframes fadeOutRightBig {
1828
- from {
1829
- opacity: 1;
1830
- }
1831
-
1832
- to {
1833
- opacity: 0;
1834
- -webkit-transform: translate3d(2000px, 0, 0);
1835
- transform: translate3d(2000px, 0, 0);
1836
- }
1837
- }
1838
-
1839
- .fadeOutRightBig {
1840
- -webkit-animation-name: fadeOutRightBig;
1841
- animation-name: fadeOutRightBig;
1842
- }
1843
-
1844
- @-webkit-keyframes fadeOutUp {
1845
- from {
1846
- opacity: 1;
1847
- }
1848
-
1849
- to {
1850
- opacity: 0;
1851
- -webkit-transform: translate3d(0, -100%, 0);
1852
- transform: translate3d(0, -100%, 0);
1853
- }
1854
- }
1855
-
1856
- @keyframes fadeOutUp {
1857
- from {
1858
- opacity: 1;
1859
- }
1860
-
1861
- to {
1862
- opacity: 0;
1863
- -webkit-transform: translate3d(0, -100%, 0);
1864
- transform: translate3d(0, -100%, 0);
1865
- }
1866
- }
1867
-
1868
- .fadeOutUp {
1869
- -webkit-animation-name: fadeOutUp;
1870
- animation-name: fadeOutUp;
1871
- }
1872
-
1873
- @-webkit-keyframes fadeOutUpBig {
1874
- from {
1875
- opacity: 1;
1876
- }
1877
-
1878
- to {
1879
- opacity: 0;
1880
- -webkit-transform: translate3d(0, -2000px, 0);
1881
- transform: translate3d(0, -2000px, 0);
1882
- }
1883
- }
1884
-
1885
- @keyframes fadeOutUpBig {
1886
- from {
1887
- opacity: 1;
1888
- }
1889
-
1890
- to {
1891
- opacity: 0;
1892
- -webkit-transform: translate3d(0, -2000px, 0);
1893
- transform: translate3d(0, -2000px, 0);
1894
- }
1895
- }
1896
-
1897
- .fadeOutUpBig {
1898
- -webkit-animation-name: fadeOutUpBig;
1899
- animation-name: fadeOutUpBig;
1900
- }
1901
-
1902
- @-webkit-keyframes flip {
1903
- from {
1904
- -webkit-transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 0)
1905
- rotate3d(0, 1, 0, -360deg);
1906
- transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 0) rotate3d(0, 1, 0, -360deg);
1907
- -webkit-animation-timing-function: ease-out;
1908
- animation-timing-function: ease-out;
1909
- }
1910
-
1911
- 40% {
1912
- -webkit-transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 150px)
1913
- rotate3d(0, 1, 0, -190deg);
1914
- transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 150px)
1915
- rotate3d(0, 1, 0, -190deg);
1916
- -webkit-animation-timing-function: ease-out;
1917
- animation-timing-function: ease-out;
1918
- }
1919
-
1920
- 50% {
1921
- -webkit-transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 150px)
1922
- rotate3d(0, 1, 0, -170deg);
1923
- transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 150px)
1924
- rotate3d(0, 1, 0, -170deg);
1925
- -webkit-animation-timing-function: ease-in;
1926
- animation-timing-function: ease-in;
1927
- }
1928
-
1929
- 80% {
1930
- -webkit-transform: perspective(400px) scale3d(0.95, 0.95, 0.95) translate3d(0, 0, 0)
1931
- rotate3d(0, 1, 0, 0deg);
1932
- transform: perspective(400px) scale3d(0.95, 0.95, 0.95) translate3d(0, 0, 0)
1933
- rotate3d(0, 1, 0, 0deg);
1934
- -webkit-animation-timing-function: ease-in;
1935
- animation-timing-function: ease-in;
1936
- }
1937
-
1938
- to {
1939
- -webkit-transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 0)
1940
- rotate3d(0, 1, 0, 0deg);
1941
- transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 0) rotate3d(0, 1, 0, 0deg);
1942
- -webkit-animation-timing-function: ease-in;
1943
- animation-timing-function: ease-in;
1944
- }
1945
- }
1946
-
1947
- @keyframes flip {
1948
- from {
1949
- -webkit-transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 0)
1950
- rotate3d(0, 1, 0, -360deg);
1951
- transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 0) rotate3d(0, 1, 0, -360deg);
1952
- -webkit-animation-timing-function: ease-out;
1953
- animation-timing-function: ease-out;
1954
- }
1955
-
1956
- 40% {
1957
- -webkit-transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 150px)
1958
- rotate3d(0, 1, 0, -190deg);
1959
- transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 150px)
1960
- rotate3d(0, 1, 0, -190deg);
1961
- -webkit-animation-timing-function: ease-out;
1962
- animation-timing-function: ease-out;
1963
- }
1964
-
1965
- 50% {
1966
- -webkit-transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 150px)
1967
- rotate3d(0, 1, 0, -170deg);
1968
- transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 150px)
1969
- rotate3d(0, 1, 0, -170deg);
1970
- -webkit-animation-timing-function: ease-in;
1971
- animation-timing-function: ease-in;
1972
- }
1973
-
1974
- 80% {
1975
- -webkit-transform: perspective(400px) scale3d(0.95, 0.95, 0.95) translate3d(0, 0, 0)
1976
- rotate3d(0, 1, 0, 0deg);
1977
- transform: perspective(400px) scale3d(0.95, 0.95, 0.95) translate3d(0, 0, 0)
1978
- rotate3d(0, 1, 0, 0deg);
1979
- -webkit-animation-timing-function: ease-in;
1980
- animation-timing-function: ease-in;
1981
- }
1982
-
1983
- to {
1984
- -webkit-transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 0)
1985
- rotate3d(0, 1, 0, 0deg);
1986
- transform: perspective(400px) scale3d(1, 1, 1) translate3d(0, 0, 0) rotate3d(0, 1, 0, 0deg);
1987
- -webkit-animation-timing-function: ease-in;
1988
- animation-timing-function: ease-in;
1989
- }
1990
- }
1991
-
1992
- .animated.flip {
1993
- -webkit-backface-visibility: visible;
1994
- backface-visibility: visible;
1995
- -webkit-animation-name: flip;
1996
- animation-name: flip;
1997
- }
1998
-
1999
- @-webkit-keyframes flipInX {
2000
- from {
2001
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, 90deg);
2002
- transform: perspective(400px) rotate3d(1, 0, 0, 90deg);
2003
- -webkit-animation-timing-function: ease-in;
2004
- animation-timing-function: ease-in;
2005
- opacity: 0;
2006
- }
2007
-
2008
- 40% {
2009
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, -20deg);
2010
- transform: perspective(400px) rotate3d(1, 0, 0, -20deg);
2011
- -webkit-animation-timing-function: ease-in;
2012
- animation-timing-function: ease-in;
2013
- }
2014
-
2015
- 60% {
2016
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, 10deg);
2017
- transform: perspective(400px) rotate3d(1, 0, 0, 10deg);
2018
- opacity: 1;
2019
- }
2020
-
2021
- 80% {
2022
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, -5deg);
2023
- transform: perspective(400px) rotate3d(1, 0, 0, -5deg);
2024
- }
2025
-
2026
- to {
2027
- -webkit-transform: perspective(400px);
2028
- transform: perspective(400px);
2029
- }
2030
- }
2031
-
2032
- @keyframes flipInX {
2033
- from {
2034
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, 90deg);
2035
- transform: perspective(400px) rotate3d(1, 0, 0, 90deg);
2036
- -webkit-animation-timing-function: ease-in;
2037
- animation-timing-function: ease-in;
2038
- opacity: 0;
2039
- }
2040
-
2041
- 40% {
2042
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, -20deg);
2043
- transform: perspective(400px) rotate3d(1, 0, 0, -20deg);
2044
- -webkit-animation-timing-function: ease-in;
2045
- animation-timing-function: ease-in;
2046
- }
2047
-
2048
- 60% {
2049
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, 10deg);
2050
- transform: perspective(400px) rotate3d(1, 0, 0, 10deg);
2051
- opacity: 1;
2052
- }
2053
-
2054
- 80% {
2055
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, -5deg);
2056
- transform: perspective(400px) rotate3d(1, 0, 0, -5deg);
2057
- }
2058
-
2059
- to {
2060
- -webkit-transform: perspective(400px);
2061
- transform: perspective(400px);
2062
- }
2063
- }
2064
-
2065
- .flipInX {
2066
- -webkit-backface-visibility: visible !important;
2067
- backface-visibility: visible !important;
2068
- -webkit-animation-name: flipInX;
2069
- animation-name: flipInX;
2070
- }
2071
-
2072
- @-webkit-keyframes flipInY {
2073
- from {
2074
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, 90deg);
2075
- transform: perspective(400px) rotate3d(0, 1, 0, 90deg);
2076
- -webkit-animation-timing-function: ease-in;
2077
- animation-timing-function: ease-in;
2078
- opacity: 0;
2079
- }
2080
-
2081
- 40% {
2082
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, -20deg);
2083
- transform: perspective(400px) rotate3d(0, 1, 0, -20deg);
2084
- -webkit-animation-timing-function: ease-in;
2085
- animation-timing-function: ease-in;
2086
- }
2087
-
2088
- 60% {
2089
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, 10deg);
2090
- transform: perspective(400px) rotate3d(0, 1, 0, 10deg);
2091
- opacity: 1;
2092
- }
2093
-
2094
- 80% {
2095
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, -5deg);
2096
- transform: perspective(400px) rotate3d(0, 1, 0, -5deg);
2097
- }
2098
-
2099
- to {
2100
- -webkit-transform: perspective(400px);
2101
- transform: perspective(400px);
2102
- }
2103
- }
2104
-
2105
- @keyframes flipInY {
2106
- from {
2107
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, 90deg);
2108
- transform: perspective(400px) rotate3d(0, 1, 0, 90deg);
2109
- -webkit-animation-timing-function: ease-in;
2110
- animation-timing-function: ease-in;
2111
- opacity: 0;
2112
- }
2113
-
2114
- 40% {
2115
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, -20deg);
2116
- transform: perspective(400px) rotate3d(0, 1, 0, -20deg);
2117
- -webkit-animation-timing-function: ease-in;
2118
- animation-timing-function: ease-in;
2119
- }
2120
-
2121
- 60% {
2122
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, 10deg);
2123
- transform: perspective(400px) rotate3d(0, 1, 0, 10deg);
2124
- opacity: 1;
2125
- }
2126
-
2127
- 80% {
2128
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, -5deg);
2129
- transform: perspective(400px) rotate3d(0, 1, 0, -5deg);
2130
- }
2131
-
2132
- to {
2133
- -webkit-transform: perspective(400px);
2134
- transform: perspective(400px);
2135
- }
2136
- }
2137
-
2138
- .flipInY {
2139
- -webkit-backface-visibility: visible !important;
2140
- backface-visibility: visible !important;
2141
- -webkit-animation-name: flipInY;
2142
- animation-name: flipInY;
2143
- }
2144
-
2145
- @-webkit-keyframes flipOutX {
2146
- from {
2147
- -webkit-transform: perspective(400px);
2148
- transform: perspective(400px);
2149
- }
2150
-
2151
- 30% {
2152
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, -20deg);
2153
- transform: perspective(400px) rotate3d(1, 0, 0, -20deg);
2154
- opacity: 1;
2155
- }
2156
-
2157
- to {
2158
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, 90deg);
2159
- transform: perspective(400px) rotate3d(1, 0, 0, 90deg);
2160
- opacity: 0;
2161
- }
2162
- }
2163
-
2164
- @keyframes flipOutX {
2165
- from {
2166
- -webkit-transform: perspective(400px);
2167
- transform: perspective(400px);
2168
- }
2169
-
2170
- 30% {
2171
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, -20deg);
2172
- transform: perspective(400px) rotate3d(1, 0, 0, -20deg);
2173
- opacity: 1;
2174
- }
2175
-
2176
- to {
2177
- -webkit-transform: perspective(400px) rotate3d(1, 0, 0, 90deg);
2178
- transform: perspective(400px) rotate3d(1, 0, 0, 90deg);
2179
- opacity: 0;
2180
- }
2181
- }
2182
-
2183
- .flipOutX {
2184
- -webkit-animation-duration: 0.75s;
2185
- animation-duration: 0.75s;
2186
- -webkit-animation-name: flipOutX;
2187
- animation-name: flipOutX;
2188
- -webkit-backface-visibility: visible !important;
2189
- backface-visibility: visible !important;
2190
- }
2191
-
2192
- @-webkit-keyframes flipOutY {
2193
- from {
2194
- -webkit-transform: perspective(400px);
2195
- transform: perspective(400px);
2196
- }
2197
-
2198
- 30% {
2199
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, -15deg);
2200
- transform: perspective(400px) rotate3d(0, 1, 0, -15deg);
2201
- opacity: 1;
2202
- }
2203
-
2204
- to {
2205
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, 90deg);
2206
- transform: perspective(400px) rotate3d(0, 1, 0, 90deg);
2207
- opacity: 0;
2208
- }
2209
- }
2210
-
2211
- @keyframes flipOutY {
2212
- from {
2213
- -webkit-transform: perspective(400px);
2214
- transform: perspective(400px);
2215
- }
2216
-
2217
- 30% {
2218
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, -15deg);
2219
- transform: perspective(400px) rotate3d(0, 1, 0, -15deg);
2220
- opacity: 1;
2221
- }
2222
-
2223
- to {
2224
- -webkit-transform: perspective(400px) rotate3d(0, 1, 0, 90deg);
2225
- transform: perspective(400px) rotate3d(0, 1, 0, 90deg);
2226
- opacity: 0;
2227
- }
2228
- }
2229
-
2230
- .flipOutY {
2231
- -webkit-animation-duration: 0.75s;
2232
- animation-duration: 0.75s;
2233
- -webkit-backface-visibility: visible !important;
2234
- backface-visibility: visible !important;
2235
- -webkit-animation-name: flipOutY;
2236
- animation-name: flipOutY;
2237
- }
2238
-
2239
- @-webkit-keyframes lightSpeedIn {
2240
- from {
2241
- -webkit-transform: translate3d(100%, 0, 0) skewX(-30deg);
2242
- transform: translate3d(100%, 0, 0) skewX(-30deg);
2243
- opacity: 0;
2244
- }
2245
-
2246
- 60% {
2247
- -webkit-transform: skewX(20deg);
2248
- transform: skewX(20deg);
2249
- opacity: 1;
2250
- }
2251
-
2252
- 80% {
2253
- -webkit-transform: skewX(-5deg);
2254
- transform: skewX(-5deg);
2255
- }
2256
-
2257
- to {
2258
- -webkit-transform: translate3d(0, 0, 0);
2259
- transform: translate3d(0, 0, 0);
2260
- }
2261
- }
2262
-
2263
- @keyframes lightSpeedIn {
2264
- from {
2265
- -webkit-transform: translate3d(100%, 0, 0) skewX(-30deg);
2266
- transform: translate3d(100%, 0, 0) skewX(-30deg);
2267
- opacity: 0;
2268
- }
2269
-
2270
- 60% {
2271
- -webkit-transform: skewX(20deg);
2272
- transform: skewX(20deg);
2273
- opacity: 1;
2274
- }
2275
-
2276
- 80% {
2277
- -webkit-transform: skewX(-5deg);
2278
- transform: skewX(-5deg);
2279
- }
2280
-
2281
- to {
2282
- -webkit-transform: translate3d(0, 0, 0);
2283
- transform: translate3d(0, 0, 0);
2284
- }
2285
- }
2286
-
2287
- .lightSpeedIn {
2288
- -webkit-animation-name: lightSpeedIn;
2289
- animation-name: lightSpeedIn;
2290
- -webkit-animation-timing-function: ease-out;
2291
- animation-timing-function: ease-out;
2292
- }
2293
-
2294
- @-webkit-keyframes lightSpeedOut {
2295
- from {
2296
- opacity: 1;
2297
- }
2298
-
2299
- to {
2300
- -webkit-transform: translate3d(100%, 0, 0) skewX(30deg);
2301
- transform: translate3d(100%, 0, 0) skewX(30deg);
2302
- opacity: 0;
2303
- }
2304
- }
2305
-
2306
- @keyframes lightSpeedOut {
2307
- from {
2308
- opacity: 1;
2309
- }
2310
-
2311
- to {
2312
- -webkit-transform: translate3d(100%, 0, 0) skewX(30deg);
2313
- transform: translate3d(100%, 0, 0) skewX(30deg);
2314
- opacity: 0;
2315
- }
2316
- }
2317
-
2318
- .lightSpeedOut {
2319
- -webkit-animation-name: lightSpeedOut;
2320
- animation-name: lightSpeedOut;
2321
- -webkit-animation-timing-function: ease-in;
2322
- animation-timing-function: ease-in;
2323
- }
2324
-
2325
- @-webkit-keyframes rotateIn {
2326
- from {
2327
- -webkit-transform-origin: center;
2328
- transform-origin: center;
2329
- -webkit-transform: rotate3d(0, 0, 1, -200deg);
2330
- transform: rotate3d(0, 0, 1, -200deg);
2331
- opacity: 0;
2332
- }
2333
-
2334
- to {
2335
- -webkit-transform-origin: center;
2336
- transform-origin: center;
2337
- -webkit-transform: translate3d(0, 0, 0);
2338
- transform: translate3d(0, 0, 0);
2339
- opacity: 1;
2340
- }
2341
- }
2342
-
2343
- @keyframes rotateIn {
2344
- from {
2345
- -webkit-transform-origin: center;
2346
- transform-origin: center;
2347
- -webkit-transform: rotate3d(0, 0, 1, -200deg);
2348
- transform: rotate3d(0, 0, 1, -200deg);
2349
- opacity: 0;
2350
- }
2351
-
2352
- to {
2353
- -webkit-transform-origin: center;
2354
- transform-origin: center;
2355
- -webkit-transform: translate3d(0, 0, 0);
2356
- transform: translate3d(0, 0, 0);
2357
- opacity: 1;
2358
- }
2359
- }
2360
-
2361
- .rotateIn {
2362
- -webkit-animation-name: rotateIn;
2363
- animation-name: rotateIn;
2364
- }
2365
-
2366
- @-webkit-keyframes rotateInDownLeft {
2367
- from {
2368
- -webkit-transform-origin: left bottom;
2369
- transform-origin: left bottom;
2370
- -webkit-transform: rotate3d(0, 0, 1, -45deg);
2371
- transform: rotate3d(0, 0, 1, -45deg);
2372
- opacity: 0;
2373
- }
2374
-
2375
- to {
2376
- -webkit-transform-origin: left bottom;
2377
- transform-origin: left bottom;
2378
- -webkit-transform: translate3d(0, 0, 0);
2379
- transform: translate3d(0, 0, 0);
2380
- opacity: 1;
2381
- }
2382
- }
2383
-
2384
- @keyframes rotateInDownLeft {
2385
- from {
2386
- -webkit-transform-origin: left bottom;
2387
- transform-origin: left bottom;
2388
- -webkit-transform: rotate3d(0, 0, 1, -45deg);
2389
- transform: rotate3d(0, 0, 1, -45deg);
2390
- opacity: 0;
2391
- }
2392
-
2393
- to {
2394
- -webkit-transform-origin: left bottom;
2395
- transform-origin: left bottom;
2396
- -webkit-transform: translate3d(0, 0, 0);
2397
- transform: translate3d(0, 0, 0);
2398
- opacity: 1;
2399
- }
2400
- }
2401
-
2402
- .rotateInDownLeft {
2403
- -webkit-animation-name: rotateInDownLeft;
2404
- animation-name: rotateInDownLeft;
2405
- }
2406
-
2407
- @-webkit-keyframes rotateInDownRight {
2408
- from {
2409
- -webkit-transform-origin: right bottom;
2410
- transform-origin: right bottom;
2411
- -webkit-transform: rotate3d(0, 0, 1, 45deg);
2412
- transform: rotate3d(0, 0, 1, 45deg);
2413
- opacity: 0;
2414
- }
2415
-
2416
- to {
2417
- -webkit-transform-origin: right bottom;
2418
- transform-origin: right bottom;
2419
- -webkit-transform: translate3d(0, 0, 0);
2420
- transform: translate3d(0, 0, 0);
2421
- opacity: 1;
2422
- }
2423
- }
2424
-
2425
- @keyframes rotateInDownRight {
2426
- from {
2427
- -webkit-transform-origin: right bottom;
2428
- transform-origin: right bottom;
2429
- -webkit-transform: rotate3d(0, 0, 1, 45deg);
2430
- transform: rotate3d(0, 0, 1, 45deg);
2431
- opacity: 0;
2432
- }
2433
-
2434
- to {
2435
- -webkit-transform-origin: right bottom;
2436
- transform-origin: right bottom;
2437
- -webkit-transform: translate3d(0, 0, 0);
2438
- transform: translate3d(0, 0, 0);
2439
- opacity: 1;
2440
- }
2441
- }
2442
-
2443
- .rotateInDownRight {
2444
- -webkit-animation-name: rotateInDownRight;
2445
- animation-name: rotateInDownRight;
2446
- }
2447
-
2448
- @-webkit-keyframes rotateInUpLeft {
2449
- from {
2450
- -webkit-transform-origin: left bottom;
2451
- transform-origin: left bottom;
2452
- -webkit-transform: rotate3d(0, 0, 1, 45deg);
2453
- transform: rotate3d(0, 0, 1, 45deg);
2454
- opacity: 0;
2455
- }
2456
-
2457
- to {
2458
- -webkit-transform-origin: left bottom;
2459
- transform-origin: left bottom;
2460
- -webkit-transform: translate3d(0, 0, 0);
2461
- transform: translate3d(0, 0, 0);
2462
- opacity: 1;
2463
- }
2464
- }
2465
-
2466
- @keyframes rotateInUpLeft {
2467
- from {
2468
- -webkit-transform-origin: left bottom;
2469
- transform-origin: left bottom;
2470
- -webkit-transform: rotate3d(0, 0, 1, 45deg);
2471
- transform: rotate3d(0, 0, 1, 45deg);
2472
- opacity: 0;
2473
- }
2474
-
2475
- to {
2476
- -webkit-transform-origin: left bottom;
2477
- transform-origin: left bottom;
2478
- -webkit-transform: translate3d(0, 0, 0);
2479
- transform: translate3d(0, 0, 0);
2480
- opacity: 1;
2481
- }
2482
- }
2483
-
2484
- .rotateInUpLeft {
2485
- -webkit-animation-name: rotateInUpLeft;
2486
- animation-name: rotateInUpLeft;
2487
- }
2488
-
2489
- @-webkit-keyframes rotateInUpRight {
2490
- from {
2491
- -webkit-transform-origin: right bottom;
2492
- transform-origin: right bottom;
2493
- -webkit-transform: rotate3d(0, 0, 1, -90deg);
2494
- transform: rotate3d(0, 0, 1, -90deg);
2495
- opacity: 0;
2496
- }
2497
-
2498
- to {
2499
- -webkit-transform-origin: right bottom;
2500
- transform-origin: right bottom;
2501
- -webkit-transform: translate3d(0, 0, 0);
2502
- transform: translate3d(0, 0, 0);
2503
- opacity: 1;
2504
- }
2505
- }
2506
-
2507
- @keyframes rotateInUpRight {
2508
- from {
2509
- -webkit-transform-origin: right bottom;
2510
- transform-origin: right bottom;
2511
- -webkit-transform: rotate3d(0, 0, 1, -90deg);
2512
- transform: rotate3d(0, 0, 1, -90deg);
2513
- opacity: 0;
2514
- }
2515
-
2516
- to {
2517
- -webkit-transform-origin: right bottom;
2518
- transform-origin: right bottom;
2519
- -webkit-transform: translate3d(0, 0, 0);
2520
- transform: translate3d(0, 0, 0);
2521
- opacity: 1;
2522
- }
2523
- }
2524
-
2525
- .rotateInUpRight {
2526
- -webkit-animation-name: rotateInUpRight;
2527
- animation-name: rotateInUpRight;
2528
- }
2529
-
2530
- @-webkit-keyframes rotateOut {
2531
- from {
2532
- -webkit-transform-origin: center;
2533
- transform-origin: center;
2534
- opacity: 1;
2535
- }
2536
-
2537
- to {
2538
- -webkit-transform-origin: center;
2539
- transform-origin: center;
2540
- -webkit-transform: rotate3d(0, 0, 1, 200deg);
2541
- transform: rotate3d(0, 0, 1, 200deg);
2542
- opacity: 0;
2543
- }
2544
- }
2545
-
2546
- @keyframes rotateOut {
2547
- from {
2548
- -webkit-transform-origin: center;
2549
- transform-origin: center;
2550
- opacity: 1;
2551
- }
2552
-
2553
- to {
2554
- -webkit-transform-origin: center;
2555
- transform-origin: center;
2556
- -webkit-transform: rotate3d(0, 0, 1, 200deg);
2557
- transform: rotate3d(0, 0, 1, 200deg);
2558
- opacity: 0;
2559
- }
2560
- }
2561
-
2562
- .rotateOut {
2563
- -webkit-animation-name: rotateOut;
2564
- animation-name: rotateOut;
2565
- }
2566
-
2567
- @-webkit-keyframes rotateOutDownLeft {
2568
- from {
2569
- -webkit-transform-origin: left bottom;
2570
- transform-origin: left bottom;
2571
- opacity: 1;
2572
- }
2573
-
2574
- to {
2575
- -webkit-transform-origin: left bottom;
2576
- transform-origin: left bottom;
2577
- -webkit-transform: rotate3d(0, 0, 1, 45deg);
2578
- transform: rotate3d(0, 0, 1, 45deg);
2579
- opacity: 0;
2580
- }
2581
- }
2582
-
2583
- @keyframes rotateOutDownLeft {
2584
- from {
2585
- -webkit-transform-origin: left bottom;
2586
- transform-origin: left bottom;
2587
- opacity: 1;
2588
- }
2589
-
2590
- to {
2591
- -webkit-transform-origin: left bottom;
2592
- transform-origin: left bottom;
2593
- -webkit-transform: rotate3d(0, 0, 1, 45deg);
2594
- transform: rotate3d(0, 0, 1, 45deg);
2595
- opacity: 0;
2596
- }
2597
- }
2598
-
2599
- .rotateOutDownLeft {
2600
- -webkit-animation-name: rotateOutDownLeft;
2601
- animation-name: rotateOutDownLeft;
2602
- }
2603
-
2604
- @-webkit-keyframes rotateOutDownRight {
2605
- from {
2606
- -webkit-transform-origin: right bottom;
2607
- transform-origin: right bottom;
2608
- opacity: 1;
2609
- }
2610
-
2611
- to {
2612
- -webkit-transform-origin: right bottom;
2613
- transform-origin: right bottom;
2614
- -webkit-transform: rotate3d(0, 0, 1, -45deg);
2615
- transform: rotate3d(0, 0, 1, -45deg);
2616
- opacity: 0;
2617
- }
2618
- }
2619
-
2620
- @keyframes rotateOutDownRight {
2621
- from {
2622
- -webkit-transform-origin: right bottom;
2623
- transform-origin: right bottom;
2624
- opacity: 1;
2625
- }
2626
-
2627
- to {
2628
- -webkit-transform-origin: right bottom;
2629
- transform-origin: right bottom;
2630
- -webkit-transform: rotate3d(0, 0, 1, -45deg);
2631
- transform: rotate3d(0, 0, 1, -45deg);
2632
- opacity: 0;
2633
- }
2634
- }
2635
-
2636
- .rotateOutDownRight {
2637
- -webkit-animation-name: rotateOutDownRight;
2638
- animation-name: rotateOutDownRight;
2639
- }
2640
-
2641
- @-webkit-keyframes rotateOutUpLeft {
2642
- from {
2643
- -webkit-transform-origin: left bottom;
2644
- transform-origin: left bottom;
2645
- opacity: 1;
2646
- }
2647
-
2648
- to {
2649
- -webkit-transform-origin: left bottom;
2650
- transform-origin: left bottom;
2651
- -webkit-transform: rotate3d(0, 0, 1, -45deg);
2652
- transform: rotate3d(0, 0, 1, -45deg);
2653
- opacity: 0;
2654
- }
2655
- }
2656
-
2657
- @keyframes rotateOutUpLeft {
2658
- from {
2659
- -webkit-transform-origin: left bottom;
2660
- transform-origin: left bottom;
2661
- opacity: 1;
2662
- }
2663
-
2664
- to {
2665
- -webkit-transform-origin: left bottom;
2666
- transform-origin: left bottom;
2667
- -webkit-transform: rotate3d(0, 0, 1, -45deg);
2668
- transform: rotate3d(0, 0, 1, -45deg);
2669
- opacity: 0;
2670
- }
2671
- }
2672
-
2673
- .rotateOutUpLeft {
2674
- -webkit-animation-name: rotateOutUpLeft;
2675
- animation-name: rotateOutUpLeft;
2676
- }
2677
-
2678
- @-webkit-keyframes rotateOutUpRight {
2679
- from {
2680
- -webkit-transform-origin: right bottom;
2681
- transform-origin: right bottom;
2682
- opacity: 1;
2683
- }
2684
-
2685
- to {
2686
- -webkit-transform-origin: right bottom;
2687
- transform-origin: right bottom;
2688
- -webkit-transform: rotate3d(0, 0, 1, 90deg);
2689
- transform: rotate3d(0, 0, 1, 90deg);
2690
- opacity: 0;
2691
- }
2692
- }
2693
-
2694
- @keyframes rotateOutUpRight {
2695
- from {
2696
- -webkit-transform-origin: right bottom;
2697
- transform-origin: right bottom;
2698
- opacity: 1;
2699
- }
2700
-
2701
- to {
2702
- -webkit-transform-origin: right bottom;
2703
- transform-origin: right bottom;
2704
- -webkit-transform: rotate3d(0, 0, 1, 90deg);
2705
- transform: rotate3d(0, 0, 1, 90deg);
2706
- opacity: 0;
2707
- }
2708
- }
2709
-
2710
- .rotateOutUpRight {
2711
- -webkit-animation-name: rotateOutUpRight;
2712
- animation-name: rotateOutUpRight;
2713
- }
2714
-
2715
- @-webkit-keyframes hinge {
2716
- 0% {
2717
- -webkit-transform-origin: top left;
2718
- transform-origin: top left;
2719
- -webkit-animation-timing-function: ease-in-out;
2720
- animation-timing-function: ease-in-out;
2721
- }
2722
-
2723
- 20%,
2724
- 60% {
2725
- -webkit-transform: rotate3d(0, 0, 1, 80deg);
2726
- transform: rotate3d(0, 0, 1, 80deg);
2727
- -webkit-transform-origin: top left;
2728
- transform-origin: top left;
2729
- -webkit-animation-timing-function: ease-in-out;
2730
- animation-timing-function: ease-in-out;
2731
- }
2732
-
2733
- 40%,
2734
- 80% {
2735
- -webkit-transform: rotate3d(0, 0, 1, 60deg);
2736
- transform: rotate3d(0, 0, 1, 60deg);
2737
- -webkit-transform-origin: top left;
2738
- transform-origin: top left;
2739
- -webkit-animation-timing-function: ease-in-out;
2740
- animation-timing-function: ease-in-out;
2741
- opacity: 1;
2742
- }
2743
-
2744
- to {
2745
- -webkit-transform: translate3d(0, 700px, 0);
2746
- transform: translate3d(0, 700px, 0);
2747
- opacity: 0;
2748
- }
2749
- }
2750
-
2751
- @keyframes hinge {
2752
- 0% {
2753
- -webkit-transform-origin: top left;
2754
- transform-origin: top left;
2755
- -webkit-animation-timing-function: ease-in-out;
2756
- animation-timing-function: ease-in-out;
2757
- }
2758
-
2759
- 20%,
2760
- 60% {
2761
- -webkit-transform: rotate3d(0, 0, 1, 80deg);
2762
- transform: rotate3d(0, 0, 1, 80deg);
2763
- -webkit-transform-origin: top left;
2764
- transform-origin: top left;
2765
- -webkit-animation-timing-function: ease-in-out;
2766
- animation-timing-function: ease-in-out;
2767
- }
2768
-
2769
- 40%,
2770
- 80% {
2771
- -webkit-transform: rotate3d(0, 0, 1, 60deg);
2772
- transform: rotate3d(0, 0, 1, 60deg);
2773
- -webkit-transform-origin: top left;
2774
- transform-origin: top left;
2775
- -webkit-animation-timing-function: ease-in-out;
2776
- animation-timing-function: ease-in-out;
2777
- opacity: 1;
2778
- }
2779
-
2780
- to {
2781
- -webkit-transform: translate3d(0, 700px, 0);
2782
- transform: translate3d(0, 700px, 0);
2783
- opacity: 0;
2784
- }
2785
- }
2786
-
2787
- .hinge {
2788
- -webkit-animation-duration: 2s;
2789
- animation-duration: 2s;
2790
- -webkit-animation-name: hinge;
2791
- animation-name: hinge;
2792
- }
2793
-
2794
- @-webkit-keyframes jackInTheBox {
2795
- from {
2796
- opacity: 0;
2797
- -webkit-transform: scale(0.1) rotate(30deg);
2798
- transform: scale(0.1) rotate(30deg);
2799
- -webkit-transform-origin: center bottom;
2800
- transform-origin: center bottom;
2801
- }
2802
-
2803
- 50% {
2804
- -webkit-transform: rotate(-10deg);
2805
- transform: rotate(-10deg);
2806
- }
2807
-
2808
- 70% {
2809
- -webkit-transform: rotate(3deg);
2810
- transform: rotate(3deg);
2811
- }
2812
-
2813
- to {
2814
- opacity: 1;
2815
- -webkit-transform: scale(1);
2816
- transform: scale(1);
2817
- }
2818
- }
2819
-
2820
- @keyframes jackInTheBox {
2821
- from {
2822
- opacity: 0;
2823
- -webkit-transform: scale(0.1) rotate(30deg);
2824
- transform: scale(0.1) rotate(30deg);
2825
- -webkit-transform-origin: center bottom;
2826
- transform-origin: center bottom;
2827
- }
2828
-
2829
- 50% {
2830
- -webkit-transform: rotate(-10deg);
2831
- transform: rotate(-10deg);
2832
- }
2833
-
2834
- 70% {
2835
- -webkit-transform: rotate(3deg);
2836
- transform: rotate(3deg);
2837
- }
2838
-
2839
- to {
2840
- opacity: 1;
2841
- -webkit-transform: scale(1);
2842
- transform: scale(1);
2843
- }
2844
- }
2845
-
2846
- .jackInTheBox {
2847
- -webkit-animation-name: jackInTheBox;
2848
- animation-name: jackInTheBox;
2849
- }
2850
-
2851
- /* originally authored by Nick Pettit - https://github.com/nickpettit/glide */
2852
-
2853
- @-webkit-keyframes rollIn {
2854
- from {
2855
- opacity: 0;
2856
- -webkit-transform: translate3d(-100%, 0, 0) rotate3d(0, 0, 1, -120deg);
2857
- transform: translate3d(-100%, 0, 0) rotate3d(0, 0, 1, -120deg);
2858
- }
2859
-
2860
- to {
2861
- opacity: 1;
2862
- -webkit-transform: translate3d(0, 0, 0);
2863
- transform: translate3d(0, 0, 0);
2864
- }
2865
- }
2866
-
2867
- @keyframes rollIn {
2868
- from {
2869
- opacity: 0;
2870
- -webkit-transform: translate3d(-100%, 0, 0) rotate3d(0, 0, 1, -120deg);
2871
- transform: translate3d(-100%, 0, 0) rotate3d(0, 0, 1, -120deg);
2872
- }
2873
-
2874
- to {
2875
- opacity: 1;
2876
- -webkit-transform: translate3d(0, 0, 0);
2877
- transform: translate3d(0, 0, 0);
2878
- }
2879
- }
2880
-
2881
- .rollIn {
2882
- -webkit-animation-name: rollIn;
2883
- animation-name: rollIn;
2884
- }
2885
-
2886
- /* originally authored by Nick Pettit - https://github.com/nickpettit/glide */
2887
-
2888
- @-webkit-keyframes rollOut {
2889
- from {
2890
- opacity: 1;
2891
- }
2892
-
2893
- to {
2894
- opacity: 0;
2895
- -webkit-transform: translate3d(100%, 0, 0) rotate3d(0, 0, 1, 120deg);
2896
- transform: translate3d(100%, 0, 0) rotate3d(0, 0, 1, 120deg);
2897
- }
2898
- }
2899
-
2900
- @keyframes rollOut {
2901
- from {
2902
- opacity: 1;
2903
- }
2904
-
2905
- to {
2906
- opacity: 0;
2907
- -webkit-transform: translate3d(100%, 0, 0) rotate3d(0, 0, 1, 120deg);
2908
- transform: translate3d(100%, 0, 0) rotate3d(0, 0, 1, 120deg);
2909
- }
2910
- }
2911
-
2912
- .rollOut {
2913
- -webkit-animation-name: rollOut;
2914
- animation-name: rollOut;
2915
- }
2916
-
2917
- @-webkit-keyframes zoomIn {
2918
- from {
2919
- opacity: 0;
2920
- -webkit-transform: scale3d(0.3, 0.3, 0.3);
2921
- transform: scale3d(0.3, 0.3, 0.3);
2922
- }
2923
-
2924
- 50% {
2925
- opacity: 1;
2926
- }
2927
- }
2928
-
2929
- @keyframes zoomIn {
2930
- from {
2931
- opacity: 0;
2932
- -webkit-transform: scale3d(0.3, 0.3, 0.3);
2933
- transform: scale3d(0.3, 0.3, 0.3);
2934
- }
2935
-
2936
- 50% {
2937
- opacity: 1;
2938
- }
2939
- }
2940
-
2941
- .zoomIn {
2942
- -webkit-animation-name: zoomIn;
2943
- animation-name: zoomIn;
2944
- }
2945
-
2946
- @-webkit-keyframes zoomInDown {
2947
- from {
2948
- opacity: 0;
2949
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);
2950
- transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);
2951
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
2952
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
2953
- }
2954
-
2955
- 60% {
2956
- opacity: 1;
2957
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
2958
- transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
2959
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
2960
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
2961
- }
2962
- }
2963
-
2964
- @keyframes zoomInDown {
2965
- from {
2966
- opacity: 0;
2967
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);
2968
- transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);
2969
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
2970
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
2971
- }
2972
-
2973
- 60% {
2974
- opacity: 1;
2975
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
2976
- transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
2977
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
2978
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
2979
- }
2980
- }
2981
-
2982
- .zoomInDown {
2983
- -webkit-animation-name: zoomInDown;
2984
- animation-name: zoomInDown;
2985
- }
2986
-
2987
- @-webkit-keyframes zoomInLeft {
2988
- from {
2989
- opacity: 0;
2990
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(-1000px, 0, 0);
2991
- transform: scale3d(0.1, 0.1, 0.1) translate3d(-1000px, 0, 0);
2992
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
2993
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
2994
- }
2995
-
2996
- 60% {
2997
- opacity: 1;
2998
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(10px, 0, 0);
2999
- transform: scale3d(0.475, 0.475, 0.475) translate3d(10px, 0, 0);
3000
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3001
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3002
- }
3003
- }
3004
-
3005
- @keyframes zoomInLeft {
3006
- from {
3007
- opacity: 0;
3008
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(-1000px, 0, 0);
3009
- transform: scale3d(0.1, 0.1, 0.1) translate3d(-1000px, 0, 0);
3010
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3011
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3012
- }
3013
-
3014
- 60% {
3015
- opacity: 1;
3016
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(10px, 0, 0);
3017
- transform: scale3d(0.475, 0.475, 0.475) translate3d(10px, 0, 0);
3018
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3019
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3020
- }
3021
- }
3022
-
3023
- .zoomInLeft {
3024
- -webkit-animation-name: zoomInLeft;
3025
- animation-name: zoomInLeft;
3026
- }
3027
-
3028
- @-webkit-keyframes zoomInRight {
3029
- from {
3030
- opacity: 0;
3031
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(1000px, 0, 0);
3032
- transform: scale3d(0.1, 0.1, 0.1) translate3d(1000px, 0, 0);
3033
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3034
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3035
- }
3036
-
3037
- 60% {
3038
- opacity: 1;
3039
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(-10px, 0, 0);
3040
- transform: scale3d(0.475, 0.475, 0.475) translate3d(-10px, 0, 0);
3041
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3042
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3043
- }
3044
- }
3045
-
3046
- @keyframes zoomInRight {
3047
- from {
3048
- opacity: 0;
3049
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(1000px, 0, 0);
3050
- transform: scale3d(0.1, 0.1, 0.1) translate3d(1000px, 0, 0);
3051
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3052
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3053
- }
3054
-
3055
- 60% {
3056
- opacity: 1;
3057
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(-10px, 0, 0);
3058
- transform: scale3d(0.475, 0.475, 0.475) translate3d(-10px, 0, 0);
3059
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3060
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3061
- }
3062
- }
3063
-
3064
- .zoomInRight {
3065
- -webkit-animation-name: zoomInRight;
3066
- animation-name: zoomInRight;
3067
- }
3068
-
3069
- @-webkit-keyframes zoomInUp {
3070
- from {
3071
- opacity: 0;
3072
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 1000px, 0);
3073
- transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 1000px, 0);
3074
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3075
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3076
- }
3077
-
3078
- 60% {
3079
- opacity: 1;
3080
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
3081
- transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
3082
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3083
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3084
- }
3085
- }
3086
-
3087
- @keyframes zoomInUp {
3088
- from {
3089
- opacity: 0;
3090
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 1000px, 0);
3091
- transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 1000px, 0);
3092
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3093
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3094
- }
3095
-
3096
- 60% {
3097
- opacity: 1;
3098
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
3099
- transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
3100
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3101
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3102
- }
3103
- }
3104
-
3105
- .zoomInUp {
3106
- -webkit-animation-name: zoomInUp;
3107
- animation-name: zoomInUp;
3108
- }
3109
-
3110
- @-webkit-keyframes zoomOut {
3111
- from {
3112
- opacity: 1;
3113
- }
3114
-
3115
- 50% {
3116
- opacity: 0;
3117
- -webkit-transform: scale3d(0.3, 0.3, 0.3);
3118
- transform: scale3d(0.3, 0.3, 0.3);
3119
- }
3120
-
3121
- to {
3122
- opacity: 0;
3123
- }
3124
- }
3125
-
3126
- @keyframes zoomOut {
3127
- from {
3128
- opacity: 1;
3129
- }
3130
-
3131
- 50% {
3132
- opacity: 0;
3133
- -webkit-transform: scale3d(0.3, 0.3, 0.3);
3134
- transform: scale3d(0.3, 0.3, 0.3);
3135
- }
3136
-
3137
- to {
3138
- opacity: 0;
3139
- }
3140
- }
3141
-
3142
- .zoomOut {
3143
- -webkit-animation-name: zoomOut;
3144
- animation-name: zoomOut;
3145
- }
3146
-
3147
- @-webkit-keyframes zoomOutDown {
3148
- 40% {
3149
- opacity: 1;
3150
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
3151
- transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
3152
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3153
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3154
- }
3155
-
3156
- to {
3157
- opacity: 0;
3158
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 2000px, 0);
3159
- transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 2000px, 0);
3160
- -webkit-transform-origin: center bottom;
3161
- transform-origin: center bottom;
3162
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3163
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3164
- }
3165
- }
3166
-
3167
- @keyframes zoomOutDown {
3168
- 40% {
3169
- opacity: 1;
3170
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
3171
- transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
3172
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3173
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3174
- }
3175
-
3176
- to {
3177
- opacity: 0;
3178
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 2000px, 0);
3179
- transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 2000px, 0);
3180
- -webkit-transform-origin: center bottom;
3181
- transform-origin: center bottom;
3182
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3183
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3184
- }
3185
- }
3186
-
3187
- .zoomOutDown {
3188
- -webkit-animation-name: zoomOutDown;
3189
- animation-name: zoomOutDown;
3190
- }
3191
-
3192
- @-webkit-keyframes zoomOutLeft {
3193
- 40% {
3194
- opacity: 1;
3195
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(42px, 0, 0);
3196
- transform: scale3d(0.475, 0.475, 0.475) translate3d(42px, 0, 0);
3197
- }
3198
-
3199
- to {
3200
- opacity: 0;
3201
- -webkit-transform: scale(0.1) translate3d(-2000px, 0, 0);
3202
- transform: scale(0.1) translate3d(-2000px, 0, 0);
3203
- -webkit-transform-origin: left center;
3204
- transform-origin: left center;
3205
- }
3206
- }
3207
-
3208
- @keyframes zoomOutLeft {
3209
- 40% {
3210
- opacity: 1;
3211
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(42px, 0, 0);
3212
- transform: scale3d(0.475, 0.475, 0.475) translate3d(42px, 0, 0);
3213
- }
3214
-
3215
- to {
3216
- opacity: 0;
3217
- -webkit-transform: scale(0.1) translate3d(-2000px, 0, 0);
3218
- transform: scale(0.1) translate3d(-2000px, 0, 0);
3219
- -webkit-transform-origin: left center;
3220
- transform-origin: left center;
3221
- }
3222
- }
3223
-
3224
- .zoomOutLeft {
3225
- -webkit-animation-name: zoomOutLeft;
3226
- animation-name: zoomOutLeft;
3227
- }
3228
-
3229
- @-webkit-keyframes zoomOutRight {
3230
- 40% {
3231
- opacity: 1;
3232
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(-42px, 0, 0);
3233
- transform: scale3d(0.475, 0.475, 0.475) translate3d(-42px, 0, 0);
3234
- }
3235
-
3236
- to {
3237
- opacity: 0;
3238
- -webkit-transform: scale(0.1) translate3d(2000px, 0, 0);
3239
- transform: scale(0.1) translate3d(2000px, 0, 0);
3240
- -webkit-transform-origin: right center;
3241
- transform-origin: right center;
3242
- }
3243
- }
3244
-
3245
- @keyframes zoomOutRight {
3246
- 40% {
3247
- opacity: 1;
3248
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(-42px, 0, 0);
3249
- transform: scale3d(0.475, 0.475, 0.475) translate3d(-42px, 0, 0);
3250
- }
3251
-
3252
- to {
3253
- opacity: 0;
3254
- -webkit-transform: scale(0.1) translate3d(2000px, 0, 0);
3255
- transform: scale(0.1) translate3d(2000px, 0, 0);
3256
- -webkit-transform-origin: right center;
3257
- transform-origin: right center;
3258
- }
3259
- }
3260
-
3261
- .zoomOutRight {
3262
- -webkit-animation-name: zoomOutRight;
3263
- animation-name: zoomOutRight;
3264
- }
3265
-
3266
- @-webkit-keyframes zoomOutUp {
3267
- 40% {
3268
- opacity: 1;
3269
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
3270
- transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
3271
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3272
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3273
- }
3274
-
3275
- to {
3276
- opacity: 0;
3277
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);
3278
- transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);
3279
- -webkit-transform-origin: center bottom;
3280
- transform-origin: center bottom;
3281
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3282
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3283
- }
3284
- }
3285
-
3286
- @keyframes zoomOutUp {
3287
- 40% {
3288
- opacity: 1;
3289
- -webkit-transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
3290
- transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
3291
- -webkit-animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3292
- animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
3293
- }
3294
-
3295
- to {
3296
- opacity: 0;
3297
- -webkit-transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);
3298
- transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);
3299
- -webkit-transform-origin: center bottom;
3300
- transform-origin: center bottom;
3301
- -webkit-animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3302
- animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
3303
- }
3304
- }
3305
-
3306
- .zoomOutUp {
3307
- -webkit-animation-name: zoomOutUp;
3308
- animation-name: zoomOutUp;
3309
- }
3310
-
3311
- @-webkit-keyframes slideInDown {
3312
- from {
3313
- -webkit-transform: translate3d(0, -100%, 0);
3314
- transform: translate3d(0, -100%, 0);
3315
- visibility: visible;
3316
- }
3317
-
3318
- to {
3319
- -webkit-transform: translate3d(0, 0, 0);
3320
- transform: translate3d(0, 0, 0);
3321
- }
3322
- }
3323
-
3324
- @keyframes slideInDown {
3325
- from {
3326
- -webkit-transform: translate3d(0, -100%, 0);
3327
- transform: translate3d(0, -100%, 0);
3328
- visibility: visible;
3329
- }
3330
-
3331
- to {
3332
- -webkit-transform: translate3d(0, 0, 0);
3333
- transform: translate3d(0, 0, 0);
3334
- }
3335
- }
3336
-
3337
- .slideInDown {
3338
- -webkit-animation-name: slideInDown;
3339
- animation-name: slideInDown;
3340
- }
3341
-
3342
- @-webkit-keyframes slideInLeft {
3343
- from {
3344
- -webkit-transform: translate3d(-100%, 0, 0);
3345
- transform: translate3d(-100%, 0, 0);
3346
- visibility: visible;
3347
- }
3348
-
3349
- to {
3350
- -webkit-transform: translate3d(0, 0, 0);
3351
- transform: translate3d(0, 0, 0);
3352
- }
3353
- }
3354
-
3355
- @keyframes slideInLeft {
3356
- from {
3357
- -webkit-transform: translate3d(-100%, 0, 0);
3358
- transform: translate3d(-100%, 0, 0);
3359
- visibility: visible;
3360
- }
3361
-
3362
- to {
3363
- -webkit-transform: translate3d(0, 0, 0);
3364
- transform: translate3d(0, 0, 0);
3365
- }
3366
- }
3367
-
3368
- .slideInLeft {
3369
- -webkit-animation-name: slideInLeft;
3370
- animation-name: slideInLeft;
3371
- }
3372
-
3373
- @-webkit-keyframes slideInRight {
3374
- from {
3375
- -webkit-transform: translate3d(100%, 0, 0);
3376
- transform: translate3d(100%, 0, 0);
3377
- visibility: visible;
3378
- }
3379
-
3380
- to {
3381
- -webkit-transform: translate3d(0, 0, 0);
3382
- transform: translate3d(0, 0, 0);
3383
- }
3384
- }
3385
-
3386
- @keyframes slideInRight {
3387
- from {
3388
- -webkit-transform: translate3d(100%, 0, 0);
3389
- transform: translate3d(100%, 0, 0);
3390
- visibility: visible;
3391
- }
3392
-
3393
- to {
3394
- -webkit-transform: translate3d(0, 0, 0);
3395
- transform: translate3d(0, 0, 0);
3396
- }
3397
- }
3398
-
3399
- .slideInRight {
3400
- -webkit-animation-name: slideInRight;
3401
- animation-name: slideInRight;
3402
- }
3403
-
3404
- @-webkit-keyframes slideInUp {
3405
- from {
3406
- -webkit-transform: translate3d(0, 100%, 0);
3407
- transform: translate3d(0, 100%, 0);
3408
- visibility: visible;
3409
- }
3410
-
3411
- to {
3412
- -webkit-transform: translate3d(0, 0, 0);
3413
- transform: translate3d(0, 0, 0);
3414
- }
3415
- }
3416
-
3417
- @keyframes slideInUp {
3418
- from {
3419
- -webkit-transform: translate3d(0, 100%, 0);
3420
- transform: translate3d(0, 100%, 0);
3421
- visibility: visible;
3422
- }
3423
-
3424
- to {
3425
- -webkit-transform: translate3d(0, 0, 0);
3426
- transform: translate3d(0, 0, 0);
3427
- }
3428
- }
3429
-
3430
- .slideInUp {
3431
- -webkit-animation-name: slideInUp;
3432
- animation-name: slideInUp;
3433
- }
3434
-
3435
- @-webkit-keyframes slideOutDown {
3436
- from {
3437
- -webkit-transform: translate3d(0, 0, 0);
3438
- transform: translate3d(0, 0, 0);
3439
- }
3440
-
3441
- to {
3442
- visibility: hidden;
3443
- -webkit-transform: translate3d(0, 100%, 0);
3444
- transform: translate3d(0, 100%, 0);
3445
- }
3446
- }
3447
-
3448
- @keyframes slideOutDown {
3449
- from {
3450
- -webkit-transform: translate3d(0, 0, 0);
3451
- transform: translate3d(0, 0, 0);
3452
- }
3453
-
3454
- to {
3455
- visibility: hidden;
3456
- -webkit-transform: translate3d(0, 100%, 0);
3457
- transform: translate3d(0, 100%, 0);
3458
- }
3459
- }
3460
-
3461
- .slideOutDown {
3462
- -webkit-animation-name: slideOutDown;
3463
- animation-name: slideOutDown;
3464
- }
3465
-
3466
- @-webkit-keyframes slideOutLeft {
3467
- from {
3468
- -webkit-transform: translate3d(0, 0, 0);
3469
- transform: translate3d(0, 0, 0);
3470
- }
3471
-
3472
- to {
3473
- visibility: hidden;
3474
- -webkit-transform: translate3d(-100%, 0, 0);
3475
- transform: translate3d(-100%, 0, 0);
3476
- }
3477
- }
3478
-
3479
- @keyframes slideOutLeft {
3480
- from {
3481
- -webkit-transform: translate3d(0, 0, 0);
3482
- transform: translate3d(0, 0, 0);
3483
- }
3484
-
3485
- to {
3486
- visibility: hidden;
3487
- -webkit-transform: translate3d(-100%, 0, 0);
3488
- transform: translate3d(-100%, 0, 0);
3489
- }
3490
- }
3491
-
3492
- .slideOutLeft {
3493
- -webkit-animation-name: slideOutLeft;
3494
- animation-name: slideOutLeft;
3495
- }
3496
-
3497
- @-webkit-keyframes slideOutRight {
3498
- from {
3499
- -webkit-transform: translate3d(0, 0, 0);
3500
- transform: translate3d(0, 0, 0);
3501
- }
3502
-
3503
- to {
3504
- visibility: hidden;
3505
- -webkit-transform: translate3d(100%, 0, 0);
3506
- transform: translate3d(100%, 0, 0);
3507
- }
3508
- }
3509
-
3510
- @keyframes slideOutRight {
3511
- from {
3512
- -webkit-transform: translate3d(0, 0, 0);
3513
- transform: translate3d(0, 0, 0);
3514
- }
3515
-
3516
- to {
3517
- visibility: hidden;
3518
- -webkit-transform: translate3d(100%, 0, 0);
3519
- transform: translate3d(100%, 0, 0);
3520
- }
3521
- }
3522
-
3523
- .slideOutRight {
3524
- -webkit-animation-name: slideOutRight;
3525
- animation-name: slideOutRight;
3526
- }
3527
-
3528
- @-webkit-keyframes slideOutUp {
3529
- from {
3530
- -webkit-transform: translate3d(0, 0, 0);
3531
- transform: translate3d(0, 0, 0);
3532
- }
3533
-
3534
- to {
3535
- visibility: hidden;
3536
- -webkit-transform: translate3d(0, -100%, 0);
3537
- transform: translate3d(0, -100%, 0);
3538
- }
3539
- }
3540
-
3541
- @keyframes slideOutUp {
3542
- from {
3543
- -webkit-transform: translate3d(0, 0, 0);
3544
- transform: translate3d(0, 0, 0);
3545
- }
3546
-
3547
- to {
3548
- visibility: hidden;
3549
- -webkit-transform: translate3d(0, -100%, 0);
3550
- transform: translate3d(0, -100%, 0);
3551
- }
3552
- }
3553
-
3554
- .slideOutUp {
3555
- -webkit-animation-name: slideOutUp;
3556
- animation-name: slideOutUp;
3557
- }
3558
-
3559
- .animated {
3560
- -webkit-animation-duration: 1s;
3561
- animation-duration: 1s;
3562
- -webkit-animation-fill-mode: both;
3563
- animation-fill-mode: both;
3564
- }
3565
-
3566
- .animated.infinite {
3567
- -webkit-animation-iteration-count: infinite;
3568
- animation-iteration-count: infinite;
3569
- }
3570
-
3571
- .animated.delay-1s {
3572
- -webkit-animation-delay: 1s;
3573
- animation-delay: 1s;
3574
- }
3575
-
3576
- .animated.delay-2s {
3577
- -webkit-animation-delay: 2s;
3578
- animation-delay: 2s;
3579
- }
3580
-
3581
- .animated.delay-3s {
3582
- -webkit-animation-delay: 3s;
3583
- animation-delay: 3s;
3584
- }
3585
-
3586
- .animated.delay-4s {
3587
- -webkit-animation-delay: 4s;
3588
- animation-delay: 4s;
3589
- }
3590
-
3591
- .animated.delay-5s {
3592
- -webkit-animation-delay: 5s;
3593
- animation-delay: 5s;
3594
- }
3595
-
3596
- .animated.fast {
3597
- -webkit-animation-duration: 800ms;
3598
- animation-duration: 800ms;
3599
- }
3600
-
3601
- .animated.faster {
3602
- -webkit-animation-duration: 500ms;
3603
- animation-duration: 500ms;
3604
- }
3605
-
3606
- .animated.slow {
3607
- -webkit-animation-duration: 2s;
3608
- animation-duration: 2s;
3609
- }
3610
-
3611
- .animated.slower {
3612
- -webkit-animation-duration: 3s;
3613
- animation-duration: 3s;
3614
- }
3615
-
3616
- @media (print), (prefers-reduced-motion) {
3617
- .animated {
3618
- -webkit-animation: unset !important;
3619
- animation: unset !important;
3620
- -webkit-transition: none !important;
3621
- transition: none !important;
3622
- }
3623
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
css/animate.min.css DELETED
@@ -1,11 +0,0 @@
1
- @charset "UTF-8";
2
-
3
- /*!
4
- * animate.css -http://daneden.me/animate
5
- * Version - 3.7.0
6
- * Licensed under the MIT license - http://opensource.org/licenses/MIT
7
- *
8
- * Copyright (c) 2018 Daniel Eden
9
- */
10
-
11
- @-webkit-keyframes bounce{0%,20%,53%,80%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);-webkit-transform:translateZ(0);animation-timing-function:cubic-bezier(.215,.61,.355,1);transform:translateZ(0)}40%,43%{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);-webkit-transform:translate3d(0,-30px,0);animation-timing-function:cubic-bezier(.755,.05,.855,.06);transform:translate3d(0,-30px,0)}70%{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);-webkit-transform:translate3d(0,-15px,0);animation-timing-function:cubic-bezier(.755,.05,.855,.06);transform:translate3d(0,-15px,0)}90%{-webkit-transform:translate3d(0,-4px,0);transform:translate3d(0,-4px,0)}}@keyframes bounce{0%,20%,53%,80%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);-webkit-transform:translateZ(0);animation-timing-function:cubic-bezier(.215,.61,.355,1);transform:translateZ(0)}40%,43%{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);-webkit-transform:translate3d(0,-30px,0);animation-timing-function:cubic-bezier(.755,.05,.855,.06);transform:translate3d(0,-30px,0)}70%{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);-webkit-transform:translate3d(0,-15px,0);animation-timing-function:cubic-bezier(.755,.05,.855,.06);transform:translate3d(0,-15px,0)}90%{-webkit-transform:translate3d(0,-4px,0);transform:translate3d(0,-4px,0)}}.bounce{-webkit-animation-name:bounce;-webkit-transform-origin:center bottom;animation-name:bounce;transform-origin:center bottom}@-webkit-keyframes flash{0%,50%,to{opacity:1}25%,75%{opacity:0}}@keyframes flash{0%,50%,to{opacity:1}25%,75%{opacity:0}}.flash{-webkit-animation-name:flash;animation-name:flash}@-webkit-keyframes pulse{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}50%{-webkit-transform:scale3d(1.05,1.05,1.05);transform:scale3d(1.05,1.05,1.05)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}@keyframes pulse{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}50%{-webkit-transform:scale3d(1.05,1.05,1.05);transform:scale3d(1.05,1.05,1.05)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}.pulse{-webkit-animation-name:pulse;animation-name:pulse}@-webkit-keyframes rubberBand{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}30%{-webkit-transform:scale3d(1.25,.75,1);transform:scale3d(1.25,.75,1)}40%{-webkit-transform:scale3d(.75,1.25,1);transform:scale3d(.75,1.25,1)}50%{-webkit-transform:scale3d(1.15,.85,1);transform:scale3d(1.15,.85,1)}65%{-webkit-transform:scale3d(.95,1.05,1);transform:scale3d(.95,1.05,1)}75%{-webkit-transform:scale3d(1.05,.95,1);transform:scale3d(1.05,.95,1)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}@keyframes rubberBand{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}30%{-webkit-transform:scale3d(1.25,.75,1);transform:scale3d(1.25,.75,1)}40%{-webkit-transform:scale3d(.75,1.25,1);transform:scale3d(.75,1.25,1)}50%{-webkit-transform:scale3d(1.15,.85,1);transform:scale3d(1.15,.85,1)}65%{-webkit-transform:scale3d(.95,1.05,1);transform:scale3d(.95,1.05,1)}75%{-webkit-transform:scale3d(1.05,.95,1);transform:scale3d(1.05,.95,1)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}.rubberBand{-webkit-animation-name:rubberBand;animation-name:rubberBand}@-webkit-keyframes shake{0%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}10%,30%,50%,70%,90%{-webkit-transform:translate3d(-10px,0,0);transform:translate3d(-10px,0,0)}20%,40%,60%,80%{-webkit-transform:translate3d(10px,0,0);transform:translate3d(10px,0,0)}}@keyframes shake{0%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}10%,30%,50%,70%,90%{-webkit-transform:translate3d(-10px,0,0);transform:translate3d(-10px,0,0)}20%,40%,60%,80%{-webkit-transform:translate3d(10px,0,0);transform:translate3d(10px,0,0)}}.shake{-webkit-animation-name:shake;animation-name:shake}@-webkit-keyframes headShake{0%{-webkit-transform:translateX(0);transform:translateX(0)}6.5%{-webkit-transform:translateX(-6px) rotateY(-9deg);transform:translateX(-6px) rotateY(-9deg)}18.5%{-webkit-transform:translateX(5px) rotateY(7deg);transform:translateX(5px) rotateY(7deg)}31.5%{-webkit-transform:translateX(-3px) rotateY(-5deg);transform:translateX(-3px) rotateY(-5deg)}43.5%{-webkit-transform:translateX(2px) rotateY(3deg);transform:translateX(2px) rotateY(3deg)}50%{-webkit-transform:translateX(0);transform:translateX(0)}}@keyframes headShake{0%{-webkit-transform:translateX(0);transform:translateX(0)}6.5%{-webkit-transform:translateX(-6px) rotateY(-9deg);transform:translateX(-6px) rotateY(-9deg)}18.5%{-webkit-transform:translateX(5px) rotateY(7deg);transform:translateX(5px) rotateY(7deg)}31.5%{-webkit-transform:translateX(-3px) rotateY(-5deg);transform:translateX(-3px) rotateY(-5deg)}43.5%{-webkit-transform:translateX(2px) rotateY(3deg);transform:translateX(2px) rotateY(3deg)}50%{-webkit-transform:translateX(0);transform:translateX(0)}}.headShake{-webkit-animation-name:headShake;-webkit-animation-timing-function:ease-in-out;animation-name:headShake;animation-timing-function:ease-in-out}@-webkit-keyframes swing{20%{-webkit-transform:rotate(15deg);transform:rotate(15deg)}40%{-webkit-transform:rotate(-10deg);transform:rotate(-10deg)}60%{-webkit-transform:rotate(5deg);transform:rotate(5deg)}80%{-webkit-transform:rotate(-5deg);transform:rotate(-5deg)}to{-webkit-transform:rotate(0deg);transform:rotate(0deg)}}@keyframes swing{20%{-webkit-transform:rotate(15deg);transform:rotate(15deg)}40%{-webkit-transform:rotate(-10deg);transform:rotate(-10deg)}60%{-webkit-transform:rotate(5deg);transform:rotate(5deg)}80%{-webkit-transform:rotate(-5deg);transform:rotate(-5deg)}to{-webkit-transform:rotate(0deg);transform:rotate(0deg)}}.swing{-webkit-animation-name:swing;-webkit-transform-origin:top center;animation-name:swing;transform-origin:top center}@-webkit-keyframes tada{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}10%,20%{-webkit-transform:scale3d(.9,.9,.9) rotate(-3deg);transform:scale3d(.9,.9,.9) rotate(-3deg)}30%,50%,70%,90%{-webkit-transform:scale3d(1.1,1.1,1.1) rotate(3deg);transform:scale3d(1.1,1.1,1.1) rotate(3deg)}40%,60%,80%{-webkit-transform:scale3d(1.1,1.1,1.1) rotate(-3deg);transform:scale3d(1.1,1.1,1.1) rotate(-3deg)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}@keyframes tada{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}10%,20%{-webkit-transform:scale3d(.9,.9,.9) rotate(-3deg);transform:scale3d(.9,.9,.9) rotate(-3deg)}30%,50%,70%,90%{-webkit-transform:scale3d(1.1,1.1,1.1) rotate(3deg);transform:scale3d(1.1,1.1,1.1) rotate(3deg)}40%,60%,80%{-webkit-transform:scale3d(1.1,1.1,1.1) rotate(-3deg);transform:scale3d(1.1,1.1,1.1) rotate(-3deg)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}.tada{-webkit-animation-name:tada;animation-name:tada}@-webkit-keyframes wobble{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}15%{-webkit-transform:translate3d(-25%,0,0) rotate(-5deg);transform:translate3d(-25%,0,0) rotate(-5deg)}30%{-webkit-transform:translate3d(20%,0,0) rotate(3deg);transform:translate3d(20%,0,0) rotate(3deg)}45%{-webkit-transform:translate3d(-15%,0,0) rotate(-3deg);transform:translate3d(-15%,0,0) rotate(-3deg)}60%{-webkit-transform:translate3d(10%,0,0) rotate(2deg);transform:translate3d(10%,0,0) rotate(2deg)}75%{-webkit-transform:translate3d(-5%,0,0) rotate(-1deg);transform:translate3d(-5%,0,0) rotate(-1deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes wobble{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}15%{-webkit-transform:translate3d(-25%,0,0) rotate(-5deg);transform:translate3d(-25%,0,0) rotate(-5deg)}30%{-webkit-transform:translate3d(20%,0,0) rotate(3deg);transform:translate3d(20%,0,0) rotate(3deg)}45%{-webkit-transform:translate3d(-15%,0,0) rotate(-3deg);transform:translate3d(-15%,0,0) rotate(-3deg)}60%{-webkit-transform:translate3d(10%,0,0) rotate(2deg);transform:translate3d(10%,0,0) rotate(2deg)}75%{-webkit-transform:translate3d(-5%,0,0) rotate(-1deg);transform:translate3d(-5%,0,0) rotate(-1deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.wobble{-webkit-animation-name:wobble;animation-name:wobble}@-webkit-keyframes jello{0%,11.1%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}22.2%{-webkit-transform:skewX(-12.5deg) skewY(-12.5deg);transform:skewX(-12.5deg) skewY(-12.5deg)}33.3%{-webkit-transform:skewX(6.25deg) skewY(6.25deg);transform:skewX(6.25deg) skewY(6.25deg)}44.4%{-webkit-transform:skewX(-3.125deg) skewY(-3.125deg);transform:skewX(-3.125deg) skewY(-3.125deg)}55.5%{-webkit-transform:skewX(1.5625deg) skewY(1.5625deg);transform:skewX(1.5625deg) skewY(1.5625deg)}66.6%{-webkit-transform:skewX(-.78125deg) skewY(-.78125deg);transform:skewX(-.78125deg) skewY(-.78125deg)}77.7%{-webkit-transform:skewX(.390625deg) skewY(.390625deg);transform:skewX(.390625deg) skewY(.390625deg)}88.8%{-webkit-transform:skewX(-.1953125deg) skewY(-.1953125deg);transform:skewX(-.1953125deg) skewY(-.1953125deg)}}@keyframes jello{0%,11.1%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}22.2%{-webkit-transform:skewX(-12.5deg) skewY(-12.5deg);transform:skewX(-12.5deg) skewY(-12.5deg)}33.3%{-webkit-transform:skewX(6.25deg) skewY(6.25deg);transform:skewX(6.25deg) skewY(6.25deg)}44.4%{-webkit-transform:skewX(-3.125deg) skewY(-3.125deg);transform:skewX(-3.125deg) skewY(-3.125deg)}55.5%{-webkit-transform:skewX(1.5625deg) skewY(1.5625deg);transform:skewX(1.5625deg) skewY(1.5625deg)}66.6%{-webkit-transform:skewX(-.78125deg) skewY(-.78125deg);transform:skewX(-.78125deg) skewY(-.78125deg)}77.7%{-webkit-transform:skewX(.390625deg) skewY(.390625deg);transform:skewX(.390625deg) skewY(.390625deg)}88.8%{-webkit-transform:skewX(-.1953125deg) skewY(-.1953125deg);transform:skewX(-.1953125deg) skewY(-.1953125deg)}}.jello{-webkit-animation-name:jello;-webkit-transform-origin:center;animation-name:jello;transform-origin:center}@-webkit-keyframes heartBeat{0%{-webkit-transform:scale(1);transform:scale(1)}14%{-webkit-transform:scale(1.3);transform:scale(1.3)}28%{-webkit-transform:scale(1);transform:scale(1)}42%{-webkit-transform:scale(1.3);transform:scale(1.3)}70%{-webkit-transform:scale(1);transform:scale(1)}}@keyframes heartBeat{0%{-webkit-transform:scale(1);transform:scale(1)}14%{-webkit-transform:scale(1.3);transform:scale(1.3)}28%{-webkit-transform:scale(1);transform:scale(1)}42%{-webkit-transform:scale(1.3);transform:scale(1.3)}70%{-webkit-transform:scale(1);transform:scale(1)}}.heartBeat{-webkit-animation-duration:1.3s;-webkit-animation-name:heartBeat;-webkit-animation-timing-function:ease-in-out;animation-duration:1.3s;animation-name:heartBeat;animation-timing-function:ease-in-out}@-webkit-keyframes bounceIn{0%,20%,40%,60%,80%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:scale3d(.3,.3,.3);opacity:0;transform:scale3d(.3,.3,.3)}20%{-webkit-transform:scale3d(1.1,1.1,1.1);transform:scale3d(1.1,1.1,1.1)}40%{-webkit-transform:scale3d(.9,.9,.9);transform:scale3d(.9,.9,.9)}60%{-webkit-transform:scale3d(1.03,1.03,1.03);opacity:1;transform:scale3d(1.03,1.03,1.03)}80%{-webkit-transform:scale3d(.97,.97,.97);transform:scale3d(.97,.97,.97)}to{-webkit-transform:scaleX(1);opacity:1;transform:scaleX(1)}}@keyframes bounceIn{0%,20%,40%,60%,80%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:scale3d(.3,.3,.3);opacity:0;transform:scale3d(.3,.3,.3)}20%{-webkit-transform:scale3d(1.1,1.1,1.1);transform:scale3d(1.1,1.1,1.1)}40%{-webkit-transform:scale3d(.9,.9,.9);transform:scale3d(.9,.9,.9)}60%{-webkit-transform:scale3d(1.03,1.03,1.03);opacity:1;transform:scale3d(1.03,1.03,1.03)}80%{-webkit-transform:scale3d(.97,.97,.97);transform:scale3d(.97,.97,.97)}to{-webkit-transform:scaleX(1);opacity:1;transform:scaleX(1)}}.bounceIn{-webkit-animation-duration:.75s;-webkit-animation-name:bounceIn;animation-duration:.75s;animation-name:bounceIn}@-webkit-keyframes bounceInDown{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:translate3d(0,-3000px,0);opacity:0;transform:translate3d(0,-3000px,0)}60%{-webkit-transform:translate3d(0,25px,0);opacity:1;transform:translate3d(0,25px,0)}75%{-webkit-transform:translate3d(0,-10px,0);transform:translate3d(0,-10px,0)}90%{-webkit-transform:translate3d(0,5px,0);transform:translate3d(0,5px,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes bounceInDown{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:translate3d(0,-3000px,0);opacity:0;transform:translate3d(0,-3000px,0)}60%{-webkit-transform:translate3d(0,25px,0);opacity:1;transform:translate3d(0,25px,0)}75%{-webkit-transform:translate3d(0,-10px,0);transform:translate3d(0,-10px,0)}90%{-webkit-transform:translate3d(0,5px,0);transform:translate3d(0,5px,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.bounceInDown{-webkit-animation-name:bounceInDown;animation-name:bounceInDown}@-webkit-keyframes bounceInLeft{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:translate3d(-3000px,0,0);opacity:0;transform:translate3d(-3000px,0,0)}60%{-webkit-transform:translate3d(25px,0,0);opacity:1;transform:translate3d(25px,0,0)}75%{-webkit-transform:translate3d(-10px,0,0);transform:translate3d(-10px,0,0)}90%{-webkit-transform:translate3d(5px,0,0);transform:translate3d(5px,0,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes bounceInLeft{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:translate3d(-3000px,0,0);opacity:0;transform:translate3d(-3000px,0,0)}60%{-webkit-transform:translate3d(25px,0,0);opacity:1;transform:translate3d(25px,0,0)}75%{-webkit-transform:translate3d(-10px,0,0);transform:translate3d(-10px,0,0)}90%{-webkit-transform:translate3d(5px,0,0);transform:translate3d(5px,0,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.bounceInLeft{-webkit-animation-name:bounceInLeft;animation-name:bounceInLeft}@-webkit-keyframes bounceInRight{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:translate3d(3000px,0,0);opacity:0;transform:translate3d(3000px,0,0)}60%{-webkit-transform:translate3d(-25px,0,0);opacity:1;transform:translate3d(-25px,0,0)}75%{-webkit-transform:translate3d(10px,0,0);transform:translate3d(10px,0,0)}90%{-webkit-transform:translate3d(-5px,0,0);transform:translate3d(-5px,0,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes bounceInRight{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:translate3d(3000px,0,0);opacity:0;transform:translate3d(3000px,0,0)}60%{-webkit-transform:translate3d(-25px,0,0);opacity:1;transform:translate3d(-25px,0,0)}75%{-webkit-transform:translate3d(10px,0,0);transform:translate3d(10px,0,0)}90%{-webkit-transform:translate3d(-5px,0,0);transform:translate3d(-5px,0,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.bounceInRight{-webkit-animation-name:bounceInRight;animation-name:bounceInRight}@-webkit-keyframes bounceInUp{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:translate3d(0,3000px,0);opacity:0;transform:translate3d(0,3000px,0)}60%{-webkit-transform:translate3d(0,-20px,0);opacity:1;transform:translate3d(0,-20px,0)}75%{-webkit-transform:translate3d(0,10px,0);transform:translate3d(0,10px,0)}90%{-webkit-transform:translate3d(0,-5px,0);transform:translate3d(0,-5px,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes bounceInUp{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{-webkit-transform:translate3d(0,3000px,0);opacity:0;transform:translate3d(0,3000px,0)}60%{-webkit-transform:translate3d(0,-20px,0);opacity:1;transform:translate3d(0,-20px,0)}75%{-webkit-transform:translate3d(0,10px,0);transform:translate3d(0,10px,0)}90%{-webkit-transform:translate3d(0,-5px,0);transform:translate3d(0,-5px,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.bounceInUp{-webkit-animation-name:bounceInUp;animation-name:bounceInUp}@-webkit-keyframes bounceOut{20%{-webkit-transform:scale3d(.9,.9,.9);transform:scale3d(.9,.9,.9)}50%,55%{-webkit-transform:scale3d(1.1,1.1,1.1);opacity:1;transform:scale3d(1.1,1.1,1.1)}to{-webkit-transform:scale3d(.3,.3,.3);opacity:0;transform:scale3d(.3,.3,.3)}}@keyframes bounceOut{20%{-webkit-transform:scale3d(.9,.9,.9);transform:scale3d(.9,.9,.9)}50%,55%{-webkit-transform:scale3d(1.1,1.1,1.1);opacity:1;transform:scale3d(1.1,1.1,1.1)}to{-webkit-transform:scale3d(.3,.3,.3);opacity:0;transform:scale3d(.3,.3,.3)}}.bounceOut{-webkit-animation-duration:.75s;-webkit-animation-name:bounceOut;animation-duration:.75s;animation-name:bounceOut}@-webkit-keyframes bounceOutDown{20%{-webkit-transform:translate3d(0,10px,0);transform:translate3d(0,10px,0)}40%,45%{-webkit-transform:translate3d(0,-20px,0);opacity:1;transform:translate3d(0,-20px,0)}to{-webkit-transform:translate3d(0,2000px,0);opacity:0;transform:translate3d(0,2000px,0)}}@keyframes bounceOutDown{20%{-webkit-transform:translate3d(0,10px,0);transform:translate3d(0,10px,0)}40%,45%{-webkit-transform:translate3d(0,-20px,0);opacity:1;transform:translate3d(0,-20px,0)}to{-webkit-transform:translate3d(0,2000px,0);opacity:0;transform:translate3d(0,2000px,0)}}.bounceOutDown{-webkit-animation-name:bounceOutDown;animation-name:bounceOutDown}@-webkit-keyframes bounceOutLeft{20%{-webkit-transform:translate3d(20px,0,0);opacity:1;transform:translate3d(20px,0,0)}to{-webkit-transform:translate3d(-2000px,0,0);opacity:0;transform:translate3d(-2000px,0,0)}}@keyframes bounceOutLeft{20%{-webkit-transform:translate3d(20px,0,0);opacity:1;transform:translate3d(20px,0,0)}to{-webkit-transform:translate3d(-2000px,0,0);opacity:0;transform:translate3d(-2000px,0,0)}}.bounceOutLeft{-webkit-animation-name:bounceOutLeft;animation-name:bounceOutLeft}@-webkit-keyframes bounceOutRight{20%{-webkit-transform:translate3d(-20px,0,0);opacity:1;transform:translate3d(-20px,0,0)}to{-webkit-transform:translate3d(2000px,0,0);opacity:0;transform:translate3d(2000px,0,0)}}@keyframes bounceOutRight{20%{-webkit-transform:translate3d(-20px,0,0);opacity:1;transform:translate3d(-20px,0,0)}to{-webkit-transform:translate3d(2000px,0,0);opacity:0;transform:translate3d(2000px,0,0)}}.bounceOutRight{-webkit-animation-name:bounceOutRight;animation-name:bounceOutRight}@-webkit-keyframes bounceOutUp{20%{-webkit-transform:translate3d(0,-10px,0);transform:translate3d(0,-10px,0)}40%,45%{-webkit-transform:translate3d(0,20px,0);opacity:1;transform:translate3d(0,20px,0)}to{-webkit-transform:translate3d(0,-2000px,0);opacity:0;transform:translate3d(0,-2000px,0)}}@keyframes bounceOutUp{20%{-webkit-transform:translate3d(0,-10px,0);transform:translate3d(0,-10px,0)}40%,45%{-webkit-transform:translate3d(0,20px,0);opacity:1;transform:translate3d(0,20px,0)}to{-webkit-transform:translate3d(0,-2000px,0);opacity:0;transform:translate3d(0,-2000px,0)}}.bounceOutUp{-webkit-animation-name:bounceOutUp;animation-name:bounceOutUp}@-webkit-keyframes fadeIn{0%{opacity:0}to{opacity:1}}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.fadeIn{-webkit-animation-name:fadeIn;animation-name:fadeIn}@-webkit-keyframes fadeInDown{0%{-webkit-transform:translate3d(0,-100%,0);opacity:0;transform:translate3d(0,-100%,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}@keyframes fadeInDown{0%{-webkit-transform:translate3d(0,-100%,0);opacity:0;transform:translate3d(0,-100%,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}.fadeInDown{-webkit-animation-name:fadeInDown;animation-name:fadeInDown}@-webkit-keyframes fadeInDownBig{0%{-webkit-transform:translate3d(0,-2000px,0);opacity:0;transform:translate3d(0,-2000px,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}@keyframes fadeInDownBig{0%{-webkit-transform:translate3d(0,-2000px,0);opacity:0;transform:translate3d(0,-2000px,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}.fadeInDownBig{-webkit-animation-name:fadeInDownBig;animation-name:fadeInDownBig}@-webkit-keyframes fadeInLeft{0%{-webkit-transform:translate3d(-100%,0,0);opacity:0;transform:translate3d(-100%,0,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}@keyframes fadeInLeft{0%{-webkit-transform:translate3d(-100%,0,0);opacity:0;transform:translate3d(-100%,0,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}.fadeInLeft{-webkit-animation-name:fadeInLeft;animation-name:fadeInLeft}@-webkit-keyframes fadeInLeftBig{0%{-webkit-transform:translate3d(-2000px,0,0);opacity:0;transform:translate3d(-2000px,0,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}@keyframes fadeInLeftBig{0%{-webkit-transform:translate3d(-2000px,0,0);opacity:0;transform:translate3d(-2000px,0,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}.fadeInLeftBig{-webkit-animation-name:fadeInLeftBig;animation-name:fadeInLeftBig}@-webkit-keyframes fadeInRight{0%{-webkit-transform:translate3d(100%,0,0);opacity:0;transform:translate3d(100%,0,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}@keyframes fadeInRight{0%{-webkit-transform:translate3d(100%,0,0);opacity:0;transform:translate3d(100%,0,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}.fadeInRight{-webkit-animation-name:fadeInRight;animation-name:fadeInRight}@-webkit-keyframes fadeInRightBig{0%{-webkit-transform:translate3d(2000px,0,0);opacity:0;transform:translate3d(2000px,0,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}@keyframes fadeInRightBig{0%{-webkit-transform:translate3d(2000px,0,0);opacity:0;transform:translate3d(2000px,0,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}.fadeInRightBig{-webkit-animation-name:fadeInRightBig;animation-name:fadeInRightBig}@-webkit-keyframes fadeInUp{0%{-webkit-transform:translate3d(0,100%,0);opacity:0;transform:translate3d(0,100%,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}@keyframes fadeInUp{0%{-webkit-transform:translate3d(0,100%,0);opacity:0;transform:translate3d(0,100%,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}.fadeInUp{-webkit-animation-name:fadeInUp;animation-name:fadeInUp}@-webkit-keyframes fadeInUpBig{0%{-webkit-transform:translate3d(0,2000px,0);opacity:0;transform:translate3d(0,2000px,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}@keyframes fadeInUpBig{0%{-webkit-transform:translate3d(0,2000px,0);opacity:0;transform:translate3d(0,2000px,0)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}.fadeInUpBig{-webkit-animation-name:fadeInUpBig;animation-name:fadeInUpBig}@-webkit-keyframes fadeOut{0%{opacity:1}to{opacity:0}}@keyframes fadeOut{0%{opacity:1}to{opacity:0}}.fadeOut{-webkit-animation-name:fadeOut;animation-name:fadeOut}@-webkit-keyframes fadeOutDown{0%{opacity:1}to{-webkit-transform:translate3d(0,100%,0);opacity:0;transform:translate3d(0,100%,0)}}@keyframes fadeOutDown{0%{opacity:1}to{-webkit-transform:translate3d(0,100%,0);opacity:0;transform:translate3d(0,100%,0)}}.fadeOutDown{-webkit-animation-name:fadeOutDown;animation-name:fadeOutDown}@-webkit-keyframes fadeOutDownBig{0%{opacity:1}to{-webkit-transform:translate3d(0,2000px,0);opacity:0;transform:translate3d(0,2000px,0)}}@keyframes fadeOutDownBig{0%{opacity:1}to{-webkit-transform:translate3d(0,2000px,0);opacity:0;transform:translate3d(0,2000px,0)}}.fadeOutDownBig{-webkit-animation-name:fadeOutDownBig;animation-name:fadeOutDownBig}@-webkit-keyframes fadeOutLeft{0%{opacity:1}to{-webkit-transform:translate3d(-100%,0,0);opacity:0;transform:translate3d(-100%,0,0)}}@keyframes fadeOutLeft{0%{opacity:1}to{-webkit-transform:translate3d(-100%,0,0);opacity:0;transform:translate3d(-100%,0,0)}}.fadeOutLeft{-webkit-animation-name:fadeOutLeft;animation-name:fadeOutLeft}@-webkit-keyframes fadeOutLeftBig{0%{opacity:1}to{-webkit-transform:translate3d(-2000px,0,0);opacity:0;transform:translate3d(-2000px,0,0)}}@keyframes fadeOutLeftBig{0%{opacity:1}to{-webkit-transform:translate3d(-2000px,0,0);opacity:0;transform:translate3d(-2000px,0,0)}}.fadeOutLeftBig{-webkit-animation-name:fadeOutLeftBig;animation-name:fadeOutLeftBig}@-webkit-keyframes fadeOutRight{0%{opacity:1}to{-webkit-transform:translate3d(100%,0,0);opacity:0;transform:translate3d(100%,0,0)}}@keyframes fadeOutRight{0%{opacity:1}to{-webkit-transform:translate3d(100%,0,0);opacity:0;transform:translate3d(100%,0,0)}}.fadeOutRight{-webkit-animation-name:fadeOutRight;animation-name:fadeOutRight}@-webkit-keyframes fadeOutRightBig{0%{opacity:1}to{-webkit-transform:translate3d(2000px,0,0);opacity:0;transform:translate3d(2000px,0,0)}}@keyframes fadeOutRightBig{0%{opacity:1}to{-webkit-transform:translate3d(2000px,0,0);opacity:0;transform:translate3d(2000px,0,0)}}.fadeOutRightBig{-webkit-animation-name:fadeOutRightBig;animation-name:fadeOutRightBig}@-webkit-keyframes fadeOutUp{0%{opacity:1}to{-webkit-transform:translate3d(0,-100%,0);opacity:0;transform:translate3d(0,-100%,0)}}@keyframes fadeOutUp{0%{opacity:1}to{-webkit-transform:translate3d(0,-100%,0);opacity:0;transform:translate3d(0,-100%,0)}}.fadeOutUp{-webkit-animation-name:fadeOutUp;animation-name:fadeOutUp}@-webkit-keyframes fadeOutUpBig{0%{opacity:1}to{-webkit-transform:translate3d(0,-2000px,0);opacity:0;transform:translate3d(0,-2000px,0)}}@keyframes fadeOutUpBig{0%{opacity:1}to{-webkit-transform:translate3d(0,-2000px,0);opacity:0;transform:translate3d(0,-2000px,0)}}.fadeOutUpBig{-webkit-animation-name:fadeOutUpBig;animation-name:fadeOutUpBig}@-webkit-keyframes flip{0%{-webkit-animation-timing-function:ease-out;-webkit-transform:perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn);animation-timing-function:ease-out;transform:perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn)}40%{-webkit-animation-timing-function:ease-out;-webkit-transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg);animation-timing-function:ease-out;transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg)}50%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg);animation-timing-function:ease-in;transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg)}80%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) scale3d(.95,.95,.95) translateZ(0) rotateY(0deg);animation-timing-function:ease-in;transform:perspective(400px) scale3d(.95,.95,.95) translateZ(0) rotateY(0deg)}to{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) scaleX(1) translateZ(0) rotateY(0deg);animation-timing-function:ease-in;transform:perspective(400px) scaleX(1) translateZ(0) rotateY(0deg)}}@keyframes flip{0%{-webkit-animation-timing-function:ease-out;-webkit-transform:perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn);animation-timing-function:ease-out;transform:perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn)}40%{-webkit-animation-timing-function:ease-out;-webkit-transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg);animation-timing-function:ease-out;transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg)}50%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg);animation-timing-function:ease-in;transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg)}80%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) scale3d(.95,.95,.95) translateZ(0) rotateY(0deg);animation-timing-function:ease-in;transform:perspective(400px) scale3d(.95,.95,.95) translateZ(0) rotateY(0deg)}to{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) scaleX(1) translateZ(0) rotateY(0deg);animation-timing-function:ease-in;transform:perspective(400px) scaleX(1) translateZ(0) rotateY(0deg)}}.animated.flip{-webkit-animation-name:flip;-webkit-backface-visibility:visible;animation-name:flip;backface-visibility:visible}@-webkit-keyframes flipInX{0%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) rotateX(90deg);animation-timing-function:ease-in;opacity:0;transform:perspective(400px) rotateX(90deg)}40%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) rotateX(-20deg);animation-timing-function:ease-in;transform:perspective(400px) rotateX(-20deg)}60%{-webkit-transform:perspective(400px) rotateX(10deg);opacity:1;transform:perspective(400px) rotateX(10deg)}80%{-webkit-transform:perspective(400px) rotateX(-5deg);transform:perspective(400px) rotateX(-5deg)}to{-webkit-transform:perspective(400px);transform:perspective(400px)}}@keyframes flipInX{0%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) rotateX(90deg);animation-timing-function:ease-in;opacity:0;transform:perspective(400px) rotateX(90deg)}40%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) rotateX(-20deg);animation-timing-function:ease-in;transform:perspective(400px) rotateX(-20deg)}60%{-webkit-transform:perspective(400px) rotateX(10deg);opacity:1;transform:perspective(400px) rotateX(10deg)}80%{-webkit-transform:perspective(400px) rotateX(-5deg);transform:perspective(400px) rotateX(-5deg)}to{-webkit-transform:perspective(400px);transform:perspective(400px)}}.flipInX{-webkit-animation-name:flipInX;-webkit-backface-visibility:visible!important;animation-name:flipInX;backface-visibility:visible!important}@-webkit-keyframes flipInY{0%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) rotateY(90deg);animation-timing-function:ease-in;opacity:0;transform:perspective(400px) rotateY(90deg)}40%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) rotateY(-20deg);animation-timing-function:ease-in;transform:perspective(400px) rotateY(-20deg)}60%{-webkit-transform:perspective(400px) rotateY(10deg);opacity:1;transform:perspective(400px) rotateY(10deg)}80%{-webkit-transform:perspective(400px) rotateY(-5deg);transform:perspective(400px) rotateY(-5deg)}to{-webkit-transform:perspective(400px);transform:perspective(400px)}}@keyframes flipInY{0%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) rotateY(90deg);animation-timing-function:ease-in;opacity:0;transform:perspective(400px) rotateY(90deg)}40%{-webkit-animation-timing-function:ease-in;-webkit-transform:perspective(400px) rotateY(-20deg);animation-timing-function:ease-in;transform:perspective(400px) rotateY(-20deg)}60%{-webkit-transform:perspective(400px) rotateY(10deg);opacity:1;transform:perspective(400px) rotateY(10deg)}80%{-webkit-transform:perspective(400px) rotateY(-5deg);transform:perspective(400px) rotateY(-5deg)}to{-webkit-transform:perspective(400px);transform:perspective(400px)}}.flipInY{-webkit-animation-name:flipInY;-webkit-backface-visibility:visible!important;animation-name:flipInY;backface-visibility:visible!important}@-webkit-keyframes flipOutX{0%{-webkit-transform:perspective(400px);transform:perspective(400px)}30%{-webkit-transform:perspective(400px) rotateX(-20deg);opacity:1;transform:perspective(400px) rotateX(-20deg)}to{-webkit-transform:perspective(400px) rotateX(90deg);opacity:0;transform:perspective(400px) rotateX(90deg)}}@keyframes flipOutX{0%{-webkit-transform:perspective(400px);transform:perspective(400px)}30%{-webkit-transform:perspective(400px) rotateX(-20deg);opacity:1;transform:perspective(400px) rotateX(-20deg)}to{-webkit-transform:perspective(400px) rotateX(90deg);opacity:0;transform:perspective(400px) rotateX(90deg)}}.flipOutX{-webkit-animation-duration:.75s;-webkit-animation-name:flipOutX;-webkit-backface-visibility:visible!important;animation-duration:.75s;animation-name:flipOutX;backface-visibility:visible!important}@-webkit-keyframes flipOutY{0%{-webkit-transform:perspective(400px);transform:perspective(400px)}30%{-webkit-transform:perspective(400px) rotateY(-15deg);opacity:1;transform:perspective(400px) rotateY(-15deg)}to{-webkit-transform:perspective(400px) rotateY(90deg);opacity:0;transform:perspective(400px) rotateY(90deg)}}@keyframes flipOutY{0%{-webkit-transform:perspective(400px);transform:perspective(400px)}30%{-webkit-transform:perspective(400px) rotateY(-15deg);opacity:1;transform:perspective(400px) rotateY(-15deg)}to{-webkit-transform:perspective(400px) rotateY(90deg);opacity:0;transform:perspective(400px) rotateY(90deg)}}.flipOutY{-webkit-animation-duration:.75s;-webkit-animation-name:flipOutY;-webkit-backface-visibility:visible!important;animation-duration:.75s;animation-name:flipOutY;backface-visibility:visible!important}@-webkit-keyframes lightSpeedIn{0%{-webkit-transform:translate3d(100%,0,0) skewX(-30deg);opacity:0;transform:translate3d(100%,0,0) skewX(-30deg)}60%{-webkit-transform:skewX(20deg);opacity:1;transform:skewX(20deg)}80%{-webkit-transform:skewX(-5deg);transform:skewX(-5deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes lightSpeedIn{0%{-webkit-transform:translate3d(100%,0,0) skewX(-30deg);opacity:0;transform:translate3d(100%,0,0) skewX(-30deg)}60%{-webkit-transform:skewX(20deg);opacity:1;transform:skewX(20deg)}80%{-webkit-transform:skewX(-5deg);transform:skewX(-5deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.lightSpeedIn{-webkit-animation-name:lightSpeedIn;-webkit-animation-timing-function:ease-out;animation-name:lightSpeedIn;animation-timing-function:ease-out}@-webkit-keyframes lightSpeedOut{0%{opacity:1}to{-webkit-transform:translate3d(100%,0,0) skewX(30deg);opacity:0;transform:translate3d(100%,0,0) skewX(30deg)}}@keyframes lightSpeedOut{0%{opacity:1}to{-webkit-transform:translate3d(100%,0,0) skewX(30deg);opacity:0;transform:translate3d(100%,0,0) skewX(30deg)}}.lightSpeedOut{-webkit-animation-name:lightSpeedOut;-webkit-animation-timing-function:ease-in;animation-name:lightSpeedOut;animation-timing-function:ease-in}@-webkit-keyframes rotateIn{0%{-webkit-transform:rotate(-200deg);-webkit-transform-origin:center;opacity:0;transform:rotate(-200deg);transform-origin:center}to{-webkit-transform:translateZ(0);-webkit-transform-origin:center;opacity:1;transform:translateZ(0);transform-origin:center}}@keyframes rotateIn{0%{-webkit-transform:rotate(-200deg);-webkit-transform-origin:center;opacity:0;transform:rotate(-200deg);transform-origin:center}to{-webkit-transform:translateZ(0);-webkit-transform-origin:center;opacity:1;transform:translateZ(0);transform-origin:center}}.rotateIn{-webkit-animation-name:rotateIn;animation-name:rotateIn}@-webkit-keyframes rotateInDownLeft{0%{-webkit-transform:rotate(-45deg);-webkit-transform-origin:left bottom;opacity:0;transform:rotate(-45deg);transform-origin:left bottom}to{-webkit-transform:translateZ(0);-webkit-transform-origin:left bottom;opacity:1;transform:translateZ(0);transform-origin:left bottom}}@keyframes rotateInDownLeft{0%{-webkit-transform:rotate(-45deg);-webkit-transform-origin:left bottom;opacity:0;transform:rotate(-45deg);transform-origin:left bottom}to{-webkit-transform:translateZ(0);-webkit-transform-origin:left bottom;opacity:1;transform:translateZ(0);transform-origin:left bottom}}.rotateInDownLeft{-webkit-animation-name:rotateInDownLeft;animation-name:rotateInDownLeft}@-webkit-keyframes rotateInDownRight{0%{-webkit-transform:rotate(45deg);-webkit-transform-origin:right bottom;opacity:0;transform:rotate(45deg);transform-origin:right bottom}to{-webkit-transform:translateZ(0);-webkit-transform-origin:right bottom;opacity:1;transform:translateZ(0);transform-origin:right bottom}}@keyframes rotateInDownRight{0%{-webkit-transform:rotate(45deg);-webkit-transform-origin:right bottom;opacity:0;transform:rotate(45deg);transform-origin:right bottom}to{-webkit-transform:translateZ(0);-webkit-transform-origin:right bottom;opacity:1;transform:translateZ(0);transform-origin:right bottom}}.rotateInDownRight{-webkit-animation-name:rotateInDownRight;animation-name:rotateInDownRight}@-webkit-keyframes rotateInUpLeft{0%{-webkit-transform:rotate(45deg);-webkit-transform-origin:left bottom;opacity:0;transform:rotate(45deg);transform-origin:left bottom}to{-webkit-transform:translateZ(0);-webkit-transform-origin:left bottom;opacity:1;transform:translateZ(0);transform-origin:left bottom}}@keyframes rotateInUpLeft{0%{-webkit-transform:rotate(45deg);-webkit-transform-origin:left bottom;opacity:0;transform:rotate(45deg);transform-origin:left bottom}to{-webkit-transform:translateZ(0);-webkit-transform-origin:left bottom;opacity:1;transform:translateZ(0);transform-origin:left bottom}}.rotateInUpLeft{-webkit-animation-name:rotateInUpLeft;animation-name:rotateInUpLeft}@-webkit-keyframes rotateInUpRight{0%{-webkit-transform:rotate(-90deg);-webkit-transform-origin:right bottom;opacity:0;transform:rotate(-90deg);transform-origin:right bottom}to{-webkit-transform:translateZ(0);-webkit-transform-origin:right bottom;opacity:1;transform:translateZ(0);transform-origin:right bottom}}@keyframes rotateInUpRight{0%{-webkit-transform:rotate(-90deg);-webkit-transform-origin:right bottom;opacity:0;transform:rotate(-90deg);transform-origin:right bottom}to{-webkit-transform:translateZ(0);-webkit-transform-origin:right bottom;opacity:1;transform:translateZ(0);transform-origin:right bottom}}.rotateInUpRight{-webkit-animation-name:rotateInUpRight;animation-name:rotateInUpRight}@-webkit-keyframes rotateOut{0%{-webkit-transform-origin:center;opacity:1;transform-origin:center}to{-webkit-transform:rotate(200deg);-webkit-transform-origin:center;opacity:0;transform:rotate(200deg);transform-origin:center}}@keyframes rotateOut{0%{-webkit-transform-origin:center;opacity:1;transform-origin:center}to{-webkit-transform:rotate(200deg);-webkit-transform-origin:center;opacity:0;transform:rotate(200deg);transform-origin:center}}.rotateOut{-webkit-animation-name:rotateOut;animation-name:rotateOut}@-webkit-keyframes rotateOutDownLeft{0%{-webkit-transform-origin:left bottom;opacity:1;transform-origin:left bottom}to{-webkit-transform:rotate(45deg);-webkit-transform-origin:left bottom;opacity:0;transform:rotate(45deg);transform-origin:left bottom}}@keyframes rotateOutDownLeft{0%{-webkit-transform-origin:left bottom;opacity:1;transform-origin:left bottom}to{-webkit-transform:rotate(45deg);-webkit-transform-origin:left bottom;opacity:0;transform:rotate(45deg);transform-origin:left bottom}}.rotateOutDownLeft{-webkit-animation-name:rotateOutDownLeft;animation-name:rotateOutDownLeft}@-webkit-keyframes rotateOutDownRight{0%{-webkit-transform-origin:right bottom;opacity:1;transform-origin:right bottom}to{-webkit-transform:rotate(-45deg);-webkit-transform-origin:right bottom;opacity:0;transform:rotate(-45deg);transform-origin:right bottom}}@keyframes rotateOutDownRight{0%{-webkit-transform-origin:right bottom;opacity:1;transform-origin:right bottom}to{-webkit-transform:rotate(-45deg);-webkit-transform-origin:right bottom;opacity:0;transform:rotate(-45deg);transform-origin:right bottom}}.rotateOutDownRight{-webkit-animation-name:rotateOutDownRight;animation-name:rotateOutDownRight}@-webkit-keyframes rotateOutUpLeft{0%{-webkit-transform-origin:left bottom;opacity:1;transform-origin:left bottom}to{-webkit-transform:rotate(-45deg);-webkit-transform-origin:left bottom;opacity:0;transform:rotate(-45deg);transform-origin:left bottom}}@keyframes rotateOutUpLeft{0%{-webkit-transform-origin:left bottom;opacity:1;transform-origin:left bottom}to{-webkit-transform:rotate(-45deg);-webkit-transform-origin:left bottom;opacity:0;transform:rotate(-45deg);transform-origin:left bottom}}.rotateOutUpLeft{-webkit-animation-name:rotateOutUpLeft;animation-name:rotateOutUpLeft}@-webkit-keyframes rotateOutUpRight{0%{-webkit-transform-origin:right bottom;opacity:1;transform-origin:right bottom}to{-webkit-transform:rotate(90deg);-webkit-transform-origin:right bottom;opacity:0;transform:rotate(90deg);transform-origin:right bottom}}@keyframes rotateOutUpRight{0%{-webkit-transform-origin:right bottom;opacity:1;transform-origin:right bottom}to{-webkit-transform:rotate(90deg);-webkit-transform-origin:right bottom;opacity:0;transform:rotate(90deg);transform-origin:right bottom}}.rotateOutUpRight{-webkit-animation-name:rotateOutUpRight;animation-name:rotateOutUpRight}@-webkit-keyframes hinge{0%{-webkit-animation-timing-function:ease-in-out;-webkit-transform-origin:top left;animation-timing-function:ease-in-out;transform-origin:top left}20%,60%{-webkit-animation-timing-function:ease-in-out;-webkit-transform:rotate(80deg);-webkit-transform-origin:top left;animation-timing-function:ease-in-out;transform:rotate(80deg);transform-origin:top left}40%,80%{-webkit-animation-timing-function:ease-in-out;-webkit-transform:rotate(60deg);-webkit-transform-origin:top left;animation-timing-function:ease-in-out;opacity:1;transform:rotate(60deg);transform-origin:top left}to{-webkit-transform:translate3d(0,700px,0);opacity:0;transform:translate3d(0,700px,0)}}@keyframes hinge{0%{-webkit-animation-timing-function:ease-in-out;-webkit-transform-origin:top left;animation-timing-function:ease-in-out;transform-origin:top left}20%,60%{-webkit-animation-timing-function:ease-in-out;-webkit-transform:rotate(80deg);-webkit-transform-origin:top left;animation-timing-function:ease-in-out;transform:rotate(80deg);transform-origin:top left}40%,80%{-webkit-animation-timing-function:ease-in-out;-webkit-transform:rotate(60deg);-webkit-transform-origin:top left;animation-timing-function:ease-in-out;opacity:1;transform:rotate(60deg);transform-origin:top left}to{-webkit-transform:translate3d(0,700px,0);opacity:0;transform:translate3d(0,700px,0)}}.hinge{-webkit-animation-duration:2s;-webkit-animation-name:hinge;animation-duration:2s;animation-name:hinge}@-webkit-keyframes jackInTheBox{0%{-webkit-transform:scale(.1) rotate(30deg);-webkit-transform-origin:center bottom;opacity:0;transform:scale(.1) rotate(30deg);transform-origin:center bottom}50%{-webkit-transform:rotate(-10deg);transform:rotate(-10deg)}70%{-webkit-transform:rotate(3deg);transform:rotate(3deg)}to{-webkit-transform:scale(1);opacity:1;transform:scale(1)}}@keyframes jackInTheBox{0%{-webkit-transform:scale(.1) rotate(30deg);-webkit-transform-origin:center bottom;opacity:0;transform:scale(.1) rotate(30deg);transform-origin:center bottom}50%{-webkit-transform:rotate(-10deg);transform:rotate(-10deg)}70%{-webkit-transform:rotate(3deg);transform:rotate(3deg)}to{-webkit-transform:scale(1);opacity:1;transform:scale(1)}}.jackInTheBox{-webkit-animation-name:jackInTheBox;animation-name:jackInTheBox}@-webkit-keyframes rollIn{0%{-webkit-transform:translate3d(-100%,0,0) rotate(-120deg);opacity:0;transform:translate3d(-100%,0,0) rotate(-120deg)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}@keyframes rollIn{0%{-webkit-transform:translate3d(-100%,0,0) rotate(-120deg);opacity:0;transform:translate3d(-100%,0,0) rotate(-120deg)}to{-webkit-transform:translateZ(0);opacity:1;transform:translateZ(0)}}.rollIn{-webkit-animation-name:rollIn;animation-name:rollIn}@-webkit-keyframes rollOut{0%{opacity:1}to{-webkit-transform:translate3d(100%,0,0) rotate(120deg);opacity:0;transform:translate3d(100%,0,0) rotate(120deg)}}@keyframes rollOut{0%{opacity:1}to{-webkit-transform:translate3d(100%,0,0) rotate(120deg);opacity:0;transform:translate3d(100%,0,0) rotate(120deg)}}.rollOut{-webkit-animation-name:rollOut;animation-name:rollOut}@-webkit-keyframes zoomIn{0%{-webkit-transform:scale3d(.3,.3,.3);opacity:0;transform:scale3d(.3,.3,.3)}50%{opacity:1}}@keyframes zoomIn{0%{-webkit-transform:scale3d(.3,.3,.3);opacity:0;transform:scale3d(.3,.3,.3)}50%{opacity:1}}.zoomIn{-webkit-animation-name:zoomIn;animation-name:zoomIn}@-webkit-keyframes zoomInDown{0%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.1,.1,.1) translate3d(0,-1000px,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,-1000px,0)}60%{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.475,.475,.475) translate3d(0,60px,0);animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,60px,0)}}@keyframes zoomInDown{0%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.1,.1,.1) translate3d(0,-1000px,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,-1000px,0)}60%{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.475,.475,.475) translate3d(0,60px,0);animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,60px,0)}}.zoomInDown{-webkit-animation-name:zoomInDown;animation-name:zoomInDown}@-webkit-keyframes zoomInLeft{0%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.1,.1,.1) translate3d(-1000px,0,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(-1000px,0,0)}60%{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.475,.475,.475) translate3d(10px,0,0);animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(10px,0,0)}}@keyframes zoomInLeft{0%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.1,.1,.1) translate3d(-1000px,0,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(-1000px,0,0)}60%{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.475,.475,.475) translate3d(10px,0,0);animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(10px,0,0)}}.zoomInLeft{-webkit-animation-name:zoomInLeft;animation-name:zoomInLeft}@-webkit-keyframes zoomInRight{0%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.1,.1,.1) translate3d(1000px,0,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(1000px,0,0)}60%{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.475,.475,.475) translate3d(-10px,0,0);animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(-10px,0,0)}}@keyframes zoomInRight{0%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.1,.1,.1) translate3d(1000px,0,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(1000px,0,0)}60%{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.475,.475,.475) translate3d(-10px,0,0);animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(-10px,0,0)}}.zoomInRight{-webkit-animation-name:zoomInRight;animation-name:zoomInRight}@-webkit-keyframes zoomInUp{0%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.1,.1,.1) translate3d(0,1000px,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,1000px,0)}60%{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,-60px,0)}}@keyframes zoomInUp{0%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.1,.1,.1) translate3d(0,1000px,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,1000px,0)}60%{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,-60px,0)}}.zoomInUp{-webkit-animation-name:zoomInUp;animation-name:zoomInUp}@-webkit-keyframes zoomOut{0%{opacity:1}50%{-webkit-transform:scale3d(.3,.3,.3);opacity:0;transform:scale3d(.3,.3,.3)}to{opacity:0}}@keyframes zoomOut{0%{opacity:1}50%{-webkit-transform:scale3d(.3,.3,.3);opacity:0;transform:scale3d(.3,.3,.3)}to{opacity:0}}.zoomOut{-webkit-animation-name:zoomOut;animation-name:zoomOut}@-webkit-keyframes zoomOutDown{40%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,-60px,0)}to{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.1,.1,.1) translate3d(0,2000px,0);-webkit-transform-origin:center bottom;animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,2000px,0);transform-origin:center bottom}}@keyframes zoomOutDown{40%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,-60px,0)}to{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.1,.1,.1) translate3d(0,2000px,0);-webkit-transform-origin:center bottom;animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,2000px,0);transform-origin:center bottom}}.zoomOutDown{-webkit-animation-name:zoomOutDown;animation-name:zoomOutDown}@-webkit-keyframes zoomOutLeft{40%{-webkit-transform:scale3d(.475,.475,.475) translate3d(42px,0,0);opacity:1;transform:scale3d(.475,.475,.475) translate3d(42px,0,0)}to{-webkit-transform:scale(.1) translate3d(-2000px,0,0);-webkit-transform-origin:left center;opacity:0;transform:scale(.1) translate3d(-2000px,0,0);transform-origin:left center}}@keyframes zoomOutLeft{40%{-webkit-transform:scale3d(.475,.475,.475) translate3d(42px,0,0);opacity:1;transform:scale3d(.475,.475,.475) translate3d(42px,0,0)}to{-webkit-transform:scale(.1) translate3d(-2000px,0,0);-webkit-transform-origin:left center;opacity:0;transform:scale(.1) translate3d(-2000px,0,0);transform-origin:left center}}.zoomOutLeft{-webkit-animation-name:zoomOutLeft;animation-name:zoomOutLeft}@-webkit-keyframes zoomOutRight{40%{-webkit-transform:scale3d(.475,.475,.475) translate3d(-42px,0,0);opacity:1;transform:scale3d(.475,.475,.475) translate3d(-42px,0,0)}to{-webkit-transform:scale(.1) translate3d(2000px,0,0);-webkit-transform-origin:right center;opacity:0;transform:scale(.1) translate3d(2000px,0,0);transform-origin:right center}}@keyframes zoomOutRight{40%{-webkit-transform:scale3d(.475,.475,.475) translate3d(-42px,0,0);opacity:1;transform:scale3d(.475,.475,.475) translate3d(-42px,0,0)}to{-webkit-transform:scale(.1) translate3d(2000px,0,0);-webkit-transform-origin:right center;opacity:0;transform:scale(.1) translate3d(2000px,0,0);transform-origin:right center}}.zoomOutRight{-webkit-animation-name:zoomOutRight;animation-name:zoomOutRight}@-webkit-keyframes zoomOutUp{40%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.475,.475,.475) translate3d(0,60px,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,60px,0)}to{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.1,.1,.1) translate3d(0,-2000px,0);-webkit-transform-origin:center bottom;animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,-2000px,0);transform-origin:center bottom}}@keyframes zoomOutUp{40%{-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);-webkit-transform:scale3d(.475,.475,.475) translate3d(0,60px,0);animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,60px,0)}to{-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);-webkit-transform:scale3d(.1,.1,.1) translate3d(0,-2000px,0);-webkit-transform-origin:center bottom;animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,-2000px,0);transform-origin:center bottom}}.zoomOutUp{-webkit-animation-name:zoomOutUp;animation-name:zoomOutUp}@-webkit-keyframes slideInDown{0%{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes slideInDown{0%{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.slideInDown{-webkit-animation-name:slideInDown;animation-name:slideInDown}@-webkit-keyframes slideInLeft{0%{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes slideInLeft{0%{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.slideInLeft{-webkit-animation-name:slideInLeft;animation-name:slideInLeft}@-webkit-keyframes slideInRight{0%{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes slideInRight{0%{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.slideInRight{-webkit-animation-name:slideInRight;animation-name:slideInRight}@-webkit-keyframes slideInUp{0%{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes slideInUp{0%{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.slideInUp{-webkit-animation-name:slideInUp;animation-name:slideInUp}@-webkit-keyframes slideOutDown{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0);visibility:hidden}}@keyframes slideOutDown{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0);visibility:hidden}}.slideOutDown{-webkit-animation-name:slideOutDown;animation-name:slideOutDown}@-webkit-keyframes slideOutLeft{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0);visibility:hidden}}@keyframes slideOutLeft{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0);visibility:hidden}}.slideOutLeft{-webkit-animation-name:slideOutLeft;animation-name:slideOutLeft}@-webkit-keyframes slideOutRight{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0);visibility:hidden}}@keyframes slideOutRight{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0);visibility:hidden}}.slideOutRight{-webkit-animation-name:slideOutRight;animation-name:slideOutRight}@-webkit-keyframes slideOutUp{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0);visibility:hidden}}@keyframes slideOutUp{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0);visibility:hidden}}.slideOutUp{-webkit-animation-name:slideOutUp;animation-name:slideOutUp}.animated{-webkit-animation-duration:1s;-webkit-animation-fill-mode:both;animation-duration:1s;animation-fill-mode:both}.animated.infinite{-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite}.animated.delay-1s{-webkit-animation-delay:1s;animation-delay:1s}.animated.delay-2s{-webkit-animation-delay:2s;animation-delay:2s}.animated.delay-3s{-webkit-animation-delay:3s;animation-delay:3s}.animated.delay-4s{-webkit-animation-delay:4s;animation-delay:4s}.animated.delay-5s{-webkit-animation-delay:5s;animation-delay:5s}.animated.fast{-webkit-animation-duration:.8s;animation-duration:.8s}.animated.faster{-webkit-animation-duration:.5s;animation-duration:.5s}.animated.slow{-webkit-animation-duration:2s;animation-duration:2s}.animated.slower{-webkit-animation-duration:3s;animation-duration:3s}@media (prefers-reduced-motion),(print){.animated{-webkit-animation:unset!important;-webkit-transition:none!important;animation:unset!important;transition:none!important}}
 
 
 
 
 
 
 
 
 
 
 
css/chosen/chosen-sprite.png DELETED
Binary file
css/chosen/chosen-sprite@2x.png DELETED
Binary file
css/chosen/chosen.css DELETED
@@ -1,496 +0,0 @@
1
- /*!
2
- Chosen, a Select Box Enhancer for jQuery and Prototype
3
- by Patrick Filler for Harvest, http://getharvest.com
4
-
5
- Version 1.8.7
6
- Full source at https://github.com/harvesthq/chosen
7
- Copyright (c) 2011-2018 Harvest http://getharvest.com
8
-
9
- MIT License, https://github.com/harvesthq/chosen/blob/master/LICENSE.md
10
- This file is generated by `grunt build`, do not edit it by hand.
11
- */
12
-
13
- /* @group Base */
14
- .chosen-container {
15
- position: relative;
16
- display: inline-block;
17
- vertical-align: middle;
18
- font-size: 13px;
19
- -webkit-user-select: none;
20
- -moz-user-select: none;
21
- -ms-user-select: none;
22
- user-select: none;
23
- }
24
-
25
- .chosen-container * {
26
- -webkit-box-sizing: border-box;
27
- box-sizing: border-box;
28
- }
29
-
30
- .chosen-container .chosen-drop {
31
- position: absolute;
32
- top: 100%;
33
- z-index: 1010;
34
- width: 100%;
35
- border: 1px solid #aaa;
36
- border-top: 0;
37
- background: #fff;
38
- -webkit-box-shadow: 0 4px 5px rgba(0, 0, 0, 0.15);
39
- box-shadow: 0 4px 5px rgba(0, 0, 0, 0.15);
40
- clip: rect(0, 0, 0, 0);
41
- -webkit-clip-path: inset(100% 100%);
42
- clip-path: inset(100% 100%);
43
- }
44
-
45
- .chosen-container.chosen-with-drop .chosen-drop {
46
- clip: auto;
47
- -webkit-clip-path: none;
48
- clip-path: none;
49
- }
50
-
51
- .chosen-container a {
52
- cursor: pointer;
53
- }
54
-
55
- .chosen-container .search-choice .group-name, .chosen-container .chosen-single .group-name {
56
- margin-right: 4px;
57
- overflow: hidden;
58
- white-space: nowrap;
59
- text-overflow: ellipsis;
60
- font-weight: normal;
61
- color: #999999;
62
- }
63
-
64
- .chosen-container .search-choice .group-name:after, .chosen-container .chosen-single .group-name:after {
65
- content: ":";
66
- padding-left: 2px;
67
- vertical-align: top;
68
- }
69
-
70
- /* @end */
71
- /* @group Single Chosen */
72
- .chosen-container-single .chosen-single {
73
- position: relative;
74
- display: block;
75
- overflow: hidden;
76
- padding: 0 0 0 8px;
77
- height: 25px;
78
- border: 1px solid #aaa;
79
- border-radius: 5px;
80
- background-color: #fff;
81
- background: -webkit-gradient(linear, left top, left bottom, color-stop(20%, #fff), color-stop(50%, #f6f6f6), color-stop(52%, #eee), to(#f4f4f4));
82
- background: linear-gradient(#fff 20%, #f6f6f6 50%, #eee 52%, #f4f4f4 100%);
83
- background-clip: padding-box;
84
- -webkit-box-shadow: 0 0 3px #fff inset, 0 1px 1px rgba(0, 0, 0, 0.1);
85
- box-shadow: 0 0 3px #fff inset, 0 1px 1px rgba(0, 0, 0, 0.1);
86
- color: #444;
87
- text-decoration: none;
88
- white-space: nowrap;
89
- line-height: 24px;
90
- }
91
-
92
- .chosen-container-single .chosen-default {
93
- color: #999;
94
- }
95
-
96
- .chosen-container-single .chosen-single span {
97
- display: block;
98
- overflow: hidden;
99
- margin-right: 26px;
100
- text-overflow: ellipsis;
101
- white-space: nowrap;
102
- }
103
-
104
- .chosen-container-single .chosen-single-with-deselect span {
105
- margin-right: 38px;
106
- }
107
-
108
- .chosen-container-single .chosen-single abbr {
109
- position: absolute;
110
- top: 6px;
111
- right: 26px;
112
- display: block;
113
- width: 12px;
114
- height: 12px;
115
- background: url("chosen-sprite.png") -42px 1px no-repeat;
116
- font-size: 1px;
117
- }
118
-
119
- .chosen-container-single .chosen-single abbr:hover {
120
- background-position: -42px -10px;
121
- }
122
-
123
- .chosen-container-single.chosen-disabled .chosen-single abbr:hover {
124
- background-position: -42px -10px;
125
- }
126
-
127
- .chosen-container-single .chosen-single div {
128
- position: absolute;
129
- top: 0;
130
- right: 0;
131
- display: block;
132
- width: 18px;
133
- height: 100%;
134
- }
135
-
136
- .chosen-container-single .chosen-single div b {
137
- display: block;
138
- width: 100%;
139
- height: 100%;
140
- background: url("chosen-sprite.png") no-repeat 0px 2px;
141
- }
142
-
143
- .chosen-container-single .chosen-search {
144
- position: relative;
145
- z-index: 1010;
146
- margin: 0;
147
- padding: 3px 4px;
148
- white-space: nowrap;
149
- }
150
-
151
- .chosen-container-single .chosen-search input[type="text"] {
152
- margin: 1px 0;
153
- padding: 4px 20px 4px 5px;
154
- width: 100%;
155
- height: auto;
156
- outline: 0;
157
- border: 1px solid #aaa;
158
- background: url("chosen-sprite.png") no-repeat 100% -20px;
159
- font-size: 1em;
160
- font-family: sans-serif;
161
- line-height: normal;
162
- border-radius: 0;
163
- }
164
-
165
- .chosen-container-single .chosen-drop {
166
- margin-top: -1px;
167
- border-radius: 0 0 4px 4px;
168
- background-clip: padding-box;
169
- }
170
-
171
- .chosen-container-single.chosen-container-single-nosearch .chosen-search {
172
- position: absolute;
173
- clip: rect(0, 0, 0, 0);
174
- -webkit-clip-path: inset(100% 100%);
175
- clip-path: inset(100% 100%);
176
- }
177
-
178
- /* @end */
179
- /* @group Results */
180
- .chosen-container .chosen-results {
181
- color: #444;
182
- position: relative;
183
- overflow-x: hidden;
184
- overflow-y: auto;
185
- margin: 0 4px 4px 0;
186
- padding: 0 0 0 4px;
187
- max-height: 240px;
188
- -webkit-overflow-scrolling: touch;
189
- }
190
-
191
- .chosen-container .chosen-results li {
192
- display: none;
193
- margin: 0;
194
- padding: 5px 6px;
195
- list-style: none;
196
- line-height: 15px;
197
- word-wrap: break-word;
198
- -webkit-touch-callout: none;
199
- }
200
-
201
- .chosen-container .chosen-results li.active-result {
202
- display: list-item;
203
- cursor: pointer;
204
- }
205
-
206
- .chosen-container .chosen-results li.disabled-result {
207
- display: list-item;
208
- color: #ccc;
209
- cursor: default;
210
- }
211
-
212
- .chosen-container .chosen-results li.highlighted {
213
- background-color: #3875d7;
214
- background-image: -webkit-gradient(linear, left top, left bottom, color-stop(20%, #3875d7), color-stop(90%, #2a62bc));
215
- background-image: linear-gradient(#3875d7 20%, #2a62bc 90%);
216
- color: #fff;
217
- }
218
-
219
- .chosen-container .chosen-results li.no-results {
220
- color: #777;
221
- display: list-item;
222
- background: #f4f4f4;
223
- }
224
-
225
- .chosen-container .chosen-results li.group-result {
226
- display: list-item;
227
- font-weight: bold;
228
- cursor: default;
229
- }
230
-
231
- .chosen-container .chosen-results li.group-option {
232
- padding-left: 15px;
233
- }
234
-
235
- .chosen-container .chosen-results li em {
236
- font-style: normal;
237
- text-decoration: underline;
238
- }
239
-
240
- /* @end */
241
- /* @group Multi Chosen */
242
- .chosen-container-multi .chosen-choices {
243
- position: relative;
244
- overflow: hidden;
245
- margin: 0;
246
- padding: 0 5px;
247
- width: 100%;
248
- height: auto;
249
- border: 1px solid #aaa;
250
- background-color: #fff;
251
- background-image: -webkit-gradient(linear, left top, left bottom, color-stop(1%, #eee), color-stop(15%, #fff));
252
- background-image: linear-gradient(#eee 1%, #fff 15%);
253
- cursor: text;
254
- }
255
-
256
- .chosen-container-multi .chosen-choices li {
257
- float: left;
258
- list-style: none;
259
- }
260
-
261
- .chosen-container-multi .chosen-choices li.search-field {
262
- margin: 0;
263
- padding: 0;
264
- white-space: nowrap;
265
- }
266
-
267
- .chosen-container-multi .chosen-choices li.search-field input[type="text"] {
268
- margin: 1px 0;
269
- padding: 0;
270
- height: 25px;
271
- outline: 0;
272
- border: 0 !important;
273
- background: transparent !important;
274
- -webkit-box-shadow: none;
275
- box-shadow: none;
276
- color: #999;
277
- font-size: 100%;
278
- font-family: sans-serif;
279
- line-height: normal;
280
- border-radius: 0;
281
- width: 25px;
282
- }
283
-
284
- .chosen-container-multi .chosen-choices li.search-choice {
285
- position: relative;
286
- margin: 3px 5px 3px 0;
287
- padding: 3px 20px 3px 5px;
288
- border: 1px solid #aaa;
289
- max-width: 100%;
290
- border-radius: 3px;
291
- background-color: #eeeeee;
292
- background-image: -webkit-gradient(linear, left top, left bottom, color-stop(20%, #f4f4f4), color-stop(50%, #f0f0f0), color-stop(52%, #e8e8e8), to(#eee));
293
- background-image: linear-gradient(#f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eee 100%);
294
- background-size: 100% 19px;
295
- background-repeat: repeat-x;
296
- background-clip: padding-box;
297
- -webkit-box-shadow: 0 0 2px #fff inset, 0 1px 0 rgba(0, 0, 0, 0.05);
298
- box-shadow: 0 0 2px #fff inset, 0 1px 0 rgba(0, 0, 0, 0.05);
299
- color: #333;
300
- line-height: 13px;
301
- cursor: default;
302
- }
303
-
304
- .chosen-container-multi .chosen-choices li.search-choice span {
305
- word-wrap: break-word;
306
- }
307
-
308
- .chosen-container-multi .chosen-choices li.search-choice .search-choice-close {
309
- position: absolute;
310
- top: 4px;
311
- right: 3px;
312
- display: block;
313
- width: 12px;
314
- height: 12px;
315
- background: url("chosen-sprite.png") -42px 1px no-repeat;
316
- font-size: 1px;
317
- }
318
-
319
- .chosen-container-multi .chosen-choices li.search-choice .search-choice-close:hover {
320
- background-position: -42px -10px;
321
- }
322
-
323
- .chosen-container-multi .chosen-choices li.search-choice-disabled {
324
- padding-right: 5px;
325
- border: 1px solid #ccc;
326
- background-color: #e4e4e4;
327
- background-image: -webkit-gradient(linear, left top, left bottom, color-stop(20%, #f4f4f4), color-stop(50%, #f0f0f0), color-stop(52%, #e8e8e8), to(#eee));
328
- background-image: linear-gradient(#f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eee 100%);
329
- color: #666;
330
- }
331
-
332
- .chosen-container-multi .chosen-choices li.search-choice-focus {
333
- background: #d4d4d4;
334
- }
335
-
336
- .chosen-container-multi .chosen-choices li.search-choice-focus .search-choice-close {
337
- background-position: -42px -10px;
338
- }
339
-
340
- .chosen-container-multi .chosen-results {
341
- margin: 0;
342
- padding: 0;
343
- }
344
-
345
- .chosen-container-multi .chosen-drop .result-selected {
346
- display: list-item;
347
- color: #ccc;
348
- cursor: default;
349
- }
350
-
351
- /* @end */
352
- /* @group Active */
353
- .chosen-container-active .chosen-single {
354
- border: 1px solid #5897fb;
355
- -webkit-box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
356
- box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
357
- }
358
-
359
- .chosen-container-active.chosen-with-drop .chosen-single {
360
- border: 1px solid #aaa;
361
- border-bottom-right-radius: 0;
362
- border-bottom-left-radius: 0;
363
- background-image: -webkit-gradient(linear, left top, left bottom, color-stop(20%, #eee), color-stop(80%, #fff));
364
- background-image: linear-gradient(#eee 20%, #fff 80%);
365
- -webkit-box-shadow: 0 1px 0 #fff inset;
366
- box-shadow: 0 1px 0 #fff inset;
367
- }
368
-
369
- .chosen-container-active.chosen-with-drop .chosen-single div {
370
- border-left: none;
371
- background: transparent;
372
- }
373
-
374
- .chosen-container-active.chosen-with-drop .chosen-single div b {
375
- background-position: -18px 2px;
376
- }
377
-
378
- .chosen-container-active .chosen-choices {
379
- border: 1px solid #5897fb;
380
- -webkit-box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
381
- box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
382
- }
383
-
384
- .chosen-container-active .chosen-choices li.search-field input[type="text"] {
385
- color: #222 !important;
386
- }
387
-
388
- /* @end */
389
- /* @group Disabled Support */
390
- .chosen-disabled {
391
- opacity: 0.5 !important;
392
- cursor: default;
393
- }
394
-
395
- .chosen-disabled .chosen-single {
396
- cursor: default;
397
- }
398
-
399
- .chosen-disabled .chosen-choices .search-choice .search-choice-close {
400
- cursor: default;
401
- }
402
-
403
- /* @end */
404
- /* @group Right to Left */
405
- .chosen-rtl {
406
- text-align: right;
407
- }
408
-
409
- .chosen-rtl .chosen-single {
410
- overflow: visible;
411
- padding: 0 8px 0 0;
412
- }
413
-
414
- .chosen-rtl .chosen-single span {
415
- margin-right: 0;
416
- margin-left: 26px;
417
- direction: rtl;
418
- }
419
-
420
- .chosen-rtl .chosen-single-with-deselect span {
421
- margin-left: 38px;
422
- }
423
-
424
- .chosen-rtl .chosen-single div {
425
- right: auto;
426
- left: 3px;
427
- }
428
-
429
- .chosen-rtl .chosen-single abbr {
430
- right: auto;
431
- left: 26px;
432
- }
433
-
434
- .chosen-rtl .chosen-choices li {
435
- float: right;
436
- }
437
-
438
- .chosen-rtl .chosen-choices li.search-field input[type="text"] {
439
- direction: rtl;
440
- }
441
-
442
- .chosen-rtl .chosen-choices li.search-choice {
443
- margin: 3px 5px 3px 0;
444
- padding: 3px 5px 3px 19px;
445
- }
446
-
447
- .chosen-rtl .chosen-choices li.search-choice .search-choice-close {
448
- right: auto;
449
- left: 4px;
450
- }
451
-
452
- .chosen-rtl.chosen-container-single .chosen-results {
453
- margin: 0 0 4px 4px;
454
- padding: 0 4px 0 0;
455
- }
456
-
457
- .chosen-rtl .chosen-results li.group-option {
458
- padding-right: 15px;
459
- padding-left: 0;
460
- }
461
-
462
- .chosen-rtl.chosen-container-active.chosen-with-drop .chosen-single div {
463
- border-right: none;
464
- }
465
-
466
- .chosen-rtl .chosen-search input[type="text"] {
467
- padding: 4px 5px 4px 20px;
468
- background: url("chosen-sprite.png") no-repeat -30px -20px;
469
- direction: rtl;
470
- }
471
-
472
- .chosen-rtl.chosen-container-single .chosen-single div b {
473
- background-position: 6px 2px;
474
- }
475
-
476
- .chosen-rtl.chosen-container-single.chosen-with-drop .chosen-single div b {
477
- background-position: -12px 2px;
478
- }
479
-
480
- /* @end */
481
- /* @group Retina compatibility */
482
- @media only screen and (-webkit-min-device-pixel-ratio: 1.5), only screen and (min-resolution: 144dpi), only screen and (min-resolution: 1.5dppx) {
483
- .chosen-rtl .chosen-search input[type="text"],
484
- .chosen-container-single .chosen-single abbr,
485
- .chosen-container-single .chosen-single div b,
486
- .chosen-container-single .chosen-search input[type="text"],
487
- .chosen-container-multi .chosen-choices .search-choice .search-choice-close,
488
- .chosen-container .chosen-results-scroll-down span,
489
- .chosen-container .chosen-results-scroll-up span {
490
- background-image: url("chosen-sprite@2x.png") !important;
491
- background-size: 52px 37px !important;
492
- background-repeat: no-repeat !important;
493
- }
494
- }
495
-
496
- /* @end */
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
css/chosen/chosen.min.css DELETED
@@ -1,11 +0,0 @@
1
- /*!
2
- Chosen, a Select Box Enhancer for jQuery and Prototype
3
- by Patrick Filler for Harvest, http://getharvest.com
4
-
5
- Version 1.8.7
6
- Full source at https://github.com/harvesthq/chosen
7
- Copyright (c) 2011-2018 Harvest http://getharvest.com
8
-
9
- MIT License, https://github.com/harvesthq/chosen/blob/master/LICENSE.md
10
- This file is generated by `grunt build`, do not edit it by hand.
11
- */.chosen-container{position:relative;display:inline-block;vertical-align:middle;font-size:13px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.chosen-container *{-webkit-box-sizing:border-box;box-sizing:border-box}.chosen-container .chosen-drop{position:absolute;top:100%;z-index:1010;width:100%;border:1px solid #aaa;border-top:0;background:#fff;-webkit-box-shadow:0 4px 5px rgba(0,0,0,.15);box-shadow:0 4px 5px rgba(0,0,0,.15);clip:rect(0,0,0,0);-webkit-clip-path:inset(100% 100%);clip-path:inset(100% 100%)}.chosen-container.chosen-with-drop .chosen-drop{clip:auto;-webkit-clip-path:none;clip-path:none}.chosen-container a{cursor:pointer}.chosen-container .chosen-single .group-name,.chosen-container .search-choice .group-name{margin-right:4px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-weight:400;color:#999}.chosen-container .chosen-single .group-name:after,.chosen-container .search-choice .group-name:after{content:":";padding-left:2px;vertical-align:top}.chosen-container-single .chosen-single{position:relative;display:block;overflow:hidden;padding:0 0 0 8px;height:25px;border:1px solid #aaa;border-radius:5px;background-color:#fff;background:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#fff),color-stop(50%,#f6f6f6),color-stop(52%,#eee),to(#f4f4f4));background:linear-gradient(#fff 20%,#f6f6f6 50%,#eee 52%,#f4f4f4 100%);background-clip:padding-box;-webkit-box-shadow:0 0 3px #fff inset,0 1px 1px rgba(0,0,0,.1);box-shadow:0 0 3px #fff inset,0 1px 1px rgba(0,0,0,.1);color:#444;text-decoration:none;white-space:nowrap;line-height:24px}.chosen-container-single .chosen-default{color:#999}.chosen-container-single .chosen-single span{display:block;overflow:hidden;margin-right:26px;text-overflow:ellipsis;white-space:nowrap}.chosen-container-single .chosen-single-with-deselect span{margin-right:38px}.chosen-container-single .chosen-single abbr{position:absolute;top:6px;right:26px;display:block;width:12px;height:12px;background:url(chosen-sprite.png) -42px 1px no-repeat;font-size:1px}.chosen-container-single .chosen-single abbr:hover{background-position:-42px -10px}.chosen-container-single.chosen-disabled .chosen-single abbr:hover{background-position:-42px -10px}.chosen-container-single .chosen-single div{position:absolute;top:0;right:0;display:block;width:18px;height:100%}.chosen-container-single .chosen-single div b{display:block;width:100%;height:100%;background:url(chosen-sprite.png) no-repeat 0 2px}.chosen-container-single .chosen-search{position:relative;z-index:1010;margin:0;padding:3px 4px;white-space:nowrap}.chosen-container-single .chosen-search input[type=text]{margin:1px 0;padding:4px 20px 4px 5px;width:100%;height:auto;outline:0;border:1px solid #aaa;background:url(chosen-sprite.png) no-repeat 100% -20px;font-size:1em;font-family:sans-serif;line-height:normal;border-radius:0}.chosen-container-single .chosen-drop{margin-top:-1px;border-radius:0 0 4px 4px;background-clip:padding-box}.chosen-container-single.chosen-container-single-nosearch .chosen-search{position:absolute;clip:rect(0,0,0,0);-webkit-clip-path:inset(100% 100%);clip-path:inset(100% 100%)}.chosen-container .chosen-results{color:#444;position:relative;overflow-x:hidden;overflow-y:auto;margin:0 4px 4px 0;padding:0 0 0 4px;max-height:240px;-webkit-overflow-scrolling:touch}.chosen-container .chosen-results li{display:none;margin:0;padding:5px 6px;list-style:none;line-height:15px;word-wrap:break-word;-webkit-touch-callout:none}.chosen-container .chosen-results li.active-result{display:list-item;cursor:pointer}.chosen-container .chosen-results li.disabled-result{display:list-item;color:#ccc;cursor:default}.chosen-container .chosen-results li.highlighted{background-color:#3875d7;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#3875d7),color-stop(90%,#2a62bc));background-image:linear-gradient(#3875d7 20%,#2a62bc 90%);color:#fff}.chosen-container .chosen-results li.no-results{color:#777;display:list-item;background:#f4f4f4}.chosen-container .chosen-results li.group-result{display:list-item;font-weight:700;cursor:default}.chosen-container .chosen-results li.group-option{padding-left:15px}.chosen-container .chosen-results li em{font-style:normal;text-decoration:underline}.chosen-container-multi .chosen-choices{position:relative;overflow:hidden;margin:0;padding:0 5px;width:100%;height:auto;border:1px solid #aaa;background-color:#fff;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(1%,#eee),color-stop(15%,#fff));background-image:linear-gradient(#eee 1%,#fff 15%);cursor:text}.chosen-container-multi .chosen-choices li{float:left;list-style:none}.chosen-container-multi .chosen-choices li.search-field{margin:0;padding:0;white-space:nowrap}.chosen-container-multi .chosen-choices li.search-field input[type=text]{margin:1px 0;padding:0;height:25px;outline:0;border:0!important;background:0 0!important;-webkit-box-shadow:none;box-shadow:none;color:#999;font-size:100%;font-family:sans-serif;line-height:normal;border-radius:0;width:25px}.chosen-container-multi .chosen-choices li.search-choice{position:relative;margin:3px 5px 3px 0;padding:3px 20px 3px 5px;border:1px solid #aaa;max-width:100%;border-radius:3px;background-color:#eee;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#f4f4f4),color-stop(50%,#f0f0f0),color-stop(52%,#e8e8e8),to(#eee));background-image:linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);background-size:100% 19px;background-repeat:repeat-x;background-clip:padding-box;-webkit-box-shadow:0 0 2px #fff inset,0 1px 0 rgba(0,0,0,.05);box-shadow:0 0 2px #fff inset,0 1px 0 rgba(0,0,0,.05);color:#333;line-height:13px;cursor:default}.chosen-container-multi .chosen-choices li.search-choice span{word-wrap:break-word}.chosen-container-multi .chosen-choices li.search-choice .search-choice-close{position:absolute;top:4px;right:3px;display:block;width:12px;height:12px;background:url(chosen-sprite.png) -42px 1px no-repeat;font-size:1px}.chosen-container-multi .chosen-choices li.search-choice .search-choice-close:hover{background-position:-42px -10px}.chosen-container-multi .chosen-choices li.search-choice-disabled{padding-right:5px;border:1px solid #ccc;background-color:#e4e4e4;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#f4f4f4),color-stop(50%,#f0f0f0),color-stop(52%,#e8e8e8),to(#eee));background-image:linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);color:#666}.chosen-container-multi .chosen-choices li.search-choice-focus{background:#d4d4d4}.chosen-container-multi .chosen-choices li.search-choice-focus .search-choice-close{background-position:-42px -10px}.chosen-container-multi .chosen-results{margin:0;padding:0}.chosen-container-multi .chosen-drop .result-selected{display:list-item;color:#ccc;cursor:default}.chosen-container-active .chosen-single{border:1px solid #5897fb;-webkit-box-shadow:0 0 5px rgba(0,0,0,.3);box-shadow:0 0 5px rgba(0,0,0,.3)}.chosen-container-active.chosen-with-drop .chosen-single{border:1px solid #aaa;border-bottom-right-radius:0;border-bottom-left-radius:0;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#eee),color-stop(80%,#fff));background-image:linear-gradient(#eee 20%,#fff 80%);-webkit-box-shadow:0 1px 0 #fff inset;box-shadow:0 1px 0 #fff inset}.chosen-container-active.chosen-with-drop .chosen-single div{border-left:none;background:0 0}.chosen-container-active.chosen-with-drop .chosen-single div b{background-position:-18px 2px}.chosen-container-active .chosen-choices{border:1px solid #5897fb;-webkit-box-shadow:0 0 5px rgba(0,0,0,.3);box-shadow:0 0 5px rgba(0,0,0,.3)}.chosen-container-active .chosen-choices li.search-field input[type=text]{color:#222!important}.chosen-disabled{opacity:.5!important;cursor:default}.chosen-disabled .chosen-single{cursor:default}.chosen-disabled .chosen-choices .search-choice .search-choice-close{cursor:default}.chosen-rtl{text-align:right}.chosen-rtl .chosen-single{overflow:visible;padding:0 8px 0 0}.chosen-rtl .chosen-single span{margin-right:0;margin-left:26px;direction:rtl}.chosen-rtl .chosen-single-with-deselect span{margin-left:38px}.chosen-rtl .chosen-single div{right:auto;left:3px}.chosen-rtl .chosen-single abbr{right:auto;left:26px}.chosen-rtl .chosen-choices li{float:right}.chosen-rtl .chosen-choices li.search-field input[type=text]{direction:rtl}.chosen-rtl .chosen-choices li.search-choice{margin:3px 5px 3px 0;padding:3px 5px 3px 19px}.chosen-rtl .chosen-choices li.search-choice .search-choice-close{right:auto;left:4px}.chosen-rtl.chosen-container-single .chosen-results{margin:0 0 4px 4px;padding:0 4px 0 0}.chosen-rtl .chosen-results li.group-option{padding-right:15px;padding-left:0}.chosen-rtl.chosen-container-active.chosen-with-drop .chosen-single div{border-right:none}.chosen-rtl .chosen-search input[type=text]{padding:4px 5px 4px 20px;background:url(chosen-sprite.png) no-repeat -30px -20px;direction:rtl}.chosen-rtl.chosen-container-single .chosen-single div b{background-position:6px 2px}.chosen-rtl.chosen-container-single.chosen-with-drop .chosen-single div b{background-position:-12px 2px}@media only screen and (-webkit-min-device-pixel-ratio:1.5),only screen and (min-resolution:144dpi),only screen and (min-resolution:1.5dppx){.chosen-container .chosen-results-scroll-down span,.chosen-container .chosen-results-scroll-up span,.chosen-container-multi .chosen-choices .search-choice .search-choice-close,.chosen-container-single .chosen-search input[type=text],.chosen-container-single .chosen-single abbr,.chosen-container-single .chosen-single div b,.chosen-rtl .chosen-search input[type=text]{background-image:url(chosen-sprite@2x.png)!important;background-size:52px 37px!important;background-repeat:no-repeat!important}}
 
 
 
 
 
 
 
 
 
 
 
css/login/login-rtl.css DELETED
@@ -1,260 +0,0 @@
1
- html,
2
- body {
3
- height: 100%;
4
- margin: 0;
5
- padding: 0;
6
- }
7
-
8
- html {
9
- background: #f1f1f1;
10
- }
11
-
12
- body {
13
- background: #f1f1f1;
14
- min-width: 0;
15
- color: #444;
16
- font-family: "Open Sans", sans-serif;
17
- font-size: 13px;
18
- line-height: 1.4em;
19
- }
20
-
21
- a {
22
- color: #0074a2;
23
- -webkit-transition-property: border, background, color;
24
- transition-property: border, background, color;
25
- -webkit-transition-duration: .05s;
26
- transition-duration: .05s;
27
- -webkit-transition-timing-function: ease-in-out;
28
- transition-timing-function: ease-in-out;
29
- }
30
-
31
- a {
32
- outline: 0;
33
- }
34
-
35
- a:hover,
36
- a:active {
37
- color: #2ea2cc;
38
- }
39
-
40
- a:focus {
41
- color: #124964;
42
- }
43
-
44
- a:focus,
45
- a:active {
46
- outline: thin dotted;
47
- }
48
-
49
- p {
50
- line-height: 1.5;
51
- }
52
-
53
- .login .message {
54
- border-right: 4px solid #7ad03a;
55
- padding: 1px 12px;
56
- background-color: #fff;
57
- -webkit-box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
58
- box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
59
- }
60
-
61
- .login #login_error {
62
- border-right: 4px solid #dd3d36;
63
- background: #fff;
64
- -webkit-box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
65
- box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
66
- }
67
-
68
- #loginform p.submit,
69
- .login-action-lostpassword p.submit {
70
- border: none;
71
- margin: -10px 0 20px; /* May want to revisit this */
72
- }
73
-
74
- .login * {
75
- margin: 0;
76
- padding: 0;
77
- }
78
-
79
- .login form {
80
- margin-top: 20px;
81
- margin-right: 0;
82
- padding: 26px 24px 46px;
83
- font-weight: normal;
84
- overflow: hidden;
85
- background: #fff;
86
- -webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.13);
87
- box-shadow: 0 1px 3px rgba(0,0,0,0.13);
88
- }
89
-
90
- .login form .forgetmenot {
91
- font-weight: normal;
92
- float: right;
93
- margin-bottom: 0;
94
- }
95
-
96
- .login .button-primary {
97
- float: left;
98
- }
99
-
100
- #login form p {
101
- margin-bottom: 0;
102
- }
103
-
104
- #login form p.submit {
105
- margin: 0;
106
- padding: 0;
107
- }
108
-
109
- .login label {
110
- color: #777;
111
- font-size: 14px;
112
- }
113
-
114
- .login form .forgetmenot label {
115
- font-size: 12px;
116
- line-height: 19px;
117
- }
118
-
119
- .login h1 {
120
- text-align: center;
121
- }
122
-
123
- .login h1 a {
124
- background-position: center top;
125
- background-repeat: no-repeat;
126
- color: #999;
127
- font-size: 20px;
128
- font-weight: normal;
129
- line-height: 1.3em;
130
- margin: 0 auto 25px;
131
- padding: 0;
132
- text-decoration: none;
133
- text-indent: -9999px;
134
- outline: none;
135
- overflow: hidden;
136
- display: block;
137
- }
138
-
139
- #login {
140
- width: 320px;
141
- padding: 8% 0 0;
142
- margin: auto;
143
- }
144
-
145
- #login_error,
146
- .login .message {
147
- margin-right: 0;
148
- padding: 12px;
149
- }
150
-
151
- .login #nav,
152
- .login #backtoblog {
153
- font-size: 13px;
154
- padding: 0 24px 0;
155
- }
156
-
157
- .login #nav {
158
- margin: 24px 0 0 0;
159
- }
160
-
161
- #backtoblog {
162
- margin: 16px 0 0 0;
163
- }
164
-
165
- .login #nav a,
166
- .login #backtoblog a {
167
- text-decoration: none;
168
- color: #999;
169
- }
170
-
171
- .login #nav a:hover,
172
- .login #backtoblog a:hover,
173
- .login h1 a:hover {
174
- color: #2ea2cc;
175
- }
176
-
177
- .login form .input,
178
- .login input[type="text"] {
179
- font-size: 24px;
180
- width: 100%;
181
- padding: 3px;
182
- margin: 2px 0 16px 6px;
183
- }
184
-
185
- .login form .input,
186
- .login input[type="text"],
187
- .login form input[type="checkbox"] {
188
- background: #fbfbfb;
189
- }
190
-
191
- .ie7 .login form .input,
192
- .ie8 .login form .input {
193
- font-family: sans-serif;
194
- }
195
-
196
- .login #pass-strength-result {
197
- width: 250px;
198
- font-weight: 600;
199
- margin: 12px 0 6px;
200
- padding: 6px 5px;
201
- text-align: center;
202
- }
203
-
204
- .mobile #login {
205
- padding: 20px 0;
206
- }
207
-
208
- .mobile #login form,
209
- .mobile #login .message,
210
- .mobile #login_error {
211
- margin-right: 0;
212
- }
213
-
214
- .mobile #login #nav,
215
- .mobile #login #backtoblog {
216
- margin-right: 8px;
217
- }
218
-
219
- .mobile #login h1 a {
220
- width: auto;
221
- }
222
-
223
- body.interim-login {
224
- height: auto;
225
- }
226
-
227
- .interim-login #login {
228
- padding: 0;
229
- margin: 5px auto 20px;
230
- }
231
-
232
- .interim-login.login h1 a {
233
- width: auto;
234
- }
235
-
236
- .interim-login #login_error,
237
- .interim-login.login .message {
238
- margin: 0 0 16px;
239
- }
240
-
241
- .interim-login.login form {
242
- margin: 0;
243
- }
244
-
245
- @-ms-viewport {
246
- width: device-width;
247
- }
248
-
249
- @media screen and ( max-width: 782px ) {
250
- .interim-login input[type=checkbox] {
251
- height: 16px;
252
- width: 16px;
253
- }
254
-
255
- .interim-login input[type=checkbox]:checked:before {
256
- width: 16px;
257
- font: normal 21px/1 'dashicons';
258
- margin: -3px -4px 0 0;
259
- }
260
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
css/login/login.css DELETED
@@ -1,270 +0,0 @@
1
- html,
2
- body {
3
- height: 100%;
4
- margin: 0;
5
- padding: 0;
6
- }
7
-
8
- html {
9
- background: #f1f1f1;
10
- }
11
-
12
- body {
13
- background: #f1f1f1;
14
- min-width: 0;
15
- color: #444;
16
- font-family: "Open Sans", sans-serif;
17
- font-size: 13px;
18
- line-height: 1.4em;
19
- }
20
-
21
- a {
22
- color: #0074a2;
23
- -webkit-transition-property: border, background, color;
24
- transition-property: border, background, color;
25
- -webkit-transition-duration: .05s;
26
- transition-duration: .05s;
27
- -webkit-transition-timing-function: ease-in-out;
28
- transition-timing-function: ease-in-out;
29
- }
30
-
31
- a {
32
- outline: 0;
33
- }
34
-
35
- a:hover,
36
- a:active {
37
- color: #2ea2cc;
38
- }
39
-
40
- a:focus {
41
- color: #124964;
42
- }
43
-
44
- a:focus,
45
- a:active {
46
- outline: thin dotted;
47
- }
48
-
49
- p {
50
- line-height: 1.5;
51
- }
52
-
53
- .login .message {
54
- border-left: 4px solid #7ad03a;
55
- padding: 1px 12px;
56
- background-color: #fff;
57
- -webkit-box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
58
- box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
59
- }
60
-
61
- .login #login_error {
62
- border-left: 4px solid #dd3d36;
63
- background: #fff;
64
- -webkit-box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
65
- box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
66
- }
67
-
68
- #loginform p.submit,
69
- .login-action-lostpassword p.submit {
70
- border: none;
71
- margin: -10px 0 20px; /* May want to revisit this */
72
- }
73
-
74
- .login * {
75
- margin: 0;
76
- padding: 0;
77
- }
78
-
79
- .login form {
80
- margin-top: 20px;
81
- margin-left: 0;
82
- padding: 26px 24px 46px;
83
- font-weight: normal;
84
- overflow: hidden;
85
- background: #fff;
86
- -webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.13);
87
- box-shadow: 0 1px 3px rgba(0,0,0,0.13);
88
- }
89
-
90
- .login form .forgetmenot {
91
- font-weight: normal;
92
- float: left;
93
- margin-bottom: 0;
94
- }
95
-
96
- .login .button-primary {
97
- float: right;
98
- }
99
-
100
- #login form p {
101
- margin-bottom: 0;
102
- }
103
-
104
- #login form p.submit {
105
- margin: 0;
106
- padding: 0;
107
- }
108
-
109
- .login label {
110
- color: #777;
111
- font-size: 14px;
112
- }
113
-
114
- .login form .forgetmenot label {
115
- font-size: 12px;
116
- line-height: 19px;
117
- }
118
-
119
- .login h1 {
120
- text-align: center;
121
- }
122
-
123
- .login h1 a {
124
- /**
125
- * Removed from default login.css
126
- **********************************
127
- background-image: url(../images/w-logo-blue.png?ver=20131202);
128
- background-image: none, url(../images/wordpress-logo.svg?ver=20131107);
129
- -webkit-background-size: 84px;
130
- background-size: 84px;
131
- *
132
- */
133
-
134
- background-position: center top;
135
- background-repeat: no-repeat;
136
- color: #999;
137
- font-size: 20px;
138
- font-weight: normal;
139
- line-height: 1.3em;
140
- margin: 0 auto 25px;
141
- padding: 0;
142
- text-decoration: none;
143
- text-indent: -9999px;
144
- outline: none;
145
- overflow: hidden;
146
- display: block;
147
- }
148
-
149
- #login {
150
- width: 320px;
151
- padding: 8% 0 0;
152
- margin: auto;
153
- }
154
-
155
- #login_error,
156
- .login .message {
157
- margin-left: 0;
158
- padding: 12px;
159
- }
160
-
161
- .login #nav,
162
- .login #backtoblog {
163
- font-size: 13px;
164
- padding: 0 24px 0;
165
- }
166
-
167
- .login #nav {
168
- margin: 24px 0 0 0;
169
- }
170
-
171
- #backtoblog {
172
- margin: 16px 0 0 0;
173
- }
174
-
175
- .login #nav a,
176
- .login #backtoblog a {
177
- text-decoration: none;
178
- color: #999;
179
- }
180
-
181
- .login #nav a:hover,
182
- .login #backtoblog a:hover,
183
- .login h1 a:hover {
184
- color: #2ea2cc;
185
- }
186
-
187
- .login form .input,
188
- .login input[type="text"] {
189
- font-size: 24px;
190
- width: 100%;
191
- padding: 3px;
192
- margin: 2px 6px 16px 0;
193
- }
194
-
195
- .login form .input,
196
- .login input[type="text"],
197
- .login form input[type="checkbox"] {
198
- background: #fbfbfb;
199
- }
200
-
201
- .ie7 .login form .input,
202
- .ie8 .login form .input {
203
- font-family: sans-serif;
204
- }
205
-
206
- .login #pass-strength-result {
207
- width: 250px;
208
- font-weight: 600;
209
- margin: 12px 0 6px;
210
- padding: 6px 5px;
211
- text-align: center;
212
- }
213
-
214
- .mobile #login {
215
- padding: 20px 0;
216
- }
217
-
218
- .mobile #login form,
219
- .mobile #login .message,
220
- .mobile #login_error {
221
- margin-left: 0;
222
- }
223
-
224
- .mobile #login #nav,
225
- .mobile #login #backtoblog {
226
- margin-left: 8px;
227
- }
228
-
229
- .mobile #login h1 a {
230
- width: auto;
231
- }
232
-
233
- body.interim-login {
234
- height: auto;
235
- }
236
-
237
- .interim-login #login {
238
- padding: 0;
239
- margin: 5px auto 20px;
240
- }
241
-
242
- .interim-login.login h1 a {
243
- width: auto;
244
- }
245
-
246
- .interim-login #login_error,
247
- .interim-login.login .message {
248
- margin: 0 0 16px;
249
- }
250
-
251
- .interim-login.login form {
252
- margin: 0;
253
- }
254
-
255
- @-ms-viewport {
256
- width: device-width;
257
- }
258
-
259
- @media screen and ( max-width: 782px ) {
260
- .interim-login input[type=checkbox] {
261
- height: 16px;
262
- width: 16px;
263
- }
264
-
265
- .interim-login input[type=checkbox]:checked:before {
266
- width: 16px;
267
- font: normal 21px/1 'dashicons';
268
- margin: -3px 0 0 -4px;
269
- }
270
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
custom-login.php CHANGED
@@ -3,374 +3,105 @@
3
  * Plugin Name: Custom Login
4
  * Plugin URI: https://frosty.media/plugins/custom-login
5
  * Description: A simple way to customize your WordPress <code>wp-login.php</code> screen! A <a href="https://frosty.media/">Frosty Media</a> plugin.
6
- * Version: 3.2.15
7
  * Author: Austin Passy
8
  * Author URI: https://austin.passy.co
9
- * Requires PHP: 5.6
 
 
10
  * Text Domain: custom-login
11
  * GitHub Plugin URI: https://github.com/thefrosty/custom-login
12
- * GitHub Branch: master
 
13
  *
14
  * @copyright 2012 - 2022
15
  * @author Austin Passy
16
  * @link https://austin.passy.co/
17
- * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
18
  *
19
  * This program is distributed in the hope that it will be useful,
20
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
21
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
22
- *
23
- * @class Custom_Login
24
  */
25
 
26
- if ( ! class_exists( 'Custom_Login' ) ) :
27
-
28
- /**
29
- * Main Custom_Login Class
30
- *
31
- * @since 2.0
32
- */
33
- final class Custom_Login {
34
-
35
- /** Singleton *************************************************************/
36
- private static $instance;
37
-
38
- /**
39
- * Plugin vars
40
- *
41
- * @return string
42
- */
43
- public $version = '3.2.15',
44
- $menu_page,
45
- $prefix;
46
-
47
- /**
48
- * Custom Login Settings API
49
- *
50
- * @var CL_Settings_API $settings_api
51
- */
52
- public $settings_api;
53
-
54
- /**
55
- * Main Instance
56
- *
57
- * @return Custom_Login The one true instance
58
- */
59
- public static function instance() {
60
- if ( ! isset( self::$instance ) && ! ( self::$instance instanceof Custom_Login ) ) {
61
- self::$instance = new Custom_Login;
62
- self::$instance->setup_constants();
63
-
64
- add_action( 'plugins_loaded', array( self::$instance, 'plugin_textdomain' ) );
65
-
66
- self::$instance->includes();
67
- self::$instance->actions();
68
- }
69
-
70
- return self::$instance;
71
- }
72
-
73
- /**
74
- * Setup plugin constants
75
- *
76
- * @access private
77
- * @since 3.0
78
- * @return void
79
- */
80
- private function setup_constants() {
81
- // API URL
82
- if ( ! defined( 'CUSTOM_LOGIN_API_URL' ) ) {
83
- define( 'CUSTOM_LOGIN_API_URL', 'https://frosty.media/' );
84
- }
85
-
86
- // Plugin version
87
- if ( ! defined( 'CUSTOM_LOGIN_VERSION' ) ) {
88
- define( 'CUSTOM_LOGIN_VERSION', $this->version );
89
- }
90
-
91
- // Plugin Root File
92
- if ( ! defined( 'CUSTOM_LOGIN_FILE' ) ) {
93
- define( 'CUSTOM_LOGIN_FILE', __FILE__ );
94
- }
95
-
96
- // Plugin Folder Path
97
- if ( ! defined( 'CUSTOM_LOGIN_DIR' ) ) {
98
- define( 'CUSTOM_LOGIN_DIR', plugin_dir_path( CUSTOM_LOGIN_FILE ) );
99
- }
100
-
101
- // Plugin Folder URL
102
- if ( ! defined( 'CUSTOM_LOGIN_URL' ) ) {
103
- define( 'CUSTOM_LOGIN_URL', plugin_dir_url( CUSTOM_LOGIN_FILE ) );
104
- }
105
-
106
- // Plugin Root Basename
107
- if ( ! defined( 'CUSTOM_LOGIN_BASENAME' ) ) {
108
- define( 'CUSTOM_LOGIN_BASENAME', plugin_basename( CUSTOM_LOGIN_FILE ) );
109
- }
110
-
111
- // Plugin Dirname
112
- if ( ! defined( 'CUSTOM_LOGIN_DIRNAME' ) ) {
113
- define( 'CUSTOM_LOGIN_DIRNAME', dirname( CUSTOM_LOGIN_BASENAME ) );
114
- }
115
-
116
- // Plugin Settings Name
117
- if ( ! defined( 'CUSTOM_LOGIN_OPTION' ) ) {
118
- define( 'CUSTOM_LOGIN_OPTION', str_replace( '-', '_', CUSTOM_LOGIN_DIRNAME ) );
119
- }
120
- }
121
-
122
- /**
123
- * Load the plugin translations
124
- *
125
- */
126
- public function plugin_textdomain() {
127
- load_plugin_textdomain( CUSTOM_LOGIN_DIRNAME, false, CUSTOM_LOGIN_DIRNAME . '/languages/' );
128
- }
129
-
130
- /**
131
- * Includes required functions
132
- *
133
- */
134
- private function includes() {
135
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/class-cl-common.php';
136
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/class-cl-cron.php';
137
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/class-cl-extensions.php';
138
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/class-cl-templates.php';
139
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/class-cl-scripts-styles.php';
140
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/class-cl-settings-api.php';
141
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/class-cl-settings-upgrades.php';
142
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/class-cl-wp-login.php';
143
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/functions.php';
144
-
145
- if ( is_admin() ) {
146
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/admin/dashboard.php';
147
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/admin/plugins.php';
148
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/admin/import-export.php';
149
- require_once trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/admin/tracking.php';
150
- }
151
- }
152
-
153
- /**
154
- * To infinity and beyond
155
- */
156
- private function actions() {
157
- $this->prefix = CUSTOM_LOGIN_OPTION;
158
-
159
- register_activation_hook( CUSTOM_LOGIN_FILE, array( $this, 'activate' ) );
160
-
161
- add_action( 'login_head', array( $this, 'cl_version_in_header' ), 1 );
162
- add_action( 'wp_head', array( $this, 'cl_version_in_header' ) );
163
- add_action( 'admin_menu', array( $this, 'admin_menu' ), 9 );
164
- add_action( 'admin_init', array( $this, 'load_settings' ), 8 );
165
- add_action( $this->prefix . '_after_sanitize_options', array( $this, 'delete_transients' ), 8 );
166
-
167
- add_action( 'admin_notices', array( $this, 'show_notifications' ) );
168
- add_action( 'admin_init', array( $this, 'notification_ignore' ) );
169
-
170
- do_action( $this->prefix . '_actions' );
171
- }
172
-
173
- /**
174
- * Runs on plugin install.
175
- *
176
- * @since 3.1
177
- */
178
- function activate() {
179
- $settings = CL_Common::get_options('general');
180
- $settings['active'] = 'on';
181
-
182
- update_option(CUSTOM_LOGIN_OPTION . '_general', $settings);
183
- }
184
-
185
- /**
186
- * Adds CL Version to the <head> tag
187
- *
188
- * @since 3.0.0
189
- * @return void
190
- */
191
- function cl_version_in_header() {
192
- echo '<meta name="generator" content="Custom Login v' . CUSTOM_LOGIN_VERSION . '" />' . "\n";
193
- }
194
-
195
- /**
196
- * Register the plugin page
197
- */
198
- public function admin_menu() {
199
- $capability = CL_Common::get_option( 'capability', 'general', 'manage_options' );
200
-
201
- $this->menu_page = add_options_page(
202
- __( 'Custom Login Settings', CUSTOM_LOGIN_DIRNAME ),
203
- __( 'Custom Login', CUSTOM_LOGIN_DIRNAME ),
204
- $capability,
205
- CUSTOM_LOGIN_DIRNAME,
206
- array( $this, 'settings_page' )
207
- );
208
- }
209
-
210
- /**
211
- * Display the plugin settings options page
212
- */
213
- public function settings_page() { ?>
214
- <div class="wrap">
215
- <?php $this->settings_api->settings_html(); ?>
216
- </div><?php
217
- }
218
-
219
- /**
220
- * Display the plugin settings options page
221
- */
222
- public function load_settings() {
223
-
224
- $fields = $sections = array();
225
- include trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/default-settings.php';
226
- $this->settings_api = new CL_Settings_API(
227
- $sections,
228
- $fields,
229
- array(
230
- 'option_name' => CUSTOM_LOGIN_OPTION,
231
- 'option_group' => CUSTOM_LOGIN_OPTION . '_group',
232
- 'domain' => CUSTOM_LOGIN_DIRNAME,
233
- 'prefix' => $this->prefix,
234
- 'version' => $this->version,
235
- 'menu_page' => $this->menu_page,
236
- 'nonce' => CUSTOM_LOGIN_OPTION . '_nonce_' . CUSTOM_LOGIN_BASENAME,
237
- 'file' => CUSTOM_LOGIN_FILE,
238
- )
239
- );
240
- $this->settings_api->admin_init();
241
- }
242
-
243
- /**
244
- * Hook into the 'sanitize_options' hook in the Settings API
245
- * and remove the transient settings for the style and script.
246
- *
247
- * @since 3.0.0
248
- */
249
- public function delete_transients() {
250
- delete_transient( CL_Common::get_transient_key( 'style' ) );
251
- delete_transient( CL_Common::get_transient_key( 'script' ) );
252
- }
253
-
254
- /**
255
- * Show global notifications if they are allowed.
256
- *
257
- */
258
- public function show_notifications() {
259
- $is_cl_screen = CL_Common::is_settings_page();
260
- $transient_key = CL_Common::get_transient_key( 'announcement' );
261
- $ignore_key = CUSTOM_LOGIN_OPTION . '_ignore_announcement';
262
- $old_message = get_option( CUSTOM_LOGIN_OPTION . '_announcement_message' );
263
- $user_meta = get_user_meta( get_current_user_id(), $ignore_key, true );
264
- $capability = CL_Common::get_option( 'capability', 'general', 'manage_options' );
265
-
266
- /**
267
- * delete_user_meta( get_current_user_id(), $ignore_key, 1 );
268
- * delete_transient( $transient_key );
269
- * update_option( CUSTOM_LOGIN_OPTION . '_announcement_message', '' );
270
- */
271
-
272
- // Current user can't manage options
273
- if ( ! current_user_can( $capability ) ) {
274
- return;
275
- }
276
-
277
- if ( ! $is_cl_screen ) {
278
-
279
- // Make sure 'Frosty_Media_Notifications' isn't activated
280
- if ( class_exists( 'Frosty_Media_Notifications' ) ) {
281
- return;
282
- }
283
-
284
- // Global notifications
285
- if ( 'off' === CL_Common::get_option( 'admin_notices', 'general', 'off' ) ) {
286
- return;
287
- }
288
-
289
- // Let's not show this at all if not on out menu page. @since 3.1
290
- return;
291
- }
292
-
293
- $message_url = esc_url( add_query_arg( array( 'get_notifications' => 'true' ), CUSTOM_LOGIN_API_URL) );
294
-
295
- $announcement = CL_Common::wp_remote_get(
296
- $transient_key,
297
- $message_url,
298
- DAY_IN_SECONDS,
299
- 'WordPress' // We need our custom $user_agent
300
- );
301
-
302
- // Bail if errors
303
- if ( is_wp_error( $announcement ) ) {
304
- return;
305
- }
306
-
307
- // Bail if false or empty
308
- if ( ! $announcement || empty( $announcement[0] ) ) {
309
- return;
310
- }
311
-
312
- if ( trim( $old_message ) !== trim( $announcement[0]->message ) && ! empty( $old_message ) ) {
313
- delete_user_meta( get_current_user_id(), $ignore_key );
314
- delete_transient( $transient_key );
315
- update_option( CUSTOM_LOGIN_OPTION . '_announcement_message', $announcement[0]->message );
316
- }
317
-
318
- $html = '<div class="updated"><p>';
319
- $html .= ! $is_cl_screen ? // If we're on our settings page let not show the dismiss notice link.
320
- sprintf( '%2$s <span class="alignright">| <a href="%3$s">%1$s</a></span>',
321
- __( 'Dismiss', CUSTOM_LOGIN_DIRNAME ),
322
- $announcement[0]->message,
323
- esc_url( add_query_arg( $ignore_key, wp_create_nonce( $ignore_key ), admin_url( 'options-general.php?page=custom-login' ) ) )
324
- // esc_url( admin_url( 'options-general.php?page=custom-login#custom_login_general' ) )
325
- ) :
326
- sprintf( '%s', $announcement[0]->message );
327
- $html .= '</p></div>';
328
-
329
- if ( ( ! $user_meta && 1 !== $user_meta ) || $is_cl_screen ) {
330
- echo $html;
331
- }
332
- }
333
-
334
- /**
335
- * Remove the admin notification.
336
- *
337
- * @return void
338
- */
339
- public function notification_ignore() {
340
- $ignore_key = CUSTOM_LOGIN_OPTION . '_ignore_announcement';
341
-
342
- // Bail if not set
343
- if ( ! isset( $_GET[ $ignore_key ] ) ) {
344
- return;
345
- }
346
-
347
- // Check nonce
348
- check_admin_referer( $ignore_key, $ignore_key );
349
-
350
- // If user clicks to ignore the notice, add that to their user meta
351
- add_user_meta( get_current_user_id(), $ignore_key, 1, true );
352
- }
353
-
354
- }
355
-
356
- endif; // End if class_exists check
357
 
358
  /**
359
- * The main function responsible for returning the one true
360
- * Instance to functions everywhere.
361
- *
362
- * Use this function like you would a global variable, except without needing
363
- * to declare the global.
364
- *
365
- * Example: <?php $custom_login = CUSTOMLOGIN(); ?>
366
- *
367
- * @return Custom_Login
368
  */
369
- if ( ! function_exists( 'CUSTOMLOGIN' ) ) {
370
- function CUSTOMLOGIN() {
371
- return Custom_Login::instance();
 
372
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
373
  }
374
 
375
- // Out of the frying pan, and into the fire.
376
- CUSTOMLOGIN();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  * Plugin Name: Custom Login
4
  * Plugin URI: https://frosty.media/plugins/custom-login
5
  * Description: A simple way to customize your WordPress <code>wp-login.php</code> screen! A <a href="https://frosty.media/">Frosty Media</a> plugin.
6
+ * Version: 4.0.8
7
  * Author: Austin Passy
8
  * Author URI: https://austin.passy.co
9
+ * Requires at least: 5.8
10
+ * Tested up to: 6.0.1
11
+ * Requires PHP: 7.4
12
  * Text Domain: custom-login
13
  * GitHub Plugin URI: https://github.com/thefrosty/custom-login
14
+ * Primary Branch: develop
15
+ * Release Asset: true
16
  *
17
  * @copyright 2012 - 2022
18
  * @author Austin Passy
19
  * @link https://austin.passy.co/
20
+ * @license https://www.gnu.org/licenses/old-licenses/gpl-2.0.html
21
  *
22
  * This program is distributed in the hope that it will be useful,
23
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
24
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
 
25
  */
26
 
27
+ use Dwnload\WpSettingsApi\WpSettingsApi;
28
+ use TheFrosty\CustomLogin\Api\Cron;
29
+ use TheFrosty\CustomLogin\CustomLogin;
30
+ use TheFrosty\CustomLogin\ServiceProvider;
31
+ use TheFrosty\CustomLogin\Settings\Api\Factory;
32
+ use TheFrosty\CustomLogin\Settings\ImportExport;
33
+ use TheFrosty\CustomLogin\Settings\Settings;
34
+ use TheFrosty\CustomLogin\WpAdmin\Dashboard;
35
+ use TheFrosty\CustomLogin\WpAdmin\Extensions;
36
+ use TheFrosty\CustomLogin\WpAdmin\SettingsUpgrades;
37
+ use TheFrosty\CustomLogin\WpAdmin\Tracking;
38
+ use TheFrosty\CustomLogin\WpLogin\Login;
39
+ use TheFrosty\WpUtilities\Plugin\PluginFactory;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
40
 
41
  /**
42
+ * Maybe trigger an error notice "message" on the `admin_notices` action hook.
43
+ * Uses an anonymous function which required PHP >= 5.3.
 
 
 
 
 
 
 
44
  */
45
+ add_action('admin_notices', function () {
46
+ $message = apply_filters('custom_login_shutdown_error_message', '');
47
+ if (!is_admin() || empty($message)) {
48
+ return;
49
  }
50
+ load_plugin_textdomain('custom-login', false, dirname(plugin_basename(__FILE__)) . '/languages/');
51
+ echo wp_kses_post(sprintf('<div class="error">%s</div>', wpautop($message)));
52
+ });
53
+
54
+ if (version_compare(PHP_VERSION, '7.4', '<')) {
55
+ return add_filter('custom_login_shutdown_error_message', function () {
56
+ return sprintf(
57
+ esc_html__(
58
+ 'Notice: Custom Login version 4 requires PHP version >= 7.4, you are running %s, all features are currently disabled.',
59
+ 'custom-login'
60
+ ),
61
+ PHP_VERSION
62
+ );
63
+ });
64
+ } elseif (!is_readable(__DIR__ . '/vendor/autoload.php')) {
65
+ return add_filter('custom_login_shutdown_error_message', function () {
66
+ return esc_html__(
67
+ 'Error: Custom Login can\'t find the autoload file (if installed from GitHub, please run `composer install`), all features are currently disabled.',
68
+ 'custom-login'
69
+ );
70
+ });
71
  }
72
 
73
+ require_once __DIR__ . '/vendor/autoload.php';
74
+ $plugin = PluginFactory::create('custom-login', __FILE__);
75
+ $container = $plugin->getContainer();
76
+ $container->register(new ServiceProvider());
77
+ $plugin
78
+ ->add(new Cron())
79
+ ->addOnHook(CustomLogin::class, 'plugins_loaded', 5)
80
+ ->addOnHook(Dashboard::class, 'load-index.php', 5, true, [Dashboard::getArgs()])
81
+ ->addOnHook(Extensions::class, 'init', 10, true, [$container])
82
+ ->addOnHook(ImportExport::class, 'init', 10, true, [$container])
83
+ ->addOnHook(Login::class, 'init', 2, null, [$container])
84
+ ->addOnHook(Settings::class, 'init', 10, true, [$container])
85
+ ->addOnHook(SettingsUpgrades::class, 'init', 10, null, [$container])
86
+ ->addOnHook(Tracking::class, 'admin_init', 10, true, [$container])
87
+ ->addOnHook(WpSettingsApi::class, 'init', 10, true, [Factory::getPluginSettings($plugin)]);
88
+
89
+ add_action('plugins_loaded', static function () use ($plugin): void {
90
+ $plugin->initialize();
91
+ });
92
+
93
+ register_activation_hook(__FILE__, static function (): void {
94
+ (new CustomLogin())->activate();
95
+ });
96
+
97
+ if (!function_exists('CUSTOMLOGIN')) {
98
+ /**
99
+ * The main function responsible for returning the one true Instance to function everywhere.
100
+ * Use this function like you would a global variable, except without needing to declare the global.
101
+ * @deprecated 4.0.0
102
+ */
103
+ function CUSTOMLOGIN()
104
+ {
105
+ _deprecated_function(__FUNCTION__, '4.0.0');
106
+ }
107
+ }
extensions.json CHANGED
@@ -1 +1,5 @@
1
- {"version":"3.0.0 01\/12\/15","message":"Download the <a href=\"https:\/\/frosty.media\/plugins\/custom-login-bundle\/\" target=\"_blank\">Custom Login Bundle<\/a> and save over $200!","html":"<div class=\"eddri-addon\"> <div class=\"eddri-addon-container\"> <div class=\"eddri-img-wrap\"> <a href=\"https:\/\/frosty.media\/plugins\/custom-login-stealth-login\/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=eddri\" target=\"_blank\"><img class=\"eddri-thumbnail\" src=\"https:\/\/i.imgur.com\/mhuymPG.jpg\"><\/a> <p>Protect your wp-login.php page from brute force attacks.<\/p> <\/div> <h3>Stealth Login<\/h3> <span class=\"eddri-status\">Not Installed<\/span> <a class=\"button\" data-edd-install=\"Custom Login Stealth Login\">Install<\/a> <a class=\"button show-if-not-purchased\" data-toggle=\"purchase-links-1\" style=\"display:none\">Purchase License<\/a> <div id=\"purchase-links-1\" style=\"display:none\"> <ul> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=7819&edd_options[price_id]=0\">Single site license ($25)<\/a><\/li> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=7819&edd_options[price_id]=1\">Up to 5 site licenses ($70)<\/a><\/li> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=7819&edd_options[price_id]=2\">Unlimited site licenses ($100)<\/a><\/li> <\/ul> <\/div> <\/div> <\/div><div class=\"eddri-addon\"> <div class=\"eddri-addon-container\"> <div class=\"eddri-img-wrap\"> <a href=\"https:\/\/frosty.media\/plugins\/custom-login-page-template\/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=eddri\" target=\"_blank\"><img class=\"eddri-thumbnail\" src=\"https:\/\/i.imgur.com\/A0rzS9q.jpg\"><\/a> <p>Add a login form to any WordPress page.<\/p> <\/div> <h3>Page Template<\/h3> <span class=\"eddri-status\">Not Installed<\/span> <a class=\"button\" data-edd-install=\"Custom Login Page Template\">Install<\/a> <a class=\"button show-if-not-purchased\" data-toggle=\"purchase-links-2\" style=\"display:none\">Purchase License<\/a> <div id=\"purchase-links-2\" style=\"display:none\"> <ul> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=13528\">One price! ($35)<\/a><\/li> <\/ul> <\/div> <\/div> <\/div><div class=\"eddri-addon\"> <div class=\"eddri-addon-container\"> <div class=\"eddri-img-wrap\"> <a href=\"https:\/\/frosty.media\/plugins\/wordpress-login-redirects\/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=eddri\" target=\"_blank\"><img class=\"eddri-thumbnail\" src=\"https:\/\/i.imgur.com\/aNGoyAa.jpg\"><\/a> <p>Manage redirects after logging in.<\/p> <\/div> <h3>Login Redirects<\/h3> <span class=\"eddri-status\">Not Installed<\/span> <a class=\"button\" data-edd-install=\"WordPress Login Redirects\">Install<\/a> <a class=\"button show-if-not-purchased\" data-toggle=\"purchase-links-3\" style=\"display:none\">Purchase License<\/a> <div id=\"purchase-links-3\" style=\"display:none\"> <ul> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=14333&edd_options[price_id]=0\">Single site license ($30)<\/a><\/li> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=14333&edd_options[price_id]=1\">Up to 5 site licenses ($70)<\/a><\/li> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=14333&edd_options[price_id]=2\">Unlimited site licenses ($150)<\/a><\/li> <\/ul> <\/div> <\/div> <\/div>"}
 
 
 
 
1
+ {
2
+ "version": "4.0.0 2022-03-10",
3
+ "message": "Download the <a href=\"https:\/\/frosty.media\/plugins\/custom-login-bundle\/\" target=\"_blank\">Custom Login Bundle<\/a> and save over $200!",
4
+ "html": "<div class=\"eddri-addon\"> <div class=\"eddri-addon-container\"> <div class=\"eddri-img-wrap\"> <a href=\"https:\/\/frosty.media\/plugins\/custom-login-stealth-login\/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=eddri\" target=\"_blank\"><img class=\"eddri-thumbnail\" src=\"https:\/\/i.imgur.com\/mhuymPG.jpg\"><\/a> <p>Protect your wp-login.php page from brute force attacks.<\/p> <\/div> <h3>Stealth Login<\/h3> <span class=\"eddri-status\">Not Installed<\/span> <a class=\"button\" data-edd-install=\"Custom Login Stealth Login\">Install<\/a> <a class=\"button show-if-not-purchased\" data-toggle=\"purchase-links-1\" style=\"display:none\">Purchase License<\/a> <div id=\"purchase-links-1\" style=\"display:none\"> <ul> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=7819&edd_options[price_id]=0\">Single site license ($25)<\/a><\/li> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=7819&edd_options[price_id]=1\">Up to 5 site licenses ($70)<\/a><\/li> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=7819&edd_options[price_id]=2\">Unlimited site licenses ($100)<\/a><\/li> <\/ul> <\/div> <\/div> <\/div><div class=\"eddri-addon\"> <div class=\"eddri-addon-container\"> <div class=\"eddri-img-wrap\"> <a href=\"https:\/\/frosty.media\/plugins\/custom-login-page-template\/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=eddri\" target=\"_blank\"><img class=\"eddri-thumbnail\" src=\"https:\/\/i.imgur.com\/A0rzS9q.jpg\"><\/a> <p>Add a login form to any WordPress page.<\/p> <\/div> <h3>Page Template<\/h3> <span class=\"eddri-status\">Not Installed<\/span> <a class=\"button\" data-edd-install=\"Custom Login Page Template\">Install<\/a> <a class=\"button show-if-not-purchased\" data-toggle=\"purchase-links-2\" style=\"display:none\">Purchase License<\/a> <div id=\"purchase-links-2\" style=\"display:none\"> <ul> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=13528\">One price! ($35)<\/a><\/li> <\/ul> <\/div> <\/div> <\/div><div class=\"eddri-addon\"> <div class=\"eddri-addon-container\"> <div class=\"eddri-img-wrap\"> <a href=\"https:\/\/frosty.media\/plugins\/wordpress-login-redirects\/?utm_source=wordpressorg&utm_medium=custom-login&utm_campaign=eddri\" target=\"_blank\"><img class=\"eddri-thumbnail\" src=\"https:\/\/i.imgur.com\/aNGoyAa.jpg\"><\/a> <p>Manage redirects after logging in.<\/p> <\/div> <h3>Login Redirects<\/h3> <span class=\"eddri-status\">Not Installed<\/span> <a class=\"button\" data-edd-install=\"WordPress Login Redirects\">Install<\/a> <a class=\"button show-if-not-purchased\" data-toggle=\"purchase-links-3\" style=\"display:none\">Purchase License<\/a> <div id=\"purchase-links-3\" style=\"display:none\"> <ul> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=14333&edd_options[price_id]=0\">Single site license ($30)<\/a><\/li> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=14333&edd_options[price_id]=1\">Up to 5 site licenses ($70)<\/a><\/li> <li><a href=\"http:\/\/frosty.media\/checkout?edd_action=straight_to_gateway&download_id=14333&edd_options[price_id]=2\">Unlimited site licenses ($150)<\/a><\/li> <\/ul> <\/div> <\/div> <\/div>"
5
+ }
functions.php ADDED
@@ -0,0 +1,127 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php declare(strict_types=1);
2
+
3
+ namespace TheFrosty\CustomLogin;
4
+
5
+ use TheFrosty\CustomLogin\Settings\Api\Factory;
6
+ use TheFrosty\WpUtilities\Plugin\PluginInterface;
7
+ use function add_action;
8
+ use function function_exists;
9
+ use function get_editable_roles;
10
+ use function is_admin;
11
+ use function is_array;
12
+ use function is_string;
13
+ use function preg_match;
14
+ use function sanitize_key;
15
+ use function sprintf;
16
+ use function strpos;
17
+ use function wp_doing_ajax;
18
+ use const WEEK_IN_SECONDS;
19
+
20
+ // Exit if accessed directly
21
+ if (!defined('ABSPATH')) {
22
+ exit;
23
+ }
24
+
25
+ /**
26
+ * Are we on the Custom Login settings page?
27
+ * @param PluginInterface $plugin
28
+ * @return bool
29
+ */
30
+ function isSettingsPage(PluginInterface $plugin): bool
31
+ {
32
+ return $GLOBALS['pagenow'] === 'options-general.php' &&
33
+ isset($_GET['page']) &&
34
+ strpos($plugin->getSlug(), $_GET['page']) !== false;
35
+ }
36
+
37
+ /**
38
+ * Return all editable role capabilities.
39
+ * @return array<string, string>
40
+ */
41
+ function getWpRoles(): array
42
+ {
43
+ $key = sprintf('%1$s%2$s', Factory::PREFIX, sanitize_key(__FUNCTION__));
44
+ $roles = get_transient($key);
45
+ if (empty($roles) && is_admin() && !wp_doing_ajax()) {
46
+ add_action('shutdown', static function () use ($key, &$roles): void {
47
+ $roles = _getEditableRoles();
48
+ set_transient($key, $roles, WEEK_IN_SECONDS);
49
+ });
50
+ }
51
+
52
+ return !is_array($roles) ? ['manage_options' => 'manage_options'] : $roles;
53
+ }
54
+
55
+ /**
56
+ * Browser prefixes.
57
+ * @param string $property
58
+ * @param string $value
59
+ * @return string
60
+ * @since 1.1 (1/8/13)
61
+ */
62
+ function prefixIt(string $property, string $value): string
63
+ {
64
+ $output = "\n\t";
65
+ foreach (['-webkit-', '-moz-', ''] as $prefix) {
66
+ $output .= trailingSemicolonIt(sprintf('%1$s%2$s', $prefix, $property), $value);
67
+ }
68
+
69
+ return $output;
70
+ }
71
+
72
+ /**
73
+ * Add a Trailing Semicolon.
74
+ * @param string $property
75
+ * @param string $value
76
+ * @return string
77
+ * @since 1.1 (1/8/13)
78
+ * @updated 1.1.1 (1/9/13) Remove esc_attr since it's encoding single quotes in image urls with quotes.
79
+ */
80
+ function trailingSemicolonIt(string $property, string $value): string
81
+ {
82
+ return sprintf("%s: %s;\n\t", $property, rtrim($value, ';'));
83
+ }
84
+
85
+ /**
86
+ * Open a new CSS rule.
87
+ * @param string $value
88
+ * @return string
89
+ * @since 2.0
90
+ */
91
+ function openCssRule(string $value): string
92
+ {
93
+ return sprintf("%s {\n\t", rtrim($value, '{'));
94
+ }
95
+
96
+ /**
97
+ * Return all editable role capabilities.
98
+ * @link http://codex.wordpress.org/Function_Reference/get_editable_roles
99
+ * @access private
100
+ * @return array<string, string>
101
+ */
102
+ function _getEditableRoles(): array
103
+ {
104
+ $roles = [];
105
+ $get_editable_roles = !function_exists('get_editable_roles') ? null : get_editable_roles();
106
+ if (empty($get_editable_roles)) {
107
+ return ['manage_options' => 'manage_options'];
108
+ }
109
+ foreach ($get_editable_roles as $role) {
110
+ /*
111
+ * Avoid "Invalid argument supplied for foreach()".
112
+ * @link https://wordpress.org/support/topic/invalid-argument-supplied-for-foreach-error-line-in-wp-dashboard?replies=2#post-6427631
113
+ */
114
+ if (!isset($role['capabilities']) || !is_array($role['capabilities'])) {
115
+ continue;
116
+ }
117
+ foreach ($role['capabilities'] as $capability => $array) {
118
+ // Remove the (deprecated) capabilities from the array
119
+ if (is_string($capability) && preg_match('/^level_/', $capability)) {
120
+ continue;
121
+ }
122
+ $roles[$capability] = $capability;
123
+ }
124
+ }
125
+
126
+ return $roles;
127
+ }
includes/admin/dashboard.php DELETED
@@ -1,299 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Admin/Classes/Dashboard
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014-2015, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- * @since 3.1
9
- */
10
-
11
- // Exit if accessed directly
12
- if ( ! defined( 'ABSPATH' ) ) exit;
13
-
14
- /**
15
- * WordPress dashboard
16
- *
17
- * @access public
18
- * @since 3.1
19
- * @return void
20
- */
21
- class CL_Dashboard {
22
-
23
- /** Singleton *************************************************************/
24
- private static $instance;
25
-
26
- private $id;
27
-
28
- private static $headers = array();
29
- private static $scripts = array();
30
-
31
- const FEED_URL = 'https://frosty.media/wp-json/wp/v2/posts';
32
-
33
- /**
34
- * Main Instance
35
- *
36
- * @staticvar array $instance
37
- * @return CL_Dashboard The one true instance
38
- */
39
- public static function instance() {
40
- if ( ! isset( self::$instance ) ) {
41
- self::$instance = new self;
42
- self::$instance->id = sprintf( '%s-dashboard', CUSTOM_LOGIN_DIRNAME );
43
- self::$instance->actions();
44
- }
45
- return self::$instance;
46
- }
47
-
48
- private function actions() {
49
-
50
- if (!is_blog_admin()) {
51
- return;
52
- }
53
-
54
- add_action( 'wp_dashboard_setup', array( $this, 'add_dashboard_widget' ) );
55
- add_action( 'admin_enqueue_scripts', array( $this, 'inline_scripts' ) );
56
- add_action( 'admin_footer', array( $this, 'admin_footer' ) );
57
- }
58
-
59
- /**
60
- * Check if the dashboard widget is allowed.
61
- *
62
- * @access private
63
- * @return bool
64
- */
65
- private function dashboard_allowed() {
66
- $dashboard = CL_Common::get_option( 'dashboard_widget', 'general', 'off' );
67
-
68
- if ( 'on' === $dashboard )
69
- return true;
70
-
71
- return false;
72
- }
73
-
74
- /**
75
- * Add Dashboard widget
76
- */
77
- public function add_dashboard_widget() {
78
-
79
- if (!$this->dashboard_allowed()) {
80
- return;
81
- }
82
-
83
- wp_add_dashboard_widget(
84
- $this->id,
85
- __( 'Frosty Media', CUSTOM_LOGIN_DIRNAME ),
86
- array( $this, 'widget' )
87
- );
88
- }
89
-
90
- public function admin_footer() {
91
- if ( $this->dashboard_allowed() ) {
92
- $this->CSS( false );
93
- } else {
94
- $this->jQuery( false );
95
- }
96
- }
97
-
98
- /**
99
- * @param int $count
100
- * @param string $feed
101
- * @return array|bool
102
- */
103
- private function get_feed( $count = 1, $feed = self::FEED_URL ) {
104
- return CL_Common::get_posts_via_rest( $feed, $count );
105
- }
106
-
107
- private function get_feed_url() {
108
- $rss_items = $this->get_feed();
109
- if (isset($rss_items[0])) {
110
- return esc_url(
111
- add_query_arg(
112
- [
113
- 'utm_medium' => 'wpadmin_dashboard',
114
- 'utm_term' => 'newsitem',
115
- 'utm_campaign' => CUSTOM_LOGIN_DIRNAME,
116
- ],
117
- array_shift($rss_items)->guid->rendered
118
- )
119
- );
120
- }
121
-
122
- return esc_url( self::FEED_URL );
123
- }
124
-
125
- private function get_feed_title() {
126
-
127
- $rss_items = $this->get_feed();
128
-
129
- return empty( $rss_items ) ? 'Unknown' : esc_html( array_shift($rss_items)->title->rendered );
130
- }
131
-
132
- /**
133
- * Dashboard widget
134
- */
135
- public function widget() {
136
- // FEED
137
- $posts = $this->get_feed(2);
138
-
139
- $content = '<div class="rss-widget">';
140
- $content .= '<ul>';
141
-
142
- if ( empty($posts) ) {
143
- $content .= '<li>' . __( 'Error fetching feed', CUSTOM_LOGIN_DIRNAME ) . '</li>';
144
- } else {
145
- $count = 1;
146
- foreach ( $posts as $item ) {
147
- $content .= '<li>';
148
- $content .= '<a class="rsswidget" href="' . esc_url( add_query_arg( array( 'utm_medium' => 'wpadmin_dashboard', 'utm_term' => 'newsitem', 'utm_campaign' => CUSTOM_LOGIN_DIRNAME ), $item->guid->rendered ) ) . '">' . esc_html( $item->title->rendered ) . '</a>';
149
- $content .= $count === 1 ? '&nbsp;&nbsp;&nbsp;<span class="rss-date">' . date_i18n( get_option( 'date_format' ), strtotime( $item->date ) ) . '</span>' : '';
150
- $content .= $count === 1 ? '<div class="rssSummary">' . strip_tags( wp_trim_words( $item->content->rendered, 28 ) ) . '</div>' : '';
151
- $content .= '</li>';
152
- $count++;
153
- }
154
- }
155
- $content .= '</ul>';
156
- $content .= '</div>';
157
-
158
-
159
- // Plugins (Taxonomy: plugin_tag; Term: custom-login-extension; Term ID: 29)
160
- $extensions = $this->get_feed(
161
- 10,
162
- sprintf('%s?plugin_tag=29', str_replace('/posts', '/extensions', self::FEED_URL))
163
- );
164
-
165
- if (!empty($extensions)) {
166
- $content .= '<div class="rss-widget">';
167
- $content .= '<ul>';
168
- $content .= '<li><strong>' . __('Custom Login Extensions:', CUSTOM_LOGIN_DIRNAME) . '</strong></li>';
169
- $content .= '<li>';
170
- $item = $extensions[array_rand($extensions)];
171
- $content .= '<a class="rsswidget" href="' . esc_url(add_query_arg([
172
- 'utm_medium' => 'wpadmin_dashboard',
173
- 'utm_term' => 'newsitem',
174
- 'utm_campaign' => CUSTOM_LOGIN_DIRNAME,
175
- ], $item->guid->rendered)) . '">' . esc_html($item->title->rendered) . '</a>';
176
- // $content .= '<div class="rssSummary">' . strip_tags( wp_trim_words( $item->content->rendered, 10 ) ) . '</div>';
177
- $content .= '</li>';
178
- $content .= '</ul>';
179
- $content .= '</div>';
180
- }
181
-
182
- $content .= '<div class="rss-widget">';
183
- $content .= '<ul class="social">';
184
- $content .= '<li>';
185
- $content .= '<a href="https://twitter.com/Frosty_Media"><span class="dashicons dashicons-twitter"></span>/Frosty_Media</a> | ';
186
- $content .= '<a href="https://twitter.com/TheFrosty"><span class="dashicons dashicons-twitter"></span>/TheFrosty</a>';
187
- $content .= '</li>';
188
- $content .= '</ul>';
189
-
190
- $content .= '</div>';
191
-
192
- echo $content;
193
- }
194
-
195
- /**
196
- * Generate the custom CSS/JS.
197
- *
198
- */
199
- public function inline_scripts() {
200
-
201
- if ( isset( $_GET[ $this->id ] ) && intval( $_GET[ $this->id ] ) === 1 ) {
202
-
203
- if ( isset( $_GET['type'] ) && $_GET['type'] === 'css' ) {
204
-
205
- if ( !headers_sent() ) {
206
- header("content-type:text/css");
207
- }
208
- ob_start();
209
- $this->CSS();
210
- if ( ob_get_level() ) echo ob_get_clean();
211
- die;
212
- } elseif ( isset( $_GET['type'] ) && $_GET['type'] === 'js' ) {
213
-
214
- if ( !headers_sent() ) {
215
- header("content-type:application/x-javascript");
216
- }
217
- ob_start();
218
- $this->jQuery();
219
- if ( ob_get_level() ) echo ob_get_clean();
220
- die;
221
- }
222
- }
223
- }
224
-
225
- public function clean_ob_contents( $contents ) {
226
- return str_replace( $contents, '', $contents );
227
- }
228
-
229
- /**
230
- * Helper function to return the proper query arg.
231
- */
232
- private function add_query_arg( $type = 'js' ) {
233
- $url = add_query_arg(
234
- array(
235
- $this->id => '1',
236
- 'type' => $type
237
- ),
238
- trailingslashit( admin_url() )
239
- );
240
- return esc_url( $url );
241
- }
242
-
243
- /**
244
- * Create the CSS.
245
- *
246
- * @param bool $remove_wrapper
247
- */
248
- private function CSS( $remove_wrapper = true ) {
249
- if ( !$remove_wrapper ) { ?>
250
- <style>
251
- <?php }
252
- #<?php echo $this->id; ?> .inside {
253
- margin: 0;
254
- padding: 0;
255
- }
256
- #<?php echo $this->id; ?> .rss-widget {
257
- border-bottom: 1px solid #eee;
258
- font-size: 13px;
259
- padding: 8px 12px 10px;
260
- }
261
- <?php if ( !$remove_wrapper ) { ?>
262
- </style>
263
- <?php }
264
- }
265
-
266
- /**
267
- * Create the jQuery.
268
- *
269
- * @param bool $remove_wrapper
270
- */
271
- private function jQuery( $remove_wrapper = true ) {
272
- if ( !$remove_wrapper ) { ?>
273
- <script>
274
- <?php } ?>
275
- jQuery(document).ready(function($) {
276
- if ( !$('div.wordpress-news:visible') ) {
277
- return;
278
- }
279
-
280
- let CL_Timeout = 200
281
-
282
- if ( !$('#dashboard_primary .rss-widget').eq(1).length ) {
283
- CL_Timeout = 2500;
284
- }
285
-
286
- setTimeout( function() {
287
- $('#dashboard_primary .rss-widget:eq(1) ul').append('<li><a class="rsswidget" target="_blank" href="<?php echo $this->get_feed_url(); ?>">Frosty Media: <?php echo $this->get_feed_title(); ?></a></li>');
288
- }, CL_Timeout );
289
-
290
- });
291
- <?php if ( !$remove_wrapper ) { ?>
292
- </script>
293
- <?php }
294
- }
295
-
296
- }
297
-
298
- // Only load on the WordPress Dashboard (index.php) page.
299
- add_action( 'load-index.php', array( 'CL_Dashboard', 'instance' ), 99 );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/admin/import-export.php DELETED
@@ -1,296 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Classes/CL_Import_Export
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014-2015, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- */
9
-
10
- // Exit if accessed directly
11
- if ( !defined( 'ABSPATH' ) ) exit;
12
-
13
-
14
- /**
15
- * Usage tracking
16
- *
17
- * @access public
18
- * @since 3.1
19
- * @return void
20
- */
21
- class CL_Import_Export {
22
-
23
- /** Singleton *************************************************************/
24
- private static $instance;
25
-
26
- /**
27
- * The menu
28
- *
29
- * @access private
30
- */
31
- private $settings_api;
32
- private $settings_id;
33
-
34
- /**
35
- * Main Instance
36
- *
37
- * @staticvar array $instance
38
- * @return The one true instance
39
- */
40
- public static function instance() {
41
- if ( ! isset( self::$instance ) ) {
42
- self::$instance = new self;
43
- self::$instance->init();
44
- }
45
- return self::$instance;
46
- }
47
-
48
- /**
49
- * Get things going
50
- *
51
- * @access public
52
- * @return void
53
- */
54
- public function init() {
55
-
56
- add_action( 'admin_init', array( $this, 'admin_init' ) );
57
- add_action( CUSTOM_LOGIN_OPTION . '_settings_sidebars', array( $this, 'settings_sidebar' ), 30 );
58
- add_action( CUSTOM_LOGIN_OPTION . '_after_settings_sections_form', array( $this, 'after_settings_sections_form' ), 11 );
59
- add_action( 'admin_action_' . CUSTOM_LOGIN_OPTION . '_download_export', array( $this, 'download_export' ) );
60
- }
61
-
62
- /**
63
- * Set our settings fields
64
- *
65
- * @access private
66
- */
67
- private function settings_fields() {
68
-
69
- $fields [ $this->settings_id ] = array(
70
- array(
71
- 'name' => 'import',
72
- 'label' => __( 'Import', CUSTOM_LOGIN_DIRNAME ),
73
- 'desc' => '',
74
- 'type' => 'textarea',
75
- 'sanitize' => '__return_empty_string',
76
- ),
77
-
78
- array(
79
- 'name' => 'export',
80
- 'label' => __( 'Export', CUSTOM_LOGIN_DIRNAME ),
81
- 'desc' => sprintf( __( 'This textarea is always pre-filled with the current settings. Copy these settings for import at a later time, or <a href="%s">download</a> them.', CUSTOM_LOGIN_DIRNAME ),
82
- esc_url( wp_nonce_url(
83
- add_query_arg( array( 'action' => CUSTOM_LOGIN_OPTION . '_download_export' ),
84
- ''
85
- ),
86
- 'export',
87
- 'cl_nonce'
88
- ) )
89
- ),
90
- 'default' => $this->get_custom_login_settings(),
91
- 'type' => 'textarea',
92
- 'extra' => array(
93
- 'readonly' => 'readonly'
94
- ),
95
- 'sanitize' => '__return_empty_string',
96
- ),
97
-
98
- );
99
-
100
- return $fields;
101
- }
102
-
103
- /**
104
- * Return the full array of settings
105
- *
106
- * @access private
107
- */
108
- private function get_custom_login_settings() {
109
-
110
- $settings = array();
111
- include( trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/default-settings.php' );
112
-
113
- foreach ( $sections as $section ) {
114
- $settings[ $section['id'] ] = get_option( $section['id'] );
115
- }
116
-
117
- return base64_encode( maybe_serialize( $settings ) );
118
-
119
- # var_dump( $settings ); exit;
120
- }
121
-
122
- public function admin_init() {
123
-
124
- $this->settings_api = CUSTOMLOGIN()->settings_api;
125
- $this->settings_id = CUSTOM_LOGIN_OPTION . '_import_export';
126
-
127
- add_settings_section( $this->settings_id, __( 'Import/Export Custom Login Settings', CUSTOM_LOGIN_DIRNAME ), '__return_false', $this->settings_id );
128
-
129
- foreach( $this->settings_fields() as $section => $field ) {
130
- foreach ( $field as $option ) {
131
-
132
- $type = isset( $option['type'] ) ? $option['type'] : 'text';
133
-
134
- $args = array(
135
- 'id' => $option['name'],
136
- 'desc' => isset( $option['desc'] ) ? $option['desc'] : '',
137
- 'name' => $option['label'],
138
- 'section' => $section,
139
- 'size' => isset( $option['size'] ) ? $option['size'] : null,
140
- 'options' => isset( $option['options'] ) ? $option['options'] : '',
141
- 'default' => isset( $option['default'] ) ? $option['default'] : '',
142
- 'sanitize' => isset( $option['sanitize'] ) ? $option['sanitize'] : '',
143
- );
144
- $args = wp_parse_args( $args, $option );
145
-
146
- add_settings_field( $section . '[' . $option['name'] . ']', $option['label'], array( $this->settings_api, 'callback_' . $type ), $section, $section, $args );
147
- }
148
- }
149
-
150
- register_setting( $this->settings_id, $this->settings_id, array( $this, 'sanitize_options' ) );
151
- }
152
-
153
- /**
154
- * Box with a link to the extensions page.
155
- */
156
- function settings_sidebar( $args ) {
157
-
158
- $html = '<ul class="cl-sections-menu">';
159
- $html .= sprintf( '<li><a href="#%1$s">%2$s</a></li>', $this->settings_id, __( 'Import/Export Settings' ) );
160
- $html .= '</ul>';
161
-
162
- echo $html;
163
- }
164
-
165
- /**
166
- * Show the import/export settings form.
167
- */
168
- function after_settings_sections_form() {
169
- ?>
170
- <div id="<?php echo $this->settings_id; ?>" class="group">
171
- <form action="options.php" id="<?php echo $this->settings_id; ?>form" method="post" >
172
- <?php settings_fields( $this->settings_id ); ?>
173
- <?php do_settings_sections( $this->settings_id ); ?>
174
- <?php submit_button(); ?>
175
- </form>
176
- </div><?php
177
- }
178
-
179
- /**
180
- * Sanitize callback for Settings API before input into database.
181
- *
182
- * @ref http://stackoverflow.com/a/10797086/558561
183
- */
184
- public function maybe_import_settings( $options ) {
185
-
186
- if ( !empty( $options['import'] ) && ( base64_encode( base64_decode( $options['import'], true ) ) === $options['import'] ) ) {
187
- $import = maybe_unserialize( base64_decode( $options['import'] ) );
188
- # var_dump( $import ); exit;
189
- if ( is_array( $import ) ) {
190
- foreach( $import as $setting_key => $settings ) {
191
- if ( false !== $settings ) {
192
- if ( update_option( $setting_key, $settings ) ) {
193
- add_settings_error(
194
- $this->settings_id ,
195
- esc_attr( 'settings_updated' ),
196
- __( 'Custom Login settings successfully imported', CUSTOM_LOGIN_DIRNAME ),
197
- 'updated'
198
- );
199
- }
200
- }
201
- }
202
- }
203
- }
204
- }
205
-
206
- /**
207
- * Sanitize callback for Settings API
208
- */
209
- function sanitize_options( $options ) {
210
-
211
- $this->maybe_import_settings( $options );
212
-
213
- foreach( $options as $option_slug => $option_value ) {
214
- $sanitize_callback = $this->get_sanitize_callback( $option_slug );
215
-
216
- // If callback is set, call it
217
- if ( $sanitize_callback ) {
218
- $options[ $option_slug ] = call_user_func( $sanitize_callback, $option_value );
219
- continue;
220
- }
221
-
222
- // Treat everything that's not an array as a string
223
- if ( !is_array( $option_value ) ) {
224
- $options[ $option_slug ] = sanitize_text_field( $option_value );
225
- continue;
226
- }
227
- }
228
-
229
- $options = $this->after_sanitize_options( $options );
230
-
231
- return $options;
232
- }
233
-
234
- /**
235
- * Get sanitization callback for given option slug
236
- *
237
- * @param string $slug option slug
238
- *
239
- * @return mixed string or bool false
240
- */
241
- function get_sanitize_callback( $slug = '' ) {
242
-
243
- if ( empty( $slug ) )
244
- return false;
245
-
246
- // Iterate over registered fields and see if we can find proper callback
247
- foreach( $this->settings_fields() as $section => $options ) {
248
- foreach ( $options as $option ) {
249
- if ( $option['name'] != $slug )
250
- continue;
251
- // Return the callback name
252
- return isset( $option['sanitize'] ) && is_callable( $option['sanitize'] ) ? $option['sanitize'] : false;
253
- }
254
- }
255
- return false;
256
- }
257
-
258
- function after_sanitize_options( $options ) {
259
-
260
- foreach( $this->settings_fields() as $section => $field ) {
261
- foreach ( $field as $option ) {
262
- unset( $options[ $option['name'] ] );
263
- }
264
- }
265
-
266
- return $options;
267
- }
268
-
269
- /**
270
- * Export the settings.
271
- *
272
- * @ref http://stackoverflow.com/a/16440501/558561
273
- */
274
- function download_export() {
275
-
276
- if ( !isset( $_GET['cl_nonce']) || !wp_verify_nonce( $_GET['cl_nonce'], 'export' ) ) {
277
- wp_redirect( remove_query_arg( array( 'action', 'cl_nonce' ) ) );
278
- exit;
279
- }
280
-
281
- $month = date( 'n' );
282
- $year = date( 'Y' );
283
-
284
- ignore_user_abort(true);
285
-
286
- nocache_headers();
287
- header( 'Content-type: text/plain; charset=utf-8' );
288
- header( 'Content-Disposition: attachment; filename=cl-export-' . $month . '-' . $year . '.txt' );
289
- header( 'Expires: 0' );
290
-
291
- echo $this->get_custom_login_settings();
292
- exit;
293
- }
294
-
295
- }
296
- $GLOBALS['cl_import_export'] = CL_Import_Export::instance();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/admin/plugins.php DELETED
@@ -1,53 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Admin/Plugins
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014-2015, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- * @since 3.0
9
- */
10
-
11
- // Exit if accessed directly
12
- if ( ! defined( 'ABSPATH' ) ) exit;
13
-
14
- /**
15
- * Plugins row action links
16
- *
17
- * @since 3.0
18
- * @param array $links already defined action links
19
- * @param string $file plugin file path and name being processed
20
- * @return array $links
21
- */
22
- function custom_login_plugin_action_links( $links, $file ) {
23
- $settings_link = '<a href="' . sprintf( admin_url( 'options-general.php?page=%s' ), CUSTOM_LOGIN_DIRNAME ) . '">' . esc_html__( 'Settings', CUSTOM_LOGIN_DIRNAME ) . '</a>';
24
- if ( $file == CUSTOM_LOGIN_BASENAME )
25
- array_unshift( $links, $settings_link );
26
-
27
- return $links;
28
- }
29
- add_filter( 'plugin_action_links', 'custom_login_plugin_action_links', 10, 2 );
30
-
31
-
32
- /**
33
- * Plugin row meta links
34
- *
35
- * @since 3.0
36
- * @param array $input already defined meta links
37
- * @param string $file plugin file path and name being processed
38
- * @return array $input
39
- */
40
- function custom_login_plugin_row_meta( $input, $file ) {
41
- if ( $file != CUSTOM_LOGIN_BASENAME )
42
- return $input;
43
-
44
- $links = array(
45
- '<a href="' . sprintf( admin_url( 'options-general.php?page=%s/extensions' ), CUSTOM_LOGIN_DIRNAME ) . '">' . esc_html__( 'Extension Installer', CUSTOM_LOGIN_DIRNAME ) . '</a>',
46
- '<a href="https://frosty.media/plugin/tag/custom-login-extension/" target="_blank">' . esc_html__( 'Add Ons', CUSTOM_LOGIN_DIRNAME ) . '</a>',
47
- );
48
-
49
- $input = array_merge( $input, $links );
50
-
51
- return $input;
52
- }
53
- add_filter( 'plugin_row_meta', 'custom_login_plugin_row_meta', 10, 2 );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/admin/tracking.php DELETED
@@ -1,284 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Classes/CL_Tracking
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014-2015, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- */
9
-
10
- // Exit if accessed directly
11
- if ( !defined( 'ABSPATH' ) ) exit;
12
-
13
-
14
- /**
15
- * Usage tracking
16
- *
17
- * @access public
18
- * @since 3.0.0
19
- * @return void
20
- */
21
- class CL_Tracking {
22
-
23
- /**
24
- * The data to send to the FM site
25
- *
26
- * @access private
27
- */
28
- private $data;
29
- private $option;
30
- private $api;
31
-
32
- /**
33
- * Get things going
34
- *
35
- * @access public
36
- * @return void
37
- */
38
- public function __construct() {
39
-
40
- $this->option = CUSTOM_LOGIN_OPTION . '_general';
41
- $this->api = CUSTOM_LOGIN_API_URL . 'cl-checkin-api/?edd_action=cl_checkin';
42
-
43
- if ( defined( 'WP_LOCAL_DEV' ) && WP_LOCAL_DEV ) {
44
- $this->api = str_replace( CUSTOM_LOGIN_API_URL, 'http://frosty.media.dev/', $this->api );
45
- }
46
-
47
- $this->schedule_send();
48
-
49
- register_activation_hook( CUSTOM_LOGIN_FILE, array( $this, 'activate' ) );
50
-
51
- add_action( CUSTOM_LOGIN_OPTION . '_after_sanitize_options', array( $this, 'check_for_settings_optin' ) );
52
- add_action( 'admin_action_cl_opt_into_tracking', array( $this, 'check_for_optin' ) );
53
- add_action( 'admin_action_cl_opt_out_of_tracking', array( $this, 'check_for_optout' ) );
54
- # add_action( 'admin_notices', array( $this, 'admin_notice' ) );
55
- }
56
-
57
- /**
58
- * Runs on plugin install.
59
- *
60
- * @since 3.0.0
61
- * @return void
62
- */
63
- function activate() {
64
- $this->send_checkin( true, array( 'on_activation' => 'yes' ) );
65
- }
66
-
67
- /**
68
- * Check if the user has opted into tracking
69
- *
70
- * @access private
71
- * @return bool
72
- */
73
- private function tracking_allowed() {
74
- $tracking = CL_Common::get_option( 'tracking', 'general', 'off' );
75
-
76
- if ( 'on' === $tracking )
77
- return true;
78
-
79
- return false;
80
- }
81
-
82
- /**
83
- * Setup the data that is going to be tracked
84
- *
85
- * @access private
86
- * @return void
87
- */
88
- private function setup_data( $extra_data = array() ) {
89
-
90
- $data = array();
91
-
92
- $theme_data = wp_get_theme();
93
- $theme = $theme_data->Name . ' ' . $theme_data->Version;
94
-
95
- $data['url'] = home_url();
96
- $data['version'] = get_bloginfo( 'version' );
97
- $data['theme'] = $theme;
98
- $data['email'] = get_bloginfo( 'admin_email' );
99
-
100
- // Retrieve current plugin information
101
- if ( ! function_exists( 'get_plugins' ) ) {
102
- include ABSPATH . '/wp-admin/includes/plugin.php';
103
- }
104
-
105
- $plugins = array_keys( get_plugins() );
106
- $active_plugins = get_option( 'active_plugins', array() );
107
-
108
- foreach ( $plugins as $key => $plugin ) {
109
- if ( in_array( $plugin, $active_plugins ) ) {
110
- // Remove active plugins from list so we can show active and inactive separately
111
- unset( $plugins[ $key ] );
112
- }
113
- }
114
-
115
- $data['active_plugins'] = $active_plugins;
116
- $data['inactive_plugins'] = $plugins;
117
- $data['post_count'] = wp_count_posts( 'post' )->publish;
118
- $data['cl_version'] = CUSTOM_LOGIN_VERSION;
119
-
120
- if ( is_array( $extra_data ) && !empty( $extra_data ) ) {
121
- foreach( $extra_data as $key => $value ) {
122
- $data[$key] = $value;
123
- }
124
- }
125
-
126
- $this->data = $data;
127
- }
128
-
129
- /**
130
- * Send the data to the FM server
131
- *
132
- * @access private
133
- * @return void
134
- */
135
- public function send_checkin( $override = false, $extra_data = array() ) {
136
-
137
- if ( ! $this->tracking_allowed() && ! $override )
138
- return;
139
-
140
- // Send a maximum of once per week
141
- $last_send = $this->get_last_send();
142
- if ( $last_send && $last_send > strtotime( '-1 week' ) )
143
- return;
144
-
145
- $this->setup_data( $extra_data );
146
-
147
- $response = wp_remote_post( esc_url_raw( $this->api ), array(
148
- 'method' => 'POST',
149
- 'timeout' => apply_filters( 'cl_wp_remote_post_timeout', (int) 15 ),
150
- 'redirection' => 5,
151
- 'body' => $this->data,
152
- 'user-agent' => 'CustomLogin/' . CUSTOM_LOGIN_VERSION . '; ' . get_bloginfo( 'url' )
153
- ) );
154
-
155
- if ( !is_wp_error( $response ) ) {
156
- update_option( 'custom_login_tracking_last_send', time() );
157
- }
158
-
159
- }
160
-
161
- /**
162
- * Check for a new opt-in on settings save
163
- *
164
- * This runs during the sanitation of General settings, thus the return
165
- *
166
- * @access public
167
- * @return array
168
- */
169
- public function check_for_settings_optin( $input ) {
170
-
171
- // Send an intial check in on settings save
172
- if ( isset( $input['tracking'] ) && 'on' === $input['tracking'] ) {
173
- $this->send_checkin( true, array( 'on_activation' => 'settings', 'mailchimp_sub' => 'yes' ) );
174
- }
175
-
176
- return $input;
177
- }
178
-
179
- /**
180
- * Check for a new opt-in via the admin notice
181
- *
182
- * @access public
183
- * @return void
184
- */
185
- public function check_for_optin( $data ) {
186
-
187
- $options = get_option( $this->option, array() );
188
-
189
- $options['tracking'] = 'on';
190
- update_option( $this->option, $options );
191
- update_option( 'custom_login_hide_tracking_notice', '1' );
192
-
193
- $this->send_checkin( true, array( 'on_activation' => 'admin notice', 'mailchimp_sub' => 'yes' ) );
194
-
195
- wp_redirect( esc_url( remove_query_arg( 'action' ) ) );
196
- exit;
197
- }
198
-
199
- /**
200
- * Check for a new opt-in via the admin notice
201
- *
202
- * @access public
203
- * @return void
204
- */
205
- public function check_for_optout( $data ) {
206
-
207
- $options = get_option( $this->option, array() );
208
-
209
- $options['tracking'] = 'off';
210
- update_option( $this->option, $options );
211
- update_option( 'custom_login_hide_tracking_notice', '1' );
212
-
213
- wp_redirect( esc_url( remove_query_arg( 'action' ) ) );
214
- exit;
215
- }
216
-
217
- /**
218
- * Get the last time a checkin was sent
219
- *
220
- * @access private
221
- * @return false/string
222
- */
223
- private function get_last_send() {
224
- return get_option( 'custom_login_tracking_last_send' );
225
- }
226
-
227
- /**
228
- * Schedule a weekly checkin
229
- *
230
- * @access private
231
- * @return void
232
- */
233
- private function schedule_send() {
234
- // We send once a week (while tracking is allowed) to check in, which can be used to determine active sites
235
- add_action( 'custom_login_weekly_scheduled_events', array( $this, 'send_checkin' ) );
236
- }
237
-
238
- /**
239
- * Display the admin notice to users that have not opted-in or out
240
- *
241
- * @access public
242
- * @return void
243
- */
244
- public function admin_notice() {
245
-
246
- $options = get_option( $this->option, array() );
247
- $hide_notice = get_option( 'custom_login_hide_tracking_notice' );
248
-
249
- if ( $hide_notice )
250
- return;
251
-
252
- if ( isset( $options['admin_notices'] ) && 'off' === $options['admin_notices'] )
253
- return;
254
-
255
- if ( isset( $options['tracking'] ) )
256
- return;
257
-
258
- if ( ! current_user_can( 'manage_options' ) )
259
- return;
260
-
261
- if (
262
- stristr( network_site_url( '/' ), 'dev' ) !== false ||
263
- stristr( network_site_url( '/' ), 'localhost' ) !== false ||
264
- stristr( network_site_url( '/' ), ':8888' ) !== false // This is common with MAMP on OS X
265
- ) {
266
- update_option( 'custom_login_hide_tracking_notice', '1' ); // Don't update the notice in case someone pushes local to live? Maybe return.
267
- }
268
- else {
269
- $admin_url = admin_url( 'admin.php' );
270
- $optin_url = add_query_arg( 'action', 'cl_opt_into_tracking' );
271
- $optout_url = add_query_arg( 'action', 'cl_opt_out_of_tracking' );
272
-
273
- echo '<div class="updated"><p>';
274
- echo __( 'Allow Custom Login to anonymously track how this plugin is used and help us make the plugin better?<br>Opt-in and receive a 20% discount code for any plugin on our <a href="https://frosty.media/plugins" target="_blank">site</a>. No sensitive data is tracked.', CUSTOM_LOGIN_DIRNAME );
275
- echo '<span class="alignright">';
276
- echo '<a href="' . esc_url( $optin_url ) . '" class="">' . __( 'Allow', CUSTOM_LOGIN_DIRNAME ) . '</a> | ';
277
- echo '&nbsp;<a href="' . esc_url( $optout_url ) . '" class="">' . __( 'Do not allow', CUSTOM_LOGIN_DIRNAME ) . '</a>';
278
- echo '</span>';
279
- echo '</p></div>';
280
- }
281
- }
282
-
283
- }
284
- $GLOBALS['cl_tracking'] = new CL_Tracking;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/class-cl-common.php DELETED
@@ -1,236 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Classes/CL_Common
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014-2015, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- */
9
-
10
- // Exit if accessed directly
11
- if ( !defined( 'ABSPATH' ) ) exit;
12
-
13
- class CL_Common {
14
-
15
- /**
16
- * Return the RSS feed object.
17
- *
18
- * @param string $feed The feed to fetch.
19
- *
20
- * @return object
21
- */
22
- public static function fetch_feed( $feed ) {
23
-
24
- if ( !function_exists( 'fetch_feed' ) ) {
25
- include_once( ABSPATH . WPINC . '/feed.php' );
26
- }
27
-
28
- return fetch_feed( $feed );
29
- }
30
-
31
- /**
32
- * Fetch RSS items from the feed.
33
- *
34
- * @param int $num Number of items to fetch.
35
- * @param string $feed The feed to fetch.
36
- * @return array|bool False on error, array of RSS items on success.
37
- */
38
- public static function fetch_rss_items( $num, $feed ) {
39
-
40
- $rss = self::fetch_feed( $feed );
41
- $maxitems = 0;
42
-
43
- if ( !is_wp_error( $rss ) ) { // Checks that the object is created correctly
44
-
45
- // Figure out how many total items there are, but limit it to 5.
46
- $maxitems = $rss->get_item_quantity( $num );
47
-
48
- // Build an array of all the items, starting with element 0 (first element).
49
- $rss_items = $rss->get_items( 0, $maxitems );
50
-
51
- }
52
- else {
53
- return false;
54
- }
55
-
56
- // If the feed was erroneous
57
- if ( !$rss_items || $maxitems == 0 ) {
58
- $md5 = md5( $feed );
59
- delete_transient( 'feed_' . $md5 );
60
- delete_transient( 'feed_mod_' . $md5 );
61
- $rss = self::fetch_feed( $feed );
62
- $rss_items = $rss->get_items( 0, $rss->get_item_quantity( $num ) );
63
- }
64
-
65
- return $rss_items;
66
- }
67
-
68
- /**
69
- * Helper function to return the data URI.
70
- *
71
- * @return string
72
- */
73
- public static function get_data_uri( $_image, $mime = '' ) {
74
-
75
- $image = trailingslashit( CUSTOM_LOGIN_URL );
76
- $image .= $_image;
77
-
78
- $data = file_exists( $image ) ? base64_encode( file_get_contents( $image ) ) : '';
79
-
80
- return !empty( $data ) ? 'data:image/' . $mime . ';base64,' . $data : '';
81
- }
82
-
83
- /**
84
- * Get's the cached transient key.
85
- *
86
- * @return string
87
- */
88
- public static function get_transient_key( $input ) {
89
-
90
- $len = is_multisite() ? 40 : 45;
91
- $key = 'custom_login_';
92
- $key = $key . substr( md5( $input ), 0, $len - strlen( $key ) );
93
-
94
- return $key;
95
- }
96
-
97
- /**
98
- * Get the value of a settings field
99
- *
100
- * @param string $option settings field name
101
- * @param string $subsection the section name this field belongs to
102
- * @param string $default default text if it's not found
103
- *
104
- * @return string
105
- */
106
- public static function get_option( $option, $subsection = '', $default = '' ) {
107
-
108
- $section = CUSTOM_LOGIN_OPTION . '_' . $subsection;
109
- $setting = get_option( $section, array() );
110
-
111
- if ( isset( $setting[$option] ) ) {
112
- return $setting[$option];
113
- }
114
-
115
- return $default;
116
- }
117
-
118
- /**
119
- * Get all values of a settings section
120
- *
121
- * @param string $subsection the section name this field belongs to
122
- *
123
- * @return array
124
- */
125
- public static function get_options( $subsection = 'design' ) {
126
-
127
- $section = CUSTOM_LOGIN_OPTION . '_' . $subsection;
128
- $settings = get_option( $section, array() );
129
-
130
- return $settings;
131
- }
132
-
133
- /**
134
- * Helper function to make remote calls
135
- *
136
- * @since 3.0.0
137
- * @updated 3.0.8
138
- * @updated 3.2.11 PHP 8 support
139
- * @param string $transient_key
140
- * @param bool $url
141
- * @param string|null $expiration
142
- * @param string $user_agent
143
- * @return array|false|mixed|object
144
- */
145
- public static function wp_remote_get( $transient_key, $url = false, $expiration = null, $user_agent = 'WordPress' ) {
146
-
147
- if ( !$url ) return false;
148
-
149
- if ( 'WordPress' == $user_agent ) {
150
- global $wp_version;
151
- $_version = $wp_version;
152
- }
153
- else {
154
- $_version = CUSTOM_LOGIN_VERSION;
155
- }
156
-
157
- $expiration = null !== $expiration ? $expiration : WEEK_IN_SECONDS;
158
-
159
- # delete_transient( $transient_key );
160
- if ( false === ( $json = get_transient( $transient_key ) ) ) {
161
-
162
- $response = wp_remote_get(
163
- esc_url( $url ),
164
- array(
165
- 'timeout' => apply_filters( 'cl_wp_remote_get_timeout', 15 ),
166
- 'sslverify' => false,
167
- 'user-agent' => $user_agent . '/' . $_version . '; ' . get_bloginfo( 'url' ),
168
- )
169
- );
170
-
171
- if ( !is_wp_error( $response ) ) {
172
-
173
- if ( isset( $response['body'] ) && strlen( $response['body'] ) > 0 ) {
174
-
175
- $json = json_decode( wp_remote_retrieve_body( $response ) );
176
-
177
- // Discount, double check?
178
- if ( is_wp_error( $json ) )
179
- return false;
180
-
181
- // Cache the results for '$expiration'
182
- set_transient( $transient_key, $json, $expiration );
183
-
184
- // Return the data
185
- return $json;
186
- }
187
- }
188
- else {
189
- return false; // Error, lets return!
190
- }
191
- }
192
-
193
- return $json;
194
- }
195
-
196
- /**
197
- * Get posts via REST API.
198
- * @param string $url
199
- * @param int $per_page
200
- * @return array<stdClass>|false
201
- */
202
- public static function get_posts_via_rest( $url, $per_page = 10 ) {
203
- $url = add_query_arg(['per_page' => $per_page], $url);
204
-
205
- return self::wp_remote_get(sprintf('cl_get_posts_via_rest_%s', md5($url)), $url, WEEK_IN_SECONDS);
206
- }
207
-
208
- /**
209
- * Helper function check if we're on our settings page.
210
- *
211
- * @since 3.0.9
212
- */
213
- public static function is_settings_page( $page = '' ) {
214
-
215
- $return = true;
216
- $screen = get_current_screen();
217
-
218
- if ( null !== $screen ) {
219
-
220
- if ( $screen->id != ( CUSTOMLOGIN()->menu_page ) )
221
- $return = false;
222
- }
223
- else {
224
- global $pagenow;
225
-
226
- if ( 'options-general.php' != $pagenow )
227
- $return = false;
228
-
229
- if ( !isset( $_GET['page'] ) || CUSTOM_LOGIN_DIRNAME != $_GET['page'] )
230
- $return = false;
231
- }
232
-
233
- return $return;
234
- }
235
-
236
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/class-cl-cron.php DELETED
@@ -1,89 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Classes/CL_Cron
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014-2015, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- */
9
-
10
- // Exit if accessed directly
11
- if ( ! defined( 'ABSPATH' ) ) exit;
12
-
13
- /**
14
- * CL_Cron Class
15
- *
16
- * This class handles scheduled events
17
- *
18
- */
19
- class CL_Cron {
20
-
21
- /**
22
- * Get things going
23
- *
24
- * @since 1.6
25
- * @see CL_Cron::weekly_events()
26
- */
27
- public function __construct() {
28
- add_filter( 'cron_schedules', array( $this, 'add_schedules' ) );
29
- add_action( 'wp', array( $this, 'schedule_events' ) );
30
- }
31
-
32
- /**
33
- * Registers new cron schedules
34
- *
35
- * @since 1.6
36
- *
37
- * @param array $schedules
38
- * @return array
39
- */
40
- public function add_schedules( $schedules = array() ) {
41
- // Adds once weekly to the existing schedules.
42
- $schedules['weekly'] = array(
43
- 'interval' => 604800,
44
- 'display' => __( 'Once Weekly', CUSTOM_LOGIN_DIRNAME )
45
- );
46
-
47
- return $schedules;
48
- }
49
-
50
- /**
51
- * Schedules our events
52
- *
53
- * @access public
54
- * @since 1.6
55
- * @return void
56
- */
57
- public function schedule_events() {
58
- $this->weekly_events();
59
- $this->daily_events();
60
- }
61
-
62
- /**
63
- * Schedule weekly events
64
- *
65
- * @access private
66
- * @since 1.6
67
- * @return void
68
- */
69
- private function weekly_events() {
70
- if ( ! wp_next_scheduled( 'custom_login_weekly_scheduled_events' ) ) {
71
- wp_schedule_event( current_time( 'timestamp' ), 'weekly', 'custom_login_weekly_scheduled_events' );
72
- }
73
- }
74
-
75
- /**
76
- * Schedule daily events
77
- *
78
- * @access private
79
- * @since 1.6
80
- * @return void
81
- */
82
- private function daily_events() {
83
- if ( ! wp_next_scheduled( 'custom_login_daily_scheduled_events' ) ) {
84
- wp_schedule_event( current_time( 'timestamp' ), 'daily', 'custom_login_daily_scheduled_events' );
85
- }
86
- }
87
-
88
- }
89
- $cl_cron = new CL_Cron;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/class-cl-extensions.php DELETED
@@ -1,282 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Classes/CL_Extensions
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014-2015, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- */
9
-
10
- // Exit if accessed directly
11
- if ( !defined( 'ABSPATH' ) ) exit;
12
-
13
- class CL_Extensions {
14
-
15
- var $extensions = array(),
16
- $checkout_url = '',
17
- $menu_page;
18
-
19
- public function __construct() {
20
-
21
- $this->checkout_url = CUSTOM_LOGIN_API_URL . 'checkout/';
22
-
23
- add_action( CUSTOM_LOGIN_OPTION . '_settings_sidebars', array( $this, 'settings_sidebar' ), 20 );
24
- add_action( 'admin_menu', array( $this, 'admin_menu' ), 10 );
25
- add_action( 'admin_init', array( $this, 'remote_install_client' ), 10 );
26
-
27
- $this->get_extensions();
28
- }
29
-
30
- /**
31
- * Box with a link to the extensions page.
32
- */
33
- function settings_sidebar( $args ) {
34
-
35
- $content = sprintf( __( 'Install Custom Login extensions on <a href="%s">this page</a> with a valid license key. <small>Purchase your license key by clicking the appropriate link below</small>.', CUSTOM_LOGIN_DIRNAME ), sprintf( admin_url( 'options-general.php?page=%s/extensions' ), CUSTOM_LOGIN_DIRNAME ) );
36
-
37
- CUSTOMLOGIN()->settings_api->postbox( 'custom-login-extensions', __( 'Extensions Installer', CUSTOM_LOGIN_DIRNAME ), $content );
38
- }
39
-
40
- public function admin_menu() {
41
-
42
- $this->menu_page = add_options_page(
43
- __( 'Custom Login Extensions', CUSTOM_LOGIN_DIRNAME ),
44
- __( 'Custom Login Extentions', CUSTOM_LOGIN_DIRNAME ),
45
- 'install_plugins',
46
- sprintf( '%s/extensions', CUSTOM_LOGIN_DIRNAME ),
47
- array( $this, 'html' )
48
- );
49
-
50
- remove_submenu_page( 'options-general.php', sprintf( '%s/extensions', CUSTOM_LOGIN_DIRNAME ) );
51
-
52
- add_action( 'load-' . $this->menu_page, array( $this, 'load' ) );
53
- }
54
-
55
- public function load() {
56
- add_action( 'admin_enqueue_scripts', array( $this, 'admin_enqueue' ) );
57
- }
58
-
59
- public function admin_enqueue() {
60
- wp_enqueue_style( CUSTOM_LOGIN_DIRNAME, plugins_url( 'css/admin.css', CUSTOM_LOGIN_FILE ), false, CUSTOM_LOGIN_VERSION, 'screen' );
61
- }
62
-
63
- /**
64
- * Load the remote installer on our setting page only.
65
- *
66
- * @updated 3.1
67
- */
68
- public function remote_install_client() {
69
-
70
- if ( !CL_Common::is_settings_page() )
71
- return;
72
-
73
- if ( !class_exists( 'CL_Remote_Install_Client' ) )
74
- require_once( trailingslashit( CUSTOM_LOGIN_DIR ) . 'includes/libraries/edd-remote-install-client/EDD_Remote_Install_Client.php' );
75
-
76
- $cl_remote_install_client = new CL_Remote_Install_Client(
77
- trailingslashit( CUSTOM_LOGIN_API_URL ) . 'edd-sl-api/',
78
- 'settings_page_custom-login/extensions', // HARD CODE IT!!! Get is with var_dump( get_current_screen() );
79
- array( 'skipplugincheck' => 0, 'url' => home_url() )
80
- );
81
- }
82
-
83
- private function get_extensions() {
84
-
85
- // Save this for a latter date since our checkin for our HTML data doesn't get called on init...
86
- $ext_url = false; //add_query_arg( array( 'edd_action' => 'cl_announcements' ), trailingslashit( CUSTOM_LOGIN_API_URL ) . 'cl-checkin-api/' );
87
- $transient_key = CL_Common::get_transient_key( 'extensions' );
88
- $extensions = CL_Common::wp_remote_get( $transient_key, $ext_url, WEEK_IN_SECONDS, 'CustomLogin' );
89
-
90
- if ( $extensions ) {
91
- $this->extensions[] = $extensions->html;
92
- }
93
- else {
94
- /* Stealth Login */
95
- $this->extensions[] = array(
96
- 'title' => 'Custom Login Stealth Login',
97
- 'description' => 'Protect your wp-login.php page from brute force attacks.',
98
- 'url' => 'https://frosty.media/plugins/custom-login-stealth-login/',
99
- 'image' => 'https://i.imgur.com/mhuymPG.jpg',
100
- 'links' => array(
101
- array(
102
- 'description' => 'Personal',
103
- 'download_id' => '108',
104
- 'price_id' => '1',
105
- 'price' => '$35',
106
- ),
107
- array(
108
- 'description' => 'Plus',
109
- 'download_id' => '108',
110
- 'price_id' => '2',
111
- 'price' => '$95',
112
- ),
113
- array(
114
- 'description' => 'Professional',
115
- 'download_id' => '108',
116
- 'price_id' => '3',
117
- 'price' => '$195',
118
- ),
119
- ),
120
- );
121
-
122
- /* Page Template */
123
- $this->extensions[] = array(
124
- 'title' => 'Custom Login Page Template',
125
- 'description' => 'Add a login form to any WordPress page.',
126
- 'url' => 'https://frosty.media/plugins/custom-login-page-template/',
127
- 'image' => 'https://i.imgur.com/A0rzS9q.jpg',
128
- 'links' => array(
129
- array(
130
- 'description' => 'Personal',
131
- 'download_id' => '120',
132
- 'price_id' => '1',
133
- 'price' => '$35',
134
- ),
135
- array(
136
- 'description' => 'Plus',
137
- 'download_id' => '120',
138
- 'price_id' => '2',
139
- 'price' => '$95',
140
- ),
141
- array(
142
- 'description' => 'Professional',
143
- 'download_id' => '120',
144
- 'price_id' => '3',
145
- 'price' => '$195',
146
- ),
147
- ),
148
- );
149
-
150
- /* Login Redirects */
151
- $this->extensions[] = array(
152
- 'title' => 'Custom Login Redirects',
153
- 'description' => 'Manage redirects after logging in.',
154
- 'url' => 'https://extendd.com/plugin/wordpress-login-redirects/',
155
- 'image' => 'https://i.imgur.com/aNGoyAa.jpg',
156
- 'links' => array(
157
- array(
158
- 'description' => 'Personal',
159
- 'download_id' => '124',
160
- 'price_id' => '1',
161
- 'price' => '$35',
162
- ),
163
- array(
164
- 'description' => 'Plus',
165
- 'download_id' => '124',
166
- 'price_id' => '2',
167
- 'price' => '$95',
168
- ),
169
- array(
170
- 'description' => 'Professional',
171
- 'download_id' => '124',
172
- 'price_id' => '3',
173
- 'price' => '$195',
174
- ),
175
- ),
176
- );
177
-
178
- /* No Password */
179
- $this->extensions[] = array(
180
- 'title' => 'Custom Login No Password',
181
- 'description' => 'Allow users to login without a password.',
182
- 'url' => 'https://frosty.media/plugins/custom-login-no-passowrd-login/',
183
- 'image' => 'https://i.imgur.com/7SXIpi5.jpg',
184
- 'links' => array(
185
- array(
186
- 'description' => 'Personal',
187
- 'download_id' => '128',
188
- 'price_id' => '1',
189
- 'price' => '$35',
190
- ),
191
- array(
192
- 'description' => 'Plus',
193
- 'download_id' => '128',
194
- 'price_id' => '2',
195
- 'price' => '$95',
196
- ),
197
- array(
198
- 'description' => 'Professional',
199
- 'download_id' => '128',
200
- 'price_id' => '3',
201
- 'price' => '$195',
202
- ),
203
- ),
204
- );
205
-
206
- } // if
207
- }
208
-
209
- public function html() {
210
-
211
- $html = '<div class="wrap">';
212
- $html .= '<h2>' . __( 'Available Custom Login Extensions' ) . '</h2>';
213
- $html .= '<form method="post" action="options.php">';
214
- $html .= '<div class="section">';
215
-
216
- foreach( $this->extensions as $key => $extension ) {
217
- $html .= '<div class="col span_1_of_3 eddri-addon">';
218
- $html .= '<div class="eddri-addon-container">';
219
- $html .= '<div class="eddri-img-wrap">';
220
- $html .= '<a href="' . esc_url( add_query_arg( array( 'utm_source' => 'wordpressorg', 'utm_medium' => 'custom-login', 'utm_campaign' => 'eddri' ), $extension['url'] ) ) . '" target="_blank"><img class="eddri-thumbnail" src="' . $extension['image'] . '"></a>';
221
- $html .= '<p>' . $extension['description'] . '</p>';
222
- $html .= '</div>';
223
-
224
- $html .= '<h3>' . $extension['title'] . '</h3>';
225
- $html .= '<span class="eddri-status">Not Installed</span>';
226
- $html .= '<a class="button" data-edd-install="' . $extension['title'] . '">Install</a>';
227
- $html .= '<a class="button show-if-not-purchased" data-toggle="purchase-links-' . $key . '" style="display:none">Purchase License</a>';
228
- $html .= '<div id="purchase-links-' . $key . '" style="display:none">';
229
-
230
- $html .= '<ul>';
231
- foreach( $extension['links'] as $link ) {
232
- $html .= '<li>';
233
- $html .= $link['description'] . ' (' . $link['price'] . '): <a href="' . esc_url( add_query_arg( array( 'edd_action' => 'straight_to_gateway', 'download_id' => $link['download_id'], 'edd_options[price_id]' => $link['price_id'] ), $this->checkout_url ) ) . '">PayPal</a>';
234
- $html .= ' | ';
235
- $html .= '<a href="' . esc_url( add_query_arg( array( 'edd_action' => 'add_to_cart', 'download_id' => $link['download_id'], 'edd_options[price_id]' => $link['price_id'] ), $this->checkout_url ) ) . '">Credit Card</a>';
236
- $html .= '</li>';
237
- }
238
- $html .= '</ul>';
239
-
240
- $html .= '</div>';
241
- $html .= '</div>';
242
- $html .= '</div>';
243
- } // foreach
244
-
245
- $html .= '</div>';
246
- $html .= '</form>';
247
- $html .= $this->footer_script();
248
- $html .= '</div>';
249
-
250
- echo $html;
251
- }
252
-
253
- function footer_script() {
254
- ob_start(); ?>
255
- <script type="text/javascript">
256
- jQuery(document).ready(function($) {
257
-
258
- setTimeout( function() {
259
- // Remote API helper
260
- $('a[data-toggle]').on('click',function(e) {
261
- e.preventDefault();
262
- $('#' + $(this).data('toggle')).toggle();
263
- });
264
-
265
- // Show Purchase button
266
- $('a[data-edd-install]').each(function() {
267
- var $this = $(this);
268
- setTimeout( function() {
269
- if ( $this.prev('.eddri-status').text() === 'Not Installed' ) {
270
- $this.closest( $this.parent() ).children('a.button').hide();
271
- $this.closest( $this.parent() ).children('a.button.show-if-not-purchased').show();
272
- }
273
- }, 500 );
274
- });
275
-
276
- }, 1000 );
277
- });
278
- </script><?php return ob_get_clean();
279
- }
280
-
281
- }
282
- $GLOBALS['cl_extensions'] = new CL_Extensions();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/class-cl-scripts-styles.php DELETED
@@ -1,141 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Classes/CL_Scripts_Styles
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- */
9
-
10
- // Exit if accessed directly
11
- if ( ! defined( 'ABSPATH' ) ) exit;
12
-
13
- /**
14
- *
15
- * @access public
16
- * @since 2.0
17
- * @return void
18
- */
19
- class CL_Scripts_Styles {
20
-
21
- /**
22
- * Helper function to convert HEX to RGB
23
- *
24
- * @ref http://css-tricks.com/snippets/php/convert-hex-to-rgb/#comment-355641
25
- * @return array
26
- */
27
- public static function hex2rgb( $color ) {
28
- if ( $color[0] == '#' ) {
29
- $color = substr( $color, 1 );
30
- }
31
- if ( strlen( $color ) == 6 ) {
32
- list( $r, $g, $b ) = array( $color[0] . $color[1], $color[2] . $color[3], $color[4] . $color[5] );
33
- } elseif ( strlen( $color ) == 3 ) {
34
- list( $r, $g, $b ) = array( $color[0] . $color[0], $color[1] . $color[1], $color[2] . $color[2] );
35
- } else {
36
- return false;
37
- }
38
- $r = hexdec( $r );
39
- $g = hexdec( $g );
40
- $b = hexdec( $b );
41
- return array( 'red' => $r, 'green' => $g, 'blue' => $b );
42
- }
43
-
44
- /**
45
- * Helper function to convert RGB to HEX
46
- *
47
- * @ref http://bavotasan.com/2011/convert-hex-color-to-rgb-using-php/
48
- * @return string
49
- */
50
- public static function rgb2hex( $rgb ) {
51
- $hex = "#";
52
- $hex .= str_pad( dechex( $rgb[0] ), 2, "0", STR_PAD_LEFT );
53
- $hex .= str_pad( dechex( $rgb[1] ), 2, "0", STR_PAD_LEFT );
54
- $hex .= str_pad( dechex( $rgb[2] ), 2, "0", STR_PAD_LEFT );
55
-
56
- return $hex; // returns the hex value including the number sign (#)
57
- }
58
-
59
- /**
60
- * Helper function to convert RGBA to HEX
61
- *
62
- * @ref http://stackoverflow.com/questions/5798129/regular-expression-to-only-allow-whole-numbers-and-commas-in-a-string
63
- * @return string
64
- */
65
- public static function rgba2hex( $rgba ) {
66
- $rgba = preg_replace(
67
- array(
68
- '/[^\d,]/', // Matches anything that's not a comma or number.
69
- '/(?<=,),+/', // Matches consecutive commas.
70
- '/^,+/', // Matches leading commas.
71
- '/,+$/' // Matches trailing commas.
72
- ), '', $rgba );
73
- $rgba = explode( ',', $rgba );
74
-
75
- $hex = "#";
76
- $hex .= str_pad( dechex( $rgba[0] ), 2, "0", STR_PAD_LEFT );
77
- $hex .= str_pad( dechex( $rgba[1] ), 2, "0", STR_PAD_LEFT );
78
- $hex .= str_pad( dechex( $rgba[2] ), 2, "0", STR_PAD_LEFT );
79
-
80
- return $hex; // returns the hex value including the number sign (#)
81
- }
82
-
83
- /**
84
- * Helper function to convert RGB(A) to array
85
- *
86
- * @return bool
87
- */
88
- public static function is_rgba( $str ) {
89
- $is_rgba = strpos( $str, 'rgba' );
90
-
91
- if ( false === $is_rgba )
92
- return false;
93
-
94
- return true;
95
- }
96
-
97
- /**
98
- * Browser prefixes
99
- *
100
- * @since 1.1 (1/8/13)
101
- */
102
- public static function prefixit( $input, $option ) {
103
- $prefix = array( '-webkit-', '-moz-', '-ms-', '-o-', '' );
104
-
105
- $output = "\n\t";
106
-
107
- foreach ( $prefix as $_prefix ) {
108
- $output .= self::trailingsemicolonit( $_prefix . $input . ': ' . esc_attr( $option ) );
109
- }
110
-
111
- return $output;
112
- }
113
-
114
- /**
115
- * Add a semi colon
116
- *
117
- * Remove esc_attr since it's encoding single quotes in image urls with quotes.
118
- *
119
- * @since 1.1 (1/8/13)
120
- * @updated 1.1.1 (1/9/13)
121
- */
122
- public static function trailingsemicolonit( $input ) {
123
- $output = rtrim( $input, ';' );
124
- $output .= ';' . "\n\t";
125
-
126
- return $output;
127
- }
128
-
129
- /**
130
- * Open a new CSS rule
131
- *
132
- * @since 2.0
133
- */
134
- public static function cssrule( $rule ) {
135
- $output = rtrim( $rule, '{' );
136
- $output .= " {\n\t";
137
-
138
- return $output;
139
- }
140
-
141
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/class-cl-settings-api.php DELETED
@@ -1,954 +0,0 @@
1
- <?php
2
-
3
- // Exit if accessed directly
4
- if ( ! defined( 'ABSPATH' ) ) {
5
- exit;
6
- }
7
-
8
- /**
9
- * Custom Login Settings API
10
- */
11
- class CL_Settings_API {
12
-
13
- /**
14
- * Version
15
- */
16
- var $api_version = '2.1.0';
17
-
18
- /**
19
- * @var array
20
- */
21
- private $settings_sections = array();
22
- private $settings_fields = array();
23
- private $settings_sidebars = array();
24
- private $localize_array = array();
25
-
26
- /**
27
- * @var array
28
- */
29
- private $settings = array();
30
-
31
- /**
32
- * Fire away captain!
33
- */
34
- public function __construct( $sections = array(), $fields = array(), $args = array() ) {
35
-
36
- $this->settings = $args;
37
-
38
- if ( ! empty( $sections ) ) {
39
- $this->set_sections( $sections );
40
- }
41
-
42
- if ( ! empty( $fields ) ) {
43
- $this->set_fields( $fields );
44
- }
45
-
46
- add_action( 'load-' . $this->settings['menu_page'], array( $this, 'init' ), 89 );
47
- add_action( 'admin_enqueue_scripts', array( $this, 'admin_enqueue_scripts' ) );
48
- add_action( 'admin_footer', array( $this, 'wp_localize_script' ), 99 );
49
- add_action( 'wp_ajax_' . $this->settings['prefix'] . '_get_form', array( $this, 'get_form' ), 99 );
50
- add_action( 'wp_ajax_' . $this->settings['prefix'] . '_activate_check', array( $this, 'activate_check_ajax' ) );
51
- }
52
-
53
- /**
54
- * Fire any actions needed a little late
55
- *
56
- * @return void
57
- */
58
- public function init() {
59
-
60
- add_action( 'admin_notices', array( $this, 'upgrade_notices' ) );
61
- add_action( $this->settings['prefix'] . '_sticky_admin_notice', array(
62
- $this,
63
- 'sticky_admin_notice_social_links',
64
- ), 10 );
65
- add_action( $this->settings['prefix'] . '_before_submit_button', array( $this, 'is_active_toggle' ), 10 );
66
- add_action( $this->settings['prefix'] . '_settings_sidebars', array( $this, 'about_the_author' ), 19 );
67
- add_action( $this->settings['prefix'] . '_settings_sidebars', array( $this, 'sidebar_feed' ), 20 );
68
- }
69
-
70
- /**
71
- * Enqueue scripts and styles
72
- */
73
- public function admin_enqueue_scripts( $hook ) {
74
- if ( 'settings_page_' . $this->settings['domain'] !== $hook ) {
75
- return;
76
- }
77
-
78
- /* Core */
79
- wp_enqueue_media();
80
- wp_enqueue_script( 'wp-color-picker' );
81
- wp_enqueue_script( 'plugin-install');
82
- wp_enqueue_style( 'wp-color-picker' );
83
- wp_enqueue_style( 'thickbox' );
84
- wp_enqueue_style( 'plugin-install' );
85
-
86
- /* jQuery Chosen */
87
- wp_enqueue_script( 'chosen', plugins_url( 'js/chosen.jquery.min.js', $this->settings['file'] ), array( 'jquery' ), '1.3.0', true );
88
- wp_enqueue_style( 'chosen', plugins_url( 'css/chosen/chosen.min.css', $this->settings['file'] ), null, '1.3.0', 'screen' );
89
-
90
- /* jQuery Sticky */
91
- wp_enqueue_script( 'sticky', plugins_url( 'js/jquery.sticky.js', $this->settings['file'] ), array( 'jquery' ), '1.0.0', true );
92
-
93
- /* Ace */
94
- wp_enqueue_script( 'ace', plugins_url( 'js/ace/src-min-noconflict/ace.js', $this->settings['file'] ), null, '20.12.14', true );
95
- // \wp_enqueue_code_editor(array());
96
-
97
- /* Dashicons */
98
- wp_enqueue_style( 'dashicons' );
99
-
100
- /* Admin */
101
- wp_enqueue_script( $this->settings['domain'], plugins_url( 'js/admin.js', $this->settings['file'] ), array(
102
- 'jquery',
103
- 'jquery-form',
104
- ), $this->settings['version'], true );
105
- wp_enqueue_style( $this->settings['domain'], plugins_url( 'css/admin.css', $this->settings['file'] ), false, $this->settings['version'], 'screen' );
106
-
107
- do_action( "{$this->settings['domain']}_admin_enqueue_scripts" );
108
- }
109
-
110
- /**
111
- * Localize our script array.
112
- */
113
- public function wp_localize_script() {
114
- $this->localize_array['prefix'] = $this->settings['prefix'];
115
- $this->localize_array['blog_id'] = get_current_blog_id();
116
- $this->localize_array['nonce'] = wp_create_nonce( $this->settings['nonce'] );
117
- wp_localize_script( $this->settings['domain'], 'cl_settings_api', $this->localize_array );
118
- }
119
-
120
- /**
121
- * Set settings sections
122
- *
123
- * @param array $sections setting sections array
124
- */
125
- public function set_sections( $sections ) {
126
-
127
- $sections = apply_filters( $this->settings['prefix'] . '_add_settings_sections', $sections );
128
- $this->settings_sections = $sections;
129
-
130
- return $this;
131
- }
132
-
133
- /**
134
- * Add a single section
135
- *
136
- * @param array $section
137
- */
138
- public function add_section( $section ) {
139
-
140
- $this->settings_sections[] = $section;
141
-
142
- return $this;
143
- }
144
-
145
- /**
146
- * Set settings fields
147
- *
148
- * @param array $fields settings fields array
149
- */
150
- public function set_fields( $fields ) {
151
-
152
- $fields = apply_filters( $this->settings['prefix'] . '_add_settings_fields', $fields );
153
- $this->settings_fields = $fields;
154
-
155
- return $this;
156
- }
157
-
158
- /**
159
- * Add a single field
160
- *
161
- * @param array $section
162
- * @param array $field
163
- */
164
- public function add_field( $section, $field ) {
165
-
166
- $defaults = array(
167
- 'name' => '',
168
- 'label' => '',
169
- 'desc' => '',
170
- 'type' => 'text',
171
- );
172
-
173
- $args = wp_parse_args( $field, $defaults );
174
- $this->settings_fields[ $section ][] = $args;
175
-
176
- return $this;
177
- }
178
-
179
- /**
180
- * Add a single section
181
- *
182
- * @param array $section
183
- */
184
- public function add_sidebar( $sidebar = array() ) {
185
-
186
- $sidebar = apply_filters( $this->settings['prefix'] . '_add_settings_sidebar', $sidebar );
187
- if ( ! empty( $sidebar ) ) {
188
- $this->settings_sidebars[] = $sidebar;
189
- }
190
- }
191
-
192
- /**
193
- * Initialize and registers the settings sections and fileds to WordPress
194
- *
195
- * Usually this should be called at `admin_init` hook.
196
- *
197
- * This function gets the initiated settings sections and fields. Then
198
- * registers them to WordPress and ready for use.
199
- */
200
- public function admin_init() {
201
-
202
- //register settings sections
203
- foreach ( $this->settings_sections as $section ) {
204
- if ( false == get_option( $section['id'] ) && ( isset( $section['option'] ) && false !== $section['option'] ) ) {
205
- add_option( $section['id'] );
206
- }
207
-
208
- add_settings_section( $section['id'], $section['title'], '__return_false', $section['id'] );
209
- }
210
-
211
- //register settings fields
212
- foreach ( $this->settings_fields as $section => $field ) {
213
- foreach ( $field as $option ) {
214
-
215
- $type = isset( $option['type'] ) ? $option['type'] : 'text';
216
-
217
- $args = array(
218
- 'id' => $option['name'],
219
- 'desc' => isset( $option['desc'] ) ? $option['desc'] : '',
220
- 'name' => $option['label'],
221
- 'section' => $section,
222
- 'size' => isset( $option['size'] ) ? $option['size'] : null,
223
- 'options' => isset( $option['options'] ) ? $option['options'] : '',
224
- 'default' => isset( $option['default'] ) ? $option['default'] : '',
225
- 'sanitize' => isset( $option['sanitize'] ) ? $option['sanitize'] : '',
226
- 'callback' => isset( $option['class'] ) ? $option['class'] : $this,
227
- );
228
- $args = wp_parse_args( $args, $option );
229
-
230
- add_settings_field( $section . '[' . $option['name'] . ']', $option['label'], array(
231
- $args['callback'],
232
- 'callback_' . $type,
233
- ), $section, $section, $args );
234
- }
235
- }
236
-
237
- // creates our settings in the options table
238
- foreach ( $this->settings_sections as $section ) {
239
- register_setting( $section['id'], $section['id'], array( $this, 'sanitize_options' ) );
240
- }
241
- }
242
-
243
- /**
244
- * Displays a text field for a settings field
245
- *
246
- * @param array $args settings field args
247
- *
248
- * @updated 2.0.2
249
- */
250
- function callback_text( $args ) {
251
-
252
- $value = esc_attr( $this->get_option( $args['id'], $args['section'], $args['default'] ) );
253
- $size = isset( $args['size'] ) && ! is_null( $args['size'] ) ? $args['size'] : 'regular';
254
- $type = isset( $args['type'] ) && ! is_null( $args['type'] ) ? $args['type'] : 'text';
255
-
256
- $html = sprintf( '<input type="%1$s" class="%2$s-text" id="%3$s[%4$s]" name="%3$s[%4$s]" value="%5$s">', $type, $size, $args['section'], $args['id'], $value );
257
- $html .= ! empty( $args['desc'] ) ? sprintf( '<span class="description"> %s</span>', $args['desc'] ) : '';
258
-
259
- echo $html;
260
- }
261
-
262
- /**
263
- * Displays a text field for a settings field
264
- *
265
- * @param array $args settings field args
266
- *
267
- * @since 2.0.2
268
- */
269
- function callback_text_number( $args ) {
270
-
271
- $args['type'] = 'number';
272
- $this->callback_text( $args );
273
- }
274
-
275
- /**
276
- * Displays a text field for a settings field
277
- *
278
- * @param array $args settings field args
279
- */
280
- function callback_text_array( $args ) {
281
-
282
- $value = $this->get_option( $args['id'], $args['section'], $args['default'] );
283
- $size = isset( $args['size'] ) && ! is_null( $args['size'] ) ? $args['size'] : 'regular';
284
-
285
- $html = '<ul style="margin-top:0">';
286
-
287
- if ( is_array( $value ) ) {
288
- foreach ( $value as $key => $val ) {
289
- $html .= '<li>';
290
- $html .= sprintf( '<input type="text" class="%1$s-text" id="%2$s[%3$s]" name="%2$s[%3$s][]" value="%4$s" data-key="%5$s">', $size, $args['section'], $args['id'], esc_attr( $val ), $key );
291
- $html .= sprintf( '<a href="#" class="button dodelete-%1$s[%2$s]">-</a>', $args['section'], $args['id'] );
292
- $html .= '</li>';
293
- }
294
- } else {
295
- $html .= '<li>';
296
- $html .= sprintf( '<input type="text" class="%1$s-text" id="%2$s[%3$s]" name="%2$s[%3$s][]" value="%4$s" data-key="0" data-array="false">', $size, $args['section'], $args['id'], esc_attr( $value ) );
297
- $html .= sprintf( '<a href="#" class="button dodelete-%1$s[%2$s]">-</a>', $args['section'], $args['id'] );
298
- $html .= '</li>';
299
- }
300
-
301
- $html .= '</ul>';
302
- $html .= sprintf( '<a href="#" class="button docopy-%1$s[%2$s]">+</a>', $args['section'], $args['id'] );
303
-
304
- $html .= ! empty( $args['desc'] ) ? sprintf( '<span class="description"> %s</span>', $args['desc'] ) : '';
305
-
306
- echo $html;
307
- }
308
-
309
- /**
310
- * Displays a text field for a settings field
311
- *
312
- * @param array $args settings field args
313
- */
314
- function callback_colorpicker( $args ) {
315
-
316
- $value = esc_attr( $this->get_option( $args['id'], $args['section'], $args['default'] ) );
317
- $check = esc_attr( $this->get_option( $args['id'] . '_checkbox', $args['section'], $args['default'] ) );
318
- $opacity = esc_attr( $this->get_option( $args['id'] . '_opacity', $args['section'], $args['default'] ) );
319
- $size = isset( $args['size'] ) && ! is_null( $args['size'] ) ? $args['size'] : 'small';
320
- $options = array( '1', '0.9', '0.8', '0.7', '0.6', '0.5', '0.4', '0.3', '0.2', '0.1', '0', );
321
- $class = 'on' != $check ? ' hidden' : '';
322
-
323
- /* Localize the array */
324
- $this->localize_array['callback_colorpicker'][] = array( 'id' => $args['id'], 'section' => $args['section'] );
325
-
326
- /* Color */
327
- $html = '<div class="cl-colorpicker-wrap">';
328
- $html .= sprintf( '<input type="text" class="%1$s-text" id="%2$s[%3$s]" name="%2$s[%3$s]" value="%4$s" style="float:left">', $size, $args['section'], $args['id'], $value );
329
-
330
- /* Allow Opacity */
331
- $html .= '<div class="checkbox-wrap">';
332
- $html .= sprintf( '<input type="hidden" name="%1$s[%2$s]" value="off" >', $args['section'], $args['id'] . '_checkbox' );
333
- $html .= sprintf( '<input type="checkbox" class="checkbox" id="%1$s[%2$s]" name="%1$s[%2$s]" value="on"%4$s >', $args['section'], $args['id'] . '_checkbox', $check, checked( $check, 'on', false ) );
334
- $html .= sprintf( __( '<label for="%1$s[%2$s]">Opacity</label>', $this->settings['domain'] ), $args['section'], $args['id'] . '_checkbox' );
335
- $html .= '</div>';
336
-
337
- /* Opacity */
338
- $html .= sprintf( '<select class="%1$s%4$s" name="%2$s[%3$s]" id="%2$s[%3$s]" style="margin-left:70px;">', $size, $args['section'], $args['id'] . '_opacity', $class );
339
- foreach ( $options as $key ) {
340
- $html .= sprintf( '<option value="%s"%s>%s</option>', $key, selected( $opacity, $key, false ), $key );
341
- }
342
- $html .= '</select>';
343
- $html .= '<br class="clear">';
344
- $html .= '</div>';
345
-
346
- $html .= ! empty( $args['desc'] ) ? sprintf( '<span class="description"> %s</span>', $args['desc'] ) : '';
347
-
348
- echo $html;
349
- }
350
-
351
- /**
352
- * Displays a checkbox for a settings field
353
- *
354
- * @param array $args settings field args
355
- */
356
- function callback_checkbox( $args ) {
357
-
358
- $value = esc_attr( $this->get_option( $args['id'], $args['section'], $args['default'] ) );
359
-
360
- $html = '<div class="checkbox-wrap">';
361
- $html .= sprintf( '<input type="hidden" name="%1$s[%2$s]" value="off" >', $args['section'], $args['id'] );
362
- $html .= sprintf( '<input type="checkbox" class="checkbox" id="%1$s[%2$s]" name="%1$s[%2$s]" value="on"%4$s >', $args['section'], $args['id'], $value, checked( $value, 'on', false ) );
363
- $html .= sprintf( '<label for="%1$s[%2$s]"></label>', $args['section'], $args['id'] );
364
- $html .= '</div>';
365
-
366
- $html .= ! empty( $args['desc'] ) ? sprintf( '<span class="description"> %s</span>', $args['desc'] ) : '';
367
-
368
- echo $html;
369
- }
370
-
371
- /**
372
- * Displays a multicheckbox a settings field
373
- *
374
- * @param array $args settings field args
375
- */
376
- function callback_multicheck( $args ) {
377
-
378
- $value = $this->get_option( $args['id'], $args['section'], $args['default'] );
379
-
380
- $html = '<div class="checkbox-wrap">';
381
- $html .= '<ul>';
382
- foreach ( $args['options'] as $key => $label ) {
383
- $checked = isset( $value[ $key ] ) ? $value[ $key ] : '0';
384
- $html .= '<li>';
385
- $html .= sprintf( '<input type="checkbox" class="checkbox" id="%1$s[%2$s][%3$s]" name="%1$s[%2$s][%3$s]" value="%3$s"%4$s >', $args['section'], $args['id'], $key, checked( $checked, $key, false ) );
386
- $html .= sprintf( '<label for="%1$s[%2$s][%4$s]" title="%3$s"> %3$s</label>', $args['section'], $args['id'], $label, $key );
387
- $html .= '</li>';
388
- }
389
- $html .= '</ul>';
390
- $html .= '</div>';
391
-
392
- $html .= ! empty( $args['desc'] ) ? sprintf( '<span class="description"> %s</span>', $args['desc'] ) : '';
393
-
394
- echo $html;
395
- }
396
-
397
- /**
398
- * Displays a multicheckbox a settings field
399
- *
400
- * @param array $args settings field args
401
- */
402
- function callback_radio( $args ) {
403
-
404
- $value = $this->get_option( $args['id'], $args['section'], $args['default'] );
405
-
406
- $html = '<div class="radio-wrap">';
407
- $html .= '<ul>';
408
- foreach ( $args['options'] as $key => $label ) {
409
- $html .= '<li>';
410
- $html .= sprintf( '<input type="radio" class="radio" id="%1$s[%2$s][%3$s]" name="%1$s[%2$s]" value="%3$s"%4$s >', $args['section'], $args['id'], $key, checked( $value, $key, false ) );
411
- $html .= sprintf( '<label for="%1$s[%2$s][%4$s]" title="%3$s"> %3$s</label><br>', $args['section'], $args['id'], $label, $key );
412
- $html .= '</li>';
413
- }
414
- $html .= '</ul>';
415
- $html .= '</div>';
416
-
417
- $html .= ! empty( $args['desc'] ) ? sprintf( '<span class="description"> %s</span>', $args['desc'] ) : '';
418
-
419
- echo $html;
420
- }
421
-
422
- /**
423
- * Displays a selectbox for a settings field
424
- *
425
- * @param array $args settings field args
426
- */
427
- function callback_select( $args ) {
428
-
429
- $value = esc_attr( $this->get_option( $args['id'], $args['section'], $args['default'] ) );
430
- $size = isset( $args['size'] ) && ! is_null( $args['size'] ) ? $args['size'] : 'regular';
431
-
432
- /* Localize the array */
433
- $this->localize_array['callback_select'][] = array( 'id' => $args['id'], 'section' => $args['section'] );
434
-
435
- $html = sprintf( '<select class="%1$s" name="%2$s[%3$s]" id="%2$s[%3$s]">', $size, $args['section'], $args['id'] );
436
- foreach ( $args['options'] as $key => $label ) {
437
- $html .= sprintf( '<option value="%s"%s>%s</option>', $key, selected( $value, $key, false ), $label );
438
- }
439
- $html .= sprintf( '</select>' );
440
-
441
- $html .= ! empty( $args['desc'] ) ? sprintf( '<br><span class="description"> %s</span>', $args['desc'] ) : '';
442
-
443
- echo $html;
444
- }
445
-
446
- /**
447
- * Displays a textarea for a settings field
448
- *
449
- * @param array $args settings field args
450
- */
451
- function callback_textarea( $args ) {
452
-
453
- $value = esc_textarea( $this->get_option( $args['id'], $args['section'], $args['default'] ) );
454
- $size = isset( $args['size'] ) && ! is_null( $args['size'] ) ? $args['size'] : 'regular';
455
- $extra = isset( $args['extra'] ) && is_array( $args['extra'] ) ? $args['extra'] : null;
456
- $param = '';
457
-
458
- if ( null !== $extra ) {
459
- foreach ( $extra as $p_key => $p_value ) {
460
- $param .= $p_key . '="' . $p_value . '"';
461
- }
462
- }
463
-
464
- $html = sprintf( '<textarea rows="5" cols="55" class="%1$s-text" id="%2$s[%3$s]" name="%2$s[%3$s]"%5$s>%4$s</textarea>', $size, $args['section'], $args['id'], stripslashes( $value ), $param );
465
- $html .= ! empty( $args['desc'] ) ? sprintf( '<span class="description"> %s</span>', $args['desc'] ) : '';
466
-
467
- echo $html;
468
- }
469
-
470
- /**
471
- * Displays a HTML for a settings field
472
- *
473
- * @param array $args settings field args
474
- */
475
- function callback_html( $args ) {
476
- static $counter = 0;
477
-
478
- $html = isset( $args['desc'] ) ? sprintf( '<div class="section-%s-%d">%s</div><hr>', $args['section'], $counter, $args['desc'] ) : '';
479
- $counter ++;
480
-
481
- echo $html;
482
- }
483
-
484
- /**
485
- * Displays raw HTML for a settings field
486
- *
487
- * @param array $args settings field args
488
- */
489
- function callback_raw( $args ) {
490
-
491
- $html = isset( $args['desc'] ) ? sprintf( '<div class="raw-html">%s</div>', $args['desc'] ) : '';
492
-
493
- echo $html;
494
- }
495
-
496
- /**
497
- * Displays a rich text textarea for a settings field
498
- *
499
- * @param array $args settings field args
500
- */
501
- function callback_wysiwyg( $args ) {
502
-
503
- $value = wpautop( $this->get_option( $args['id'], $args['section'], $args['default'] ) );
504
- $size = isset( $args['size'] ) && ! is_null( $args['size'] ) ? $args['size'] : '500px';
505
-
506
- $html = sprintf( '<div style="width: %s">', $size );
507
-
508
- ob_start();
509
- wp_editor( $value, $args['section'] . '[' . $args['id'] . ']', array(
510
- 'teeny' => true,
511
- 'textarea_rows' => 10,
512
- ) );
513
-
514
- $html .= ob_get_clean();
515
- $html .= '</div>';
516
-
517
- $html .= ! empty( $args['desc'] ) ? sprintf( '<br><span class="description"> %s</span>', $args['desc'] ) : '';
518
-
519
- echo $html;
520
- }
521
-
522
- /**
523
- * Displays a file upload field for a settings field
524
- *
525
- * @param array $args settings field args
526
- */
527
- function callback_file( $args ) {
528
- static $counter = 0;
529
-
530
- $value = esc_attr( $this->get_option( $args['id'], $args['section'], $args['default'] ) );
531
- $size = isset( $args['size'] ) && ! is_null( $args['size'] ) ? $args['size'] : 'regular';
532
- $id = $args['section'] . '[' . $args['id'] . ']';
533
-
534
- /* Localize the array */
535
- $this->localize_array['callback_file'][] = array( 'id' => $args['id'], 'section' => $args['section'] );
536
-
537
- $html = sprintf( '<input type="text" class="%1$s-text" id="%2$s[%3$s]" name="%2$s[%3$s]" value="%4$s">', $size, $args['section'], $args['id'], $value );
538
- $html .= '<input type="button" class="button ' . $args['id'] . '-browse" id="' . $id . '_button" value="Browse" style="margin-left:5px" >';
539
- $html .= '<input type="button" class="button ' . $args['id'] . '-clear" id="' . $id . '_clear" value="Clear" style="margin-left:5px" >';
540
-
541
- $html .= ! empty( $args['desc'] ) ? sprintf( '<br><span class="description"> %s</span>', $args['desc'] ) : '';
542
-
543
- /* Image */
544
- $html .= '<div id="' . $id . '_preview" class="' . $id . '_preview">';
545
- if ( $value != '' ) {
546
- $check_image = preg_match( '/(^.*\.jpg|jpeg|png|gif|ico*)/i', $value );
547
- if ( $check_image ) {
548
- $html .= '<div class="img-wrapper">';
549
- $html .= '<img src="' . $value . '" alt="" >';
550
- $html .= '<a href="#" class="remove_file_button" rel="' . $id . '">Remove Image</a>';
551
- $html .= '</div>';
552
- }
553
- }
554
- $html .= '</div>';
555
-
556
- echo $html;
557
- }
558
-
559
- /**
560
- * Displays a password field for a settings field
561
- *
562
- * @param array $args settings field args
563
- */
564
- function callback_password( $args ) {
565
-
566
- $value = esc_attr( $this->get_option( $args['id'], $args['section'], $args['default'] ) );
567
- $size = isset( $args['size'] ) && ! is_null( $args['size'] ) ? $args['size'] : 'regular';
568
-
569
- $html = sprintf( '<input type="password" class="%1$s-text" id="%2$s[%3$s]" name="%2$s[%3$s]" value="%4$s">', $size, $args['section'], $args['id'], $value );
570
- $html .= ! empty( $args['desc'] ) ? sprintf( '<span class="description"> %s</span>', $args['desc'] ) : '';
571
-
572
- echo $html;
573
- }
574
-
575
- /**
576
- * Sanitize callback for Settings API
577
- */
578
- function sanitize_options( $options ) {
579
-
580
- if ( is_null( $options ) ) {
581
- return $options;
582
- }
583
-
584
- do_action( $this->settings['prefix'] . '_before_sanitize_options', $options );
585
-
586
- foreach ( $options as $option_slug => $option_value ) {
587
- $sanitize_callback = $this->get_sanitize_callback( $option_slug );
588
-
589
- // If callback is set, call it
590
- if ( $sanitize_callback ) {
591
- $options[ $option_slug ] = call_user_func( $sanitize_callback, $option_value );
592
- continue;
593
- }
594
-
595
- // Treat everything that's not an array as a string
596
- if ( ! is_array( $option_value ) ) {
597
- $options[ $option_slug ] = sanitize_text_field( $option_value );
598
- continue;
599
- }
600
- }
601
-
602
- do_action( $this->settings['prefix'] . '_after_sanitize_options', $options );
603
-
604
- return $options;
605
- }
606
-
607
- /**
608
- * Get sanitization callback for given option slug
609
- *
610
- * @param string $slug option slug
611
- *
612
- * @return mixed string or bool false
613
- */
614
- function get_sanitize_callback( $slug = '' ) {
615
-
616
- if ( empty( $slug ) ) {
617
- return false;
618
- }
619
-
620
- // Iterate over registered fields and see if we can find proper callback
621
- foreach ( $this->settings_fields as $section => $options ) {
622
- foreach ( $options as $option ) {
623
- if ( $option['name'] != $slug ) {
624
- continue;
625
- }
626
-
627
- // Return the callback name
628
- return isset( $option['sanitize'] ) && is_callable( $option['sanitize'] ) ? $option['sanitize'] : false;
629
- }
630
- }
631
-
632
- return false;
633
- }
634
-
635
- /**
636
- * Output our settings HTML
637
- *
638
- */
639
- public function settings_html() { ?>
640
-
641
- <div class="cl-container">
642
-
643
- <div class="cl-header">
644
- <h3><?php _e( 'Custom Login', $this->settings['domain'] ); ?></h3>
645
- <span><?php echo $this->settings['version']; ?></span>
646
- <div>
647
- <?php echo sprintf( __( 'A %s plugin', $this->settings['domain'] ), '<strong><a href="https://frosty.media/" target="_blank">Frosty Media</a></strong>' ); ?>
648
- &nbsp;&nbsp;|&nbsp;&nbsp;<a href="https://twitter.com/Frosty_Media"><span
649
- class="dashicons dashicons-twitter"></span></a>
650
- </div>
651
- </div><!-- #cl-header -->
652
-
653
- <div id="cl-notices">
654
- <h2></h2>
655
- </div><!-- #cl-text -->
656
-
657
- <div id="cl-sticky">
658
- <div class="wrap">
659
- <div id="sticky-admin-notice">
660
- <?php do_action( $this->settings['prefix'] . '_sticky_admin_notice' ); ?>
661
- </div>
662
- <div class="alignright">
663
- <?php do_action( $this->settings['prefix'] . '_before_submit_button' ); ?>
664
- <?php submit_button( __( 'Save Changes', $this->settings['domain'] ), 'primary', 'cl_save', false ); ?>
665
- </div>
666
- <br class="clear">
667
- </div>
668
- </div><!-- #cl-sticky -->
669
-
670
- <div class="cl-sidebar">
671
- <?php $this->show_navigation(); ?>
672
- <?php do_action( $this->settings['prefix'] . '_settings_sidebars', $this->settings_sidebars ); ?>
673
- </div><!-- #cl-header -->
674
-
675
- <div class="cl-main">
676
- <?php $this->show_forms(); ?>
677
- </div><!-- #cl-header -->
678
-
679
- </div><!-- #cl-wrapper -->
680
- <?php
681
- }
682
-
683
- /**
684
- * Show navigation as lists
685
- *
686
- * Shows all the settings section labels as list items
687
- */
688
- private function show_navigation() {
689
-
690
- $html = '<ul class="cl-sections-menu">';
691
- foreach ( $this->settings_sections as $tab ) {
692
- $html .= sprintf( '<li><a href="%1$s">%2$s</a></li>', isset( $tab['href'] ) ? $tab['href'] : '#' . $tab['id'], $tab['title'] );
693
- }
694
- $html .= '</ul>';
695
-
696
- echo $html;
697
- }
698
-
699
- /**
700
- * Show the section settings forms
701
- *
702
- * This function displays every sections in a different form
703
- */
704
- private function show_forms() {
705
-
706
- foreach ( $this->settings_sections as $form ) {
707
- $form_id = $form['id']; ?>
708
- <div id="<?php echo $form_id; ?>" class="group">
709
- <form action="options.php" id="<?php echo $form_id; ?>form" method="post">
710
- <?php do_action( $this->settings['prefix'] . '_form_top_' . $form_id, $form ); ?>
711
- <?php settings_fields( $form_id ); ?>
712
- <?php do_settings_sections( $form_id ); ?>
713
- <?php do_action( $this->settings['prefix'] . '_form_bottom_' . $form_id, $form ); ?>
714
- <?php if ( isset( $form['submit'] ) && $form['submit'] ) {
715
- submit_button( sprintf( __( 'Save %s', $this->settings['domain'] ), $form['title'] ) );
716
- } ?>
717
- </form>
718
- </div><?php
719
- # var_dump( $form_id, get_option( $form_id ) );
720
- }
721
- do_action( $this->settings['prefix'] . '_after_settings_sections_form' );
722
- }
723
-
724
- /**
725
- * Show the section settings forms
726
- *
727
- * This function displays every sections in a different form
728
- */
729
- public function get_form() {
730
-
731
- check_ajax_referer( $this->settings['nonce'], 'nonce' );
732
-
733
- if ( isset( $_POST['form_id'] ) ) {
734
-
735
- $setting_form = array();
736
- $setting_form['error'] = 1;
737
-
738
- foreach ( $this->settings_sections as $form ) {
739
- $form_id = $form['id'];
740
- if ( str_replace( '#', '', $_POST['form_id'] ) !== $form_id ) {
741
- continue;
742
- }
743
- ob_start(); ?>
744
- <form action="options.php" id="<?php echo $form_id; ?>form" method="post">
745
- <?php do_action( $this->settings['prefix'] . '_form_top_' . $form['id'], $form ); ?>
746
- <?php settings_fields( $form['id'] ); ?>
747
- <?php do_settings_sections( $form['id'] ); ?>
748
- <?php do_action( $this->settings['prefix'] . '_form_bottom_' . $form['id'], $form ); ?>
749
- <?php submit_button( sprintf( __( 'Save %s Changes', $this->settings['domain'] ), $form_id ) ); ?>
750
- </form><?php
751
- $setting_form['error'] = 0;
752
- $setting_form['html'] = ob_get_clean();
753
- }
754
-
755
- header( 'Content-Type: application/json' );
756
- echo json_encode( $setting_form );
757
- die();
758
- }
759
- }
760
-
761
- /**
762
- * Show the section settings forms
763
- *
764
- * This function displays every sections in a different form
765
- */
766
- public function activate_check_ajax() {
767
-
768
- if ( empty( $_POST ) || ! check_ajax_referer( $this->settings['nonce'], 'nonce', false ) ) {
769
- wp_send_json_error();
770
- }
771
-
772
- $settings = CL_Common::get_options( 'general' );
773
- $active_value = isset( $_POST['active_value'] ) && 'true' == $_POST['active_value'] ? 'on' : 'off';
774
- $settings['active'] = $active_value;
775
-
776
- if ( update_option( CUSTOM_LOGIN_OPTION . '_general', $settings ) ) {
777
- wp_send_json_success();
778
- }
779
-
780
- wp_send_json_error();
781
- }
782
-
783
- /**
784
- * Create a potbox widget.
785
- *
786
- * @param string $id ID of the postbox.
787
- * @param string $title Title of the postbox.
788
- * @param string $content Content of the postbox.
789
- */
790
- public function postbox( $id, $title, $content, $group = false ) { ?>
791
-
792
- <div class="metabox-holder<?php if ( $group ) {
793
- echo ' group';
794
- } ?>" id="<?php echo $id; ?>">
795
- <div class="postbox">
796
- <h3><?php echo $title; ?></h3>
797
- <div class="inside"><?php echo $content; ?></div>
798
- </div>
799
- </div><?php
800
- }
801
-
802
- /**
803
- * Global 'active' checkbox notification.
804
- *
805
- * @ref http://codepen.io/pklada/pen/jEGwMB
806
- */
807
- function is_active_toggle() { ?>
808
- <label class="tgl">
809
- <span class="tgl_input"></span>
810
- <span class="tgl_body">
811
- <span class="tgl_switch"></span>
812
- <span class="tgl_track">
813
- <span class="tgl_bgd"></span>
814
- <span class="tgl_bgd tgl_bgd-negative"></span>
815
- </span>
816
- </span>
817
- </label><?php
818
- }
819
-
820
- /**
821
- * Box with latest plugins from Extendd.com for sidebar
822
- */
823
- function about_the_author( $args ) {
824
-
825
- $content = sprintf( '%s: <a href="https://wordpress.org/support/view/plugin-reviews/custom-login" class="star-rating" target="_blank">
826
- <i class="dashicons dashicons-star-filled"></i>
827
- <i class="dashicons dashicons-star-filled"></i>
828
- <i class="dashicons dashicons-star-filled"></i>
829
- <i class="dashicons dashicons-star-filled"></i>
830
- <i class="dashicons dashicons-star-filled"></i>
831
- </a>', _x( 'Rate', 'rate; as in rate this plugin', $this->settings['domain'] ) );
832
-
833
- $content .= '<ul>';
834
- $content .= sprintf( '<li>%s: <a href="http://austin.passy.co" target="_blank">Austin Passy</a></li>', _x( 'Author', 'the author of this plugin', $this->settings['domain'] ) );
835
- $content .= sprintf( '<li>%s: <a href="https://twitter.com/TheFrosty" target="_blank">TheFrosty</a></li>', __( 'Twitter', $this->settings['domain'] ) );
836
- $content .= '</ul>';
837
-
838
- $content .= sprintf( __( '<small>If you have suggestions for a new add-on, feel free to open a support request on <a href="%s" target="_blank">GitHub</a>. Want regular updates? Follow me on <a href="%s" target="_blank">Twitter</a> or visit my <a href="%s" target="_blank">blog</a>.</small>' ),
839
- 'https://github.com/thefrosty/custom-login/issues',
840
- 'https://twitter.com/TheFrosty',
841
- 'http://austin.passy.co'
842
- );
843
-
844
- $this->postbox( 'frosty-media-author', __( 'Custom Login', $this->settings['domain'] ), $content );
845
- }
846
-
847
- /**
848
- * Box with latest plugins from Extendd.com for sidebar
849
- */
850
- function sidebar_feed( $args ) {
851
-
852
- $defaults = array(
853
- 'items' => 6,
854
- 'feed' => 'https://frosty.media/wp-json/wp/v2/extensions?plugin_tag=29&per_page=6',
855
- );
856
-
857
- $args = wp_parse_args( $args, $defaults );
858
-
859
- $rss_items = CL_Common::get_posts_via_rest( $args['feed'], $args['items'] );
860
-
861
- $content = '<ul>';
862
- if ( ! $rss_items ) {
863
- $content .= '<li>' . __( 'Error fetching feed', $this->settings['domain'] ) . '</li>';
864
- } else {
865
- foreach ( $rss_items as $item ) {
866
- $url = esc_url( $item->link );
867
- $content .= '<li>';
868
- $content .= '<a href="' . $url . '?utm_source=wpadmin&utm_medium=sidebarwidget&utm_term=newsite&utm_campaign=' . $this->settings['prefix'] . '_settings-api" target="_blank">' . esc_html( $item->title->rendered ) . '</a>';
869
- $content .= '</li>';
870
- }
871
- }
872
- $content .= '</ul>';
873
-
874
- $this->postbox( 'custom-login-extensions', sprintf( __( 'Custom Login Extensions %s', $this->settings['domain'] ), '<small class="dashicons dashicons-external"></small>' ), $content );
875
- }
876
-
877
- /**
878
- * Display Upgrade Notices
879
- *
880
- * @access private
881
- * @since 3.0.3
882
- * @return void
883
- */
884
- public function upgrade_notices() {
885
-
886
- $show_upgrade_notice = false;
887
-
888
- // Version < 2.0
889
- if ( false !== get_option( 'custom_login_settings', false ) ) {
890
- $show_upgrade_notice = true;
891
- }
892
-
893
- // Version > 2.0
894
- if ( false !== get_option( 'custom_login', false ) ) {
895
- $show_upgrade_notice = true;
896
- }
897
-
898
- if ( $show_upgrade_notice && ( '' === get_option( CUSTOM_LOGIN_OPTION . '_general', '' ) ) ) {
899
- remove_action( 'admin_notice', array( CL_Settings_Upgrade::instance(), 'upgrade_notices' ) );
900
- printf(
901
- '<div class="error"><p>' . esc_html__( 'Custom Login has detected old settings. If you wish to use them please run %sthis%s script before making any changes below.', CUSTOM_LOGIN_DIRNAME ) . '</p></div>',
902
- '<a href="' . esc_url( admin_url( 'options.php?page=custom-login-upgrades' ) ) . '">',
903
- '</a>'
904
- );
905
- }
906
- }
907
-
908
- /**
909
- * Box with latest plugins from Extendd.com for sidebar
910
- */
911
- public function sticky_admin_notice_social_links() {
912
-
913
- $content = '<ul class="social">';
914
- $content .= '<li><a href="https://www.facebook.com/FrostyMediaWP" target="_blank"><span class="dashicons dashicons-facebook"></span></a></li>';
915
- $content .= '<li><a href="https://twitter.com/Frosty_Media" target="_blank"><span class="dashicons dashicons-twitter"></span></a></li>';
916
- $content .= '<li><a href="https://plus.google.com/+FrostyMedia/" target="_blank"><span class="dashicons dashicons-googleplus"></span></a></li>';
917
- $content .= '<li><a href="http://eepurl.com/bbj0bD" target="_blank"><span class="dashicons dashicons-email"></span></a></li>';
918
- $content .= '</ul>';
919
-
920
- echo $content;
921
- }
922
-
923
- /**
924
- * Replace all square brackets with and underscore.
925
- *
926
- * @param string $input
927
- *
928
- * @return string
929
- */
930
- private function replace_bracket_underscore( $input ) {
931
- return preg_replace( '/[\[\]]/', '_', $input );
932
- }
933
-
934
- /**
935
- * Get the value of a settings field
936
- *
937
- * @param string $option settings field name
938
- * @param string $section the section name this field belongs to
939
- * @param string $default default text if it's not found
940
- *
941
- * @return string
942
- */
943
- function get_option( $option, $section, $default = '' ) {
944
-
945
- $options = get_option( $section, array() );
946
-
947
- if ( isset( $options[ $option ] ) ) {
948
- return $options[ $option ];
949
- }
950
-
951
- return $default;
952
- }
953
-
954
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/class-cl-settings-upgrades.php DELETED
@@ -1,426 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Classes/CL_Settings_Upgrade
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014-2015, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- */
9
-
10
- // Exit if accessed directly
11
- if ( !defined( 'ABSPATH' ) ) exit;
12
-
13
- class CL_Settings_Upgrade {
14
-
15
- /** Singleton *************************************************************/
16
- private static $instance;
17
-
18
- protected $parent;
19
-
20
- /**
21
- * Main Instance
22
- *
23
- * @staticvar array $instance
24
- * @return The one true instance
25
- */
26
- public static function instance() {
27
- if ( ! isset( self::$instance ) ) {
28
- self::$instance = new self;
29
- self::$instance->actions();
30
- self::$instance->parent = CUSTOMLOGIN();
31
- }
32
- return self::$instance;
33
- }
34
-
35
- private function actions() {
36
-
37
- add_action( 'admin_notices', array( $this, 'upgrade_notices' ) );
38
- add_action( 'admin_menu', array( $this, 'add_submenu_page' ) );
39
- add_action( 'wp_ajax_custom_login_trigger_upgrades', array( $this, 'trigger_upgrades' ) );
40
- }
41
-
42
- /**
43
- * Display Upgrade Notices
44
- *
45
- * @access private
46
- * @since 2.0
47
- * @return void
48
- */
49
- public function upgrade_notices() {
50
-
51
- if ( isset( $_GET['page'] ) && $_GET['page'] == ( 'custom-login-upgrades' || 'custom-login' ) )
52
- return; // Don't show notices on the upgrades page
53
-
54
- $cl_version = get_option( CUSTOM_LOGIN_OPTION . '_version' );
55
-
56
- if ( ! $cl_version ) {
57
- // 2.0 is the first version to use this option so we must add it
58
- $cl_version = '2.0';
59
- }
60
-
61
- $cl_version = preg_replace( '/[^0-9.].*/', '', $cl_version );
62
-
63
- // Version less than 2.0 (settings exist)
64
- if ( false !== ( $old_settings = get_option( 'custom_login_settings', false ) ) ) {
65
-
66
- // New install
67
- if ( !$old_settings )
68
- return;
69
-
70
- if ( !empty( $old_settings ) && !empty( $old_settings['version'] ) )
71
- $cl_version = $old_settings['version'];
72
-
73
- // Versions less than 2.0
74
- if ( version_compare( $cl_version, '2.0', '<' ) ) {
75
- printf(
76
- '<div class="updated"><p>' . __( 'Custom Login needs to upgrade the settings, please click <a href="%s">here</a> to start the upgrade.', CUSTOM_LOGIN_DIRNAME ) . '</p></div>',
77
- esc_url( add_query_arg( array( 'ver' => '2.0' ), admin_url( 'options.php?page=custom-login-upgrades' ) ) )
78
- );
79
- }
80
- } // 2.0
81
-
82
- // Version less than 3.0 (settings exist)
83
- if ( false !== ( $old_settings = get_option( 'custom_login', false ) ) ) {
84
-
85
- // Versions less than 3.0
86
- if ( version_compare( $cl_version, '3.0', '<' ) ) {
87
- printf(
88
- '<div class="updated"><p>' . __( 'Custom Login needs to upgrade the settings database, please click <a href="%s">here</a> to start the upgrade.', CUSTOM_LOGIN_DIRNAME ) . '</p></div>',
89
- add_query_arg( array( 'ver' => '3.0' ), admin_url( 'options.php?page=custom-login-upgrades' ) )
90
- );
91
- }
92
- } // 3.0
93
-
94
- // Version less than 3.1
95
- if ( version_compare( CUSTOM_LOGIN_VERSION, '3.1', '<' ) ) {
96
- printf(
97
- '<div class="notice is-dismissible"><p>' . __( 'Custom Login needs to upgrade the database, please click <a href="%s">here</a> to start the upgrade.', CUSTOM_LOGIN_DIRNAME ) . '</p></div>',
98
- esc_url( add_query_arg( array( 'ver' => '3.1' ), admin_url( 'options.php?page=custom-login-upgrades' ) ) )
99
- );
100
- } // 3.1
101
- }
102
-
103
- /**
104
- * Add Submenu Upgrade page
105
- *
106
- * @access private
107
- * @since 1.0
108
- * @return void
109
- */
110
- public function add_submenu_page() {
111
-
112
- add_submenu_page(
113
- null,
114
- __( 'Custom Login Upgrades', CUSTOM_LOGIN_DIRNAME ),
115
- __( 'Custom Login Upgrades', CUSTOM_LOGIN_DIRNAME ),
116
- 'update_plugins',
117
- 'custom-login-upgrades',
118
- array( $this, 'upgrades_screen' )
119
- );
120
- }
121
-
122
- /**
123
- * Render Upgrades Screen
124
- *
125
- * @access private
126
- * @since 2.0
127
- * @return void
128
- */
129
- function upgrades_screen() {
130
- ?>
131
- <div class="wrap">
132
- <h2><?php _e( 'Custom Login - Upgrades', CUSTOM_LOGIN_DIRNAME ); ?></h2>
133
- <div id="custom-login-upgrade-status">
134
- <p>
135
- <?php _e( 'The upgrade process has started, please be patient. This could take several minutes. You will be automatically redirected when the upgrade is finished.', CUSTOM_LOGIN_DIRNAME ); ?>
136
- <img src="<?php echo esc_url( admin_url( 'images/loading.gif' ) ); ?>" id="custom-login-upgrade-loader"/>
137
- </p>
138
- </div>
139
- <script type="text/javascript">
140
- jQuery( document ).ready( function($) {
141
- // Trigger upgrades on page load
142
- var data = {
143
- action : 'custom_login_trigger_upgrades',
144
- nonce : '<?php echo wp_create_nonce( 'CL_Settings_Upgrade' . basename( __FILE__ ) ); ?>'
145
- };
146
- $.post( ajaxurl, data, function (response) {
147
- if ( response == 'complete' ) {
148
- $('#custom-login-upgrade-loader').hide();
149
- document.location.href = 'options-general.php?page=custom-login';
150
- }
151
- });
152
- });
153
- </script>
154
- </div>
155
- <?php
156
- }
157
-
158
- /**
159
- * Triggers all upgrade functions
160
- *
161
- * This function is usually triggered via ajax
162
- *
163
- * @access private
164
- * @since 2.0
165
- */
166
- public function trigger_upgrades() {
167
-
168
- check_ajax_referer( 'CL_Settings_Upgrade' . basename( __FILE__ ), 'nonce' );
169
-
170
- $cl_version = get_option( CUSTOM_LOGIN_OPTION . '_version' );
171
-
172
- if ( ! $cl_version ) {
173
- // 2.0 is the first version to use this option so we must add it
174
- $cl_version = '2.0';
175
- add_option( CUSTOM_LOGIN_OPTION . '_version', $cl_version );
176
- }
177
-
178
- // Version less than 2.0
179
- if ( false !== ( $old_settings = get_option( 'custom_login_settings', false ) ) ) {
180
-
181
- $cl_version = '1.0';
182
-
183
- if ( !empty( $old_settings ) && !empty( $old_settings['version'] ) )
184
- $cl_version = $old_settings['version'];
185
-
186
- if ( version_compare( $cl_version, '2.0', '<' ) ) {
187
- $this->cl_v20_upgrades();
188
- }
189
-
190
- } // 2.0
191
-
192
- // Version less than 3.0
193
- if ( false !== ( $old_settings = get_option( 'custom_login', false ) ) ) {
194
-
195
- $cl_version = '2.0';
196
-
197
- if ( !empty( $old_settings ) && !empty( $old_settings['version'] ) )
198
- $cl_version = $old_settings['version'];
199
-
200
- if ( version_compare( $cl_version, '3.0', '<' ) ) {
201
- $this->cl_v30_upgrades();
202
- }
203
-
204
- } // 3.0
205
-
206
- // Version less than 3.1
207
- if ( version_compare( $cl_version, '3.1', '<' ) ) {
208
- $this->cl_v31_upgrades();
209
- } // 3.1
210
-
211
- update_option( CUSTOM_LOGIN_OPTION . '_version', CUSTOM_LOGIN_VERSION );
212
-
213
- if ( DOING_AJAX ) {
214
- die( 'complete' );
215
- }
216
- }
217
-
218
- /**
219
- * Upgrade routine for v2.0
220
- *
221
- * @access private
222
- * @since 2.0.0
223
- * @return void
224
- */
225
- private function cl_v20_upgrades() {
226
-
227
- $old_settings = get_option( 'custom_login_settings' );
228
- $new_settings = get_option( 'custom_login', array() );
229
-
230
- $new_settings['version'] = $this->parent->version;
231
- $new_settings['active'] = true === $old_settings['custom'] ? 'on' : 'off';
232
- $new_settings['html_background_color'] = CL_Scripts_Styles::is_rgba( $old_settings['html_background_color'] ) ? CL_Scripts_Styles::rgba2hex( $old_settings['html_background_color'] ) : $old_settings['html_background_color'];
233
- $new_settings['html_background_color_checkbox'] = 'off';
234
- $new_settings['html_background_color_opacity'] = '';
235
- $new_settings['html_background_url'] = $old_settings['html_background_url'];
236
- $new_settings['html_background_position'] = 'left top';
237
- $new_settings['html_background_repeat'] = $old_settings['html_background_repeat'];
238
- $new_settings['html_background_size'] = $old_settings['html_background_size'];
239
- $new_settomgs['hide_wp_logo'] = 'on';
240
- $new_settings['logo_background_url'] = $old_settings['login_form_logo'];
241
- $new_settings['logo_background_position'] = 'top center';
242
- $new_settings['logo_background_repeat'] = '';
243
- $new_settings['logo_background_size'] = '';
244
- $new_settings['login_form_background_color'] = CL_Scripts_Styles::is_rgba( $old_settings['html_background_color'] ) ? CL_Scripts_Styles::rgba2hex( $old_settings['login_form_background_color'] ) : $old_settings['login_form_background_color'];
245
- $new_settings['login_form_background_color_checkbox'] = 'off';
246
- $new_settings['login_form_background_color_opacity'] = '';
247
- $new_settings['login_form_background_url'] = $old_settings['login_form_background'];
248
- $new_settings['login_form_background_position'] = '';
249
- $new_settings['login_form_background_repeat'] = '';
250
- $new_settings['login_form_background_size'] = $old_settings['login_form_background_size'];
251
- $new_settings['login_form_border_radius'] = $old_settings['login_form_border_radius'];
252
- $new_settings['login_form_border_size'] = $old_settings['login_form_border'];
253
- $new_settings['login_form_border_color'] = CL_Scripts_Styles::is_rgba( $old_settings['html_background_color'] ) ? CL_Scripts_Styles::rgba2hex( $old_settings['login_form_border_color'] ) : $old_settings['login_form_border_color'];
254
- $new_settings['login_form_border_color_checkbox'] = 'off';
255
- $new_settings['login_form_border_color_opacity'] = '';
256
- $new_settings['login_form_box_shadow'] = $old_settings['login_form_box_shadow_1'] . 'px ' . $old_settings['login_form_box_shadow_2'] . 'px ' . $old_settings['login_form_box_shadow_3'] . 'px';
257
- $new_settings['login_form_box_shadow_color'] = CL_Scripts_Styles::is_rgba( $old_settings['html_background_color'] ) ? CL_Scripts_Styles::rgba2hex( $old_settings['login_form_box_shadow_4'] ) : $old_settings['login_form_box_shadow_4'];
258
- $new_settings['login_form_box_shadow_color_checkbox'] = 'off';
259
- $new_settings['login_form_box_shadow_color_opacity'] = '';
260
- $new_settings['label_color'] = CL_Scripts_Styles::is_rgba( $old_settings['html_background_color'] ) ? CL_Scripts_Styles::rgba2hex( $old_settings['label_color'] ) : $old_settings['label_color'];
261
- $new_settings['label_color_checkbox'] = 'off';
262
- $new_settings['label_color_opacity'] = '';
263
- $new_settings['nav_color'] = '';
264
- $new_settings['nav_color_checkbox'] = 'off';
265
- $new_settings['nav_color_opacity'] = '';
266
- $new_settings['nav_text_shadow_color'] = '';
267
- $new_settings['nav_text_shadow_color_checkbox'] = 'off';
268
- $new_settings['nav_text_shadow_color_opacity'] = '';
269
- $new_settings['nav_hover_color'] = '';
270
- $new_settings['nav_hover_color_checkbox'] = 'off';
271
- $new_settings['nav_hover_color_opacity'] = '';
272
- $new_settings['nav_text_shadow_hover_color'] = '';
273
- $new_settings['nav_text_shadow_hover_color_checkbox'] = 'off';
274
- $new_settings['nav_text_shadow_hover_color_opacity'] = '';
275
- $new_settings['custom_css'] = wp_filter_nohtml_kses( $old_settings['custom_css'] );
276
- $new_settings['custom_html'] = wp_kses_post( $old_settings['custom_html'] );
277
- $new_settings['custom_jquery'] = wp_specialchars_decode( stripslashes( $old_settings['custom_jquery'] ), 1, 0, 1 );
278
-
279
- update_option( 'custom_login', $new_settings );
280
- delete_option( 'custom_login_settings' );
281
- return true;
282
- }
283
-
284
- /**
285
- * Upgrade routine for v3.0
286
- *
287
- * @access private
288
- * @since 3.0.0
289
- * @return void
290
- */
291
- private function cl_v30_upgrades() {
292
-
293
- $old_settings = get_option( 'custom_login', array() );
294
- $design_settings = get_option( CUSTOM_LOGIN_OPTION . '_design', array() );
295
- $general_settings = get_option( CUSTOM_LOGIN_OPTION . '_general', array() );
296
-
297
- /** Design */
298
- $design_settings['html_background_color'] = $this->get_old_setting( $old_settings, 'html_background_color' );
299
- $design_settings['html_background_color_checkbox'] = $this->get_old_setting( $old_settings, 'html_background_color_checkbox' );
300
- $design_settings['html_background_color_opacity'] = $this->get_old_setting( $old_settings, 'html_background_color_opacity' );
301
- $design_settings['html_background_url'] = $this->get_old_setting( $old_settings, 'html_background_url' );
302
- $design_settings['html_background_position'] = $this->get_old_setting( $old_settings, 'html_background_position' );
303
- $design_settings['html_background_repeat'] = $this->get_old_setting( $old_settings, 'html_background_repeat' );
304
- $design_settings['html_background_size'] = $this->get_old_setting( $old_settings, 'html_background_size' );
305
-
306
- $design_settings['logo_force_form_max_width'] = 'off'; // New
307
- $design_settings['hide_wp_logo'] = $this->get_old_setting( $old_settings, 'hide_wp_logo' );
308
- $design_settings['logo_background_url'] = $this->get_old_setting( $old_settings, 'logo_background_url' );
309
- $design_settings['logo_background_size_width'] = $this->get_old_setting( $old_settings, 'logo_background_size_width' );
310
- $design_settings['logo_background_size_height'] = $this->get_old_setting( $old_settings, 'logo_background_size_height' );
311
- $design_settings['logo_background_position'] = $this->get_old_setting( $old_settings, 'logo_background_position' );
312
- $design_settings['logo_background_repeat'] = $this->get_old_setting( $old_settings, 'logo_background_repeat' );
313
- $design_settings['logo_background_size'] = $this->get_old_setting( $old_settings, 'logo_background_size' );
314
-
315
- $design_settings['login_form_width'] = ''; // New
316
-
317
- $design_settings['login_form_background_color'] = $this->get_old_setting( $old_settings, 'login_form_background_color' );
318
- $design_settings['login_form_background_color_checkbox'] = $this->get_old_setting( $old_settings, 'login_form_background_color_checkbox' );
319
- $design_settings['login_form_background_color_opacity'] = $this->get_old_setting( $old_settings, 'login_form_background_color_opacity' );
320
- $design_settings['login_form_background_url'] = $this->get_old_setting( $old_settings, 'login_form_background_url' );
321
- $design_settings['login_form_background_position'] = $this->get_old_setting( $old_settings, 'login_form_background_position' );
322
- $design_settings['login_form_background_repeat'] = $this->get_old_setting( $old_settings, 'login_form_background_repeat' );
323
- $design_settings['login_form_background_size'] = $this->get_old_setting( $old_settings, 'login_form_background_size' );
324
-
325
- $design_settings['login_form_border_radius'] = $this->get_old_setting( $old_settings, 'login_form_border_radius' );
326
- $design_settings['login_form_border_size'] = $this->get_old_setting( $old_settings, 'login_form_border_size' );
327
- $design_settings['login_form_border_color'] = $this->get_old_setting( $old_settings, 'login_form_border_color' );
328
- $design_settings['login_form_border_color_checkbox'] = $this->get_old_setting( $old_settings, 'login_form_border_color_checkbox' );
329
- $design_settings['login_form_border_color_opacity'] = $this->get_old_setting( $old_settings, 'login_form_border_color_opacity' );
330
- $design_settings['login_form_box_shadow'] = $this->get_old_setting( $old_settings, 'login_form_box_shadow' );
331
- $design_settings['login_form_box_shadow_color'] = $this->get_old_setting( $old_settings, 'login_form_box_shadow_color' );
332
- $design_settings['login_form_box_shadow_color_checkbox'] = $this->get_old_setting( $old_settings, 'login_form_box_shadow_color_checkbox' );
333
- $design_settings['login_form_box_shadow_color_opacity'] = $this->get_old_setting( $old_settings, 'login_form_box_shadow_color_opacity' );
334
-
335
- $design_settings['label_color'] = $this->get_old_setting( $old_settings, 'label_color' );
336
- $design_settings['label_color_checkbox'] = $this->get_old_setting( $old_settings, 'label_color_checkbox' );
337
- $design_settings['label_color_opacity'] = $this->get_old_setting( $old_settings, 'label_color_opacity' );
338
-
339
- $design_settings['nav_color'] = $this->get_old_setting( $old_settings, 'nav_color' );
340
- $design_settings['nav_color_checkbox'] = $this->get_old_setting( $old_settings, 'nav_color_checkbox' );
341
- $design_settings['nav_color_opacity'] = $this->get_old_setting( $old_settings, 'nav_color_opacity' );
342
- $design_settings['nav_text_shadow_color'] = $this->get_old_setting( $old_settings, 'nav_text_shadow_color' );
343
- $design_settings['nav_text_shadow_color_checkbox'] = $this->get_old_setting( $old_settings, 'nav_text_shadow_color_checkbox' );
344
- $design_settings['nav_text_shadow_color_opacity'] = $this->get_old_setting( $old_settings, 'nav_text_shadow_color_opacity' );
345
- $design_settings['nav_hover_color'] = $this->get_old_setting( $old_settings, 'nav_hover_color' );
346
- $design_settings['nav_hover_color_checkbox'] = $this->get_old_setting( $old_settings, 'nav_hover_color_checkbox' );
347
- $design_settings['nav_hover_color_opacity'] = $this->get_old_setting( $old_settings, 'nav_hover_color_opacity' );
348
- $design_settings['nav_text_shadow_hover_color'] = $this->get_old_setting( $old_settings, 'nav_text_shadow_hover_color' );
349
- $design_settings['nav_text_shadow_hover_color_checkbox'] = $this->get_old_setting( $old_settings, 'nav_text_shadow_hover_color_checkbox' );
350
- $design_settings['nav_text_shadow_hover_color_opacity'] = $this->get_old_setting( $old_settings, 'nav_text_shadow_hover_color_opacity' );
351
-
352
- $design_settings['custom_css'] = wp_filter_nohtml_kses( $this->get_old_setting( $old_settings, 'custom_css' ) );
353
- $design_settings['animate.css'] = 'off'; // New
354
- $design_settings['custom_html'] = wp_kses_post( $this->get_old_setting( $old_settings, 'custom_html' ) );
355
- $design_settings['custom_jquery'] = wp_specialchars_decode( stripslashes( $this->get_old_setting( $old_settings, 'custom_jquery' ) ), 1, 0, 1 );
356
-
357
- /** General */
358
- $general_settings['active'] = $this->get_old_setting( $old_settings, 'active', 'on' );
359
- $general_settings['capability'] = 'manage_options'; // New
360
- $general_settings['tracking'] = 'off'; // New
361
- $general_settings['admin_notices'] = 'off'; // New
362
- $general_settings['wp_shake_js'] = 'off'; // New
363
- $general_settings['remove_login_css'] = 'off'; // New
364
- $general_settings['lostpassword_text'] = 'off'; // New
365
-
366
- update_option( CUSTOM_LOGIN_OPTION . '_design', $design_settings );
367
- update_option( CUSTOM_LOGIN_OPTION . '_general', $general_settings );
368
- delete_option( 'custom_login' );
369
- return true;
370
- }
371
-
372
- /**
373
- * Upgrade routine for v3.1
374
- *
375
- * @access private
376
- * @since 3.1
377
- * @return void
378
- */
379
- private function cl_v31_upgrades() {
380
-
381
- $general_settings = get_option( CUSTOM_LOGIN_OPTION . '_general', array() );
382
-
383
- // Remove old settings
384
- unset( $general_settings['allow_password_reset'] );
385
- unset( $general_settings['auth_timeout'] );
386
- unset( $general_settings['auth_timeout_remember'] );
387
-
388
- // Leave
389
- $general_settings['active'] = $this->get_old_setting( $general_settings, 'active', 'on' );
390
-
391
- // New settings
392
- $general_settings['dashboard_widget'] = 'off';
393
-
394
- update_option( CUSTOM_LOGIN_OPTION . '_general', $general_settings );
395
-
396
- // Update tracking options name
397
- update_option( CUSTOM_LOGIN_OPTION . '_tracking_last_send', get_option( 'cl_tracking_last_send' ) );
398
- update_option( CUSTOM_LOGIN_OPTION . '_tracking_notice', get_option( 'cl_tracking_notice' ) );
399
- delete_option( 'cl_tracking_last_send' );
400
- delete_option( 'cl_tracking_notice' );
401
-
402
- delete_option( CUSTOM_LOGIN_OPTION . '_announcement_message' );
403
-
404
- /** Cleanup Cron Events */
405
- wp_clear_scheduled_hook( 'cl_daily_scheduled_events' );
406
- wp_clear_scheduled_hook( 'cl_weekly_scheduled_events' );
407
- return true;
408
- }
409
-
410
- /**
411
- * Helper function to check if option isset
412
- *
413
- * @since 12/26/2014
414
- */
415
- private function get_old_setting( $setting = array(), $option = null, $default = '' ) {
416
- if ( is_null( $option ) )
417
- return $default;
418
-
419
- if ( isset( $setting[$option] ) )
420
- return $setting[$option];
421
-
422
- return $default;
423
- }
424
-
425
- }
426
- CL_Settings_Upgrade::instance();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/class-cl-templates.php DELETED
@@ -1,112 +0,0 @@
1
- <?php
2
-
3
- // Exit if accessed directly
4
- if ( ! defined( 'ABSPATH' ) ) exit;
5
-
6
- class CL_Templates {
7
-
8
- /**
9
- * Returns the path to the CL templates directory
10
- *
11
- * @access private
12
- * @since 2.0
13
- * @return string
14
- */
15
- public static function get_templates_dir() {
16
- return CUSTOM_LOGIN_DIR . 'templates';
17
- }
18
-
19
- /**
20
- * Returns the URL to the CL templates directory
21
- *
22
- * @access private
23
- * @since 2.0
24
- * @return string
25
- */
26
- public static function get_templates_url() {
27
- return CUSTOM_LOGIN_URL . 'templates';
28
- }
29
-
30
- /**
31
- * Retrieves a template part
32
- *
33
- * @since 2.0
34
- *
35
- * @param string $slug
36
- * @param string $name Optional. Default null
37
- *
38
- * @uses custom_login_locate_template()
39
- * @uses load_template()
40
- * @uses get_template_part()
41
- */
42
- public static function get_template_part( $slug, $name = null, $load = true ) {
43
-
44
- // Execute code for this part
45
- do_action( 'get_template_part_' . $slug, $slug, $name );
46
-
47
- // Setup possible parts
48
- $templates = array();
49
- if ( isset( $name ) )
50
- $templates[] = $slug . '-' . $name . '.php';
51
- $templates[] = $slug . '.php';
52
-
53
- // Allow template parst to be filtered
54
- $templates = apply_filters( 'custom_login_get_template_part', $templates, $slug, $name );
55
-
56
- // Return the part that is found
57
- return self::locate_template( $templates, $load, false );
58
- }
59
-
60
- /**
61
- * Retrieve the name of the highest priority template file that exists.
62
- *
63
- * Searches in the STYLESHEETPATH before TEMPLATEPATH so that themes which
64
- * inherit from a parent theme can just overload one file. If the template is
65
- * not found in either of those, it looks in the theme-compat folder last.
66
- *
67
- * @since 2.0
68
- *
69
- * @param string|array $template_names Template file(s) to search for, in order.
70
- * @param bool $load If true the template file will be loaded if it is found.
71
- * @param bool $require_once Whether to require_once or require. Default true.
72
- * Has no effect if $load is false.
73
- * @return string The template filename if one is located.
74
- */
75
- public static function locate_template( $template_names, $load = false, $require_once = true ) {
76
-
77
- // No file found yet
78
- $located = false;
79
-
80
- // Try to find a template file
81
- foreach ( (array) $template_names as $template_name ) {
82
-
83
- // Continue if template is empty
84
- if ( empty( $template_name ) )
85
- continue;
86
-
87
- // Trim off any slashes from the template name
88
- $template_name = ltrim( $template_name, '/' );
89
-
90
- // Check child theme first
91
- if ( file_exists( trailingslashit( get_stylesheet_directory() ) . 'custom_login_templates/' . $template_name ) ) {
92
- $located = trailingslashit( get_stylesheet_directory() ) . 'custom_login_templates/' . $template_name;
93
- break;
94
-
95
- // Check parent theme next
96
- } elseif ( file_exists( trailingslashit( get_template_directory() ) . 'custom_login_templates/' . $template_name ) ) {
97
- $located = trailingslashit( get_template_directory() ) . 'custom_login_templates/' . $template_name;
98
- break;
99
-
100
- // Check plugin compatibility last
101
- } elseif ( file_exists( trailingslashit( self::get_templates_dir() ) . $template_name ) ) {
102
- $located = trailingslashit( self::get_templates_dir() ) . $template_name;
103
- break;
104
- }
105
- }
106
-
107
- if ( ( true == $load ) && ! empty( $located ) )
108
- load_template( $located, $require_once );
109
-
110
- return $located;
111
- }
112
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/class-cl-wp-login.php DELETED
@@ -1,262 +0,0 @@
1
- <?php
2
- /**
3
- * @package CustomLogin
4
- * @subpackage Classes/CL_WP_Login
5
- * @author Austin Passy <http://austin.passy.co>
6
- * @copyright Copyright (c) 2014-2015, Austin Passy
7
- * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
8
- */
9
-
10
- // Exit if accessed directly
11
- if ( ! defined( 'ABSPATH' ) ) {
12
- exit;
13
- }
14
-
15
- class CL_WP_Login {
16
-
17
- /** Singleton *************************************************************/
18
- private static $instance;
19
-
20
- /**
21
- * Main Instance
22
- *
23
- * @staticvar array $instance
24
- * @return self The one true instance
25
- */
26
- public static function instance() {
27
- if ( ! isset( self::$instance ) ) {
28
- self::$instance = new self;
29
- self::$instance->init();
30
- }
31
-
32
- return self::$instance;
33
- }
34
-
35
- private function init() {
36
-
37
- if ( 'off' === CL_Common::get_option( 'active', 'general', 'off' ) ) {
38
- return;
39
- }
40
-
41
- $this->actions();
42
- $this->filters();
43
- }
44
-
45
- private function actions() {
46
- add_action( 'login_enqueue_scripts', array( $this, 'login_enqueue_scripts' ) );
47
- add_action( 'login_footer', array( $this, 'login_footer_html' ), 8 );
48
- add_action( 'login_footer', array( $this, 'login_footer_jquery' ), 19 );
49
-
50
- add_action( 'init', array( $this, 'login_remove_scripts' ) );
51
- add_action( 'login_head', array( $this, 'login_head' ), 10 );
52
- add_filter( 'login_headerurl', array( $this, 'login_headerurl' ) );
53
- if (version_compare($GLOBALS['wp_version'],'5.2', '>=')) {
54
- add_filter('login_headertext', [$this, 'login_headertitle']);
55
- } else {
56
- add_filter('login_headertitle', [$this, 'login_headertitle']);
57
- }
58
- }
59
-
60
- private function filters() {
61
- add_filter( 'gettext', array( $this, 'remove_lostpassword_text' ), 20, 2 );
62
- }
63
-
64
- /**
65
- *************************************************************
66
- **************** ACTIONS **********************************
67
- *************************************************************
68
- */
69
-
70
- /**
71
- * Enqueue additional scripts.
72
- *
73
- * @since 2.0
74
- * @updated 3.2
75
- */
76
- public function login_enqueue_scripts() {
77
- /**
78
- * Animate.css
79
- * @ref https://github.com/daneden/animate.css/blob/master/animate.min.css
80
- */
81
- $animate_css = CL_Common::get_option( 'animate.css', 'design', 'off' );
82
- if ( 'on' == $animate_css ) {
83
- wp_enqueue_style( 'animate.css', plugins_url( 'css/animate.min.css', CUSTOM_LOGIN_FILE ), array( 'login' ), '08112014', 'screen' );
84
- }
85
-
86
- /* Custom jQuery */
87
- $jquery = CL_Common::get_option( 'custom_jquery', 'design', '' );
88
- if ( '' !== $jquery ) {
89
- wp_enqueue_script( 'jquery' );
90
- }
91
- }
92
-
93
- /**
94
- * If there is custom HTML set in the settings echo it to the
95
- * 'login_footer' hook in wp-login.php.
96
- *
97
- * @return string|void
98
- */
99
- public function login_footer_html() {
100
-
101
- $custom_html = CL_Common::get_option( 'custom_html', 'design', false );
102
-
103
- if ( $custom_html ) {
104
- $html = wp_kses_post( $custom_html );
105
- $html .= "\n";
106
-
107
- echo $html;
108
- }
109
- }
110
-
111
- /**
112
- * Database access to the scripts and styles.
113
- *
114
- * @since 2.1
115
- * @return string|void
116
- */
117
- public function login_footer_jquery() {
118
-
119
- $jquery = CL_Common::get_option( 'custom_jquery', 'design', '' );
120
-
121
- if ( '' != $jquery ) {
122
-
123
- global $cl_js_atts;
124
-
125
- $cl_js_atts = array(
126
- 'version' => CUSTOM_LOGIN_VERSION,
127
- 'trans_key' => CL_Common::get_transient_key( 'script' ),
128
- );
129
- $cl_js_atts = wp_parse_args( CL_Common::get_options( 'design' ), $cl_js_atts );
130
-
131
- foreach ( $cl_js_atts as $atts => $value ) {
132
- if ( 'custom_jquery' !== $atts && 'version' !== $atts && 'trans_key' !== $atts ) {
133
- unset( $cl_js_atts[ $atts ] );
134
- }
135
- }
136
-
137
- ob_start();
138
- echo "<script type=\"text/javascript\">\n";
139
- CL_Templates::get_template_part( 'wp-login', 'script' );
140
- echo "\n</script>\n";
141
- echo ob_get_clean();
142
- }
143
- }
144
-
145
- /**
146
- * Finds the global page for the wp-login.php. When on the page
147
- * remove default stylesheets so we can add our own.
148
- *
149
- * @return void
150
- */
151
- function login_remove_scripts() {
152
- global $pagenow;
153
-
154
- if ( 'wp-login.php' == $pagenow ) {
155
-
156
- $suffix = is_rtl() ? '-rtl' : '';
157
- $suffix .= defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min'; // Don't have minified version in place.
158
-
159
- /**
160
- * User reports on messed up checkboxes
161
- *
162
- * Probobly easier to use WordPress login CSS
163
- *
164
- * wp_deregister_style( array( 'login' ) );
165
- *
166
- * wp_enqueue_style( 'forms', get_admin_url( get_current_blog_id(), "css/forms{$suffix}.css", 'admin' ), null, CUSTOM_LOGIN_VERSION, 'screen' );
167
- * wp_enqueue_style( 'l10n', get_admin_url( get_current_blog_id(), "css/l10n{$suffix}.css", 'admin' ), null, CUSTOM_LOGIN_VERSION, 'screen' );
168
- * wp_register_style( 'login', plugins_url( "css/login/login{$suffix}.css", CUSTOM_LOGIN_FILE ), array( 'buttons' ), CUSTOM_LOGIN_VERSION, 'all' );
169
- */
170
-
171
- if ( 'on' === CL_Common::get_option( 'remove_login_css', 'general' ) ) {
172
- add_filter( 'wp_admin_css', '__return_false' );
173
- wp_deregister_style( 'login' );
174
- }
175
- }
176
- }
177
-
178
- /**
179
- * Actions hooked into login_head
180
- *
181
- */
182
- public function login_head() {
183
- global $cl_css_atts;
184
-
185
- $cl_css_atts = array(
186
- 'version' => CUSTOM_LOGIN_VERSION,
187
- 'trans_key' => CL_Common::get_transient_key( 'style' ),
188
- );
189
- $cl_css_atts = wp_parse_args( CL_Common::get_options( 'design' ), $cl_css_atts );
190
-
191
- ob_start();
192
- echo "<style type=\"text/css\">\n";
193
- CL_Templates::get_template_part( 'wp-login', 'style' );
194
- echo "\n</style>\n";
195
- echo ob_get_clean();
196
-
197
- if ( 'on' === CL_Common::get_option( 'wp_shake_js', 'general' ) ) {
198
- remove_action( 'login_head', 'wp_shake_js', 12 );
199
- }
200
- }
201
-
202
- /**
203
- * Replace the default link to your URL
204
- *
205
- * @param string $url
206
- *
207
- * @return string
208
- */
209
- public function login_headerurl( $url ) {
210
- if ( ! is_multisite() ) {
211
- return home_url();
212
- }
213
-
214
- return $url;
215
- }
216
-
217
- /**
218
- * Replace the default title to your description
219
- *
220
- * @param string $title
221
- *
222
- * @return string
223
- */
224
- public function login_headertitle( $title ) {
225
- if ( ! is_multisite() ) {
226
- return get_bloginfo( 'description' );
227
- }
228
-
229
- return $title;
230
- }
231
-
232
- /**
233
- *************************************************************
234
- **************** FILTERS **********************************
235
- *************************************************************
236
- */
237
-
238
- /**
239
- * Remove the "Lost your password?" text.
240
- */
241
- public function remove_lostpassword_text( $translated_text, $untranslated_text ) {
242
- global $pagenow;
243
-
244
- if ( 'wp-login.php' == $pagenow ) {
245
-
246
- if ( 'off' !== CL_Common::get_option( 'lostpassword_text', 'general' ) ) {
247
- //make the changes to the text
248
- switch ( $untranslated_text ) {
249
-
250
- case 'Lost your password?':
251
- $translated_text = '';
252
- break;
253
- }
254
- }
255
- }
256
-
257
- return $translated_text;
258
- }
259
-
260
- }
261
-
262
- add_action( CUSTOM_LOGIN_OPTION . '_actions', array( 'CL_WP_Login', 'instance' ) );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/default-settings.php DELETED
@@ -1,508 +0,0 @@
1
- <?php
2
-
3
- // Exit if accessed directly
4
- if ( ! defined( 'ABSPATH' ) ) exit;
5
-
6
- $strings = array(
7
- 'checked' => ' ' . __( 'Checked equals "on" (allow).', CUSTOM_LOGIN_DIRNAME ),
8
- 'unchecked' => ' ' . __( 'Unchecked equals "off" (do not allow).', CUSTOM_LOGIN_DIRNAME ),
9
- );
10
-
11
- $sections = array(
12
- array(
13
- 'id' => CUSTOM_LOGIN_OPTION . '_design',
14
- 'title' => __( 'Design Settings', CUSTOM_LOGIN_DIRNAME ),
15
- 'submit' => true,
16
- ),
17
- array(
18
- 'id' => CUSTOM_LOGIN_OPTION . '_general',
19
- 'title' => __( 'General Settings', CUSTOM_LOGIN_DIRNAME ),
20
- 'submit' => true,
21
- ),
22
- );
23
-
24
- /**
25
- * Design Settings Section
26
- *
27
- */
28
- $fields [CUSTOM_LOGIN_OPTION . '_design'] = array(
29
- /** BREAK **/
30
- array(
31
- 'name' => 'break_1',
32
- 'label' => sprintf( '<h4>%s</h4>', __( '<abbr title="Hyper Text Markup Language">HTML</abbr>', CUSTOM_LOGIN_DIRNAME ) ),
33
- 'desc' => '',
34
- 'type' => 'html',
35
- ),
36
- /** BREAK **/
37
-
38
- array(
39
- 'name' => 'html_background_color',
40
- 'label' => __( 'Background color', CUSTOM_LOGIN_DIRNAME ),
41
- 'desc' => '',
42
- 'type' => 'colorpicker',
43
- 'default' => '',
44
- ),
45
- array(
46
- 'name' => 'html_background_url',
47
- 'label' => __( 'Background image', CUSTOM_LOGIN_DIRNAME ),
48
- 'desc' => '',
49
- 'type' => 'file',
50
- 'default' => '',
51
- 'size' => 'large',
52
- 'sanitize' => 'esc_url',
53
- ),
54
- array(
55
- 'name' => 'html_background_position',
56
- 'label' => __( 'Background position', CUSTOM_LOGIN_DIRNAME ),
57
- 'desc' => sprintf( '<a href="http://www.w3schools.com/cssref/pr_background-position.asp" target="_blank">%s</a>.', __( 'html background position', CUSTOM_LOGIN_DIRNAME ) ),
58
- 'type' => 'select',
59
- 'options' => array(
60
- 'left top' => 'left top',
61
- 'left center' => 'left center',
62
- 'left bottom' => 'left bottom',
63
- 'right top' => 'right top',
64
- 'right center' => 'right center',
65
- 'right bottom' => 'right bottom',
66
- 'center top' => 'center top',
67
- 'center center' => 'center center',
68
- 'center bottom' => 'center bottom',
69
- ),
70
- ),
71
- array(
72
- 'name' => 'html_background_repeat',
73
- 'label' => __( 'Background repeat', CUSTOM_LOGIN_DIRNAME ),
74
- 'desc' => '',
75
- 'type' => 'select',
76
- 'options' => array(
77
- 'no-repeat' => 'no-repeat',
78
- 'repeat' => 'repeat',
79
- 'repeat-x' => 'repeat-x',
80
- 'repeat-y' => 'repeat-y',
81
- )
82
- ),
83
- array(
84
- 'name' => 'html_background_size',
85
- 'label' => __( 'Background size', CUSTOM_LOGIN_DIRNAME ),
86
- 'desc' => '',
87
- 'type' => 'select',
88
- 'options' => array(
89
- 'none' => 'none',
90
- 'cover' => 'cover',
91
- 'contain' => 'contain',
92
- 'flex' => 'flex',
93
- )
94
- ),
95
-
96
- /** BREAK **/
97
- array(
98
- 'name' => 'break_2',
99
- 'label' => sprintf( '<h4>%s</h4>', __( 'Logo', CUSTOM_LOGIN_DIRNAME ) ),
100
- 'desc' => '',
101
- 'type' => 'html',
102
- ),
103
- /** BREAK **/
104
-
105
- array(
106
- 'name' => 'hide_wp_logo',
107
- 'label' => __( 'Hide the WP logo', CUSTOM_LOGIN_DIRNAME ),
108
- 'desc' => __( 'This setting hides the h1 element.', CUSTOM_LOGIN_DIRNAME ),
109
- 'type' => 'checkbox'
110
- ),
111
- array(
112
- 'name' => 'logo_background_url',
113
- 'label' => __( 'Image', CUSTOM_LOGIN_DIRNAME ),
114
- 'desc' => __( 'I would suggest a max width of 320px, the default form width. You can widen the width (setting below).', CUSTOM_LOGIN_DIRNAME ),
115
- 'type' => 'file',
116
- 'default' => '',
117
- 'size' => 'large',
118
- 'sanitize' => 'esc_url',
119
- ),
120
- array(
121
- 'name' => 'logo_background_size_width',
122
- 'label' => __( 'Image width', CUSTOM_LOGIN_DIRNAME ),
123
- 'desc' => __( 'Enter your desired image height (All not integers will be removed).', CUSTOM_LOGIN_DIRNAME ),
124
- 'type' => 'text_number',
125
- 'size' => 'small',
126
- 'default' => '',
127
- 'sanitize' => 'int',
128
- ),
129
- array(
130
- 'name' => 'logo_background_size_height',
131
- 'label' => __( 'Image height', CUSTOM_LOGIN_DIRNAME ),
132
- 'desc' => __( 'Enter your desired image height (All not integers will be removed).', CUSTOM_LOGIN_DIRNAME ),
133
- 'type' => 'text_number',
134
- 'size' => 'small',
135
- 'default' => '',
136
- 'sanitize' => 'int',
137
- ),
138
- array(
139
- 'name' => 'logo_background_position',
140
- 'label' => __( 'Background position', CUSTOM_LOGIN_DIRNAME ),
141
- 'desc' => sprintf( '<a href="http://www.w3schools.com/cssref/pr_background-position.asp" target="_blank">%s</a>', __( 'html background position', CUSTOM_LOGIN_DIRNAME ) ),
142
- 'type' => 'select',
143
- 'options' => array(
144
- 'left top' => 'left top',
145
- 'left center' => 'left center',
146
- 'left bottom' => 'left bottom',
147
- 'right top' => 'right top',
148
- 'right center' => 'right center',
149
- 'right bottom' => 'right bottom',
150
- 'center top' => 'center top',
151
- 'center center' => 'center center',
152
- 'center bottom' => 'center bottom',
153
- ),
154
- ),
155
- array(
156
- 'name' => 'logo_background_repeat',
157
- 'label' => __( 'Background repeat', CUSTOM_LOGIN_DIRNAME ),
158
- 'desc' => '',
159
- 'type' => 'select',
160
- 'options' => array(
161
- 'no-repeat' => 'no-repeat',
162
- 'repeat' => 'repeat',
163
- 'repeat-x' => 'repeat-x',
164
- 'repeat-y' => 'repeat-y',
165
- )
166
- ),
167
- array(
168
- 'name' => 'logo_background_size',
169
- 'label' => __( 'Background size', CUSTOM_LOGIN_DIRNAME ),
170
- 'desc' => '',
171
- 'type' => 'select',
172
- 'options' => array(
173
- 'none' => 'none',
174
- 'cover' => 'cover',
175
- 'contain' => 'contain',
176
- 'flex' => 'flex',
177
- )
178
- ),
179
-
180
- /** BREAK **/
181
- array(
182
- 'name' => 'break_3',
183
- 'label' => sprintf( '<h4>%s</h4>', __( 'Login Form', CUSTOM_LOGIN_DIRNAME ) ),
184
- 'desc' => '',
185
- 'type' => 'html',
186
- ),
187
- /** BREAK **/
188
-
189
- array(
190
- 'name' => 'logo_force_form_max_width',
191
- 'label' => __( 'Force max-width', CUSTOM_LOGIN_DIRNAME ),
192
- 'desc' => __( 'If checked and the login form width (set below) is not empty, a CSS rule of <code>width</code> will be applied on the logo wrapper element <code>.login h1</code>. This settings applies to the Logo image (when background size is used).', CUSTOM_LOGIN_DIRNAME ),
193
- 'type' => 'checkbox'
194
- ),
195
- array(
196
- 'name' => 'login_form_width',
197
- 'label' => __( 'Width', CUSTOM_LOGIN_DIRNAME ),
198
- 'desc' => __( 'Change the default width of the login form.', CUSTOM_LOGIN_DIRNAME ),
199
- 'type' => 'text_number',
200
- 'size' => 'small',
201
- 'default' => '320',
202
- 'sanitize' => 'int',
203
- ),
204
- array(
205
- 'name' => 'login_form_background_color',
206
- 'label' => __( 'Background color', CUSTOM_LOGIN_DIRNAME ),
207
- 'desc' => '',
208
- 'type' => 'colorpicker',
209
- 'default' => ''
210
- ),
211
- array(
212
- 'name' => 'login_form_background_url',
213
- 'label' => __( 'Background URL', CUSTOM_LOGIN_DIRNAME ),
214
- 'desc' => __( 'Add a background image to the login form.', CUSTOM_LOGIN_DIRNAME ),
215
- 'type' => 'file',
216
- 'default' => '',
217
- 'size' => 'large',
218
- 'sanitize' => 'esc_url',
219
- ),
220
- array(
221
- 'name' => 'login_form_background_position',
222
- 'label' => __( 'Background position', CUSTOM_LOGIN_DIRNAME ),
223
- 'desc' => sprintf( '<a href="http://www.w3schools.com/cssref/pr_background-position.asp" target="_blank">%s</a>', __( 'html background position', CUSTOM_LOGIN_DIRNAME ) ),
224
- 'type' => 'select',
225
- 'options' => array(
226
- 'left top' => 'left top',
227
- 'left center' => 'left center',
228
- 'left bottom' => 'left bottom',
229
- 'right top' => 'right top',
230
- 'right center' => 'right center',
231
- 'right bottom' => 'right bottom',
232
- 'center top' => 'center top',
233
- 'center center' => 'center center',
234
- 'center bottom' => 'center bottom',
235
- ),
236
- ),
237
- array(
238
- 'name' => 'login_form_background_repeat',
239
- 'label' => __( 'Background repeat', CUSTOM_LOGIN_DIRNAME ),
240
- 'desc' => '',
241
- 'type' => 'select',
242
- 'options' => array(
243
- 'no-repeat' => 'no-repeat',
244
- 'repeat' => 'repeat',
245
- 'repeat-x' => 'repeat-x',
246
- 'repeat-y' => 'repeat-y',
247
- )
248
- ),
249
- array(
250
- 'name' => 'login_form_background_size',
251
- 'label' => __( 'Background size', CUSTOM_LOGIN_DIRNAME ),
252
- 'desc' => '',
253
- 'type' => 'select',
254
- 'options' => array(
255
- 'none' => 'none',
256
- 'cover' => 'cover',
257
- 'contain' => 'contain',
258
- 'flex' => 'flex',
259
- )
260
- ),
261
- array(
262
- 'name' => 'login_form_border_radius',
263
- 'label' => __( 'Border radius', CUSTOM_LOGIN_DIRNAME ),
264
- 'desc' => '',
265
- 'type' => 'text_number',
266
- 'size' => 'small',
267
- 'default' => '',
268
- 'sanitize' => 'int',
269
- ),
270
- array(
271
- 'name' => 'login_form_border_size',
272
- 'label' => __( 'Border size', CUSTOM_LOGIN_DIRNAME ),
273
- 'desc' => '',
274
- 'type' => 'text_number',
275
- 'size' => 'small',
276
- 'default' => '',
277
- 'sanitize' => 'int',
278
- ),
279
- array(
280
- 'name' => 'login_form_border_color',
281
- 'label' => __( 'Border color', CUSTOM_LOGIN_DIRNAME ),
282
- 'desc' => '',
283
- 'type' => 'colorpicker',
284
- 'default' => ''
285
- ),
286
- array(
287
- 'name' => 'login_form_box_shadow',
288
- 'label' => __( 'Box shadow', CUSTOM_LOGIN_DIRNAME ),
289
- 'desc' => sprintf( __( 'Use <a href="%s" target="_blank">box shadow</a> syntax w/ out color. <code>inset h-shadow v-shadow blur spread</code>', CUSTOM_LOGIN_DIRNAME ), 'http://www.w3schools.com/cssref/css3_pr_box-shadow.asp' ),
290
- 'type' => 'text',
291
- 'size' => 'medium',
292
- 'default' => '5px 5px 10px'
293
- ),
294
- array(
295
- 'name' => 'login_form_box_shadow_color',
296
- 'label' => __( 'Box shadow color', CUSTOM_LOGIN_DIRNAME ),
297
- 'desc' => '',
298
- 'type' => 'colorpicker',
299
- 'default' => ''
300
- ),
301
-
302
- /** BREAK **/
303
- array(
304
- 'name' => 'break_4',
305
- 'label' => sprintf( '<h4>%s</h4>', __( 'Miscellaneous', CUSTOM_LOGIN_DIRNAME ) ),
306
- 'desc' => '',
307
- 'type' => 'html',
308
- ),
309
- /** BREAK **/
310
-
311
- array(
312
- 'name' => 'label_color',
313
- 'label' => __( 'Label color', CUSTOM_LOGIN_DIRNAME ),
314
- 'desc' => '',
315
- 'type' => 'colorpicker',
316
- 'default' => ''
317
- ),
318
-
319
- /** BREAK **/
320
- array(
321
- 'name' => 'break_5',
322
- 'label' => sprintf( '<h4>%s</h4>', __( 'Below Form anchor', CUSTOM_LOGIN_DIRNAME ) ),
323
- 'desc' => '',
324
- 'type' => 'html',
325
- ),
326
- /** BREAK **/
327
-
328
- array(
329
- 'name' => 'nav_color',
330
- 'label' => __( 'Nav color', CUSTOM_LOGIN_DIRNAME ),
331
- 'desc' => '',
332
- 'type' => 'colorpicker',
333
- 'default' => '',
334
- ),
335
- array(
336
- 'name' => 'nav_text_shadow_color',
337
- 'label' => __( 'Nav text-shadow color', CUSTOM_LOGIN_DIRNAME ),
338
- 'desc' => '',
339
- 'type' => 'colorpicker',
340
- 'default' => '',
341
- ),
342
- array(
343
- 'name' => 'nav_hover_color',
344
- 'label' => __( 'Nav color hover', CUSTOM_LOGIN_DIRNAME ),
345
- 'desc' => '',
346
- 'type' => 'colorpicker',
347
- 'default' => '',
348
- ),
349
- array(
350
- 'name' => 'nav_text_shadow_hover_color',
351
- 'label' => __( 'Nav text-shadow hover', CUSTOM_LOGIN_DIRNAME ),
352
- 'desc' => '',
353
- 'type' => 'colorpicker',
354
- 'default' => '',
355
- ),
356
-
357
- /** BREAK **/
358
- array(
359
- 'name' => 'break_6',
360
- 'label' => sprintf( '<h4>%s</h4>', __( 'Custom CSS', CUSTOM_LOGIN_DIRNAME ) ),
361
- 'desc' => '',
362
- 'type' => 'html',
363
- ),
364
- /** BREAK **/
365
-
366
- array(
367
- 'name' => 'custom_css',
368
- 'label' => '',
369
- 'desc' => sprintf( '%s %s', __( 'Allowed variables:', CUSTOM_LOGIN_DIRNAME ), '<ul>
370
- <li>{BSLASH} = "\" (backslash)</li>
371
- <li><a href="http://wordpress.org/support/topic/quotes-in-custom-css-gets-replaced-with-useless-quote?replies=4">Request others</a></li>
372
- </ul>' ),
373
- 'type' => 'textarea',
374
- 'sanitize' => static function($css) {
375
- return wp_specialchars_decode(wp_filter_nohtml_kses($css));
376
- },
377
- ),
378
- array(
379
- 'name' => 'animate.css',
380
- 'label' => __( 'Animate', CUSTOM_LOGIN_DIRNAME ),
381
- 'desc' => __( 'Include <a href="http://daneden.github.io/animate.css/">animate.css</a>?', CUSTOM_LOGIN_DIRNAME ),
382
- 'type' => 'checkbox',
383
- 'default' => 'off',
384
- ),
385
-
386
- /** BREAK **/
387
- array(
388
- 'name' => 'break_7',
389
- 'label' => sprintf( '<h4>%s</h4>', __( 'Custom HTML', CUSTOM_LOGIN_DIRNAME ) ),
390
- 'desc' => '',
391
- 'type' => 'html',
392
- ),
393
- /** BREAK **/
394
-
395
- array(
396
- 'name' => 'custom_html',
397
- 'label' => '',
398
- 'desc' => '',
399
- 'type' => 'textarea',
400
- 'sanitize' => 'wp_kses_post', //Allow HTML
401
- ),
402
-
403
- /** BREAK **/
404
- array(
405
- 'name' => 'break_8',
406
- 'label' => sprintf( '<h4>%s</h4>', __( 'Custom jQuery', CUSTOM_LOGIN_DIRNAME ) ),
407
- 'desc' => '',
408
- 'type' => 'html',
409
- ),
410
- /** BREAK **/
411
-
412
- array(
413
- 'name' => 'custom_jquery',
414
- 'label' => '',
415
- 'desc' => '<code>(function($) { "use strict";</code> ' . __( '** Your custom jQuery will output here **.', CUSTOM_LOGIN_DIRNAME ) . ' <code>}(jQuery));</code><br>',
416
- 'type' => 'textarea',
417
- 'sanitize' => 'wp_specialchars_decode',
418
- ),
419
- );
420
-
421
- /**
422
- * General Settings Section
423
- *
424
- */
425
- $fields [CUSTOM_LOGIN_OPTION . '_general'] = array(
426
- array(
427
- 'name' => 'active',
428
- 'label' => __( 'Activate', CUSTOM_LOGIN_DIRNAME ),
429
- 'desc' => __( 'Allow Custom Login to hook into WordPress.', CUSTOM_LOGIN_DIRNAME ),
430
- 'type' => 'checkbox',
431
- 'default' => 'on',
432
- ),
433
- array(
434
- 'name' => 'capability',
435
- 'label' => __( 'Capability', CUSTOM_LOGIN_DIRNAME ),
436
- 'desc' => sprintf( __( 'Set the minimum user capability to manage these settings. The default capability is <code>%s</code>', CUSTOM_LOGIN_DIRNAME ), 'manage_options' ),
437
- 'type' => 'select',
438
- 'size' => 'large',
439
- 'default' => 'manage_options',
440
- 'options' => custom_login_get_editable_roles()
441
- ),
442
-
443
- /** BREAK **/
444
- array(
445
- 'name' => 'break_1',
446
- 'label' => sprintf( '<h4>%s</h4>', __( 'Tracking Settings', CUSTOM_LOGIN_DIRNAME ) ),
447
- 'desc' => '',
448
- 'type' => 'html',
449
- ),
450
- /** BREAK **/
451
-
452
- array(
453
- 'name' => 'tracking',
454
- 'label' => __( 'Usage tracking', CUSTOM_LOGIN_DIRNAME ),
455
- 'desc' => __( 'Allow Frosty Media to anonymously track how this plugin is used (and help us make the plugin better). Opt-in and receive a 20% discount code for all Custom Login extensions. Get your coupon code <a href="http://frosty.media/?p=21442">here</a>.', CUSTOM_LOGIN_DIRNAME ),
456
- 'type' => 'checkbox'
457
- ),
458
-
459
- /** BREAK **/
460
- array(
461
- 'name' => 'break_2',
462
- 'label' => sprintf( '<h4>%s</h4>', __( 'Notices', CUSTOM_LOGIN_DIRNAME ) ),
463
- 'desc' => '',
464
- 'type' => 'html',
465
- ),
466
- /** BREAK **/
467
-
468
- array(
469
- 'name' => 'admin_notices',
470
- 'label' => __( 'Admin notices', CUSTOM_LOGIN_DIRNAME ),
471
- 'desc' => __( 'Allow admin notices everywhere in WordPress.', CUSTOM_LOGIN_DIRNAME ) . $strings['unchecked'],
472
- 'type' => 'checkbox'
473
- ),
474
- array(
475
- 'name' => 'dashboard_widget',
476
- 'label' => __( 'Dashboard widget', CUSTOM_LOGIN_DIRNAME ),
477
- 'desc' => __( 'Show a dashboard widget, like WordPress news for Frosty Media.', CUSTOM_LOGIN_DIRNAME ) . $strings['unchecked'],
478
- 'type' => 'checkbox'
479
- ),
480
-
481
- /** BREAK **/
482
- array(
483
- 'name' => 'break_3',
484
- 'label' => sprintf( '<h4>%s</h4>', __( 'Login functions', CUSTOM_LOGIN_DIRNAME ) ),
485
- 'desc' => '',
486
- 'type' => 'html',
487
- ),
488
- /** BREAK **/
489
-
490
- array(
491
- 'name' => 'wp_shake_js',
492
- 'label' => __( 'Disable Login shake', CUSTOM_LOGIN_DIRNAME ),
493
- 'desc' => __( 'Disable the login forms animated "shake" on error.', CUSTOM_LOGIN_DIRNAME ),
494
- 'type' => 'checkbox'
495
- ),
496
- array(
497
- 'name' => 'remove_login_css',
498
- 'label' => __( 'Remove login CSS', CUSTOM_LOGIN_DIRNAME ),
499
- 'desc' => __( 'Remove WordPress\' login CSS. Warning: You\'ll have to add aditional syles not set by this plugin.', CUSTOM_LOGIN_DIRNAME ),
500
- 'type' => 'checkbox'
501
- ),
502
- array(
503
- 'name' => 'lostpassword_text',
504
- 'label' => __( 'Remove lost password text', CUSTOM_LOGIN_DIRNAME ),
505
- 'desc' => __( 'Remove the "Lost Password?" text. This does <strong>not</strong> disable the lost password function.', CUSTOM_LOGIN_DIRNAME ),
506
- 'type' => 'checkbox'
507
- ),
508
- );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/functions.php DELETED
@@ -1,33 +0,0 @@
1
- <?php
2
-
3
- // Exit if accessed directly
4
- if ( ! defined( 'ABSPATH' ) ) exit;
5
-
6
- /**
7
- * Return all editiable role capabilites.
8
- *
9
- * @ref http://codex.wordpress.org/Function_Reference/get_editable_roles
10
- * @return array
11
- */
12
- function custom_login_get_editable_roles() {
13
-
14
- $roles = array();
15
- foreach ( get_editable_roles() as $role_name => $role ) :
16
-
17
- // https://wordpress.org/support/topic/invalid-argument-supplied-for-foreach-error-line-in-wp-dashboard?replies=2#post-6427631
18
- if ( !is_array( $role['capabilities'] ) )
19
- break;
20
-
21
- foreach ( $role['capabilities'] as $capability => $array ) :
22
-
23
- // Remove the (deprecated) capabilities from the array
24
- if ( preg_match( '/^level_/', $capability ) )
25
- break;
26
-
27
- $roles[$capability] = $capability;
28
- endforeach;
29
-
30
- endforeach;
31
-
32
- return $roles;
33
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/libraries/edd-remote-install-client/EDD_Remote_Install_Client.php DELETED
@@ -1,394 +0,0 @@
1
- <?php
2
-
3
- /**
4
- * Allows plugins to install new plugins or upgrades
5
- *
6
- * @author Mindshare Studios, Inc.
7
- * @version 1.7.2 (FROSTY HACK)
8
- */
9
-
10
- class CL_Remote_Install_Client {
11
- private $api_url = '';
12
- private $options = array(
13
- 'skipplugincheck' => false
14
- );
15
-
16
- /**
17
- * Class constructor.
18
- *
19
- *
20
- * @param string $_api_url The URL pointing to the custom API endpoint.
21
- * @param string $_plugin_file Path to the plugin file.
22
- * @param array $_api_data Optional data to send with API calls.
23
- * @return void
24
- */
25
- function __construct( $_api_url, $page, $options = array() ) {
26
- $this->api_url = trailingslashit( $_api_url );
27
-
28
- if(isset($options['skipplugincheck']) && $options['skipplugincheck'] == true) {
29
- $this->options['skipplugincheck'] = true;
30
- }
31
-
32
- $options['page'] = $page;
33
- $this->options = $options;
34
-
35
- add_action( 'load-' . $page, array($this, 'register_scripts' ));
36
-
37
- add_action('wp_ajax_edd-activate-plugin-' . $page, array($this, 'activate_plugin'));
38
- add_action('wp_ajax_edd-deactivate-plugin-' . $page, array($this, 'deactivate_plugin'));
39
- add_action('wp_ajax_edd-check-plugin-status-' . $page, array($this, 'check_plugin_status'));
40
- add_action('wp_ajax_edd-check-remote-install-' . $page, array($this, 'check_remote_install'));
41
- add_action('wp_ajax_edd-do-remote-install-' . $page, array($this, 'do_remote_install'));
42
-
43
- add_action('wp_ajax_edd-do-manual-install-' . $page, array($this, 'do_manual_install'));
44
- add_action( 'plugins_api', array($this, 'plugins_api'), 100, 3 );
45
-
46
- add_action('eddri-install-complete-' . $page, array($this, 'install_complete'), 0, 1);
47
- }
48
-
49
- /**
50
- * Try to convert plugin name to slug
51
- *
52
- * @param $str Download name
53
- * @return $str Slug
54
- */
55
-
56
- private function slug($str) {
57
- // var_dump( $str ); exit;
58
- $str = strtolower( $str );
59
- $str = preg_replace("/[\s_]/", "-", $str);
60
-
61
- return $str;
62
- }
63
-
64
- /**
65
- * Register scripts and styles
66
- *
67
- * @return void
68
- */
69
-
70
- public function register_scripts() {
71
- wp_enqueue_script('edd-remote-install-script', plugin_dir_url( __FILE__ ) . '/js/edd-remote-install-admin.js', array('jquery'));
72
- wp_enqueue_style('edd-remote-install-style', plugin_dir_url( __FILE__ ) . '/css/edd-remote-install-admin.css');
73
-
74
- wp_localize_script( 'edd-remote-install-script', 'edd_ri_options', $this->options );
75
- }
76
-
77
- /**
78
- * Do manual install
79
- *
80
- * If a plugin was unable to be installed automatically, generate an install URL and redirect to the plugins API
81
- *
82
- * @param string $_POST['download'] Download requested
83
- * @param string $_POST['license'] License key
84
- * @return string $url
85
- */
86
-
87
- public function do_manual_install() {
88
-
89
- $download_name = urlencode($_POST['download']);
90
- $download_slug = $this->slug($_POST['download']);
91
-
92
- $license = '';
93
- if(isset($_POST['license']))
94
- $license = $_POST['license'];
95
-
96
- $nonce = wp_create_nonce('install-plugin_' . $download_slug);
97
-
98
- $url = admin_url('update.php?action=install-plugin&plugin=' . $download_slug . '&name=' . $download_name . '&license=' . $license . '&_wpnonce=' . $nonce . '&eddri=' . $this->options['page']);
99
-
100
- die($url);
101
-
102
- }
103
-
104
- /**
105
- * Plugins API
106
- *
107
- * Overrides the plugins API parameters for download URLs originated by EDDRI
108
- *
109
- * @param string $_GET['eddri'] EDDRI page that originated the request
110
- * @param string $_GET['license'] License key
111
- * @param string $_GET['name'] Name of the plugin requested
112
- * @return obj $api
113
- */
114
-
115
- public function plugins_api($api, $action, $args) {
116
-
117
- if($action = 'plugin_information') {
118
-
119
- if(isset($_GET['eddri']) && $_GET['eddri'] == $this->options['page']) {
120
-
121
- $api_params = array(
122
- 'edd_action' => 'get_download',
123
- 'item_name' => urlencode( $_GET['name'] ),
124
- 'license' => urlencode( $_GET['license'] )
125
- );
126
-
127
- $download_link = esc_url( add_query_arg($api_params, $this->api_url) );
128
-
129
- ///////////// NEW /////////////////
130
- $download_id = $this->get_remote_download_id( $_GET['name'] );
131
- $download_link = $this->get_encoded_download_package_url( $download_id, $_GET['license'] );
132
- ///////////// NEW /////////////////
133
-
134
- $api = new stdClass();
135
- $api->name = $args->slug;
136
- $api->version = "";
137
- $api->download_link = $download_link;
138
-
139
- }
140
-
141
- }
142
-
143
- return $api;
144
-
145
- }
146
-
147
- /**
148
- * Callback action that's fired when an install is completed successfully
149
- *
150
- * @param array $args Install complete arguments
151
- * @return void
152
- */
153
-
154
- public function install_complete($args) {
155
-
156
-
157
- }
158
-
159
- /**
160
- * Check plugin status
161
- *
162
- * Checks to see if a plugin is currently installed and disables the install button if so
163
- *
164
- * @param string $_POST['download'] Download requested
165
- * @return string $response
166
- */
167
-
168
- public function check_plugin_status() {
169
-
170
- $plugin = $this->slug($_POST['download']);
171
-
172
- if (is_plugin_active($plugin . '/' . $plugin . '.php')) {
173
- die("active");
174
- } elseif (file_exists(WP_PLUGIN_DIR . '/' . $plugin . '/' . $plugin . '.php')) {
175
- die("installed");
176
- } {
177
- die(false);
178
- }
179
- }
180
-
181
- /**
182
- * Check remote install
183
- *
184
- * Checks remote server for the specified Download
185
- *
186
- * @param string $_POST['download'] Download requested
187
- * @return string $response
188
- */
189
-
190
- public function check_remote_install() {
191
-
192
- if ( ! current_user_can('install_plugins') )
193
- die( 'You do not have sufficient permissions to install plugins on this site.' );
194
-
195
- $api_params = array(
196
- 'edd_action' => 'check_download',
197
- 'item_name' => urlencode( $_POST['download'] )
198
- );
199
-
200
- $request = wp_remote_post( $this->api_url, array( 'timeout' => 15, 'sslverify' => false, 'body' => $api_params ) );
201
-
202
- if ( ! is_wp_error( $request ) ):
203
- $request = json_decode( wp_remote_retrieve_body( $request ) );
204
- $request = maybe_unserialize( $request );
205
-
206
- if($request->download == "free") {
207
-
208
- $response = "0";
209
-
210
- } else if ($request->download == "not-free") {
211
-
212
- $response = "1";
213
-
214
- } else {
215
-
216
- $response = "does not exist";
217
-
218
- }
219
-
220
- else:
221
-
222
- $response = "Error occurred while trying to reach remote server. Please try again or contact support.";
223
-
224
- endif;
225
-
226
- die(json_encode($response));
227
- }
228
-
229
- /**
230
- * Activate plugin
231
- *
232
- * Attemps to activate a plugin which is installed and inactive. Triggered by user clicking "Activate".
233
- *
234
- * @param string $_POST['download'] Download requested
235
- * @return response
236
- */
237
-
238
- public function activate_plugin() {
239
-
240
- $slug = $this->slug($_POST['download']);
241
- $path = WP_PLUGIN_DIR . "/" . $slug . "/" . $slug . ".php";
242
- activate_plugin( $path );
243
-
244
- if(is_plugin_active( $slug . '/' . $slug . '.php' )) {
245
- die('activated');
246
- } else {
247
- die('error');
248
- }
249
-
250
- }
251
-
252
- /**
253
- * Deactivate plugin
254
- *
255
- * Attemps to deactivate a plugin. Triggered by user clicking "Deactivate".
256
- *
257
- * @param string $_POST['download'] Download requested
258
- * @return response
259
- */
260
-
261
- public function deactivate_plugin() {
262
-
263
- $slug = $this->slug($_POST['download']);
264
- $path = WP_PLUGIN_DIR . "/" . $slug . "/" . $slug . ".php";
265
- deactivate_plugins( $path );
266
-
267
- if(!is_plugin_active( $slug . '/' . $slug . '.php' )) {
268
- die('deactivated');
269
- } else {
270
- die('error');
271
- }
272
-
273
- }
274
-
275
- /**
276
- * Manual install
277
- *
278
- * Outputs full install log in cases where auto-install failed
279
- *
280
- * @param string $_POST['download'] Download requested
281
- * @return response
282
- */
283
-
284
- public function manual_install() {
285
-
286
- echo "Hi";
287
-
288
- }
289
-
290
- /**
291
- * Do remote install
292
- *
293
- * Passes the download and license key (if specified) to the server and receives and installs the plugin package
294
- *
295
- * @param string $_POST['license'] License key (if specified)
296
- * @param string $_POST['download'] Download requested
297
- * @return response
298
- */
299
-
300
- public function do_remote_install() {
301
-
302
- if ( ! current_user_can('install_plugins') )
303
- wp_die( 'You do not have sufficient permissions to install plugins on this site.' );
304
-
305
- $download = $_POST['download'];
306
-
307
- if(isset($_POST['license'])) {
308
- $license = $_POST['license'];
309
-
310
- $api_params = array(
311
- 'edd_action'=> 'activate_license',
312
- 'license' => $license,
313
- 'item_name' => urlencode( $download ) // the name of our product in EDD
314
- );
315
-
316
- // Call the custom API.
317
- $response = wp_remote_get( esc_url( add_query_arg( $api_params, $this->api_url ) ), array( 'timeout' => 15, 'sslverify' => false ) );
318
-
319
- // make sure the response came back okay
320
- if ( is_wp_error( $response ) )
321
- return false;
322
-
323
- // decode the license data
324
- $license_data = json_decode( wp_remote_retrieve_body( $response ) );
325
-
326
- if($license_data->license != "valid")
327
- die("invalid");
328
-
329
- } else {
330
-
331
- // If its a free download, don't send a license
332
- $license = null;
333
-
334
- }
335
-
336
- $api_params = array(
337
- 'edd_action' => 'get_download',
338
- 'item_name' => urlencode( $download ),
339
- 'license' => urlencode( $license )
340
- );
341
-
342
- // decode the license data
343
- $download_id = $this->get_remote_download_id( $download );
344
-
345
- $download_link = $this->get_encoded_download_package_url( $download_id, $license );
346
-
347
- if ( !class_exists( 'Plugin_Upgrader' ) )
348
- include_once ( ABSPATH . 'wp-admin/includes/class-wp-upgrader.php' ); //for plugins_api..
349
-
350
- $upgrader = new Plugin_Upgrader();
351
-
352
- $result = $upgrader->install($download_link);
353
-
354
- if($result == 1) {
355
- $slug = $this->slug($download);
356
- $path = WP_PLUGIN_DIR . "/" . $slug . "/" . $slug . ".php";
357
- $result = activate_plugin( $path );
358
-
359
- $args['slug'] = $slug;
360
- $args['license'] = $license;
361
- do_action('eddri-install-complete-' . $this->options['page'], $args);
362
- }
363
-
364
- die();
365
- }
366
-
367
- private function get_remote_download_id( $download_title, $download_id = null ) {
368
-
369
- $api_params = array(
370
- 'edd_action' => 'get_download_id',
371
- 'item_name' => urlencode( $download_title )
372
- );
373
-
374
- $response = wp_remote_get( esc_url( add_query_arg( $api_params, $this->api_url ) ), array( 'timeout' => 15, 'sslverify' => false ) );
375
-
376
- if ( !is_wp_error( $response ) )
377
- $download_id = json_decode( wp_remote_retrieve_body( $response ) );
378
-
379
- return $download_id;
380
- }
381
-
382
- private function get_encoded_download_package_url( $download_id, $license ) {
383
-
384
- $package_url = add_query_arg( array(
385
- 'edd_action' => 'package_download',
386
- 'id' => $download_id,
387
- 'key' => $license,
388
- 'expires' => rawurlencode( base64_encode( strtotime( '+1 hour' ) ) )
389
- ), $this->api_url );
390
-
391
- return apply_filters( 'edd_sl_encoded_package_url', esc_url( $package_url ) );
392
-
393
- }
394
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/libraries/edd-remote-install-client/css/edd-remote-install-admin.css DELETED
@@ -1,210 +0,0 @@
1
- .edd-remote-install {
2
- display: inline-block;
3
- font-size:14px;
4
- color:#fff !important;
5
- text-decoration: none !important;
6
- padding:14px 60px;
7
- line-height:1;
8
- overflow: hidden;
9
- position:relative;
10
-
11
- box-shadow:0 1px 1px #ccc;
12
- border-radius:2px;
13
-
14
- background-color: #21759b;
15
- background-image: -webkit-gradient(linear,left top,left bottom,from(#2a95c5),to(#21759b));
16
- background-image: -webkit-linear-gradient(top,#2a95c5,#21759b);
17
- background-image: -moz-linear-gradient(top,#2a95c5,#21759b);
18
- background-image: -ms-linear-gradient(top,#2a95c5,#21759b);
19
- background-image: -o-linear-gradient(top,#2a95c5,#21759b);
20
- background-image: linear-gradient(to bottom,#2a95c5,#21759b);
21
- border: 1px solid #21759b;
22
- border-bottom-color: #1e6a8d;
23
- border-radius: 3px;
24
- -webkit-box-shadow: inset 0 1px 0 rgba(120,200,230,0.5);
25
- box-shadow: inset 0 1px 0 rgba(120,200,230,0.5);
26
- text-decoration: none;
27
- text-shadow: 0 1px 0 rgba(0,0,0,0.1);
28
-
29
- cursor: pointer;
30
-
31
- }
32
-
33
- .edd-remote-install.disabled {
34
- pointer-events: none;
35
- cursor: default;
36
- background-color: #9c9c9c;
37
- background-image: -webkit-gradient(linear,left top,left bottom,from(#c4c4c4),to(#9c9c9c));
38
- background-image: -webkit-linear-gradient(top,#c4c4c4,#9c9c9c);
39
- background-image: -moz-linear-gradient(top,#c4c4c4,#9c9c9c);
40
- background-image: -ms-linear-gradient(top,#c4c4c4,#9c9c9c);
41
- background-image: -o-linear-gradient(top,#c4c4c4,#9c9c9c);
42
- background-image: linear-gradient(to bottom,#c4c4c4,#9c9c9c);
43
- border: 1px solid #9c9c9c;
44
- border-bottom-color: #8c8c8c;
45
- box-shadow: inset 0 1px 0 rgba(0,0,0,0.2);
46
- }
47
-
48
- .eddri-addon {
49
- vertical-align: top;
50
- border: 1px solid #CCC;
51
- }
52
-
53
- .eddri-addon .eddri-addon-container {
54
- margin: 5px;
55
- }
56
-
57
- .eddri-addon .eddri-img-wrap {
58
- border: 1px solid #efefef;
59
- overflow: hidden;
60
- position: relative;
61
- }
62
- .eddri-addon .eddri-img-wrap > p {
63
- background: #fff;
64
- bottom: 0;
65
- margin: 0 0 -25px 0;
66
- padding: 10px;
67
- position: absolute;
68
- opacity: 0.1;
69
-
70
- -webkit-transition: all 0.15s linear;
71
- -moz-transition: all 0.15s linear;
72
- -o-transition: all 0.15s linear;
73
- transition: all 0.15s linear;
74
- }
75
- .eddri-addon .eddri-img-wrap:hover > p {
76
- margin: 0;
77
- opacity: 0.98;
78
- }
79
-
80
- .eddri-addon .eddri-thumbnail {
81
- width: 100%;
82
- height: auto;
83
- }
84
-
85
- .eddri-addon h3 {
86
- line-height: 1.4em !important;
87
- min-height: 60px;
88
- }
89
-
90
- .eddri-addon a.button {
91
- margin-top: 12px;
92
- }
93
-
94
- .eddri-addon span.eddri-status {
95
- background-color: #EEE;
96
- border: 1px solid #DADADA;
97
- padding: 6px;
98
- display: block;
99
- position: relative;
100
- font-weight: bold;
101
- color: #424242;
102
- -webkit-border-radius: 3px;
103
- -moz-border-radius: 3px;
104
- border-radius: 3px;
105
- }
106
-
107
- .eddri-addon span.eddri-status.eddri-inactive {
108
- background-color: #FFFBCC;
109
- border: 1px solid #E6DB55;
110
- }
111
-
112
- .eddri-addon span.eddri-status.eddri-active {
113
- background-color: #CBECA0;
114
- border: 1px solid #97B48A;
115
- color: #2D5312;
116
- }
117
-
118
- .eddri-addon span.eddri-status.eddri-error {
119
- color: #A94442;
120
- background-color: #F2DEDE;
121
- border: 1px solid #EBCCD1;
122
- }
123
-
124
- .eddri-status.in-progress {
125
- cursor: progress;
126
- background-color: #D9EDF7 !important;
127
- }
128
-
129
- .eddri-status.stopped {
130
- cursor: pointer;
131
- background-color: #D9EDF7 !important;
132
- }
133
-
134
- .eddri-status.success {
135
- background-color: #D9EDF7 !important;
136
- }
137
-
138
- .eddri-status.failure {
139
-
140
- }
141
- /* Hide the original text of the button. Then the loading or finished
142
- text will be shown in the :after element above it. */
143
-
144
- .eddri-status.in-progress,
145
- .eddri-status.finished{
146
- color:transparent !important;
147
- text-shadow: none;
148
- }
149
-
150
- .eddri-status.in-progress:after,
151
- .eddri-status.finished:after{
152
- position: absolute;
153
- z-index: 2;
154
- width: 100%;
155
- height: 100%;
156
- top: 6px;
157
- left: 6px;
158
- color: #424242;
159
- }
160
-
161
- /* If the .in-progress class is set on the button, show the
162
- contents of the data-loading attribute on the butotn */
163
-
164
- .eddri-status.in-progress:after{
165
- content:attr(data-loading);
166
- }
167
-
168
- /* The same goes for the .finished class */
169
-
170
- .eddri-status.finished:after{
171
- content:attr(data-finished);
172
- }
173
-
174
- .eddri-status.eddri-error:after{
175
- color: #A94442;
176
- }
177
-
178
- /* The colorful bar that grows depending on the progress */
179
-
180
- .eddri-status .tz-bar{
181
- background-color: #428BCA;
182
- height:3px;
183
- bottom:0;
184
- left:0;
185
- width:0;
186
- position:absolute;
187
- z-index:1;
188
-
189
- border-radius:0 0 2px 2px;
190
-
191
- -webkit-transition: width 0.5s, height 0.5s;
192
- -moz-transition: width 0.5s, height 0.5s;
193
- transition: width 0.5s, height 0.5s;
194
- }
195
-
196
- /* The bar can be either horizontal, or vertical */
197
-
198
- .eddri-status .tz-bar.background-horizontal{
199
- height:100%;
200
- border-radius:2px;
201
- }
202
-
203
- #license-input {
204
- display: block;
205
- position: relative;
206
- margin-top: 4px;
207
- outline: none;
208
- width: 100%;
209
- line-height: 18px;
210
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/libraries/edd-remote-install-client/js/edd-remote-install-admin.js DELETED
@@ -1,364 +0,0 @@
1
- jQuery(document).ready(function ($) {
2
-
3
- if(edd_ri_options.skipplugincheck != true) {
4
-
5
- $('a[data-edd-install]').each(function() {
6
-
7
- var downloadButton = $(this);
8
-
9
- var data = {
10
- action: 'edd-check-plugin-status-' + edd_ri_options.page,
11
- download: downloadButton.data('edd-install')
12
- }
13
-
14
- $.post(ajaxurl, data, function (res) {
15
-
16
- if(res) {
17
- if(res == 'installed') {
18
- $(downloadButton).prev(".eddri-status").text("Inactive").addClass('eddri-inactive');
19
- $(downloadButton).text('Activate');
20
- }
21
- if(res == 'active') {
22
- $(downloadButton).prev(".eddri-status").text("Active").addClass('eddri-active');
23
- $(downloadButton).text('Deactivate');
24
- }
25
-
26
- }
27
-
28
- });
29
-
30
- });
31
- }
32
-
33
- $('body').on('click', 'a[data-edd-install]', function (e) {
34
- e.preventDefault();
35
-
36
- var downloadButton = $(this);
37
- var statusContainer = $(this).prev(".eddri-status");
38
-
39
- if(downloadButton.text() == 'Activate') {
40
-
41
- var data = {
42
- action: 'edd-activate-plugin-' + edd_ri_options.page,
43
- download: downloadButton.data('edd-install')
44
- }
45
-
46
- $.post(ajaxurl, data, function (res) {
47
-
48
- if(res == 'activated') {
49
-
50
- $(statusContainer).text("Active").addClass('eddri-active');
51
- $(downloadButton).text('Deactivate');
52
-
53
- } else {
54
-
55
- $(statusContainer).addClass('eddri-error').text("Error activating. Try activating manually from the plugins screen.");
56
-
57
- }
58
-
59
- });
60
-
61
- } else if(downloadButton.text() == 'Deactivate') {
62
-
63
- var data = {
64
- action: 'edd-deactivate-plugin-' + edd_ri_options.page,
65
- download: downloadButton.data('edd-install')
66
- }
67
-
68
- $.post(ajaxurl, data, function (res) {
69
-
70
- if(res == 'deactivated') {
71
-
72
- $(statusContainer).text("Inactive").removeClass('eddri-active success finished').addClass('eddri-inactive');
73
- $(downloadButton).text('Activate');
74
-
75
- } else {
76
-
77
- $(statusContainer).addClass('eddri-error').text("Error deactivating. Try deactivating manually from the plugins screen.");
78
-
79
- }
80
-
81
- });
82
-
83
- } else {
84
-
85
- var data = {
86
- action: 'edd-check-remote-install-' + edd_ri_options.page,
87
- download: downloadButton.data('edd-install')
88
- }
89
-
90
- statusContainer.progressInitialize()
91
- .progressStart()
92
- .attr({'data-loading': "Requesting package..."});
93
-
94
- $.post(ajaxurl, data, function (res) {
95
- res = $.parseJSON( res );
96
- if (res == '0') {
97
- // Free download found
98
-
99
- var data = {
100
- action: 'edd-do-remote-install-' + edd_ri_options.page,
101
- download: downloadButton.data('edd-install')
102
- };
103
-
104
- statusContainer.progressSet(50)
105
- .attr({'data-loading': "Found package. Installing..."});
106
-
107
- $.post(ajaxurl, data, function (res) {
108
- $(downloadButton).text('Deactivate');
109
- return statusContainer.progressFinish(res, downloadButton);
110
- });
111
-
112
- } else if (res == '1') {
113
- // License key required to continue
114
- statusContainer.validateLicense(downloadButton);
115
- } else {
116
-
117
- return statusContainer.progressFinish(res, downloadButton);
118
- }
119
-
120
- });
121
- }
122
- });
123
-
124
- // Progress meter functionality defined in jQuery plugins.
125
-
126
- $.fn.validateLicense = function(downloadButton) {
127
- var statusContainer = $(downloadButton).prev(".eddri-status");
128
- var licenseInput;
129
-
130
- // Pause auto-updating of progress bar and create license key input field
131
- statusContainer.progressStop(40)
132
- .attr({'data-loading': "Enter license key to continue:"})
133
- .after("<input id='license-input' placeholder='License key'></input>")
134
- .off('click')
135
- .removeClass('success failure');
136
-
137
- licenseInput = $('#license-input');
138
-
139
- licenseInput.click(function() {
140
-
141
- statusContainer.attr({'data-loading': "Click to proceed."})
142
-
143
- statusContainer.click(function (e) {
144
- e.stopPropagation();
145
- validPost();
146
- });
147
-
148
- downloadButton.click(function (e) {
149
- e.stopPropagation();
150
- validPost();
151
- });
152
-
153
- $(document).keypress(function (e) {
154
- if(e.which == 13) {
155
- e.preventDefault();
156
- validPost();
157
- }
158
- });
159
-
160
- function validPost() {
161
- var license = licenseInput.val();
162
- if (!license) return false;
163
-
164
- var data = {
165
- action: 'edd-do-remote-install-' + edd_ri_options.page,
166
- download: downloadButton.data('edd-install'),
167
- license: license,
168
- url: edd_ri_options.url
169
- }
170
-
171
- licenseInput.remove();
172
-
173
- statusContainer.progressStart().progressSet(50)
174
- .attr({'data-loading': "Validating license..."});
175
-
176
- $.post(ajaxurl, data, function (res) {
177
- statusContainer.progressFinish(res, downloadButton, license);
178
- });
179
- };
180
- });
181
- }
182
-
183
- $.fn.progressInitialize = function() {
184
- var button = this;
185
- var progress = 0;
186
-
187
- // Add markup for the progress bar.
188
- var bar = $('<span class="tz-bar background-horizontal">').appendTo(button);
189
-
190
- button.on('progress', function (e, val, absolute, finished) {
191
- var finished = finished;
192
-
193
- // Make sure button has `in-progress` class when initialized.
194
- // And that local var `progress` = 0 to start.
195
- // Then show the progress bar.
196
- if (!button.hasClass('in-progress')) {
197
- button.removeClass('finished').addClass('in-progress');
198
- progress = 0;
199
- bar.show();
200
- }
201
-
202
- if (absolute) {
203
- progress = val;
204
- } else if (progress >= 100) {
205
- progress = 100;
206
- finished = true;
207
- } else {
208
- progress += val;
209
- }
210
-
211
- if (finished) {
212
- button.removeClass('in-progress').addClass('finished');
213
-
214
- bar.delay(500).fadeOut(function() {
215
- button.trigger('progress-finish');
216
- setProgress(0);
217
- });
218
- }
219
-
220
- setProgress(progress);
221
- });
222
-
223
- function setProgress (percentage) {
224
- bar.filter('.background-horizontal,.background-bar').width(percentage+'%');
225
- bar.filter('.background-vertical').height(percentage+'%');
226
- }
227
-
228
- return button;
229
- };
230
-
231
- $.fn.progressStart = function() {
232
- var button = this;
233
- var last_progress = new Date().getTime();
234
-
235
- if (button.hasClass('in-progress')) {
236
- // Don't start it a second time!
237
- return button;
238
- }
239
-
240
- button.on('progress', function() {
241
- last_progress = new Date().getTime();
242
- });
243
-
244
- // Every half a second check whether the progress
245
- // has been incremented in the last two seconds
246
-
247
- var interval = window.setInterval(function() {
248
-
249
- // Check every half-second to see whether
250
- // progress has incremented in past 2 seconds.
251
- if ( new Date().getTime() > 2000+last_progress && !button.hasClass('stopped')) {
252
-
253
- // There has been no activity for 2s. Increment the progress
254
- // bar a little bit to show that something is happening.
255
- button.progressIncrement(5);
256
- }
257
-
258
- }, 500);
259
-
260
- button.on('progress-finish', function() {
261
- window.clearInterval(interval);
262
- }).progressIncrement(10);
263
- return button;
264
- };
265
-
266
- $.fn.progressSet = function (val) {
267
- var button = this;
268
- var finished = false;
269
- val = val || 10;
270
-
271
- if (button.hasClass('stopped')) {
272
- button.removeClass('stopped');
273
- }
274
-
275
- if (val >= 100) {
276
- finished = true;
277
- }
278
-
279
- button.trigger('progress', [val, true, finished]);
280
- return button;
281
- };
282
-
283
- $.fn.progressIncrement = function (val) {
284
- var button = this;
285
- val = val || 10;
286
- button.trigger('progress', [val]);
287
- return button;
288
- };
289
-
290
- $.fn.progressStop = function (val) {
291
- var button = this;
292
- button.progressSet(val).addClass('stopped');
293
- return button;
294
- };
295
-
296
- $.fn.progressFinish = function (res, downloadButton, license) {
297
- // alert(res);
298
-
299
- var statusContainer = $(downloadButton).prev(".eddri-status");
300
-
301
- statusContainer.progressSet(100);
302
-
303
- if (res === 'invalid') {
304
- statusContainer.attr({'data-finished': "Invalid License"});
305
-
306
- setTimeout(function() {
307
- statusContainer.validateLicense(downloadButton);
308
- }, 1200);
309
-
310
- } else if (res.search('error') > 0) {
311
-
312
- // If there was an unknown error, try to run the install manually
313
-
314
- statusContainer.attr({'data-finished': "Unknown error. Redirecting..."})
315
- .addClass('eddri-error');
316
-
317
- var data = {
318
- action: 'edd-do-manual-install-' + edd_ri_options.page,
319
- download: downloadButton.data('edd-install'),
320
- license: license
321
- }
322
-
323
- $.post(ajaxurl, data, function (res) {
324
- // console.log(res);
325
- window.location.href = res;
326
- });
327
-
328
- } else if (res.search('already exists') > 0) {
329
- statusContainer.attr({'data-finished': "Error: Already installed"})
330
- .addClass('eddri-error');
331
-
332
- } else if (res.search('not exist') > 0) {
333
- statusContainer.attr({'data-finished': "Error: Plugin file does not exist."})
334
- .addClass('eddri-error');
335
-
336
- } else if (res.search('installed successfully') > 0) {
337
- statusContainer.attr({'data-finished': "Success!"})
338
- .addClass('success');
339
- $(downloadButton).text('Deactivate');
340
-
341
- } else {
342
-
343
- // If there was an unknown error, try to run the install manually
344
-
345
- statusContainer.attr({'data-finished': "Unknown error. Redirecting..."})
346
- .addClass('eddri-error');
347
-
348
- var data = {
349
- action: 'edd-do-manual-install-' + edd_ri_options.page,
350
- download: downloadButton.data('edd-install'),
351
- license: license
352
- }
353
-
354
- $.post(ajaxurl, data, function (res) {
355
- //console.log(res);
356
- window.location.href = res;
357
- });
358
-
359
- }
360
-
361
- return statusContainer;
362
- };
363
-
364
- });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
js/ace/src-min-noconflict/ace.js DELETED
@@ -1,11 +0,0 @@
1
- (function(){function s(r){var i=function(e,t){return n("",e,t)},s=e;r&&(e[r]||(e[r]={}),s=e[r]);if(!s.define||!s.define.packaged)t.original=s.define,s.define=t,s.define.packaged=!0;if(!s.require||!s.require.packaged)n.original=s.require,s.require=i,s.require.packaged=!0}var ACE_NAMESPACE = "ace",e=function(){return this}();if(!ACE_NAMESPACE&&typeof requirejs!="undefined")return;var t=function(e,n,r){if(typeof e!="string"){t.original?t.original.apply(window,arguments):(console.error("dropping module because define wasn't a string."),console.trace());return}arguments.length==2&&(r=n),t.modules||(t.modules={},t.payloads={}),t.payloads[e]=r,t.modules[e]=null},n=function(e,t,r){if(Object.prototype.toString.call(t)==="[object Array]"){var s=[];for(var o=0,u=t.length;o<u;++o){var a=i(e,t[o]);if(!a&&n.original)return n.original.apply(window,arguments);s.push(a)}r&&r.apply(null,s)}else{if(typeof t=="string"){var f=i(e,t);return!f&&n.original?n.original.apply(window,arguments):(r&&r(),f)}if(n.original)return n.original.apply(window,arguments)}},r=function(e,t){if(t.indexOf("!")!==-1){var n=t.split("!");return r(e,n[0])+"!"+r(e,n[1])}if(t.charAt(0)=="."){var i=e.split("/").slice(0,-1).join("/");t=i+"/"+t;while(t.indexOf(".")!==-1&&s!=t){var s=t;t=t.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return t},i=function(e,i){i=r(e,i);var s=t.modules[i];if(!s){s=t.payloads[i];if(typeof s=="function"){var o={},u={id:i,uri:"",exports:o,packaged:!0},a=function(e,t){return n(i,e,t)},f=s(a,o,u);o=f||u.exports,t.modules[i]=o,delete t.payloads[i]}s=t.modules[i]=o||s}return s};s(ACE_NAMESPACE)})(),ace.define("ace/lib/regexp",["require","exports","module"],function(e,t,n){"use strict";function o(e){return(e.global?"g":"")+(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.extended?"x":"")+(e.sticky?"y":"")}function u(e,t,n){if(Array.prototype.indexOf)return e.indexOf(t,n);for(var r=n||0;r<e.length;r++)if(e[r]===t)return r;return-1}var r={exec:RegExp.prototype.exec,test:RegExp.prototype.test,match:String.prototype.match,replace:String.prototype.replace,split:String.prototype.split},i=r.exec.call(/()??/,"")[1]===undefined,s=function(){var e=/^/g;return r.test.call(e,""),!e.lastIndex}();if(s&&i)return;RegExp.prototype.exec=function(e){var t=r.exec.apply(this,arguments),n,a;if(typeof e=="string"&&t){!i&&t.length>1&&u(t,"")>-1&&(a=RegExp(this.source,r.replace.call(o(this),"g","")),r.replace.call(e.slice(t.index),a,function(){for(var e=1;e<arguments.length-2;e++)arguments[e]===undefined&&(t[e]=undefined)}));if(this._xregexp&&this._xregexp.captureNames)for(var f=1;f<t.length;f++)n=this._xregexp.captureNames[f-1],n&&(t[n]=t[f]);!s&&this.global&&!t[0].length&&this.lastIndex>t.index&&this.lastIndex--}return t},s||(RegExp.prototype.test=function(e){var t=r.exec.call(this,e);return t&&this.global&&!t[0].length&&this.lastIndex>t.index&&this.lastIndex--,!!t})}),ace.define("ace/lib/es5-shim",["require","exports","module"],function(e,t,n){function r(){}function w(e){try{return Object.defineProperty(e,"sentinel",{}),"sentinel"in e}catch(t){}}function H(e){return e=+e,e!==e?e=0:e!==0&&e!==1/0&&e!==-1/0&&(e=(e>0||-1)*Math.floor(Math.abs(e))),e}function B(e){var t=typeof e;return e===null||t==="undefined"||t==="boolean"||t==="number"||t==="string"}function j(e){var t,n,r;if(B(e))return e;n=e.valueOf;if(typeof n=="function"){t=n.call(e);if(B(t))return t}r=e.toString;if(typeof r=="function"){t=r.call(e);if(B(t))return t}throw new TypeError}Function.prototype.bind||(Function.prototype.bind=function(t){var n=this;if(typeof n!="function")throw new TypeError("Function.prototype.bind called on incompatible "+n);var i=u.call(arguments,1),s=function(){if(this instanceof s){var e=n.apply(this,i.concat(u.call(arguments)));return Object(e)===e?e:this}return n.apply(t,i.concat(u.call(arguments)))};return n.prototype&&(r.prototype=n.prototype,s.prototype=new r,r.prototype=null),s});var i=Function.prototype.call,s=Array.prototype,o=Object.prototype,u=s.slice,a=i.bind(o.toString),f=i.bind(o.hasOwnProperty),l,c,h,p,d;if(d=f(o,"__defineGetter__"))l=i.bind(o.__defineGetter__),c=i.bind(o.__defineSetter__),h=i.bind(o.__lookupGetter__),p=i.bind(o.__lookupSetter__);if([1,2].splice(0).length!=2)if(!function(){function e(e){var t=new Array(e+2);return t[0]=t[1]=0,t}var t=[],n;t.splice.apply(t,e(20)),t.splice.apply(t,e(26)),n=t.length,t.splice(5,0,"XXX"),n+1==t.length;if(n+1==t.length)return!0}())Array.prototype.splice=function(e,t){var n=this.length;e>0?e>n&&(e=n):e==void 0?e=0:e<0&&(e=Math.max(n+e,0)),e+t<n||(t=n-e);var r=this.slice(e,e+t),i=u.call(arguments,2),s=i.length;if(e===n)s&&this.push.apply(this,i);else{var o=Math.min(t,n-e),a=e+o,f=a+s-o,l=n-a,c=n-o;if(f<a)for(var h=0;h<l;++h)this[f+h]=this[a+h];else if(f>a)for(h=l;h--;)this[f+h]=this[a+h];if(s&&e===c)this.length=c,this.push.apply(this,i);else{this.length=c+s;for(h=0;h<s;++h)this[e+h]=i[h]}}return r};else{var v=Array.prototype.splice;Array.prototype.splice=function(e,t){return arguments.length?v.apply(this,[e===void 0?0:e,t===void 0?this.length-e:t].concat(u.call(arguments,2))):[]}}Array.isArray||(Array.isArray=function(t){return a(t)=="[object Array]"});var m=Object("a"),g=m[0]!="a"||!(0 in m);Array.prototype.forEach||(Array.prototype.forEach=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=arguments[1],s=-1,o=r.length>>>0;if(a(t)!="[object Function]")throw new TypeError;while(++s<o)s in r&&t.call(i,r[s],s,n)}),Array.prototype.map||(Array.prototype.map=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0,s=Array(i),o=arguments[1];if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");for(var u=0;u<i;u++)u in r&&(s[u]=t.call(o,r[u],u,n));return s}),Array.prototype.filter||(Array.prototype.filter=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0,s=[],o,u=arguments[1];if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");for(var f=0;f<i;f++)f in r&&(o=r[f],t.call(u,o,f,n)&&s.push(o));return s}),Array.prototype.every||(Array.prototype.every=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0,s=arguments[1];if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");for(var o=0;o<i;o++)if(o in r&&!t.call(s,r[o],o,n))return!1;return!0}),Array.prototype.some||(Array.prototype.some=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0,s=arguments[1];if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");for(var o=0;o<i;o++)if(o in r&&t.call(s,r[o],o,n))return!0;return!1}),Array.prototype.reduce||(Array.prototype.reduce=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0;if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");if(!i&&arguments.length==1)throw new TypeError("reduce of empty array with no initial value");var s=0,o;if(arguments.length>=2)o=arguments[1];else do{if(s in r){o=r[s++];break}if(++s>=i)throw new TypeError("reduce of empty array with no initial value")}while(!0);for(;s<i;s++)s in r&&(o=t.call(void 0,o,r[s],s,n));return o}),Array.prototype.reduceRight||(Array.prototype.reduceRight=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0;if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");if(!i&&arguments.length==1)throw new TypeError("reduceRight of empty array with no initial value");var s,o=i-1;if(arguments.length>=2)s=arguments[1];else do{if(o in r){s=r[o--];break}if(--o<0)throw new TypeError("reduceRight of empty array with no initial value")}while(!0);do o in this&&(s=t.call(void 0,s,r[o],o,n));while(o--);return s});if(!Array.prototype.indexOf||[0,1].indexOf(1,2)!=-1)Array.prototype.indexOf=function(t){var n=g&&a(this)=="[object String]"?this.split(""):F(this),r=n.length>>>0;if(!r)return-1;var i=0;arguments.length>1&&(i=H(arguments[1])),i=i>=0?i:Math.max(0,r+i);for(;i<r;i++)if(i in n&&n[i]===t)return i;return-1};if(!Array.prototype.lastIndexOf||[0,1].lastIndexOf(0,-3)!=-1)Array.prototype.lastIndexOf=function(t){var n=g&&a(this)=="[object String]"?this.split(""):F(this),r=n.length>>>0;if(!r)return-1;var i=r-1;arguments.length>1&&(i=Math.min(i,H(arguments[1]))),i=i>=0?i:r-Math.abs(i);for(;i>=0;i--)if(i in n&&t===n[i])return i;return-1};Object.getPrototypeOf||(Object.getPrototypeOf=function(t){return t.__proto__||(t.constructor?t.constructor.prototype:o)});if(!Object.getOwnPropertyDescriptor){var y="Object.getOwnPropertyDescriptor called on a non-object: ";Object.getOwnPropertyDescriptor=function(t,n){if(typeof t!="object"&&typeof t!="function"||t===null)throw new TypeError(y+t);if(!f(t,n))return;var r,i,s;r={enumerable:!0,configurable:!0};if(d){var u=t.__proto__;t.__proto__=o;var i=h(t,n),s=p(t,n);t.__proto__=u;if(i||s)return i&&(r.get=i),s&&(r.set=s),r}return r.value=t[n],r}}Object.getOwnPropertyNames||(Object.getOwnPropertyNames=function(t){return Object.keys(t)});if(!Object.create){var b;Object.prototype.__proto__===null?b=function(){return{__proto__:null}}:b=function(){var e={};for(var t in e)e[t]=null;return e.constructor=e.hasOwnProperty=e.propertyIsEnumerable=e.isPrototypeOf=e.toLocaleString=e.toString=e.valueOf=e.__proto__=null,e},Object.create=function(t,n){var r;if(t===null)r=b();else{if(typeof t!="object")throw new TypeError("typeof prototype["+typeof t+"] != 'object'");var i=function(){};i.prototype=t,r=new i,r.__proto__=t}return n!==void 0&&Object.defineProperties(r,n),r}}if(Object.defineProperty){var E=w({}),S=typeof document=="undefined"||w(document.createElement("div"));if(!E||!S)var x=Object.defineProperty}if(!Object.defineProperty||x){var T="Property description must be an object: ",N="Object.defineProperty called on non-object: ",C="getters & setters can not be defined on this javascript engine";Object.defineProperty=function(t,n,r){if(typeof t!="object"&&typeof t!="function"||t===null)throw new TypeError(N+t);if(typeof r!="object"&&typeof r!="function"||r===null)throw new TypeError(T+r);if(x)try{return x.call(Object,t,n,r)}catch(i){}if(f(r,"value"))if(d&&(h(t,n)||p(t,n))){var s=t.__proto__;t.__proto__=o,delete t[n],t[n]=r.value,t.__proto__=s}else t[n]=r.value;else{if(!d)throw new TypeError(C);f(r,"get")&&l(t,n,r.get),f(r,"set")&&c(t,n,r.set)}return t}}Object.defineProperties||(Object.defineProperties=function(t,n){for(var r in n)f(n,r)&&Object.defineProperty(t,r,n[r]);return t}),Object.seal||(Object.seal=function(t){return t}),Object.freeze||(Object.freeze=function(t){return t});try{Object.freeze(function(){})}catch(k){Object.freeze=function(t){return function(n){return typeof n=="function"?n:t(n)}}(Object.freeze)}Object.preventExtensions||(Object.preventExtensions=function(t){return t}),Object.isSealed||(Object.isSealed=function(t){return!1}),Object.isFrozen||(Object.isFrozen=function(t){return!1}),Object.isExtensible||(Object.isExtensible=function(t){if(Object(t)===t)throw new TypeError;var n="";while(f(t,n))n+="?";t[n]=!0;var r=f(t,n);return delete t[n],r});if(!Object.keys){var L=!0,A=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],O=A.length;for(var M in{toString:null})L=!1;Object.keys=function I(e){if(typeof e!="object"&&typeof e!="function"||e===null)throw new TypeError("Object.keys called on a non-object");var I=[];for(var t in e)f(e,t)&&I.push(t);if(L)for(var n=0,r=O;n<r;n++){var i=A[n];f(e,i)&&I.push(i)}return I}}Date.now||(Date.now=function(){return(new Date).getTime()});var _=" \n\f\r \u00a0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029\ufeff";if(!String.prototype.trim||_.trim()){_="["+_+"]";var D=new RegExp("^"+_+_+"*"),P=new RegExp(_+_+"*$");String.prototype.trim=function(){return String(this).replace(D,"").replace(P,"")}}var F=function(e){if(e==null)throw new TypeError("can't convert "+e+" to object");return Object(e)}}),ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/regexp","ace/lib/es5-shim"],function(e,t,n){"use strict";e("./regexp"),e("./es5-shim")}),ace.define("ace/lib/dom",["require","exports","module"],function(e,t,n){"use strict";var r="http://www.w3.org/1999/xhtml";t.getDocumentHead=function(e){return e||(e=document),e.head||e.getElementsByTagName("head")[0]||e.documentElement},t.createElement=function(e,t){return document.createElementNS?document.createElementNS(t||r,e):document.createElement(e)},t.hasCssClass=function(e,t){var n=(e.className||"").split(/\s+/g);return n.indexOf(t)!==-1},t.addCssClass=function(e,n){t.hasCssClass(e,n)||(e.className+=" "+n)},t.removeCssClass=function(e,t){var n=e.className.split(/\s+/g);for(;;){var r=n.indexOf(t);if(r==-1)break;n.splice(r,1)}e.className=n.join(" ")},t.toggleCssClass=function(e,t){var n=e.className.split(/\s+/g),r=!0;for(;;){var i=n.indexOf(t);if(i==-1)break;r=!1,n.splice(i,1)}return r&&n.push(t),e.className=n.join(" "),r},t.setCssClass=function(e,n,r){r?t.addCssClass(e,n):t.removeCssClass(e,n)},t.hasCssString=function(e,t){var n=0,r;t=t||document;if(t.createStyleSheet&&(r=t.styleSheets)){while(n<r.length)if(r[n++].owningElement.id===e)return!0}else if(r=t.getElementsByTagName("style"))while(n<r.length)if(r[n++].id===e)return!0;return!1},t.importCssString=function(n,i,s){s=s||document;if(i&&t.hasCssString(i,s))return null;var o;s.createStyleSheet?(o=s.createStyleSheet(),o.cssText=n,i&&(o.owningElement.id=i)):(o=s.createElementNS?s.createElementNS(r,"style"):s.createElement("style"),o.appendChild(s.createTextNode(n)),i&&(o.id=i),t.getDocumentHead(s).appendChild(o))},t.importCssStylsheet=function(e,n){if(n.createStyleSheet)n.createStyleSheet(e);else{var r=t.createElement("link");r.rel="stylesheet",r.href=e,t.getDocumentHead(n).appendChild(r)}},t.getInnerWidth=function(e){return parseInt(t.computedStyle(e,"paddingLeft"),10)+parseInt(t.computedStyle(e,"paddingRight"),10)+e.clientWidth},t.getInnerHeight=function(e){return parseInt(t.computedStyle(e,"paddingTop"),10)+parseInt(t.computedStyle(e,"paddingBottom"),10)+e.clientHeight};if(typeof document=="undefined")return;window.pageYOffset!==undefined?(t.getPageScrollTop=function(){return window.pageYOffset},t.getPageScrollLeft=function(){return window.pageXOffset}):(t.getPageScrollTop=function(){return document.body.scrollTop},t.getPageScrollLeft=function(){return document.body.scrollLeft}),window.getComputedStyle?t.computedStyle=function(e,t){return t?(window.getComputedStyle(e,"")||{})[t]||"":window.getComputedStyle(e,"")||{}}:t.computedStyle=function(e,t){return t?e.currentStyle[t]:e.currentStyle},t.scrollbarWidth=function(e){var n=t.createElement("ace_inner");n.style.width="100%",n.style.minWidth="0px",n.style.height="200px",n.style.display="block";var r=t.createElement("ace_outer"),i=r.style;i.position="absolute",i.left="-10000px",i.overflow="hidden",i.width="200px",i.minWidth="0px",i.height="150px",i.display="block",r.appendChild(n);var s=e.documentElement;s.appendChild(r);var o=n.offsetWidth;i.overflow="scroll";var u=n.offsetWidth;return o==u&&(u=r.clientWidth),s.removeChild(r),o-u},t.setInnerHtml=function(e,t){var n=e.cloneNode(!1);return n.innerHTML=t,e.parentNode.replaceChild(n,e),n},"textContent"in document.documentElement?(t.setInnerText=function(e,t){e.textContent=t},t.getInnerText=function(e){return e.textContent}):(t.setInnerText=function(e,t){e.innerText=t},t.getInnerText=function(e){return e.innerText}),t.getParentWindow=function(e){return e.defaultView||e.parentWindow}}),ace.define("ace/lib/oop",["require","exports","module"],function(e,t,n){"use strict";t.inherits=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})},t.mixin=function(e,t){for(var n in t)e[n]=t[n];return e},t.implement=function(e,n){t.mixin(e,n)}}),ace.define("ace/lib/keys",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/oop"],function(e,t,n){"use strict";e("./fixoldbrowsers");var r=e("./oop"),i=function(){var e={MODIFIER_KEYS:{16:"Shift",17:"Ctrl",18:"Alt",224:"Meta"},KEY_MODS:{ctrl:1,alt:2,option:2,shift:4,"super":8,meta:8,command:8,cmd:8},FUNCTION_KEYS:{8:"Backspace",9:"Tab",13:"Return",19:"Pause",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"Print",45:"Insert",46:"Delete",96:"Numpad0",97:"Numpad1",98:"Numpad2",99:"Numpad3",100:"Numpad4",101:"Numpad5",102:"Numpad6",103:"Numpad7",104:"Numpad8",105:"Numpad9","-13":"NumpadEnter",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"Numlock",145:"Scrolllock"},PRINTABLE_KEYS:{32:" ",48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",59:";",61:"=",65:"a",66:"b",67:"c",68:"d",69:"e",70:"f",71:"g",72:"h",73:"i",74:"j",75:"k",76:"l",77:"m",78:"n",79:"o",80:"p",81:"q",82:"r",83:"s",84:"t",85:"u",86:"v",87:"w",88:"x",89:"y",90:"z",107:"+",109:"-",110:".",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"}},t,n;for(n in e.FUNCTION_KEYS)t=e.FUNCTION_KEYS[n].toLowerCase(),e[t]=parseInt(n,10);for(n in e.PRINTABLE_KEYS)t=e.PRINTABLE_KEYS[n].toLowerCase(),e[t]=parseInt(n,10);return r.mixin(e,e.MODIFIER_KEYS),r.mixin(e,e.PRINTABLE_KEYS),r.mixin(e,e.FUNCTION_KEYS),e.enter=e["return"],e.escape=e.esc,e.del=e["delete"],e[173]="-",function(){var t=["cmd","ctrl","alt","shift"];for(var n=Math.pow(2,t.length);n--;)e.KEY_MODS[n]=t.filter(function(t){return n&e.KEY_MODS[t]}).join("-")+"-"}(),e.KEY_MODS[0]="",e.KEY_MODS[-1]="input",e}();r.mixin(t,i),t.keyCodeToString=function(e){var t=i[e];return typeof t!="string"&&(t=String.fromCharCode(e)),t.toLowerCase()}}),ace.define("ace/lib/useragent",["require","exports","module"],function(e,t,n){"use strict";t.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},t.getOS=function(){return t.isMac?t.OS.MAC:t.isLinux?t.OS.LINUX:t.OS.WINDOWS};if(typeof navigator!="object")return;var r=(navigator.platform.match(/mac|win|linux/i)||["other"])[0].toLowerCase(),i=navigator.userAgent;t.isWin=r=="win",t.isMac=r=="mac",t.isLinux=r=="linux",t.isIE=navigator.appName=="Microsoft Internet Explorer"||navigator.appName.indexOf("MSAppHost")>=0?parseFloat((i.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((i.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),t.isOldIE=t.isIE&&t.isIE<9,t.isGecko=t.isMozilla=(window.Controllers||window.controllers)&&window.navigator.product==="Gecko",t.isOldGecko=t.isGecko&&parseInt((i.match(/rv\:(\d+)/)||[])[1],10)<4,t.isOpera=window.opera&&Object.prototype.toString.call(window.opera)=="[object Opera]",t.isWebKit=parseFloat(i.split("WebKit/")[1])||undefined,t.isChrome=parseFloat(i.split(" Chrome/")[1])||undefined,t.isAIR=i.indexOf("AdobeAIR")>=0,t.isIPad=i.indexOf("iPad")>=0,t.isTouchPad=i.indexOf("TouchPad")>=0,t.isChromeOS=i.indexOf(" CrOS ")>=0}),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,t,n){"use strict";function o(e,t,n){var o=s(t);if(!i.isMac&&u){if(u[91]||u[92])o|=8;if(u.altGr){if((3&o)==3)return;u.altGr=0}if(n===18||n===17){var f="location"in t?t.location:t.keyLocation;if(n===17&&f===1)a=t.timeStamp;else if(n===18&&o===3&&f===2){var l=-a;a=t.timeStamp,l+=a,l<3&&(u.altGr=!0)}}}if(n in r.MODIFIER_KEYS){switch(r.MODIFIER_KEYS[n]){case"Alt":o=2;break;case"Shift":o=4;break;case"Ctrl":o=1;break;default:o=8}n=-1}o&8&&(n===91||n===93)&&(n=-1);if(!o&&n===13){var f="location"in t?t.location:t.keyLocation;if(f===3){e(t,o,-n);if(t.defaultPrevented)return}}if(i.isChromeOS&&o&8){e(t,o,n);if(t.defaultPrevented)return;o&=-9}return!!o||n in r.FUNCTION_KEYS||n in r.PRINTABLE_KEYS?e(t,o,n):!1}var r=e("./keys"),i=e("./useragent");t.addListener=function(e,t,n){if(e.addEventListener)return e.addEventListener(t,n,!1);if(e.attachEvent){var r=function(){n.call(e,window.event)};n._wrapper=r,e.attachEvent("on"+t,r)}},t.removeListener=function(e,t,n){if(e.removeEventListener)return e.removeEventListener(t,n,!1);e.detachEvent&&e.detachEvent("on"+t,n._wrapper||n)},t.stopEvent=function(e){return t.stopPropagation(e),t.preventDefault(e),!1},t.stopPropagation=function(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0},t.preventDefault=function(e){e.preventDefault?e.preventDefault():e.returnValue=!1},t.getButton=function(e){return e.type=="dblclick"?0:e.type=="contextmenu"||i.isMac&&e.ctrlKey&&!e.altKey&&!e.shiftKey?2:e.preventDefault?e.button:{1:0,2:2,4:1}[e.button]},t.capture=function(e,n,r){function i(e){n&&n(e),r&&r(e),t.removeListener(document,"mousemove",n,!0),t.removeListener(document,"mouseup",i,!0),t.removeListener(document,"dragstart",i,!0)}return t.addListener(document,"mousemove",n,!0),t.addListener(document,"mouseup",i,!0),t.addListener(document,"dragstart",i,!0),i},t.addMouseWheelListener=function(e,n){"onmousewheel"in e?t.addListener(e,"mousewheel",function(e){var t=8;e.wheelDeltaX!==undefined?(e.wheelX=-e.wheelDeltaX/t,e.wheelY=-e.wheelDeltaY/t):(e.wheelX=0,e.wheelY=-e.wheelDelta/t),n(e)}):"onwheel"in e?t.addListener(e,"wheel",function(e){var t=.35;switch(e.deltaMode){case e.DOM_DELTA_PIXEL:e.wheelX=e.deltaX*t||0,e.wheelY=e.deltaY*t||0;break;case e.DOM_DELTA_LINE:case e.DOM_DELTA_PAGE:e.wheelX=(e.deltaX||0)*5,e.wheelY=(e.deltaY||0)*5}n(e)}):t.addListener(e,"DOMMouseScroll",function(e){e.axis&&e.axis==e.HORIZONTAL_AXIS?(e.wheelX=(e.detail||0)*5,e.wheelY=0):(e.wheelX=0,e.wheelY=(e.detail||0)*5),n(e)})},t.addMultiMouseDownListener=function(e,n,r,s){var o=0,u,a,f,l={2:"dblclick",3:"tripleclick",4:"quadclick"};t.addListener(e,"mousedown",function(e){t.getButton(e)!==0?o=0:e.detail>1?(o++,o>4&&(o=1)):o=1;if(i.isIE){var c=Math.abs(e.clientX-u)>5||Math.abs(e.clientY-a)>5;if(!f||c)o=1;f&&clearTimeout(f),f=setTimeout(function(){f=null},n[o-1]||600),o==1&&(u=e.clientX,a=e.clientY)}e._clicks=o,r[s]("mousedown",e);if(o>4)o=0;else if(o>1)return r[s](l[o],e)}),i.isOldIE&&t.addListener(e,"dblclick",function(e){o=2,f&&clearTimeout(f),f=setTimeout(function(){f=null},n[o-1]||600),r[s]("mousedown",e),r[s](l[o],e)})};var s=!i.isMac||!i.isOpera||"KeyboardEvent"in window?function(e){return 0|(e.ctrlKey?1:0)|(e.altKey?2:0)|(e.shiftKey?4:0)|(e.metaKey?8:0)}:function(e){return 0|(e.metaKey?1:0)|(e.altKey?2:0)|(e.shiftKey?4:0)|(e.ctrlKey?8:0)};t.getModifierString=function(e){return r.KEY_MODS[s(e)]};var u=null,a=0;t.addCommandKeyListener=function(e,n){var r=t.addListener;if(i.isOldGecko||i.isOpera&&!("KeyboardEvent"in window)){var s=null;r(e,"keydown",function(e){s=e.keyCode}),r(e,"keypress",function(e){return o(n,e,s)})}else{var a=null;r(e,"keydown",function(e){u[e.keyCode]=!0;var t=o(n,e,e.keyCode);return a=e.defaultPrevented,t}),r(e,"keypress",function(e){a&&(e.ctrlKey||e.altKey||e.shiftKey||e.metaKey)&&(t.stopEvent(e),a=null)}),r(e,"keyup",function(e){u[e.keyCode]=null}),u||(u=Object.create(null),r(window,"focus",function(e){u=Object.create(null)}))}};if(window.postMessage&&!i.isOldIE){var f=1;t.nextTick=function(e,n){n=n||window;var r="zero-timeout-message-"+f;t.addListener(n,"message",function i(s){s.data==r&&(t.stopPropagation(s),t.removeListener(n,"message",i),e())}),n.postMessage(r,"*")}}t.nextFrame=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame,t.nextFrame?t.nextFrame=t.nextFrame.bind(window):t.nextFrame=function(e){setTimeout(e,17)}}),ace.define("ace/lib/lang",["require","exports","module"],function(e,t,n){"use strict";t.last=function(e){return e[e.length-1]},t.stringReverse=function(e){return e.split("").reverse().join("")},t.stringRepeat=function(e,t){var n="";while(t>0){t&1&&(n+=e);if(t>>=1)e+=e}return n};var r=/^\s\s*/,i=/\s\s*$/;t.stringTrimLeft=function(e){return e.replace(r,"")},t.stringTrimRight=function(e){return e.replace(i,"")},t.copyObject=function(e){var t={};for(var n in e)t[n]=e[n];return t},t.copyArray=function(e){var t=[];for(var n=0,r=e.length;n<r;n++)e[n]&&typeof e[n]=="object"?t[n]=this.copyObject(e[n]):t[n]=e[n];return t},t.deepCopy=function(e){if(typeof e!="object"||!e)return e;var n=e.constructor;if(n===RegExp)return e;var r=n();for(var i in e)typeof e[i]=="object"?r[i]=t.deepCopy(e[i]):r[i]=e[i];return r},t.arrayToMap=function(e){var t={};for(var n=0;n<e.length;n++)t[e[n]]=1;return t},t.createMap=function(e){var t=Object.create(null);for(var n in e)t[n]=e[n];return t},t.arrayRemove=function(e,t){for(var n=0;n<=e.length;n++)t===e[n]&&e.splice(n,1)},t.escapeRegExp=function(e){return e.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},t.escapeHTML=function(e){return e.replace(/&/g,"&#38;").replace(/"/g,"&#34;").replace(/'/g,"&#39;").replace(/</g,"&#60;")},t.getMatchOffsets=function(e,t){var n=[];return e.replace(t,function(e){n.push({offset:arguments[arguments.length-2],length:e.length})}),n},t.deferredCall=function(e){var t=null,n=function(){t=null,e()},r=function(e){return r.cancel(),t=setTimeout(n,e||0),r};return r.schedule=r,r.call=function(){return this.cancel(),e(),r},r.cancel=function(){return clearTimeout(t),t=null,r},r.isPending=function(){return t},r},t.delayedCall=function(e,t){var n=null,r=function(){n=null,e()},i=function(e){n==null&&(n=setTimeout(r,e||t))};return i.delay=function(e){n&&clearTimeout(n),n=setTimeout(r,e||t)},i.schedule=i,i.call=function(){this.cancel(),e()},i.cancel=function(){n&&clearTimeout(n),n=null},i.isPending=function(){return n},i}}),ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/lib/dom","ace/lib/lang"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),s=e("../lib/dom"),o=e("../lib/lang"),u=i.isChrome<18,a=i.isIE,f=function(e,t){function b(e){if(h)return;if(k)t=0,r=e?0:n.value.length-1;else var t=e?2:1,r=2;try{n.setSelectionRange(t,r)}catch(i){}}function w(){if(h)return;n.value=f,i.isWebKit&&y.schedule()}function R(){clearTimeout(q),q=setTimeout(function(){p&&(n.style.cssText=p,p=""),t.renderer.$keepTextAreaAtCursor==null&&(t.renderer.$keepTextAreaAtCursor=!0,t.renderer.$moveTextAreaToCursor())},i.isOldIE?200:0)}var n=s.createElement("textarea");n.className="ace_text-input",i.isTouchPad&&n.setAttribute("x-palm-disable-auto-cap",!0),n.setAttribute("wrap","off"),n.setAttribute("autocorrect","off"),n.setAttribute("autocapitalize","off"),n.setAttribute("spellcheck",!1),n.style.opacity="0",i.isOldIE&&(n.style.top="-100px"),e.insertBefore(n,e.firstChild);var f="",l=!1,c=!1,h=!1,p="",d=!0;try{var v=document.activeElement===n}catch(m){}r.addListener(n,"blur",function(e){t.onBlur(e),v=!1}),r.addListener(n,"focus",function(e){v=!0,t.onFocus(e),b()}),this.focus=function(){n.style.position="fixed",n.style.top="-10000000px",n.focus(),setTimeout(function(){n.style.position=""},0)},this.blur=function(){n.blur()},this.isFocused=function(){return v};var g=o.delayedCall(function(){v&&b(d)}),y=o.delayedCall(function(){h||(n.value=f,v&&b())});i.isWebKit||t.addEventListener("changeSelection",function(){t.selection.isEmpty()!=d&&(d=!d,g.schedule())}),w(),v&&t.onFocus();var E=function(e){return e.selectionStart===0&&e.selectionEnd===e.value.length};!n.setSelectionRange&&n.createTextRange&&(n.setSelectionRange=function(e,t){var n=this.createTextRange();n.collapse(!0),n.moveStart("character",e),n.moveEnd("character",t),n.select()},E=function(e){try{var t=e.ownerDocument.selection.createRange()}catch(n){}return!t||t.parentElement()!=e?!1:t.text==e.value});if(i.isOldIE){var S=!1,x=function(e){if(S)return;var t=n.value;if(h||!t||t==f)return;if(e&&t==f[0])return T.schedule();A(t),S=!0,w(),S=!1},T=o.delayedCall(x);r.addListener(n,"propertychange",x);var N={13:1,27:1};r.addListener(n,"keyup",function(e){h&&(!n.value||N[e.keyCode])&&setTimeout(F,0);if((n.value.charCodeAt(0)||0)<129)return T.call();h?j():B()}),r.addListener(n,"keydown",function(e){T.schedule(50)})}var C=function(e){l?l=!1:E(n)?(t.selectAll(),b()):k&&b(t.selection.isEmpty())},k=null;this.setInputHandler=function(e){k=e},this.getInputHandler=function(){return k};var L=!1,A=function(e){k&&(e=k(e),k=null),c?(b(),e&&t.onPaste(e),c=!1):e==f.charAt(0)?L?t.execCommand("del",{source:"ace"}):t.execCommand("backspace",{source:"ace"}):(e.substring(0,2)==f?e=e.substr(2):e.charAt(0)==f.charAt(0)?e=e.substr(1):e.charAt(e.length-1)==f.charAt(0)&&(e=e.slice(0,-1)),e.charAt(e.length-1)==f.charAt(0)&&(e=e.slice(0,-1)),e&&t.onTextInput(e)),L&&(L=!1)},O=function(e){if(h)return;var t=n.value;A(t),w()},M=function(e,t){var n=e.clipboardData||window.clipboardData;if(!n||u)return;var r=a?"Text":"text/plain";return t?n.setData(r,t)!==!1:n.getData(r)},_=function(e,i){var s=t.getCopyText();if(!s)return r.preventDefault(e);M(e,s)?(i?t.onCut():t.onCopy(),r.preventDefault(e)):(l=!0,n.value=s,n.select(),setTimeout(function(){l=!1,w(),b(),i?t.onCut():t.onCopy()}))},D=function(e){_(e,!0)},P=function(e){_(e,!1)},H=function(e){var s=M(e);typeof s=="string"?(s&&t.onPaste(s),i.isIE&&setTimeout(b),r.preventDefault(e)):(n.value="",c=!0)};r.addCommandKeyListener(n,t.onCommandKey.bind(t)),r.addListener(n,"select",C),r.addListener(n,"input",O),r.addListener(n,"cut",D),r.addListener(n,"copy",P),r.addListener(n,"paste",H),(!("oncut"in n)||!("oncopy"in n)||!("onpaste"in n))&&r.addListener(e,"keydown",function(e){if(i.isMac&&!e.metaKey||!e.ctrlKey)return;switch(e.keyCode){case 67:P(e);break;case 86:H(e);break;case 88:D(e)}});var B=function(e){if(h||!t.onCompositionStart||t.$readOnly)return;h={},t.onCompositionStart(),setTimeout(j,0),t.on("mousedown",F),t.selection.isEmpty()||(t.insert(""),t.session.markUndoGroup(),t.selection.clearSelection()),t.session.markUndoGroup()},j=function(){if(!h||!t.onCompositionUpdate||t.$readOnly)return;var e=n.value.replace(/\x01/g,"");if(h.lastValue===e)return;t.onCompositionUpdate(e),h.lastValue&&t.undo(),h.lastValue=e;if(h.lastValue){var r=t.selection.getRange();t.insert(h.lastValue),t.session.markUndoGroup(),h.range=t.selection.getRange(),t.selection.setRange(r),t.selection.clearSelection()}},F=function(e){if(!t.onCompositionEnd||t.$readOnly)return;var r=h;h=!1;var i=setTimeout(function(){i=null;var e=n.value.replace(/\x01/g,"");if(h)return;e==r.lastValue?w():!r.lastValue&&e&&(w(),A(e))});k=function(n){return i&&clearTimeout(i),n=n.replace(/\x01/g,""),n==r.lastValue?"":(r.lastValue&&i&&t.undo(),n)},t.onCompositionEnd(),t.removeListener("mousedown",F),e.type=="compositionend"&&r.range&&t.selection.setRange(r.range)},I=o.delayedCall(j,50);r.addListener(n,"compositionstart",B),i.isGecko?r.addListener(n,"text",function(){I.schedule()}):(r.addListener(n,"keyup",function(){I.schedule()}),r.addListener(n,"keydown",function(){I.schedule()})),r.addListener(n,"compositionend",F),this.getElement=function(){return n},this.setReadOnly=function(e){n.readOnly=e},this.onContextMenu=function(e){L=!0,b(t.selection.isEmpty()),t._emit("nativecontextmenu",{target:t,domEvent:e}),this.moveToMouse(e,!0)},this.moveToMouse=function(e,o){if(!o&&i.isOldIE)return;p||(p=n.style.cssText),n.style.cssText=(o?"z-index:100000;":"")+"height:"+n.style.height+";"+(i.isIE?"opacity:0.1;":"");var u=t.container.getBoundingClientRect(),a=s.computedStyle(t.container),f=u.top+(parseInt(a.borderTopWidth)||0),l=u.left+(parseInt(u.borderLeftWidth)||0),c=u.bottom-f-n.clientHeight-2,h=function(e){n.style.left=e.clientX-l-2+"px",n.style.top=Math.min(e.clientY-f-2,c)+"px"};h(e);if(e.type!="mousedown")return;t.renderer.$keepTextAreaAtCursor&&(t.renderer.$keepTextAreaAtCursor=null),i.isWin&&!i.isOldIE&&r.capture(t.container,h,R)},this.onContextMenuClose=R;var q,U=function(e){t.textInput.onContextMenu(e),R()};r.addListener(t.renderer.scroller,"contextmenu",U),r.addListener(n,"contextmenu",U)};t.TextInput=f}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";function u(e){e.$clickSelection=null;var t=e.editor;t.setDefaultHandler("mousedown",this.onMouseDown.bind(e)),t.setDefaultHandler("dblclick",this.onDoubleClick.bind(e)),t.setDefaultHandler("tripleclick",this.onTripleClick.bind(e)),t.setDefaultHandler("quadclick",this.onQuadClick.bind(e)),t.setDefaultHandler("mousewheel",this.onMouseWheel.bind(e));var n=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];n.forEach(function(t){e[t]=this[t]},this),e.selectByLines=this.extendSelectionBy.bind(e,"getLineRange"),e.selectByWords=this.extendSelectionBy.bind(e,"getWordRange")}function a(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}function f(e,t){if(e.start.row==e.end.row)var n=2*t.column-e.start.column-e.end.column;else if(e.start.row==e.end.row-1&&!e.start.column&&!e.end.column)var n=t.column-4;else var n=2*t.row-e.start.row-e.end.row;return n<0?{cursor:e.start,anchor:e.end}:{cursor:e.end,anchor:e.start}}var r=e("../lib/dom"),i=e("../lib/event"),s=e("../lib/useragent"),o=0;(function(){this.onMouseDown=function(e){var t=e.inSelection(),n=e.getDocumentPosition();this.mousedownEvent=e;var r=this.editor,i=e.getButton();if(i!==0){var s=r.getSelectionRange(),o=s.isEmpty();r.$blockScrolling++,o&&r.selection.moveToPosition(n),r.$blockScrolling--,r.textInput.onContextMenu(e.domEvent);return}this.mousedownEvent.time=Date.now();if(t&&!r.isFocused()){r.focus();if(this.$focusTimout&&!this.$clickSelection&&!r.inMultiSelectMode){this.setState("focusWait"),this.captureMouse(e);return}}return this.captureMouse(e),this.startSelect(n,e.domEvent._clicks>1),e.preventDefault()},this.startSelect=function(e,t){e=e||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var n=this.editor;n.$blockScrolling++,this.mousedownEvent.getShiftKey()?n.selection.selectToPosition(e):t||n.selection.moveToPosition(e),t||this.select(),n.renderer.scroller.setCapture&&n.renderer.scroller.setCapture(),n.setStyle("ace_selecting"),this.setState("select"),n.$blockScrolling--},this.select=function(){var e,t=this.editor,n=t.renderer.screenToTextCoordinates(this.x,this.y);t.$blockScrolling++;if(this.$clickSelection){var r=this.$clickSelection.comparePoint(n);if(r==-1)e=this.$clickSelection.end;else if(r==1)e=this.$clickSelection.start;else{var i=f(this.$clickSelection,n);n=i.cursor,e=i.anchor}t.selection.setSelectionAnchor(e.row,e.column)}t.selection.selectToPosition(n),t.$blockScrolling--,t.renderer.scrollCursorIntoView()},this.extendSelectionBy=function(e){var t,n=this.editor,r=n.renderer.screenToTextCoordinates(this.x,this.y),i=n.selection[e](r.row,r.column);n.$blockScrolling++;if(this.$clickSelection){var s=this.$clickSelection.comparePoint(i.start),o=this.$clickSelection.comparePoint(i.end);if(s==-1&&o<=0){t=this.$clickSelection.end;if(i.end.row!=r.row||i.end.column!=r.column)r=i.start}else if(o==1&&s>=0){t=this.$clickSelection.start;if(i.start.row!=r.row||i.start.column!=r.column)r=i.end}else if(s==-1&&o==1)r=i.end,t=i.start;else{var u=f(this.$clickSelection,r);r=u.cursor,t=u.anchor}n.selection.setSelectionAnchor(t.row,t.column)}n.selection.selectToPosition(r),n.$blockScrolling--,n.renderer.scrollCursorIntoView()},this.selectEnd=this.selectAllEnd=this.selectByWordsEnd=this.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting"),this.editor.renderer.scroller.releaseCapture&&this.editor.renderer.scroller.releaseCapture()},this.focusWait=function(){var e=a(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),t=Date.now();(e>o||t-this.mousedownEvent.time>this.$focusTimout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},this.onDoubleClick=function(e){var t=e.getDocumentPosition(),n=this.editor,r=n.session,i=r.getBracketRange(t);i?(i.isEmpty()&&(i.start.column--,i.end.column++),this.setState("select")):(i=n.selection.getWordRange(t.row,t.column),this.setState("selectByWords")),this.$clickSelection=i,this.select()},this.onTripleClick=function(e){var t=e.getDocumentPosition(),n=this.editor;this.setState("selectByLines");var r=n.getSelectionRange();r.isMultiLine()&&r.contains(t.row,t.column)?(this.$clickSelection=n.selection.getLineRange(r.start.row),this.$clickSelection.end=n.selection.getLineRange(r.end.row).end):this.$clickSelection=n.selection.getLineRange(t.row),this.select()},this.onQuadClick=function(e){var t=this.editor;t.selectAll(),this.$clickSelection=t.getSelectionRange(),this.setState("selectAll")},this.onMouseWheel=function(e){if(e.getAccelKey())return;e.getShiftKey()&&e.wheelY&&!e.wheelX&&(e.wheelX=e.wheelY,e.wheelY=0);var t=e.domEvent.timeStamp,n=t-(this.$lastScrollTime||0),r=this.editor,i=r.renderer.isScrollableBy(e.wheelX*e.speed,e.wheelY*e.speed);if(i||n<200)return this.$lastScrollTime=t,r.renderer.scrollBy(e.wheelX*e.speed,e.wheelY*e.speed),e.stop()}}).call(u.prototype),t.DefaultHandlers=u}),ace.define("ace/tooltip",["require","exports","module","ace/lib/oop","ace/lib/dom"],function(e,t,n){"use strict";function s(e){this.isOpen=!1,this.$element=null,this.$parentNode=e}var r=e("./lib/oop"),i=e("./lib/dom");(function(){this.$init=function(){return this.$element=i.createElement("div"),this.$element.className="ace_tooltip",this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},this.getElement=function(){return this.$element||this.$init()},this.setText=function(e){i.setInnerText(this.getElement(),e)},this.setHtml=function(e){this.getElement().innerHTML=e},this.setPosition=function(e,t){this.getElement().style.left=e+"px",this.getElement().style.top=t+"px"},this.setClassName=function(e){i.addCssClass(this.getElement(),e)},this.show=function(e,t,n){e!=null&&this.setText(e),t!=null&&n!=null&&this.setPosition(t,n),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},this.hide=function(){this.isOpen&&(this.getElement().style.display="none",this.isOpen=!1)},this.getHeight=function(){return this.getElement().offsetHeight},this.getWidth=function(){return this.getElement().offsetWidth}}).call(s.prototype),t.Tooltip=s}),ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event","ace/tooltip"],function(e,t,n){"use strict";function u(e){function l(){var r=u.getDocumentPosition().row,s=n.$annotations[r];if(!s)return c();var o=t.session.getLength();if(r==o){var a=t.renderer.pixelToScreenCoordinates(0,u.y).row,l=u.$pos;if(a>t.session.documentToScreenRow(l.row,l.column))return c()}if(f==s)return;f=s.text.join("<br/>"),i.setHtml(f),i.show(),t.on("mousewheel",c);if(e.$tooltipFollowsMouse)h(u);else{var p=n.$cells[t.session.documentToScreenRow(r,0)].element,d=p.getBoundingClientRect(),v=i.getElement().style;v.left=d.right+"px",v.top=d.bottom+"px"}}function c(){o&&(o=clearTimeout(o)),f&&(i.hide(),f=null,t.removeEventListener("mousewheel",c))}function h(e){i.setPosition(e.x,e.y)}var t=e.editor,n=t.renderer.$gutterLayer,i=new a(t.container);e.editor.setDefaultHandler("guttermousedown",function(r){if(!t.isFocused()||r.getButton()!=0)return;var i=n.getRegion(r);if(i=="foldWidgets")return;var s=r.getDocumentPosition().row,o=t.session.selection;if(r.getShiftKey())o.selectTo(s,0);else{if(r.domEvent.detail==2)return t.selectAll(),r.preventDefault();e.$clickSelection=t.selection.getLineRange(s)}return e.setState("selectByLines"),e.captureMouse(r),r.preventDefault()});var o,u,f;e.editor.setDefaultHandler("guttermousemove",function(t){var n=t.domEvent.target||t.domEvent.srcElement;if(r.hasCssClass(n,"ace_fold-widget"))return c();f&&e.$tooltipFollowsMouse&&h(t),u=t;if(o)return;o=setTimeout(function(){o=null,u&&!e.isMousePressed?l():c()},50)}),s.addListener(t.renderer.$gutter,"mouseout",function(e){u=null;if(!f||o)return;o=setTimeout(function(){o=null,c()},50)}),t.on("changeSession",c)}function a(e){o.call(this,e)}var r=e("../lib/dom"),i=e("../lib/oop"),s=e("../lib/event"),o=e("../tooltip").Tooltip;i.inherits(a,o),function(){this.setPosition=function(e,t){var n=window.innerWidth||document.documentElement.clientWidth,r=window.innerHeight||document.documentElement.clientHeight,i=this.getWidth(),s=this.getHeight();e+=15,t+=15,e+i>n&&(e-=e+i-n),t+s>r&&(t-=20+s),o.prototype.setPosition.call(this,e,t)}}.call(a.prototype),t.GutterHandler=u}),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),s=t.MouseEvent=function(e,t){this.domEvent=e,this.editor=t,this.x=this.clientX=e.clientX,this.y=this.clientY=e.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1};(function(){this.stopPropagation=function(){r.stopPropagation(this.domEvent),this.propagationStopped=!0},this.preventDefault=function(){r.preventDefault(this.domEvent),this.defaultPrevented=!0},this.stop=function(){this.stopPropagation(),this.preventDefault()},this.getDocumentPosition=function(){return this.$pos?this.$pos:(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY),this.$pos)},this.inSelection=function(){if(this.$inSelection!==null)return this.$inSelection;var e=this.editor,t=e.getSelectionRange();if(t.isEmpty())this.$inSelection=!1;else{var n=this.getDocumentPosition();this.$inSelection=t.contains(n.row,n.column)}return this.$inSelection},this.getButton=function(){return r.getButton(this.domEvent)},this.getShiftKey=function(){return this.domEvent.shiftKey},this.getAccelKey=i.isMac?function(){return this.domEvent.metaKey}:function(){return this.domEvent.ctrlKey}}).call(s.prototype)}),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";function f(e){function T(e,n){var r=Date.now(),i=!n||e.row!=n.row,s=!n||e.column!=n.column;if(!S||i||s)t.$blockScrolling+=1,t.moveCursorToPosition(e),t.$blockScrolling-=1,S=r,x={x:p,y:d};else{var o=l(x.x,x.y,p,d);o>a?S=null:r-S>=u&&(t.renderer.scrollCursorIntoView(),S=null)}}function N(e,n){var r=Date.now(),i=t.renderer.layerConfig.lineHeight,s=t.renderer.layerConfig.characterWidth,u=t.renderer.scroller.getBoundingClientRect(),a={x:{left:p-u.left,right:u.right-p},y:{top:d-u.top,bottom:u.bottom-d}},f=Math.min(a.x.left,a.x.right),l=Math.min(a.y.top,a.y.bottom),c={row:e.row,column:e.column};f/s<=2&&(c.column+=a.x.left<a.x.right?-3:2),l/i<=1&&(c.row+=a.y.top<a.y.bottom?-1:1);var h=e.row!=c.row,v=e.column!=c.column,m=!n||e.row!=n.row;h||v&&!m?E?r-E>=o&&t.renderer.scrollCursorIntoView(c):E=r:E=null}function C(){var e=g;g=t.renderer.screenToTextCoordinates(p,d),T(g,e),N(g,e)}function k(){m=t.selection.toOrientedRange(),h=t.session.addMarker(m,"ace_selection",t.getSelectionStyle()),t.clearSelection(),t.isFocused()&&t.renderer.$cursorLayer.setBlinking(!1),clearInterval(v),C(),v=setInterval(C,20),y=0,i.addListener(document,"mousemove",O)}function L(){clearInterval(v),t.session.removeMarker(h),h=null,t.$blockScrolling+=1,t.selection.fromOrientedRange(m),t.$blockScrolling-=1,t.isFocused()&&!w&&t.renderer.$cursorLayer.setBlinking(!t.getReadOnly()),m=null,g=null,y=0,E=null,S=null,i.removeListener(document,"mousemove",O)}function O(){A==null&&(A=setTimeout(function(){A!=null&&h&&L()},20))}function M(e){var t=e.types;return!t||Array.prototype.some.call(t,function(e){return e=="text/plain"||e=="Text"})}function _(e){var t=["copy","copymove","all","uninitialized"],n=["move","copymove","linkmove","all","uninitialized"],r=s.isMac?e.altKey:e.ctrlKey,i="uninitialized";try{i=e.dataTransfer.effectAllowed.toLowerCase()}catch(e){}var o="none";return r&&t.indexOf(i)>=0?o="copy":n.indexOf(i)>=0?o="move":t.indexOf(i)>=0&&(o="copy"),o}var t=e.editor,n=r.createElement("img");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",s.isOpera&&(n.style.cssText="width:1px;height:1px;position:fixed;top:0;left:0;z-index:2147483647;opacity:0;");var f=["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"];f.forEach(function(t){e[t]=this[t]},this),t.addEventListener("mousedown",this.onMouseDown.bind(e));var c=t.container,h,p,d,v,m,g,y=0,b,w,E,S,x;this.onDragStart=function(e){if(this.cancelDrag||!c.draggable){var r=this;return setTimeout(function(){r.startSelect(),r.captureMouse(e)},0),e.preventDefault()}m=t.getSelectionRange();var i=e.dataTransfer;i.effectAllowed=t.getReadOnly()?"copy":"copyMove",s.isOpera&&(t.container.appendChild(n),n.scrollTop=0),i.setDragImage&&i.setDragImage(n,0,0),s.isOpera&&t.container.removeChild(n),i.clearData(),i.setData("Text",t.session.getTextRange()),w=!0,this.setState("drag")},this.onDragEnd=function(e){c.draggable=!1,w=!1,this.setState(null);if(!t.getReadOnly()){var n=e.dataTransfer.dropEffect;!b&&n=="move"&&t.session.remove(t.getSelectionRange()),t.renderer.$cursorLayer.setBlinking(!0)}this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(e){if(t.getReadOnly()||!M(e.dataTransfer))return;return p=e.clientX,d=e.clientY,h||k(),y++,e.dataTransfer.dropEffect=b=_(e),i.preventDefault(e)},this.onDragOver=function(e){if(t.getReadOnly()||!M(e.dataTransfer))return;return p=e.clientX,d=e.clientY,h||(k(),y++),A!==null&&(A=null),e.dataTransfer.dropEffect=b=_(e),i.preventDefault(e)},this.onDragLeave=function(e){y--;if(y<=0&&h)return L(),b=null,i.preventDefault(e)},this.onDrop=function(e){if(!g)return;var n=e.dataTransfer;if(w)switch(b){case"move":m.contains(g.row,g.column)?m={start:g,end:g}:m=t.moveText(m,g);break;case"copy":m=t.moveText(m,g,!0)}else{var r=n.getData("Text");m={start:g,end:t.session.insert(g,r)},t.focus(),b=null}return L(),i.preventDefault(e)},i.addListener(c,"dragstart",this.onDragStart.bind(e)),i.addListener(c,"dragend",this.onDragEnd.bind(e)),i.addListener(c,"dragenter",this.onDragEnter.bind(e)),i.addListener(c,"dragover",this.onDragOver.bind(e)),i.addListener(c,"dragleave",this.onDragLeave.bind(e)),i.addListener(c,"drop",this.onDrop.bind(e));var A=null}function l(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}var r=e("../lib/dom"),i=e("../lib/event"),s=e("../lib/useragent"),o=200,u=200,a=5;(function(){this.dragWait=function(){var e=Date.now()-this.mousedownEvent.time;e>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var e=this.editor.container;e.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(e){this.editor.renderer.$cursorLayer.setBlinking(!this.editor.getReadOnly()),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var e=this.editor,t=e.container;t.draggable=!0,e.renderer.$cursorLayer.setBlinking(!1),e.setStyle("ace_dragging");var n=s.isWin?"default":"move";e.renderer.setCursorStyle(n),this.setState("dragReady")},this.onMouseDrag=function(e){var t=this.editor.container;if(s.isIE&&this.state=="dragReady"){var n=l(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>3&&t.dragDrop()}if(this.state==="dragWait"){var n=l(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>0&&(t.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(e){if(!this.$dragEnabled)return;this.mousedownEvent=e;var t=this.editor,n=e.inSelection(),r=e.getButton(),i=e.domEvent.detail||1;if(i===1&&r===0&&n){if(e.editor.inMultiSelectMode&&(e.getAccelKey()||e.getShiftKey()))return;this.mousedownEvent.time=Date.now();var o=e.domEvent.target||e.domEvent.srcElement;"unselectable"in o&&(o.unselectable="on");if(t.getDragDelay()){if(s.isWebKit){this.cancelDrag=!0;var u=t.container;u.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(e,this.onMouseDrag.bind(this)),e.defaultPrevented=!0}}}).call(f.prototype),t.DragdropHandler=f}),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("./dom");t.get=function(e,t){var n=new XMLHttpRequest;n.open("GET",e,!0),n.onreadystatechange=function(){n.readyState===4&&t(n.responseText)},n.send(null)},t.loadScript=function(e,t){var n=r.getDocumentHead(),i=document.createElement("script");i.src=e,n.appendChild(i),i.onload=i.onreadystatechange=function(e,n){if(n||!i.readyState||i.readyState=="loaded"||i.readyState=="complete")i=i.onload=i.onreadystatechange=null,n||t()}},t.qualifyURL=function(e){var t=document.createElement("a");return t.href=e,t.href}}),ace.define("ace/lib/event_emitter",["require","exports","module"],function(e,t,n){"use strict";var r={},i=function(){this.propagationStopped=!0},s=function(){this.defaultPrevented=!0};r._emit=r._dispatchEvent=function(e,t){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var n=this._eventRegistry[e]||[],r=this._defaultHandlers[e];if(!n.length&&!r)return;if(typeof t!="object"||!t)t={};t.type||(t.type=e),t.stopPropagation||(t.stopPropagation=i),t.preventDefault||(t.preventDefault=s),n=n.slice();for(var o=0;o<n.length;o++){n[o](t,this);if(t.propagationStopped)break}if(r&&!t.defaultPrevented)return r(t,this)},r._signal=function(e,t){var n=(this._eventRegistry||{})[e];if(!n)return;n=n.slice();for(var r=0;r<n.length;r++)n[r](t,this)},r.once=function(e,t){var n=this;t&&this.addEventListener(e,function r(){n.removeEventListener(e,r),t.apply(null,arguments)})},r.setDefaultHandler=function(e,t){var n=this._defaultHandlers;n||(n=this._defaultHandlers={_disabled_:{}});if(n[e]){var r=n[e],i=n._disabled_[e];i||(n._disabled_[e]=i=[]),i.push(r);var s=i.indexOf(t);s!=-1&&i.splice(s,1)}n[e]=t},r.removeDefaultHandler=function(e,t){var n=this._defaultHandlers;if(!n)return;var r=n._disabled_[e];if(n[e]==t){var i=n[e];r&&this.setDefaultHandler(e,r.pop())}else if(r){var s=r.indexOf(t);s!=-1&&r.splice(s,1)}},r.on=r.addEventListener=function(e,t,n){this._eventRegistry=this._eventRegistry||{};var r=this._eventRegistry[e];return r||(r=this._eventRegistry[e]=[]),r.indexOf(t)==-1&&r[n?"unshift":"push"](t),t},r.off=r.removeListener=r.removeEventListener=function(e,t){this._eventRegistry=this._eventRegistry||{};var n=this._eventRegistry[e];if(!n)return;var r=n.indexOf(t);r!==-1&&n.splice(r,1)},r.removeAllListeners=function(e){this._eventRegistry&&(this._eventRegistry[e]=[])},t.EventEmitter=r}),ace.define("ace/lib/app_config",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,t,n){"no use strict";function o(e){typeof console!="undefined"&&console.warn&&console.warn.apply(console,arguments)}function u(e,t){var n=new Error(e);n.data=t,typeof console=="object"&&console.error&&console.error(n),setTimeout(function(){throw n})}var r=e("./oop"),i=e("./event_emitter").EventEmitter,s={setOptions:function(e){Object.keys(e).forEach(function(t){this.setOption(t,e[t])},this)},getOptions:function(e){var t={};return e?Array.isArray(e)||(t=e,e=Object.keys(t)):e=Object.keys(this.$options),e.forEach(function(e){t[e]=this.getOption(e)},this),t},setOption:function(e,t){if(this["$"+e]===t)return;var n=this.$options[e];if(!n)return o('misspelled option "'+e+'"');if(n.forwardTo)return this[n.forwardTo]&&this[n.forwardTo].setOption(e,t);n.handlesSet||(this["$"+e]=t),n&&n.set&&n.set.call(this,t)},getOption:function(e){var t=this.$options[e];return t?t.forwardTo?this[t.forwardTo]&&this[t.forwardTo].getOption(e):t&&t.get?t.get.call(this):this["$"+e]:o('misspelled option "'+e+'"')}},a=function(){this.$defaultOptions={}};(function(){r.implement(this,i),this.defineOptions=function(e,t,n){return e.$options||(this.$defaultOptions[t]=e.$options={}),Object.keys(n).forEach(function(t){var r=n[t];typeof r=="string"&&(r={forwardTo:r}),r.name||(r.name=t),e.$options[r.name]=r,"initialValue"in r&&(e["$"+r.name]=r.initialValue)}),r.implement(e,s),this},this.resetOptions=function(e){Object.keys(e.$options).forEach(function(t){var n=e.$options[t];"value"in n&&e.setOption(t,n.value)})},this.setDefaultValue=function(e,t,n){var r=this.$defaultOptions[e]||(this.$defaultOptions[e]={});r[t]&&(r.forwardTo?this.setDefaultValue(r.forwardTo,t,n):r[t].value=n)},this.setDefaultValues=function(e,t){Object.keys(t).forEach(function(n){this.setDefaultValue(e,n,t[n])},this)},this.warn=o,this.reportError=u}).call(a.prototype),t.AppConfig=a}),ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/lib/net","ace/lib/app_config"],function(e,t,n){"no use strict";function f(r){a.packaged=r||e.packaged||n.packaged||u.define&&define.packaged;if(!u.document)return"";var i={},s="",o=document.currentScript||document._currentScript,f=o&&o.ownerDocument||document,c=f.getElementsByTagName("script");for(var h=0;h<c.length;h++){var p=c[h],d=p.src||p.getAttribute("src");if(!d)continue;var v=p.attributes;for(var m=0,g=v.length;m<g;m++){var y=v[m];y.name.indexOf("data-ace-")===0&&(i[l(y.name.replace(/^data-ace-/,""))]=y.value)}var b=d.match(/^(.*)\/ace(\-\w+)?\.js(\?|$)/);b&&(s=b[1])}s&&(i.base=i.base||s,i.packaged=!0),i.basePath=i.base,i.workerPath=i.workerPath||i.base,i.modePath=i.modePath||i.base,i.themePath=i.themePath||i.base,delete i.base;for(var w in i)typeof i[w]!="undefined"&&t.set(w,i[w])}function l(e){return e.replace(/-(.)/g,function(e,t){return t.toUpperCase()})}var r=e("./lib/lang"),i=e("./lib/oop"),s=e("./lib/net"),o=e("./lib/app_config").AppConfig;n.exports=t=new o;var u=function(){return this}(),a={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{}};t.get=function(e){if(!a.hasOwnProperty(e))throw new Error("Unknown config key: "+e);return a[e]},t.set=function(e,t){if(!a.hasOwnProperty(e))throw new Error("Unknown config key: "+e);a[e]=t},t.all=function(){return r.copyObject(a)},t.moduleUrl=function(e,t){if(a.$moduleUrls[e])return a.$moduleUrls[e];var n=e.split("/");t=t||n[n.length-2]||"";var r=t=="snippets"?"/":"-",i=n[n.length-1];if(t=="worker"&&r=="-"){var s=new RegExp("^"+t+"[\\-_]|[\\-_]"+t+"$","g");i=i.replace(s,"")}(!i||i==t)&&n.length>1&&(i=n[n.length-2]);var o=a[t+"Path"];return o==null?o=a.basePath:r=="/"&&(t=r=""),o&&o.slice(-1)!="/"&&(o+="/"),o+t+r+i+this.get("suffix")},t.setModuleUrl=function(e,t){return a.$moduleUrls[e]=t},t.$loading={},t.loadModule=function(n,r){var i,o;Array.isArray(n)&&(o=n[0],n=n[1]);try{i=e(n)}catch(u){}if(i&&!t.$loading[n])return r&&r(i);t.$loading[n]||(t.$loading[n]=[]),t.$loading[n].push(r);if(t.$loading[n].length>1)return;var a=function(){e([n],function(e){t._emit("load.module",{name:n,module:e});var r=t.$loading[n];t.$loading[n]=null,r.forEach(function(t){t&&t(e)})})};if(!t.get("packaged"))return a();s.loadScript(t.moduleUrl(n,o),a)},t.init=f}),ace.define("ace/mouse/mouse_handler",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/mouse/default_handlers","ace/mouse/default_gutter_handler","ace/mouse/mouse_event","ace/mouse/dragdrop_handler","ace/config"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),s=e("./default_handlers").DefaultHandlers,o=e("./default_gutter_handler").GutterHandler,u=e("./mouse_event").MouseEvent,a=e("./dragdrop_handler").DragdropHandler,f=e("../config"),l=function(e){var t=this;this.editor=e,new s(this),new o(this),new a(this);var n=function(t){(!document.hasFocus||!document.hasFocus())&&window.focus(),e.focus()},u=e.renderer.getMouseEventTarget();r.addListener(u,"click",this.onMouseEvent.bind(this,"click")),r.addListener(u,"mousemove",this.onMouseMove.bind(this,"mousemove")),r.addMultiMouseDownListener(u,[400,300,250],this,"onMouseEvent"),e.renderer.scrollBarV&&(r.addMultiMouseDownListener(e.renderer.scrollBarV.inner,[400,300,250],this,"onMouseEvent"),r.addMultiMouseDownListener(e.renderer.scrollBarH.inner,[400,300,250],this,"onMouseEvent"),i.isIE&&(r.addListener(e.renderer.scrollBarV.element,"mousedown",n),r.addListener(e.renderer.scrollBarH.element,"mousedown",n))),r.addMouseWheelListener(e.container,this.onMouseWheel.bind(this,"mousewheel"));var f=e.renderer.$gutter;r.addListener(f,"mousedown",this.onMouseEvent.bind(this,"guttermousedown")),r.addListener(f,"click",this.onMouseEvent.bind(this,"gutterclick")),r.addListener(f,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick")),r.addListener(f,"mousemove",this.onMouseEvent.bind(this,"guttermousemove")),r.addListener(u,"mousedown",n),r.addListener(f,"mousedown",function(t){return e.focus(),r.preventDefault(t)}),e.on("mousemove",function(n){if(t.state||t.$dragDelay||!t.$dragEnabled)return;var r=e.renderer.screenToTextCoordinates(n.x,n.y),i=e.session.selection.getRange(),s=e.renderer;!i.isEmpty()&&i.insideStart(r.row,r.column)?s.setCursorStyle("default"):s.setCursorStyle("")})};(function(){this.onMouseEvent=function(e,t){this.editor._emit(e,new u(t,this.editor))},this.onMouseMove=function(e,t){var n=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;if(!n||!n.length)return;this.editor._emit(e,new u(t,this.editor))},this.onMouseWheel=function(e,t){var n=new u(t,this.editor);n.speed=this.$scrollSpeed*2,n.wheelX=t.wheelX,n.wheelY=t.wheelY,this.editor._emit(e,n)},this.setState=function(e){this.state=e},this.captureMouse=function(e,t){this.x=e.x,this.y=e.y,this.isMousePressed=!0;var n=this.editor.renderer;n.$keepTextAreaAtCursor&&(n.$keepTextAreaAtCursor=null);var s=this,o=function(e){if(!e)return;if(i.isWebKit&&!e.which&&s.releaseMouse)return s.releaseMouse();s.x=e.clientX,s.y=e.clientY,t&&t(e),s.mouseEvent=new u(e,s.editor),s.$mouseMoved=!0},a=function(e){clearInterval(l),f(),s[s.state+"End"]&&s[s.state+"End"](e),s.state="",n.$keepTextAreaAtCursor==null&&(n.$keepTextAreaAtCursor=!0,n.$moveTextAreaToCursor()),s.isMousePressed=!1,s.$onCaptureMouseMove=s.releaseMouse=null,e&&s.onMouseEvent("mouseup",e)},f=function(){s[s.state]&&s[s.state](),s.$mouseMoved=!1};if(i.isOldIE&&e.domEvent.type=="dblclick")return setTimeout(function(){a(e)});s.$onCaptureMouseMove=o,s.releaseMouse=r.capture(this.editor.container,o,a);var l=setInterval(f,20)},this.releaseMouse=null,this.cancelContextMenu=function(){var e=function(t){if(t&&t.domEvent&&t.domEvent.type!="contextmenu")return;this.editor.off("nativecontextmenu",e),t&&t.domEvent&&r.stopEvent(t.domEvent)}.bind(this);setTimeout(e,10),this.editor.on("nativecontextmenu",e)}}).call(l.prototype),f.defineOptions(l.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:i.isMac?150:0},dragEnabled:{initialValue:!0},focusTimout:{initialValue:0},tooltipFollowsMouse:{initialValue:!0}}),t.MouseHandler=l}),ace.define("ace/mouse/fold_handler",["require","exports","module"],function(e,t,n){"use strict";function r(e){e.on("click",function(t){var n=t.getDocumentPosition(),r=e.session,i=r.getFoldAt(n.row,n.column,1);i&&(t.getAccelKey()?r.removeFold(i):r.expandFold(i),t.stop())}),e.on("gutterclick",function(t){var n=e.renderer.$gutterLayer.getRegion(t);if(n=="foldWidgets"){var r=t.getDocumentPosition().row,i=e.session;i.foldWidgets&&i.foldWidgets[r]&&e.session.onFoldWidgetClick(r,t),e.isFocused()||e.focus(),t.stop()}}),e.on("gutterdblclick",function(t){var n=e.renderer.$gutterLayer.getRegion(t);if(n=="foldWidgets"){var r=t.getDocumentPosition().row,i=e.session,s=i.getParentFoldRangeData(r,!0),o=s.range||s.firstRange;if(o){r=o.start.row;var u=i.getFoldAt(r,i.getLine(r).length,1);u?i.removeFold(u):(i.addFold("...",o),e.renderer.scrollCursorIntoView({row:o.start.row,column:0}))}t.stop()}})}t.FoldHandler=r}),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],function(e,t,n){"use strict";var r=e("../lib/keys"),i=e("../lib/event"),s=function(e){this.$editor=e,this.$data={editor:e},this.$handlers=[],this.setDefaultHandler(e.commands)};(function(){this.setDefaultHandler=function(e){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=e,this.addKeyboardHandler(e,0)},this.setKeyboardHandler=function(e){var t=this.$handlers;if(t[t.length-1]==e)return;while(t[t.length-1]&&t[t.length-1]!=this.$defaultHandler)this.removeKeyboardHandler(t[t.length-1]);this.addKeyboardHandler(e,1)},this.addKeyboardHandler=function(e,t){if(!e)return;typeof e=="function"&&!e.handleKeyboard&&(e.handleKeyboard=e);var n=this.$handlers.indexOf(e);n!=-1&&this.$handlers.splice(n,1),t==undefined?this.$handlers.push(e):this.$handlers.splice(t,0,e),n==-1&&e.attach&&e.attach(this.$editor)},this.removeKeyboardHandler=function(e){var t=this.$handlers.indexOf(e);return t==-1?!1:(this.$handlers.splice(t,1),e.detach&&e.detach(this.$editor),!0)},this.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},this.getStatusText=function(){var e=this.$data,t=e.editor;return this.$handlers.map(function(n){return n.getStatusText&&n.getStatusText(t,e)||""}).filter(Boolean).join(" ")},this.$callKeyboardHandlers=function(e,t,n,r){var s,o=!1,u=this.$editor.commands;for(var a=this.$handlers.length;a--;){s=this.$handlers[a].handleKeyboard(this.$data,e,t,n,r);if(!s||!s.command)continue;s.command=="null"?o=!0:o=u.exec(s.command,this.$editor,s.args,r),o&&r&&e!=-1&&s.passEvent!=1&&s.command.passEvent!=1&&i.stopEvent(r);if(o)break}return o},this.onCommandKey=function(e,t,n){var i=r.keyCodeToString(n);this.$callKeyboardHandlers(t,i,n,e)},this.onTextInput=function(e){var t=this.$callKeyboardHandlers(-1,e);t||this.$editor.commands.exec("insertstring",this.$editor,e)}}).call(s.prototype),t.KeyBinding=s}),ace.define("ace/range",["require","exports","module"],function(e,t,n){"use strict";var r=function(e,t){return e.row-t.row||e.column-t.column},i=function(e,t,n,r){this.start={row:e,column:t},this.end={row:n,column:r}};(function(){this.isEqual=function(e){return this.start.row===e.start.row&&this.end.row===e.end.row&&this.start.column===e.start.column&&this.end.column===e.end.column},this.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},this.contains=function(e,t){return this.compare(e,t)==0},this.compareRange=function(e){var t,n=e.end,r=e.start;return t=this.compare(n.row,n.column),t==1?(t=this.compare(r.row,r.column),t==1?2:t==0?1:0):t==-1?-2:(t=this.compare(r.row,r.column),t==-1?-1:t==1?42:0)},this.comparePoint=function(e){return this.compare(e.row,e.column)},this.containsRange=function(e){return this.comparePoint(e.start)==0&&this.comparePoint(e.end)==0},this.intersects=function(e){var t=this.compareRange(e);return t==-1||t==0||t==1},this.isEnd=function(e,t){return this.end.row==e&&this.end.column==t},this.isStart=function(e,t){return this.start.row==e&&this.start.column==t},this.setStart=function(e,t){typeof e=="object"?(this.start.column=e.column,this.start.row=e.row):(this.start.row=e,this.start.column=t)},this.setEnd=function(e,t){typeof e=="object"?(this.end.column=e.column,this.end.row=e.row):(this.end.row=e,this.end.column=t)},this.inside=function(e,t){return this.compare(e,t)==0?this.isEnd(e,t)||this.isStart(e,t)?!1:!0:!1},this.insideStart=function(e,t){return this.compare(e,t)==0?this.isEnd(e,t)?!1:!0:!1},this.insideEnd=function(e,t){return this.compare(e,t)==0?this.isStart(e,t)?!1:!0:!1},this.compare=function(e,t){return!this.isMultiLine()&&e===this.start.row?t<this.start.column?-1:t>this.end.column?1:0:e<this.start.row?-1:e>this.end.row?1:this.start.row===e?t>=this.start.column?0:-1:this.end.row===e?t<=this.end.column?0:1:0},this.compareStart=function(e,t){return this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},this.compareEnd=function(e,t){return this.end.row==e&&this.end.column==t?1:this.compare(e,t)},this.compareInside=function(e,t){return this.end.row==e&&this.end.column==t?1:this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},this.clipRows=function(e,t){if(this.end.row>t)var n={row:t+1,column:0};else if(this.end.row<e)var n={row:e,column:0};if(this.start.row>t)var r={row:t+1,column:0};else if(this.start.row<e)var r={row:e,column:0};return i.fromPoints(r||this.start,n||this.end)},this.extend=function(e,t){var n=this.compare(e,t);if(n==0)return this;if(n==-1)var r={row:e,column:t};else var s={row:e,column:t};return i.fromPoints(r||this.start,s||this.end)},this.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},this.isMultiLine=function(){return this.start.row!==this.end.row},this.clone=function(){return i.fromPoints(this.start,this.end)},this.collapseRows=function(){return this.end.column==0?new i(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new i(this.start.row,0,this.end.row,0)},this.toScreenRange=function(e){var t=e.documentToScreenPosition(this.start),n=e.documentToScreenPosition(this.end);return new i(t.row,t.column,n.row,n.column)},this.moveBy=function(e,t){this.start.row+=e,this.start.column+=t,this.end.row+=e,this.end.column+=t}}).call(i.prototype),i.fromPoints=function(e,t){return new i(e.row,e.column,t.row,t.column)},i.comparePoints=r,i.comparePoints=function(e,t){return e.row-t.row||e.column-t.column},t.Range=i}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/lang"),s=e("./lib/event_emitter").EventEmitter,o=e("./range").Range,u=function(e){this.session=e,this.doc=e.getDocument(),this.clearSelection(),this.lead=this.selectionLead=this.doc.createAnchor(0,0),this.anchor=this.selectionAnchor=this.doc.createAnchor(0,0);var t=this;this.lead.on("change",function(e){t._emit("changeCursor"),t.$isEmpty||t._emit("changeSelection"),!t.$keepDesiredColumnOnChange&&e.old.column!=e.value.column&&(t.$desiredColumn=null)}),this.selectionAnchor.on("change",function(){t.$isEmpty||t._emit("changeSelection")})};(function(){r.implement(this,s),this.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},this.isMultiLine=function(){return this.isEmpty()?!1:this.getRange().isMultiLine()},this.getCursor=function(){return this.lead.getPosition()},this.setSelectionAnchor=function(e,t){this.anchor.setPosition(e,t),this.$isEmpty&&(this.$isEmpty=!1,this._emit("changeSelection"))},this.getSelectionAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},this.getSelectionLead=function(){return this.lead.getPosition()},this.shiftSelection=function(e){if(this.$isEmpty){this.moveCursorTo(this.lead.row,this.lead.column+e);return}var t=this.getSelectionAnchor(),n=this.getSelectionLead(),r=this.isBackwards();(!r||t.column!==0)&&this.setSelectionAnchor(t.row,t.column+e),(r||n.column!==0)&&this.$moveSelection(function(){this.moveCursorTo(n.row,n.column+e)})},this.isBackwards=function(){var e=this.anchor,t=this.lead;return e.row>t.row||e.row==t.row&&e.column>t.column},this.getRange=function(){var e=this.anchor,t=this.lead;return this.isEmpty()?o.fromPoints(t,t):this.isBackwards()?o.fromPoints(t,e):o.fromPoints(e,t)},this.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},this.selectAll=function(){var e=this.doc.getLength()-1;this.setSelectionAnchor(0,0),this.moveCursorTo(e,this.doc.getLine(e).length)},this.setRange=this.setSelectionRange=function(e,t){t?(this.setSelectionAnchor(e.end.row,e.end.column),this.selectTo(e.start.row,e.start.column)):(this.setSelectionAnchor(e.start.row,e.start.column),this.selectTo(e.end.row,e.end.column)),this.getRange().isEmpty()&&(this.$isEmpty=!0),this.$desiredColumn=null},this.$moveSelection=function(e){var t=this.lead;this.$isEmpty&&this.setSelectionAnchor(t.row,t.column),e.call(this)},this.selectTo=function(e,t){this.$moveSelection(function(){this.moveCursorTo(e,t)})},this.selectToPosition=function(e){this.$moveSelection(function(){this.moveCursorToPosition(e)})},this.moveTo=function(e,t){this.clearSelection(),this.moveCursorTo(e,t)},this.moveToPosition=function(e){this.clearSelection(),this.moveCursorToPosition(e)},this.selectUp=function(){this.$moveSelection(this.moveCursorUp)},this.selectDown=function(){this.$moveSelection(this.moveCursorDown)},this.selectRight=function(){this.$moveSelection(this.moveCursorRight)},this.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},this.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},this.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},this.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},this.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},this.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},this.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},this.getWordRange=function(e,t){if(typeof t=="undefined"){var n=e||this.lead;e=n.row,t=n.column}return this.session.getWordRange(e,t)},this.selectWord=function(){this.setSelectionRange(this.getWordRange())},this.selectAWord=function(){var e=this.getCursor(),t=this.session.getAWordRange(e.row,e.column);this.setSelectionRange(t)},this.getLineRange=function(e,t){var n=typeof e=="number"?e:this.lead.row,r,i=this.session.getFoldLine(n);return i?(n=i.start.row,r=i.end.row):r=n,t===!0?new o(n,0,r,this.session.getLine(r).length):new o(n,0,r+1,0)},this.selectLine=function(){this.setSelectionRange(this.getLineRange())},this.moveCursorUp=function(){this.moveCursorBy(-1,0)},this.moveCursorDown=function(){this.moveCursorBy(1,0)},this.moveCursorLeft=function(){var e=this.lead.getPosition(),t;if(t=this.session.getFoldAt(e.row,e.column,-1))this.moveCursorTo(t.start.row,t.start.column);else if(e.column===0)e.row>0&&this.moveCursorTo(e.row-1,this.doc.getLine(e.row-1).length);else{var n=this.session.getTabSize();this.session.isTabStop(e)&&this.doc.getLine(e.row).slice(e.column-n,e.column).split(" ").length-1==n?this.moveCursorBy(0,-n):this.moveCursorBy(0,-1)}},this.moveCursorRight=function(){var e=this.lead.getPosition(),t;if(t=this.session.getFoldAt(e.row,e.column,1))this.moveCursorTo(t.end.row,t.end.column);else if(this.lead.column==this.doc.getLine(this.lead.row).length)this.lead.row<this.doc.getLength()-1&&this.moveCursorTo(this.lead.row+1,0);else{var n=this.session.getTabSize(),e=this.lead;this.session.isTabStop(e)&&this.doc.getLine(e.row).slice(e.column,e.column+n).split(" ").length-1==n?this.moveCursorBy(0,n):this.moveCursorBy(0,1)}},this.moveCursorLineStart=function(){var e=this.lead.row,t=this.lead.column,n=this.session.documentToScreenRow(e,t),r=this.session.screenToDocumentPosition(n,0),i=this.session.getDisplayLine(e,null,r.row,r.column),s=i.match(/^\s*/);s[0].length!=t&&!this.session.$useEmacsStyleLineStart&&(r.column+=s[0].length),this.moveCursorToPosition(r)},this.moveCursorLineEnd=function(){var e=this.lead,t=this.session.getDocumentLastRowColumnPosition(e.row,e.column);if(this.lead.column==t.column){var n=this.session.getLine(t.row);if(t.column==n.length){var r=n.search(/\s+$/);r>0&&(t.column=r)}}this.moveCursorTo(t.row,t.column)},this.moveCursorFileEnd=function(){var e=this.doc.getLength()-1,t=this.doc.getLine(e).length;this.moveCursorTo(e,t)},this.moveCursorFileStart=function(){this.moveCursorTo(0,0)},this.moveCursorLongWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t),i;this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var s=this.session.getFoldAt(e,t,1);if(s){this.moveCursorTo(s.end.row,s.end.column);return}if(i=this.session.nonTokenRe.exec(r))t+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,r=n.substring(t);if(t>=n.length){this.moveCursorTo(e,n.length),this.moveCursorRight(),e<this.doc.getLength()-1&&this.moveCursorWordRight();return}if(i=this.session.tokenRe.exec(r))t+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0;this.moveCursorTo(e,t)},this.moveCursorLongWordLeft=function(){var e=this.lead.row,t=this.lead.column,n;if(n=this.session.getFoldAt(e,t,-1)){this.moveCursorTo(n.start.row,n.start.column);return}var r=this.session.getFoldStringAt(e,t,-1);r==null&&(r=this.doc.getLine(e).substring(0,t));var s=i.stringReverse(r),o;this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;if(o=this.session.nonTokenRe.exec(s))t-=this.session.nonTokenRe.lastIndex,s=s.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0;if(t<=0){this.moveCursorTo(e,0),this.moveCursorLeft(),e>0&&this.moveCursorWordLeft();return}if(o=this.session.tokenRe.exec(s))t-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0;this.moveCursorTo(e,t)},this.$shortWordEndIndex=function(e){var t,n=0,r,i=/\s/,s=this.session.tokenRe;s.lastIndex=0;if(t=this.session.tokenRe.exec(e))n=this.session.tokenRe.lastIndex;else{while((r=e[n])&&i.test(r))n++;if(n<1){s.lastIndex=0;while((r=e[n])&&!s.test(r)){s.lastIndex=0,n++;if(i.test(r)){if(n>2){n--;break}while((r=e[n])&&i.test(r))n++;if(n>2)break}}}}return s.lastIndex=0,n},this.moveCursorShortWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t),i=this.session.getFoldAt(e,t,1);if(i)return this.moveCursorTo(i.end.row,i.end.column);if(t==n.length){var s=this.doc.getLength();do e++,r=this.doc.getLine(e);while(e<s&&/^\s*$/.test(r));/^\s+/.test(r)||(r=""),t=0}var o=this.$shortWordEndIndex(r);this.moveCursorTo(e,t+o)},this.moveCursorShortWordLeft=function(){var e=this.lead.row,t=this.lead.column,n;if(n=this.session.getFoldAt(e,t,-1))return this.moveCursorTo(n.start.row,n.start.column);var r=this.session.getLine(e).substring(0,t);if(t===0){do e--,r=this.doc.getLine(e);while(e>0&&/^\s*$/.test(r));t=r.length,/\s+$/.test(r)||(r="")}var s=i.stringReverse(r),o=this.$shortWordEndIndex(s);return this.moveCursorTo(e,t-o)},this.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},this.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},this.moveCursorBy=function(e,t){var n=this.session.documentToScreenPosition(this.lead.row,this.lead.column);t===0&&(this.$desiredColumn?n.column=this.$desiredColumn:this.$desiredColumn=n.column);var r=this.session.screenToDocumentPosition(n.row+e,n.column);e!==0&&t===0&&r.row===this.lead.row&&r.column===this.lead.column&&this.session.lineWidgets&&this.session.lineWidgets[r.row]&&r.row++,this.moveCursorTo(r.row,r.column+t,t===0)},this.moveCursorToPosition=function(e){this.moveCursorTo(e.row,e.column)},this.moveCursorTo=function(e,t,n){var r=this.session.getFoldAt(e,t,1);r&&(e=r.start.row,t=r.start.column),this.$keepDesiredColumnOnChange=!0,this.lead.setPosition(e,t),this.$keepDesiredColumnOnChange=!1,n||(this.$desiredColumn=null)},this.moveCursorToScreen=function(e,t,n){var r=this.session.screenToDocumentPosition(e,t);this.moveCursorTo(r.row,r.column,n)},this.detach=function(){this.lead.detach(),this.anchor.detach(),this.session=this.doc=null},this.fromOrientedRange=function(e){this.setSelectionRange(e,e.cursor==e.start),this.$desiredColumn=e.desiredColumn||this.$desiredColumn},this.toOrientedRange=function(e){var t=this.getRange();return e?(e.start.column=t.start.column,e.start.row=t.start.row,e.end.column=t.end.column,e.end.row=t.end.row):e=t,e.cursor=this.isBackwards()?e.start:e.end,e.desiredColumn=this.$desiredColumn,e},this.getRangeOfMovements=function(e){var t=this.getCursor();try{e.call(null,this);var n=this.getCursor();return o.fromPoints(t,n)}catch(r){return o.fromPoints(t,t)}finally{this.moveCursorToPosition(t)}},this.toJSON=function(){if(this.rangeCount)var e=this.ranges.map(function(e){var t=e.clone();return t.isBackwards=e.cursor==e.start,t});else{var e=this.getRange();e.isBackwards=this.isBackwards()}return e},this.fromJSON=function(e){if(e.start==undefined){if(this.rangeList){this.toSingleRange(e[0]);for(var t=e.length;t--;){var n=o.fromPoints(e[t].start,e[t].end);e.isBackwards&&(n.cursor=n.start),this.addRange(n,!0)}return}e=e[0]}this.rangeList&&this.toSingleRange(e),this.setSelectionRange(e,e.isBackwards)},this.isEqual=function(e){if((e.length||this.rangeCount)&&e.length!=this.rangeCount)return!1;if(!e.length||!this.ranges)return this.getRange().isEqual(e);for(var t=this.ranges.length;t--;)if(!this.ranges[t].isEqual(e[t]))return!1;return!0}}).call(u.prototype),t.Selection=u}),ace.define("ace/tokenizer",["require","exports","module","ace/config"],function(e,t,n){"use strict";var r=e("./config"),i=2e3,s=function(e){this.states=e,this.regExps={},this.matchMappings={};for(var t in this.states){var n=this.states[t],r=[],i=0,s=this.matchMappings[t]={defaultToken:"text"},o="g",u=[];for(var a=0;a<n.length;a++){var f=n[a];f.defaultToken&&(s.defaultToken=f.defaultToken),f.caseInsensitive&&(o="gi");if(f.regex==null)continue;f.regex instanceof RegExp&&(f.regex=f.regex.toString().slice(1,-1));var l=f.regex,c=(new RegExp("(?:("+l+")|(.))")).exec("a").length-2;Array.isArray(f.token)?f.token.length==1||c==1?f.token=f.token[0]:c-1!=f.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:f,groupCount:c-1}),f.token=f.token[0]):(f.tokenArray=f.token,f.token=null,f.onMatch=this.$arrayTokens):typeof f.token=="function"&&!f.onMatch&&(c>1?f.onMatch=this.$applyToken:f.onMatch=f.token),c>1&&(/\\\d/.test(f.regex)?l=f.regex.replace(/\\([0-9]+)/g,function(e,t){return"\\"+(parseInt(t,10)+i+1)}):(c=1,l=this.removeCapturingGroups(f.regex)),!f.splitRegex&&typeof f.token!="string"&&u.push(f)),s[i]=a,i+=c,r.push(l),f.onMatch||(f.onMatch=null)}r.length||(s[0]=0,r.push("$")),u.forEach(function(e){e.splitRegex=this.createSplitterRegexp(e.regex,o)},this),this.regExps[t]=new RegExp("("+r.join(")|(")+")|($)",o)}};(function(){this.$setMaxTokenCount=function(e){i=e|0},this.$applyToken=function(e){var t=this.splitRegex.exec(e).slice(1),n=this.token.apply(this,t);if(typeof n=="string")return[{type:n,value:e}];var r=[];for(var i=0,s=n.length;i<s;i++)t[i]&&(r[r.length]={type:n[i],value:t[i]});return r},this.$arrayTokens=function(e){if(!e)return[];var t=this.splitRegex.exec(e);if(!t)return"text";var n=[],r=this.tokenArray;for(var i=0,s=r.length;i<s;i++)t[i+1]&&(n[n.length]={type:r[i],value:t[i+1]});return n},this.removeCapturingGroups=function(e){var t=e.replace(/\[(?:\\.|[^\]])*?\]|\\.|\(\?[:=!]|(\()/g,function(e,t){return t?"(?:":e});return t},this.createSplitterRegexp=function(e,t){if(e.indexOf("(?=")!=-1){var n=0,r=!1,i={};e.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,function(e,t,s,o,u,a){return r?r=u!="]":u?r=!0:o?(n==i.stack&&(i.end=a+1,i.stack=-1),n--):s&&(n++,s.length!=1&&(i.stack=n,i.start=a)),e}),i.end!=null&&/^\)*$/.test(e.substr(i.end))&&(e=e.substring(0,i.start)+e.substr(i.end))}return new RegExp(e,(t||"").replace("g",""))},this.getLineTokens=function(e,t){if(t&&typeof t!="string"){var n=t.slice(0);t=n[0],t==="#tmp"&&(n.shift(),t=n.shift())}else var n=[];var r=t||"start",s=this.states[r];s||(r="start",s=this.states[r]);var o=this.matchMappings[r],u=this.regExps[r];u.lastIndex=0;var a,f=[],l=0,c=0,h={type:null,value:""};while(a=u.exec(e)){var p=o.defaultToken,d=null,v=a[0],m=u.lastIndex;if(m-v.length>l){var g=e.substring(l,m-v.length);h.type==p?h.value+=g:(h.type&&f.push(h),h={type:p,value:g})}for(var y=0;y<a.length-2;y++){if(a[y+1]===undefined)continue;d=s[o[y]],d.onMatch?p=d.onMatch(v,r,n):p=d.token,d.next&&(typeof d.next=="string"?r=d.next:r=d.next(r,n),s=this.states[r],s||(this.reportError("state doesn't exist",r),r="start",s=this.states[r]),o=this.matchMappings[r],l=m,u=this.regExps[r],u.lastIndex=m);break}if(v)if(typeof p=="string")!!d&&d.merge===!1||h.type!==p?(h.type&&f.push(h),h={type:p,value:v}):h.value+=v;else if(p){h.type&&f.push(h),h={type:null,value:""};for(var y=0;y<p.length;y++)f.push(p[y])}if(l==e.length)break;l=m;if(c++>i){c>2*e.length&&this.reportError("infinite loop with in ace tokenizer",{startState:t,line:e});while(l<e.length)h.type&&f.push(h),h={value:e.substring(l,l+=2e3),type:"overflow"};r="start",n=[];break}}return h.type&&f.push(h),n.length>1&&n[0]!==r&&n.unshift("#tmp",r),{tokens:f,state:n.length?n:r}},this.reportError=r.reportError}).call(s.prototype),t.Tokenizer=s}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/lang"],function(e,t,n){"use strict";var r=e("../lib/lang"),i=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}};(function(){this.addRules=function(e,t){if(!t){for(var n in e)this.$rules[n]=e[n];return}for(var n in e){var r=e[n];for(var i=0;i<r.length;i++){var s=r[i];if(s.next||s.onMatch)typeof s.next!="string"?s.nextState&&s.nextState.indexOf(t)!==0&&(s.nextState=t+s.nextState):s.next.indexOf(t)!==0&&(s.next=t+s.next)}this.$rules[t+n]=r}},this.getRules=function(){return this.$rules},this.embedRules=function(e,t,n,i,s){var o=typeof e=="function"?(new e).getRules():e;if(i)for(var u=0;u<i.length;u++)i[u]=t+i[u];else{i=[];for(var a in o)i.push(t+a)}this.addRules(o,t);if(n){var f=Array.prototype[s?"push":"unshift"];for(var u=0;u<i.length;u++)f.apply(this.$rules[i[u]],r.deepCopy(n))}this.$embeds||(this.$embeds=[]),this.$embeds.push(t)},this.getEmbeds=function(){return this.$embeds};var e=function(e,t){return(e!="start"||t.length)&&t.unshift(this.nextState,e),this.nextState},t=function(e,t){return t.shift(),t.shift()||"start"};this.normalizeRules=function(){function i(s){var o=r[s];o.processed=!0;for(var u=0;u<o.length;u++){var a=o[u];!a.regex&&a.start&&(a.regex=a.start,a.next||(a.next=[]),a.next.push({defaultToken:a.token},{token:a.token+".end",regex:a.end||a.start,next:"pop"}),a.token=a.token+".start",a.push=!0);var f=a.next||a.push;if(f&&Array.isArray(f)){var l=a.stateName;l||(l=a.token,typeof l!="string"&&(l=l[0]||""),r[l]&&(l+=n++)),r[l]=f,a.next=l,i(l)}else f=="pop"&&(a.next=t);a.push&&(a.nextState=a.next||a.push,a.next=e,delete a.push);if(a.rules)for(var c in a.rules)r[c]?r[c].push&&r[c].push.apply(r[c],a.rules[c]):r[c]=a.rules[c];if(a.include||typeof a=="string")var h=a.include||a,p=r[h];else Array.isArray(a)&&(p=a);if(p){var d=[u,1].concat(p);a.noEscape&&(d=d.filter(function(e){return!e.next})),o.splice.apply(o,d),u--,p=null}a.keywordMap&&(a.token=this.createKeywordMapper(a.keywordMap,a.defaultToken||"text",a.caseInsensitive),delete a.defaultToken)}}var n=0,r=this.$rules;Object.keys(r).forEach(i,this)},this.createKeywordMapper=function(e,t,n,r){var i=Object.create(null);return Object.keys(e).forEach(function(t){var s=e[t];n&&(s=s.toLowerCase());var o=s.split(r||"|");for(var u=o.length;u--;)i[o[u]]=t}),Object.getPrototypeOf(i)&&(i.__proto__=null),this.$keywordList=Object.keys(i),e=null,n?function(e){return i[e.toLowerCase()]||t}:function(e){return i[e]||t}},this.getKeywords=function(){return this.$keywords}}).call(i.prototype),t.TextHighlightRules=i}),ace.define("ace/mode/behaviour",["require","exports","module"],function(e,t,n){"use strict";var r=function(){this.$behaviours={}};(function(){this.add=function(e,t,n){switch(undefined){case this.$behaviours:this.$behaviours={};case this.$behaviours[e]:this.$behaviours[e]={}}this.$behaviours[e][t]=n},this.addBehaviours=function(e){for(var t in e)for(var n in e[t])this.add(t,n,e[t][n])},this.remove=function(e){this.$behaviours&&this.$behaviours[e]&&delete this.$behaviours[e]},this.inherit=function(e,t){if(typeof e=="function")var n=(new e).getBehaviours(t);else var n=e.getBehaviours(t);this.addBehaviours(n)},this.getBehaviours=function(e){if(!e)return this.$behaviours;var t={};for(var n=0;n<e.length;n++)this.$behaviours[e[n]]&&(t[e[n]]=this.$behaviours[e[n]]);return t}}).call(r.prototype),t.Behaviour=r}),ace.define("ace/unicode",["require","exports","module"],function(e,t,n){"use strict";function r(e){var n=/\w{4}/g;for(var r in e)t.packages[r]=e[r].replace(n,"\\u$&")}t.packages={},r({L:"0041-005A0061-007A00AA00B500BA00C0-00D600D8-00F600F8-02C102C6-02D102E0-02E402EC02EE0370-037403760377037A-037D03860388-038A038C038E-03A103A3-03F503F7-0481048A-05250531-055605590561-058705D0-05EA05F0-05F20621-064A066E066F0671-06D306D506E506E606EE06EF06FA-06FC06FF07100712-072F074D-07A507B107CA-07EA07F407F507FA0800-0815081A082408280904-0939093D09500958-0961097109720979-097F0985-098C098F09900993-09A809AA-09B009B209B6-09B909BD09CE09DC09DD09DF-09E109F009F10A05-0A0A0A0F0A100A13-0A280A2A-0A300A320A330A350A360A380A390A59-0A5C0A5E0A72-0A740A85-0A8D0A8F-0A910A93-0AA80AAA-0AB00AB20AB30AB5-0AB90ABD0AD00AE00AE10B05-0B0C0B0F0B100B13-0B280B2A-0B300B320B330B35-0B390B3D0B5C0B5D0B5F-0B610B710B830B85-0B8A0B8E-0B900B92-0B950B990B9A0B9C0B9E0B9F0BA30BA40BA8-0BAA0BAE-0BB90BD00C05-0C0C0C0E-0C100C12-0C280C2A-0C330C35-0C390C3D0C580C590C600C610C85-0C8C0C8E-0C900C92-0CA80CAA-0CB30CB5-0CB90CBD0CDE0CE00CE10D05-0D0C0D0E-0D100D12-0D280D2A-0D390D3D0D600D610D7A-0D7F0D85-0D960D9A-0DB10DB3-0DBB0DBD0DC0-0DC60E01-0E300E320E330E40-0E460E810E820E840E870E880E8A0E8D0E94-0E970E99-0E9F0EA1-0EA30EA50EA70EAA0EAB0EAD-0EB00EB20EB30EBD0EC0-0EC40EC60EDC0EDD0F000F40-0F470F49-0F6C0F88-0F8B1000-102A103F1050-1055105A-105D106110651066106E-10701075-1081108E10A0-10C510D0-10FA10FC1100-1248124A-124D1250-12561258125A-125D1260-1288128A-128D1290-12B012B2-12B512B8-12BE12C012C2-12C512C8-12D612D8-13101312-13151318-135A1380-138F13A0-13F41401-166C166F-167F1681-169A16A0-16EA1700-170C170E-17111720-17311740-17511760-176C176E-17701780-17B317D717DC1820-18771880-18A818AA18B0-18F51900-191C1950-196D1970-19741980-19AB19C1-19C71A00-1A161A20-1A541AA71B05-1B331B45-1B4B1B83-1BA01BAE1BAF1C00-1C231C4D-1C4F1C5A-1C7D1CE9-1CEC1CEE-1CF11D00-1DBF1E00-1F151F18-1F1D1F20-1F451F48-1F4D1F50-1F571F591F5B1F5D1F5F-1F7D1F80-1FB41FB6-1FBC1FBE1FC2-1FC41FC6-1FCC1FD0-1FD31FD6-1FDB1FE0-1FEC1FF2-1FF41FF6-1FFC2071207F2090-209421022107210A-211321152119-211D212421262128212A-212D212F-2139213C-213F2145-2149214E218321842C00-2C2E2C30-2C5E2C60-2CE42CEB-2CEE2D00-2D252D30-2D652D6F2D80-2D962DA0-2DA62DA8-2DAE2DB0-2DB62DB8-2DBE2DC0-2DC62DC8-2DCE2DD0-2DD62DD8-2DDE2E2F300530063031-3035303B303C3041-3096309D-309F30A1-30FA30FC-30FF3105-312D3131-318E31A0-31B731F0-31FF3400-4DB54E00-9FCBA000-A48CA4D0-A4FDA500-A60CA610-A61FA62AA62BA640-A65FA662-A66EA67F-A697A6A0-A6E5A717-A71FA722-A788A78BA78CA7FB-A801A803-A805A807-A80AA80C-A822A840-A873A882-A8B3A8F2-A8F7A8FBA90A-A925A930-A946A960-A97CA984-A9B2A9CFAA00-AA28AA40-AA42AA44-AA4BAA60-AA76AA7AAA80-AAAFAAB1AAB5AAB6AAB9-AABDAAC0AAC2AADB-AADDABC0-ABE2AC00-D7A3D7B0-D7C6D7CB-D7FBF900-FA2DFA30-FA6DFA70-FAD9FB00-FB06FB13-FB17FB1DFB1F-FB28FB2A-FB36FB38-FB3CFB3EFB40FB41FB43FB44FB46-FBB1FBD3-FD3DFD50-FD8FFD92-FDC7FDF0-FDFBFE70-FE74FE76-FEFCFF21-FF3AFF41-FF5AFF66-FFBEFFC2-FFC7FFCA-FFCFFFD2-FFD7FFDA-FFDC",Ll:"0061-007A00AA00B500BA00DF-00F600F8-00FF01010103010501070109010B010D010F01110113011501170119011B011D011F01210123012501270129012B012D012F01310133013501370138013A013C013E014001420144014601480149014B014D014F01510153015501570159015B015D015F01610163016501670169016B016D016F0171017301750177017A017C017E-0180018301850188018C018D019201950199-019B019E01A101A301A501A801AA01AB01AD01B001B401B601B901BA01BD-01BF01C601C901CC01CE01D001D201D401D601D801DA01DC01DD01DF01E101E301E501E701E901EB01ED01EF01F001F301F501F901FB01FD01FF02010203020502070209020B020D020F02110213021502170219021B021D021F02210223022502270229022B022D022F02310233-0239023C023F0240024202470249024B024D024F-02930295-02AF037103730377037B-037D039003AC-03CE03D003D103D5-03D703D903DB03DD03DF03E103E303E503E703E903EB03ED03EF-03F303F503F803FB03FC0430-045F04610463046504670469046B046D046F04710473047504770479047B047D047F0481048B048D048F04910493049504970499049B049D049F04A104A304A504A704A904AB04AD04AF04B104B304B504B704B904BB04BD04BF04C204C404C604C804CA04CC04CE04CF04D104D304D504D704D904DB04DD04DF04E104E304E504E704E904EB04ED04EF04F104F304F504F704F904FB04FD04FF05010503050505070509050B050D050F05110513051505170519051B051D051F0521052305250561-05871D00-1D2B1D62-1D771D79-1D9A1E011E031E051E071E091E0B1E0D1E0F1E111E131E151E171E191E1B1E1D1E1F1E211E231E251E271E291E2B1E2D1E2F1E311E331E351E371E391E3B1E3D1E3F1E411E431E451E471E491E4B1E4D1E4F1E511E531E551E571E591E5B1E5D1E5F1E611E631E651E671E691E6B1E6D1E6F1E711E731E751E771E791E7B1E7D1E7F1E811E831E851E871E891E8B1E8D1E8F1E911E931E95-1E9D1E9F1EA11EA31EA51EA71EA91EAB1EAD1EAF1EB11EB31EB51EB71EB91EBB1EBD1EBF1EC11EC31EC51EC71EC91ECB1ECD1ECF1ED11ED31ED51ED71ED91EDB1EDD1EDF1EE11EE31EE51EE71EE91EEB1EED1EEF1EF11EF31EF51EF71EF91EFB1EFD1EFF-1F071F10-1F151F20-1F271F30-1F371F40-1F451F50-1F571F60-1F671F70-1F7D1F80-1F871F90-1F971FA0-1FA71FB0-1FB41FB61FB71FBE1FC2-1FC41FC61FC71FD0-1FD31FD61FD71FE0-1FE71FF2-1FF41FF61FF7210A210E210F2113212F21342139213C213D2146-2149214E21842C30-2C5E2C612C652C662C682C6A2C6C2C712C732C742C76-2C7C2C812C832C852C872C892C8B2C8D2C8F2C912C932C952C972C992C9B2C9D2C9F2CA12CA32CA52CA72CA92CAB2CAD2CAF2CB12CB32CB52CB72CB92CBB2CBD2CBF2CC12CC32CC52CC72CC92CCB2CCD2CCF2CD12CD32CD52CD72CD92CDB2CDD2CDF2CE12CE32CE42CEC2CEE2D00-2D25A641A643A645A647A649A64BA64DA64FA651A653A655A657A659A65BA65DA65FA663A665A667A669A66BA66DA681A683A685A687A689A68BA68DA68FA691A693A695A697A723A725A727A729A72BA72DA72F-A731A733A735A737A739A73BA73DA73FA741A743A745A747A749A74BA74DA74FA751A753A755A757A759A75BA75DA75FA761A763A765A767A769A76BA76DA76FA771-A778A77AA77CA77FA781A783A785A787A78CFB00-FB06FB13-FB17FF41-FF5A",Lu:"0041-005A00C0-00D600D8-00DE01000102010401060108010A010C010E01100112011401160118011A011C011E01200122012401260128012A012C012E01300132013401360139013B013D013F0141014301450147014A014C014E01500152015401560158015A015C015E01600162016401660168016A016C016E017001720174017601780179017B017D018101820184018601870189-018B018E-0191019301940196-0198019C019D019F01A001A201A401A601A701A901AC01AE01AF01B1-01B301B501B701B801BC01C401C701CA01CD01CF01D101D301D501D701D901DB01DE01E001E201E401E601E801EA01EC01EE01F101F401F6-01F801FA01FC01FE02000202020402060208020A020C020E02100212021402160218021A021C021E02200222022402260228022A022C022E02300232023A023B023D023E02410243-02460248024A024C024E03700372037603860388-038A038C038E038F0391-03A103A3-03AB03CF03D2-03D403D803DA03DC03DE03E003E203E403E603E803EA03EC03EE03F403F703F903FA03FD-042F04600462046404660468046A046C046E04700472047404760478047A047C047E0480048A048C048E04900492049404960498049A049C049E04A004A204A404A604A804AA04AC04AE04B004B204B404B604B804BA04BC04BE04C004C104C304C504C704C904CB04CD04D004D204D404D604D804DA04DC04DE04E004E204E404E604E804EA04EC04EE04F004F204F404F604F804FA04FC04FE05000502050405060508050A050C050E05100512051405160518051A051C051E0520052205240531-055610A0-10C51E001E021E041E061E081E0A1E0C1E0E1E101E121E141E161E181E1A1E1C1E1E1E201E221E241E261E281E2A1E2C1E2E1E301E321E341E361E381E3A1E3C1E3E1E401E421E441E461E481E4A1E4C1E4E1E501E521E541E561E581E5A1E5C1E5E1E601E621E641E661E681E6A1E6C1E6E1E701E721E741E761E781E7A1E7C1E7E1E801E821E841E861E881E8A1E8C1E8E1E901E921E941E9E1EA01EA21EA41EA61EA81EAA1EAC1EAE1EB01EB21EB41EB61EB81EBA1EBC1EBE1EC01EC21EC41EC61EC81ECA1ECC1ECE1ED01ED21ED41ED61ED81EDA1EDC1EDE1EE01EE21EE41EE61EE81EEA1EEC1EEE1EF01EF21EF41EF61EF81EFA1EFC1EFE1F08-1F0F1F18-1F1D1F28-1F2F1F38-1F3F1F48-1F4D1F591F5B1F5D1F5F1F68-1F6F1FB8-1FBB1FC8-1FCB1FD8-1FDB1FE8-1FEC1FF8-1FFB21022107210B-210D2110-211221152119-211D212421262128212A-212D2130-2133213E213F214521832C00-2C2E2C602C62-2C642C672C692C6B2C6D-2C702C722C752C7E-2C802C822C842C862C882C8A2C8C2C8E2C902C922C942C962C982C9A2C9C2C9E2CA02CA22CA42CA62CA82CAA2CAC2CAE2CB02CB22CB42CB62CB82CBA2CBC2CBE2CC02CC22CC42CC62CC82CCA2CCC2CCE2CD02CD22CD42CD62CD82CDA2CDC2CDE2CE02CE22CEB2CEDA640A642A644A646A648A64AA64CA64EA650A652A654A656A658A65AA65CA65EA662A664A666A668A66AA66CA680A682A684A686A688A68AA68CA68EA690A692A694A696A722A724A726A728A72AA72CA72EA732A734A736A738A73AA73CA73EA740A742A744A746A748A74AA74CA74EA750A752A754A756A758A75AA75CA75EA760A762A764A766A768A76AA76CA76EA779A77BA77DA77EA780A782A784A786A78BFF21-FF3A",Lt:"01C501C801CB01F21F88-1F8F1F98-1F9F1FA8-1FAF1FBC1FCC1FFC",Lm:"02B0-02C102C6-02D102E0-02E402EC02EE0374037A0559064006E506E607F407F507FA081A0824082809710E460EC610FC17D718431AA71C78-1C7D1D2C-1D611D781D9B-1DBF2071207F2090-20942C7D2D6F2E2F30053031-3035303B309D309E30FC-30FEA015A4F8-A4FDA60CA67FA717-A71FA770A788A9CFAA70AADDFF70FF9EFF9F",Lo:"01BB01C0-01C3029405D0-05EA05F0-05F20621-063F0641-064A066E066F0671-06D306D506EE06EF06FA-06FC06FF07100712-072F074D-07A507B107CA-07EA0800-08150904-0939093D09500958-096109720979-097F0985-098C098F09900993-09A809AA-09B009B209B6-09B909BD09CE09DC09DD09DF-09E109F009F10A05-0A0A0A0F0A100A13-0A280A2A-0A300A320A330A350A360A380A390A59-0A5C0A5E0A72-0A740A85-0A8D0A8F-0A910A93-0AA80AAA-0AB00AB20AB30AB5-0AB90ABD0AD00AE00AE10B05-0B0C0B0F0B100B13-0B280B2A-0B300B320B330B35-0B390B3D0B5C0B5D0B5F-0B610B710B830B85-0B8A0B8E-0B900B92-0B950B990B9A0B9C0B9E0B9F0BA30BA40BA8-0BAA0BAE-0BB90BD00C05-0C0C0C0E-0C100C12-0C280C2A-0C330C35-0C390C3D0C580C590C600C610C85-0C8C0C8E-0C900C92-0CA80CAA-0CB30CB5-0CB90CBD0CDE0CE00CE10D05-0D0C0D0E-0D100D12-0D280D2A-0D390D3D0D600D610D7A-0D7F0D85-0D960D9A-0DB10DB3-0DBB0DBD0DC0-0DC60E01-0E300E320E330E40-0E450E810E820E840E870E880E8A0E8D0E94-0E970E99-0E9F0EA1-0EA30EA50EA70EAA0EAB0EAD-0EB00EB20EB30EBD0EC0-0EC40EDC0EDD0F000F40-0F470F49-0F6C0F88-0F8B1000-102A103F1050-1055105A-105D106110651066106E-10701075-1081108E10D0-10FA1100-1248124A-124D1250-12561258125A-125D1260-1288128A-128D1290-12B012B2-12B512B8-12BE12C012C2-12C512C8-12D612D8-13101312-13151318-135A1380-138F13A0-13F41401-166C166F-167F1681-169A16A0-16EA1700-170C170E-17111720-17311740-17511760-176C176E-17701780-17B317DC1820-18421844-18771880-18A818AA18B0-18F51900-191C1950-196D1970-19741980-19AB19C1-19C71A00-1A161A20-1A541B05-1B331B45-1B4B1B83-1BA01BAE1BAF1C00-1C231C4D-1C4F1C5A-1C771CE9-1CEC1CEE-1CF12135-21382D30-2D652D80-2D962DA0-2DA62DA8-2DAE2DB0-2DB62DB8-2DBE2DC0-2DC62DC8-2DCE2DD0-2DD62DD8-2DDE3006303C3041-3096309F30A1-30FA30FF3105-312D3131-318E31A0-31B731F0-31FF3400-4DB54E00-9FCBA000-A014A016-A48CA4D0-A4F7A500-A60BA610-A61FA62AA62BA66EA6A0-A6E5A7FB-A801A803-A805A807-A80AA80C-A822A840-A873A882-A8B3A8F2-A8F7A8FBA90A-A925A930-A946A960-A97CA984-A9B2AA00-AA28AA40-AA42AA44-AA4BAA60-AA6FAA71-AA76AA7AAA80-AAAFAAB1AAB5AAB6AAB9-AABDAAC0AAC2AADBAADCABC0-ABE2AC00-D7A3D7B0-D7C6D7CB-D7FBF900-FA2DFA30-FA6DFA70-FAD9FB1DFB1F-FB28FB2A-FB36FB38-FB3CFB3EFB40FB41FB43FB44FB46-FBB1FBD3-FD3DFD50-FD8FFD92-FDC7FDF0-FDFBFE70-FE74FE76-FEFCFF66-FF6FFF71-FF9DFFA0-FFBEFFC2-FFC7FFCA-FFCFFFD2-FFD7FFDA-FFDC",M:"0300-036F0483-04890591-05BD05BF05C105C205C405C505C70610-061A064B-065E067006D6-06DC06DE-06E406E706E806EA-06ED07110730-074A07A6-07B007EB-07F30816-0819081B-08230825-08270829-082D0900-0903093C093E-094E0951-0955096209630981-098309BC09BE-09C409C709C809CB-09CD09D709E209E30A01-0A030A3C0A3E-0A420A470A480A4B-0A4D0A510A700A710A750A81-0A830ABC0ABE-0AC50AC7-0AC90ACB-0ACD0AE20AE30B01-0B030B3C0B3E-0B440B470B480B4B-0B4D0B560B570B620B630B820BBE-0BC20BC6-0BC80BCA-0BCD0BD70C01-0C030C3E-0C440C46-0C480C4A-0C4D0C550C560C620C630C820C830CBC0CBE-0CC40CC6-0CC80CCA-0CCD0CD50CD60CE20CE30D020D030D3E-0D440D46-0D480D4A-0D4D0D570D620D630D820D830DCA0DCF-0DD40DD60DD8-0DDF0DF20DF30E310E34-0E3A0E47-0E4E0EB10EB4-0EB90EBB0EBC0EC8-0ECD0F180F190F350F370F390F3E0F3F0F71-0F840F860F870F90-0F970F99-0FBC0FC6102B-103E1056-1059105E-10601062-10641067-106D1071-10741082-108D108F109A-109D135F1712-17141732-1734175217531772177317B6-17D317DD180B-180D18A91920-192B1930-193B19B0-19C019C819C91A17-1A1B1A55-1A5E1A60-1A7C1A7F1B00-1B041B34-1B441B6B-1B731B80-1B821BA1-1BAA1C24-1C371CD0-1CD21CD4-1CE81CED1CF21DC0-1DE61DFD-1DFF20D0-20F02CEF-2CF12DE0-2DFF302A-302F3099309AA66F-A672A67CA67DA6F0A6F1A802A806A80BA823-A827A880A881A8B4-A8C4A8E0-A8F1A926-A92DA947-A953A980-A983A9B3-A9C0AA29-AA36AA43AA4CAA4DAA7BAAB0AAB2-AAB4AAB7AAB8AABEAABFAAC1ABE3-ABEAABECABEDFB1EFE00-FE0FFE20-FE26",Mn:"0300-036F0483-04870591-05BD05BF05C105C205C405C505C70610-061A064B-065E067006D6-06DC06DF-06E406E706E806EA-06ED07110730-074A07A6-07B007EB-07F30816-0819081B-08230825-08270829-082D0900-0902093C0941-0948094D0951-095509620963098109BC09C1-09C409CD09E209E30A010A020A3C0A410A420A470A480A4B-0A4D0A510A700A710A750A810A820ABC0AC1-0AC50AC70AC80ACD0AE20AE30B010B3C0B3F0B41-0B440B4D0B560B620B630B820BC00BCD0C3E-0C400C46-0C480C4A-0C4D0C550C560C620C630CBC0CBF0CC60CCC0CCD0CE20CE30D41-0D440D4D0D620D630DCA0DD2-0DD40DD60E310E34-0E3A0E47-0E4E0EB10EB4-0EB90EBB0EBC0EC8-0ECD0F180F190F350F370F390F71-0F7E0F80-0F840F860F870F90-0F970F99-0FBC0FC6102D-10301032-10371039103A103D103E10581059105E-10601071-1074108210851086108D109D135F1712-17141732-1734175217531772177317B7-17BD17C617C9-17D317DD180B-180D18A91920-19221927192819321939-193B1A171A181A561A58-1A5E1A601A621A65-1A6C1A73-1A7C1A7F1B00-1B031B341B36-1B3A1B3C1B421B6B-1B731B801B811BA2-1BA51BA81BA91C2C-1C331C361C371CD0-1CD21CD4-1CE01CE2-1CE81CED1DC0-1DE61DFD-1DFF20D0-20DC20E120E5-20F02CEF-2CF12DE0-2DFF302A-302F3099309AA66FA67CA67DA6F0A6F1A802A806A80BA825A826A8C4A8E0-A8F1A926-A92DA947-A951A980-A982A9B3A9B6-A9B9A9BCAA29-AA2EAA31AA32AA35AA36AA43AA4CAAB0AAB2-AAB4AAB7AAB8AABEAABFAAC1ABE5ABE8ABEDFB1EFE00-FE0FFE20-FE26",Mc:"0903093E-09400949-094C094E0982098309BE-09C009C709C809CB09CC09D70A030A3E-0A400A830ABE-0AC00AC90ACB0ACC0B020B030B3E0B400B470B480B4B0B4C0B570BBE0BBF0BC10BC20BC6-0BC80BCA-0BCC0BD70C01-0C030C41-0C440C820C830CBE0CC0-0CC40CC70CC80CCA0CCB0CD50CD60D020D030D3E-0D400D46-0D480D4A-0D4C0D570D820D830DCF-0DD10DD8-0DDF0DF20DF30F3E0F3F0F7F102B102C10311038103B103C105610571062-10641067-106D108310841087-108C108F109A-109C17B617BE-17C517C717C81923-19261929-192B193019311933-193819B0-19C019C819C91A19-1A1B1A551A571A611A631A641A6D-1A721B041B351B3B1B3D-1B411B431B441B821BA11BA61BA71BAA1C24-1C2B1C341C351CE11CF2A823A824A827A880A881A8B4-A8C3A952A953A983A9B4A9B5A9BAA9BBA9BD-A9C0AA2FAA30AA33AA34AA4DAA7BABE3ABE4ABE6ABE7ABE9ABEAABEC",Me:"0488048906DE20DD-20E020E2-20E4A670-A672",N:"0030-003900B200B300B900BC-00BE0660-066906F0-06F907C0-07C90966-096F09E6-09EF09F4-09F90A66-0A6F0AE6-0AEF0B66-0B6F0BE6-0BF20C66-0C6F0C78-0C7E0CE6-0CEF0D66-0D750E50-0E590ED0-0ED90F20-0F331040-10491090-10991369-137C16EE-16F017E0-17E917F0-17F91810-18191946-194F19D0-19DA1A80-1A891A90-1A991B50-1B591BB0-1BB91C40-1C491C50-1C5920702074-20792080-20892150-21822185-21892460-249B24EA-24FF2776-27932CFD30073021-30293038-303A3192-31953220-32293251-325F3280-328932B1-32BFA620-A629A6E6-A6EFA830-A835A8D0-A8D9A900-A909A9D0-A9D9AA50-AA59ABF0-ABF9FF10-FF19",Nd:"0030-00390660-066906F0-06F907C0-07C90966-096F09E6-09EF0A66-0A6F0AE6-0AEF0B66-0B6F0BE6-0BEF0C66-0C6F0CE6-0CEF0D66-0D6F0E50-0E590ED0-0ED90F20-0F291040-10491090-109917E0-17E91810-18191946-194F19D0-19DA1A80-1A891A90-1A991B50-1B591BB0-1BB91C40-1C491C50-1C59A620-A629A8D0-A8D9A900-A909A9D0-A9D9AA50-AA59ABF0-ABF9FF10-FF19",Nl:"16EE-16F02160-21822185-218830073021-30293038-303AA6E6-A6EF",No:"00B200B300B900BC-00BE09F4-09F90BF0-0BF20C78-0C7E0D70-0D750F2A-0F331369-137C17F0-17F920702074-20792080-20892150-215F21892460-249B24EA-24FF2776-27932CFD3192-31953220-32293251-325F3280-328932B1-32BFA830-A835",P:"0021-00230025-002A002C-002F003A003B003F0040005B-005D005F007B007D00A100AB00B700BB00BF037E0387055A-055F0589058A05BE05C005C305C605F305F40609060A060C060D061B061E061F066A-066D06D40700-070D07F7-07F90830-083E0964096509700DF40E4F0E5A0E5B0F04-0F120F3A-0F3D0F850FD0-0FD4104A-104F10FB1361-13681400166D166E169B169C16EB-16ED1735173617D4-17D617D8-17DA1800-180A1944194519DE19DF1A1E1A1F1AA0-1AA61AA8-1AAD1B5A-1B601C3B-1C3F1C7E1C7F1CD32010-20272030-20432045-20512053-205E207D207E208D208E2329232A2768-277527C527C627E6-27EF2983-299829D8-29DB29FC29FD2CF9-2CFC2CFE2CFF2E00-2E2E2E302E313001-30033008-30113014-301F3030303D30A030FBA4FEA4FFA60D-A60FA673A67EA6F2-A6F7A874-A877A8CEA8CFA8F8-A8FAA92EA92FA95FA9C1-A9CDA9DEA9DFAA5C-AA5FAADEAADFABEBFD3EFD3FFE10-FE19FE30-FE52FE54-FE61FE63FE68FE6AFE6BFF01-FF03FF05-FF0AFF0C-FF0FFF1AFF1BFF1FFF20FF3B-FF3DFF3FFF5BFF5DFF5F-FF65",Pd:"002D058A05BE140018062010-20152E172E1A301C303030A0FE31FE32FE58FE63FF0D",Ps:"0028005B007B0F3A0F3C169B201A201E2045207D208D23292768276A276C276E27702772277427C527E627E827EA27EC27EE2983298529872989298B298D298F299129932995299729D829DA29FC2E222E242E262E283008300A300C300E3010301430163018301A301DFD3EFE17FE35FE37FE39FE3BFE3DFE3FFE41FE43FE47FE59FE5BFE5DFF08FF3BFF5BFF5FFF62",Pe:"0029005D007D0F3B0F3D169C2046207E208E232A2769276B276D276F27712773277527C627E727E927EB27ED27EF298429862988298A298C298E2990299229942996299829D929DB29FD2E232E252E272E293009300B300D300F3011301530173019301B301E301FFD3FFE18FE36FE38FE3AFE3CFE3EFE40FE42FE44FE48FE5AFE5CFE5EFF09FF3DFF5DFF60FF63",Pi:"00AB2018201B201C201F20392E022E042E092E0C2E1C2E20",Pf:"00BB2019201D203A2E032E052E0A2E0D2E1D2E21",Pc:"005F203F20402054FE33FE34FE4D-FE4FFF3F",Po:"0021-00230025-0027002A002C002E002F003A003B003F0040005C00A100B700BF037E0387055A-055F058905C005C305C605F305F40609060A060C060D061B061E061F066A-066D06D40700-070D07F7-07F90830-083E0964096509700DF40E4F0E5A0E5B0F04-0F120F850FD0-0FD4104A-104F10FB1361-1368166D166E16EB-16ED1735173617D4-17D617D8-17DA1800-18051807-180A1944194519DE19DF1A1E1A1F1AA0-1AA61AA8-1AAD1B5A-1B601C3B-1C3F1C7E1C7F1CD3201620172020-20272030-2038203B-203E2041-20432047-205120532055-205E2CF9-2CFC2CFE2CFF2E002E012E06-2E082E0B2E0E-2E162E182E192E1B2E1E2E1F2E2A-2E2E2E302E313001-3003303D30FBA4FEA4FFA60D-A60FA673A67EA6F2-A6F7A874-A877A8CEA8CFA8F8-A8FAA92EA92FA95FA9C1-A9CDA9DEA9DFAA5C-AA5FAADEAADFABEBFE10-FE16FE19FE30FE45FE46FE49-FE4CFE50-FE52FE54-FE57FE5F-FE61FE68FE6AFE6BFF01-FF03FF05-FF07FF0AFF0CFF0EFF0FFF1AFF1BFF1FFF20FF3CFF61FF64FF65",S:"0024002B003C-003E005E0060007C007E00A2-00A900AC00AE-00B100B400B600B800D700F702C2-02C502D2-02DF02E5-02EB02ED02EF-02FF03750384038503F604820606-0608060B060E060F06E906FD06FE07F609F209F309FA09FB0AF10B700BF3-0BFA0C7F0CF10CF20D790E3F0F01-0F030F13-0F170F1A-0F1F0F340F360F380FBE-0FC50FC7-0FCC0FCE0FCF0FD5-0FD8109E109F13601390-139917DB194019E0-19FF1B61-1B6A1B74-1B7C1FBD1FBF-1FC11FCD-1FCF1FDD-1FDF1FED-1FEF1FFD1FFE20442052207A-207C208A-208C20A0-20B8210021012103-21062108210921142116-2118211E-2123212521272129212E213A213B2140-2144214A-214D214F2190-2328232B-23E82400-24262440-244A249C-24E92500-26CD26CF-26E126E326E8-26FF2701-27042706-2709270C-27272729-274B274D274F-27522756-275E2761-276727942798-27AF27B1-27BE27C0-27C427C7-27CA27CC27D0-27E527F0-29822999-29D729DC-29FB29FE-2B4C2B50-2B592CE5-2CEA2E80-2E992E9B-2EF32F00-2FD52FF0-2FFB300430123013302030363037303E303F309B309C319031913196-319F31C0-31E33200-321E322A-32503260-327F328A-32B032C0-32FE3300-33FF4DC0-4DFFA490-A4C6A700-A716A720A721A789A78AA828-A82BA836-A839AA77-AA79FB29FDFCFDFDFE62FE64-FE66FE69FF04FF0BFF1C-FF1EFF3EFF40FF5CFF5EFFE0-FFE6FFE8-FFEEFFFCFFFD",Sm:"002B003C-003E007C007E00AC00B100D700F703F60606-060820442052207A-207C208A-208C2140-2144214B2190-2194219A219B21A021A321A621AE21CE21CF21D221D421F4-22FF2308-230B23202321237C239B-23B323DC-23E125B725C125F8-25FF266F27C0-27C427C7-27CA27CC27D0-27E527F0-27FF2900-29822999-29D729DC-29FB29FE-2AFF2B30-2B442B47-2B4CFB29FE62FE64-FE66FF0BFF1C-FF1EFF5CFF5EFFE2FFE9-FFEC",Sc:"002400A2-00A5060B09F209F309FB0AF10BF90E3F17DB20A0-20B8A838FDFCFE69FF04FFE0FFE1FFE5FFE6",Sk:"005E006000A800AF00B400B802C2-02C502D2-02DF02E5-02EB02ED02EF-02FF0375038403851FBD1FBF-1FC11FCD-1FCF1FDD-1FDF1FED-1FEF1FFD1FFE309B309CA700-A716A720A721A789A78AFF3EFF40FFE3",So:"00A600A700A900AE00B000B60482060E060F06E906FD06FE07F609FA0B700BF3-0BF80BFA0C7F0CF10CF20D790F01-0F030F13-0F170F1A-0F1F0F340F360F380FBE-0FC50FC7-0FCC0FCE0FCF0FD5-0FD8109E109F13601390-1399194019E0-19FF1B61-1B6A1B74-1B7C210021012103-21062108210921142116-2118211E-2123212521272129212E213A213B214A214C214D214F2195-2199219C-219F21A121A221A421A521A7-21AD21AF-21CD21D021D121D321D5-21F32300-2307230C-231F2322-2328232B-237B237D-239A23B4-23DB23E2-23E82400-24262440-244A249C-24E92500-25B625B8-25C025C2-25F72600-266E2670-26CD26CF-26E126E326E8-26FF2701-27042706-2709270C-27272729-274B274D274F-27522756-275E2761-276727942798-27AF27B1-27BE2800-28FF2B00-2B2F2B452B462B50-2B592CE5-2CEA2E80-2E992E9B-2EF32F00-2FD52FF0-2FFB300430123013302030363037303E303F319031913196-319F31C0-31E33200-321E322A-32503260-327F328A-32B032C0-32FE3300-33FF4DC0-4DFFA490-A4C6A828-A82BA836A837A839AA77-AA79FDFDFFE4FFE8FFEDFFEEFFFCFFFD",Z:"002000A01680180E2000-200A20282029202F205F3000",Zs:"002000A01680180E2000-200A202F205F3000",Zl:"2028",Zp:"2029",C:"0000-001F007F-009F00AD03780379037F-0383038B038D03A20526-05300557055805600588058B-059005C8-05CF05EB-05EF05F5-0605061C061D0620065F06DD070E070F074B074C07B2-07BF07FB-07FF082E082F083F-08FF093A093B094F095609570973-097809800984098D098E0991099209A909B109B3-09B509BA09BB09C509C609C909CA09CF-09D609D8-09DB09DE09E409E509FC-0A000A040A0B-0A0E0A110A120A290A310A340A370A3A0A3B0A3D0A43-0A460A490A4A0A4E-0A500A52-0A580A5D0A5F-0A650A76-0A800A840A8E0A920AA90AB10AB40ABA0ABB0AC60ACA0ACE0ACF0AD1-0ADF0AE40AE50AF00AF2-0B000B040B0D0B0E0B110B120B290B310B340B3A0B3B0B450B460B490B4A0B4E-0B550B58-0B5B0B5E0B640B650B72-0B810B840B8B-0B8D0B910B96-0B980B9B0B9D0BA0-0BA20BA5-0BA70BAB-0BAD0BBA-0BBD0BC3-0BC50BC90BCE0BCF0BD1-0BD60BD8-0BE50BFB-0C000C040C0D0C110C290C340C3A-0C3C0C450C490C4E-0C540C570C5A-0C5F0C640C650C70-0C770C800C810C840C8D0C910CA90CB40CBA0CBB0CC50CC90CCE-0CD40CD7-0CDD0CDF0CE40CE50CF00CF3-0D010D040D0D0D110D290D3A-0D3C0D450D490D4E-0D560D58-0D5F0D640D650D76-0D780D800D810D840D97-0D990DB20DBC0DBE0DBF0DC7-0DC90DCB-0DCE0DD50DD70DE0-0DF10DF5-0E000E3B-0E3E0E5C-0E800E830E850E860E890E8B0E8C0E8E-0E930E980EA00EA40EA60EA80EA90EAC0EBA0EBE0EBF0EC50EC70ECE0ECF0EDA0EDB0EDE-0EFF0F480F6D-0F700F8C-0F8F0F980FBD0FCD0FD9-0FFF10C6-10CF10FD-10FF1249124E124F12571259125E125F1289128E128F12B112B612B712BF12C112C612C712D7131113161317135B-135E137D-137F139A-139F13F5-13FF169D-169F16F1-16FF170D1715-171F1737-173F1754-175F176D17711774-177F17B417B517DE17DF17EA-17EF17FA-17FF180F181A-181F1878-187F18AB-18AF18F6-18FF191D-191F192C-192F193C-193F1941-1943196E196F1975-197F19AC-19AF19CA-19CF19DB-19DD1A1C1A1D1A5F1A7D1A7E1A8A-1A8F1A9A-1A9F1AAE-1AFF1B4C-1B4F1B7D-1B7F1BAB-1BAD1BBA-1BFF1C38-1C3A1C4A-1C4C1C80-1CCF1CF3-1CFF1DE7-1DFC1F161F171F1E1F1F1F461F471F4E1F4F1F581F5A1F5C1F5E1F7E1F7F1FB51FC51FD41FD51FDC1FF01FF11FF51FFF200B-200F202A-202E2060-206F20722073208F2095-209F20B9-20CF20F1-20FF218A-218F23E9-23FF2427-243F244B-245F26CE26E226E4-26E727002705270A270B2728274C274E2753-2755275F27602795-279727B027BF27CB27CD-27CF2B4D-2B4F2B5A-2BFF2C2F2C5F2CF2-2CF82D26-2D2F2D66-2D6E2D70-2D7F2D97-2D9F2DA72DAF2DB72DBF2DC72DCF2DD72DDF2E32-2E7F2E9A2EF4-2EFF2FD6-2FEF2FFC-2FFF3040309730983100-3104312E-3130318F31B8-31BF31E4-31EF321F32FF4DB6-4DBF9FCC-9FFFA48D-A48FA4C7-A4CFA62C-A63FA660A661A674-A67BA698-A69FA6F8-A6FFA78D-A7FAA82C-A82FA83A-A83FA878-A87FA8C5-A8CDA8DA-A8DFA8FC-A8FFA954-A95EA97D-A97FA9CEA9DA-A9DDA9E0-A9FFAA37-AA3FAA4EAA4FAA5AAA5BAA7C-AA7FAAC3-AADAAAE0-ABBFABEEABEFABFA-ABFFD7A4-D7AFD7C7-D7CAD7FC-F8FFFA2EFA2FFA6EFA6FFADA-FAFFFB07-FB12FB18-FB1CFB37FB3DFB3FFB42FB45FBB2-FBD2FD40-FD4FFD90FD91FDC8-FDEFFDFEFDFFFE1A-FE1FFE27-FE2FFE53FE67FE6C-FE6FFE75FEFD-FF00FFBF-FFC1FFC8FFC9FFD0FFD1FFD8FFD9FFDD-FFDFFFE7FFEF-FFFBFFFEFFFF",Cc:"0000-001F007F-009F",Cf:"00AD0600-060306DD070F17B417B5200B-200F202A-202E2060-2064206A-206FFEFFFFF9-FFFB",Co:"E000-F8FF",Cs:"D800-DFFF",Cn:"03780379037F-0383038B038D03A20526-05300557055805600588058B-059005C8-05CF05EB-05EF05F5-05FF06040605061C061D0620065F070E074B074C07B2-07BF07FB-07FF082E082F083F-08FF093A093B094F095609570973-097809800984098D098E0991099209A909B109B3-09B509BA09BB09C509C609C909CA09CF-09D609D8-09DB09DE09E409E509FC-0A000A040A0B-0A0E0A110A120A290A310A340A370A3A0A3B0A3D0A43-0A460A490A4A0A4E-0A500A52-0A580A5D0A5F-0A650A76-0A800A840A8E0A920AA90AB10AB40ABA0ABB0AC60ACA0ACE0ACF0AD1-0ADF0AE40AE50AF00AF2-0B000B040B0D0B0E0B110B120B290B310B340B3A0B3B0B450B460B490B4A0B4E-0B550B58-0B5B0B5E0B640B650B72-0B810B840B8B-0B8D0B910B96-0B980B9B0B9D0BA0-0BA20BA5-0BA70BAB-0BAD0BBA-0BBD0BC3-0BC50BC90BCE0BCF0BD1-0BD60BD8-0BE50BFB-0C000C040C0D0C110C290C340C3A-0C3C0C450C490C4E-0C540C570C5A-0C5F0C640C650C70-0C770C800C810C840C8D0C910CA90CB40CBA0CBB0CC50CC90CCE-0CD40CD7-0CDD0CDF0CE40CE50CF00CF3-0D010D040D0D0D110D290D3A-0D3C0D450D490D4E-0D560D58-0D5F0D640D650D76-0D780D800D810D840D97-0D990DB20DBC0DBE0DBF0DC7-0DC90DCB-0DCE0DD50DD70DE0-0DF10DF5-0E000E3B-0E3E0E5C-0E800E830E850E860E890E8B0E8C0E8E-0E930E980EA00EA40EA60EA80EA90EAC0EBA0EBE0EBF0EC50EC70ECE0ECF0EDA0EDB0EDE-0EFF0F480F6D-0F700F8C-0F8F0F980FBD0FCD0FD9-0FFF10C6-10CF10FD-10FF1249124E124F12571259125E125F1289128E128F12B112B612B712BF12C112C612C712D7131113161317135B-135E137D-137F139A-139F13F5-13FF169D-169F16F1-16FF170D1715-171F1737-173F1754-175F176D17711774-177F17DE17DF17EA-17EF17FA-17FF180F181A-181F1878-187F18AB-18AF18F6-18FF191D-191F192C-192F193C-193F1941-1943196E196F1975-197F19AC-19AF19CA-19CF19DB-19DD1A1C1A1D1A5F1A7D1A7E1A8A-1A8F1A9A-1A9F1AAE-1AFF1B4C-1B4F1B7D-1B7F1BAB-1BAD1BBA-1BFF1C38-1C3A1C4A-1C4C1C80-1CCF1CF3-1CFF1DE7-1DFC1F161F171F1E1F1F1F461F471F4E1F4F1F581F5A1F5C1F5E1F7E1F7F1FB51FC51FD41FD51FDC1FF01FF11FF51FFF2065-206920722073208F2095-209F20B9-20CF20F1-20FF218A-218F23E9-23FF2427-243F244B-245F26CE26E226E4-26E727002705270A270B2728274C274E2753-2755275F27602795-279727B027BF27CB27CD-27CF2B4D-2B4F2B5A-2BFF2C2F2C5F2CF2-2CF82D26-2D2F2D66-2D6E2D70-2D7F2D97-2D9F2DA72DAF2DB72DBF2DC72DCF2DD72DDF2E32-2E7F2E9A2EF4-2EFF2FD6-2FEF2FFC-2FFF3040309730983100-3104312E-3130318F31B8-31BF31E4-31EF321F32FF4DB6-4DBF9FCC-9FFFA48D-A48FA4C7-A4CFA62C-A63FA660A661A674-A67BA698-A69FA6F8-A6FFA78D-A7FAA82C-A82FA83A-A83FA878-A87FA8C5-A8CDA8DA-A8DFA8FC-A8FFA954-A95EA97D-A97FA9CEA9DA-A9DDA9E0-A9FFAA37-AA3FAA4EAA4FAA5AAA5BAA7C-AA7FAAC3-AADAAAE0-ABBFABEEABEFABFA-ABFFD7A4-D7AFD7C7-D7CAD7FC-D7FFFA2EFA2FFA6EFA6FFADA-FAFFFB07-FB12FB18-FB1CFB37FB3DFB3FFB42FB45FBB2-FBD2FD40-FD4FFD90FD91FDC8-FDEFFDFEFDFFFE1A-FE1FFE27-FE2FFE53FE67FE6C-FE6FFE75FEFDFEFEFF00FFBF-FFC1FFC8FFC9FFD0FFD1FFD8FFD9FFDD-FFDFFFE7FFEF-FFF8FFFEFFFF"})}),ace.define("ace/token_iterator",["require","exports","module"],function(e,t,n){"use strict";var r=function(e,t,n){this.$session=e,this.$row=t,this.$rowTokens=e.getTokens(t);var r=e.getTokenAt(t,n);this.$tokenIndex=r?r.index:-1};(function(){this.stepBackward=function(){this.$tokenIndex-=1;while(this.$tokenIndex<0){this.$row-=1;if(this.$row<0)return this.$row=0,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=this.$rowTokens.length-1}return this.$rowTokens[this.$tokenIndex]},this.stepForward=function(){this.$tokenIndex+=1;var e;while(this.$tokenIndex>=this.$rowTokens.length){this.$row+=1,e||(e=this.$session.getLength());if(this.$row>=e)return this.$row=e-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},this.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},this.getCurrentTokenRow=function(){return this.$row},this.getCurrentTokenColumn=function(){var e=this.$rowTokens,t=this.$tokenIndex,n=e[t].start;if(n!==undefined)return n;n=0;while(t>0)t-=1,n+=e[t].value.length;return n}}).call(r.prototype),t.TokenIterator=r}),ace.define("ace/mode/text",["require","exports","module","ace/tokenizer","ace/mode/text_highlight_rules","ace/mode/behaviour","ace/unicode","ace/lib/lang","ace/token_iterator","ace/range"],function(e,t,n){"use strict";var r=e("../tokenizer").Tokenizer,i=e("./text_highlight_rules").TextHighlightRules,s=e("./behaviour").Behaviour,o=e("../unicode"),u=e("../lib/lang"),a=e("../token_iterator").TokenIterator,f=e("../range").Range,l=function(){this.HighlightRules=i,this.$behaviour=new s};(function(){this.tokenRe=new RegExp("^["+o.packages.L+o.packages.Mn+o.packages.Mc+o.packages.Nd+o.packages.Pc+"\\$_]+","g"),this.nonTokenRe=new RegExp("^(?:[^"+o.packages.L+o.packages.Mn+o.packages.Mc+o.packages.Nd+o.packages.Pc+"\\$_]|\\s])+","g"),this.getTokenizer=function(){return this.$tokenizer||(this.$highlightRules=this.$highlightRules||new this.HighlightRules,this.$tokenizer=new r(this.$highlightRules.getRules())),this.$tokenizer},this.lineCommentStart="",this.blockComment="",this.toggleCommentLines=function(e,t,n,r){function w(e){for(var t=n;t<=r;t++)e(i.getLine(t),t)}var i=t.doc,s=!0,o=!0,a=Infinity,f=t.getTabSize(),l=!1;if(!this.lineCommentStart){if(!this.blockComment)return!1;var c=this.blockComment.start,h=this.blockComment.end,p=new RegExp("^(\\s*)(?:"+u.escapeRegExp(c)+")"),d=new RegExp("(?:"+u.escapeRegExp(h)+")\\s*$"),v=function(e,t){if(g(e,t))return;if(!s||/\S/.test(e))i.insertInLine({row:t,column:e.length},h),i.insertInLine({row:t,column:a},c)},m=function(e,t){var n;(n=e.match(d))&&i.removeInLine(t,e.length-n[0].length,e.length),(n=e.match(p))&&i.removeInLine(t,n[1].length,n[0].length)},g=function(e,n){if(p.test(e))return!0;var r=t.getTokens(n);for(var i=0;i<r.length;i++)if(r[i].type==="comment")return!0}}else{if(Array.isArray(this.lineCommentStart))var p=this.lineCommentStart.map(u.escapeRegExp).join("|"),c=this.lineCommentStart[0];else var p=u.escapeRegExp(this.lineCommentStart),c=this.lineCommentStart;p=new RegExp("^(\\s*)(?:"+p+") ?"),l=t.getUseSoftTabs();var m=function(e,t){var n=e.match(p);if(!n)return;var r=n[1].length,s=n[0].length;!b(e,r,s)&&n[0][s-1]==" "&&s--,i.removeInLine(t,r,s)},y=c+" ",v=function(e,t){if(!s||/\S/.test(e))b(e,a,a)?i.insertInLine({row:t,column:a},y):i.insertInLine({row:t,column:a},c)},g=function(e,t){return p.test(e)},b=function(e,t,n){var r=0;while(t--&&e.charAt(t)==" ")r++;if(r%f!=0)return!1;var r=0;while(e.charAt(n++)==" ")r++;return f>2?r%f!=f-1:r%f==0}}var E=Infinity;w(function(e,t){var n=e.search(/\S/);n!==-1?(n<a&&(a=n),o&&!g(e,t)&&(o=!1)):E>e.length&&(E=e.length)}),a==Infinity&&(a=E,s=!1,o=!1),l&&a%f!=0&&(a=Math.floor(a/f)*f),w(o?m:v)},this.toggleBlockComment=function(e,t,n,r){var i=this.blockComment;if(!i)return;!i.start&&i[0]&&(i=i[0]);var s=new a(t,r.row,r.column),o=s.getCurrentToken(),u=t.selection,l=t.selection.toOrientedRange(),c,h;if(o&&/comment/.test(o.type)){var p,d;while(o&&/comment/.test(o.type)){var v=o.value.indexOf(i.start);if(v!=-1){var m=s.getCurrentTokenRow(),g=s.getCurrentTokenColumn()+v;p=new f(m,g,m,g+i.start.length);break}o=s.stepBackward()}var s=new a(t,r.row,r.column),o=s.getCurrentToken();while(o&&/comment/.test(o.type)){var v=o.value.indexOf(i.end);if(v!=-1){var m=s.getCurrentTokenRow(),g=s.getCurrentTokenColumn()+v;d=new f(m,g,m,g+i.end.length);break}o=s.stepForward()}d&&t.remove(d),p&&(t.remove(p),c=p.start.row,h=-i.start.length)}else h=i.start.length,c=n.start.row,t.insert(n.end,i.end),t.insert(n.start,i.start);l.start.row==c&&(l.start.column+=h),l.end.row==c&&(l.end.column+=h),t.selection.fromOrientedRange(l)},this.getNextLineIndent=function(e,t,n){return this.$getIndent(t)},this.checkOutdent=function(e,t,n){return!1},this.autoOutdent=function(e,t,n){},this.$getIndent=function(e){return e.match(/^\s*/)[0]},this.createWorker=function(e){return null},this.createModeDelegates=function(e){this.$embeds=[],this.$modes={};for(var t in e)e[t]&&(this.$embeds.push(t),this.$modes[t]=new e[t]);var n=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"];for(var t=0;t<n.length;t++)(function(e){var r=n[t],i=e[r];e[n[t]]=function(){return this.$delegator(r,arguments,i)}})(this)},this.$delegator=function(e,t,n){var r=t[0];typeof r!="string"&&(r=r[0]);for(var i=0;i<this.$embeds.length;i++){if(!this.$modes[this.$embeds[i]])continue;var s=r.split(this.$embeds[i]);if(!s[0]&&s[1]){t[0]=s[1];var o=this.$modes[this.$embeds[i]];return o[e].apply(o,t)}}var u=n.apply(this,t);return n?u:undefined},this.transformAction=function(e,t,n,r,i){if(this.$behaviour){var s=this.$behaviour.getBehaviours();for(var o in s)if(s[o][t]){var u=s[o][t].apply(this,arguments);if(u)return u}}},this.getKeywords=function(e){if(!this.completionKeywords){var t=this.$tokenizer.rules,n=[];for(var r in t){var i=t[r];for(var s=0,o=i.length;s<o;s++)if(typeof i[s].token=="string")/keyword|support|storage/.test(i[s].token)&&n.push(i[s].regex);else if(typeof i[s].token=="object")for(var u=0,a=i[s].token.length;u<a;u++)if(/keyword|support|storage/.test(i[s].token[u])){var r=i[s].regex.match(/\(.+?\)/g)[u];n.push(r.substr(1,r.length-2))}}this.completionKeywords=n}return e?n.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(e,t,n,r){var i=this.$keywordList||this.$createKeywordList();return i.map(function(e){return{name:e,value:e,score:0,meta:"keyword"}})},this.$id="ace/mode/text"}).call(l.prototype),t.Mode=l}),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=t.Anchor=function(e,t,n){this.$onChange=this.onChange.bind(this),this.attach(e),typeof n=="undefined"?this.setPosition(t.row,t.column):this.setPosition(t,n)};(function(){r.implement(this,i),this.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},this.getDocument=function(){return this.document},this.$insertRight=!1,this.onChange=function(e){var t=e.data,n=t.range;if(n.start.row==n.end.row&&n.start.row!=this.row)return;if(n.start.row>this.row)return;if(n.start.row==this.row&&n.start.column>this.column)return;var r=this.row,i=this.column,s=n.start,o=n.end;if(t.action==="insertText")if(s.row===r&&s.column<=i){if(s.column!==i||!this.$insertRight)s.row===o.row?i+=o.column-s.column:(i-=s.column,r+=o.row-s.row)}else s.row!==o.row&&s.row<r&&(r+=o.row-s.row);else t.action==="insertLines"?(s.row!==r||i!==0||!this.$insertRight)&&s.row<=r&&(r+=o.row-s.row):t.action==="removeText"?s.row===r&&s.column<i?o.column>=i?i=s.column:i=Math.max(0,i-(o.column-s.column)):s.row!==o.row&&s.row<r?(o.row===r&&(i=Math.max(0,i-o.column)+s.column),r-=o.row-s.row):o.row===r&&(r-=o.row-s.row,i=Math.max(0,i-o.column)+s.column):t.action=="removeLines"&&s.row<=r&&(o.row<=r?r-=o.row-s.row:(r=s.row,i=0));this.setPosition(r,i,!0)},this.setPosition=function(e,t,n){var r;n?r={row:e,column:t}:r=this.$clipPositionToDocument(e,t);if(this.row==r.row&&this.column==r.column)return;var i={row:this.row,column:this.column};this.row=r.row,this.column=r.column,this._signal("change",{old:i,value:r})},this.detach=function(){this.document.removeEventListener("change",this.$onChange)},this.attach=function(e){this.document=e||this.document,this.document.on("change",this.$onChange)},this.$clipPositionToDocument=function(e,t){var n={};return e>=this.document.getLength()?(n.row=Math.max(0,this.document.getLength()-1),n.column=this.document.getLine(n.row).length):e<0?(n.row=0,n.column=0):(n.row=e,n.column=Math.min(this.document.getLine(n.row).length,Math.max(0,t))),t<0&&(n.column=0),n}}).call(s.prototype)}),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/range","ace/anchor"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=e("./range").Range,o=e("./anchor").Anchor,u=function(e){this.$lines=[],e.length===0?this.$lines=[""]:Array.isArray(e)?this._insertLines(0,e):this.insert({row:0,column:0},e)};(function(){r.implement(this,i),this.setValue=function(e){var t=this.getLength();this.remove(new s(0,0,t,this.getLine(t-1).length)),this.insert({row:0,column:0},e)},this.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},this.createAnchor=function(e,t){return new o(this,e,t)},"aaa".split(/a/).length===0?this.$split=function(e){return e.replace(/\r\n|\r/g,"\n").split("\n")}:this.$split=function(e){return e.split(/\r\n|\r|\n/)},this.$detectNewLine=function(e){var t=e.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=t?t[1]:"\n",this._signal("changeNewLineMode")},this.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return"\r\n";case"unix":return"\n";default:return this.$autoNewLine||"\n"}},this.$autoNewLine="",this.$newLineMode="auto",this.setNewLineMode=function(e){if(this.$newLineMode===e)return;this.$newLineMode=e,this._signal("changeNewLineMode")},this.getNewLineMode=function(){return this.$newLineMode},this.isNewLine=function(e){return e=="\r\n"||e=="\r"||e=="\n"},this.getLine=function(e){return this.$lines[e]||""},this.getLines=function(e,t){return this.$lines.slice(e,t+1)},this.getAllLines=function(){return this.getLines(0,this.getLength())},this.getLength=function(){return this.$lines.length},this.getTextRange=function(e){if(e.start.row==e.end.row)return this.getLine(e.start.row).substring(e.start.column,e.end.column);var t=this.getLines(e.start.row,e.end.row);t[0]=(t[0]||"").substring(e.start.column);var n=t.length-1;return e.end.row-e.start.row==n&&(t[n]=t[n].substring(0,e.end.column)),t.join(this.getNewLineCharacter())},this.$clipPosition=function(e){var t=this.getLength();return e.row>=t?(e.row=Math.max(0,t-1),e.column=this.getLine(t-1).length):e.row<0&&(e.row=0),e},this.insert=function(e,t){if(!t||t.length===0)return e;e=this.$clipPosition(e),this.getLength()<=1&&this.$detectNewLine(t);var n=this.$split(t),r=n.splice(0,1)[0],i=n.length==0?null:n.splice(n.length-1,1)[0];return e=this.insertInLine(e,r),i!==null&&(e=this.insertNewLine(e),e=this._insertLines(e.row,n),e=this.insertInLine(e,i||"")),e},this.insertLines=function(e,t){return e>=this.getLength()?this.insert({row:e,column:0},"\n"+t.join("\n")):this._insertLines(Math.max(e,0),t)},this._insertLines=function(e,t){if(t.length==0)return{row:e,column:0};while(t.length>61440){var n=this._insertLines(e,t.slice(0,61440));t=t.slice(61440),e=n.row}var r=[e,0];r.push.apply(r,t),this.$lines.splice.apply(this.$lines,r);var i=new s(e,0,e+t.length,0),o={action:"insertLines",range:i,lines:t};return this._signal("change",{data:o}),i.end},this.insertNewLine=function(e){e=this.$clipPosition(e);var t=this.$lines[e.row]||"";this.$lines[e.row]=t.substring(0,e.column),this.$lines.splice(e.row+1,0,t.substring(e.column,t.length));var n={row:e.row+1,column:0},r={action:"insertText",range:s.fromPoints(e,n),text:this.getNewLineCharacter()};return this._signal("change",{data:r}),n},this.insertInLine=function(e,t){if(t.length==0)return e;var n=this.$lines[e.row]||"";this.$lines[e.row]=n.substring(0,e.column)+t+n.substring(e.column);var r={row:e.row,column:e.column+t.length},i={action:"insertText",range:s.fromPoints(e,r),text:t};return this._signal("change",{data:i}),r},this.remove=function(e){e instanceof s||(e=s.fromPoints(e.start,e.end)),e.start=this.$clipPosition(e.start),e.end=this.$clipPosition(e.end);if(e.isEmpty())return e.start;var t=e.start.row,n=e.end.row;if(e.isMultiLine()){var r=e.start.column==0?t:t+1,i=n-1;e.end.column>0&&this.removeInLine(n,0,e.end.column),i>=r&&this._removeLines(r,i),r!=t&&(this.removeInLine(t,e.start.column,this.getLine(t).length),this.removeNewLine(e.start.row))}else this.removeInLine(t,e.start.column,e.end.column);return e.start},this.removeInLine=function(e,t,n){if(t==n)return;var r=new s(e,t,e,n),i=this.getLine(e),o=i.substring(t,n),u=i.substring(0,t)+i.substring(n,i.length);this.$lines.splice(e,1,u);var a={action:"removeText",range:r,text:o};return this._signal("change",{data:a}),r.start},this.removeLines=function(e,t){return e<0||t>=this.getLength()?this.remove(new s(e,0,t+1,0)):this._removeLines(e,t)},this._removeLines=function(e,t){var n=new s(e,0,t+1,0),r=this.$lines.splice(e,t-e+1),i={action:"removeLines",range:n,nl:this.getNewLineCharacter(),lines:r};return this._signal("change",{data:i}),r},this.removeNewLine=function(e){var t=this.getLine(e),n=this.getLine(e+1),r=new s(e,t.length,e+1,0),i=t+n;this.$lines.splice(e,2,i);var o={action:"removeText",range:r,text:this.getNewLineCharacter()};this._signal("change",{data:o})},this.replace=function(e,t){e instanceof s||(e=s.fromPoints(e.start,e.end));if(t.length==0&&e.isEmpty())return e.start;if(t==this.getTextRange(e))return e.end;this.remove(e);if(t)var n=this.insert(e.start,t);else n=e.start;return n},this.applyDeltas=function(e){for(var t=0;t<e.length;t++){var n=e[t],r=s.fromPoints(n.range.start,n.range.end);n.action=="insertLines"?this.insertLines(r.start.row,n.lines):n.action=="insertText"?this.insert(r.start,n.text):n.action=="removeLines"?this._removeLines(r.start.row,r.end.row-1):n.action=="removeText"&&this.remove(r)}},this.revertDeltas=function(e){for(var t=e.length-1;t>=0;t--){var n=e[t],r=s.fromPoints(n.range.start,n.range.end);n.action=="insertLines"?this._removeLines(r.start.row,r.end.row-1):n.action=="insertText"?this.remove(r):n.action=="removeLines"?this._insertLines(r.start.row,n.lines):n.action=="removeText"&&this.insert(r.start,n.text)}},this.indexToPosition=function(e,t){var n=this.$lines||this.getAllLines(),r=this.getNewLineCharacter().length;for(var i=t||0,s=n.length;i<s;i++){e-=n[i].length+r;if(e<0)return{row:i,column:e+n[i].length+r}}return{row:s-1,column:n[s-1].length}},this.positionToIndex=function(e,t){var n=this.$lines||this.getAllLines(),r=this.getNewLineCharacter().length,i=0,s=Math.min(e.row,n.length);for(var o=t||0;o<s;++o)i+=n[o].length+r;return i+e.column}}).call(u.prototype),t.Document=u}),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=function(e,t){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=e;var n=this;this.$worker=function(){if(!n.running)return;var e=new Date,t=n.currentLine,r=-1,i=n.doc;while(n.lines[t])t++;var s=t,o=i.getLength(),u=0;n.running=!1;while(t<o){n.$tokenizeRow(t),r=t;do t++;while(n.lines[t]);u++;if(u%5===0&&new Date-e>20){n.running=setTimeout(n.$worker,20);break}}n.currentLine=t,s<=r&&n.fireUpdateEvent(s,r)}};(function(){r.implement(this,i),this.setTokenizer=function(e){this.tokenizer=e,this.lines=[],this.states=[],this.start(0)},this.setDocument=function(e){this.doc=e,this.lines=[],this.states=[],this.stop()},this.fireUpdateEvent=function(e,t){var n={first:e,last:t};this._signal("update",{data:n})},this.start=function(e){this.currentLine=Math.min(e||0,this.currentLine,this.doc.getLength()),this.lines.splice(this.currentLine,this.lines.length),this.states.splice(this.currentLine,this.states.length),this.stop(),this.running=setTimeout(this.$worker,700)},this.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},this.$updateOnChange=function(e){var t=e.range,n=t.start.row,r=t.end.row-n;if(r===0)this.lines[n]=null;else if(e.action=="removeText"||e.action=="removeLines")this.lines.splice(n,r+1,null),this.states.splice(n,r+1,null);else{var i=Array(r+1);i.unshift(n,1),this.lines.splice.apply(this.lines,i),this.states.splice.apply(this.states,i)}this.currentLine=Math.min(n,this.currentLine,this.doc.getLength()),this.stop()},this.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},this.getTokens=function(e){return this.lines[e]||this.$tokenizeRow(e)},this.getState=function(e){return this.currentLine==e&&this.$tokenizeRow(e),this.states[e]||"start"},this.$tokenizeRow=function(e){var t=this.doc.getLine(e),n=this.states[e-1],r=this.tokenizer.getLineTokens(t,n,e);return this.states[e]+""!=r.state+""?(this.states[e]=r.state,this.lines[e+1]=null,this.currentLine>e+1&&(this.currentLine=e+1)):this.currentLine==e&&(this.currentLine=e+1),this.lines[e]=r.tokens}}).call(s.prototype),t.BackgroundTokenizer=s}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(e,t,n){"use strict";var r=e("./lib/lang"),i=e("./lib/oop"),s=e("./range").Range,o=function(e,t,n){this.setRegexp(e),this.clazz=t,this.type=n||"text"};(function(){this.MAX_RANGES=500,this.setRegexp=function(e){if(this.regExp+""==e+"")return;this.regExp=e,this.cache=[]},this.update=function(e,t,n,i){if(!this.regExp)return;var o=i.firstRow,u=i.lastRow;for(var a=o;a<=u;a++){var f=this.cache[a];f==null&&(f=r.getMatchOffsets(n.getLine(a),this.regExp),f.length>this.MAX_RANGES&&(f=f.slice(0,this.MAX_RANGES)),f=f.map(function(e){return new s(a,e.offset,a,e.offset+e.length)}),this.cache[a]=f.length?f:"");for(var l=f.length;l--;)t.drawSingleLineMarker(e,f[l].toScreenRange(n),this.clazz,i)}}}).call(o.prototype),t.SearchHighlight=o}),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(e,t,n){"use strict";function i(e,t){this.foldData=e,Array.isArray(t)?this.folds=t:t=this.folds=[t];var n=t[t.length-1];this.range=new r(t[0].start.row,t[0].start.column,n.end.row,n.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach(function(e){e.setFoldLine(this)},this)}var r=e("../range").Range;(function(){this.shiftRow=function(e){this.start.row+=e,this.end.row+=e,this.folds.forEach(function(t){t.start.row+=e,t.end.row+=e})},this.addFold=function(e){if(e.sameRow){if(e.start.row<this.startRow||e.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(e),this.folds.sort(function(e,t){return-e.range.compareEnd(t.start.row,t.start.column)}),this.range.compareEnd(e.start.row,e.start.column)>0?(this.end.row=e.end.row,this.end.column=e.end.column):this.range.compareStart(e.end.row,e.end.column)<0&&(this.start.row=e.start.row,this.start.column=e.start.column)}else if(e.start.row==this.end.row)this.folds.push(e),this.end.row=e.end.row,this.end.column=e.end.column;else{if(e.end.row!=this.start.row)throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");this.folds.unshift(e),this.start.row=e.start.row,this.start.column=e.start.column}e.foldLine=this},this.containsRow=function(e){return e>=this.start.row&&e<=this.end.row},this.walk=function(e,t,n){var r=0,i=this.folds,s,o,u,a=!0;t==null&&(t=this.end.row,n=this.end.column);for(var f=0;f<i.length;f++){s=i[f],o=s.range.compareStart(t,n);if(o==-1){e(null,t,n,r,a);return}u=e(null,s.start.row,s.start.column,r,a),u=!u&&e(s.placeholder,s.start.row,s.start.column,r);if(u||o===0)return;a=!s.sameRow,r=s.end.column}e(null,t,n,r,a)},this.getNextFoldTo=function(e,t){var n,r;for(var i=0;i<this.folds.length;i++){n=this.folds[i],r=n.range.compareEnd(e,t);if(r==-1)return{fold:n,kind:"after"};if(r===0)return{fold:n,kind:"inside"}}return null},this.addRemoveChars=function(e,t,n){var r=this.getNextFoldTo(e,t),i,s;if(r){i=r.fold;if(r.kind=="inside"&&i.start.column!=t&&i.start.row!=e)window.console&&window.console.log(e,t,i);else if(i.start.row==e){s=this.folds;var o=s.indexOf(i);o===0&&(this.start.column+=n);for(o;o<s.length;o++){i=s[o],i.start.column+=n;if(!i.sameRow)return;i.end.column+=n}this.end.column+=n}}},this.split=function(e,t){var n=this.getNextFoldTo(e,t);if(!n||n.kind=="inside")return null;var r=n.fold,s=this.folds,o=this.foldData,u=s.indexOf(r),a=s[u-1];this.end.row=a.end.row,this.end.column=a.end.column,s=s.splice(u,s.length-u);var f=new i(o,s);return o.splice(o.indexOf(this)+1,0,f),f},this.merge=function(e){var t=e.folds;for(var n=0;n<t.length;n++)this.addFold(t[n]);var r=this.foldData;r.splice(r.indexOf(e),1)},this.toString=function(){var e=[this.range.toString()+": ["];return this.folds.forEach(function(t){e.push(" "+t.toString())}),e.push("]"),e.join("\n")},this.idxToPosition=function(e){var t=0;for(var n=0;n<this.folds.length;n++){var r=this.folds[n];e-=r.start.column-t;if(e<0)return{row:r.start.row,column:r.start.column+e};e-=r.placeholder.length;if(e<0)return r.start;t=r.end.column}return{row:this.end.row,column:this.end.column+e}}}).call(i.prototype),t.FoldLine=i}),ace.define("ace/range_list",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("./range").Range,i=r.comparePoints,s=function(){this.ranges=[]};(function(){this.comparePoints=i,this.pointIndex=function(e,t,n){var r=this.ranges;for(var s=n||0;s<r.length;s++){var o=r[s],u=i(e,o.end);if(u>0)continue;var a=i(e,o.start);return u===0?t&&a!==0?-s-2:s:a>0||a===0&&!t?s:-s-1}return-s-1},this.add=function(e){var t=!e.isEmpty(),n=this.pointIndex(e.start,t);n<0&&(n=-n-1);var r=this.pointIndex(e.end,t,n);return r<0?r=-r-1:r++,this.ranges.splice(n,r-n,e)},this.addList=function(e){var t=[];for(var n=e.length;n--;)t.push.call(t,this.add(e[n]));return t},this.substractPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges.splice(t,1)},this.merge=function(){var e=[],t=this.ranges;t=t.sort(function(e,t){return i(e.start,t.start)});var n=t[0],r;for(var s=1;s<t.length;s++){r=n,n=t[s];var o=i(r.end,n.start);if(o<0)continue;if(o==0&&!r.isEmpty()&&!n.isEmpty())continue;i(r.end,n.end)<0&&(r.end.row=n.end.row,r.end.column=n.end.column),t.splice(s,1),e.push(n),n=r,s--}return this.ranges=t,e},this.contains=function(e,t){return this.pointIndex({row:e,column:t})>=0},this.containsPoint=function(e){return this.pointIndex(e)>=0},this.rangeAtPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges[t]},this.clipRows=function(e,t){var n=this.ranges;if(n[0].start.row>t||n[n.length-1].start.row<e)return[];var r=this.pointIndex({row:e,column:0});r<0&&(r=-r-1);var i=this.pointIndex({row:t,column:0},r);i<0&&(i=-i-1);var s=[];for(var o=r;o<i;o++)s.push(n[o]);return s},this.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},this.attach=function(e){this.session&&this.detach(),this.session=e,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},this.detach=function(){if(!this.session)return;this.session.removeListener("change",this.onChange),this.session=null},this.$onChange=function(e){var t=e.data.range;if(e.data.action[0]=="i")var n=t.start,r=t.end;else var r=t.start,n=t.end;var i=n.row,s=r.row,o=s-i,u=-n.column+r.column,a=this.ranges;for(var f=0,l=a.length;f<l;f++){var c=a[f];if(c.end.row<i)continue;if(c.start.row>i)break;c.start.row==i&&c.start.column>=n.column&&(c.start.column!=n.column||!this.$insertRight)&&(c.start.column+=u,c.start.row+=o);if(c.end.row==i&&c.end.column>=n.column){if(c.end.column==n.column&&this.$insertRight)continue;c.end.column==n.column&&u>0&&f<l-1&&c.end.column>c.start.column&&c.end.column==a[f+1].start.column&&(c.end.column-=u),c.end.column+=u,c.end.row+=o}}if(o!=0&&f<l)for(;f<l;f++){var c=a[f];c.start.row+=o,c.end.row+=o}}}).call(s.prototype),t.RangeList=s}),ace.define("ace/edit_session/fold",["require","exports","module","ace/range","ace/range_list","ace/lib/oop"],function(e,t,n){"use strict";function u(e,t){e.row-=t.row,e.row==0&&(e.column-=t.column)}function a(e,t){u(e.start,t),u(e.end,t)}function f(e,t){e.row==0&&(e.column+=t.column),e.row+=t.row}function l(e,t){f(e.start,t),f(e.end,t)}var r=e("../range").Range,i=e("../range_list").RangeList,s=e("../lib/oop"),o=t.Fold=function(e,t){this.foldLine=null,this.placeholder=t,this.range=e,this.start=e.start,this.end=e.end,this.sameRow=e.start.row==e.end.row,this.subFolds=this.ranges=[]};s.inherits(o,i),function(){this.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},this.setFoldLine=function(e){this.foldLine=e,this.subFolds.forEach(function(t){t.setFoldLine(e)})},this.clone=function(){var e=this.range.clone(),t=new o(e,this.placeholder);return this.subFolds.forEach(function(e){t.subFolds.push(e.clone())}),t.collapseChildren=this.collapseChildren,t},this.addSubFold=function(e){if(this.range.isEqual(e))return;if(!this.range.containsRange(e))throw new Error("A fold can't intersect already existing fold"+e.range+this.range);a(e,this.start);var t=e.start.row,n=e.start.column;for(var r=0,i=-1;r<this.subFolds.length;r++){i=this.subFolds[r].range.compare(t,n);if(i!=1)break}var s=this.subFolds[r];if(i==0)return s.addSubFold(e);var t=e.range.end.row,n=e.range.end.column;for(var o=r,i=-1;o<this.subFolds.length;o++){i=this.subFolds[o].range.compare(t,n);if(i!=1)break}var u=this.subFolds[o];if(i==0)throw new Error("A fold can't intersect already existing fold"+e.range+this.range);var f=this.subFolds.splice(r,o-r,e);return e.setFoldLine(this.foldLine),e},this.restoreRange=function(e){return l(e,this.start)}}.call(o.prototype)}),ace.define("ace/edit_session/folding",["require","exports","module","ace/range","ace/edit_session/fold_line","ace/edit_session/fold","ace/token_iterator"],function(e,t,n){"use strict";function u(){this.getFoldAt=function(e,t,n){var r=this.getFoldLine(e);if(!r)return null;var i=r.folds;for(var s=0;s<i.length;s++){var o=i[s];if(o.range.contains(e,t)){if(n==1&&o.range.isEnd(e,t))continue;if(n==-1&&o.range.isStart(e,t))continue;return o}}},this.getFoldsInRange=function(e){var t=e.start,n=e.end,r=this.$foldData,i=[];t.column+=1,n.column-=1;for(var s=0;s<r.length;s++){var o=r[s].range.compareRange(e);if(o==2)continue;if(o==-2)break;var u=r[s].folds;for(var a=0;a<u.length;a++){var f=u[a];o=f.range.compareRange(e);if(o==-2)break;if(o==2)continue;if(o==42)break;i.push(f)}}return t.column-=1,n.column+=1,i},this.getFoldsInRangeList=function(e){if(Array.isArray(e)){var t=[];e.forEach(function(e){t=t.concat(this.getFoldsInRange(e))},this)}else var t=this.getFoldsInRange(e);return t},this.getAllFolds=function(){var e=[],t=this.$foldData;for(var n=0;n<t.length;n++)for(var r=0;r<t[n].folds.length;r++)e.push(t[n].folds[r]);return e},this.getFoldStringAt=function(e,t,n,r){r=r||this.getFoldLine(e);if(!r)return null;var i={end:{column:0}},s,o;for(var u=0;u<r.folds.length;u++){o=r.folds[u];var a=o.range.compareEnd(e,t);if(a==-1){s=this.getLine(o.start.row).substring(i.end.column,o.start.column);break}if(a===0)return null;i=o}return s||(s=this.getLine(o.start.row).substring(i.end.column)),n==-1?s.substring(0,t-i.end.column):n==1?s.substring(t-i.end.column):s},this.getFoldLine=function(e,t){var n=this.$foldData,r=0;t&&(r=n.indexOf(t)),r==-1&&(r=0);for(r;r<n.length;r++){var i=n[r];if(i.start.row<=e&&i.end.row>=e)return i;if(i.end.row>e)return null}return null},this.getNextFoldLine=function(e,t){var n=this.$foldData,r=0;t&&(r=n.indexOf(t)),r==-1&&(r=0);for(r;r<n.length;r++){var i=n[r];if(i.end.row>=e)return i}return null},this.getFoldedRowCount=function(e,t){var n=this.$foldData,r=t-e+1;for(var i=0;i<n.length;i++){var s=n[i],o=s.end.row,u=s.start.row;if(o>=t){u<t&&(u>=e?r-=t-u:r=0);break}o>=e&&(u>=e?r-=o-u:r-=o-e+1)}return r},this.$addFoldLine=function(e){return this.$foldData.push(e),this.$foldData.sort(function(e,t){return e.start.row-t.start.row}),e},this.addFold=function(e,t){var n=this.$foldData,r=!1,o;e instanceof s?o=e:(o=new s(t,e),o.collapseChildren=t.collapseChildren),this.$clipRangeToDocument(o.range);var u=o.start.row,a=o.start.column,f=o.end.row,l=o.end.column;if(u<f||u==f&&a<=l-2){var c=this.getFoldAt(u,a,1),h=this.getFoldAt(f,l,-1);if(c&&h==c)return c.addSubFold(o);c&&!c.range.isStart(u,a)&&this.removeFold(c),h&&!h.range.isEnd(f,l)&&this.removeFold(h);var p=this.getFoldsInRange(o.range);p.length>0&&(this.removeFolds(p),p.forEach(function(e){o.addSubFold(e)}));for(var d=0;d<n.length;d++){var v=n[d];if(f==v.start.row){v.addFold(o),r=!0;break}if(u==v.end.row){v.addFold(o),r=!0;if(!o.sameRow){var m=n[d+1];if(m&&m.start.row==f){v.merge(m);break}}break}if(f<=v.start.row)break}return r||(v=this.$addFoldLine(new i(this.$foldData,o))),this.$useWrapMode?this.$updateWrapData(v.start.row,v.start.row):this.$updateRowLengthCache(v.start.row,v.start.row),this.$modified=!0,this._emit("changeFold",{data:o,action:"add"}),o}throw new Error("The range has to be at least 2 characters width")},this.addFolds=function(e){e.forEach(function(e){this.addFold(e)},this)},this.removeFold=function(e){var t=e.foldLine,n=t.start.row,r=t.end.row,i=this.$foldData,s=t.folds;if(s.length==1)i.splice(i.indexOf(t),1);else if(t.range.isEnd(e.end.row,e.end.column))s.pop(),t.end.row=s[s.length-1].end.row,t.end.column=s[s.length-1].end.column;else if(t.range.isStart(e.start.row,e.start.column))s.shift(),t.start.row=s[0].start.row,t.start.column=s[0].start.column;else if(e.sameRow)s.splice(s.indexOf(e),1);else{var o=t.split(e.start.row,e.start.column);s=o.folds,s.shift(),o.start.row=s[0].start.row,o.start.column=s[0].start.column}this.$updating||(this.$useWrapMode?this.$updateWrapData(n,r):this.$updateRowLengthCache(n,r)),this.$modified=!0,this._emit("changeFold",{data:e,action:"remove"})},this.removeFolds=function(e){var t=[];for(var n=0;n<e.length;n++)t.push(e[n]);t.forEach(function(e){this.removeFold(e)},this),this.$modified=!0},this.expandFold=function(e){this.removeFold(e),e.subFolds.forEach(function(t){e.restoreRange(t),this.addFold(t)},this),e.collapseChildren>0&&this.foldAll(e.start.row+1,e.end.row,e.collapseChildren-1),e.subFolds=[]},this.expandFolds=function(e){e.forEach(function(e){this.expandFold(e)},this)},this.unfold=function(e,t){var n,i;e==null?(n=new r(0,0,this.getLength(),0),t=!0):typeof e=="number"?n=new r(e,0,e,this.getLine(e).length):"row"in e?n=r.fromPoints(e,e):n=e,i=this.getFoldsInRangeList(n);if(t)this.removeFolds(i);else{var s=i;while(s.length)this.expandFolds(s),s=this.getFoldsInRangeList(n)}if(i.length)return i},this.isRowFolded=function(e,t){return!!this.getFoldLine(e,t)},this.getRowFoldEnd=function(e,t){var n=this.getFoldLine(e,t);return n?n.end.row:e},this.getRowFoldStart=function(e,t){var n=this.getFoldLine(e,t);return n?n.start.row:e},this.getFoldDisplayLine=function(e,t,n,r,i){r==null&&(r=e.start.row),i==null&&(i=0),t==null&&(t=e.end.row),n==null&&(n=this.getLine(t).length);var s=this.doc,o="";return e.walk(function(e,t,n,u){if(t<r)return;if(t==r){if(n<i)return;u=Math.max(i,u)}e!=null?o+=e:o+=s.getLine(t).substring(u,n)},t,n),o},this.getDisplayLine=function(e,t,n,r){var i=this.getFoldLine(e);if(!i){var s;return s=this.doc.getLine(e),s.substring(r||0,t||s.length)}return this.getFoldDisplayLine(i,e,t,n,r)},this.$cloneFoldData=function(){var e=[];return e=this.$foldData.map(function(t){var n=t.folds.map(function(e){return e.clone()});return new i(e,n)}),e},this.toggleFold=function(e){var t=this.selection,n=t.getRange(),r,i;if(n.isEmpty()){var s=n.start;r=this.getFoldAt(s.row,s.column);if(r){this.expandFold(r);return}(i=this.findMatchingBracket(s))?n.comparePoint(i)==1?n.end=i:(n.start=i,n.start.column++,n.end.column--):(i=this.findMatchingBracket({row:s.row,column:s.column+1}))?(n.comparePoint(i)==1?n.end=i:n.start=i,n.start.column++):n=this.getCommentFoldRange(s.row,s.column)||n}else{var o=this.getFoldsInRange(n);if(e&&o.length){this.expandFolds(o);return}o.length==1&&(r=o[0])}r||(r=this.getFoldAt(n.start.row,n.start.column));if(r&&r.range.toString()==n.toString()){this.expandFold(r);return}var u="...";if(!n.isMultiLine()){u=this.getTextRange(n);if(u.length<4)return;u=u.trim().substring(0,2)+".."}this.addFold(u,n)},this.getCommentFoldRange=function(e,t,n){var i=new o(this,e,t),s=i.getCurrentToken();if(s&&/^comment|string/.test(s.type)){var u=new r,a=new RegExp(s.type.replace(/\..*/,"\\."));if(n!=1){do s=i.stepBackward();while(s&&a.test(s.type));i.stepForward()}u.start.row=i.getCurrentTokenRow(),u.start.column=i.getCurrentTokenColumn()+2,i=new o(this,e,t);if(n!=-1){do s=i.stepForward();while(s&&a.test(s.type));s=i.stepBackward()}else s=i.getCurrentToken();return u.end.row=i.getCurrentTokenRow(),u.end.column=i.getCurrentTokenColumn()+s.value.length-2,u}},this.foldAll=function(e,t,n){n==undefined&&(n=1e5);var r=this.foldWidgets;if(!r)return;t=t||this.getLength(),e=e||0;for(var i=e;i<t;i++){r[i]==null&&(r[i]=this.getFoldWidget(i));if(r[i]!="start")continue;var s=this.getFoldWidgetRange(i);if(s&&s.isMultiLine()&&s.end.row<=t&&s.start.row>=e){i=s.end.row;try{var o=this.addFold("...",s);o&&(o.collapseChildren=n)}catch(u){}}}},this.$foldStyles={manual:1,markbegin:1,markbeginend:1},this.$foldStyle="markbegin",this.setFoldStyle=function(e){if(!this.$foldStyles[e])throw new Error("invalid fold style: "+e+"["+Object.keys(this.$foldStyles).join(", ")+"]");if(this.$foldStyle==e)return;this.$foldStyle=e,e=="manual"&&this.unfold();var t=this.$foldMode;this.$setFolding(null),this.$setFolding(t)},this.$setFolding=function(e){if(this.$foldMode==e)return;this.$foldMode=e,this.off("change",this.$updateFoldWidgets),this.off("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets),this._emit("changeAnnotation");if(!e||this.$foldStyle=="manual"){this.foldWidgets=null;return}this.foldWidgets=[],this.getFoldWidget=e.getFoldWidget.bind(e,this,this.$foldStyle),this.getFoldWidgetRange=e.getFoldWidgetRange.bind(e,this,this.$foldStyle),this.$updateFoldWidgets=this.updateFoldWidgets.bind(this),this.$tokenizerUpdateFoldWidgets=this.tokenizerUpdateFoldWidgets.bind(this),this.on("change",this.$updateFoldWidgets),this.on("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets)},this.getParentFoldRangeData=function(e,t){var n=this.foldWidgets;if(!n||t&&n[e])return{};var r=e-1,i;while(r>=0){var s=n[r];s==null&&(s=n[r]=this.getFoldWidget(r));if(s=="start"){var o=this.getFoldWidgetRange(r);i||(i=o);if(o&&o.end.row>=e)break}r--}return{range:r!==-1&&o,firstRange:i}},this.onFoldWidgetClick=function(e,t){t=t.domEvent;var n={children:t.shiftKey,all:t.ctrlKey||t.metaKey,siblings:t.altKey},r=this.$toggleFoldWidget(e,n);if(!r){var i=t.target||t.srcElement;i&&/ace_fold-widget/.test(i.className)&&(i.className+=" ace_invalid")}},this.$toggleFoldWidget=function(e,t){if(!this.getFoldWidget)return;var n=this.getFoldWidget(e),r=this.getLine(e),i=n==="end"?-1:1,s=this.getFoldAt(e,i===-1?0:r.length,i);if(s){t.children||t.all?this.removeFold(s):this.expandFold(s);return}var o=this.getFoldWidgetRange(e,!0);if(o&&!o.isMultiLine()){s=this.getFoldAt(o.start.row,o.start.column,1);if(s&&o.isEqual(s.range)){this.removeFold(s);return}}if(t.siblings){var u=this.getParentFoldRangeData(e);if(u.range)var a=u.range.start.row+1,f=u.range.end.row;this.foldAll(a,f,t.all?1e4:0)}else t.children?(f=o?o.end.row:this.getLength(),this.foldAll(e+1,o.end.row,t.all?1e4:0)):o&&(t.all&&(o.collapseChildren=1e4),this.addFold("...",o));return o},this.toggleFoldWidget=function(e){var t=this.selection.getCursor().row;t=this.getRowFoldStart(t);var n=this.$toggleFoldWidget(t,{});if(n)return;var r=this.getParentFoldRangeData(t,!0);n=r.range||r.firstRange;if(n){t=n.start.row;var i=this.getFoldAt(t,this.getLine(t).length,1);i?this.removeFold(i):this.addFold("...",n)}},this.updateFoldWidgets=function(e){var t=e.data,n=t.range,r=n.start.row,i=n.end.row-r;if(i===0)this.foldWidgets[r]=null;else if(t.action=="removeText"||t.action=="removeLines")this.foldWidgets.splice(r,i+1,null);else{var s=Array(i+1);s.unshift(r,1),this.foldWidgets.splice.apply(this.foldWidgets,s)}},this.tokenizerUpdateFoldWidgets=function(e){var t=e.data;t.first!=t.last&&this.foldWidgets.length>t.first&&this.foldWidgets.splice(t.first,this.foldWidgets.length)}}var r=e("../range").Range,i=e("./fold_line").FoldLine,s=e("./fold").Fold,o=e("../token_iterator").TokenIterator;t.Folding=u}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(e,t,n){"use strict";function s(){this.findMatchingBracket=function(e,t){if(e.column==0)return null;var n=t||this.getLine(e.row).charAt(e.column-1);if(n=="")return null;var r=n.match(/([\(\[\{])|([\)\]\}])/);return r?r[1]?this.$findClosingBracket(r[1],e):this.$findOpeningBracket(r[2],e):null},this.getBracketRange=function(e){var t=this.getLine(e.row),n=!0,r,s=t.charAt(e.column-1),o=s&&s.match(/([\(\[\{])|([\)\]\}])/);o||(s=t.charAt(e.column),e={row:e.row,column:e.column+1},o=s&&s.match(/([\(\[\{])|([\)\]\}])/),n=!1);if(!o)return null;if(o[1]){var u=this.$findClosingBracket(o[1],e);if(!u)return null;r=i.fromPoints(e,u),n||(r.end.column++,r.start.column--),r.cursor=r.end}else{var u=this.$findOpeningBracket(o[2],e);if(!u)return null;r=i.fromPoints(u,e),n||(r.start.column++,r.end.column--),r.cursor=r.start}return r},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{"},this.$findOpeningBracket=function(e,t,n){var i=this.$brackets[e],s=1,o=new r(this,t.row,t.column),u=o.getCurrentToken();u||(u=o.stepForward());if(!u)return;n||(n=new RegExp("(\\.?"+u.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end|start|begin)\b/,"")+")+"));var a=t.column-o.getCurrentTokenColumn()-2,f=u.value;for(;;){while(a>=0){var l=f.charAt(a);if(l==i){s-=1;if(s==0)return{row:o.getCurrentTokenRow(),column:a+o.getCurrentTokenColumn()}}else l==e&&(s+=1);a-=1}do u=o.stepBackward();while(u&&!n.test(u.type));if(u==null)break;f=u.value,a=f.length-1}return null},this.$findClosingBracket=function(e,t,n){var i=this.$brackets[e],s=1,o=new r(this,t.row,t.column),u=o.getCurrentToken();u||(u=o.stepForward());if(!u)return;n||(n=new RegExp("(\\.?"+u.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:end|start|begin)\b/,"")+")+"));var a=t.column-o.getCurrentTokenColumn();for(;;){var f=u.value,l=f.length;while(a<l){var c=f.charAt(a);if(c==i){s-=1;if(s==0)return{row:o.getCurrentTokenRow(),column:a+o.getCurrentTokenColumn()}}else c==e&&(s+=1);a+=1}do u=o.stepForward();while(u&&!n.test(u.type));if(u==null)break;a=0}return null}}var r=e("../token_iterator").TokenIterator,i=e("../range").Range;t.BracketMatch=s}),ace.define("ace/edit_session",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/config","ace/lib/event_emitter","ace/selection","ace/mode/text","ace/range","ace/document","ace/background_tokenizer","ace/search_highlight","ace/edit_session/folding","ace/edit_session/bracket_match"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/lang"),s=e("./config"),o=e("./lib/event_emitter").EventEmitter,u=e("./selection").Selection,a=e("./mode/text").Mode,f=e("./range").Range,l=e("./document").Document,c=e("./background_tokenizer").BackgroundTokenizer,h=e("./search_highlight").SearchHighlight,p=function(e,t){this.$breakpoints=[],this.$decorations=[],this.$frontMarkers={},this.$backMarkers={},this.$markerId=1,this.$undoSelect=!0,this.$foldData=[],this.$foldData.toString=function(){return this.join("\n")},this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this);if(typeof e!="object"||!e.getLine)e=new l(e);this.setDocument(e),this.selection=new u(this),s.resetOptions(this),this.setMode(t),s._signal("session",this)};(function(){function m(e){return e<4352?!1:e>=4352&&e<=4447||e>=4515&&e<=4519||e>=4602&&e<=4607||e>=9001&&e<=9002||e>=11904&&e<=11929||e>=11931&&e<=12019||e>=12032&&e<=12245||e>=12272&&e<=12283||e>=12288&&e<=12350||e>=12353&&e<=12438||e>=12441&&e<=12543||e>=12549&&e<=12589||e>=12593&&e<=12686||e>=12688&&e<=12730||e>=12736&&e<=12771||e>=12784&&e<=12830||e>=12832&&e<=12871||e>=12880&&e<=13054||e>=13056&&e<=19903||e>=19968&&e<=42124||e>=42128&&e<=42182||e>=43360&&e<=43388||e>=44032&&e<=55203||e>=55216&&e<=55238||e>=55243&&e<=55291||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65106||e>=65108&&e<=65126||e>=65128&&e<=65131||e>=65281&&e<=65376||e>=65504&&e<=65510}r.implement(this,o),this.setDocument=function(e){this.doc&&this.doc.removeListener("change",this.$onChange),this.doc=e,e.on("change",this.$onChange),this.bgTokenizer&&this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},this.getDocument=function(){return this.doc},this.$resetRowCache=function(e){if(!e){this.$docRowCache=[],this.$screenRowCache=[];return}var t=this.$docRowCache.length,n=this.$getRowCacheIndex(this.$docRowCache,e)+1;t>n&&(this.$docRowCache.splice(n,t),this.$screenRowCache.splice(n,t))},this.$getRowCacheIndex=function(e,t){var n=0,r=e.length-1;while(n<=r){var i=n+r>>1,s=e[i];if(t>s)n=i+1;else{if(!(t<s))return i;r=i-1}}return n-1},this.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.bgTokenizer&&this.bgTokenizer.start(0)},this.onChangeFold=function(e){var t=e.data;this.$resetRowCache(t.start.row)},this.onChange=function(e){var t=e.data;this.$modified=!0,this.$resetRowCache(t.range.start.row);var n=this.$updateInternalDataOnChange(e);!this.$fromUndo&&this.$undoManager&&!t.ignore&&(this.$deltasDoc.push(t),n&&n.length!=0&&this.$deltasFold.push({action:"removeFolds",folds:n}),this.$informUndoManager.schedule()),this.bgTokenizer&&this.bgTokenizer.$updateOnChange(t),this._signal("change",e)},this.setValue=function(e){this.doc.setValue(e),this.selection.moveTo(0,0),this.$resetRowCache(0),this.$deltas=[],this.$deltasDoc=[],this.$deltasFold=[],this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},this.getValue=this.toString=function(){return this.doc.getValue()},this.getSelection=function(){return this.selection},this.getState=function(e){return this.bgTokenizer.getState(e)},this.getTokens=function(e){return this.bgTokenizer.getTokens(e)},this.getTokenAt=function(e,t){var n=this.bgTokenizer.getTokens(e),r,i=0;if(t==null)s=n.length-1,i=this.getLine(e).length;else for(var s=0;s<n.length;s++){i+=n[s].value.length;if(i>=t)break}return r=n[s],r?(r.index=s,r.start=i-r.value.length,r):null},this.setUndoManager=function(e){this.$undoManager=e,this.$deltas=[],this.$deltasDoc=[],this.$deltasFold=[],this.$informUndoManager&&this.$informUndoManager.cancel();if(e){var t=this;this.$syncInformUndoManager=function(){t.$informUndoManager.cancel(),t.$deltasFold.length&&(t.$deltas.push({group:"fold",deltas:t.$deltasFold}),t.$deltasFold=[]),t.$deltasDoc.length&&(t.$deltas.push({group:"doc",deltas:t.$deltasDoc}),t.$deltasDoc=[]),t.$deltas.length>0&&e.execute({action:"aceupdate",args:[t.$deltas,t],merge:t.mergeUndoDeltas}),t.mergeUndoDeltas=!1,t.$deltas=[]},this.$informUndoManager=i.delayedCall(this.$syncInformUndoManager)}},this.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},this.$defaultUndoManager={undo:function(){},redo:function(){},reset:function(){}},this.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},this.getTabString=function(){return this.getUseSoftTabs()?i.stringRepeat(" ",this.getTabSize()):" "},this.setUseSoftTabs=function(e){this.setOption("useSoftTabs",e)},this.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},this.setTabSize=function(e){this.setOption("tabSize",e)},this.getTabSize=function(){return this.$tabSize},this.isTabStop=function(e){return this.$useSoftTabs&&e.column%this.$tabSize===0},this.$overwrite=!1,this.setOverwrite=function(e){this.setOption("overwrite",e)},this.getOverwrite=function(){return this.$overwrite},this.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},this.addGutterDecoration=function(e,t){this.$decorations[e]||(this.$decorations[e]=""),this.$decorations[e]+=" "+t,this._signal("changeBreakpoint",{})},this.removeGutterDecoration=function(e,t){this.$decorations[e]=(this.$decorations[e]||"").replace(" "+t,""),this._signal("changeBreakpoint",{})},this.getBreakpoints=function(){return this.$breakpoints},this.setBreakpoints=function(e){this.$breakpoints=[];for(var t=0;t<e.length;t++)this.$breakpoints[e[t]]="ace_breakpoint";this._signal("changeBreakpoint",{})},this.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},this.setBreakpoint=function(e,t){t===undefined&&(t="ace_breakpoint"),t?this.$breakpoints[e]=t:delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},this.clearBreakpoint=function(e){delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},this.addMarker=function(e,t,n,r){var i=this.$markerId++,s={range:e,type:n||"line",renderer:typeof n=="function"?n:null,clazz:t,inFront:!!r,id:i};return r?(this.$frontMarkers[i]=s,this._signal("changeFrontMarker")):(this.$backMarkers[i]=s,this._signal("changeBackMarker")),i},this.addDynamicMarker=function(e,t){if(!e.update)return;var n=this.$markerId++;return e.id=n,e.inFront=!!t,t?(this.$frontMarkers[n]=e,this._signal("changeFrontMarker")):(this.$backMarkers[n]=e,this._signal("changeBackMarker")),e},this.removeMarker=function(e){var t=this.$frontMarkers[e]||this.$backMarkers[e];if(!t)return;var n=t.inFront?this.$frontMarkers:this.$backMarkers;t&&(delete n[e],this._signal(t.inFront?"changeFrontMarker":"changeBackMarker"))},this.getMarkers=function(e){return e?this.$frontMarkers:this.$backMarkers},this.highlight=function(e){if(!this.$searchHighlight){var t=new h(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker(t)}this.$searchHighlight.setRegexp(e)},this.highlightLines=function(e,t,n,r){typeof t!="number"&&(n=t,t=e),n||(n="ace_step");var i=new f(e,0,t,Infinity);return i.id=this.addMarker(i,n,"fullLine",r),i},this.setAnnotations=function(e){this.$annotations=e,this._signal("changeAnnotation",{})},this.getAnnotations=function(){return this.$annotations||[]},this.clearAnnotations=function(){this.setAnnotations([])},this.$detectNewLine=function(e){var t=e.match(/^.*?(\r?\n)/m);t?this.$autoNewLine=t[1]:this.$autoNewLine="\n"},this.getWordRange=function(e,t){var n=this.getLine(e),r=!1;t>0&&(r=!!n.charAt(t-1).match(this.tokenRe)),r||(r=!!n.charAt(t).match(this.tokenRe));if(r)var i=this.tokenRe;else if(/^\s+$/.test(n.slice(t-1,t+1)))var i=/\s/;else var i=this.nonTokenRe;var s=t;if(s>0){do s--;while(s>=0&&n.charAt(s).match(i));s++}var o=t;while(o<n.length&&n.charAt(o).match(i))o++;return new f(e,s,e,o)},this.getAWordRange=function(e,t){var n=this.getWordRange(e,t),r=this.getLine(n.end.row);while(r.charAt(n.end.column).match(/[ \t]/))n.end.column+=1;return n},this.setNewLineMode=function(e){this.doc.setNewLineMode(e)},this.getNewLineMode=function(){return this.doc.getNewLineMode()},this.setUseWorker=function(e){this.setOption("useWorker",e)},this.getUseWorker=function(){return this.$useWorker},this.onReloadTokenizer=function(e){var t=e.data;this.bgTokenizer.start(t.first),this._signal("tokenizerUpdate",e)},this.$modes={},this.$mode=null,this.$modeId=null,this.setMode=function(e,t){if(e&&typeof e=="object"){if(e.getTokenizer)return this.$onChangeMode(e);var n=e,r=n.path}else r=e||"ace/mode/text";this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new a);if(this.$modes[r]&&!n){this.$onChangeMode(this.$modes[r]),t&&t();return}this.$modeId=r,s.loadModule(["mode",r],function(e){if(this.$modeId!==r)return t&&t();if(this.$modes[r]&&!n)return this.$onChangeMode(this.$modes[r]);e&&e.Mode&&(e=new e.Mode(n),n||(this.$modes[r]=e,e.$id=r),this.$onChangeMode(e),t&&t())}.bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0)},this.$onChangeMode=function(e,t){t||(this.$modeId=e.$id);if(this.$mode===e)return;this.$mode=e,this.$stopWorker(),this.$useWorker&&this.$startWorker();var n=e.getTokenizer();if(n.addEventListener!==undefined){var r=this.onReloadTokenizer.bind(this);n.addEventListener("update",r)}if(!this.bgTokenizer){this.bgTokenizer=new c(n);var i=this;this.bgTokenizer.addEventListener("update",function(e){i._signal("tokenizerUpdate",e)})}else this.bgTokenizer.setTokenizer(n);this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=e.tokenRe,this.nonTokenRe=e.nonTokenRe,t||(e.attachToSession&&e.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(e.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode"))},this.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},this.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(e){s.warn("Could not load worker",e),this.$worker=null}},this.getMode=function(){return this.$mode},this.$scrollTop=0,this.setScrollTop=function(e){if(this.$scrollTop===e||isNaN(e))return;this.$scrollTop=e,this._signal("changeScrollTop",e)},this.getScrollTop=function(){return this.$scrollTop},this.$scrollLeft=0,this.setScrollLeft=function(e){if(this.$scrollLeft===e||isNaN(e))return;this.$scrollLeft=e,this._signal("changeScrollLeft",e)},this.getScrollLeft=function(){return this.$scrollLeft},this.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},this.getLineWidgetMaxWidth=function(){if(this.lineWidgetsWidth!=null)return this.lineWidgetsWidth;var e=0;return this.lineWidgets.forEach(function(t){t&&t.screenWidth>e&&(e=t.screenWidth)}),this.lineWidgetWidth=e},this.$computeWidth=function(e){if(this.$modified||e){this.$modified=!1;if(this.$useWrapMode)return this.screenWidth=this.$wrapLimit;var t=this.doc.getAllLines(),n=this.$rowLengthCache,r=0,i=0,s=this.$foldData[i],o=s?s.start.row:Infinity,u=t.length;for(var a=0;a<u;a++){if(a>o){a=s.end.row+1;if(a>=u)break;s=this.$foldData[i++],o=s?s.start.row:Infinity}n[a]==null&&(n[a]=this.$getStringScreenWidth(t[a])[0]),n[a]>r&&(r=n[a])}this.screenWidth=r}},this.getLine=function(e){return this.doc.getLine(e)},this.getLines=function(e,t){return this.doc.getLines(e,t)},this.getLength=function(){return this.doc.getLength()},this.getTextRange=function(e){return this.doc.getTextRange(e||this.selection.getRange())},this.insert=function(e,t){return this.doc.insert(e,t)},this.remove=function(e){return this.doc.remove(e)},this.undoChanges=function(e,t){if(!e.length)return;this.$fromUndo=!0;var n=null;for(var r=e.length-1;r!=-1;r--){var i=e[r];i.group=="doc"?(this.doc.revertDeltas(i.deltas),n=this.$getUndoSelection(i.deltas,!0,n)):i.deltas.forEach(function(e){this.addFolds(e.folds)},this)}return this.$fromUndo=!1,n&&this.$undoSelect&&!t&&this.selection.setSelectionRange(n),n},this.redoChanges=function(e,t){if(!e.length)return;this.$fromUndo=!0;var n=null;for(var r=0;r<e.length;r++){var i=e[r];i.group=="doc"&&(this.doc.applyDeltas(i.deltas),n=this.$getUndoSelection(i.deltas,!1,n))}return this.$fromUndo=!1,n&&this.$undoSelect&&!t&&this.selection.setSelectionRange(n),n},this.setUndoSelect=function(e){this.$undoSelect=e},this.$getUndoSelection=function(e,t,n){function r(e){var n=e.action==="insertText"||e.action==="insertLines";return t?!n:n}var i=e[0],s,o,u=!1;r(i)?(s=f.fromPoints(i.range.start,i.range.end),u=!0):(s=f.fromPoints(i.range.start,i.range.start),u=!1);for(var a=1;a<e.length;a++)i=e[a],r(i)?(o=i.range.start,s.compare(o.row,o.column)==-1&&s.setStart(i.range.start),o=i.range.end,s.compare(o.row,o.column)==1&&s.setEnd(i.range.end),u=!0):(o=i.range.start,s.compare(o.row,o.column)==-1&&(s=f.fromPoints(i.range.start,i.range.start)),u=!1);if(n!=null){f.comparePoints(n.start,s.start)===0&&(n.start.column+=s.end.column-s.start.column,n.end.column+=s.end.column-s.start.column);var l=n.compareRange(s);l==1?s.setStart(n.start):l==-1&&s.setEnd(n.end)}return s},this.replace=function(e,t){return this.doc.replace(e,t)},this.moveText=function(e,t,n){var r=this.getTextRange(e),i=this.getFoldsInRange(e),s=f.fromPoints(t,t);if(!n){this.remove(e);var o=e.start.row-e.end.row,u=o?-e.end.column:e.start.column-e.end.column;u&&(s.start.row==e.end.row&&s.start.column>e.end.column&&(s.start.column+=u),s.end.row==e.end.row&&s.end.column>e.end.column&&(s.end.column+=u)),o&&s.start.row>=e.end.row&&(s.start.row+=o,s.end.row+=o)}s.end=this.insert(s.start,r);if(i.length){var a=e.start,l=s.start,o=l.row-a.row,u=l.column-a.column;this.addFolds(i.map(function(e){return e=e.clone(),e.start.row==a.row&&(e.start.column+=u),e.end.row==a.row&&(e.end.column+=u),e.start.row+=o,e.end.row+=o,e}))}return s},this.indentRows=function(e,t,n){n=n.replace(/\t/g,this.getTabString());for(var r=e;r<=t;r++)this.insert({row:r,column:0},n)},this.outdentRows=function(e){var t=e.collapseRows(),n=new f(0,0,0,0),r=this.getTabSize();for(var i=t.start.row;i<=t.end.row;++i){var s=this.getLine(i);n.start.row=i,n.end.row=i;for(var o=0;o<r;++o)if(s.charAt(o)!=" ")break;o<r&&s.charAt(o)==" "?(n.start.column=o,n.end.column=o+1):(n.start.column=0,n.end.column=o),this.remove(n)}},this.$moveLines=function(e,t,n){e=this.getRowFoldStart(e),t=this.getRowFoldEnd(t);if(n<0){var r=this.getRowFoldStart(e+n);if(r<0)return 0;var i=r-e}else if(n>0){var r=this.getRowFoldEnd(t+n);if(r>this.doc.getLength()-1)return 0;var i=r-t}else{e=this.$clipRowToDocument(e),t=this.$clipRowToDocument(t);var i=t-e+1}var s=new f(e,0,t,Number.MAX_VALUE),o=this.getFoldsInRange(s).map(function(e){return e=e.clone(),e.start.row+=i,e.end.row+=i,e}),u=n==0?this.doc.getLines(e,t):this.doc.removeLines(e,t);return this.doc.insertLines(e+i,u),o.length&&this.addFolds(o),i},this.moveLinesUp=function(e,t){return this.$moveLines(e,t,-1)},this.moveLinesDown=function(e,t){return this.$moveLines(e,t,1)},this.duplicateLines=function(e,t){return this.$moveLines(e,t,0)},this.$clipRowToDocument=function(e){return Math.max(0,Math.min(e,this.doc.getLength()-1))},this.$clipColumnToRow=function(e,t){return t<0?0:Math.min(this.doc.getLine(e).length,t)},this.$clipPositionToDocument=function(e,t){t=Math.max(0,t);if(e<0)e=0,t=0;else{var n=this.doc.getLength();e>=n?(e=n-1,t=this.doc.getLine(n-1).length):t=Math.min(this.doc.getLine(e).length,t)}return{row:e,column:t}},this.$clipRangeToDocument=function(e){e.start.row<0?(e.start.row=0,e.start.column=0):e.start.column=this.$clipColumnToRow(e.start.row,e.start.column);var t=this.doc.getLength()-1;return e.end.row>t?(e.end.row=t,e.end.column=this.doc.getLine(t).length):e.end.column=this.$clipColumnToRow(e.end.row,e.end.column),e},this.$wrapLimit=80,this.$useWrapMode=!1,this.$wrapLimitRange={min:null,max:null},this.setUseWrapMode=function(e){if(e!=this.$useWrapMode){this.$useWrapMode=e,this.$modified=!0,this.$resetRowCache(0);if(e){var t=this.getLength();this.$wrapData=Array(t),this.$updateWrapData(0,t-1)}this._signal("changeWrapMode")}},this.getUseWrapMode=function(){return this.$useWrapMode},this.setWrapLimitRange=function(e,t){if(this.$wrapLimitRange.min!==e||this.$wrapLimitRange.max!==t)this.$wrapLimitRange={min:e,max:t},this.$modified=!0,this._signal("changeWrapMode")},this.adjustWrapLimit=function(e,t){var n=this.$wrapLimitRange;n.max<0&&(n={min:t,max:t});var r=this.$constrainWrapLimit(e,n.min,n.max);return r!=this.$wrapLimit&&r>1?(this.$wrapLimit=r,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0):!1},this.$constrainWrapLimit=function(e,t,n){return t&&(e=Math.max(t,e)),n&&(e=Math.min(n,e)),e},this.getWrapLimit=function(){return this.$wrapLimit},this.setWrapLimit=function(e){this.setWrapLimitRange(e,e)},this.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},this.$updateInternalDataOnChange=function(e){var t=this.$useWrapMode,n,r=e.data.action,i=e.data.range.start.row,s=e.data.range.end.row,o=e.data.range.start,u=e.data.range.end,a=null;r.indexOf("Lines")!=-1?(r=="insertLines"?s=i+e.data.lines.length:s=i,n=e.data.lines?e.data.lines.length:s-i):n=s-i,this.$updating=!0;if(n!=0)if(r.indexOf("remove")!=-1){this[t?"$wrapData":"$rowLengthCache"].splice(i,n);var f=this.$foldData;a=this.getFoldsInRange(e.data.range),this.removeFolds(a);var l=this.getFoldLine(u.row),c=0;if(l){l.addRemoveChars(u.row,u.column,o.column-u.column),l.shiftRow(-n);var h=this.getFoldLine(i);h&&h!==l&&(h.merge(l),l=h),c=f.indexOf(l)+1}for(c;c<f.length;c++){var l=f[c];l.start.row>=u.row&&l.shiftRow(-n)}s=i}else{var p=Array(n);p.unshift(i,0);var d=t?this.$wrapData:this.$rowLengthCache;d.splice.apply(d,p);var f=this.$foldData,l=this.getFoldLine(i),c=0;if(l){var v=l.range.compareInside(o.row,o.column);v==0?(l=l.split(o.row,o.column),l&&(l.shiftRow(n),l.addRemoveChars(s,0,u.column-o.column))):v==-1&&(l.addRemoveChars(i,0,u.column-o.column),l.shiftRow(n)),c=f.indexOf(l)+1}for(c;c<f.length;c++){var l=f[c];l.start.row>=i&&l.shiftRow(n)}}else{n=Math.abs(e.data.range.start.column-e.data.range.end.column),r.indexOf("remove")!=-1&&(a=this.getFoldsInRange(e.data.range),this.removeFolds(a),n=-n);var l=this.getFoldLine(i);l&&l.addRemoveChars(i,o.column,n)}return t&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,t?this.$updateWrapData(i,s):this.$updateRowLengthCache(i,s),a},this.$updateRowLengthCache=function(e,t,n){this.$rowLengthCache[e]=null,this.$rowLengthCache[t]=null},this.$updateWrapData=function(e,t){var r=this.doc.getAllLines(),i=this.getTabSize(),s=this.$wrapData,o=this.$wrapLimit,a,f,l=e;t=Math.min(t,r.length-1);while(l<=t)f=this.getFoldLine(l,f),f?(a=[],f.walk(function(e,t,i,s){var o;if(e!=null){o=this.$getDisplayTokens(e,a.length),o[0]=n;for(var f=1;f<o.length;f++)o[f]=u}else o=this.$getDisplayTokens(r[t].substring(s,i),a.length);a=a.concat(o)}.bind(this),f.end.row,r[f.end.row].length+1),s[f.start.row]=this.$computeWrapSplits(a,o,i),l=f.end.row+1):(a=this.$getDisplayTokens(r[l]),s[l]=this.$computeWrapSplits(a,o,i),l++)};var e=1,t=2,n=3,u=4,l=9,p=10,d=11,v=12;this.$computeWrapSplits=function(e,r){function c(t){var n=e.slice(o,t),r=n.length;n.join("").replace(/12/g,function(){r-=1}).replace(/2/g,function(){r-=1}),a+=r,i.push(a),o=t}if(e.length==0)return[];var i=[],s=e.length,o=0,a=0,f=this.$wrapAsCode;while(s-o>r){var h=o+r;if(e[h-1]>=p&&e[h]>=p){c(h);continue}if(e[h]==n||e[h]==u){for(h;h!=o-1;h--)if(e[h]==n)break;if(h>o){c(h);continue}h=o+r;for(h;h<e.length;h++)if(e[h]!=u)break;if(h==e.length)break;c(h);continue}var d=Math.max(h-(f?10:r-(r>>2)),o-1);while(h>d&&e[h]<n)h--;if(f){while(h>d&&e[h]<n)h--;while(h>d&&e[h]==l)h--}else while(h>d&&e[h]<p)h--;if(h>d){c(++h);continue}h=o+r,e[h]==t&&h--,c(h)}return i},this.$getDisplayTokens=function(n,r){var i=[],s;r=r||0;for(var o=0;o<n.length;o++){var u=n.charCodeAt(o);if(u==9){s=this.getScreenTabSize(i.length+r),i.push(d);for(var a=1;a<s;a++)i.push(v)}else u==32?i.push(p):u>39&&u<48||u>57&&u<64?i.push(l):u>=4352&&m(u)?i.push(e,t):i.push(e)}return i},this.$getStringScreenWidth=function(e,t,n){if(t==0)return[0,0];t==null&&(t=Infinity),n=n||0;var r,i;for(i=0;i<e.length;i++){r=e.charCodeAt(i),r==9?n+=this.getScreenTabSize(n):r>=4352&&m(r)?n+=2:n+=1;if(n>t)break}return[n,i]},this.lineWidgets=null,this.getRowLength=function(e){if(this.lineWidgets)var t=this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0;else t=0;return!this.$useWrapMode||!this.$wrapData[e]?1+t:this.$wrapData[e].length+1+t},this.getRowLineCount=function(e){return!this.$useWrapMode||!this.$wrapData[e]?1:this.$wrapData[e].length+1},this.getScreenLastRowColumn=function(e){var t=this.screenToDocumentPosition(e,Number.MAX_VALUE);return this.documentToScreenColumn(t.row,t.column)},this.getDocumentLastRowColumn=function(e,t){var n=this.documentToScreenRow(e,t);return this.getScreenLastRowColumn(n)},this.getDocumentLastRowColumnPosition=function(e,t){var n=this.documentToScreenRow(e,t);return this.screenToDocumentPosition(n,Number.MAX_VALUE/10)},this.getRowSplitData=function(e){return this.$useWrapMode?this.$wrapData[e]:undefined},this.getScreenTabSize=function(e){return this.$tabSize-e%this.$tabSize},this.screenToDocumentRow=function(e,t){return this.screenToDocumentPosition(e,t).row},this.screenToDocumentColumn=function(e,t){return this.screenToDocumentPosition(e,t).column},this.screenToDocumentPosition=function(e,t){if(e<0)return{row:0,column:0};var n,r=0,i=0,s,o=0,u=0,a=this.$screenRowCache,f=this.$getRowCacheIndex(a,e),l=a.length;if(l&&f>=0)var o=a[f],r=this.$docRowCache[f],c=e>a[l-1];else var c=!l;var h=this.getLength()-1,p=this.getNextFoldLine(r),d=p?p.start.row:Infinity;while(o<=e){u=this.getRowLength(r);if(o+u>e||r>=h)break;o+=u,r++,r>d&&(r=p.end.row+1,p=this.getNextFoldLine(r,p),d=p?p.start.row:Infinity),c&&(this.$docRowCache.push(r),this.$screenRowCache.push(o))}if(p&&p.start.row<=r)n=this.getFoldDisplayLine(p),r=p.start.row;else{if(o+u<=e||r>h)return{row:h,column:this.getLine(h).length};n=this.getLine(r),p=null}if(this.$useWrapMode){var v=this.$wrapData[r];if(v){var m=Math.floor(e-o);s=v[m],m>0&&v.length&&(i=v[m-1]||v[v.length-1],n=n.substring(i))}}return i+=this.$getStringScreenWidth(n,t)[1],this.$useWrapMode&&i>=s&&(i=s-1),p?p.idxToPosition(i):{row:r,column:i}},this.documentToScreenPosition=function(e,t){if(typeof t=="undefined")var n=this.$clipPositionToDocument(e.row,e.column);else n=this.$clipPositionToDocument(e,t);e=n.row,t=n.column;var r=0,i=null,s=null;s=this.getFoldAt(e,t,1),s&&(e=s.start.row,t=s.start.column);var o,u=0,a=this.$docRowCache,f=this.$getRowCacheIndex(a,e),l=a.length;if(l&&f>=0)var u=a[f],r=this.$screenRowCache[f],c=e>a[l-1];else var c=!l;var h=this.getNextFoldLine(u),p=h?h.start.row:Infinity;while(u<e){if(u>=p){o=h.end.row+1;if(o>e)break;h=this.getNextFoldLine(o,h),p=h?h.start.row:Infinity}else o=u+1;r+=this.getRowLength(u),u=o,c&&(this.$docRowCache.push(u),this.$screenRowCache.push(r))}var d="";h&&u>=p?(d=this.getFoldDisplayLine(h,e,t),i=h.start.row):(d=this.getLine(e).substring(0,t),i=e);if(this.$useWrapMode){var v=this.$wrapData[i];if(v){var m=0;while(d.length>=v[m])r++,m++;d=d.substring(v[m-1]||0,d.length)}}return{row:r,column:this.$getStringScreenWidth(d)[0]}},this.documentToScreenColumn=function(e,t){return this.documentToScreenPosition(e,t).column},this.documentToScreenRow=function(e,t){return this.documentToScreenPosition(e,t).row},this.getScreenLength=function(){var e=0,t=null;if(!this.$useWrapMode){e=this.getLength();var n=this.$foldData;for(var r=0;r<n.length;r++)t=n[r],e-=t.end.row-t.start.row}else{var i=this.$wrapData.length,s=0,r=0,t=this.$foldData[r++],o=t?t.start.row:Infinity;while(s<i){var u=this.$wrapData[s];e+=u?u.length+1:1,s++,s>o&&(s=t.end.row+1,t=this.$foldData[r++],o=t?t.start.row:Infinity)}}return this.lineWidgets&&(e+=this.$getWidgetScreenLength()),e},this.$setFontMetrics=function(e){},this.destroy=function(){this.bgTokenizer&&(this.bgTokenizer.setDocument(null),this.bgTokenizer=null),this.$stopWorker()}}).call(p.prototype),e("./edit_session/folding").Folding.call(p.prototype),e("./edit_session/bracket_match").BracketMatch.call(p.prototype),s.defineOptions(p.prototype,"session",{wrap:{set:function(e){!e||e=="off"?e=!1:e=="free"?e=!0:e=="printMargin"?e=-1:typeof e=="string"&&(e=parseInt(e,10)||!1);if(this.$wrap==e)return;if(!e)this.setUseWrapMode(!1);else{var t=typeof e=="number"?e:null;this.setWrapLimitRange(t,t),this.setUseWrapMode(!0)}this.$wrap=e},get:function(){return this.getUseWrapMode()?this.$wrap==-1?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(e){e=e=="auto"?this.$mode.type!="text":e!="text",e!=this.$wrapAsCode&&(this.$wrapAsCode=e,this.$useWrapMode&&(this.$modified=!0,this.$resetRowCache(0),this.$updateWrapData(0,this.getLength()-1)))},initialValue:"auto"},firstLineNumber:{set:function(){this._signal("changeBreakpoint")},initialValue:1},useWorker:{set:function(e){this.$useWorker=e,this.$stopWorker(),e&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(e){if(isNaN(e)||this.$tabSize===e)return;this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=e,this._signal("changeTabSize")},initialValue:4,handlesSet:!0},overwrite:{set:function(e){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(e){this.doc.setNewLineMode(e)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(e){this.setMode(e)},get:function(){return this.$modeId}}}),t.EditSession=p}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(e,t,n){"use strict";var r=e("./lib/lang"),i=e("./lib/oop"),s=e("./range").Range,o=function(){this.$options={}};(function(){this.set=function(e){return i.mixin(this.$options,e),this},this.getOptions=function(){return r.copyObject(this.$options)},this.setOptions=function(e){this.$options=e},this.find=function(e){var t=this.$options,n=this.$matchIterator(e,t);if(!n)return!1;var r=null;return n.forEach(function(e,n,i){if(!e.start){var o=e.offset+(i||0);r=new s(n,o,n,o+e.length);if(!e.length&&t.start&&t.start.start&&t.skipCurrent!=0&&r.isEqual(t.start))return r=null,!1}else r=e;return!0}),r},this.findAll=function(e){var t=this.$options;if(!t.needle)return[];this.$assembleRegExp(t);var n=t.range,i=n?e.getLines(n.start.row,n.end.row):e.doc.getAllLines(),o=[],u=t.re;if(t.$isMultiLine){var a=u.length,f=i.length-a,l;e:for(var c=u.offset||0;c<=f;c++){for(var h=0;h<a;h++)if(i[c+h].search(u[h])==-1)continue e;var p=i[c],d=i[c+a-1],v=p.length-p.match(u[0])[0].length,m=d.match(u[a-1])[0].length;if(l&&l.end.row===c&&l.end.column>v)continue;o.push(l=new s(c,v,c+a-1,m)),a>2&&(c=c+a-2)}}else for(var g=0;g<i.length;g++){var y=r.getMatchOffsets(i[g],u);for(var h=0;h<y.length;h++){var b=y[h];o.push(new s(g,b.offset,g,b.offset+b.length))}}if(n){var w=n.start.column,E=n.start.column,g=0,h=o.length-1;while(g<h&&o[g].start.column<w&&o[g].start.row==n.start.row)g++;while(g<h&&o[h].end.column>E&&o[h].end.row==n.end.row)h--;o=o.slice(g,h+1);for(g=0,h=o.length;g<h;g++)o[g].start.row+=n.start.row,o[g].end.row+=n.start.row}return o},this.replace=function(e,t){var n=this.$options,r=this.$assembleRegExp(n);if(n.$isMultiLine)return t;if(!r)return;var i=r.exec(e);if(!i||i[0].length!=e.length)return null;t=e.replace(r,t);if(n.preserveCase){t=t.split("");for(var s=Math.min(e.length,e.length);s--;){var o=e[s];o&&o.toLowerCase()!=o?t[s]=t[s].toUpperCase():t[s]=t[s].toLowerCase()}t=t.join("")}return t},this.$matchIterator=function(e,t){var n=this.$assembleRegExp(t);if(!n)return!1;var i;if(t.$isMultiLine)var o=n.length,u=function(t,r,u){var a=t.search(n[0]);if(a==-1)return;for(var f=1;f<o;f++){t=e.getLine(r+f);if(t.search(n[f])==-1)return}var l=t.match(n[o-1])[0].length,c=new s(r,a,r+o-1,l);n.offset==1?(c.start.row--,c.start.column=Number.MAX_VALUE):u&&(c.start.column+=u);if(i(c))return!0};else if(t.backwards)var u=function(e,t,s){var o=r.getMatchOffsets(e,n);for(var u=o.length-1;u>=0;u--)if(i(o[u],t,s))return!0};else var u=function(e,t,s){var o=r.getMatchOffsets(e,n);for(var u=0;u<o.length;u++)if(i(o[u],t,s))return!0};var a=this.$lineIterator(e,t);return{forEach:function(e){i=e,a.forEach(u)}}},this.$assembleRegExp=function(e,t){if(e.needle instanceof RegExp)return e.re=e.needle;var n=e.needle;if(!e.needle)return e.re=!1;e.regExp||(n=r.escapeRegExp(n)),e.wholeWord&&(n="\\b"+n+"\\b");var i=e.caseSensitive?"gm":"gmi";e.$isMultiLine=!t&&/[\n\r]/.test(n);if(e.$isMultiLine)return e.re=this.$assembleMultilineRegExp(n,i);try{var s=new RegExp(n,i)}catch(o){s=!1}return e.re=s},this.$assembleMultilineRegExp=function(e,t){var n=e.replace(/\r\n|\r|\n/g,"$\n^").split("\n"),r=[];for(var i=0;i<n.length;i++)try{r.push(new RegExp(n[i],t))}catch(s){return!1}return n[0]==""?(r.shift(),r.offset=1):r.offset=0,r},this.$lineIterator=function(e,t){var n=t.backwards==1,r=t.skipCurrent!=0,i=t.range,s=t.start;s||(s=i?i[n?"end":"start"]:e.selection.getRange()),s.start&&(s=s[r!=n?"end":"start"]);var o=i?i.start.row:0,u=i?i.end.row:e.getLength()-1,a=n?function(n){var r=s.row,i=e.getLine(r).substring(0,s.column);if(n(i,r))return;for(r--;r>=o;r--)if(n(e.getLine(r),r))return;if(t.wrap==0)return;for(r=u,o=s.row;r>=o;r--)if(n(e.getLine(r),r))return}:function(n){var r=s.row,i=e.getLine(r).substr(s.column);if(n(i,r,s.column))return;for(r+=1;r<=u;r++)if(n(e.getLine(r),r))return;if(t.wrap==0)return;for(r=o,u=s.row;r<=u;r++)if(n(e.getLine(r),r))return};return{forEach:a}}}).call(o.prototype),t.Search=o}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,t,n){"use strict";function o(e,t){this.platform=t||(i.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(e),this.$singleCommand=!0}function u(e,t){o.call(this,e,t),this.$singleCommand=!1}var r=e("../lib/keys"),i=e("../lib/useragent"),s=r.KEY_MODS;u.prototype=o.prototype,function(){this.addCommand=function(e){this.commands[e.name]&&this.removeCommand(e),this.commands[e.name]=e,e.bindKey&&this._buildKeyHash(e)},this.removeCommand=function(e,t){var n=e&&(typeof e=="string"?e:e.name);e=this.commands[n],t||delete this.commands[n];var r=this.commandKeyBinding;for(var i in r){var s=r[i];if(s==e)delete r[i];else if(Array.isArray(s)){var o=s.indexOf(e);o!=-1&&(s.splice(o,1),s.length==1&&(r[i]=s[0]))}}},this.bindKey=function(e,t,n){typeof e=="object"&&(e=e[this.platform]);if(!e)return;if(typeof t=="function")return this.addCommand({exec:t,bindKey:e,name:t.name||e});e.split("|").forEach(function(e){var r="";if(e.indexOf(" ")!=-1){var i=e.split(/\s+/);e=i.pop(),i.forEach(function(e){var t=this.parseKeys(e),n=s[t.hashId]+t.key;r+=(r?" ":"")+n,this._addCommandToBinding(r,"chainKeys")},this),r+=" "}var o=this.parseKeys(e),u=s[o.hashId]+o.key;this._addCommandToBinding(r+u,t,n)},this)},this._addCommandToBinding=function(e,t,n){var r=this.commandKeyBinding,i;t?!r[e]||this.$singleCommand?r[e]=t:(Array.isArray(r[e])?(i=r[e].indexOf(t))!=-1&&r[e].splice(i,1):r[e]=[r[e]],n||t.isDefault?r[e].unshift(t):r[e].push(t)):delete r[e]},this.addCommands=function(e){e&&Object.keys(e).forEach(function(t){var n=e[t];if(!n)return;if(typeof n=="string")return this.bindKey(n,t);typeof n=="function"&&(n={exec:n});if(typeof n!="object")return;n.name||(n.name=t),this.addCommand(n)},this)},this.removeCommands=function(e){Object.keys(e).forEach(function(t){this.removeCommand(e[t])},this)},this.bindKeys=function(e){Object.keys(e).forEach(function(t){this.bindKey(t,e[t])},this)},this._buildKeyHash=function(e){this.bindKey(e.bindKey,e)},this.parseKeys=function(e){var t=e.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(e){return e}),n=t.pop(),i=r[n];if(r.FUNCTION_KEYS[i])n=r.FUNCTION_KEYS[i].toLowerCase();else{if(!t.length)return{key:n,hashId:-1};if(t.length==1&&t[0]=="shift")return{key:n.toUpperCase(),hashId:-1}}var s=0;for(var o=t.length;o--;){var u=r.KEY_MODS[t[o]];if(u==null)return typeof console!="undefined"&&console.error("invalid modifier "+t[o]+" in "+e),!1;s|=u}return{key:n,hashId:s}},this.findKeyCommand=function(t,n){var r=s[t]+n;return this.commandKeyBinding[r]},this.handleKeyboard=function(e,t,n,r){var i=s[t]+n,o=this.commandKeyBinding[i];e.$keyChain&&(e.$keyChain+=" "+i,o=this.commandKeyBinding[e.$keyChain]||o);if(o)if(o=="chainKeys"||o[o.length-1]=="chainKeys")return e.$keyChain=e.$keyChain||i,{command:"null"};return e.$keyChain&&r>0&&(e.$keyChain=""),{command:o}}}.call(o.prototype),t.HashHandler=o,t.MultiHashHandler=u}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../keyboard/hash_handler").MultiHashHandler,s=e("../lib/event_emitter").EventEmitter,o=function(e,t){i.call(this,t,e),this.byName=this.commands,this.setDefaultHandler("exec",function(e){return e.command.exec(e.editor,e.args||{})})};r.inherits(o,i),function(){r.implement(this,s),this.exec=function(e,t,n){if(Array.isArray(e)){for(var r=e.length;r--;)if(this.exec(e[r],t,n))return!0;return!1}typeof e=="string"&&(e=this.commands[e]);if(!e)return!1;if(t&&t.$readOnly&&!e.readOnly)return!1;var i={editor:t,command:e,args:n};return i.returnValue=this._emit("exec",i),this._signal("afterExec",i),i.returnValue===!1?!1:!0},this.toggleRecording=function(e){if(this.$inReplay)return;return e&&e._emit("changeStatus"),this.recording?(this.macro.pop(),this.removeEventListener("exec",this.$addCommandToMacro),this.macro.length||(this.macro=this.oldMacro),this.recording=!1):(this.$addCommandToMacro||(this.$addCommandToMacro=function(e){this.macro.push([e.command,e.args])}.bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},this.replay=function(e){if(this.$inReplay||!this.macro)return;if(this.recording)return this.toggleRecording(e);try{this.$inReplay=!0,this.macro.forEach(function(t){typeof t=="string"?this.exec(t,e):this.exec(t[0],e,t[1])},this)}finally{this.$inReplay=!1}},this.trimMacro=function(e){return e.map(function(e){return typeof e[0]!="string"&&(e[0]=e[0].name),e[1]||(e=e[0]),e})}}.call(o.prototype),t.CommandManager=o}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(e,t,n){"use strict";function o(e,t){return{win:e,mac:t}}var r=e("../lib/lang"),i=e("../config"),s=e("../range").Range;t.commands=[{name:"showSettingsMenu",bindKey:o("Ctrl-,","Command-,"),exec:function(e){i.loadModule("ace/ext/settings_menu",function(t){t.init(e),e.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",bindKey:o("Alt-E","Ctrl-E"),exec:function(e){i.loadModule("ace/ext/error_marker",function(t){t.showErrorMarker(e,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",bindKey:o("Alt-Shift-E","Ctrl-Shift-E"),exec:function(e){i.loadModule("ace/ext/error_marker",function(t){t.showErrorMarker(e,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",bindKey:o("Ctrl-A","Command-A"),exec:function(e){e.selectAll()},readOnly:!0},{name:"centerselection",bindKey:o(null,"Ctrl-L"),exec:function(e){e.centerSelection()},readOnly:!0},{name:"gotoline",bindKey:o("Ctrl-L","Command-L"),exec:function(e){var t=parseInt(prompt("Enter line number:"),10);isNaN(t)||e.gotoLine(t)},readOnly:!0},{name:"fold",bindKey:o("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(e){e.session.toggleFold(!1)},scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:o("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(e){e.session.toggleFold(!0)},scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",bindKey:o("F2","F2"),exec:function(e){e.session.toggleFoldWidget()},scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",bindKey:o("Alt-F2","Alt-F2"),exec:function(e){e.session.toggleFoldWidget(!0)},scrollIntoView:"center",readOnly:!0},{name:"foldall",bindKey:o("Ctrl-Alt-0","Ctrl-Command-Option-0"),exec:function(e){e.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",bindKey:o("Alt-0","Command-Option-0"),exec:function(e){e.session.foldAll(),e.session.unfold(e.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",bindKey:o("Alt-Shift-0","Command-Option-Shift-0"),exec:function(e){e.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",bindKey:o("Ctrl-K","Command-G"),exec:function(e){e.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",bindKey:o("Ctrl-Shift-K","Command-Shift-G"),exec:function(e){e.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",bindKey:o("Alt-K","Ctrl-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findNext()},readOnly:!0},{name:"selectOrFindPrevious",bindKey:o("Alt-Shift-K","Ctrl-Shift-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findPrevious()},readOnly:!0},{name:"find",bindKey:o("Ctrl-F","Command-F"),exec:function(e){i.loadModule("ace/ext/searchbox",function(t){t.Search(e)})},readOnly:!0},{name:"overwrite",bindKey:"Insert",exec:function(e){e.toggleOverwrite()},readOnly:!0},{name:"selecttostart",bindKey:o("Ctrl-Shift-Home","Command-Shift-Up"),exec:function(e){e.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",bindKey:o("Ctrl-Home","Command-Home|Command-Up"),exec:function(e){e.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",bindKey:o("Shift-Up","Shift-Up"),exec:function(e){e.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",bindKey:o("Up","Up|Ctrl-P"),exec:function(e,t){e.navigateUp(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",bindKey:o("Ctrl-Shift-End","Command-Shift-Down"),exec:function(e){e.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",bindKey:o("Ctrl-End","Command-End|Command-Down"),exec:function(e){e.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",bindKey:o("Shift-Down","Shift-Down"),exec:function(e){e.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",bindKey:o("Down","Down|Ctrl-N"),exec:function(e,t){e.navigateDown(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",bindKey:o("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(e){e.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",bindKey:o("Ctrl-Left","Option-Left"),exec:function(e){e.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",bindKey:o("Alt-Shift-Left","Command-Shift-Left"),exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",bindKey:o("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(e){e.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",bindKey:o("Shift-Left","Shift-Left"),exec:function(e){e.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",bindKey:o("Left","Left|Ctrl-B"),exec:function(e,t){e.navigateLeft(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",bindKey:o("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(e){e.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",bindKey:o("Ctrl-Right","Option-Right"),exec:function(e){e.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",bindKey:o("Alt-Shift-Right","Command-Shift-Right"),exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",bindKey:o("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(e){e.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",bindKey:o("Shift-Right","Shift-Right"),exec:function(e){e.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",bindKey:o("Right","Right|Ctrl-F"),exec:function(e,t){e.navigateRight(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",bindKey:"Shift-PageDown",exec:function(e){e.selectPageDown()},readOnly:!0},{name:"pagedown",bindKey:o(null,"Option-PageDown"),exec:function(e){e.scrollPageDown()},readOnly:!0},{name:"gotopagedown",bindKey:o("PageDown","PageDown|Ctrl-V"),exec:function(e){e.gotoPageDown()},readOnly:!0},{name:"selectpageup",bindKey:"Shift-PageUp",exec:function(e){e.selectPageUp()},readOnly:!0},{name:"pageup",bindKey:o(null,"Option-PageUp"),exec:function(e){e.scrollPageUp()},readOnly:!0},{name:"gotopageup",bindKey:"PageUp",exec:function(e){e.gotoPageUp()},readOnly:!0},{name:"scrollup",bindKey:o("Ctrl-Up",null),exec:function(e){e.renderer.scrollBy(0,-2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",bindKey:o("Ctrl-Down",null),exec:function(e){e.renderer.scrollBy(0,2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",bindKey:"Shift-Home",exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",bindKey:"Shift-End",exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",bindKey:o("Ctrl-Alt-E","Command-Option-E"),exec:function(e){e.commands.toggleRecording(e)},readOnly:!0},{name:"replaymacro",bindKey:o("Ctrl-Shift-E","Command-Shift-E"),exec:function(e){e.commands.replay(e)},readOnly:!0},{name:"jumptomatching",bindKey:o("Ctrl-P","Ctrl-P"),exec:function(e){e.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",bindKey:o("Ctrl-Shift-P","Ctrl-Shift-P"),exec:function(e){e.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",bindKey:o("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(e){e.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",bindKey:o("null","null"),exec:function(){},passEvent:!0,readOnly:!0},{name:"cut",exec:function(e){var t=e.getSelectionRange();e._emit("cut",t),e.selection.isEmpty()||(e.session.remove(t),e.clearSelection())},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"removeline",bindKey:o("Ctrl-D","Command-D"),exec:function(e){e.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",bindKey:o("Ctrl-Shift-D","Command-Shift-D"),exec:function(e){e.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",bindKey:o("Ctrl-Alt-S","Command-Alt-S"),exec:function(e){e.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",bindKey:o("Ctrl-/","Command-/"),exec:function(e){e.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",bindKey:o("Ctrl-Shift-/","Command-Shift-/"),exec:function(e){e.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",bindKey:o("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(e){e.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",bindKey:o("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(e){e.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",bindKey:o("Ctrl-H","Command-Option-F"),exec:function(e){i.loadModule("ace/ext/searchbox",function(t){t.Search(e,!0)})}},{name:"undo",bindKey:o("Ctrl-Z","Command-Z"),exec:function(e){e.undo()}},{name:"redo",bindKey:o("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(e){e.redo()}},{name:"copylinesup",bindKey:o("Alt-Shift-Up","Command-Option-Up"),exec:function(e){e.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",bindKey:o("Alt-Up","Option-Up"),exec:function(e){e.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",bindKey:o("Alt-Shift-Down","Command-Option-Down"),exec:function(e){e.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",bindKey:o("Alt-Down","Option-Down"),exec:function(e){e.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",bindKey:o("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(e){e.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",bindKey:o("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(e){e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",bindKey:o("Shift-Delete",null),exec:function(e){if(!e.selection.isEmpty())return!1;e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",bindKey:o("Alt-Backspace","Command-Backspace"),exec:function(e){e.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",bindKey:o("Alt-Delete","Ctrl-K"),exec:function(e){e.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",bindKey:o("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(e){e.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",bindKey:o("Ctrl-Delete","Alt-Delete"),exec:function(e){e.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",bindKey:o("Shift-Tab","Shift-Tab"),exec:function(e){e.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",bindKey:o("Tab","Tab"),exec:function(e){e.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",bindKey:o("Ctrl-[","Ctrl-["),exec:function(e){e.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",bindKey:o("Ctrl-]","Ctrl-]"),exec:function(e){e.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",exec:function(e,t){e.insert(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",exec:function(e,t){e.insert(r.stringRepeat(t.text||"",t.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",bindKey:o(null,"Ctrl-O"),exec:function(e){e.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",bindKey:o("Ctrl-T","Ctrl-T"),exec:function(e){e.transposeLetters()},multiSelectAction:function(e){e.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",bindKey:o("Ctrl-U","Ctrl-U"),exec:function(e){e.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",bindKey:o("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(e){e.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"expandtoline",bindKey:o("Ctrl-Shift-L","Command-Shift-L"),exec:function(e){var t=e.selection.getRange();t.start.column=t.end.column=0,t.end.row++,e.selection.setRange(t,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"joinlines",bindKey:o(null,null),exec:function(e){var t=e.selection.isBackwards(),n=t?e.selection.getSelectionLead():e.selection.getSelectionAnchor(),i=t?e.selection.getSelectionAnchor():e.selection.getSelectionLead(),o=e.session.doc.getLine(n.row).length,u=e.session.doc.getTextRange(e.selection.getRange()),a=u.replace(/\n\s*/," ").length,f=e.session.doc.getLine(n.row);for(var l=n.row+1;l<=i.row+1;l++){var c=r.stringTrimLeft(r.stringTrimRight(e.session.doc.getLine(l)));c.length!==0&&(c=" "+c),f+=c}i.row+1<e.session.doc.getLength()-1&&(f+=e.session.doc.getNewLineCharacter()),e.clearSelection(),e.session.doc.replace(new s(n.row,0,i.row+2,0),f),a>0?(e.selection.moveCursorTo(n.row,n.column),e.selection.selectTo(n.row,n.column+a)):(o=e.session.doc.getLine(n.row).length>o?o+1:o,e.selection.moveCursorTo(n.row,o))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",bindKey:o(null,null),exec:function(e){var t=e.session.doc.getLength()-1,n=e.session.doc.getLine(t).length,r=e.selection.rangeList.ranges,i=[];r.length<1&&(r=[e.selection.getRange()]);for(var o=0;o<r.length;o++)o==r.length-1&&(r[o].end.row!==t||r[o].end.column!==n)&&i.push(new s(r[o].end.row,r[o].end.column,t,n)),o===0?(r[o].start.row!==0||r[o].start.column!==0)&&i.push(new s(0,0,r[o].start.row,r[o].start.column)):i.push(new s(r[o-1].end.row,r[o-1].end.column,r[o].start.row,r[o].start.column));e.exitMultiSelectMode(),e.clearSelection();for(var o=0;o<i.length;o++)e.selection.addRange(i[o],!1)},readOnly:!0,scrollIntoView:"none"}]}),ace.define("ace/editor",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/keyboard/textinput","ace/mouse/mouse_handler","ace/mouse/fold_handler","ace/keyboard/keybinding","ace/edit_session","ace/search","ace/range","ace/lib/event_emitter","ace/commands/command_manager","ace/commands/default_commands","ace/config","ace/token_iterator"],function(e,t,n){"use strict";e("./lib/fixoldbrowsers");var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./lib/lang"),o=e("./lib/useragent"),u=e("./keyboard/textinput").TextInput,a=e("./mouse/mouse_handler").MouseHandler,f=e("./mouse/fold_handler").FoldHandler,l=e("./keyboard/keybinding").KeyBinding,c=e("./edit_session").EditSession,h=e("./search").Search,p=e("./range").Range,d=e("./lib/event_emitter").EventEmitter,v=e("./commands/command_manager").CommandManager,m=e("./commands/default_commands").commands,g=e("./config"),y=e("./token_iterator").TokenIterator,b=function(e,t){var n=e.getContainerElement();this.container=n,this.renderer=e,this.commands=new v(o.isMac?"mac":"win",m),this.textInput=new u(e.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.keyBinding=new l(this),this.$mouseHandler=new a(this),new f(this),this.$blockScrolling=0,this.$search=(new h).set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=s.delayedCall(function(){this._signal("input",{}),this.session&&this.session.bgTokenizer&&this.session.bgTokenizer.scheduleStart()}.bind(this)),this.on("change",function(e,t){t._$emitInputEvent.schedule(31)}),this.setSession(t||new c("")),g.resetOptions(this),g._signal("editor",this)};(function(){r.implement(this,d),this.$initOperationListeners=function(){function e(e){return e[e.length-1]}this.selections=[],this.commands.on("exec",this.startOperation.bind(this),!0),this.commands.on("afterExec",this.endOperation.bind(this),!0),this.$opResetTimer=s.delayedCall(this.endOperation.bind(this)),this.on("change",function(){this.curOp||this.startOperation(),this.curOp.docChanged=!0}.bind(this),!0),this.on("changeSelection",function(){this.curOp||this.startOperation(),this.curOp.selectionChanged=!0}.bind(this),!0)},this.curOp=null,this.prevOp={},this.startOperation=function(e){if(this.curOp){if(!e||this.curOp.command)return;this.prevOp=this.curOp}e||(this.previousCommand=null,e={}),this.$opResetTimer.schedule(),this.curOp={command:e.command||{},args:e.args,scrollTop:this.renderer.scrollTop},this.curOp.command.name&&this.$blockScrolling++},this.endOperation=function(e){if(this.curOp){if(e&&e.returnValue===!1)return this.curOp=null;this._signal("beforeEndOperation");var t=this.curOp.command;t.name&&this.$blockScrolling&&this.$blockScrolling--;if(t&&t.scrollIntoView){switch(t.scrollIntoView){case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var n=this.selection.getRange(),r=this.renderer.layerConfig;(n.start.row>=r.lastRow||n.end.row<=r.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break;default:}t.scrollIntoView=="animate"&&this.renderer.animateScrolling(this.curOp.scrollTop)}this.prevOp=this.curOp,this.curOp=null}},this.$mergeableCommands=["backspace","del","insertstring"],this.$historyTracker=function(e){if(!this.$mergeUndoDeltas)return;var t=this.prevOp,n=this.$mergeableCommands,r=t.command&&e.command.name==t.command.name;if(e.command.name=="insertstring"){var i=e.args;this.mergeNextCommand===undefined&&(this.mergeNextCommand=!0),r=r&&this.mergeNextCommand&&(!/\s/.test(i)||/\s/.test(t.args)),this.mergeNextCommand=!0}else r=r&&n.indexOf(e.command.name)!==-1;this.$mergeUndoDeltas!="always"&&Date.now()-this.sequenceStartTime>2e3&&(r=!1),r?this.session.mergeUndoDeltas=!0:n.indexOf(e.command.name)!==-1&&(this.sequenceStartTime=Date.now())},this.setKeyboardHandler=function(e,t){if(e&&typeof e=="string"){this.$keybindingId=e;var n=this;g.loadModule(["keybinding",e],function(r){n.$keybindingId==e&&n.keyBinding.setKeyboardHandler(r&&r.handler),t&&t()})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(e),t&&t()},this.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},this.setSession=function(e){if(this.session==e)return;var t=this.session;if(t){this.session.removeEventListener("change",this.$onDocumentChange),this.session.removeEventListener("changeMode",this.$onChangeMode),this.session.removeEventListener("tokenizerUpdate",this.$onTokenizerUpdate),this.session.removeEventListener("changeTabSize",this.$onChangeTabSize),this.session.removeEventListener("changeWrapLimit",this.$onChangeWrapLimit),this.session.removeEventListener("changeWrapMode",this.$onChangeWrapMode),this.session.removeEventListener("onChangeFold",this.$onChangeFold),this.session.removeEventListener("changeFrontMarker",this.$onChangeFrontMarker),this.session.removeEventListener("changeBackMarker",this.$onChangeBackMarker),this.session.removeEventListener("changeBreakpoint",this.$onChangeBreakpoint),this.session.removeEventListener("changeAnnotation",this.$onChangeAnnotation),this.session.removeEventListener("changeOverwrite",this.$onCursorChange),this.session.removeEventListener("changeScrollTop",this.$onScrollTopChange),this.session.removeEventListener("changeScrollLeft",this.$onScrollLeftChange);var n=this.session.getSelection();n.removeEventListener("changeCursor",this.$onCursorChange),n.removeEventListener("changeSelection",this.$onSelectionChange)}this.session=e,e?(this.$onDocumentChange=this.onDocumentChange.bind(this),e.addEventListener("change",this.$onDocumentChange),this.renderer.setSession(e),this.$onChangeMode=this.onChangeMode.bind(this),e.addEventListener("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),e.addEventListener("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),e.addEventListener("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),e.addEventListener("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),e.addEventListener("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),e.addEventListener("changeFold",this.$onChangeFold),this.$onChangeFrontMarker=this.onChangeFrontMarker.bind(this),this.session.addEventListener("changeFrontMarker",this.$onChangeFrontMarker),this.$onChangeBackMarker=this.onChangeBackMarker.bind(this),this.session.addEventListener("changeBackMarker",this.$onChangeBackMarker),this.$onChangeBreakpoint=this.onChangeBreakpoint.bind(this),this.session.addEventListener("changeBreakpoint",this.$onChangeBreakpoint),this.$onChangeAnnotation=this.onChangeAnnotation.bind(this),this.session.addEventListener("changeAnnotation",this.$onChangeAnnotation),this.$onCursorChange=this.onCursorChange.bind(this),this.session.addEventListener("changeOverwrite",this.$onCursorChange),this.$onScrollTopChange=this.onScrollTopChange.bind(this),this.session.addEventListener("changeScrollTop",this.$onScrollTopChange),this.$onScrollLeftChange=this.onScrollLeftChange.bind(this),this.session.addEventListener("changeScrollLeft",this.$onScrollLeftChange),this.selection=e.getSelection(),this.selection.addEventListener("changeCursor",this.$onCursorChange),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.addEventListener("changeSelection",this.$onSelectionChange),this.onChangeMode(),this.$blockScrolling+=1,this.onCursorChange(),this.$blockScrolling-=1,this.onScrollTopChange(),this.onScrollLeftChange(),this.onSelectionChange(),this.onChangeFrontMarker(),this.onChangeBackMarker(),this.onChangeBreakpoint(),this.onChangeAnnotation(),this.session.getUseWrapMode()&&this.renderer.adjustWrapLimit(),this.renderer.updateFull()):(this.selection=null,this.renderer.setSession(e)),this._signal("changeSession",{session:e,oldSession:t}),t&&t._signal("changeEditor",{oldEditor:this}),e&&e._signal("changeEditor",{editor:this})},this.getSession=function(){return this.session},this.setValue=function(e,t){return this.session.doc.setValue(e),t?t==1?this.navigateFileEnd():t==-1&&this.navigateFileStart():this.selectAll(),e},this.getValue=function(){return this.session.getValue()},this.getSelection=function(){return this.selection},this.resize=function(e){this.renderer.onResize(e)},this.setTheme=function(e,t){this.renderer.setTheme(e,t)},this.getTheme=function(){return this.renderer.getTheme()},this.setStyle=function(e){this.renderer.setStyle(e)},this.unsetStyle=function(e){this.renderer.unsetStyle(e)},this.getFontSize=function(){return this.getOption("fontSize")||i.computedStyle(this.container,"fontSize")},this.setFontSize=function(e){this.setOption("fontSize",e)},this.$highlightBrackets=function(){this.session.$bracketHighlight&&(this.session.removeMarker(this.session.$bracketHighlight),this.session.$bracketHighlight=null);if(this.$highlightPending)return;var e=this;this.$highlightPending=!0,setTimeout(function(){e.$highlightPending=!1;var t=e.session;if(!t||!t.bgTokenizer)return;var n=t.findMatchingBracket(e.getCursorPosition());if(n)var r=new p(n.row,n.column,n.row,n.column+1);else if(t.$mode.getMatching)var r=t.$mode.getMatching(e.session);r&&(t.$bracketHighlight=t.addMarker(r,"ace_bracket","text"))},50)},this.$highlightTags=function(){if(this.$highlightTagPending)return;var e=this;this.$highlightTagPending=!0,setTimeout(function(){e.$highlightTagPending=!1;var t=e.session;if(!t||!t.bgTokenizer)return;var n=e.getCursorPosition(),r=new y(e.session,n.row,n.column),i=r.getCurrentToken();if(!i||!/\b(?:tag-open|tag-name)/.test(i.type)){t.removeMarker(t.$tagHighlight),t.$tagHighlight=null;return}i.type.indexOf("tag-open")!=-1&&(i=r.stepForward());var s=i.value,o=0,u=r.stepBackward();if(u.value=="<"){do u=i,i=r.stepForward(),i&&i.value===s&&i.type.indexOf("tag-name")!==-1&&(u.value==="<"?o++:u.value==="</"&&o--);while(i&&o>=0)}else{do i=u,u=r.stepBackward(),i&&i.value===s&&i.type.indexOf("tag-name")!==-1&&(u.value==="<"?o++:u.value==="</"&&o--);while(u&&o<=0);r.stepForward()}if(!i){t.removeMarker(t.$tagHighlight),t.$tagHighlight=null;return}var a=r.getCurrentTokenRow(),f=r.getCurrentTokenColumn(),l=new p(a,f,a,f+i.value.length);t.$tagHighlight&&l.compareRange(t.$backMarkers[t.$tagHighlight].range)!==0&&(t.removeMarker(t.$tagHighlight),t.$tagHighlight=null),l&&!t.$tagHighlight&&(t.$tagHighlight=t.addMarker(l,"ace_bracket","text"))},50)},this.focus=function(){var e=this;setTimeout(function(){e.textInput.focus()}),this.textInput.focus()},this.isFocused=function(){return this.textInput.isFocused()},this.blur=function(){this.textInput.blur()},this.onFocus=function(e){if(this.$isFocused)return;this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",e)},this.onBlur=function(e){if(!this.$isFocused)return;this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",e)},this.$cursorChange=function(){this.renderer.updateCursor()},this.onDocumentChange=function(e){var t=e.data,n=t.range,r;n.start.row==n.end.row&&t.action!="insertLines"&&t.action!="removeLines"?r=n.end.row:r=Infinity,this.renderer.updateLines(n.start.row,r,this.session.$useWrapMode),this._signal("change",e),this.$cursorChange(),this.$updateHighlightActiveLine()},this.onTokenizerUpdate=function(e){var t=e.data;this.renderer.updateLines(t.first,t.last)},this.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},this.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},this.onCursorChange=function(){this.$cursorChange(),this.$blockScrolling||(g.warn("Automatically scrolling cursor into view after selection change","this will be disabled in the next version","set editor.$blockScrolling = Infinity to disable this message"),this.renderer.scrollCursorIntoView()),this.$highlightBrackets(),this.$highlightTags(),this.$updateHighlightActiveLine(),this._signal("changeSelection")},this.$updateHighlightActiveLine=function(){var e=this.getSession(),t;if(this.$highlightActiveLine){if(this.$selectionStyle!="line"||!this.selection.isMultiLine())t=this.getCursorPosition();this.renderer.$maxLines&&this.session.getLength()===1&&!(this.renderer.$minLines>1)&&(t=!1)}if(e.$highlightLineMarker&&!t)e.removeMarker(e.$highlightLineMarker.id),e.$highlightLineMarker=null;else if(!e.$highlightLineMarker&&t){var n=new p(t.row,t.column,t.row,Infinity);n.id=e.addMarker(n,"ace_active-line","screenLine"),e.$highlightLineMarker=n}else t&&(e.$highlightLineMarker.start.row=t.row,e.$highlightLineMarker.end.row=t.row,e.$highlightLineMarker.start.column=t.column,e._signal("changeBackMarker"))},this.onSelectionChange=function(e){var t=this.session;t.$selectionMarker&&t.removeMarker(t.$selectionMarker),t.$selectionMarker=null;if(!this.selection.isEmpty()){var n=this.selection.getRange(),r=this.getSelectionStyle();t.$selectionMarker=t.addMarker(n,"ace_selection",r)}else this.$updateHighlightActiveLine();var i=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(i),this._signal("changeSelection")},this.$getSelectionHighLightRegexp=function(){var e=this.session,t=this.getSelectionRange();if(t.isEmpty()||t.isMultiLine())return;var n=t.start.column-1,r=t.end.column+1,i=e.getLine(t.start.row),s=i.length,o=i.substring(Math.max(n,0),Math.min(r,s));if(n>=0&&/^[\w\d]/.test(o)||r<=s&&/[\w\d]$/.test(o))return;o=i.substring(t.start.column,t.end.column);if(!/^[\w\d]+$/.test(o))return;var u=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:o});return u},this.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},this.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},this.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},this.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},this.onChangeMode=function(e){this.renderer.updateText(),this._emit("changeMode",e)},this.onChangeWrapLimit=function(){this.renderer.updateFull()},this.onChangeWrapMode=function(){this.renderer.onResize(!0)},this.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},this.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},this.getCopyText=function(){var e=this.getSelectedText();return this._signal("copy",e),e},this.onCopy=function(){this.commands.exec("copy",this)},this.onCut=function(){this.commands.exec("cut",this)},this.onPaste=function(e){if(this.$readOnly)return;var t={text:e};this._signal("paste",t),e=t.text;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)this.insert(e);else{var n=e.split(/\r\n|\r|\n/),r=this.selection.rangeList.ranges;if(n.length>r.length||n.length<2||!n[1])return this.commands.exec("insertstring",this,e);for(var i=r.length;i--;){var s=r[i];s.isEmpty()||this.session.remove(s),this.session.insert(s.start,n[i])}}this.renderer.scrollCursorIntoView()},this.execCommand=function(e,t){return this.commands.exec(e,this,t)},this.insert=function(e,t){var n=this.session,r=n.getMode(),i=this.getCursorPosition();if(this.getBehavioursEnabled()&&!t){var s=r.transformAction(n.getState(i.row),"insertion",this,n,e);s&&(e!==s.text&&(this.session.mergeUndoDeltas=!1,this.$mergeNextCommand=!1),e=s.text)}e==" "&&(e=this.session.getTabString());if(!this.selection.isEmpty()){var o=this.getSelectionRange();i=this.session.remove(o),this.clearSelection()}else if(this.session.getOverwrite()){var o=new p.fromPoints(i,i);o.end.column+=e.length,this.session.remove(o)}if(e=="\n"||e=="\r\n"){var u=n.getLine(i.row);if(i.column>u.search(/\S|$/)){var a=u.substr(i.column).search(/\S|$/);n.doc.removeInLine(i.row,i.column,i.column+a)}}this.clearSelection();var f=i.column,l=n.getState(i.row),u=n.getLine(i.row),c=r.checkOutdent(l,u,e),h=n.insert(i,e);s&&s.selection&&(s.selection.length==2?this.selection.setSelectionRange(new p(i.row,f+s.selection[0],i.row,f+s.selection[1])):this.selection.setSelectionRange(new p(i.row+s.selection[0],s.selection[1],i.row+s.selection[2],s.selection[3])));if(n.getDocument().isNewLine(e)){var d=r.getNextLineIndent(l,u.slice(0,i.column),n.getTabString());n.insert({row:i.row+1,column:0},d)}c&&r.autoOutdent(l,n,i.row)},this.onTextInput=function(e){this.keyBinding.onTextInput(e)},this.onCommandKey=function(e,t,n){this.keyBinding.onCommandKey(e,t,n)},this.setOverwrite=function(e){this.session.setOverwrite(e)},this.getOverwrite=function(){return this.session.getOverwrite()},this.toggleOverwrite=function(){this.session.toggleOverwrite()},this.setScrollSpeed=function(e){this.setOption("scrollSpeed",e)},this.getScrollSpeed=function(){return this.getOption("scrollSpeed")},this.setDragDelay=function(e){this.setOption("dragDelay",e)},this.getDragDelay=function(){return this.getOption("dragDelay")},this.setSelectionStyle=function(e){this.setOption("selectionStyle",e)},this.getSelectionStyle=function(){return this.getOption("selectionStyle")},this.setHighlightActiveLine=function(e){this.setOption("highlightActiveLine",e)},this.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},this.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.setHighlightSelectedWord=function(e){this.setOption("highlightSelectedWord",e)},this.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},this.setAnimatedScroll=function(e){this.renderer.setAnimatedScroll(e)},this.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},this.setShowInvisibles=function(e){this.renderer.setShowInvisibles(e)},this.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},this.setDisplayIndentGuides=function(e){this.renderer.setDisplayIndentGuides(e)},this.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},this.setShowPrintMargin=function(e){this.renderer.setShowPrintMargin(e)},this.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},this.setPrintMarginColumn=function(e){this.renderer.setPrintMarginColumn(e)},this.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},this.setReadOnly=function(e){this.setOption("readOnly",e)},this.getReadOnly=function(){return this.getOption("readOnly")},this.setBehavioursEnabled=function(e){this.setOption("behavioursEnabled",e)},this.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},this.setWrapBehavioursEnabled=function(e){this.setOption("wrapBehavioursEnabled",e)},this.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},this.setShowFoldWidgets=function(e){this.setOption("showFoldWidgets",e)},this.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},this.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.remove=function(e){this.selection.isEmpty()&&(e=="left"?this.selection.selectLeft():this.selection.selectRight());var t=this.getSelectionRange();if(this.getBehavioursEnabled()){var n=this.session,r=n.getState(t.start.row),i=n.getMode().transformAction(r,"deletion",this,n,t);if(t.end.column===0){var s=n.getTextRange(t);if(s[s.length-1]=="\n"){var o=n.getLine(t.end.row);/^\s+$/.test(o)&&(t.end.column=o.length)}}i&&(t=i)}this.session.remove(t),this.clearSelection()},this.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var e=this.getSelectionRange();e.start.column==e.end.column&&e.start.row==e.end.row&&(e.end.column=0,e.end.row++),this.session.remove(e),this.clearSelection()},this.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var e=this.getCursorPosition();this.insert("\n"),this.moveCursorToPosition(e)},this.transposeLetters=function(){if(!this.selection.isEmpty())return;var e=this.getCursorPosition(),t=e.column;if(t===0)return;var n=this.session.getLine(e.row),r,i;t<n.length?(r=n.charAt(t)+n.charAt(t-1),i=new p(e.row,t-1,e.row,t+1)):(r=n.charAt(t-1)+n.charAt(t-2),i=new p(e.row,t-2,e.row,t)),this.session.replace(i,r)},this.toLowerCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toLowerCase()),this.selection.setSelectionRange(e)},this.toUpperCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toUpperCase()),this.selection.setSelectionRange(e)},this.indent=function(){var e=this.session,t=this.getSelectionRange();if(t.start.row<t.end.row){var n=this.$getSelectedRows();e.indentRows(n.first,n.last," ");return}if(t.start.column<t.end.column){var r=e.getTextRange(t);if(!/^\s+$/.test(r)){var n=this.$getSelectedRows();e.indentRows(n.first,n.last," ");return}}var i=e.getLine(t.start.row),o=t.start,u=e.getTabSize(),a=e.documentToScreenColumn(o.row,o.column);if(this.session.getUseSoftTabs())var f=u-a%u,l=s.stringRepeat(" ",f);else{var f=a%u;while(i[t.start.column]==" "&&f)t.start.column--,f--;this.selection.setSelectionRange(t),l=" "}return this.insert(l)},this.blockIndent=function(){var e=this.$getSelectedRows();this.session.indentRows(e.first,e.last," ")},this.blockOutdent=function(){var e=this.session.getSelection();this.session.outdentRows(e.getRange())},this.sortLines=function(){var e=this.$getSelectedRows(),t=this.session,n=[];for(i=e.first;i<=e.last;i++)n.push(t.getLine(i));n.sort(function(e,t){return e.toLowerCase()<t.toLowerCase()?-1:e.toLowerCase()>t.toLowerCase()?1:0});var r=new p(0,0,0,0);for(var i=e.first;i<=e.last;i++){var s=t.getLine(i);r.start.row=i,r.end.row=i,r.end.column=s.length,t.replace(r,n[i-e.first])}},this.toggleCommentLines=function(){var e=this.session.getState(this.getCursorPosition().row),t=this.$getSelectedRows();this.session.getMode().toggleCommentLines(e,this.session,t.first,t.last)},this.toggleBlockComment=function(){var e=this.getCursorPosition(),t=this.session.getState(e.row),n=this.getSelectionRange();this.session.getMode().toggleBlockComment(t,this.session,n,e)},this.getNumberAt=function(e,t){var n=/[\-]?[0-9]+(?:\.[0-9]+)?/g;n.lastIndex=0;var r=this.session.getLine(e);while(n.lastIndex<t){var i=n.exec(r);if(i.index<=t&&i.index+i[0].length>=t){var s={value:i[0],start:i.index,end:i.index+i[0].length};return s}}return null},this.modifyNumber=function(e){var t=this.selection.getCursor().row,n=this.selection.getCursor().column,r=new p(t,n-1,t,n),i=this.session.getTextRange(r);if(!isNaN(parseFloat(i))&&isFinite(i)){var s=this.getNumberAt(t,n);if(s){var o=s.value.indexOf(".")>=0?s.start+s.value.indexOf(".")+1:s.end,u=s.start+s.value.length-o,a=parseFloat(s.value);a*=Math.pow(10,u),o!==s.end&&n<o?e*=Math.pow(10,s.end-n-1):e*=Math.pow(10,s.end-n),a+=e,a/=Math.pow(10,u);var f=a.toFixed(u),l=new p(t,s.start,t,s.end);this.session.replace(l,f),this.moveCursorTo(t,Math.max(s.start+1,n+f.length-s.value.length))}}},this.removeLines=function(){var e=this.$getSelectedRows(),t;e.first===0||e.last+1<this.session.getLength()?t=new p(e.first,0,e.last+1,0):t=new p(e.first-1,this.session.getLine(e.first-1).length,e.last,this.session.getLine(e.last).length),this.session.remove(t),this.clearSelection()},this.duplicateSelection=function(){var e=this.selection,t=this.session,n=e.getRange(),r=e.isBackwards();if(n.isEmpty()){var i=n.start.row;t.duplicateLines(i,i)}else{var s=r?n.start:n.end,o=t.insert(s,t.getTextRange(n),!1);n.start=s,n.end=o,e.setSelectionRange(n,r)}},this.moveLinesDown=function(){this.$moveLines(1,!1)},this.moveLinesUp=function(){this.$moveLines(-1,!1)},this.moveText=function(e,t,n){return this.session.moveText(e,t,n)},this.copyLinesUp=function(){this.$moveLines(-1,!0)},this.copyLinesDown=function(){this.$moveLines(1,!0)},this.$moveLines=function(e,t){var n,r,i=this.selection;if(!i.inMultiSelectMode||this.inVirtualSelectionMode){var s=i.toOrientedRange();n=this.$getSelectedRows(s),r=this.session.$moveLines(n.first,n.last,t?0:e),t&&e==-1&&(r=0),s.moveBy(r,0),i.fromOrientedRange(s)}else{var o=i.rangeList.ranges;i.rangeList.detach(this.session),this.inVirtualSelectionMode=!0;var u=0,a=0,f=o.length;for(var l=0;l<f;l++){var c=l;o[l].moveBy(u,0),n=this.$getSelectedRows(o[l]);var h=n.first,p=n.last;while(++l<f){a&&o[l].moveBy(a,0);var d=this.$getSelectedRows(o[l]);if(t&&d.first!=p)break;if(!t&&d.first>p+1)break;p=d.last}l--,u=this.session.$moveLines(h,p,t?0:e),t&&e==-1&&(c=l+1);while(c<=l)o[c].moveBy(u,0),c++;t||(u=0),a+=u}i.fromOrientedRange(i.ranges[0]),i.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},this.$getSelectedRows=function(e){return e=(e||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(e.start.row),last:this.session.getRowFoldEnd(e.end.row)}},this.onCompositionStart=function(e){this.renderer.showComposition(this.getCursorPosition())},this.onCompositionUpdate=function(e){this.renderer.setCompositionText(e)},this.onCompositionEnd=function(){this.renderer.hideComposition()},this.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},this.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},this.isRowVisible=function(e){return e>=this.getFirstVisibleRow()&&e<=this.getLastVisibleRow()},this.isRowFullyVisible=function(e){return e>=this.renderer.getFirstFullyVisibleRow()&&e<=this.renderer.getLastFullyVisibleRow()},this.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},this.$moveByPage=function(e,t){var n=this.renderer,r=this.renderer.layerConfig,i=e*Math.floor(r.height/r.lineHeight);this.$blockScrolling++,t===!0?this.selection.$moveSelection(function(){this.moveCursorBy(i,0)}):t===!1&&(this.selection.moveCursorBy(i,0),this.selection.clearSelection()),this.$blockScrolling--;var s=n.scrollTop;n.scrollBy(0,i*r.lineHeight),t!=null&&n.scrollCursorIntoView(null,.5),n.animateScrolling(s)},this.selectPageDown=function(){this.$moveByPage(1,!0)},this.selectPageUp=function(){this.$moveByPage(-1,!0)},this.gotoPageDown=function(){this.$moveByPage(1,!1)},this.gotoPageUp=function(){this.$moveByPage(-1,!1)},this.scrollPageDown=function(){this.$moveByPage(1)},this.scrollPageUp=function(){this.$moveByPage(-1)},this.scrollToRow=function(e){this.renderer.scrollToRow(e)},this.scrollToLine=function(e,t,n,r){this.renderer.scrollToLine(e,t,n,r)},this.centerSelection=function(){var e=this.getSelectionRange(),t={row:Math.floor(e.start.row+(e.end.row-e.start.row)/2),column:Math.floor(e.start.column+(e.end.column-e.start.column)/2)};this.renderer.alignCursor(t,.5)},this.getCursorPosition=function(){return this.selection.getCursor()},this.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},this.getSelectionRange=function(){return this.selection.getRange()},this.selectAll=function(){this.$blockScrolling+=1,this.selection.selectAll(),this.$blockScrolling-=1},this.clearSelection=function(){this.selection.clearSelection()},this.moveCursorTo=function(e,t){this.selection.moveCursorTo(e,t)},this.moveCursorToPosition=function(e){this.selection.moveCursorToPosition(e)},this.jumpToMatching=function(e,t){var n=this.getCursorPosition(),r=new y(this.session,n.row,n.column),i=r.getCurrentToken(),s=i||r.stepForward();if(!s)return;var o,u=!1,a={},f=n.column-s.start,l,c={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(s.value.match(/[{}()\[\]]/g))for(;f<s.value.length&&!u;f++){if(!c[s.value[f]])continue;l=c[s.value[f]]+"."+s.type.replace("rparen","lparen"),isNaN(a[l])&&(a[l]=0);switch(s.value[f]){case"(":case"[":case"{":a[l]++;break;case")":case"]":case"}":a[l]--,a[l]===-1&&(o="bracket",u=!0)}}else s&&s.type.indexOf("tag-name")!==-1&&(isNaN(a[s.value])&&(a[s.value]=0),i.value==="<"?a[s.value]++:i.value==="</"&&a[s.value]--,a[s.value]===-1&&(o="tag",u=!0));u||(i=s,s=r.stepForward(),f=0)}while(s&&!u);if(!o)return;var h,d;if(o==="bracket"){h=this.session.getBracketRange(n);if(!h){h=new p(r.getCurrentTokenRow(),r.getCurrentTokenColumn()+f-1,r.getCurrentTokenRow(),r.getCurrentTokenColumn()+f-1),d=h.start;if(t||d.row===n.row&&Math.abs(d.column-n.column)<2)h=this.session.getBracketRange(d)}}else if(o==="tag"){if(!s||s.type.indexOf("tag-name")===-1)return;var v=s.value;h=new p(r.getCurrentTokenRow(),r.getCurrentTokenColumn()-2,r.getCurrentTokenRow(),r.getCurrentTokenColumn()-2);if(h.compare(n.row,n.column)===0){u=!1;do s=i,i=r.stepBackward(),i&&(i.type.indexOf("tag-close")!==-1&&h.setEnd(r.getCurrentTokenRow(),r.getCurrentTokenColumn()+1),s.value===v&&s.type.indexOf("tag-name")!==-1&&(i.value==="<"?a[v]++:i.value==="</"&&a[v]--,a[v]===0&&(u=!0)));while(i&&!u)}s&&s.type.indexOf("tag-name")&&(d=h.start,d.row==n.row&&Math.abs(d.column-n.column)<2&&(d=h.end))}d=h&&h.cursor||d,d&&(e?h&&t?this.selection.setRange(h):h&&h.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(d.row,d.column):this.selection.moveTo(d.row,d.column))},this.gotoLine=function(e,t,n){this.selection.clearSelection(),this.session.unfold({row:e-1,column:t||0}),this.$blockScrolling+=1,this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(e-1,t||0),this.$blockScrolling-=1,this.isRowFullyVisible(e-1)||this.scrollToLine(e-1,!0,n)},this.navigateTo=function(e,t){this.selection.moveTo(e,t)},this.navigateUp=function(e){if(this.selection.isMultiLine()&&!this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(-e||-1,0)},this.navigateDown=function(e){if(this.selection.isMultiLine()&&this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(e||1,0)},this.navigateLeft=function(e){if(!this.selection.isEmpty()){var t=this.getSelectionRange().start;this.moveCursorToPosition(t)}else{e=e||1;while(e--)this.selection.moveCursorLeft()}this.clearSelection()},this.navigateRight=function(e){if(!this.selection.isEmpty()){var t=this.getSelectionRange().end;this.moveCursorToPosition(t)}else{e=e||1;while(e--)this.selection.moveCursorRight()}this.clearSelection()},this.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},this.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},this.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},this.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},this.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},this.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},this.replace=function(e,t){t&&this.$search.set(t);var n=this.$search.find(this.session),r=0;return n?(this.$tryReplace(n,e)&&(r=1),n!==null&&(this.selection.setSelectionRange(n),this.renderer.scrollSelectionIntoView(n.start,n.end)),r):r},this.replaceAll=function(e,t){t&&this.$search.set(t);var n=this.$search.findAll(this.session),r=0;if(!n.length)return r;this.$blockScrolling+=1;var i=this.getSelectionRange();this.selection.moveTo(0,0);for(var s=n.length-1;s>=0;--s)this.$tryReplace(n[s],e)&&r++;return this.selection.setSelectionRange(i),this.$blockScrolling-=1,r},this.$tryReplace=function(e,t){var n=this.session.getTextRange(e);return t=this.$search.replace(n,t),t!==null?(e.end=this.session.replace(e,t),e):null},this.getLastSearchOptions=function(){return this.$search.getOptions()},this.find=function(e,t,n){t||(t={}),typeof e=="string"||e instanceof RegExp?t.needle=e:typeof e=="object"&&r.mixin(t,e);var i=this.selection.getRange();t.needle==null&&(e=this.session.getTextRange(i)||this.$search.$options.needle,e||(i=this.session.getWordRange(i.start.row,i.start.column),e=this.session.getTextRange(i)),this.$search.set({needle:e})),this.$search.set(t),t.start||this.$search.set({start:i});var s=this.$search.find(this.session);if(t.preventScroll)return s;if(s)return this.revealRange(s,n),s;t.backwards?i.start=i.end:i.end=i.start,this.selection.setRange(i)},this.findNext=function(e,t){this.find({skipCurrent:!0,backwards:!1},e,t)},this.findPrevious=function(e,t){this.find(e,{skipCurrent:!0,backwards:!0},t)},this.revealRange=function(e,t){this.$blockScrolling+=1,this.session.unfold(e),this.selection.setSelectionRange(e),this.$blockScrolling-=1;var n=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(e.start,e.end,.5),t!==!1&&this.renderer.animateScrolling(n)},this.undo=function(){this.$blockScrolling++,this.session.getUndoManager().undo(),this.$blockScrolling--,this.renderer.scrollCursorIntoView(null,.5)},this.redo=function(){this.$blockScrolling++,this.session.getUndoManager().redo(),this.$blockScrolling--,this.renderer.scrollCursorIntoView(null,.5)},this.destroy=function(){this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy()},this.setAutoScrollEditorIntoView=function(e){if(!e)return;var t,n=this,r=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var i=this.$scrollAnchor;i.style.cssText="position:absolute",this.container.insertBefore(i,this.container.firstChild);var s=this.on("changeSelection",function(){r=!0}),o=this.renderer.on("beforeRender",function(){r&&(t=n.renderer.container.getBoundingClientRect())}),u=this.renderer.on("afterRender",function(){if(r&&t&&(n.isFocused()||n.searchBox&&n.searchBox.isFocused())){var e=n.renderer,s=e.$cursorLayer.$pixelPos,o=e.layerConfig,u=s.top-o.offset;s.top>=0&&u+t.top<0?r=!0:s.top<o.height&&s.top+t.top+o.lineHeight>window.innerHeight?r=!1:r=null,r!=null&&(i.style.top=u+"px",i.style.left=s.left+"px",i.style.height=o.lineHeight+"px",i.scrollIntoView(r)),r=t=null}});this.setAutoScrollEditorIntoView=function(e){if(e)return;delete this.setAutoScrollEditorIntoView,this.removeEventListener("changeSelection",s),this.renderer.removeEventListener("afterRender",u),this.renderer.removeEventListener("beforeRender",o)}},this.$resetCursorStyle=function(){var e=this.$cursorStyle||"ace",t=this.renderer.$cursorLayer;if(!t)return;t.setSmoothBlinking(/smooth/.test(e)),t.isBlinking=!this.$readOnly&&e!="wide",i.setCssClass(t.element,"ace_slim-cursors",/slim/.test(e))}}).call(b.prototype),g.defineOptions(b.prototype,"editor",{selectionStyle:{set:function(e){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:e})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(e){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(e){this.$resetCursorStyle()},initialValue:!1},cursorStyle:{set:function(e){this.$resetCursorStyle()},values:["ace","slim","smooth","wide"],initialValue:"ace"},mergeUndoDeltas:{values:[!1,!0,"always"],initialValue:!0},behavioursEnabled:{initialValue:!0},wrapBehavioursEnabled:{initialValue:!0},autoScrollEditorIntoView:{set:function(e){this.setAutoScrollEditorIntoView(e)}},hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",showLineNumbers:"renderer",showGutter:"renderer",displayIndentGuides:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimout:"$mouseHandler",tooltipFollowsMouse:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",tabSize:"session",wrap:"session",foldStyle:"session",mode:"session"}),t.Editor=b}),ace.define("ace/undomanager",["require","exports","module"],function(e,t,n){"use strict";var r=function(){this.reset()};(function(){this.execute=function(e){var t=e.args[0];this.$doc=e.args[1],e.merge&&this.hasUndo()&&(this.dirtyCounter--,t=this.$undoStack.pop().concat(t)),this.$undoStack.push(t),this.$redoStack=[],this.dirtyCounter<0&&(this.dirtyCounter=NaN),this.dirtyCounter++},this.undo=function(e){var t=this.$undoStack.pop(),n=null;return t&&(n=this.$doc.undoChanges(t,e),this.$redoStack.push(t),this.dirtyCounter--),n},this.redo=function(e){var t=this.$redoStack.pop(),n=null;return t&&(n=this.$doc.redoChanges(t,e),this.$undoStack.push(t),this.dirtyCounter++),n},this.reset=function(){this.$undoStack=[],this.$redoStack=[],this.dirtyCounter=0},this.hasUndo=function(){return this.$undoStack.length>0},this.hasRedo=function(){return this.$redoStack.length>0},this.markClean=function(){this.dirtyCounter=0},this.isClean=function(){return this.dirtyCounter===0}}).call(r.prototype),t.UndoManager=r}),ace.define("ace/layer/gutter",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/dom"),i=e("../lib/oop"),s=e("../lib/lang"),o=e("../lib/event_emitter").EventEmitter,u=function(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_gutter-layer",e.appendChild(this.element),this.setShowFoldWidgets(this.$showFoldWidgets),this.gutterWidth=0,this.$annotations=[],this.$updateAnnotations=this.$updateAnnotations.bind(this),this.$cells=[]};(function(){i.implement(this,o),this.setSession=function(e){this.session&&this.session.removeEventListener("change",this.$updateAnnotations),this.session=e,e&&e.on("change",this.$updateAnnotations)},this.addGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(e,t)},this.removeGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(e,t)},this.setAnnotations=function(e){this.$annotations=[];for(var t=0;t<e.length;t++){var n=e[t],r=n.row,i=this.$annotations[r];i||(i=this.$annotations[r]={text:[]});var o=n.text;o=o?s.escapeHTML(o):n.html||"",i.text.indexOf(o)===-1&&i.text.push(o);var u=n.type;u=="error"?i.className=" ace_error":u=="warning"&&i.className!=" ace_error"?i.className=" ace_warning":u=="info"&&!i.className&&(i.className=" ace_info")}},this.$updateAnnotations=function(e){if(!this.$annotations.length)return;var t=e.data,n=t.range,r=n.start.row,i=n.end.row-r;if(i!==0)if(t.action=="removeText"||t.action=="removeLines")this.$annotations.splice(r,i+1,null);else{var s=new Array(i+1);s.unshift(r,1),this.$annotations.splice.apply(this.$annotations,s)}},this.update=function(e){var t=this.session,n=e.firstRow,i=Math.min(e.lastRow+e.gutterOffset,t.getLength()-1),s=t.getNextFoldLine(n),o=s?s.start.row:Infinity,u=this.$showFoldWidgets&&t.foldWidgets,a=t.$breakpoints,f=t.$decorations,l=t.$firstLineNumber,c=0,h=t.gutterRenderer||this.$renderer,p=null,d=-1,v=n;for(;;){v>o&&(v=s.end.row+1,s=t.getNextFoldLine(v,s),o=s?s.start.row:Infinity);if(v>i){while(this.$cells.length>d+1)p=this.$cells.pop(),this.element.removeChild(p.element);break}p=this.$cells[++d],p||(p={element:null,textNode:null,foldWidget:null},p.element=r.createElement("div"),p.textNode=document.createTextNode(""),p.element.appendChild(p.textNode),this.element.appendChild(p.element),this.$cells[d]=p);var m="ace_gutter-cell ";a[v]&&(m+=a[v]),f[v]&&(m+=f[v]),this.$annotations[v]&&(m+=this.$annotations[v].className),p.element.className!=m&&(p.element.className=m);var g=t.getRowLength(v)*e.lineHeight+"px";g!=p.element.style.height&&(p.element.style.height=g);if(u){var y=u[v];y==null&&(y=u[v]=t.getFoldWidget(v))}if(y){p.foldWidget||(p.foldWidget=r.createElement("span"),p.element.appendChild(p.foldWidget));var m="ace_fold-widget ace_"+y;y=="start"&&v==o&&v<s.end.row?m+=" ace_closed":m+=" ace_open",p.foldWidget.className!=m&&(p.foldWidget.className=m);var g=e.lineHeight+"px";p.foldWidget.style.height!=g&&(p.foldWidget.style.height=g)}else p.foldWidget&&(p.element.removeChild(p.foldWidget),p.foldWidget=null);var b=c=h?h.getText(t,v):v+l;b!=p.textNode.data&&(p.textNode.data=b),v++}this.element.style.height=e.minHeight+"px";if(this.$fixedWidth||t.$useWrapMode)c=t.getLength()+l;var w=h?h.getWidth(t,c,e):c.toString().length*e.characterWidth,E=this.$padding||this.$computePadding();w+=E.left+E.right,w!==this.gutterWidth&&!isNaN(w)&&(this.gutterWidth=w,this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._emit("changeGutterWidth",w))},this.$fixedWidth=!1,this.$showLineNumbers=!0,this.$renderer="",this.setShowLineNumbers=function(e){this.$renderer=!e&&{getWidth:function(){return""},getText:function(){return""}}},this.getShowLineNumbers=function(){return this.$showLineNumbers},this.$showFoldWidgets=!0,this.setShowFoldWidgets=function(e){e?r.addCssClass(this.element,"ace_folding-enabled"):r.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=e,this.$padding=null},this.getShowFoldWidgets=function(){return this.$showFoldWidgets},this.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var e=r.computedStyle(this.element.firstChild);return this.$padding={},this.$padding.left=parseInt(e.paddingLeft)+1||0,this.$padding.right=parseInt(e.paddingRight)||0,this.$padding},this.getRegion=function(e){var t=this.$padding||this.$computePadding(),n=this.element.getBoundingClientRect();if(e.x<t.left+n.left)return"markers";if(this.$showFoldWidgets&&e.x>n.right-t.right)return"foldWidgets"}}).call(u.prototype),t.Gutter=u}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../range").Range,i=e("../lib/dom"),s=function(e){this.element=i.createElement("div"),this.element.className="ace_layer ace_marker-layer",e.appendChild(this.element)};(function(){this.$padding=0,this.setPadding=function(e){this.$padding=e},this.setSession=function(e){this.session=e},this.setMarkers=function(e){this.markers=e},this.update=function(e){var e=e||this.config;if(!e)return;this.config=e;var t=[];for(var n in this.markers){var r=this.markers[n];if(!r.range){r.update(t,this,this.session,e);continue}var i=r.range.clipRows(e.firstRow,e.lastRow);if(i.isEmpty())continue;i=i.toScreenRange(this.session);if(r.renderer){var s=this.$getTop(i.start.row,e),o=this.$padding+i.start.column*e.characterWidth;r.renderer(t,i,o,s,e)}else r.type=="fullLine"?this.drawFullLineMarker(t,i,r.clazz,e):r.type=="screenLine"?this.drawScreenLineMarker(t,i,r.clazz,e):i.isMultiLine()?r.type=="text"?this.drawTextMarker(t,i,r.clazz,e):this.drawMultiLineMarker(t,i,r.clazz,e):this.drawSingleLineMarker(t,i,r.clazz+" ace_start",e)}this.element.innerHTML=t.join("")},this.$getTop=function(e,t){return(e-t.firstRowScreen)*t.lineHeight},this.drawTextMarker=function(e,t,n,i,s){var o=t.start.row,u=new r(o,t.start.column,o,this.session.getScreenLastRowColumn(o));this.drawSingleLineMarker(e,u,n+" ace_start",i,1,s),o=t.end.row,u=new r(o,0,o,t.end.column),this.drawSingleLineMarker(e,u,n,i,0,s);for(o=t.start.row+1;o<t.end.row;o++)u.start.row=o,u.end.row=o,u.end.column=this.session.getScreenLastRowColumn(o),this.drawSingleLineMarker(e,u,n,i,1,s)},this.drawMultiLineMarker=function(e,t,n,r,i){var s=this.$padding,o=r.lineHeight,u=this.$getTop(t.start.row,r),a=s+t.start.column*r.characterWidth;i=i||"",e.push("<div class='",n," ace_start' style='","height:",o,"px;","right:0;","top:",u,"px;","left:",a,"px;",i,"'></div>"),u=this.$getTop(t.end.row,r);var f=t.end.column*r.characterWidth;e.push("<div class='",n,"' style='","height:",o,"px;","width:",f,"px;","top:",u,"px;","left:",s,"px;",i,"'></div>"),o=(t.end.row-t.start.row-1)*r.lineHeight;if(o<0)return;u=this.$getTop(t.start.row+1,r),e.push("<div class='",n,"' style='","height:",o,"px;","right:0;","top:",u,"px;","left:",s,"px;",i,"'></div>")},this.drawSingleLineMarker=function(e,t,n,r,i,s){var o=r.lineHeight,u=(t.end.column+(i||0)-t.start.column)*r.characterWidth,a=this.$getTop(t.start.row,r),f=this.$padding+t.start.column*r.characterWidth;e.push("<div class='",n,"' style='","height:",o,"px;","width:",u,"px;","top:",a,"px;","left:",f,"px;",s||"","'></div>")},this.drawFullLineMarker=function(e,t,n,r,i){var s=this.$getTop(t.start.row,r),o=r.lineHeight;t.start.row!=t.end.row&&(o+=this.$getTop(t.end.row,r)-s),e.push("<div class='",n,"' style='","height:",o,"px;","top:",s,"px;","left:0;right:0;",i||"","'></div>")},this.drawScreenLineMarker=function(e,t,n,r,i){var s=this.$getTop(t.start.row,r),o=r.lineHeight;e.push("<div class='",n,"' style='","height:",o,"px;","top:",s,"px;","left:0;right:0;",i||"","'></div>")}}).call(s.prototype),t.Marker=s}),ace.define("ace/layer/text",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../lib/dom"),s=e("../lib/lang"),o=e("../lib/useragent"),u=e("../lib/event_emitter").EventEmitter,a=function(e){this.element=i.createElement("div"),this.element.className="ace_layer ace_text-layer",e.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this)};(function(){r.implement(this,u),this.EOF_CHAR="\u00b6",this.EOL_CHAR_LF="\u00ac",this.EOL_CHAR_CRLF="\u00a4",this.EOL_CHAR=this.EOL_CHAR_LF,this.TAB_CHAR="\u2192",this.SPACE_CHAR="\u00b7",this.$padding=0,this.$updateEolChar=function(){var e=this.session.doc.getNewLineCharacter()=="\n"?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=e)return this.EOL_CHAR=e,!0},this.setPadding=function(e){this.$padding=e,this.element.style.padding="0 "+e+"px"},this.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},this.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},this.$setFontMetrics=function(e){this.$fontMetrics=e,this.$fontMetrics.on("changeCharacterSize",function(e){this._signal("changeCharacterSize",e)}.bind(this)),this.$pollSizeChanges()},this.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},this.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},this.setSession=function(e){this.session=e,e&&this.$computeTabString()},this.showInvisibles=!1,this.setShowInvisibles=function(e){return this.showInvisibles==e?!1:(this.showInvisibles=e,this.$computeTabString(),!0)},this.displayIndentGuides=!0,this.setDisplayIndentGuides=function(e){return this.displayIndentGuides==e?!1:(this.displayIndentGuides=e,this.$computeTabString(),!0)},this.$tabStrings=[],this.onChangeTabSize=this.$computeTabString=function(){var e=this.session.getTabSize();this.tabSize=e;var t=this.$tabStrings=[0];for(var n=1;n<e+1;n++)this.showInvisibles?t.push("<span class='ace_invisible ace_invisible_tab'>"+this.TAB_CHAR+s.stringRepeat("\u00a0",n-1)+"</span>"):t.push(s.stringRepeat("\u00a0",n));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;var r="ace_indent-guide",i="",o="";if(this.showInvisibles){r+=" ace_invisible",i=" ace_invisible_space",o=" ace_invisible_tab";var u=s.stringRepeat(this.SPACE_CHAR,this.tabSize),a=this.TAB_CHAR+s.stringRepeat("\u00a0",this.tabSize-1)}else var u=s.stringRepeat("\u00a0",this.tabSize),a=u;this.$tabStrings[" "]="<span class='"+r+i+"'>"+u+"</span>",this.$tabStrings[" "]="<span class='"+r+o+"'>"+a+"</span>"}},this.updateLines=function(e,t,n){(this.config.lastRow!=e.lastRow||this.config.firstRow!=e.firstRow)&&this.scrollLines(e),this.config=e;var r=Math.max(t,e.firstRow),i=Math.min(n,e.lastRow),s=this.element.childNodes,o=0;for(var u=e.firstRow;u<r;u++){var a=this.session.getFoldLine(u);if(a){if(a.containsRow(r)){r=a.start.row;break}u=a.end.row}o++}var u=r,a=this.session.getNextFoldLine(u),f=a?a.start.row:Infinity;for(;;){u>f&&(u=a.end.row+1,a=this.session.getNextFoldLine(u,a),f=a?a.start.row:Infinity);if(u>i)break;var l=s[o++];if(l){var c=[];this.$renderLine(c,u,!this.$useLineGroups(),u==f?a:!1),l.style.height=e.lineHeight*this.session.getRowLength(u)+"px",l.innerHTML=c.join("")}u++}},this.scrollLines=function(e){var t=this.config;this.config=e;if(!t||t.lastRow<e.firstRow)return this.update(e);if(e.lastRow<t.firstRow)return this.update(e);var n=this.element;if(t.firstRow<e.firstRow)for(var r=this.session.getFoldedRowCount(t.firstRow,e.firstRow-1);r>0;r--)n.removeChild(n.firstChild);if(t.lastRow>e.lastRow)for(var r=this.session.getFoldedRowCount(e.lastRow+1,t.lastRow);r>0;r--)n.removeChild(n.lastChild);if(e.firstRow<t.firstRow){var i=this.$renderLinesFragment(e,e.firstRow,t.firstRow-1);n.firstChild?n.insertBefore(i,n.firstChild):n.appendChild(i)}if(e.lastRow>t.lastRow){var i=this.$renderLinesFragment(e,t.lastRow+1,e.lastRow);n.appendChild(i)}},this.$renderLinesFragment=function(e,t,n){var r=this.element.ownerDocument.createDocumentFragment(),s=t,o=this.session.getNextFoldLine(s),u=o?o.start.row:Infinity;for(;;){s>u&&(s=o.end.row+1,o=this.session.getNextFoldLine(s,o),u=o?o.start.row:Infinity);if(s>n)break;var a=i.createElement("div"),f=[];this.$renderLine(f,s,!1,s==u?o:!1),a.innerHTML=f.join("");if(this.$useLineGroups())a.className="ace_line_group",r.appendChild(a),a.style.height=e.lineHeight*this.session.getRowLength(s)+"px";else while(a.firstChild)r.appendChild(a.firstChild);s++}return r},this.update=function(e){this.config=e;var t=[],n=e.firstRow,r=e.lastRow,i=n,s=this.session.getNextFoldLine(i),o=s?s.start.row:Infinity;for(;;){i>o&&(i=s.end.row+1,s=this.session.getNextFoldLine(i,s),o=s?s.start.row:Infinity);if(i>r)break;this.$useLineGroups()&&t.push("<div class='ace_line_group' style='height:",e.lineHeight*this.session.getRowLength(i),"px'>"),this.$renderLine(t,i,!1,i==o?s:!1),this.$useLineGroups()&&t.push("</div>"),i++}this.element.innerHTML=t.join("")},this.$textToken={text:!0,rparen:!0,lparen:!0},this.$renderToken=function(e,t,n,r){var i=this,o=/\t|&|<|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\u3000\uFEFF])|[\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3000-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]/g,u=function(e,n,r,o,u){if(n)return i.showInvisibles?"<span class='ace_invisible ace_invisible_space'>"+s.stringRepeat(i.SPACE_CHAR,e.length)+"</span>":s.stringRepeat("\u00a0",e.length);if(e=="&")return"&#38;";if(e=="<")return"&#60;";if(e==" "){var a=i.session.getScreenTabSize(t+o);return t+=a-1,i.$tabStrings[a]}if(e=="\u3000"){var f=i.showInvisibles?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",l=i.showInvisibles?i.SPACE_CHAR:"";return t+=1,"<span class='"+f+"' style='width:"+i.config.characterWidth*2+"px'>"+l+"</span>"}return r?"<span class='ace_invisible ace_invisible_space ace_invalid'>"+i.SPACE_CHAR+"</span>":(t+=1,"<span class='ace_cjk' style='width:"+i.config.characterWidth*2+"px'>"+e+"</span>")},a=r.replace(o,u);if(!this.$textToken[n.type]){var f="ace_"+n.type.replace(/\./g," ace_"),l="";n.type=="fold"&&(l=" style='width:"+n.value.length*this.config.characterWidth+"px;' "),e.push("<span class='",f,"'",l,">",a,"</span>")}else e.push(a);return t+r.length},this.renderIndentGuide=function(e,t,n){var r=t.search(this.$indentGuideRe);return r<=0||r>=n?t:t[0]==" "?(r-=r%this.tabSize,e.push(s.stringRepeat(this.$tabStrings[" "],r/this.tabSize)),t.substr(r)):t[0]==" "?(e.push(s.stringRepeat(this.$tabStrings[" "],r)),t.substr(r)):t},this.$renderWrappedLine=function(e,t,n,r){var i=0,s=0,o=n[0],u=0;for(var a=0;a<t.length;a++){var f=t[a],l=f.value;if(a==0&&this.displayIndentGuides){i=l.length,l=this.renderIndentGuide(e,l,o);if(!l)continue;i-=l.length}if(i+l.length<o)u=this.$renderToken(e,u,f,l),i+=l.length;else{while(i+l.length>=o)u=this.$renderToken(e,u,f,l.substring(0,o-i)),l=l.substring(o-i),i=o,r||e.push("</div>","<div class='ace_line' style='height:",this.config.lineHeight,"px'>"),s++,u=0,o=n[s]||Number.MAX_VALUE;l.length!=0&&(i+=l.length,u=this.$renderToken(e,u,f,l))}}},this.$renderSimpleLine=function(e,t){var n=0,r=t[0],i=r.value;this.displayIndentGuides&&(i=this.renderIndentGuide(e,i)),i&&(n=this.$renderToken(e,n,r,i));for(var s=1;s<t.length;s++)r=t[s],i=r.value,n=this.$renderToken(e,n,r,i)},this.$renderLine=function(e,t,n,r){!r&&r!=0&&(r=this.session.getFoldLine(t));if(r)var i=this.$getFoldLineTokens(t,r);else var i=this.session.getTokens(t);n||e.push("<div class='ace_line' style='height:",this.config.lineHeight*(this.$useLineGroups()?1:this.session.getRowLength(t)),"px'>");if(i.length){var s=this.session.getRowSplitData(t);s&&s.length?this.$renderWrappedLine(e,i,s,n):this.$renderSimpleLine(e,i)}this.showInvisibles&&(r&&(t=r.end.row),e.push("<span class='ace_invisible ace_invisible_eol'>",t==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,"</span>")),n||e.push("</div>")},this.$getFoldLineTokens=function(e,t){function i(e,t,n){var i=0,s=0;while(s+e[i].value.length<t){s+=e[i].value.length,i++;if(i==e.length)return}if(s!=t){var o=e[i].value.substring(t-s);o.length>n-t&&(o=o.substring(0,n-t)),r.push({type:e[i].type,value:o}),s=t+o.length,i+=1}while(s<n&&i<e.length){var o=e[i].value;o.length+s>n?r.push({type:e[i].type,value:o.substring(0,n-s)}):r.push(e[i]),s+=o.length,i+=1}}var n=this.session,r=[],s=n.getTokens(e);return t.walk(function(e,t,o,u,a){e!=null?r.push({type:"fold",value:e}):(a&&(s=n.getTokens(t)),s.length&&i(s,u,o))},t.end.row,this.session.getLine(t.end.row).length),r},this.$useLineGroups=function(){return this.session.getUseWrapMode()},this.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$measureNode&&this.$measureNode.parentNode.removeChild(this.$measureNode),delete this.$measureNode}}).call(a.prototype),t.Text=a}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../lib/dom"),i,s=function(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_cursor-layer",e.appendChild(this.element),i===undefined&&(i="opacity"in this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),r.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateVisibility.bind(this)};(function(){this.$updateVisibility=function(e){var t=this.cursors;for(var n=t.length;n--;)t[n].style.visibility=e?"":"hidden"},this.$updateOpacity=function(e){var t=this.cursors;for(var n=t.length;n--;)t[n].style.opacity=e?"":"0"},this.$padding=0,this.setPadding=function(e){this.$padding=e},this.setSession=function(e){this.session=e},this.setBlinking=function(e){e!=this.isBlinking&&(this.isBlinking=e,this.restartTimer())},this.setBlinkInterval=function(e){e!=this.blinkInterval&&(this.blinkInterval=e,this.restartTimer())},this.setSmoothBlinking=function(e){e!=this.smoothBlinking&&!i&&(this.smoothBlinking=e,r.setCssClass(this.element,"ace_smooth-blinking",e),this.$updateCursors(!0),this.$updateCursors=(e?this.$updateOpacity:this.$updateVisibility).bind(this),this.restartTimer())},this.addCursor=function(){var e=r.createElement("div");return e.className="ace_cursor",this.element.appendChild(e),this.cursors.push(e),e},this.removeCursor=function(){if(this.cursors.length>1){var e=this.cursors.pop();return e.parentNode.removeChild(e),e}},this.hideCursor=function(){this.isVisible=!1,r.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.showCursor=function(){this.isVisible=!0,r.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.restartTimer=function(){var e=this.$updateCursors;clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.smoothBlinking&&r.removeCssClass(this.element,"ace_smooth-blinking"),e(!0);if(!this.isBlinking||!this.blinkInterval||!this.isVisible)return;this.smoothBlinking&&setTimeout(function(){r.addCssClass(this.element,"ace_smooth-blinking")}.bind(this));var t=function(){this.timeoutId=setTimeout(function(){e(!1)},.6*this.blinkInterval)}.bind(this);this.intervalId=setInterval(function(){e(!0),t()},this.blinkInterval),t()},this.getPixelPosition=function(e,t){if(!this.config||!this.session)return{left:0,top:0};e||(e=this.session.selection.getCursor());var n=this.session.documentToScreenPosition(e),r=this.$padding+n.column*this.config.characterWidth,i=(n.row-(t?this.config.firstRowScreen:0))*this.config.lineHeight;return{left:r,top:i}},this.update=function(e){this.config=e;var t=this.session.$selectionMarkers,n=0,r=0;if(t===undefined||t.length===0)t=[{cursor:null}];for(var n=0,i=t.length;n<i;n++){var s=this.getPixelPosition(t[n].cursor,!0);if((s.top>e.height+e.offset||s.top<0)&&n>1)continue;var o=(this.cursors[r++]||this.addCursor()).style;this.drawCursor?this.drawCursor(o,s,e,t[n],this.session):(o.left=s.left+"px",o.top=s.top+"px",o.width=e.characterWidth+"px",o.height=e.lineHeight+"px")}while(this.cursors.length>r)this.removeCursor();var u=this.session.getOverwrite();this.$setOverwrite(u),this.$pixelPos=s,this.restartTimer()},this.drawCursor=null,this.$setOverwrite=function(e){e!=this.overwrite&&(this.overwrite=e,e?r.addCssClass(this.element,"ace_overwrite-cursors"):r.removeCssClass(this.element,"ace_overwrite-cursors"))},this.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)}}).call(s.prototype),t.Cursor=s}),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./lib/event"),o=e("./lib/event_emitter").EventEmitter,u=function(e){this.element=i.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+this.classSuffix,this.inner=i.createElement("div"),this.inner.className="ace_scrollbar-inner",this.element.appendChild(this.inner),e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addListener(this.element,"scroll",this.onScroll.bind(this)),s.addListener(this.element,"mousedown",s.preventDefault)};(function(){r.implement(this,o),this.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e}}).call(u.prototype);var a=function(e,t){u.call(this,e),this.scrollTop=0,t.$scrollbarWidth=this.width=i.scrollbarWidth(e.ownerDocument),this.inner.style.width=this.element.style.width=(this.width||15)+5+"px"};r.inherits(a,u),function(){this.classSuffix="-v",this.onScroll=function(){this.skipEvent||(this.scrollTop=this.element.scrollTop,this._emit("scroll",{data:this.scrollTop})),this.skipEvent=!1},this.getWidth=function(){return this.isVisible?this.width:0},this.setHeight=function(e){this.element.style.height=e+"px"},this.setInnerHeight=function(e){this.inner.style.height=e+"px"},this.setScrollHeight=function(e){this.inner.style.height=e+"px"},this.setScrollTop=function(e){this.scrollTop!=e&&(this.skipEvent=!0,this.scrollTop=this.element.scrollTop=e)}}.call(a.prototype);var f=function(e,t){u.call(this,e),this.scrollLeft=0,this.height=t.$scrollbarWidth,this.inner.style.height=this.element.style.height=(this.height||15)+5+"px"};r.inherits(f,u),function(){this.classSuffix="-h",this.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},this.getHeight=function(){return this.isVisible?this.height:0},this.setWidth=function(e){this.element.style.width=e+"px"},this.setInnerWidth=function(e){this.inner.style.width=e+"px"},this.setScrollWidth=function(e){this.inner.style.width=e+"px"},this.setScrollLeft=function(e){this.scrollLeft!=e&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=e)}}.call(f.prototype),t.ScrollBar=a,t.ScrollBarV=a,t.ScrollBarH=f,t.VScrollBar=a,t.HScrollBar=f}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(e,t,n){"use strict";var r=e("./lib/event"),i=function(e,t){this.onRender=e,this.pending=!1,this.changes=0,this.window=t||window};(function(){this.schedule=function(e){this.changes=this.changes|e;if(!this.pending&&this.changes){this.pending=!0;var t=this;r.nextFrame(function(){t.pending=!1;var e;while(e=t.changes)t.changes=0,t.onRender(e)},this.window)}}}).call(i.prototype),t.RenderLoop=i}),ace.define("ace/layer/font_metrics",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/lib/event_emitter"],function(e,t,n){var r=e("../lib/oop"),i=e("../lib/dom"),s=e("../lib/lang"),o=e("../lib/useragent"),u=e("../lib/event_emitter").EventEmitter,a=0,f=t.FontMetrics=function(e,t){this.el=i.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=i.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=i.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),e.appendChild(this.el),a||this.$testFractionalRect(),this.$measureNode.innerHTML=s.stringRepeat("X",a),this.$characterSize={width:0,height:0},this.checkForSizeChanges()};(function(){r.implement(this,u),this.$characterSize={width:0,height:0},this.$testFractionalRect=function(){var e=i.createElement("div");this.$setMeasureNodeStyles(e.style),e.style.width="0.2px",document.documentElement.appendChild(e);var t=e.getBoundingClientRect().width;t>0&&t<1?a=50:a=100,e.parentNode.removeChild(e)},this.$setMeasureNodeStyles=function(e,t){e.width=e.height="auto",e.left=e.top="0px",e.visibility="hidden",e.position="absolute",e.whiteSpace="pre",o.isIE<8?e["font-family"]="inherit":e.font="inherit",e.overflow=t?"hidden":"visible"},this.checkForSizeChanges=function(){var e=this.$measureSizes();if(e&&(this.$characterSize.width!==e.width||this.$characterSize.height!==e.height)){this.$measureNode.style.fontWeight="bold";var t=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=e,this.charSizes=Object.create(null),this.allowBoldFonts=t&&t.width===e.width&&t.height===e.height,this._emit("changeCharacterSize",{data:e})}},this.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer)return this.$pollSizeChangesTimer;var e=this;return this.$pollSizeChangesTimer=setInterval(function(){e.checkForSizeChanges()},500)},this.setPolling=function(e){e?this.$pollSizeChanges():this.$pollSizeChangesTimer&&this.$pollSizeChangesTimer},this.$measureSizes=function(){if(a===50){var e=null;try{e=this.$measureNode.getBoundingClientRect()}catch(t){e={width:0,height:0}}var n={height:e.height,width:e.width/a}}else var n={height:this.$measureNode.clientHeight,width:this.$measureNode.clientWidth/a};return n.width===0||n.height===0?null:n},this.$measureCharWidth=function(e){this.$main.innerHTML=s.stringRepeat(e,a);var t=this.$main.getBoundingClientRect();return t.width/a},this.getCharacterWidth=function(e){var t=this.charSizes[e];return t===undefined&&(this.charSizes[e]=this.$measureCharWidth(e)/this.$characterSize.width),t},this.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)}}).call(f.prototype)}),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/config","ace/lib/useragent","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./config"),o=e("./lib/useragent"),u=e("./layer/gutter").Gutter,a=e("./layer/marker").Marker,f=e("./layer/text").Text,l=e("./layer/cursor").Cursor,c=e("./scrollbar").HScrollBar,h=e("./scrollbar").VScrollBar,p=e("./renderloop").RenderLoop,d=e("./layer/font_metrics").FontMetrics,v=e("./lib/event_emitter").EventEmitter,m='.ace_editor {position: relative;overflow: hidden;font: 12px/normal \'Monaco\', \'Menlo\', \'Ubuntu Mono\', \'Consolas\', \'source-code-pro\', monospace;direction: ltr;}.ace_scroller {position: absolute;overflow: hidden;top: 0;bottom: 0;background-color: inherit;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;cursor: text;}.ace_content {position: absolute;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;min-width: 100%;}.ace_dragging .ace_scroller:before{position: absolute;top: 0;left: 0;right: 0;bottom: 0;content: \'\';background: rgba(250, 250, 250, 0.01);z-index: 1000;}.ace_dragging.ace_dark .ace_scroller:before{background: rgba(0, 0, 0, 0.01);}.ace_selecting, .ace_selecting * {cursor: text !important;}.ace_gutter {position: absolute;overflow : hidden;width: auto;top: 0;bottom: 0;left: 0;cursor: default;z-index: 4;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;}.ace_gutter-active-line {position: absolute;left: 0;right: 0;}.ace_scroller.ace_scroll-left {box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;}.ace_gutter-cell {padding-left: 19px;padding-right: 6px;background-repeat: no-repeat;}.ace_gutter-cell.ace_error {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: 2px center;}.ace_gutter-cell.ace_warning {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==");background-position: 2px center;}.ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");background-position: 2px center;}.ace_dark .ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");}.ace_scrollbar {position: absolute;right: 0;bottom: 0;z-index: 6;}.ace_scrollbar-inner {position: absolute;cursor: text;left: 0;top: 0;}.ace_scrollbar-v{overflow-x: hidden;overflow-y: scroll;top: 0;}.ace_scrollbar-h {overflow-x: scroll;overflow-y: hidden;left: 0;}.ace_print-margin {position: absolute;height: 100%;}.ace_text-input {position: absolute;z-index: 0;width: 0.5em;height: 1em;opacity: 0;background: transparent;-moz-appearance: none;appearance: none;border: none;resize: none;outline: none;overflow: hidden;font: inherit;padding: 0 1px;margin: 0 -1px;text-indent: -1em;-ms-user-select: text;-moz-user-select: text;-webkit-user-select: text;user-select: text;}.ace_text-input.ace_composition {background: inherit;color: inherit;z-index: 1000;opacity: 1;text-indent: 0;}.ace_layer {z-index: 1;position: absolute;overflow: hidden;white-space: pre;height: 100%;width: 100%;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;pointer-events: none;}.ace_gutter-layer {position: relative;width: auto;text-align: right;pointer-events: auto;}.ace_text-layer {font: inherit !important;}.ace_cjk {display: inline-block;text-align: center;}.ace_cursor-layer {z-index: 4;}.ace_cursor {z-index: 4;position: absolute;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;border-left: 2px solid}.ace_slim-cursors .ace_cursor {border-left-width: 1px;}.ace_overwrite-cursors .ace_cursor {border-left-width: 0;border-bottom: 1px solid;}.ace_hidden-cursors .ace_cursor {opacity: 0.2;}.ace_smooth-blinking .ace_cursor {-webkit-transition: opacity 0.18s;transition: opacity 0.18s;}.ace_editor.ace_multiselect .ace_cursor {border-left-width: 1px;}.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {position: absolute;z-index: 3;}.ace_marker-layer .ace_selection {position: absolute;z-index: 5;}.ace_marker-layer .ace_bracket {position: absolute;z-index: 6;}.ace_marker-layer .ace_active-line {position: absolute;z-index: 2;}.ace_marker-layer .ace_selected-word {position: absolute;z-index: 4;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;}.ace_line .ace_fold {-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;display: inline-block;height: 11px;margin-top: -2px;vertical-align: middle;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");background-repeat: no-repeat, repeat-x;background-position: center center, top left;color: transparent;border: 1px solid black;border-radius: 2px;cursor: pointer;pointer-events: auto;}.ace_dark .ace_fold {}.ace_fold:hover{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");}.ace_tooltip {background-color: #FFF;background-image: -webkit-linear-gradient(top, transparent, rgba(0, 0, 0, 0.1));background-image: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.1));border: 1px solid gray;border-radius: 1px;box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);color: black;max-width: 100%;padding: 3px 4px;position: fixed;z-index: 999999;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;cursor: default;white-space: pre;word-wrap: break-word;line-height: normal;font-style: normal;font-weight: normal;letter-spacing: normal;pointer-events: none;}.ace_folding-enabled > .ace_gutter-cell {padding-right: 13px;}.ace_fold-widget {-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;margin: 0 -12px 0 1px;display: none;width: 11px;vertical-align: top;background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: center;border-radius: 3px;border: 1px solid transparent;cursor: pointer;}.ace_folding-enabled .ace_fold-widget {display: inline-block; }.ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");}.ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");}.ace_fold-widget:hover {border: 1px solid rgba(0, 0, 0, 0.3);background-color: rgba(255, 255, 255, 0.2);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);}.ace_fold-widget:active {border: 1px solid rgba(0, 0, 0, 0.4);background-color: rgba(0, 0, 0, 0.05);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);}.ace_dark .ace_fold-widget {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");}.ace_dark .ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget:hover {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);background-color: rgba(255, 255, 255, 0.1);}.ace_dark .ace_fold-widget:active {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);}.ace_fold-widget.ace_invalid {background-color: #FFB4B4;border-color: #DE5555;}.ace_fade-fold-widgets .ace_fold-widget {-webkit-transition: opacity 0.4s ease 0.05s;transition: opacity 0.4s ease 0.05s;opacity: 0;}.ace_fade-fold-widgets:hover .ace_fold-widget {-webkit-transition: opacity 0.05s ease 0.05s;transition: opacity 0.05s ease 0.05s;opacity:1;}.ace_underline {text-decoration: underline;}.ace_bold {font-weight: bold;}.ace_nobold .ace_bold {font-weight: normal;}.ace_italic {font-style: italic;}.ace_error-marker {background-color: rgba(255, 0, 0,0.2);position: absolute;z-index: 9;}.ace_highlight-marker {background-color: rgba(255, 255, 0,0.2);position: absolute;z-index: 8;}';i.importCssString(m,"ace_editor");var g=function(e,t){var n=this;this.container=e||i.createElement("div"),this.$keepTextAreaAtCursor=!o.isOldIE,i.addCssClass(this.container,"ace_editor"),this.setTheme(t),this.$gutter=i.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.scroller=i.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=i.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new u(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new a(this.content);var r=this.$textLayer=new f(this.content);this.canvas=r.element,this.$markerFront=new a(this.content),this.$cursorLayer=new l(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new h(this.container,this),this.scrollBarH=new c(this.container,this),this.scrollBarV.addEventListener("scroll",function(e){n.$scrollAnimation||n.session.setScrollTop(e.data-n.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(e){n.$scrollAnimation||n.session.setScrollLeft(e.data-n.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new d(this.container,500),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.addEventListener("changeCharacterSize",function(e){n.updateCharacterSize(),n.onResize(!0,n.gutterWidth,n.$size.width,n.$size.height),n._signal("changeCharacterSize",e)}),this.$size={width:0,height:0,scrollerHeight:0,scrollerWidth:0,$dirty:!0},this.layerConfig={width:1,padding:0,firstRow:0,firstRowScreen:0,lastRow:0,lineHeight:0,characterWidth:0,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1},this.scrollMargin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.$loop=new p(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),s.resetOptions(this),s._emit("renderer",this)};(function(){this.CHANGE_CURSOR=1,this.CHANGE_MARKER=2,this.CHANGE_GUTTER=4,this.CHANGE_SCROLL=8,this.CHANGE_LINES=16,this.CHANGE_TEXT=32,this.CHANGE_SIZE=64,this.CHANGE_MARKER_BACK=128,this.CHANGE_MARKER_FRONT=256,this.CHANGE_FULL=512,this.CHANGE_H_SCROLL=1024,r.implement(this,v),this.updateCharacterSize=function(){this.$textLayer.allowBoldFonts!=this.$allowBoldFonts&&(this.$allowBoldFonts=this.$textLayer.allowBoldFonts,this.setStyle("ace_nobold",!this.$allowBoldFonts)),this.layerConfig.characterWidth=this.characterWidth=this.$textLayer.getCharacterWidth(),this.layerConfig.lineHeight=this.lineHeight=this.$textLayer.getLineHeight(),this.$updatePrintMargin()},this.setSession=function(e){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=e,e&&this.scrollMargin.top&&e.getScrollTop()<=0&&e.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(e),this.$markerBack.setSession(e),this.$markerFront.setSession(e),this.$gutterLayer.setSession(e),this.$textLayer.setSession(e);if(!e)return;this.$loop.schedule(this.CHANGE_FULL),this.session.$setFontMetrics(this.$fontMetrics),this.onChangeNewLineMode=this.onChangeNewLineMode.bind(this),this.onChangeNewLineMode(),this.session.doc.on("changeNewLineMode",this.onChangeNewLineMode)},this.updateLines=function(e,t,n){t===undefined&&(t=Infinity),this.$changedLines?(this.$changedLines.firstRow>e&&(this.$changedLines.firstRow=e),this.$changedLines.lastRow<t&&(this.$changedLines.lastRow=t)):this.$changedLines={firstRow:e,lastRow:t};if(this.$changedLines.lastRow<this.layerConfig.firstRow){if(!n)return;this.$changedLines.lastRow=this.layerConfig.lastRow}if(this.$changedLines.firstRow>this.layerConfig.lastRow)return;this.$loop.schedule(this.CHANGE_LINES)},this.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar()},this.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},this.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},this.updateFull=function(e){e?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},this.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},this.$changes=0,this.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},this.onResize=function(e,t,n,r){if(this.resizing>2)return;this.resizing>0?this.resizing++:this.resizing=e?1:0;var i=this.container;r||(r=i.clientHeight||i.scrollHeight),n||(n=i.clientWidth||i.scrollWidth);var s=this.$updateCachedSize(e,t,n,r);if(!this.$size.scrollerHeight||!n&&!r)return this.resizing=0;e&&(this.$gutterLayer.$padding=null),e?this.$renderChanges(s|this.$changes,!0):this.$loop.schedule(s|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarV.scrollLeft=this.scrollBarV.scrollTop=null},this.$updateCachedSize=function(e,t,n,r){r-=this.$extraHeight||0;var i=0,s=this.$size,o={width:s.width,height:s.height,scrollerHeight:s.scrollerHeight,scrollerWidth:s.scrollerWidth};r&&(e||s.height!=r)&&(s.height=r,i|=this.CHANGE_SIZE,s.scrollerHeight=s.height,this.$horizScroll&&(s.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",i|=this.CHANGE_SCROLL);if(n&&(e||s.width!=n)){i|=this.CHANGE_SIZE,s.width=n,t==null&&(t=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=t,this.scrollBarH.element.style.left=this.scroller.style.left=t+"px",s.scrollerWidth=Math.max(0,n-t-this.scrollBarV.getWidth()),this.scrollBarH.element.style.right=this.scroller.style.right=this.scrollBarV.getWidth()+"px",this.scroller.style.bottom=this.scrollBarH.getHeight()+"px";if(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||e)i|=this.CHANGE_FULL}return s.$dirty=!n||!r,i&&this._signal("resize",o),i},this.onGutterResize=function(){var e=this.$showGutter?this.$gutter.offsetWidth:0;e!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,e,this.$size.width,this.$size.height)),this.session.getUseWrapMode()&&this.adjustWrapLimit()?this.$loop.schedule(this.CHANGE_FULL):this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):(this.$computeLayerConfig(),this.$loop.schedule(this.CHANGE_MARKER))},this.adjustWrapLimit=function(){var e=this.$size.scrollerWidth-this.$padding*2,t=Math.floor(e/this.characterWidth);return this.session.adjustWrapLimit(t,this.$showPrintMargin&&this.$printMarginColumn)},this.setAnimatedScroll=function(e){this.setOption("animatedScroll",e)},this.getAnimatedScroll=function(){return this.$animatedScroll},this.setShowInvisibles=function(e){this.setOption("showInvisibles",e)},this.getShowInvisibles=function(){return this.getOption("showInvisibles")},this.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},this.setDisplayIndentGuides=function(e){this.setOption("displayIndentGuides",e)},this.setShowPrintMargin=function(e){this.setOption("showPrintMargin",e)},this.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},this.setPrintMarginColumn=function(e){this.setOption("printMarginColumn",e)},this.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},this.getShowGutter=function(){return this.getOption("showGutter")},this.setShowGutter=function(e){return this.setOption("showGutter",e)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},this.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.$updateGutterLineHighlight=function(){var e=this.$cursorLayer.$pixelPos,t=this.layerConfig.lineHeight;if(this.session.getUseWrapMode()){var n=this.session.selection.getCursor();n.column=0,e=this.$cursorLayer.getPixelPosition(n,!0),t*=this.session.getRowLength(n.row)}this.$gutterLineHighlight.style.top=e.top-this.layerConfig.offset+"px",this.$gutterLineHighlight.style.height=t+"px"},this.$updatePrintMargin=function(){if(!this.$showPrintMargin&&!this.$printMarginEl)return;if(!this.$printMarginEl){var e=i.createElement("div");e.className="ace_layer ace_print-margin-layer",this.$printMarginEl=i.createElement("div"),this.$printMarginEl.className="ace_print-margin",e.appendChild(this.$printMarginEl),this.content.insertBefore(e,this.content.firstChild)}var t=this.$printMarginEl.style;t.left=this.characterWidth*this.$printMarginColumn+this.$padding+"px",t.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&this.session.$wrap==-1&&this.adjustWrapLimit()},this.getContainerElement=function(){return this.container},this.getMouseEventTarget=function(){return this.content},this.getTextAreaContainer=function(){return this.container},this.$moveTextAreaToCursor=function(){if(!this.$keepTextAreaAtCursor)return;var e=this.layerConfig,t=this.$cursorLayer.$pixelPos.top,n=this.$cursorLayer.$pixelPos.left;t-=e.offset;var r=this.textarea.style,i=this.lineHeight;if(t<0||t>e.height-i){r.top=r.left="0";return}var s=this.characterWidth;if(this.$composition){var o=this.textarea.value.replace(/^\x01+/,"");s*=this.session.$getStringScreenWidth(o)[0]+2,i+=2}n-=this.scrollLeft,n>this.$size.scrollerWidth-s&&(n=this.$size.scrollerWidth-s),n+=this.gutterWidth,r.height=i+"px",r.width=s+"px",r.left=Math.min(n,this.$size.scrollerWidth-s)+"px",r.top=Math.min(t,this.$size.height-i)+"px"},this.getFirstVisibleRow=function(){return this.layerConfig.firstRow},this.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(this.layerConfig.offset===0?0:1)},this.getLastFullyVisibleRow=function(){var e=Math.floor((this.layerConfig.height+this.layerConfig.offset)/this.layerConfig.lineHeight);return this.layerConfig.firstRow-1+e},this.getLastVisibleRow=function(){return this.layerConfig.lastRow},this.$padding=null,this.setPadding=function(e){this.$padding=e,this.$textLayer.setPadding(e),this.$cursorLayer.setPadding(e),this.$markerFront.setPadding(e),this.$markerBack.setPadding(e),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},this.setScrollMargin=function(e,t,n,r){var i=this.scrollMargin;i.top=e|0,i.bottom=t|0,i.right=r|0,i.left=n|0,i.v=i.top+i.bottom,i.h=i.left+i.right,i.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-i.top),this.updateFull()},this.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},this.setHScrollBarAlwaysVisible=function(e){this.setOption("hScrollBarAlwaysVisible",e)},this.getVScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},this.setVScrollBarAlwaysVisible=function(e){this.setOption("vScrollBarAlwaysVisible",e)},this.$updateScrollBarV=function(){var e=this.layerConfig.maxHeight,t=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(e-=(t-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>e-t&&(e=this.scrollTop+t,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(e+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},this.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},this.$frozen=!1,this.freeze=function(){this.$frozen=!0},this.unfreeze=function(){this.$frozen=!1},this.$renderChanges=function(e,t){this.$changes&&(e|=this.$changes,this.$changes=0);if(!this.session||!this.container.offsetWidth||this.$frozen||!e&&!t){this.$changes|=e;return}if(this.$size.$dirty)return this.$changes|=e,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender");var n=this.layerConfig;if(e&this.CHANGE_FULL||e&this.CHANGE_SIZE||e&this.CHANGE_TEXT||e&this.CHANGE_LINES||e&this.CHANGE_SCROLL||e&this.CHANGE_H_SCROLL){e|=this.$computeLayerConfig();if(n.firstRow!=this.layerConfig.firstRow&&n.firstRowScreen==this.layerConfig.firstRowScreen){var r=this.scrollTop+(n.firstRow-this.layerConfig.firstRow)*this.lineHeight;r>0&&(this.scrollTop=r,e|=this.CHANGE_SCROLL,e|=this.$computeLayerConfig())}n=this.layerConfig,this.$updateScrollBarV(),e&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),this.$gutterLayer.element.style.marginTop=-n.offset+"px",this.content.style.marginTop=-n.offset+"px",this.content.style.width=n.width+2*this.$padding+"px",this.content.style.height=n.minHeight+"px"}e&this.CHANGE_H_SCROLL&&(this.content.style.marginLeft=-this.scrollLeft+"px",this.scroller.className=this.scrollLeft<=0?"ace_scroller":"ace_scroller ace_scroll-left");if(e&this.CHANGE_FULL){this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),this.$highlightGutterLine&&this.$updateGutterLineHighlight(),this._signal("afterRender");return}if(e&this.CHANGE_SCROLL){e&this.CHANGE_TEXT||e&this.CHANGE_LINES?this.$textLayer.update(n):this.$textLayer.scrollLines(n),this.$showGutter&&this.$gutterLayer.update(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$highlightGutterLine&&this.$updateGutterLineHighlight(),this.$moveTextAreaToCursor(),this._signal("afterRender");return}e&this.CHANGE_TEXT?(this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n)):e&this.CHANGE_LINES?(this.$updateLines()||e&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(n):(e&this.CHANGE_TEXT||e&this.CHANGE_GUTTER)&&this.$showGutter&&this.$gutterLayer.update(n),e&this.CHANGE_CURSOR&&(this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),this.$highlightGutterLine&&this.$updateGutterLineHighlight()),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(n),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(n),this._signal("afterRender")},this.$autosize=function(){var e=this.session.getScreenLength()*this.lineHeight,t=this.$maxLines*this.lineHeight,n=Math.max((this.$minLines||1)*this.lineHeight,Math.min(t,e))+this.scrollMargin.v+(this.$extraHeight||0),r=e>t;if(n!=this.desiredHeight||this.$size.height!=this.desiredHeight||r!=this.$vScroll){r!=this.$vScroll&&(this.$vScroll=r,this.scrollBarV.setVisible(r));var i=this.container.clientWidth;this.container.style.height=n+"px",this.$updateCachedSize(!0,this.$gutterWidth,i,n),this.desiredHeight=n,this._signal("autosize")}},this.$computeLayerConfig=function(){this.$maxLines&&this.lineHeight>1&&this.$autosize();var e=this.session,t=this.$size,n=t.height<=2*this.lineHeight,r=this.session.getScreenLength(),i=r*this.lineHeight,s=this.scrollTop%this.lineHeight,o=t.scrollerHeight+this.lineHeight,u=this.$getLongestLine(),a=!n&&(this.$hScrollBarAlwaysVisible||t.scrollerWidth-u-2*this.$padding<0),f=this.$horizScroll!==a;f&&(this.$horizScroll=a,this.scrollBarH.setVisible(a));var l=!this.$maxLines&&this.$scrollPastEnd?(t.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;i+=l,this.session.setScrollTop(Math.max(-this.scrollMargin.top,Math.min(this.scrollTop,i-t.scrollerHeight+this.scrollMargin.bottom))),this.session.setScrollLeft(Math.max(-this.scrollMargin.left,Math.min(this.scrollLeft,u+2*this.$padding-t.scrollerWidth+this.scrollMargin.right)));var c=!n&&(this.$vScrollBarAlwaysVisible||t.scrollerHeight-i+l<0||this.scrollTop),h=this.$vScroll!==c;h&&(this.$vScroll=c,this.scrollBarV.setVisible(c));var p=Math.ceil(o/this.lineHeight)-1,d=Math.max(0,Math.round((this.scrollTop-s)/this.lineHeight)),v=d+p,m,g,y=this.lineHeight;d=e.screenToDocumentRow(d,0);var b=e.getFoldLine(d);b&&(d=b.start.row),m=e.documentToScreenRow(d,0),g=e.getRowLength(d)*y,v=Math.min(e.screenToDocumentRow(v,0),e.getLength()-1),o=t.scrollerHeight+e.getRowLength(v)*y+g,s=this.scrollTop-m*y;var w=0;this.layerConfig.width!=u&&(w=this.CHANGE_H_SCROLL);if(f||h)w=this.$updateCachedSize(!0,this.gutterWidth,t.width,t.height),this._signal("scrollbarVisibilityChanged"),h&&(u=this.$getLongestLine());return this.layerConfig={width:u,padding:this.$padding,firstRow:d,firstRowScreen:m,lastRow:v,lineHeight:y,characterWidth:this.characterWidth,minHeight:o,maxHeight:i,offset:s,gutterOffset:Math.max(0,Math.ceil((s+t.height-t.scrollerHeight)/y)),height:this.$size.scrollerHeight},w},this.$updateLines=function(){var e=this.$changedLines.firstRow,t=this.$changedLines.lastRow;this.$changedLines=null;var n=this.layerConfig;if(e>n.lastRow+1)return;if(t<n.firstRow)return;if(t===Infinity){this.$showGutter&&this.$gutterLayer.update(n),this.$textLayer.update(n);return}return this.$textLayer.updateLines(n,e,t),!0},this.$getLongestLine=function(){var e=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(e+=1),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(e*this.characterWidth))},this.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},this.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},this.addGutterDecoration=function(e,t){this.$gutterLayer.addGutterDecoration(e,t)},this.removeGutterDecoration=function(e,t){this.$gutterLayer.removeGutterDecoration(e,t)},this.updateBreakpoints=function(e){this.$loop.schedule(this.CHANGE_GUTTER)},this.setAnnotations=function(e){this.$gutterLayer.setAnnotations(e),this.$loop.schedule(this.CHANGE_GUTTER)},this.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},this.hideCursor=function(){this.$cursorLayer.hideCursor()},this.showCursor=function(){this.$cursorLayer.showCursor()},this.scrollSelectionIntoView=function(e,t,n){this.scrollCursorIntoView(e,n),this.scrollCursorIntoView(t,n)},this.scrollCursorIntoView=function(e,t,n){if(this.$size.scrollerHeight===0)return;var r=this.$cursorLayer.getPixelPosition(e),i=r.left,s=r.top,o=n&&n.top||0,u=n&&n.bottom||0,a=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;a+o>s?(t&&(s-=t*this.$size.scrollerHeight),s===0&&(s=-this.scrollMargin.top),this.session.setScrollTop(s)):a+this.$size.scrollerHeight-u<s+this.lineHeight&&(t&&(s+=t*this.$size.scrollerHeight),this.session.setScrollTop(s+this.lineHeight-this.$size.scrollerHeight));var f=this.scrollLeft;f>i?(i<this.$padding+2*this.layerConfig.characterWidth&&(i=-this.scrollMargin.left),this.session.setScrollLeft(i)):f+this.$size.scrollerWidth<i+this.characterWidth?this.session.setScrollLeft(Math.round(i+this.characterWidth-this.$size.scrollerWidth)):f<=this.$padding&&i-f<this.characterWidth&&this.session.setScrollLeft(0)},this.getScrollTop=function(){return this.session.getScrollTop()},this.getScrollLeft=function(){return this.session.getScrollLeft()},this.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},this.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},this.scrollToRow=function(e){this.session.setScrollTop(e*this.lineHeight)},this.alignCursor=function(e,t){typeof e=="number"&&(e={row:e,column:0});var n=this.$cursorLayer.getPixelPosition(e),r=this.$size.scrollerHeight-this.lineHeight,i=n.top-r*(t||0);return this.session.setScrollTop(i),i},this.STEPS=8,this.$calcSteps=function(e,t){var n=0,r=this.STEPS,i=[],s=function(e,t,n){return n*(Math.pow(e-1,3)+1)+t};for(n=0;n<r;++n)i.push(s(n/this.STEPS,e,t-e));return i},this.scrollToLine=function(e,t,n,r){var i=this.$cursorLayer.getPixelPosition({row:e,column:0}),s=i.top;t&&(s-=this.$size.scrollerHeight/2);var o=this.scrollTop;this.session.setScrollTop(s),n!==!1&&this.animateScrolling(o,r)},this.animateScrolling=function(e,t){var n=this.scrollTop;if(!this.$animatedScroll)return;var r=this;if(e==n)return;if(this.$scrollAnimation){var i=this.$scrollAnimation.steps;if(i.length){e=i[0];if(e==n)return}}var s=r.$calcSteps(e,n);this.$scrollAnimation={from:e,to:n,steps:s},clearInterval(this.$timer),r.session.setScrollTop(s.shift()),r.session.$scrollTop=n,this.$timer=setInterval(function(){s.length?(r.session.setScrollTop(s.shift()),r.session.$scrollTop=n):n!=null?(r.session.$scrollTop=-1,r.session.setScrollTop(n),n=null):(r.$timer=clearInterval(r.$timer),r.$scrollAnimation=null,t&&t())},10)},this.scrollToY=function(e){this.scrollTop!==e&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=e)},this.scrollToX=function(e){this.scrollLeft!==e&&(this.scrollLeft=e),this.$loop.schedule(this.CHANGE_H_SCROLL)},this.scrollTo=function(e,t){this.session.setScrollTop(t),this.session.setScrollLeft(t)},this.scrollBy=function(e,t){t&&this.session.setScrollTop(this.session.getScrollTop()+t),e&&this.session.setScrollLeft(this.session.getScrollLeft()+e)},this.isScrollableBy=function(e,t){if(t<0&&this.session.getScrollTop()>=1-this.scrollMargin.top)return!0;if(t>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom)return!0;if(e<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left)return!0;if(e>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right)return!0},this.pixelToScreenCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),r=(e+this.scrollLeft-n.left-this.$padding)/this.characterWidth,i=Math.floor((t+this.scrollTop-n.top)/this.lineHeight),s=Math.round(r);return{row:i,column:s,side:r-s>0?1:-1}},this.screenToTextCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),r=Math.round((e+this.scrollLeft-n.left-this.$padding)/this.characterWidth),i=(t+this.scrollTop-n.top)/this.lineHeight;return this.session.screenToDocumentPosition(i,Math.max(r,0))},this.textToScreenCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),r=this.session.documentToScreenPosition(e,t),i=this.$padding+Math.round(r.column*this.characterWidth),s=r.row*this.lineHeight;return{pageX:n.left+i-this.scrollLeft,pageY:n.top+s-this.scrollTop}},this.visualizeFocus=function(){i.addCssClass(this.container,"ace_focus")},this.visualizeBlur=function(){i.removeCssClass(this.container,"ace_focus")},this.showComposition=function(e){this.$composition||(this.$composition={keepTextAreaAtCursor:this.$keepTextAreaAtCursor,cssText:this.textarea.style.cssText}),this.$keepTextAreaAtCursor=!0,i.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor()},this.setCompositionText=function(e){this.$moveTextAreaToCursor()},this.hideComposition=function(){if(!this.$composition)return;i.removeCssClass(this.textarea,"ace_composition"),this.$keepTextAreaAtCursor=this.$composition.keepTextAreaAtCursor,this.textarea.style.cssText=this.$composition.cssText,this.$composition=null},this.setTheme=function(e,t){function o(r){if(n.$themeId!=e)return t&&t();if(!r.cssClass)return;i.importCssString(r.cssText,r.cssClass,n.container.ownerDocument),n.theme&&i.removeCssClass(n.container,n.theme.cssClass);var s="padding"in r?r.padding:"padding"in(n.theme||{})?4:n.$padding;n.$padding&&s!=n.$padding&&n.setPadding(s),n.$theme=r.cssClass,n.theme=r,i.addCssClass(n.container,r.cssClass),i.setCssClass(n.container,"ace_dark",r.isDark),n.$size&&(n.$size.width=0,n.$updateSizeAsync()),n._dispatchEvent("themeLoaded",{theme:r}),t&&t()}var n=this;this.$themeId=e,n._dispatchEvent("themeChange",{theme:e});if(!e||typeof e=="string"){var r=e||this.$options.theme.initialValue;s.loadModule(["theme",r],o)}else o(e)},this.getTheme=function(){return this.$themeId},this.setStyle=function(e,t){i.setCssClass(this.container,e,t!==!1)},this.unsetStyle=function(e){i.removeCssClass(this.container,e)},this.setCursorStyle=function(e){this.scroller.style.cursor!=e&&(this.scroller.style.cursor=e)},this.setMouseCursor=function(e){this.scroller.style.cursor=e},this.destroy=function(){this.$textLayer.destroy(),this.$cursorLayer.destroy()}}).call(g.prototype),s.defineOptions(g.prototype,"renderer",{animatedScroll:{initialValue:!1},showInvisibles:{set:function(e){this.$textLayer.setShowInvisibles(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!1},showPrintMargin:{set:function(){this.$updatePrintMargin()},initialValue:!0},printMarginColumn:{set:function(){this.$updatePrintMargin()},initialValue:80},printMargin:{set:function(e){typeof e=="number"&&(this.$printMarginColumn=e),this.$showPrintMargin=!!e,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(e){this.$gutter.style.display=e?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},fadeFoldWidgets:{set:function(e){i.setCssClass(this.$gutter,"ace_fade-fold-widgets",e)},initialValue:!1},showFoldWidgets:{set:function(e){this.$gutterLayer.setShowFoldWidgets(e)},initialValue:!0},showLineNumbers:{set:function(e){this.$gutterLayer.setShowLineNumbers(e),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(e){this.$textLayer.setDisplayIndentGuides(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightGutterLine:{set:function(e){if(!this.$gutterLineHighlight){this.$gutterLineHighlight=i.createElement("div"),this.$gutterLineHighlight.className="ace_gutter-active-line",this.$gutter.appendChild(this.$gutterLineHighlight);return}this.$gutterLineHighlight.style.display=e?"":"none",this.$cursorLayer.$pixelPos&&this.$updateGutterLineHighlight()},initialValue:!1,value:!0},hScrollBarAlwaysVisible:{set:function(e){(!this.$hScrollBarAlwaysVisible||!this.$horizScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(e){(!this.$vScrollBarAlwaysVisible||!this.$vScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(e){typeof e=="number"&&(e+="px"),this.container.style.fontSize=e,this.updateFontSize()},initialValue:12},fontFamily:{set:function(e){this.container.style.fontFamily=e,this.updateFontSize()}},maxLines:{set:function(e){this.updateFull()}},minLines:{set:function(e){this.updateFull()}},scrollPastEnd:{set:function(e){e=+e||0;if(this.$scrollPastEnd==e)return;this.$scrollPastEnd=e,this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(e){this.$gutterLayer.$fixedWidth=!!e,this.$loop.schedule(this.CHANGE_GUTTER)}},theme:{set:function(e){this.setTheme(e)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0}}),t.VirtualRenderer=g}),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../lib/net"),s=e("../lib/event_emitter").EventEmitter,o=e("../config"),u=function(t,n,r,i){this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this),this.changeListener=this.changeListener.bind(this),this.onMessage=this.onMessage.bind(this),e.nameToUrl&&!e.toUrl&&(e.toUrl=e.nameToUrl);if(o.get("packaged")||!e.toUrl)i=i||o.moduleUrl(n,"worker");else{var s=this.$normalizePath;i=i||s(e.toUrl("ace/worker/worker.js",null,"_"));var u={};t.forEach(function(t){u[t]=s(e.toUrl(t,null,"_").replace(/(\.js)?(\?.*)?$/,""))})}try{this.$worker=new Worker(i)}catch(a){if(!(a instanceof window.DOMException))throw a;var f=this.$workerBlob(i),l=window.URL||window.webkitURL,c=l.createObjectURL(f);this.$worker=new Worker(c),l.revokeObjectURL(c)}this.$worker.postMessage({init:!0,tlns:u,module:n,classname:r}),this.callbackId=1,this.callbacks={},this.$worker.onmessage=this.onMessage};(function(){r.implement(this,s),this.onMessage=function(e){var t=e.data;switch(t.type){case"event":this._signal(t.name,{data:t.data});break;case"call":var n=this.callbacks[t.id];n&&(n(t.data),delete this.callbacks[t.id]);break;case"error":this.reportError(t.data);break;case"log":window.console&&console.log&&console.log.apply(console,t.data)}},this.reportError=function(e){window.console&&console.error&&console.error(e)},this.$normalizePath=function(e){return i.qualifyURL(e)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker=null,this.$doc&&this.$doc.off("change",this.changeListener),this.$doc=null},this.send=function(e,t){this.$worker.postMessage({command:e,args:t})},this.call=function(e,t,n){if(n){var r=this.callbackId++;this.callbacks[r]=n,t.push(r)}this.send(e,t)},this.emit=function(e,t){try{this.$worker.postMessage({event:e,data:{data:t.data}})}catch(n){console.error(n.stack)}},this.attachToDocument=function(e){this.$doc&&this.terminate(),this.$doc=e,this.call("setValue",[e.getValue()]),e.on("change",this.changeListener)},this.changeListener=function(e){this.deltaQueue?this.deltaQueue.push(e.data):(this.deltaQueue=[e.data],setTimeout(this.$sendDeltaQueue,0))},this.$sendDeltaQueue=function(){var e=this.deltaQueue;if(!e)return;this.deltaQueue=null,e.length>20&&e.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:e})},this.$workerBlob=function(e){var t="importScripts('"+i.qualifyURL(e)+"');";try{return new Blob([t],{type:"application/javascript"})}catch(n){var r=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder,s=new r;return s.append(t),s.getBlob("application/javascript")}}}).call(u.prototype);var a=function(e,t,n){this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this),this.changeListener=this.changeListener.bind(this),this.callbackId=1,this.callbacks={},this.messageBuffer=[];var r=null,i=!1,u=Object.create(s),a=this;this.$worker={},this.$worker.terminate=function(){},this.$worker.postMessage=function(e){a.messageBuffer.push(e),r&&(i?setTimeout(f):f())},this.setEmitSync=function(e){i=e};var f=function(){var e=a.messageBuffer.shift();e.command?r[e.command].apply(r,e.args):e.event&&u._signal(e.event,e.data)};u.postMessage=function(e){a.onMessage({data:e})},u.callback=function(e,t){this.postMessage({type:"call",id:t,data:e})},u.emit=function(e,t){this.postMessage({type:"event",name:e,data:t})},o.loadModule(["worker",t],function(e){r=new e[n](u);while(a.messageBuffer.length)f()})};a.prototype=u.prototype,t.UIWorkerClient=a,t.WorkerClient=u}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(e,t,n){"use strict";var r=e("./range").Range,i=e("./lib/event_emitter").EventEmitter,s=e("./lib/oop"),o=function(e,t,n,r,i,s){var o=this;this.length=t,this.session=e,this.doc=e.getDocument(),this.mainClass=i,this.othersClass=s,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate),this.$others=r,this.$onCursorChange=function(){setTimeout(function(){o.onCursorChange()})},this.$pos=n;var u=e.getUndoManager().$undoStack||e.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=u.length,this.setup(),e.selection.on("changeCursor",this.$onCursorChange)};(function(){s.implement(this,i),this.setup=function(){var e=this,t=this.doc,n=this.session,i=this.$pos;this.selectionBefore=n.selection.toJSON(),n.selection.inMultiSelectMode&&n.selection.toSingleRange(),this.pos=t.createAnchor(i.row,i.column),this.markerId=n.addMarker(new r(i.row,i.column,i.row,i.column+this.length),this.mainClass,null,!1),this.pos.on("change",function(t){n.removeMarker(e.markerId),e.markerId=n.addMarker(new r(t.value.row,t.value.column,t.value.row,t.value.column+e.length),e.mainClass,null,!1)}),this.others=[],this.$others.forEach(function(n){var r=t.createAnchor(n.row,n.column);e.others.push(r)}),n.setUndoSelect(!1)},this.showOtherMarkers=function(){if(this.othersActive)return;var e=this.session,t=this;this.othersActive=!0,this.others.forEach(function(n){n.markerId=e.addMarker(new r(n.row,n.column,n.row,n.column+t.length),t.othersClass,null,!1),n.on("change",function(i){e.removeMarker(n.markerId),n.markerId=e.addMarker(new r(i.value.row,i.value.column,i.value.row,i.value.column+t.length),t.othersClass,null,!1)})})},this.hideOtherMarkers=function(){if(!this.othersActive)return;this.othersActive=!1;for(var e=0;e<this.others.length;e++)this.session.removeMarker(this.others[e].markerId)},this.onUpdate=function(e){var t=e.data,n=t.range;if(n.start.row!==n.end.row)return;if(n.start.row!==this.pos.row)return;if(this.$updating)return;this.$updating=!0;var i=t.action==="insertText"?n.end.column-n.start.column:n.start.column-n.end.column;if(n.start.column>=this.pos.column&&n.start.column<=this.pos.column+this.length+1){var s=n.start.column-this.pos.column;this.length+=i;if(!this.session.$fromUndo){if(t.action==="insertText")for(var o=this.others.length-1;o>=0;o--){var u=this.others[o],a={row:u.row,column:u.column+s};u.row===n.start.row&&n.start.column<u.column&&(a.column+=i),this.doc.insert(a,t.text)}else if(t.action==="removeText")for(var o=this.others.length-1;o>=0;o--){var u=this.others[o],a={row:u.row,column:u.column+s};u.row===n.start.row&&n.start.column<u.column&&(a.column+=i),this.doc.remove(new r(a.row,a.column,a.row,a.column-i))}n.start.column===this.pos.column&&t.action==="insertText"?setTimeout(function(){this.pos.setPosition(this.pos.row,this.pos.column-i);for(var e=0;e<this.others.length;e++){var t=this.others[e],r={row:t.row,column:t.column-i};t.row===n.start.row&&n.start.column<t.column&&(r.column+=i),t.setPosition(r.row,r.column)}}.bind(this),0):n.start.column===this.pos.column&&t.action==="removeText"&&setTimeout(function(){for(var e=0;e<this.others.length;e++){var t=this.others[e];t.row===n.start.row&&n.start.column<t.column&&t.setPosition(t.row,t.column-i)}}.bind(this),0)}this.pos._emit("change",{value:this.pos});for(var o=0;o<this.others.length;o++)this.others[o]._emit("change",{value:this.others[o]})}this.$updating=!1},this.onCursorChange=function(e){if(this.$updating||!this.session)return;var t=this.session.selection.getCursor();t.row===this.pos.row&&t.column>=this.pos.column&&t.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",e)):(this.hideOtherMarkers(),this._emit("cursorLeave",e))},this.detach=function(){this.session.removeMarker(this.markerId),this.hideOtherMarkers(),this.doc.removeEventListener("change",this.$onUpdate),this.session.selection.removeEventListener("changeCursor",this.$onCursorChange),this.pos.detach();for(var e=0;e<this.others.length;e++)this.others[e].detach();this.session.setUndoSelect(!0),this.session=null},this.cancel=function(){if(this.$undoStackDepth===-1)throw Error("Canceling placeholders only supported with undo manager attached to session.");var e=this.session.getUndoManager(),t=(e.$undoStack||e.$undostack).length-this.$undoStackDepth;for(var n=0;n<t;n++)e.undo(!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}}).call(o.prototype),t.PlaceHolder=o}),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(e,t,n){function s(e,t){return e.row==t.row&&e.column==t.column}function o(e){var t=e.domEvent,n=t.altKey,o=t.shiftKey,u=t.ctrlKey,a=e.getAccelKey(),f=e.getButton();u&&i.isMac&&(f=t.button);if(e.editor.inMultiSelectMode&&f==2){e.editor.textInput.onContextMenu(e.domEvent);return}if(!u&&!n&&!a){f===0&&e.editor.inMultiSelectMode&&e.editor.exitMultiSelectMode();return}if(f!==0)return;var l=e.editor,c=l.selection,h=l.inMultiSelectMode,p=e.getDocumentPosition(),d=c.getCursor(),v=e.inSelection()||c.isEmpty()&&s(p,d),m=e.x,g=e.y,y=function(e){m=e.clientX,g=e.clientY},b=l.session,w=l.renderer.pixelToScreenCoordinates(m,g),E=w,S;if(l.$mouseHandler.$enableJumpToDef)u&&n||a&&n?S="add":n&&(S="block");else if(a&&!n){S="add";if(!h&&o)return}else n&&(S="block");S&&i.isMac&&t.ctrlKey&&l.$mouseHandler.cancelContextMenu();if(S=="add"){if(!h&&v)return;if(!h){var x=c.toOrientedRange();l.addSelectionMarker(x)}var T=c.rangeList.rangeAtPoint(p);l.$blockScrolling++,l.inVirtualSelectionMode=!0,o&&(T=null,x=c.ranges[0],l.removeSelectionMarker(x)),l.once("mouseup",function(){var e=c.toOrientedRange();T&&e.isEmpty()&&s(T.cursor,e.cursor)?c.substractPoint(e.cursor):(o?c.substractPoint(x.cursor):x&&(l.removeSelectionMarker(x),c.addRange(x)),c.addRange(e)),l.$blockScrolling--,l.inVirtualSelectionMode=!1})}else if(S=="block"){e.stop(),l.inVirtualSelectionMode=!0;var N,C=[],k=function(){var e=l.renderer.pixelToScreenCoordinates(m,g),t=b.screenToDocumentPosition(e.row,e.column);if(s(E,e)&&s(t,c.lead))return;E=e,l.$blockScrolling++,l.selection.moveToPosition(t),l.renderer.scrollCursorIntoView(),l.removeSelectionMarkers(C),C=c.rectangularRangeBlock(E,w),l.$mouseHandler.$clickSelection&&C.length==1&&C[0].isEmpty()&&(C[0]=l.$mouseHandler.$clickSelection.clone()),C.forEach(l.addSelectionMarker,l),l.updateSelectionMarkers(),l.$blockScrolling--};l.$blockScrolling++,h&&!a?c.toSingleRange():!h&&a&&(N=c.toOrientedRange(),l.addSelectionMarker(N)),o?w=b.documentToScreenPosition(c.lead):c.moveToPosition(p),l.$blockScrolling--,E={row:-1,column:-1};var L=function(e){clearInterval(O),l.removeSelectionMarkers(C),C.length||(C=[c.toOrientedRange()]),l.$blockScrolling++,N&&(l.removeSelectionMarker(N),c.toSingleRange(N));for(var t=0;t<C.length;t++)c.addRange(C[t]);l.inVirtualSelectionMode=!1,l.$mouseHandler.$clickSelection=null,l.$blockScrolling--},A=k;r.capture(l.container,y,L);var O=setInterval(function(){A()},20);return e.preventDefault()}}var r=e("../lib/event"),i=e("../lib/useragent");t.onMouseDown=o}),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],function(e,t,n){t.defaultCommands=[{name:"addCursorAbove",exec:function(e){e.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},scrollIntoView:"cursor",readonly:!0},{name:"addCursorBelow",exec:function(e){e.selectMoreLines(1)},bindKey:{win:"Ctrl-Alt-Down",mac:"Ctrl-Alt-Down"},scrollIntoView:"cursor",readonly:!0},{name:"addCursorAboveSkipCurrent",exec:function(e){e.selectMoreLines(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Up",mac:"Ctrl-Alt-Shift-Up"},scrollIntoView:"cursor",readonly:!0},{name:"addCursorBelowSkipCurrent",exec:function(e){e.selectMoreLines(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Down",mac:"Ctrl-Alt-Shift-Down"},scrollIntoView:"cursor",readonly:!0},{name:"selectMoreBefore",exec:function(e){e.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},scrollIntoView:"cursor",readonly:!0},{name:"selectMoreAfter",exec:function(e){e.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",mac:"Ctrl-Alt-Right"},scrollIntoView:"cursor",readonly:!0},{name:"selectNextBefore",exec:function(e){e.selectMore(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Left",mac:"Ctrl-Alt-Shift-Left"},scrollIntoView:"cursor",readonly:!0},{name:"selectNextAfter",exec:function(e){e.selectMore(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Right",mac:"Ctrl-Alt-Shift-Right"},scrollIntoView:"cursor",readonly:!0},{name:"splitIntoLines",exec:function(e){e.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readonly:!0},{name:"alignCursors",exec:function(e){e.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",exec:function(e){e.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readonly:!0}],t.multiSelectCommands=[{name:"singleSelection",bindKey:"esc",exec:function(e){e.exitMultiSelectMode()},scrollIntoView:"cursor",readonly:!0,isAvailable:function(e){return e&&e.inMultiSelectMode}}];var r=e("../keyboard/hash_handler").HashHandler;t.keyboardHandler=new r(t.multiSelectCommands)}),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],function(e,t,n){function h(e,t,n){return c.$options.wrap=!0,c.$options.needle=t,c.$options.backwards=n==-1,c.find(e)}function v(e,t){return e.row==t.row&&e.column==t.column}function m(e){if(e.$multiselectOnSessionChange)return;e.$onAddRange=e.$onAddRange.bind(e),e.$onRemoveRange=e.$onRemoveRange.bind(e),e.$onMultiSelect=e.$onMultiSelect.bind(e),e.$onSingleSelect=e.$onSingleSelect.bind(e),e.$multiselectOnSessionChange=t.onSessionChange.bind(e),e.$checkMultiselectChange=e.$checkMultiselectChange.bind(e),e.$multiselectOnSessionChange(e),e.on("changeSession",e.$multiselectOnSessionChange),e.on("mousedown",o),e.commands.addCommands(f.defaultCommands),g(e)}function g(e){function r(t){n&&(e.renderer.setMouseCursor(""),n=!1)}var t=e.textInput.getElement(),n=!1;u.addListener(t,"keydown",function(t){t.keyCode==18&&!(t.ctrlKey||t.shiftKey||t.metaKey)?n||(e.renderer.setMouseCursor("crosshair"),n=!0):n&&r()}),u.addListener(t,"keyup",r),u.addListener(t,"blur",r)}var r=e("./range_list").RangeList,i=e("./range").Range,s=e("./selection").Selection,o=e("./mouse/multi_select_handler").onMouseDown,u=e("./lib/event"),a=e("./lib/lang"),f=e("./commands/multi_select_commands");t.commands=f.defaultCommands.concat(f.multiSelectCommands);var l=e("./search").Search,c=new l,p=e("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(p.prototype),function(){this.ranges=null,this.rangeList=null,this.addRange=function(e,t){if(!e)return;if(!this.inMultiSelectMode&&this.rangeCount===0){var n=this.toOrientedRange();this.rangeList.add(n),this.rangeList.add(e);if(this.rangeList.ranges.length!=2)return this.rangeList.removeAll(),t||this.fromOrientedRange(e);this.rangeList.removeAll(),this.rangeList.add(n),this.$onAddRange(n)}e.cursor||(e.cursor=e.end);var r=this.rangeList.add(e);return this.$onAddRange(e),r.length&&this.$onRemoveRange(r),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),t||this.fromOrientedRange(e)},this.toSingleRange=function(e){e=e||this.ranges[0];var t=this.rangeList.removeAll();t.length&&this.$onRemoveRange(t),e&&this.fromOrientedRange(e)},this.substractPoint=function(e){var t=this.rangeList.substractPoint(e);if(t)return this.$onRemoveRange(t),t[0]},this.mergeOverlappingRanges=function(){var e=this.rangeList.merge();e.length?this.$onRemoveRange(e):this.ranges[0]&&this.fromOrientedRange(this.ranges[0])},this.$onAddRange=function(e){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(e),this._signal("addRange",{range:e})},this.$onRemoveRange=function(e){this.rangeCount=this.rangeList.ranges.length;if(this.rangeCount==1&&this.inMultiSelectMode){var t=this.rangeList.ranges.pop();e.push(t),this.rangeCount=0}for(var n=e.length;n--;){var r=this.ranges.indexOf(e[n]);this.ranges.splice(r,1)}this._signal("removeRange",{ranges:e}),this.rangeCount===0&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),t=t||this.ranges[0],t&&!t.isEqual(this.getRange())&&this.fromOrientedRange(t)},this.$initRangeList=function(){if(this.rangeList)return;this.rangeList=new r,this.ranges=[],this.rangeCount=0},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){if(this.rangeCount>1){var e=this.rangeList.ranges,t=e[e.length-1],n=i.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)}else{var n=this.getRange(),r=this.isBackwards(),s=n.start.row,o=n.end.row;if(s==o){if(r)var u=n.end,a=n.start;else var u=n.start,a=n.end;this.addRange(i.fromPoints(a,a)),this.addRange(i.fromPoints(u,u));return}var f=[],l=this.getLineRange(s,!0);l.start.column=n.start.column,f.push(l);for(var c=s+1;c<o;c++)f.push(this.getLineRange(c,!0));l=this.getLineRange(o,!0),l.end.column=n.end.column,f.push(l),f.forEach(this.addRange,this)}},this.toggleBlockSelection=function(){if(this.rangeCount>1){var e=this.rangeList.ranges,t=e[e.length-1],n=i.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)}else{var r=this.session.documentToScreenPosition(this.selectionLead),s=this.session.documentToScreenPosition(this.selectionAnchor),o=this.rectangularRangeBlock(r,s);o.forEach(this.addRange,this)}},this.rectangularRangeBlock=function(e,t,n){var r=[],s=e.column<t.column;if(s)var o=e.column,u=t.column;else var o=t.column,u=e.column;var a=e.row<t.row;if(a)var f=e.row,l=t.row;else var f=t.row,l=e.row;o<0&&(o=0),f<0&&(f=0),f==l&&(n=!0);for(var c=f;c<=l;c++){var h=i.fromPoints(this.session.screenToDocumentPosition(c,o),this.session.screenToDocumentPosition(c,u));if(h.isEmpty()){if(p&&v(h.end,p))break;var p=h.end}h.cursor=s?h.start:h.end,r.push(h)}a&&r.reverse();if(!n){var d=r.length-1;while(r[d].isEmpty()&&d>0)d--;if(d>0){var m=0;while(r[m].isEmpty())m++}for(var g=d;g>=m;g--)r[g].isEmpty()&&r.splice(g,1)}return r}}.call(s.prototype);var d=e("./editor").Editor;(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(e){e.cursor||(e.cursor=e.end);var t=this.getSelectionStyle();return e.marker=this.session.addMarker(e,"ace_selection",t),this.session.$selectionMarkers.push(e),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,e},this.removeSelectionMarker=function(e){if(!e.marker)return;this.session.removeMarker(e.marker);var t=this.session.$selectionMarkers.indexOf(e);t!=-1&&this.session.$selectionMarkers.splice(t,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length},this.removeSelectionMarkers=function(e){var t=this.session.$selectionMarkers;for(var n=e.length;n--;){var r=e[n];if(!r.marker)continue;this.session.removeMarker(r.marker);var i=t.indexOf(r);i!=-1&&t.splice(i,1)}this.session.selectionMarkerCount=t.length},this.$onAddRange=function(e){this.addSelectionMarker(e.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(e){this.removeSelectionMarkers(e.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(e){if(this.inMultiSelectMode)return;this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(f.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onSingleSelect=function(e){if(this.session.multiSelect.inVirtualMode)return;this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(f.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection")},this.$onMultiSelectExec=function(e){var t=e.command,n=e.editor;if(!n.multiSelect)return;if(!t.multiSelectAction){var r=t.exec(n,e.args||{});n.multiSelect.addRange(n.multiSelect.toOrientedRange()),n.multiSelect.mergeOverlappingRanges()}else t.multiSelectAction=="forEach"?r=n.forEachSelection(t,e.args):t.multiSelectAction=="forEachLine"?r=n.forEachSelection(t,e.args,!0):t.multiSelectAction=="single"?(n.exitMultiSelectMode(),r=t.exec(n,e.args||{})):r=t.multiSelectAction(n,e.args||{});return r},this.forEachSelection=function(e,t,n){if(this.inVirtualSelectionMode)return;var r=n&&n.keepOrder,i=n==1||n&&n.$byLines,o=this.session,u=this.selection,a=u.rangeList,f=(r?u:a).ranges,l;if(!f.length)return e.exec?e.exec(this,t||{}):e(this,t||{});var c=u._eventRegistry;u._eventRegistry={};var h=new s(o);this.inVirtualSelectionMode=!0;for(var p=f.length;p--;){if(i)while(p>0&&f[p].start.row==f[p-1].end.row)p--;h.fromOrientedRange(f[p]),h.index=p,this.selection=o.selection=h;var d=e.exec?e.exec(this,t||{}):e(this,t||{});!l&&d!==undefined&&(l=d),h.toOrientedRange(f[p])}h.detach(),this.selection=o.selection=u,this.inVirtualSelectionMode=!1,u._eventRegistry=c,u.mergeOverlappingRanges();var v=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),v&&v.from==v.to&&this.renderer.animateScrolling(v.from),l},this.exitMultiSelectMode=function(){if(!this.inMultiSelectMode||this.inVirtualSelectionMode)return;this.multiSelect.toSingleRange()},this.getSelectedText=function(){var e="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var t=this.multiSelect.rangeList.ranges,n=[];for(var r=0;r<t.length;r++)n.push(this.session.getTextRange(t[r]));var i=this.session.getDocument().getNewLineCharacter();e=n.join(i),e.length==(n.length-1)*i.length&&(e="")}else this.selection.isEmpty()||(e=this.session.getTextRange(this.getSelectionRange()));return e},this.$checkMultiselectChange=function(e,t){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var n=this.multiSelect.ranges[0];if(this.multiSelect.isEmpty()&&t==this.multiSelect.anchor)return;var r=t==this.multiSelect.anchor?n.cursor==n.start?n.end:n.start:n.cursor;(r.row!=t.row||this.session.$clipPositionToDocument(r.row,r.column).column!=t.column)&&this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange())}},this.findAll=function(e,t,n){t=t||{},t.needle=e||t.needle;if(t.needle==undefined){var r=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();t.needle=this.session.getTextRange(r)}this.$search.set(t);var i=this.$search.findAll(this.session);if(!i.length)return 0;this.$blockScrolling+=1;var s=this.multiSelect;n||s.toSingleRange(i[0]);for(var o=i.length;o--;)s.addRange(i[o],!0);return r&&s.rangeList.rangeAtPoint(r.start)&&s.addRange(r,!0),this.$blockScrolling-=1,i.length},this.selectMoreLines=function(e,t){var n=this.selection.toOrientedRange(),r=n.cursor==n.end,s=this.session.documentToScreenPosition(n.cursor);this.selection.$desiredColumn&&(s.column=this.selection.$desiredColumn);var o=this.session.screenToDocumentPosition(s.row+e,s.column);if(!n.isEmpty())var u=this.session.documentToScreenPosition(r?n.end:n.start),a=this.session.screenToDocumentPosition(u.row+e,u.column);else var a=o;if(r){var f=i.fromPoints(o,a);f.cursor=f.start}else{var f=i.fromPoints(a,o);f.cursor=f.end}f.desiredColumn=s.column;if(!this.selection.inMultiSelectMode)this.selection.addRange(n);else if(t)var l=n.cursor;this.selection.addRange(f),l&&this.selection.substractPoint(l)},this.transposeSelections=function(e){var t=this.session,n=t.multiSelect,r=n.ranges;for(var i=r.length;i--;){var s=r[i];if(s.isEmpty()){var o=t.getWordRange(s.start.row,s.start.column);s.start.row=o.start.row,s.start.column=o.start.column,s.end.row=o.end.row,s.end.column=o.end.column}}n.mergeOverlappingRanges();var u=[];for(var i=r.length;i--;){var s=r[i];u.unshift(t.getTextRange(s))}e<0?u.unshift(u.pop()):u.push(u.shift());for(var i=r.length;i--;){var s=r[i],o=s.clone();t.replace(s,u[i]),s.start.row=o.start.row,s.start.column=o.start.column}},this.selectMore=function(e,t,n){var r=this.session,i=r.multiSelect,s=i.toOrientedRange();if(s.isEmpty()){s=r.getWordRange(s.start.row,s.start.column),s.cursor=e==-1?s.start:s.end,this.multiSelect.addRange(s);if(n)return}var o=r.getTextRange(s),u=h(r,o,e);u&&(u.cursor=e==-1?u.start:u.end,this.$blockScrolling+=1,this.session.unfold(u),this.multiSelect.addRange(u),this.$blockScrolling-=1,this.renderer.scrollCursorIntoView(null,.5)),t&&this.multiSelect.substractPoint(s.cursor)},this.alignCursors=function(){var e=this.session,t=e.multiSelect,n=t.ranges,r=-1,s=n.filter(function(e){if(e.cursor.row==r)return!0;r=e.cursor.row});if(!n.length||s.length==n.length-1){var o=this.selection.getRange(),u=o.start.row,f=o.end.row,l=u==f;if(l){var c=this.session.getLength(),h;do h=this.session.getLine(f);while(/[=:]/.test(h)&&++f<c);do h=this.session.getLine(u);while(/[=:]/.test(h)&&--u>0);u<0&&(u=0),f>=c&&(f=c-1)}var p=this.session.doc.removeLines(u,f);p=this.$reAlignText(p,l),this.session.doc.insert({row:u,column:0},p.join("\n")+"\n"),l||(o.start.column=0,o.end.column=p[p.length-1].length),this.selection.setRange(o)}else{s.forEach(function(e){t.substractPoint(e.cursor)});var d=0,v=Infinity,m=n.map(function(t){var n=t.cursor,r=e.getLine(n.row),i=r.substr(n.column).search(/\S/g);return i==-1&&(i=0),n.column>d&&(d=n.column),i<v&&(v=i),i});n.forEach(function(t,n){var r=t.cursor,s=d-r.column,o=m[n]-v;s>o?e.insert(r,a.stringRepeat(" ",s-o)):e.remove(new i(r.row,r.column,r.row,r.column-s+o)),t.start.column=t.end.column=d,t.start.row=t.end.row=r.row,t.cursor=t.end}),t.fromOrientedRange(n[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}},this.$reAlignText=function(e,t){function u(e){return a.stringRepeat(" ",e)}function f(e){return e[2]?u(i)+e[2]+u(s-e[2].length+o)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function l(e){return e[2]?u(i+s-e[2].length)+e[2]+u(o," ")+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function c(e){return e[2]?u(i)+e[2]+u(o)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}var n=!0,r=!0,i,s,o;return e.map(function(e){var t=e.match(/(\s*)(.*?)(\s*)([=:].*)/);return t?i==null?(i=t[1].length,s=t[2].length,o=t[3].length,t):(i+s+o!=t[1].length+t[2].length+t[3].length&&(r=!1),i!=t[1].length&&(n=!1),i>t[1].length&&(i=t[1].length),s<t[2].length&&(s=t[2].length),o>t[3].length&&(o=t[3].length),t):[e]}).map(t?f:n?r?l:f:c)}}).call(d.prototype),t.onSessionChange=function(e){var t=e.session;t&&!t.multiSelect&&(t.$selectionMarkers=[],t.selection.$initRangeList(),t.multiSelect=t.selection),this.multiSelect=t&&t.multiSelect;var n=e.oldSession;n&&(n.multiSelect.off("addRange",this.$onAddRange),n.multiSelect.off("removeRange",this.$onRemoveRange),n.multiSelect.off("multiSelect",this.$onMultiSelect),n.multiSelect.off("singleSelect",this.$onSingleSelect),n.multiSelect.lead.off("change",this.$checkMultiselectChange),n.multiSelect.anchor.off("change",this.$checkMultiselectChange)),t&&(t.multiSelect.on("addRange",this.$onAddRange),t.multiSelect.on("removeRange",this.$onRemoveRange),t.multiSelect.on("multiSelect",this.$onMultiSelect),t.multiSelect.on("singleSelect",this.$onSingleSelect),t.multiSelect.lead.on("change",this.$checkMultiselectChange),t.multiSelect.anchor.on("change",this.$checkMultiselectChange)),t&&this.inMultiSelectMode!=t.selection.inMultiSelectMode&&(t.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())},t.MultiSelect=m,e("./config").defineOptions(d.prototype,"editor",{enableMultiselect:{set:function(e){m(this),e?(this.on("changeSession",this.$multiselectOnSessionChange),this.on("mousedown",o)):(this.off("changeSession",this.$multiselectOnSessionChange),this.off("mousedown",o))},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("../../range").Range,i=t.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(e,t,n){var r=e.getLine(n);return this.foldingStartMarker.test(r)?"start":t=="markbeginend"&&this.foldingStopMarker&&this.foldingStopMarker.test(r)?"end":""},this.getFoldWidgetRange=function(e,t,n){return null},this.indentationBlock=function(e,t,n){var i=/\S/,s=e.getLine(t),o=s.search(i);if(o==-1)return;var u=n||s.length,a=e.getLength(),f=t,l=t;while(++t<a){var c=e.getLine(t).search(i);if(c==-1)continue;if(c<=o)break;l=t}if(l>f){var h=e.getLine(l).length;return new r(f,u,l,h)}},this.openingBracketBlock=function(e,t,n,i,s){var o={row:n,column:i+1},u=e.$findClosingBracket(t,o,s);if(!u)return;var a=e.foldWidgets[u.row];return a==null&&(a=e.getFoldWidget(u.row)),a=="start"&&u.row>o.row&&(u.row--,u.column=e.getLine(u.row).length),r.fromPoints(o,u)},this.closingBracketBlock=function(e,t,n,i,s){var o={row:n,column:i},u=e.$findOpeningBracket(t,o);if(!u)return;return u.column++,o.column--,r.fromPoints(u,o)}}).call(i.prototype)}),ace.define("ace/theme/textmate",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";t.isDark=!1,t.cssClass="ace-tm",t.cssText='.ace-tm .ace_gutter {background: #f0f0f0;color: #333;}.ace-tm .ace_print-margin {width: 1px;background: #e8e8e8;}.ace-tm .ace_fold {background-color: #6B72E6;}.ace-tm {background-color: #FFFFFF;color: black;}.ace-tm .ace_cursor {color: black;}.ace-tm .ace_invisible {color: rgb(191, 191, 191);}.ace-tm .ace_storage,.ace-tm .ace_keyword {color: blue;}.ace-tm .ace_constant {color: rgb(197, 6, 11);}.ace-tm .ace_constant.ace_buildin {color: rgb(88, 72, 246);}.ace-tm .ace_constant.ace_language {color: rgb(88, 92, 246);}.ace-tm .ace_constant.ace_library {color: rgb(6, 150, 14);}.ace-tm .ace_invalid {background-color: rgba(255, 0, 0, 0.1);color: red;}.ace-tm .ace_support.ace_function {color: rgb(60, 76, 114);}.ace-tm .ace_support.ace_constant {color: rgb(6, 150, 14);}.ace-tm .ace_support.ace_type,.ace-tm .ace_support.ace_class {color: rgb(109, 121, 222);}.ace-tm .ace_keyword.ace_operator {color: rgb(104, 118, 135);}.ace-tm .ace_string {color: rgb(3, 106, 7);}.ace-tm .ace_comment {color: rgb(76, 136, 107);}.ace-tm .ace_comment.ace_doc {color: rgb(0, 102, 255);}.ace-tm .ace_comment.ace_doc.ace_tag {color: rgb(128, 159, 191);}.ace-tm .ace_constant.ace_numeric {color: rgb(0, 0, 205);}.ace-tm .ace_variable {color: rgb(49, 132, 149);}.ace-tm .ace_xml-pe {color: rgb(104, 104, 91);}.ace-tm .ace_entity.ace_name.ace_function {color: #0000A2;}.ace-tm .ace_heading {color: rgb(12, 7, 255);}.ace-tm .ace_list {color:rgb(185, 6, 144);}.ace-tm .ace_meta.ace_tag {color:rgb(0, 22, 142);}.ace-tm .ace_string.ace_regex {color: rgb(255, 0, 0)}.ace-tm .ace_marker-layer .ace_selection {background: rgb(181, 213, 255);}.ace-tm.ace_multiselect .ace_selection.ace_start {box-shadow: 0 0 3px 0px white;border-radius: 2px;}.ace-tm .ace_marker-layer .ace_step {background: rgb(252, 255, 0);}.ace-tm .ace_marker-layer .ace_stack {background: rgb(164, 229, 101);}.ace-tm .ace_marker-layer .ace_bracket {margin: -1px 0 0 -1px;border: 1px solid rgb(192, 192, 192);}.ace-tm .ace_marker-layer .ace_active-line {background: rgba(0, 0, 0, 0.07);}.ace-tm .ace_gutter-active-line {background-color : #dcdcdc;}.ace-tm .ace_marker-layer .ace_selected-word {background: rgb(250, 250, 255);border: 1px solid rgb(200, 200, 250);}.ace-tm .ace_indent-guide {background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;}';var r=e("../lib/dom");r.importCssString(t.cssText,t.cssClass)}),ace.define("ace/line_widgets",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/range"],function(e,t,n){"use strict";function o(e){this.session=e,this.session.widgetManager=this,this.session.getRowLength=this.getRowLength,this.session.$getWidgetScreenLength=this.$getWidgetScreenLength,this.updateOnChange=this.updateOnChange.bind(this),this.renderWidgets=this.renderWidgets.bind(this),this.measureWidgets=this.measureWidgets.bind(this),this.session._changedWidgets=[],this.$onChangeEditor=this.$onChangeEditor.bind(this),this.session.on("change",this.updateOnChange),this.session.on("changeEditor",this.$onChangeEditor)}var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./range").Range;(function(){this.getRowLength=function(e){var t;return this.lineWidgets?t=this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0:t=0,!this.$useWrapMode||!this.$wrapData[e]?1+t:this.$wrapData[e].length+1+t},this.$getWidgetScreenLength=function(){var e=0;return this.lineWidgets.forEach(function(t){t&&t.rowCount&&(e+=t.rowCount)}),e},this.$onChangeEditor=function(e){this.attach(e.editor)},this.attach=function(e){e&&e.widgetManager&&e.widgetManager!=this&&e.widgetManager.detach();if(this.editor==e)return;this.detach(),this.editor=e,e&&(e.widgetManager=this,e.renderer.on("beforeRender",this.measureWidgets),e.renderer.on("afterRender",this.renderWidgets))},this.detach=function(e){var t=this.editor;if(!t)return;this.editor=null,t.widgetManager=null,t.renderer.off("beforeRender",this.measureWidgets),t.renderer.off("afterRender",this.renderWidgets);var n=this.session.lineWidgets;n&&n.forEach(function(e){e&&e.el&&e.el.parentNode&&(e._inDocument=!1,e.el.parentNode.removeChild(e.el))})},this.updateOnChange=function(e){var t=this.session.lineWidgets;if(!t)return;var n=e.data,r=n.range,i=r.start.row,s=r.end.row-i;if(s!==0)if(n.action=="removeText"||n.action=="removeLines"){var o=t.splice(i+1,s);o.forEach(function(e){e&&this.removeLineWidget(e)},this),this.$updateRows()}else{var u=new Array(s);u.unshift(i,0),t.splice.apply(t,u),this.$updateRows()}},this.$updateRows=function(){var e=this.session.lineWidgets;if(!e)return;var t=!0;e.forEach(function(e,n){e&&(t=!1,e.row=n)}),t&&(this.session.lineWidgets=null)},this.addLineWidget=function(e){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength())),this.session.lineWidgets[e.row]=e;var t=this.editor.renderer;return e.html&&!e.el&&(e.el=i.createElement("div"),e.el.innerHTML=e.html),e.el&&(i.addCssClass(e.el,"ace_lineWidgetContainer"),e.el.style.position="absolute",e.el.style.zIndex=5,t.container.appendChild(e.el),e._inDocument=!0),e.coverGutter||(e.el.style.zIndex=3),e.pixelHeight||(e.pixelHeight=e.el.offsetHeight),e.rowCount==null&&(e.rowCount=e.pixelHeight/t.layerConfig.lineHeight),this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows(),this.renderWidgets(null,t),e},this.removeLineWidget=function(e){e._inDocument=!1,e.el&&e.el.parentNode&&e.el.parentNode.removeChild(e.el);if(e.editor&&e.editor.destroy)try{e.editor.destroy()}catch(t){}this.session.lineWidgets&&(this.session.lineWidgets[e.row]=undefined),this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows()},this.onWidgetChanged=function(e){this.session._changedWidgets.push(e),this.editor&&this.editor.renderer.updateFull()},this.measureWidgets=function(e,t){var n=this.session._changedWidgets,r=t.layerConfig;if(!n||!n.length)return;var i=Infinity;for(var s=0;s<n.length;s++){var o=n[s];o._inDocument||(o._inDocument=!0,t.container.appendChild(o.el)),o.h=o.el.offsetHeight,o.fixedWidth||(o.w=o.el.offsetWidth,o.screenWidth=Math.ceil(o.w/r.characterWidth));var u=o.h/r.lineHeight;o.coverLine&&(u-=this.session.getRowLineCount(o.row),u<0&&(u=0)),o.rowCount!=u&&(o.rowCount=u,o.row<i&&(i=o.row))}i!=Infinity&&(this.session._emit("changeFold",{data:{start:{row:i}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]},this.renderWidgets=function(e,t){var n=t.layerConfig,r=this.session.lineWidgets;if(!r)return;var i=Math.min(this.firstRow,n.firstRow),s=Math.max(this.lastRow,n.lastRow,r.length);while(i>0&&!r[i])i--;this.firstRow=n.firstRow,this.lastRow=n.lastRow,t.$cursorLayer.config=n;for(var o=i;o<=s;o++){var u=r[o];if(!u||!u.el)continue;u._inDocument||(u._inDocument=!0,t.container.appendChild(u.el));var a=t.$cursorLayer.getPixelPosition({row:o,column:0},!0).top;u.coverLine||(a+=n.lineHeight*this.session.getRowLineCount(u.row)),u.el.style.top=a-n.offset+"px";var f=u.coverGutter?0:t.gutterWidth;u.fixedWidth||(f-=t.scrollLeft),u.el.style.left=f+"px",u.fixedWidth?u.el.style.right=t.scrollBar.getWidth()+"px":u.el.style.right=""}}}).call(o.prototype),t.LineWidgets=o}),ace.define("ace/ext/error_marker",["require","exports","module","ace/line_widgets","ace/lib/dom","ace/range"],function(e,t,n){"use strict";function o(e,t,n){var r=0,i=e.length-1;while(r<=i){var s=r+i>>1,o=n(t,e[s]);if(o>0)r=s+1;else{if(!(o<0))return s;i=s-1}}return-(r+1)}function u(e,t,n){var r=e.getAnnotations().sort(s.comparePoints);if(!r.length)return;var i=o(r,{row:t,column:-1},s.comparePoints);i<0&&(i=-i-1),i>=r.length-1?i=n>0?0:r.length-1:i===0&&n<0&&(i=r.length-1);var u=r[i];if(!u||!n)return;if(u.row===t){do u=r[i+=n];while(u&&u.row===t);if(!u)return r.slice()}var a=[];t=u.row;do a[n<0?"unshift":"push"](u),u=r[i+=n];while(u&&u.row==t);return a.length&&a}var r=e("../line_widgets").LineWidgets,i=e("../lib/dom"),s=e("../range").Range;t.showErrorMarker=function(e,t){var n=e.session;n.widgetManager||(n.widgetManager=new r(n),n.widgetManager.attach(e));var s=e.getCursorPosition(),o=s.row,a=n.lineWidgets&&n.lineWidgets[o];a?a.destroy():o-=t;var f=u(n,o,t),l;if(f){var c=f[0];s.column=(c.pos&&typeof c.column!="number"?c.pos.sc:c.column)||0,s.row=c.row,l=e.renderer.$gutterLayer.$annotations[s.row]}else{if(a)return;l={text:["Looks good!"],className:"ace_ok"}}e.session.unfold(s.row),e.selection.moveToPosition(s);var h={row:s.row,fixedWidth:!0,coverGutter:!0,el:i.createElement("div")},p=h.el.appendChild(i.createElement("div")),d=h.el.appendChild(i.createElement("div"));d.className="error_widget_arrow "+l.className;var v=e.renderer.$cursorLayer.getPixelPosition(s).left;d.style.left=v+e.renderer.gutterWidth-5+"px",h.el.className="error_widget_wrapper",p.className="error_widget "+l.className,p.innerHTML=l.text.join("<br>"),p.appendChild(i.createElement("div"));var m=function(e,t,n){if(t===0&&(n==="esc"||n==="return"))return h.destroy(),{command:"null"}};h.destroy=function(){if(e.$mouseHandler.isMousePressed)return;e.keyBinding.removeKeyboardHandler(m),n.widgetManager.removeLineWidget(h),e.off("changeSelection",h.destroy),e.off("changeSession",h.destroy),e.off("mouseup",h.destroy),e.off("change",h.destroy)},e.keyBinding.addKeyboardHandler(m),e.on("changeSelection",h.destroy),e.on("changeSession",h.destroy),e.on("mouseup",h.destroy),e.on("change",h.destroy),e.session.widgetManager.addLineWidget(h),h.el.onmousedown=e.focus.bind(e),e.renderer.scrollCursorIntoView(null,.5,{bottom:h.el.offsetHeight})},i.importCssString(" .error_widget_wrapper { background: inherit; color: inherit; border:none } .error_widget { border-top: solid 2px; border-bottom: solid 2px; margin: 5px 0; padding: 10px 40px; white-space: pre-wrap; } .error_widget.ace_error, .error_widget_arrow.ace_error{ border-color: #ff5a5a } .error_widget.ace_warning, .error_widget_arrow.ace_warning{ border-color: #F1D817 } .error_widget.ace_info, .error_widget_arrow.ace_info{ border-color: #5a5a5a } .error_widget.ace_ok, .error_widget_arrow.ace_ok{ border-color: #5aaa5a } .error_widget_arrow { position: absolute; border: solid 5px; border-top-color: transparent!important; border-right-color: transparent!important; border-left-color: transparent!important; top: -5px; }","")}),ace.define("ace/ace",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/dom","ace/lib/event","ace/editor","ace/edit_session","ace/undomanager","ace/virtual_renderer","ace/worker/worker_client","ace/keyboard/hash_handler","ace/placeholder","ace/multi_select","ace/mode/folding/fold_mode","ace/theme/textmate","ace/ext/error_marker","ace/config"],function(e,t,n){"use strict";e("./lib/fixoldbrowsers");var r=e("./lib/dom"),i=e("./lib/event"),s=e("./editor").Editor,o=e("./edit_session").EditSession,u=e("./undomanager").UndoManager,a=e("./virtual_renderer").VirtualRenderer;e("./worker/worker_client"),e("./keyboard/hash_handler"),e("./placeholder"),e("./multi_select"),e("./mode/folding/fold_mode"),e("./theme/textmate"),e("./ext/error_marker"),t.config=e("./config"),t.require=e,t.edit=function(e){if(typeof e=="string"){var n=e;e=document.getElementById(n);if(!e)throw new Error("ace.edit can't find div #"+n)}if(e&&e.env&&e.env.editor instanceof s)return e.env.editor;var o="";if(e&&/input|textarea/i.test(e.tagName)){var u=e;o=u.value,e=r.createElement("pre"),u.parentNode.replaceChild(e,u)}else o=r.getInnerText(e),e.innerHTML="";var f=t.createEditSession(o),l=new s(new a(e));l.setSession(f);var c={document:f,editor:l,onResize:l.resize.bind(l,null)};return u&&(c.textarea=u),i.addListener(window,"resize",c.onResize),l.on("destroy",function(){i.removeListener(window,"resize",c.onResize),c.editor.container.env=null}),l.container.env=l.env=c,l},t.createEditSession=function(e,t){var n=new o(e,t);return n.setUndoManager(new u),n},t.EditSession=o,t.UndoManager=u});
2
- (function() {
3
- ace.require(["ace/ace"], function(a) {
4
- a && a.config.init(true);
5
- if (!window.ace)
6
- window.ace = a;
7
- for (var key in a) if (a.hasOwnProperty(key))
8
- window.ace[key] = a[key];
9
- });
10
- })();
11
-
 
 
 
 
 
 
 
 
 
 
 
js/ace/src-min-noconflict/ext-beautify.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/beautify/php_rules",["require","exports","module","ace/token_iterator"],function(e,t,n){"use strict";var r=e("ace/token_iterator").TokenIterator;t.newLines=[{type:"support.php_tag",value:"<?php"},{type:"support.php_tag",value:"<?"},{type:"support.php_tag",value:"?>"},{type:"paren.lparen",value:"{",indent:!0},{type:"paren.rparen",breakBefore:!0,value:"}",indent:!1},{type:"paren.rparen",breakBefore:!0,value:"})",indent:!1,dontBreak:!0},{type:"comment"},{type:"text",value:";"},{type:"text",value:":",context:"php"},{type:"keyword",value:"case",indent:!0,dontBreak:!0},{type:"keyword",value:"default",indent:!0,dontBreak:!0},{type:"keyword",value:"break",indent:!1,dontBreak:!0},{type:"punctuation.doctype.end",value:">"},{type:"meta.tag.punctuation.end",value:">"},{type:"meta.tag.punctuation.begin",value:"<",blockTag:!0,indent:!0,dontBreak:!0},{type:"meta.tag.punctuation.begin",value:"</",indent:!1,breakBefore:!0,dontBreak:!0},{type:"punctuation.operator",value:";"}],t.spaces=[{type:"xml-pe",prepend:!0},{type:"entity.other.attribute-name",prepend:!0},{type:"storage.type",value:"var",append:!0},{type:"storage.type",value:"function",append:!0},{type:"keyword.operator",value:"="},{type:"keyword",value:"as",prepend:!0,append:!0},{type:"keyword",value:"function",append:!0},{type:"support.function",next:/[^\(]/,append:!0},{type:"keyword",value:"or",append:!0,prepend:!0},{type:"keyword",value:"and",append:!0,prepend:!0},{type:"keyword",value:"case",append:!0},{type:"keyword.operator",value:"||",append:!0,prepend:!0},{type:"keyword.operator",value:"&&",append:!0,prepend:!0}],t.singleTags=["!doctype","area","base","br","hr","input","img","link","meta"],t.transform=function(e,n,r){var i=e.getCurrentToken(),s=t.newLines,o=t.spaces,u=t.singleTags,a="",f=0,l=!1,c,h,p={},d,v={},m=!1,g="";while(i!==null){console.log(i);if(!i){i=e.stepForward();continue}i.type=="support.php_tag"&&i.value!="?>"?r="php":i.type=="support.php_tag"&&i.value=="?>"?r="html":i.type=="meta.tag.name.style"&&r!="css"?r="css":i.type=="meta.tag.name.style"&&r=="css"?r="html":i.type=="meta.tag.name.script"&&r!="js"?r="js":i.type=="meta.tag.name.script"&&r=="js"&&(r="html"),v=e.stepForward(),v&&v.type.indexOf("meta.tag.name")==0&&(d=v.value),p.type=="support.php_tag"&&p.value=="<?="&&(l=!0),i.type=="meta.tag.name"&&(i.value=i.value.toLowerCase()),i.type=="text"&&(i.value=i.value.trim());if(!i.value){i=v;continue}g=i.value;for(var y in o)i.type==o[y].type&&(!o[y].value||i.value==o[y].value)&&v&&(!o[y].next||o[y].next.test(v.value))&&(o[y].prepend&&(g=" "+i.value),o[y].append&&(g+=" "));i.type.indexOf("meta.tag.name")==0&&(c=i.value),m=!1;for(y in s)if(i.type==s[y].type&&(!s[y].value||i.value==s[y].value)&&(!s[y].blockTag||u.indexOf(d)===-1)&&(!s[y].context||s[y].context===r)){s[y].indent===!1&&f--;if(s[y].breakBefore&&(!s[y].prev||s[y].prev.test(p.value))){a+="\n",m=!0;for(y=0;y<f;y++)a+=" "}break}if(l===!1)for(y in s)if(p.type==s[y].type&&(!s[y].value||p.value==s[y].value)&&(!s[y].blockTag||u.indexOf(c)===-1)&&(!s[y].context||s[y].context===r)){s[y].indent===!0&&f++;if(!s[y].dontBreak&&!m){a+="\n";for(y=0;y<f;y++)a+=" "}break}a+=g,p.type=="support.php_tag"&&p.value=="?>"&&(l=!1),h=c,p=i,i=v;if(i===null)break}return a}}),ace.define("ace/ext/beautify",["require","exports","module","ace/token_iterator","ace/ext/beautify/php_rules"],function(e,t,n){"use strict";var r=e("ace/token_iterator").TokenIterator,i=e("./beautify/php_rules").transform;t.beautify=function(e){var t=new r(e,0,0),n=t.getCurrentToken(),s=e.$modeId.split("/").pop(),o=i(t,s);e.doc.setValue(o)},t.commands=[{name:"beautify",exec:function(e){t.beautify(e.session)},bindKey:"Ctrl-Shift-B"}]});
2
- (function() {
3
- ace.require(["ace/ext/beautify"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-chromevox.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/chromevox",["require","exports","module","ace/editor","ace/config"],function(e,t,n){function gt(){return typeof cvox!="undefined"&&cvox&&cvox.Api}function wt(e){if(gt())mt(e);else{yt++;if(yt>=bt)return;window.setTimeout(wt,500,e)}}var r={};r.SpeechProperty,r.Cursor,r.Token,r.Annotation;var i={rate:.8,pitch:.4,volume:.9},s={rate:1,pitch:.5,volume:.9},o={rate:.8,pitch:.8,volume:.9},u={rate:.8,pitch:.3,volume:.9},a={rate:.8,pitch:.7,volume:.9},f={rate:.8,pitch:.8,volume:.9},l={punctuationEcho:"none",relativePitch:-0.6},c="ALERT_NONMODAL",h="ALERT_MODAL",p="INVALID_KEYPRESS",d="insertMode",v="start",m=[{substr:";",newSubstr:" semicolon "},{substr:":",newSubstr:" colon "}],g={SPEAK_ANNOT:"annots",SPEAK_ALL_ANNOTS:"all_annots",TOGGLE_LOCATION:"toggle_location",SPEAK_MODE:"mode",SPEAK_ROW_COL:"row_col",TOGGLE_DISPLACEMENT:"toggle_displacement",FOCUS_TEXT:"focus_text"},y="CONTROL + SHIFT ";r.editor=null;var b=null,w={},E=!1,S=!1,x=!1,T=null,N={},C={},k=function(e){return y+String.fromCharCode(e)},L=function(){var e=r.editor.keyBinding.getKeyboardHandler();return e.$id==="ace/keyboard/vim"},A=function(e){return r.editor.getSession().getTokenAt(e.row,e.column+1)},O=function(e){return r.editor.getSession().getLine(e.row)},M=function(e){w[e.row]&&cvox.Api.playEarcon(c),E?(cvox.Api.stop(),W(e),R(A(e)),I(e.row,1)):I(e.row,0)},_=function(e){var t=O(e),n=t.substr(e.column-1);e.column===0&&(n=" "+t);var r=/^\W(\w+)/,i=r.exec(n);return i!==null},D={constant:{prop:i},entity:{prop:o},keyword:{prop:u},storage:{prop:a},variable:{prop:f},meta:{prop:s,replace:[{substr:"</",newSubstr:" closing tag "},{substr:"/>",newSubstr:" close tag "},{substr:"<",newSubstr:" tag start "},{substr:">",newSubstr:" tag end "}]}},P={prop:P},H=function(e,t){var n=e;for(var r=0;r<t.length;r++){var i=t[r],s=new RegExp(i.substr,"g");n=n.replace(s,i.newSubstr)}return n},B=function(e,t,n){var r={};r.value="",r.type=e[t].type;for(var i=t;i<n;i++)r.value+=e[i].value;return r},j=function(e){if(e.length<=1)return e;var t=[],n=0;for(var r=1;r<e.length;r++){var i=e[n],s=e[r];U(i)!==U(s)&&(t.push(B(e,n,r)),n=r)}return t.push(B(e,n,e.length)),t},F=function(e){var t=r.editor.getSession().getLine(e),n=/^\s*$/;return n.exec(t)!==null},I=function(e,t){var n=r.editor.getSession().getTokens(e);if(n.length===0||F(e)){cvox.Api.playEarcon("EDITABLE_TEXT");return}n=j(n);var i=n[0];n=n.filter(function(e){return e!==i}),z(i,t),n.forEach(R)},q=function(e){z(e,0)},R=function(e){z(e,1)},U=function(e){if(!e||!e.type)return;var t=e.type.split(".");if(t.length===0)return;var n=t[0],r=D[n];return r?r:P},z=function(e,t){var n=U(e),r=H(e.value,m);n.replace&&(r=H(r,n.replace)),cvox.Api.speak(r,t,n.prop)},W=function(e){var t=O(e);cvox.Api.speak(t[e.column],1)},X=function(e,t){var n=O(t),r=n.substring(e.column,t.column);r=r.replace(/ /g," space "),cvox.Api.speak(r)},V=function(e,t){if(Math.abs(e.column-t.column)!==1){var n=O(t).length;if(t.column===0||t.column===n){I(t.row,0);return}if(_(t)){cvox.Api.stop(),R(A(t));return}}W(t)},$=function(e,t){r.editor.selection.isEmpty()?S?X(e,t):V(e,t):(X(e,t),cvox.Api.speak("selected",1))},J=function(e){if(x){x=!1;return}var t=r.editor.selection.getCursor();t.row!==b.row?M(t):$(b,t),b=t},K=function(e){r.editor.selection.isEmpty()&&cvox.Api.speak("unselected")},Q=function(e){var t=e.data;switch(t.action){case"removeText":cvox.Api.speak(t.text,0,l),x=!0;break;case"insertText":cvox.Api.speak(t.text,0),x=!0}},G=function(e){var t=e.row,n=e.column;return!w[t]||!w[t][n]},Y=function(e){w={};for(var t=0;t<e.length;t++){var n=e[t],r=n.row,i=n.column;w[r]||(w[r]={}),w[r][i]=n}},Z=function(e){var t=r.editor.getSession().getAnnotations(),n=t.filter(G);n.length>0&&cvox.Api.playEarcon(c),Y(t)},et=function(e){var t=e.type+" "+e.text+" on "+nt(e.row,e.column);t=t.replace(";","semicolon"),cvox.Api.speak(t,1)},tt=function(e){var t=w[e];for(var n in t)et(t[n])},nt=function(e,t){return"row "+(e+1)+" column "+(t+1)},rt=function(){cvox.Api.speak(nt(b.row,b.column))},it=function(){for(var e in w)tt(e)},st=function(){if(!L())return;switch(r.editor.keyBinding.$data.state){case d:cvox.Api.speak("Insert mode");break;case v:cvox.Api.speak("Command mode")}},ot=function(){E=!E,E?cvox.Api.speak("Speak location on row change enabled."):cvox.Api.speak("Speak location on row change disabled.")},ut=function(){S=!S,S?cvox.Api.speak("Speak displacement on column changes."):cvox.Api.speak("Speak current character or word on column changes.")},at=function(e){if(e.ctrlKey&&e.shiftKey){var t=N[e.keyCode];t&&t.func()}},ft=function(e,t){if(!L())return;var n=t.keyBinding.$data.state;if(n===T)return;switch(n){case d:cvox.Api.playEarcon(h),cvox.Api.setKeyEcho(!0);break;case v:cvox.Api.playEarcon(h),cvox.Api.setKeyEcho(!1)}T=n},lt=function(e){var t=e.detail.customCommand,n=C[t];n&&(n.func(),r.editor.focus())},ct=function(){var e=dt.map(function(e){return{desc:e.desc+k(e.keyCode),cmd:e.cmd}}),t=document.querySelector("body");t.setAttribute("contextMenuActions",JSON.stringify(e)),t.addEventListener("ATCustomEvent",lt,!0)},ht=function(e){e.match?I(b.row,0):cvox.Api.playEarcon(p)},pt=function(){r.editor.focus()},dt=[{keyCode:49,func:function(){tt(b.row)},cmd:g.SPEAK_ANNOT,desc:"Speak annotations on line"},{keyCode:50,func:it,cmd:g.SPEAK_ALL_ANNOTS,desc:"Speak all annotations"},{keyCode:51,func:st,cmd:g.SPEAK_MODE,desc:"Speak Vim mode"},{keyCode:52,func:ot,cmd:g.TOGGLE_LOCATION,desc:"Toggle speak row location"},{keyCode:53,func:rt,cmd:g.SPEAK_ROW_COL,desc:"Speak row and column"},{keyCode:54,func:ut,cmd:g.TOGGLE_DISPLACEMENT,desc:"Toggle speak displacement"},{keyCode:55,func:pt,cmd:g.FOCUS_TEXT,desc:"Focus text"}],vt=function(){r.editor=editor,editor.getSession().selection.on("changeCursor",J),editor.getSession().selection.on("changeSelection",K),editor.getSession().on("change",Q),editor.getSession().on("changeAnnotation",Z),editor.on("changeStatus",ft),editor.on("findSearchBox",ht),editor.container.addEventListener("keydown",at),b=editor.selection.getCursor()},mt=function(e){vt(),dt.forEach(function(e){N[e.keyCode]=e,C[e.cmd]=e}),e.on("focus",vt),L()&&cvox.Api.setKeyEcho(!1),ct()},yt=0,bt=15,Et=e("../editor").Editor;e("../config").defineOptions(Et.prototype,"editor",{enableChromevoxEnhancements:{set:function(e){e&&wt(this)},value:!0}})});
2
- (function() {
3
- ace.require(["ace/ext/chromevox"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-elastic_tabstops_lite.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/elastic_tabstops_lite",["require","exports","module","ace/editor","ace/config"],function(e,t,n){"use strict";var r=function(e){this.$editor=e;var t=this,n=[],r=!1;this.onAfterExec=function(){r=!1,t.processRows(n),n=[]},this.onExec=function(){r=!0},this.onChange=function(e){var t=e.data.range;r&&(n.indexOf(t.start.row)==-1&&n.push(t.start.row),t.end.row!=t.start.row&&n.push(t.end.row))}};(function(){this.processRows=function(e){this.$inChange=!0;var t=[];for(var n=0,r=e.length;n<r;n++){var i=e[n];if(t.indexOf(i)>-1)continue;var s=this.$findCellWidthsForBlock(i),o=this.$setBlockCellWidthsToMax(s.cellWidths),u=s.firstRow;for(var a=0,f=o.length;a<f;a++){var l=o[a];t.push(u),this.$adjustRow(u,l),u++}}this.$inChange=!1},this.$findCellWidthsForBlock=function(e){var t=[],n,r=e;while(r>=0){n=this.$cellWidthsForRow(r);if(n.length==0)break;t.unshift(n),r--}var i=r+1;r=e;var s=this.$editor.session.getLength();while(r<s-1){r++,n=this.$cellWidthsForRow(r);if(n.length==0)break;t.push(n)}return{cellWidths:t,firstRow:i}},this.$cellWidthsForRow=function(e){var t=this.$selectionColumnsForRow(e),n=[-1].concat(this.$tabsForRow(e)),r=n.map(function(e){return 0}).slice(1),i=this.$editor.session.getLine(e);for(var s=0,o=n.length-1;s<o;s++){var u=n[s]+1,a=n[s+1],f=this.$rightmostSelectionInCell(t,a),l=i.substring(u,a);r[s]=Math.max(l.replace(/\s+$/g,"").length,f-u)}return r},this.$selectionColumnsForRow=function(e){var t=[],n=this.$editor.getCursorPosition();return this.$editor.session.getSelection().isEmpty()&&e==n.row&&t.push(n.column),t},this.$setBlockCellWidthsToMax=function(e){var t=!0,n,r,i,s=this.$izip_longest(e);for(var o=0,u=s.length;o<u;o++){var a=s[o];if(!a.push){console.error(a);continue}a.push(NaN);for(var f=0,l=a.length;f<l;f++){var c=a[f];t&&(n=f,i=0,t=!1);if(isNaN(c)){r=f;for(var h=n;h<r;h++)e[h][o]=i;t=!0}i=Math.max(i,c)}}return e},this.$rightmostSelectionInCell=function(e,t){var n=0;if(e.length){var r=[];for(var i=0,s=e.length;i<s;i++)e[i]<=t?r.push(i):r.push(0);n=Math.max.apply(Math,r)}return n},this.$tabsForRow=function(e){var t=[],n=this.$editor.session.getLine(e),r=/\t/g,i;while((i=r.exec(n))!=null)t.push(i.index);return t},this.$adjustRow=function(e,t){var n=this.$tabsForRow(e);if(n.length==0)return;var r=0,i=-1,s=this.$izip(t,n);for(var o=0,u=s.length;o<u;o++){var a=s[o][0],f=s[o][1];i+=1+a,f+=r;var l=i-f;if(l==0)continue;var c=this.$editor.session.getLine(e).substr(0,f),h=c.replace(/\s*$/g,""),p=c.length-h.length;l>0&&(this.$editor.session.getDocument().insertInLine({row:e,column:f+1},Array(l+1).join(" ")+" "),this.$editor.session.getDocument().removeInLine(e,f,f+1),r+=l),l<0&&p>=-l&&(this.$editor.session.getDocument().removeInLine(e,f+l,f),r+=l)}},this.$izip_longest=function(e){if(!e[0])return[];var t=e[0].length,n=e.length;for(var r=1;r<n;r++){var i=e[r].length;i>t&&(t=i)}var s=[];for(var o=0;o<t;o++){var u=[];for(var r=0;r<n;r++)e[r][o]===""?u.push(NaN):u.push(e[r][o]);s.push(u)}return s},this.$izip=function(e,t){var n=e.length>=t.length?t.length:e.length,r=[];for(var i=0;i<n;i++){var s=[e[i],t[i]];r.push(s)}return r}}).call(r.prototype),t.ElasticTabstopsLite=r;var i=e("../editor").Editor;e("../config").defineOptions(i.prototype,"editor",{useElasticTabstops:{set:function(e){e?(this.elasticTabstops||(this.elasticTabstops=new r(this)),this.commands.on("afterExec",this.elasticTabstops.onAfterExec),this.commands.on("exec",this.elasticTabstops.onExec),this.on("change",this.elasticTabstops.onChange)):this.elasticTabstops&&(this.commands.removeListener("afterExec",this.elasticTabstops.onAfterExec),this.commands.removeListener("exec",this.elasticTabstops.onExec),this.removeListener("change",this.elasticTabstops.onChange))}}})});
2
- (function() {
3
- ace.require(["ace/ext/elastic_tabstops_lite"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-emmet.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/snippets",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/anchor","ace/keyboard/hash_handler","ace/tokenizer","ace/lib/dom","ace/editor"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=e("./lib/lang"),o=e("./range").Range,u=e("./anchor").Anchor,a=e("./keyboard/hash_handler").HashHandler,f=e("./tokenizer").Tokenizer,l=o.comparePoints,c=function(){this.snippetMap={},this.snippetNameMap={}};(function(){r.implement(this,i),this.getTokenizer=function(){function e(e,t,n){return e=e.substr(1),/^\d+$/.test(e)&&!n.inFormatString?[{tabstopId:parseInt(e,10)}]:[{text:e}]}function t(e){return"(?:[^\\\\"+e+"]|\\\\.)"}return c.$tokenizer=new f({start:[{regex:/:/,onMatch:function(e,t,n){return n.length&&n[0].expectIf?(n[0].expectIf=!1,n[0].elseBranch=n[0],[n[0]]):":"}},{regex:/\\./,onMatch:function(e,t,n){var r=e[1];return r=="}"&&n.length?e=r:"`$\\".indexOf(r)!=-1?e=r:n.inFormatString&&(r=="n"?e="\n":r=="t"?e="\n":"ulULE".indexOf(r)!=-1&&(e={changeCase:r,local:r>"a"})),[e]}},{regex:/}/,onMatch:function(e,t,n){return[n.length?n.shift():e]}},{regex:/\$(?:\d+|\w+)/,onMatch:e},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(t,n,r){var i=e(t.substr(1),n,r);return r.unshift(i[0]),i},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+t("\\|")+"*\\|",onMatch:function(e,t,n){n[0].choices=e.slice(1,-1).split(",")},next:"start"},{regex:"/("+t("/")+"+)/(?:("+t("/")+"*)/)(\\w*):?",onMatch:function(e,t,n){var r=n[0];return r.fmtString=e,e=this.splitRegex.exec(e),r.guard=e[1],r.fmt=e[2],r.flag=e[3],""},next:"start"},{regex:"`"+t("`")+"*`",onMatch:function(e,t,n){return n[0].code=e.splice(1,-1),""},next:"start"},{regex:"\\?",onMatch:function(e,t,n){n[0]&&(n[0].expectIf=!0)},next:"start"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:"/("+t("/")+"+)/",token:"regex"},{regex:"",onMatch:function(e,t,n){n.inFormatString=!0},next:"start"}]}),c.prototype.getTokenizer=function(){return c.$tokenizer},c.$tokenizer},this.tokenizeTmSnippet=function(e,t){return this.getTokenizer().getLineTokens(e,t).tokens.map(function(e){return e.value||e})},this.$getDefaultValue=function(e,t){if(/^[A-Z]\d+$/.test(t)){var n=t.substr(1);return(this.variables[t[0]+"__"]||{})[n]}if(/^\d+$/.test(t))return(this.variables.__||{})[t];t=t.replace(/^TM_/,"");if(!e)return;var r=e.session;switch(t){case"CURRENT_WORD":var i=r.getWordRange();case"SELECTION":case"SELECTED_TEXT":return r.getTextRange(i);case"CURRENT_LINE":return r.getLine(e.getCursorPosition().row);case"PREV_LINE":return r.getLine(e.getCursorPosition().row-1);case"LINE_INDEX":return e.getCursorPosition().column;case"LINE_NUMBER":return e.getCursorPosition().row+1;case"SOFT_TABS":return r.getUseSoftTabs()?"YES":"NO";case"TAB_SIZE":return r.getTabSize();case"FILENAME":case"FILEPATH":return"";case"FULLNAME":return"Ace"}},this.variables={},this.getVariableValue=function(e,t){return this.variables.hasOwnProperty(t)?this.variables[t](e,t)||"":this.$getDefaultValue(e,t)||""},this.tmStrFormat=function(e,t,n){var r=t.flag||"",i=t.guard;i=new RegExp(i,r.replace(/[^gi]/,""));var s=this.tokenizeTmSnippet(t.fmt,"formatString"),o=this,u=e.replace(i,function(){o.variables.__=arguments;var e=o.resolveVariables(s,n),t="E";for(var r=0;r<e.length;r++){var i=e[r];if(typeof i=="object"){e[r]="";if(i.changeCase&&i.local){var u=e[r+1];u&&typeof u=="string"&&(i.changeCase=="u"?e[r]=u[0].toUpperCase():e[r]=u[0].toLowerCase(),e[r+1]=u.substr(1))}else i.changeCase&&(t=i.changeCase)}else t=="U"?e[r]=i.toUpperCase():t=="L"&&(e[r]=i.toLowerCase())}return e.join("")});return this.variables.__=null,u},this.resolveVariables=function(e,t){function o(t){var n=e.indexOf(t,r+1);n!=-1&&(r=n)}var n=[];for(var r=0;r<e.length;r++){var i=e[r];if(typeof i=="string")n.push(i);else{if(typeof i!="object")continue;if(i.skip)o(i);else{if(i.processed<r)continue;if(i.text){var s=this.getVariableValue(t,i.text);s&&i.fmtString&&(s=this.tmStrFormat(s,i)),i.processed=r,i.expectIf==null?s&&(n.push(s),o(i)):s?i.skip=i.elseBranch:o(i)}else i.tabstopId!=null?n.push(i):i.changeCase!=null&&n.push(i)}}}return n},this.insertSnippetForSelection=function(e,t){function f(e){var t=[];for(var n=0;n<e.length;n++){var r=e[n];if(typeof r=="object"){if(a[r.tabstopId])continue;var i=e.lastIndexOf(r,n-1);r=t[i]||{tabstopId:r.tabstopId}}t[n]=r}return t}var n=e.getCursorPosition(),r=e.session.getLine(n.row),i=e.session.getTabString(),s=r.match(/^\s*/)[0];n.column<s.length&&(s=s.slice(0,n.column));var o=this.tokenizeTmSnippet(t);o=this.resolveVariables(o,e),o=o.map(function(e){return e=="\n"?e+s:typeof e=="string"?e.replace(/\t/g,i):e});var u=[];o.forEach(function(e,t){if(typeof e!="object")return;var n=e.tabstopId,r=u[n];r||(r=u[n]=[],r.index=n,r.value="");if(r.indexOf(e)!==-1)return;r.push(e);var i=o.indexOf(e,t+1);if(i===-1)return;var s=o.slice(t+1,i),a=s.some(function(e){return typeof e=="object"});a&&!r.value?r.value=s:s.length&&(!r.value||typeof r.value!="string")&&(r.value=s.join(""))}),u.forEach(function(e){e.length=0});var a={};for(var l=0;l<o.length;l++){var c=o[l];if(typeof c!="object")continue;var p=c.tabstopId,d=o.indexOf(c,l+1);if(a[p]){a[p]===c&&(a[p]=null);continue}var v=u[p],m=typeof v.value=="string"?[v.value]:f(v.value);m.unshift(l+1,Math.max(0,d-l)),m.push(c),a[p]=c,o.splice.apply(o,m),v.indexOf(c)===-1&&v.push(c)}var g=0,y=0,b="";o.forEach(function(e){typeof e=="string"?(e[0]==="\n"?(y=e.length-1,g++):y+=e.length,b+=e):e.start?e.end={row:g,column:y}:e.start={row:g,column:y}});var w=e.getSelectionRange(),E=e.session.replace(w,b),S=new h(e),x=e.inVirtualSelectionMode&&e.selection.index;S.addTabstops(u,w.start,E,x)},this.insertSnippet=function(e,t){var n=this;if(e.inVirtualSelectionMode)return n.insertSnippetForSelection(e,t);e.forEachSelection(function(){n.insertSnippetForSelection(e,t)},null,{keepOrder:!0}),e.tabstopManager&&e.tabstopManager.tabNext()},this.$getScope=function(e){var t=e.session.$mode.$id||"";t=t.split("/").pop();if(t==="html"||t==="php"){t==="php"&&!e.session.$mode.inlinePhp&&(t="html");var n=e.getCursorPosition(),r=e.session.getState(n.row);typeof r=="object"&&(r=r[0]),r.substring&&(r.substring(0,3)=="js-"?t="javascript":r.substring(0,4)=="css-"?t="css":r.substring(0,4)=="php-"&&(t="php"))}return t},this.getActiveScopes=function(e){var t=this.$getScope(e),n=[t],r=this.snippetMap;return r[t]&&r[t].includeScopes&&n.push.apply(n,r[t].includeScopes),n.push("_"),n},this.expandWithTab=function(e,t){var n=this,r=e.forEachSelection(function(){return n.expandSnippetForSelection(e,t)},null,{keepOrder:!0});return r&&e.tabstopManager&&e.tabstopManager.tabNext(),r},this.expandSnippetForSelection=function(e,t){var n=e.getCursorPosition(),r=e.session.getLine(n.row),i=r.substring(0,n.column),s=r.substr(n.column),o=this.snippetMap,u;return this.getActiveScopes(e).some(function(e){var t=o[e];return t&&(u=this.findMatchingSnippet(t,i,s)),!!u},this),u?t&&t.dryRun?!0:(e.session.doc.removeInLine(n.row,n.column-u.replaceBefore.length,n.column+u.replaceAfter.length),this.variables.M__=u.matchBefore,this.variables.T__=u.matchAfter,this.insertSnippetForSelection(e,u.content),this.variables.M__=this.variables.T__=null,!0):!1},this.findMatchingSnippet=function(e,t,n){for(var r=e.length;r--;){var i=e[r];if(i.startRe&&!i.startRe.test(t))continue;if(i.endRe&&!i.endRe.test(n))continue;if(!i.startRe&&!i.endRe)continue;return i.matchBefore=i.startRe?i.startRe.exec(t):[""],i.matchAfter=i.endRe?i.endRe.exec(n):[""],i.replaceBefore=i.triggerRe?i.triggerRe.exec(t)[0]:"",i.replaceAfter=i.endTriggerRe?i.endTriggerRe.exec(n)[0]:"",i}},this.snippetMap={},this.snippetNameMap={},this.register=function(e,t){function o(e){return e&&!/^\^?\(.*\)\$?$|^\\b$/.test(e)&&(e="(?:"+e+")"),e||""}function u(e,t,n){return e=o(e),t=o(t),n?(e=t+e,e&&e[e.length-1]!="$"&&(e+="$")):(e+=t,e&&e[0]!="^"&&(e="^"+e)),new RegExp(e)}function a(e){e.scope||(e.scope=t||"_"),t=e.scope,n[t]||(n[t]=[],r[t]={});var o=r[t];if(e.name){var a=o[e.name];a&&i.unregister(a),o[e.name]=e}n[t].push(e),e.tabTrigger&&!e.trigger&&(!e.guard&&/^\w/.test(e.tabTrigger)&&(e.guard="\\b"),e.trigger=s.escapeRegExp(e.tabTrigger)),e.startRe=u(e.trigger,e.guard,!0),e.triggerRe=new RegExp(e.trigger,"",!0),e.endRe=u(e.endTrigger,e.endGuard,!0),e.endTriggerRe=new RegExp(e.endTrigger,"",!0)}var n=this.snippetMap,r=this.snippetNameMap,i=this;e||(e=[]),e&&e.content?a(e):Array.isArray(e)&&e.forEach(a),this._signal("registerSnippets",{scope:t})},this.unregister=function(e,t){function i(e){var i=r[e.scope||t];if(i&&i[e.name]){delete i[e.name];var s=n[e.scope||t],o=s&&s.indexOf(e);o>=0&&s.splice(o,1)}}var n=this.snippetMap,r=this.snippetNameMap;e.content?i(e):Array.isArray(e)&&e.forEach(i)},this.parseSnippetFile=function(e){e=e.replace(/\r/g,"");var t=[],n={},r=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm,i;while(i=r.exec(e)){if(i[1])try{n=JSON.parse(i[1]),t.push(n)}catch(s){}if(i[4])n.content=i[4].replace(/^\t/gm,""),t.push(n),n={};else{var o=i[2],u=i[3];if(o=="regex"){var a=/\/((?:[^\/\\]|\\.)*)|$/g;n.guard=a.exec(u)[1],n.trigger=a.exec(u)[1],n.endTrigger=a.exec(u)[1],n.endGuard=a.exec(u)[1]}else o=="snippet"?(n.tabTrigger=u.match(/^\S*/)[0],n.name||(n.name=u)):n[o]=u}}return t},this.getSnippetByName=function(e,t){var n=this.snippetNameMap,r;return this.getActiveScopes(t).some(function(t){var i=n[t];return i&&(r=i[e]),!!r},this),r}}).call(c.prototype);var h=function(e){if(e.tabstopManager)return e.tabstopManager;e.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=s.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(e)};(function(){this.attach=function(e){this.index=0,this.ranges=[],this.tabstops=[],this.$openTabstops=null,this.selectedTabstop=null,this.editor=e,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},this.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges=null,this.tabstops=null,this.selectedTabstop=null,this.editor.removeListener("change",this.$onChange),this.editor.removeListener("changeSelection",this.$onChangeSelection),this.editor.removeListener("changeSession",this.$onChangeSession),this.editor.commands.removeListener("afterExec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.editor=null},this.onChange=function(e){var t=e.data.range,n=e.data.action[0]=="r",r=t.start,i=t.end,s=r.row,o=i.row,u=o-s,a=i.column-r.column;n&&(u=-u,a=-a);if(!this.$inChange&&n){var f=this.selectedTabstop,c=f&&!f.some(function(e){return l(e.start,r)<=0&&l(e.end,i)>=0});if(c)return this.detach()}var h=this.ranges;for(var p=0;p<h.length;p++){var d=h[p];if(d.end.row<r.row)continue;if(n&&l(r,d.start)<0&&l(i,d.end)>0){this.removeRange(d),p--;continue}d.start.row==s&&d.start.column>r.column&&(d.start.column+=a),d.end.row==s&&d.end.column>=r.column&&(d.end.column+=a),d.start.row>=s&&(d.start.row+=u),d.end.row>=s&&(d.end.row+=u),l(d.start,d.end)>0&&this.removeRange(d)}h.length||this.detach()},this.updateLinkedFields=function(){var e=this.selectedTabstop;if(!e||!e.hasLinkedRanges)return;this.$inChange=!0;var n=this.editor.session,r=n.getTextRange(e.firstNonLinked);for(var i=e.length;i--;){var s=e[i];if(!s.linked)continue;var o=t.snippetManager.tmStrFormat(r,s.original);n.replace(s,o)}this.$inChange=!1},this.onAfterExec=function(e){e.command&&!e.command.readOnly&&this.updateLinkedFields()},this.onChangeSelection=function(){if(!this.editor)return;var e=this.editor.selection.lead,t=this.editor.selection.anchor,n=this.editor.selection.isEmpty();for(var r=this.ranges.length;r--;){if(this.ranges[r].linked)continue;var i=this.ranges[r].contains(e.row,e.column),s=n||this.ranges[r].contains(t.row,t.column);if(i&&s)return}this.detach()},this.onChangeSession=function(){this.detach()},this.tabNext=function(e){var t=this.tabstops.length,n=this.index+(e||1);n=Math.min(Math.max(n,1),t),n==t&&(n=0),this.selectTabstop(n),n===0&&this.detach()},this.selectTabstop=function(e){this.$openTabstops=null;var t=this.tabstops[this.index];t&&this.addTabstopMarkers(t),this.index=e,t=this.tabstops[this.index];if(!t||!t.length)return;this.selectedTabstop=t;if(!this.editor.inVirtualSelectionMode){var n=this.editor.multiSelect;n.toSingleRange(t.firstNonLinked.clone());for(var r=t.length;r--;){if(t.hasLinkedRanges&&t[r].linked)continue;n.addRange(t[r].clone(),!0)}n.ranges[0]&&n.addRange(n.ranges[0].clone())}else this.editor.selection.setRange(t.firstNonLinked);this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},this.addTabstops=function(e,t,n){this.$openTabstops||(this.$openTabstops=[]);if(!e[0]){var r=o.fromPoints(n,n);v(r.start,t),v(r.end,t),e[0]=[r],e[0].index=0}var i=this.index,s=[i+1,0],u=this.ranges;e.forEach(function(e,n){var r=this.$openTabstops[n]||e;for(var i=e.length;i--;){var a=e[i],f=o.fromPoints(a.start,a.end||a.start);d(f.start,t),d(f.end,t),f.original=a,f.tabstop=r,u.push(f),r!=e?r.unshift(f):r[i]=f,a.fmtString?(f.linked=!0,r.hasLinkedRanges=!0):r.firstNonLinked||(r.firstNonLinked=f)}r.firstNonLinked||(r.hasLinkedRanges=!1),r===e&&(s.push(r),this.$openTabstops[n]=r),this.addTabstopMarkers(r)},this),s.length>2&&(this.tabstops.length&&s.push(s.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,s))},this.addTabstopMarkers=function(e){var t=this.editor.session;e.forEach(function(e){e.markerId||(e.markerId=t.addMarker(e,"ace_snippet-marker","text"))})},this.removeTabstopMarkers=function(e){var t=this.editor.session;e.forEach(function(e){t.removeMarker(e.markerId),e.markerId=null})},this.removeRange=function(e){var t=e.tabstop.indexOf(e);e.tabstop.splice(t,1),t=this.ranges.indexOf(e),this.ranges.splice(t,1),this.editor.session.removeMarker(e.markerId),e.tabstop.length||(t=this.tabstops.indexOf(e.tabstop),t!=-1&&this.tabstops.splice(t,1),this.tabstops.length||this.detach())},this.keyboardHandler=new a,this.keyboardHandler.bindKeys({Tab:function(e){if(t.snippetManager&&t.snippetManager.expandWithTab(e))return;e.tabstopManager.tabNext(1)},"Shift-Tab":function(e){e.tabstopManager.tabNext(-1)},Esc:function(e){e.tabstopManager.detach()},Return:function(e){return!1}})}).call(h.prototype);var p={};p.onChange=u.prototype.onChange,p.setPosition=function(e,t){this.pos.row=e,this.pos.column=t},p.update=function(e,t,n){this.$insertRight=n,this.pos=e,this.onChange(t)};var d=function(e,t){e.row==0&&(e.column+=t.column),e.row+=t.row},v=function(e,t){e.row==t.row&&(e.column-=t.column),e.row-=t.row};e("./lib/dom").importCssString(".ace_snippet-marker { -moz-box-sizing: border-box; box-sizing: border-box; background: rgba(194, 193, 208, 0.09); border: 1px dotted rgba(211, 208, 235, 0.62); position: absolute;}"),t.snippetManager=new c;var m=e("./editor").Editor;(function(){this.insertSnippet=function(e,n){return t.snippetManager.insertSnippet(this,e,n)},this.expandSnippet=function(e){return t.snippetManager.expandWithTab(this,e)}}).call(m.prototype)}),ace.define("ace/ext/emmet",["require","exports","module","ace/keyboard/hash_handler","ace/editor","ace/snippets","ace/range","resources","resources","range","tabStops","resources","utils","actions","ace/config","ace/config"],function(e,t,n){"use strict";function f(){}var r=e("ace/keyboard/hash_handler").HashHandler,i=e("ace/editor").Editor,s=e("ace/snippets").snippetManager,o=e("ace/range").Range,u,a;f.prototype={setupContext:function(e){this.ace=e,this.indentation=e.session.getTabString(),u||(u=window.emmet),u.require("resources").setVariable("indentation",this.indentation),this.$syntax=null,this.$syntax=this.getSyntax()},getSelectionRange:function(){var e=this.ace.getSelectionRange(),t=this.ace.session.doc;return{start:t.positionToIndex(e.start),end:t.positionToIndex(e.end)}},createSelection:function(e,t){var n=this.ace.session.doc;this.ace.selection.setRange({start:n.indexToPosition(e),end:n.indexToPosition(t)})},getCurrentLineRange:function(){var e=this.ace,t=e.getCursorPosition().row,n=e.session.getLine(t).length,r=e.session.doc.positionToIndex({row:t,column:0});return{start:r,end:r+n}},getCaretPos:function(){var e=this.ace.getCursorPosition();return this.ace.session.doc.positionToIndex(e)},setCaretPos:function(e){var t=this.ace.session.doc.indexToPosition(e);this.ace.selection.moveToPosition(t)},getCurrentLine:function(){var e=this.ace.getCursorPosition().row;return this.ace.session.getLine(e)},replaceContent:function(e,t,n,r){n==null&&(n=t==null?this.getContent().length:t),t==null&&(t=0);var i=this.ace,u=i.session.doc,a=o.fromPoints(u.indexToPosition(t),u.indexToPosition(n));i.session.remove(a),a.end=a.start,e=this.$updateTabstops(e),s.insertSnippet(i,e)},getContent:function(){return this.ace.getValue()},getSyntax:function(){if(this.$syntax)return this.$syntax;var e=this.ace.session.$modeId.split("/").pop();if(e=="html"||e=="php"){var t=this.ace.getCursorPosition(),n=this.ace.session.getState(t.row);typeof n!="string"&&(n=n[0]),n&&(n=n.split("-"),n.length>1?e=n[0]:e=="php"&&(e="html"))}return e},getProfileName:function(){switch(this.getSyntax()){case"css":return"css";case"xml":case"xsl":return"xml";case"html":var e=u.require("resources").getVariable("profile");return e||(e=this.ace.session.getLines(0,2).join("").search(/<!DOCTYPE[^>]+XHTML/i)!=-1?"xhtml":"html"),e}return"xhtml"},prompt:function(e){return prompt(e)},getSelection:function(){return this.ace.session.getTextRange()},getFilePath:function(){return""},$updateTabstops:function(e){var t=1e3,n=0,r=null,i=u.require("range"),s=u.require("tabStops"),o=u.require("resources").getVocabulary("user"),a={tabstop:function(e){var o=parseInt(e.group,10),u=o===0;u?o=++n:o+=t;var f=e.placeholder;f&&(f=s.processText(f,a));var l="${"+o+(f?":"+f:"")+"}";return u&&(r=i.create(e.start,l)),l},escape:function(e){return e=="$"?"\\$":e=="\\"?"\\\\":e}};return e=s.processText(e,a),o.variables.insert_final_tabstop&&!/\$\{0\}$/.test(e)?e+="${0}":r&&(e=u.require("utils").replaceSubstring(e,"${0}",r)),e}};var l={expand_abbreviation:{mac:"ctrl+alt+e",win:"alt+e"},match_pair_outward:{mac:"ctrl+d",win:"ctrl+,"},match_pair_inward:{mac:"ctrl+j",win:"ctrl+shift+0"},matching_pair:{mac:"ctrl+alt+j",win:"alt+j"},next_edit_point:"alt+right",prev_edit_point:"alt+left",toggle_comment:{mac:"command+/",win:"ctrl+/"},split_join_tag:{mac:"shift+command+'",win:"shift+ctrl+`"},remove_tag:{mac:"command+'",win:"shift+ctrl+;"},evaluate_math_expression:{mac:"shift+command+y",win:"shift+ctrl+y"},increment_number_by_1:"ctrl+up",decrement_number_by_1:"ctrl+down",increment_number_by_01:"alt+up",decrement_number_by_01:"alt+down",increment_number_by_10:{mac:"alt+command+up",win:"shift+alt+up"},decrement_number_by_10:{mac:"alt+command+down",win:"shift+alt+down"},select_next_item:{mac:"shift+command+.",win:"shift+ctrl+."},select_previous_item:{mac:"shift+command+,",win:"shift+ctrl+,"},reflect_css_value:{mac:"shift+command+r",win:"shift+ctrl+r"},encode_decode_data_url:{mac:"shift+ctrl+d",win:"ctrl+'"},expand_abbreviation_with_tab:"Tab",wrap_with_abbreviation:{mac:"shift+ctrl+a",win:"shift+ctrl+a"}},c=new f;t.commands=new r,t.runEmmetCommand=function(e){try{c.setupContext(e);if(c.getSyntax()=="php")return!1;var t=u.require("actions");if(this.action=="expand_abbreviation_with_tab"&&!e.selection.isEmpty())return!1;if(this.action=="wrap_with_abbreviation")return setTimeout(function(){t.run("wrap_with_abbreviation",c)},0);var n=e.selection.lead,r=e.session.getTokenAt(n.row,n.column);if(r&&/\btag\b/.test(r.type))return!1;var i=t.run(this.action,c)}catch(s){e._signal("changeStatus",typeof s=="string"?s:s.message),console.log(s),i=!1}return i};for(var h in l)t.commands.addCommand({name:"emmet:"+h,action:h,bindKey:l[h],exec:t.runEmmetCommand,multiSelectAction:"forEach"});t.updateCommands=function(e,n){n?e.keyBinding.addKeyboardHandler(t.commands):e.keyBinding.removeKeyboardHandler(t.commands)},t.isSupportedMode=function(e){return e&&/css|less|scss|sass|stylus|html|php|twig|ejs/.test(e)};var p=function(n,r){var i=r;if(!i)return;var s=t.isSupportedMode(i.session.$modeId);n.enableEmmet===!1&&(s=!1),s&&typeof a=="string"&&e("ace/config").loadModule(a,function(){a=null}),t.updateCommands(i,s)};t.AceEmmetEditor=f,e("ace/config").defineOptions(i.prototype,"editor",{enableEmmet:{set:function(e){this[e?"on":"removeListener"]("changeMode",p),p({enableEmmet:!!e},this)},value:!0}}),t.setCore=function(e){typeof e=="string"?a=e:u=e}});
2
- (function() {
3
- ace.require(["ace/ext/emmet"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-error_marker.js DELETED
@@ -1,5 +0,0 @@
1
- ;
2
- (function() {
3
- ace.require(["ace/ext/error_marker"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-keybinding_menu.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/menu_tools/overlay_page",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../../lib/dom"),i="#ace_settingsmenu, #kbshortcutmenu {background-color: #F7F7F7;color: black;box-shadow: -5px 4px 5px rgba(126, 126, 126, 0.55);padding: 1em 0.5em 2em 1em;overflow: auto;position: absolute;margin: 0;bottom: 0;right: 0;top: 0;z-index: 9991;cursor: default;}.ace_dark #ace_settingsmenu, .ace_dark #kbshortcutmenu {box-shadow: -20px 10px 25px rgba(126, 126, 126, 0.25);background-color: rgba(255, 255, 255, 0.6);color: black;}.ace_optionsMenuEntry:hover {background-color: rgba(100, 100, 100, 0.1);-webkit-transition: all 0.5s;transition: all 0.3s}.ace_closeButton {background: rgba(245, 146, 146, 0.5);border: 1px solid #F48A8A;border-radius: 50%;padding: 7px;position: absolute;right: -8px;top: -8px;z-index: 1000;}.ace_closeButton{background: rgba(245, 146, 146, 0.9);}.ace_optionsMenuKey {color: darkslateblue;font-weight: bold;}.ace_optionsMenuCommand {color: darkcyan;font-weight: normal;}";r.importCssString(i),n.exports.overlayPage=function(t,n,i,s,o,u){function l(e){e.keyCode===27&&a.click()}i=i?"top: "+i+";":"",o=o?"bottom: "+o+";":"",s=s?"right: "+s+";":"",u=u?"left: "+u+";":"";var a=document.createElement("div"),f=document.createElement("div");a.style.cssText="margin: 0; padding: 0; position: fixed; top:0; bottom:0; left:0; right:0;z-index: 9990; background-color: rgba(0, 0, 0, 0.3);",a.addEventListener("click",function(){document.removeEventListener("keydown",l),a.parentNode.removeChild(a),t.focus(),a=null}),document.addEventListener("keydown",l),f.style.cssText=i+s+o+u,f.addEventListener("click",function(e){e.stopPropagation()});var c=r.createElement("div");c.style.position="relative";var h=r.createElement("div");h.className="ace_closeButton",h.addEventListener("click",function(){a.click()}),c.appendChild(h),f.appendChild(c),f.appendChild(n),a.appendChild(f),document.body.appendChild(a),t.blur()}}),ace.define("ace/ext/menu_tools/get_editor_keyboard_shortcuts",["require","exports","module","ace/lib/keys"],function(e,t,n){"use strict";var r=e("../../lib/keys");n.exports.getEditorKeybordShortcuts=function(e){var t=r.KEY_MODS,n=[],i={};return e.keyBinding.$handlers.forEach(function(e){var t=e.commandKeyBinding;for(var r in t){var s=r.replace(/(^|-)\w/g,function(e){return e.toUpperCase()}),o=t[r];Array.isArray(o)||(o=[o]),o.forEach(function(e){typeof e!="string"&&(e=e.name),i[e]?i[e].key+="|"+s:(i[e]={key:s,command:e},n.push(i[e]))})}}),n}}),ace.define("ace/ext/keybinding_menu",["require","exports","module","ace/editor","ace/ext/menu_tools/overlay_page","ace/ext/menu_tools/get_editor_keyboard_shortcuts"],function(e,t,n){"use strict";function i(t){if(!document.getElementById("kbshortcutmenu")){var n=e("./menu_tools/overlay_page").overlayPage,r=e("./menu_tools/get_editor_keyboard_shortcuts").getEditorKeybordShortcuts,i=r(t),s=document.createElement("div"),o=i.reduce(function(e,t){return e+'<div class="ace_optionsMenuEntry"><span class="ace_optionsMenuCommand">'+t.command+"</span> : "+'<span class="ace_optionsMenuKey">'+t.key+"</span></div>"},"");s.id="kbshortcutmenu",s.innerHTML="<h1>Keyboard Shortcuts</h1>"+o+"</div>",n(t,s,"0","0","0",null)}}var r=e("ace/editor").Editor;n.exports.init=function(e){r.prototype.showKeyboardShortcuts=function(){i(this)},e.commands.addCommands([{name:"showKeyboardShortcuts",bindKey:{win:"Ctrl-Alt-h",mac:"Command-Alt-h"},exec:function(e,t){e.showKeyboardShortcuts()}}])}});
2
- (function() {
3
- ace.require(["ace/ext/keybinding_menu"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-language_tools.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/snippets",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/anchor","ace/keyboard/hash_handler","ace/tokenizer","ace/lib/dom","ace/editor"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=e("./lib/lang"),o=e("./range").Range,u=e("./anchor").Anchor,a=e("./keyboard/hash_handler").HashHandler,f=e("./tokenizer").Tokenizer,l=o.comparePoints,c=function(){this.snippetMap={},this.snippetNameMap={}};(function(){r.implement(this,i),this.getTokenizer=function(){function e(e,t,n){return e=e.substr(1),/^\d+$/.test(e)&&!n.inFormatString?[{tabstopId:parseInt(e,10)}]:[{text:e}]}function t(e){return"(?:[^\\\\"+e+"]|\\\\.)"}return c.$tokenizer=new f({start:[{regex:/:/,onMatch:function(e,t,n){return n.length&&n[0].expectIf?(n[0].expectIf=!1,n[0].elseBranch=n[0],[n[0]]):":"}},{regex:/\\./,onMatch:function(e,t,n){var r=e[1];return r=="}"&&n.length?e=r:"`$\\".indexOf(r)!=-1?e=r:n.inFormatString&&(r=="n"?e="\n":r=="t"?e="\n":"ulULE".indexOf(r)!=-1&&(e={changeCase:r,local:r>"a"})),[e]}},{regex:/}/,onMatch:function(e,t,n){return[n.length?n.shift():e]}},{regex:/\$(?:\d+|\w+)/,onMatch:e},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(t,n,r){var i=e(t.substr(1),n,r);return r.unshift(i[0]),i},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+t("\\|")+"*\\|",onMatch:function(e,t,n){n[0].choices=e.slice(1,-1).split(",")},next:"start"},{regex:"/("+t("/")+"+)/(?:("+t("/")+"*)/)(\\w*):?",onMatch:function(e,t,n){var r=n[0];return r.fmtString=e,e=this.splitRegex.exec(e),r.guard=e[1],r.fmt=e[2],r.flag=e[3],""},next:"start"},{regex:"`"+t("`")+"*`",onMatch:function(e,t,n){return n[0].code=e.splice(1,-1),""},next:"start"},{regex:"\\?",onMatch:function(e,t,n){n[0]&&(n[0].expectIf=!0)},next:"start"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:"/("+t("/")+"+)/",token:"regex"},{regex:"",onMatch:function(e,t,n){n.inFormatString=!0},next:"start"}]}),c.prototype.getTokenizer=function(){return c.$tokenizer},c.$tokenizer},this.tokenizeTmSnippet=function(e,t){return this.getTokenizer().getLineTokens(e,t).tokens.map(function(e){return e.value||e})},this.$getDefaultValue=function(e,t){if(/^[A-Z]\d+$/.test(t)){var n=t.substr(1);return(this.variables[t[0]+"__"]||{})[n]}if(/^\d+$/.test(t))return(this.variables.__||{})[t];t=t.replace(/^TM_/,"");if(!e)return;var r=e.session;switch(t){case"CURRENT_WORD":var i=r.getWordRange();case"SELECTION":case"SELECTED_TEXT":return r.getTextRange(i);case"CURRENT_LINE":return r.getLine(e.getCursorPosition().row);case"PREV_LINE":return r.getLine(e.getCursorPosition().row-1);case"LINE_INDEX":return e.getCursorPosition().column;case"LINE_NUMBER":return e.getCursorPosition().row+1;case"SOFT_TABS":return r.getUseSoftTabs()?"YES":"NO";case"TAB_SIZE":return r.getTabSize();case"FILENAME":case"FILEPATH":return"";case"FULLNAME":return"Ace"}},this.variables={},this.getVariableValue=function(e,t){return this.variables.hasOwnProperty(t)?this.variables[t](e,t)||"":this.$getDefaultValue(e,t)||""},this.tmStrFormat=function(e,t,n){var r=t.flag||"",i=t.guard;i=new RegExp(i,r.replace(/[^gi]/,""));var s=this.tokenizeTmSnippet(t.fmt,"formatString"),o=this,u=e.replace(i,function(){o.variables.__=arguments;var e=o.resolveVariables(s,n),t="E";for(var r=0;r<e.length;r++){var i=e[r];if(typeof i=="object"){e[r]="";if(i.changeCase&&i.local){var u=e[r+1];u&&typeof u=="string"&&(i.changeCase=="u"?e[r]=u[0].toUpperCase():e[r]=u[0].toLowerCase(),e[r+1]=u.substr(1))}else i.changeCase&&(t=i.changeCase)}else t=="U"?e[r]=i.toUpperCase():t=="L"&&(e[r]=i.toLowerCase())}return e.join("")});return this.variables.__=null,u},this.resolveVariables=function(e,t){function o(t){var n=e.indexOf(t,r+1);n!=-1&&(r=n)}var n=[];for(var r=0;r<e.length;r++){var i=e[r];if(typeof i=="string")n.push(i);else{if(typeof i!="object")continue;if(i.skip)o(i);else{if(i.processed<r)continue;if(i.text){var s=this.getVariableValue(t,i.text);s&&i.fmtString&&(s=this.tmStrFormat(s,i)),i.processed=r,i.expectIf==null?s&&(n.push(s),o(i)):s?i.skip=i.elseBranch:o(i)}else i.tabstopId!=null?n.push(i):i.changeCase!=null&&n.push(i)}}}return n},this.insertSnippetForSelection=function(e,t){function f(e){var t=[];for(var n=0;n<e.length;n++){var r=e[n];if(typeof r=="object"){if(a[r.tabstopId])continue;var i=e.lastIndexOf(r,n-1);r=t[i]||{tabstopId:r.tabstopId}}t[n]=r}return t}var n=e.getCursorPosition(),r=e.session.getLine(n.row),i=e.session.getTabString(),s=r.match(/^\s*/)[0];n.column<s.length&&(s=s.slice(0,n.column));var o=this.tokenizeTmSnippet(t);o=this.resolveVariables(o,e),o=o.map(function(e){return e=="\n"?e+s:typeof e=="string"?e.replace(/\t/g,i):e});var u=[];o.forEach(function(e,t){if(typeof e!="object")return;var n=e.tabstopId,r=u[n];r||(r=u[n]=[],r.index=n,r.value="");if(r.indexOf(e)!==-1)return;r.push(e);var i=o.indexOf(e,t+1);if(i===-1)return;var s=o.slice(t+1,i),a=s.some(function(e){return typeof e=="object"});a&&!r.value?r.value=s:s.length&&(!r.value||typeof r.value!="string")&&(r.value=s.join(""))}),u.forEach(function(e){e.length=0});var a={};for(var l=0;l<o.length;l++){var c=o[l];if(typeof c!="object")continue;var p=c.tabstopId,d=o.indexOf(c,l+1);if(a[p]){a[p]===c&&(a[p]=null);continue}var v=u[p],m=typeof v.value=="string"?[v.value]:f(v.value);m.unshift(l+1,Math.max(0,d-l)),m.push(c),a[p]=c,o.splice.apply(o,m),v.indexOf(c)===-1&&v.push(c)}var g=0,y=0,b="";o.forEach(function(e){typeof e=="string"?(e[0]==="\n"?(y=e.length-1,g++):y+=e.length,b+=e):e.start?e.end={row:g,column:y}:e.start={row:g,column:y}});var w=e.getSelectionRange(),E=e.session.replace(w,b),S=new h(e),x=e.inVirtualSelectionMode&&e.selection.index;S.addTabstops(u,w.start,E,x)},this.insertSnippet=function(e,t){var n=this;if(e.inVirtualSelectionMode)return n.insertSnippetForSelection(e,t);e.forEachSelection(function(){n.insertSnippetForSelection(e,t)},null,{keepOrder:!0}),e.tabstopManager&&e.tabstopManager.tabNext()},this.$getScope=function(e){var t=e.session.$mode.$id||"";t=t.split("/").pop();if(t==="html"||t==="php"){t==="php"&&!e.session.$mode.inlinePhp&&(t="html");var n=e.getCursorPosition(),r=e.session.getState(n.row);typeof r=="object"&&(r=r[0]),r.substring&&(r.substring(0,3)=="js-"?t="javascript":r.substring(0,4)=="css-"?t="css":r.substring(0,4)=="php-"&&(t="php"))}return t},this.getActiveScopes=function(e){var t=this.$getScope(e),n=[t],r=this.snippetMap;return r[t]&&r[t].includeScopes&&n.push.apply(n,r[t].includeScopes),n.push("_"),n},this.expandWithTab=function(e,t){var n=this,r=e.forEachSelection(function(){return n.expandSnippetForSelection(e,t)},null,{keepOrder:!0});return r&&e.tabstopManager&&e.tabstopManager.tabNext(),r},this.expandSnippetForSelection=function(e,t){var n=e.getCursorPosition(),r=e.session.getLine(n.row),i=r.substring(0,n.column),s=r.substr(n.column),o=this.snippetMap,u;return this.getActiveScopes(e).some(function(e){var t=o[e];return t&&(u=this.findMatchingSnippet(t,i,s)),!!u},this),u?t&&t.dryRun?!0:(e.session.doc.removeInLine(n.row,n.column-u.replaceBefore.length,n.column+u.replaceAfter.length),this.variables.M__=u.matchBefore,this.variables.T__=u.matchAfter,this.insertSnippetForSelection(e,u.content),this.variables.M__=this.variables.T__=null,!0):!1},this.findMatchingSnippet=function(e,t,n){for(var r=e.length;r--;){var i=e[r];if(i.startRe&&!i.startRe.test(t))continue;if(i.endRe&&!i.endRe.test(n))continue;if(!i.startRe&&!i.endRe)continue;return i.matchBefore=i.startRe?i.startRe.exec(t):[""],i.matchAfter=i.endRe?i.endRe.exec(n):[""],i.replaceBefore=i.triggerRe?i.triggerRe.exec(t)[0]:"",i.replaceAfter=i.endTriggerRe?i.endTriggerRe.exec(n)[0]:"",i}},this.snippetMap={},this.snippetNameMap={},this.register=function(e,t){function o(e){return e&&!/^\^?\(.*\)\$?$|^\\b$/.test(e)&&(e="(?:"+e+")"),e||""}function u(e,t,n){return e=o(e),t=o(t),n?(e=t+e,e&&e[e.length-1]!="$"&&(e+="$")):(e+=t,e&&e[0]!="^"&&(e="^"+e)),new RegExp(e)}function a(e){e.scope||(e.scope=t||"_"),t=e.scope,n[t]||(n[t]=[],r[t]={});var o=r[t];if(e.name){var a=o[e.name];a&&i.unregister(a),o[e.name]=e}n[t].push(e),e.tabTrigger&&!e.trigger&&(!e.guard&&/^\w/.test(e.tabTrigger)&&(e.guard="\\b"),e.trigger=s.escapeRegExp(e.tabTrigger)),e.startRe=u(e.trigger,e.guard,!0),e.triggerRe=new RegExp(e.trigger,"",!0),e.endRe=u(e.endTrigger,e.endGuard,!0),e.endTriggerRe=new RegExp(e.endTrigger,"",!0)}var n=this.snippetMap,r=this.snippetNameMap,i=this;e||(e=[]),e&&e.content?a(e):Array.isArray(e)&&e.forEach(a),this._signal("registerSnippets",{scope:t})},this.unregister=function(e,t){function i(e){var i=r[e.scope||t];if(i&&i[e.name]){delete i[e.name];var s=n[e.scope||t],o=s&&s.indexOf(e);o>=0&&s.splice(o,1)}}var n=this.snippetMap,r=this.snippetNameMap;e.content?i(e):Array.isArray(e)&&e.forEach(i)},this.parseSnippetFile=function(e){e=e.replace(/\r/g,"");var t=[],n={},r=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm,i;while(i=r.exec(e)){if(i[1])try{n=JSON.parse(i[1]),t.push(n)}catch(s){}if(i[4])n.content=i[4].replace(/^\t/gm,""),t.push(n),n={};else{var o=i[2],u=i[3];if(o=="regex"){var a=/\/((?:[^\/\\]|\\.)*)|$/g;n.guard=a.exec(u)[1],n.trigger=a.exec(u)[1],n.endTrigger=a.exec(u)[1],n.endGuard=a.exec(u)[1]}else o=="snippet"?(n.tabTrigger=u.match(/^\S*/)[0],n.name||(n.name=u)):n[o]=u}}return t},this.getSnippetByName=function(e,t){var n=this.snippetNameMap,r;return this.getActiveScopes(t).some(function(t){var i=n[t];return i&&(r=i[e]),!!r},this),r}}).call(c.prototype);var h=function(e){if(e.tabstopManager)return e.tabstopManager;e.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=s.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(e)};(function(){this.attach=function(e){this.index=0,this.ranges=[],this.tabstops=[],this.$openTabstops=null,this.selectedTabstop=null,this.editor=e,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},this.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges=null,this.tabstops=null,this.selectedTabstop=null,this.editor.removeListener("change",this.$onChange),this.editor.removeListener("changeSelection",this.$onChangeSelection),this.editor.removeListener("changeSession",this.$onChangeSession),this.editor.commands.removeListener("afterExec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.editor=null},this.onChange=function(e){var t=e.data.range,n=e.data.action[0]=="r",r=t.start,i=t.end,s=r.row,o=i.row,u=o-s,a=i.column-r.column;n&&(u=-u,a=-a);if(!this.$inChange&&n){var f=this.selectedTabstop,c=f&&!f.some(function(e){return l(e.start,r)<=0&&l(e.end,i)>=0});if(c)return this.detach()}var h=this.ranges;for(var p=0;p<h.length;p++){var d=h[p];if(d.end.row<r.row)continue;if(n&&l(r,d.start)<0&&l(i,d.end)>0){this.removeRange(d),p--;continue}d.start.row==s&&d.start.column>r.column&&(d.start.column+=a),d.end.row==s&&d.end.column>=r.column&&(d.end.column+=a),d.start.row>=s&&(d.start.row+=u),d.end.row>=s&&(d.end.row+=u),l(d.start,d.end)>0&&this.removeRange(d)}h.length||this.detach()},this.updateLinkedFields=function(){var e=this.selectedTabstop;if(!e||!e.hasLinkedRanges)return;this.$inChange=!0;var n=this.editor.session,r=n.getTextRange(e.firstNonLinked);for(var i=e.length;i--;){var s=e[i];if(!s.linked)continue;var o=t.snippetManager.tmStrFormat(r,s.original);n.replace(s,o)}this.$inChange=!1},this.onAfterExec=function(e){e.command&&!e.command.readOnly&&this.updateLinkedFields()},this.onChangeSelection=function(){if(!this.editor)return;var e=this.editor.selection.lead,t=this.editor.selection.anchor,n=this.editor.selection.isEmpty();for(var r=this.ranges.length;r--;){if(this.ranges[r].linked)continue;var i=this.ranges[r].contains(e.row,e.column),s=n||this.ranges[r].contains(t.row,t.column);if(i&&s)return}this.detach()},this.onChangeSession=function(){this.detach()},this.tabNext=function(e){var t=this.tabstops.length,n=this.index+(e||1);n=Math.min(Math.max(n,1),t),n==t&&(n=0),this.selectTabstop(n),n===0&&this.detach()},this.selectTabstop=function(e){this.$openTabstops=null;var t=this.tabstops[this.index];t&&this.addTabstopMarkers(t),this.index=e,t=this.tabstops[this.index];if(!t||!t.length)return;this.selectedTabstop=t;if(!this.editor.inVirtualSelectionMode){var n=this.editor.multiSelect;n.toSingleRange(t.firstNonLinked.clone());for(var r=t.length;r--;){if(t.hasLinkedRanges&&t[r].linked)continue;n.addRange(t[r].clone(),!0)}n.ranges[0]&&n.addRange(n.ranges[0].clone())}else this.editor.selection.setRange(t.firstNonLinked);this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},this.addTabstops=function(e,t,n){this.$openTabstops||(this.$openTabstops=[]);if(!e[0]){var r=o.fromPoints(n,n);v(r.start,t),v(r.end,t),e[0]=[r],e[0].index=0}var i=this.index,s=[i+1,0],u=this.ranges;e.forEach(function(e,n){var r=this.$openTabstops[n]||e;for(var i=e.length;i--;){var a=e[i],f=o.fromPoints(a.start,a.end||a.start);d(f.start,t),d(f.end,t),f.original=a,f.tabstop=r,u.push(f),r!=e?r.unshift(f):r[i]=f,a.fmtString?(f.linked=!0,r.hasLinkedRanges=!0):r.firstNonLinked||(r.firstNonLinked=f)}r.firstNonLinked||(r.hasLinkedRanges=!1),r===e&&(s.push(r),this.$openTabstops[n]=r),this.addTabstopMarkers(r)},this),s.length>2&&(this.tabstops.length&&s.push(s.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,s))},this.addTabstopMarkers=function(e){var t=this.editor.session;e.forEach(function(e){e.markerId||(e.markerId=t.addMarker(e,"ace_snippet-marker","text"))})},this.removeTabstopMarkers=function(e){var t=this.editor.session;e.forEach(function(e){t.removeMarker(e.markerId),e.markerId=null})},this.removeRange=function(e){var t=e.tabstop.indexOf(e);e.tabstop.splice(t,1),t=this.ranges.indexOf(e),this.ranges.splice(t,1),this.editor.session.removeMarker(e.markerId),e.tabstop.length||(t=this.tabstops.indexOf(e.tabstop),t!=-1&&this.tabstops.splice(t,1),this.tabstops.length||this.detach())},this.keyboardHandler=new a,this.keyboardHandler.bindKeys({Tab:function(e){if(t.snippetManager&&t.snippetManager.expandWithTab(e))return;e.tabstopManager.tabNext(1)},"Shift-Tab":function(e){e.tabstopManager.tabNext(-1)},Esc:function(e){e.tabstopManager.detach()},Return:function(e){return!1}})}).call(h.prototype);var p={};p.onChange=u.prototype.onChange,p.setPosition=function(e,t){this.pos.row=e,this.pos.column=t},p.update=function(e,t,n){this.$insertRight=n,this.pos=e,this.onChange(t)};var d=function(e,t){e.row==0&&(e.column+=t.column),e.row+=t.row},v=function(e,t){e.row==t.row&&(e.column-=t.column),e.row-=t.row};e("./lib/dom").importCssString(".ace_snippet-marker { -moz-box-sizing: border-box; box-sizing: border-box; background: rgba(194, 193, 208, 0.09); border: 1px dotted rgba(211, 208, 235, 0.62); position: absolute;}"),t.snippetManager=new c;var m=e("./editor").Editor;(function(){this.insertSnippet=function(e,n){return t.snippetManager.insertSnippet(this,e,n)},this.expandSnippet=function(e){return t.snippetManager.expandWithTab(this,e)}}).call(m.prototype)}),ace.define("ace/autocomplete/popup",["require","exports","module","ace/edit_session","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../edit_session").EditSession,i=e("../virtual_renderer").VirtualRenderer,s=e("../editor").Editor,o=e("../range").Range,u=e("../lib/event"),a=e("../lib/lang"),f=e("../lib/dom"),l=function(e){var t=new i(e);t.$maxLines=4;var n=new s(t);return n.setHighlightActiveLine(!1),n.setShowPrintMargin(!1),n.renderer.setShowGutter(!1),n.renderer.setHighlightGutterLine(!1),n.$mouseHandler.$focusWaitTimout=0,n.$highlightTagPending=!0,n},c=function(e){var t=f.createElement("div"),n=new l(t);e&&e.appendChild(t),t.style.display="none",n.renderer.content.style.cursor="default",n.renderer.setStyle("ace_autocomplete"),n.setOption("displayIndentGuides",!1),n.setOption("dragDelay",150);var r=function(){};n.focus=r,n.$isFocused=!0,n.renderer.$cursorLayer.restartTimer=r,n.renderer.$cursorLayer.element.style.opacity=0,n.renderer.$maxLines=8,n.renderer.$keepTextAreaAtCursor=!1,n.setHighlightActiveLine(!1),n.session.highlight(""),n.session.$searchHighlight.clazz="ace_highlight-marker",n.on("mousedown",function(e){var t=e.getDocumentPosition();n.selection.moveToPosition(t),c.start.row=c.end.row=t.row,e.stop()});var i,s=new o(-1,0,-1,Infinity),c=new o(-1,0,-1,Infinity);c.id=n.session.addMarker(c,"ace_active-line","fullLine"),n.setSelectOnHover=function(e){e?s.id&&(n.session.removeMarker(s.id),s.id=null):s.id=n.session.addMarker(s,"ace_line-hover","fullLine")},n.setSelectOnHover(!1),n.on("mousemove",function(e){if(!i){i=e;return}if(i.x==e.x&&i.y==e.y)return;i=e,i.scrollTop=n.renderer.scrollTop;var t=i.getDocumentPosition().row;s.start.row!=t&&(s.id||n.setRow(t),p(t))}),n.renderer.on("beforeRender",function(){if(i&&s.start.row!=-1){i.$pos=null;var e=i.getDocumentPosition().row;s.id||n.setRow(e),p(e,!0)}}),n.renderer.on("afterRender",function(){var e=n.getRow(),t=n.renderer.$textLayer,r=t.element.childNodes[e-t.config.firstRow];if(r==t.selectedNode)return;t.selectedNode&&f.removeCssClass(t.selectedNode,"ace_selected"),t.selectedNode=r,r&&f.addCssClass(r,"ace_selected")});var h=function(){p(-1)},p=function(e,t){e!==s.start.row&&(s.start.row=s.end.row=e,t||n.session._emit("changeBackMarker"),n._emit("changeHoverMarker"))};n.getHoveredRow=function(){return s.start.row},u.addListener(n.container,"mouseout",h),n.on("hide",h),n.on("changeSelection",h),n.session.doc.getLength=function(){return n.data.length},n.session.doc.getLine=function(e){var t=n.data[e];return typeof t=="string"?t:t&&t.value||""};var d=n.session.bgTokenizer;return d.$tokenizeRow=function(e){var t=n.data[e],r=[];if(!t)return r;typeof t=="string"&&(t={value:t}),t.caption||(t.caption=t.value||t.name);var i=-1,s,o;for(var u=0;u<t.caption.length;u++)o=t.caption[u],s=t.matchMask&1<<u?1:0,i!==s?(r.push({type:t.className||""+(s?"completion-highlight":""),value:o}),i=s):r[r.length-1].value+=o;if(t.meta){var a=n.renderer.$size.scrollerWidth/n.renderer.layerConfig.characterWidth;t.meta.length+t.caption.length<a-2&&r.push({type:"rightAlignedText",value:t.meta})}return r},d.$updateOnChange=r,d.start=r,n.session.$computeWidth=function(){return this.screenWidth=0},n.$blockScrolling=Infinity,n.isOpen=!1,n.isTopdown=!1,n.data=[],n.setData=function(e){n.data=e||[],n.setValue(a.stringRepeat("\n",e.length),-1),n.setRow(0)},n.getData=function(e){return n.data[e]},n.getRow=function(){return c.start.row},n.setRow=function(e){e=Math.max(-1,Math.min(this.data.length,e)),c.start.row!=e&&(n.selection.clearSelection(),c.start.row=c.end.row=e||0,n.session._emit("changeBackMarker"),n.moveCursorTo(e||0,0),n.isOpen&&n._signal("select"))},n.on("changeSelection",function(){n.isOpen&&n.setRow(n.selection.lead.row),n.renderer.scrollCursorIntoView()}),n.hide=function(){this.container.style.display="none",this._signal("hide"),n.isOpen=!1},n.show=function(e,t,r){var s=this.container,o=window.innerHeight,u=window.innerWidth,a=this.renderer,f=a.$maxLines*t*1.4,l=e.top+this.$borderSize;l+f>o-t&&!r?(s.style.top="",s.style.bottom=o-l+"px",n.isTopdown=!1):(l+=t,s.style.top=l+"px",s.style.bottom="",n.isTopdown=!0),s.style.display="",this.renderer.$textLayer.checkForSizeChanges();var c=e.left;c+s.offsetWidth>u&&(c=u-s.offsetWidth),s.style.left=c+"px",this._signal("show"),i=null,n.isOpen=!0},n.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},n.$imageSize=0,n.$borderSize=1,n};f.importCssString(".ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line { background-color: #CAD6FA; z-index: 1;}.ace_editor.ace_autocomplete .ace_line-hover { border: 1px solid #abbffe; margin-top: -1px; background: rgba(233,233,253,0.4);}.ace_editor.ace_autocomplete .ace_line-hover { position: absolute; z-index: 2;}.ace_editor.ace_autocomplete .ace_scroller { background: none; border: none; box-shadow: none;}.ace_rightAlignedText { color: gray; display: inline-block; position: absolute; right: 4px; text-align: right; z-index: -1;}.ace_editor.ace_autocomplete .ace_completion-highlight{ color: #000; text-shadow: 0 0 0.01em;}.ace_editor.ace_autocomplete { width: 280px; z-index: 200000; background: #fbfbfb; color: #444; border: 1px lightgray solid; position: fixed; box-shadow: 2px 3px 5px rgba(0,0,0,.2); line-height: 1.4;}"),t.AcePopup=c}),ace.define("ace/autocomplete/util",["require","exports","module"],function(e,t,n){"use strict";t.parForEach=function(e,t,n){var r=0,i=e.length;i===0&&n();for(var s=0;s<i;s++)t(e[s],function(e,t){r++,r===i&&n(e,t)})};var r=/[a-zA-Z_0-9\$\-\u00A2-\uFFFF]/;t.retrievePrecedingIdentifier=function(e,t,n){n=n||r;var i=[];for(var s=t-1;s>=0;s--){if(!n.test(e[s]))break;i.push(e[s])}return i.reverse().join("")},t.retrieveFollowingIdentifier=function(e,t,n){n=n||r;var i=[];for(var s=t;s<e.length;s++){if(!n.test(e[s]))break;i.push(e[s])}return i}}),ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/event","ace/lib/lang","ace/lib/dom","ace/snippets"],function(e,t,n){"use strict";var r=e("./keyboard/hash_handler").HashHandler,i=e("./autocomplete/popup").AcePopup,s=e("./autocomplete/util"),o=e("./lib/event"),u=e("./lib/lang"),a=e("./lib/dom"),f=e("./snippets").snippetManager,l=function(){this.autoInsert=!0,this.autoSelect=!0,this.exactMatch=!1,this.keyboardHandler=new r,this.keyboardHandler.bindKeys(this.commands),this.blurListener=this.blurListener.bind(this),this.changeListener=this.changeListener.bind(this),this.mousedownListener=this.mousedownListener.bind(this),this.mousewheelListener=this.mousewheelListener.bind(this),this.changeTimer=u.delayedCall(function(){this.updateCompletions(!0)}.bind(this)),this.tooltipTimer=u.delayedCall(this.updateDocTooltip.bind(this),50)};(function(){this.gatherCompletionsId=0,this.$init=function(){return this.popup=new i(document.body||document.documentElement),this.popup.on("click",function(e){this.insertMatch(),e.stop()}.bind(this)),this.popup.focus=this.editor.focus.bind(this.editor),this.popup.on("show",this.tooltipTimer.bind(null,null)),this.popup.on("select",this.tooltipTimer.bind(null,null)),this.popup.on("changeHoverMarker",this.tooltipTimer.bind(null,null)),this.popup},this.getPopup=function(){return this.popup||this.$init()},this.openPopup=function(e,t,n){this.popup||this.$init(),this.popup.setData(this.completions.filtered);var r=e.renderer;this.popup.setRow(this.autoSelect?0:-1);if(!n){this.popup.setTheme(e.getTheme()),this.popup.setFontSize(e.getFontSize());var i=r.layerConfig.lineHeight,s=r.$cursorLayer.getPixelPosition(this.base,!0);s.left-=this.popup.getTextLeftOffset();var o=e.container.getBoundingClientRect();s.top+=o.top-r.layerConfig.offset,s.left+=o.left-e.renderer.scrollLeft,s.left+=r.$gutterLayer.gutterWidth,this.popup.show(s,i)}else n&&!t&&this.detach()},this.detach=function(){this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.off("changeSelection",this.changeListener),this.editor.off("blur",this.blurListener),this.editor.off("mousedown",this.mousedownListener),this.editor.off("mousewheel",this.mousewheelListener),this.changeTimer.cancel(),this.hideDocTooltip(),this.popup&&this.popup.isOpen&&(this.gatherCompletionsId+=1,this.popup.hide()),this.base&&this.base.detach(),this.activated=!1,this.completions=this.base=null},this.changeListener=function(e){var t=this.editor.selection.lead;(t.row!=this.base.row||t.column<this.base.column)&&this.detach(),this.activated?this.changeTimer.schedule():this.detach()},this.blurListener=function(e){var t=document.activeElement,n=this.editor.textInput.getElement();t!=n&&t.parentNode!=this.popup.container&&t!=this.tooltipNode&&e.relatedTarget!=this.tooltipNode&&e.relatedTarget!=n&&this.detach()},this.mousedownListener=function(e){this.detach()},this.mousewheelListener=function(e){this.detach()},this.goTo=function(e){var t=this.popup.getRow(),n=this.popup.session.getLength()-1;switch(e){case"up":t=t<=0?n:t-1;break;case"down":t=t>=n?-1:t+1;break;case"start":t=0;break;case"end":t=n}this.popup.setRow(t)},this.insertMatch=function(e){e||(e=this.popup.getData(this.popup.getRow()));if(!e)return!1;if(e.completer&&e.completer.insertMatch)e.completer.insertMatch(this.editor,e);else{if(this.completions.filterText){var t=this.editor.selection.getAllRanges();for(var n=0,r;r=t[n];n++)r.start.column-=this.completions.filterText.length,this.editor.session.remove(r)}e.snippet?f.insertSnippet(this.editor,e.snippet):this.editor.execCommand("insertstring",e.value||e)}this.detach()},this.commands={Up:function(e){e.completer.goTo("up")},Down:function(e){e.completer.goTo("down")},"Ctrl-Up|Ctrl-Home":function(e){e.completer.goTo("start")},"Ctrl-Down|Ctrl-End":function(e){e.completer.goTo("end")},Esc:function(e){e.completer.detach()},Space:function(e){e.completer.detach(),e.insert(" ")},Return:function(e){return e.completer.insertMatch()},"Shift-Return":function(e){e.completer.insertMatch(!0)},Tab:function(e){var t=e.completer.insertMatch();if(!!t||!!e.tabstopManager)return t;e.completer.goTo("down")},PageUp:function(e){e.completer.popup.gotoPageUp()},PageDown:function(e){e.completer.popup.gotoPageDown()}},this.gatherCompletions=function(e,t){var n=e.getSession(),r=e.getCursorPosition(),i=n.getLine(r.row),o=s.retrievePrecedingIdentifier(i,r.column);this.base=n.doc.createAnchor(r.row,r.column-o.length),this.base.$insertRight=!0;var u=[],a=e.completers.length;return e.completers.forEach(function(i,f){i.getCompletions(e,n,r,o,function(r,i){r||(u=u.concat(i));var o=e.getCursorPosition(),f=n.getLine(o.row);t(null,{prefix:s.retrievePrecedingIdentifier(f,o.column,i[0]&&i[0].identifierRegex),matches:u,finished:--a===0})})}),!0},this.showPopup=function(e){this.editor&&this.detach(),this.activated=!0,this.editor=e,e.completer!=this&&(e.completer&&e.completer.detach(),e.completer=this),e.keyBinding.addKeyboardHandler(this.keyboardHandler),e.on("changeSelection",this.changeListener),e.on("blur",this.blurListener),e.on("mousedown",this.mousedownListener),e.on("mousewheel",this.mousewheelListener),this.updateCompletions()},this.updateCompletions=function(e){if(e&&this.base&&this.completions){var t=this.editor.getCursorPosition(),n=this.editor.session.getTextRange({start:this.base,end:t});if(n==this.completions.filterText)return;this.completions.setFilter(n);if(!this.completions.filtered.length)return this.detach();if(this.completions.filtered.length==1&&this.completions.filtered[0].value==n&&!this.completions.filtered[0].snippet)return this.detach();this.openPopup(this.editor,n,e);return}var r=this.gatherCompletionsId;this.gatherCompletions(this.editor,function(t,n){var i=function(){if(!n.finished)return;return this.detach()}.bind(this),s=n.prefix,o=n&&n.matches;if(!o||!o.length)return i();if(s.indexOf(n.prefix)!==0||r!=this.gatherCompletionsId)return;this.completions=new c(o),this.exactMatch&&(this.completions.exactMatch=!0),this.completions.setFilter(s);var u=this.completions.filtered;if(!u.length)return i();if(u.length==1&&u[0].value==s&&!u[0].snippet)return i();if(this.autoInsert&&u.length==1&&n.finished)return this.insertMatch(u[0]);this.openPopup(this.editor,s,e)}.bind(this))},this.cancelContextMenu=function(){this.editor.$mouseHandler.cancelContextMenu()},this.updateDocTooltip=function(){var e=this.popup,t=e.data,n=t&&(t[e.getHoveredRow()]||t[e.getRow()]),r=null;if(!n||!this.editor||!this.popup.isOpen)return this.hideDocTooltip();this.editor.completers.some(function(e){return e.getDocTooltip&&(r=e.getDocTooltip(n)),r}),r||(r=n),typeof r=="string"&&(r={docText:r});if(!r||!r.docHTML&&!r.docText)return this.hideDocTooltip();this.showDocTooltip(r)},this.showDocTooltip=function(e){this.tooltipNode||(this.tooltipNode=a.createElement("div"),this.tooltipNode.className="ace_tooltip ace_doc-tooltip",this.tooltipNode.style.margin=0,this.tooltipNode.style.pointerEvents="auto",this.tooltipNode.tabIndex=-1,this.tooltipNode.onblur=this.blurListener.bind(this));var t=this.tooltipNode;e.docHTML?t.innerHTML=e.docHTML:e.docText&&(t.textContent=e.docText),t.parentNode||document.body.appendChild(t);var n=this.popup,r=n.container.getBoundingClientRect();t.style.top=n.container.style.top,t.style.bottom=n.container.style.bottom,window.innerWidth-r.right<320?(t.style.right=window.innerWidth-r.left+"px",t.style.left=""):(t.style.left=r.right+1+"px",t.style.right=""),t.style.display="block"},this.hideDocTooltip=function(){this.tooltipTimer.cancel();if(!this.tooltipNode)return;var e=this.tooltipNode;!this.editor.isFocused()&&document.activeElement==e&&this.editor.focus(),this.tooltipNode=null,e.parentNode&&e.parentNode.removeChild(e)}}).call(l.prototype),l.startCommand={name:"startAutocomplete",exec:function(e){e.completer||(e.completer=new l),e.completer.autoInsert=e.completer.autoSelect=!0,e.completer.showPopup(e),e.completer.cancelContextMenu()},bindKey:"Ctrl-Space|Ctrl-Shift-Space|Alt-Space"};var c=function(e,t,n){this.all=e,this.filtered=e,this.filterText=t||"",this.exactMatch=!1};(function(){this.setFilter=function(e){if(e.length>this.filterText&&e.lastIndexOf(this.filterText,0)===0)var t=this.filtered;else var t=this.all;this.filterText=e,t=this.filterCompletions(t,this.filterText),t=t.sort(function(e,t){return t.exactMatch-e.exactMatch||t.score-e.score});var n=null;t=t.filter(function(e){var t=e.snippet||e.caption||e.value;return t===n?!1:(n=t,!0)}),this.filtered=t},this.filterCompletions=function(e,t){var n=[],r=t.toUpperCase(),i=t.toLowerCase();e:for(var s=0,o;o=e[s];s++){var u=o.value||o.caption||o.snippet;if(!u)continue;var a=-1,f=0,l=0,c,h;if(this.exactMatch){if(t!==u.substr(0,t.length))continue e}else for(var p=0;p<t.length;p++){var d=u.indexOf(i[p],a+1),v=u.indexOf(r[p],a+1);c=d>=0?v<0||d<v?d:v:v;if(c<0)continue e;h=c-a-1,h>0&&(a===-1&&(l+=10),l+=h),f|=1<<c,a=c}o.matchMask=f,o.exactMatch=l?0:1,o.score=(o.score||0)-l,n.push(o)}return n}}).call(c.prototype),t.Autocomplete=l,t.FilteredList=c}),ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"],function(e,t,n){function s(e,t){var n=e.getTextRange(r.fromPoints({row:0,column:0},t));return n.split(i).length-1}function o(e,t){var n=s(e,t),r=e.getValue().split(i),o=Object.create(null),u=r[n];return r.forEach(function(e,t){if(!e||e===u)return;var i=Math.abs(n-t),s=r.length-i;o[e]?o[e]=Math.max(s,o[e]):o[e]=s}),o}var r=e("../range").Range,i=/[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;t.getCompletions=function(e,t,n,r,i){var s=o(t,n,r),u=Object.keys(s);i(null,u.map(function(e){return{caption:e,value:e,score:s[e],meta:"local"}}))}}),ace.define("ace/ext/language_tools",["require","exports","module","ace/snippets","ace/autocomplete","ace/config","ace/lib/lang","ace/autocomplete/util","ace/autocomplete/text_completer","ace/editor","ace/config"],function(e,t,n){"use strict";function m(e){var t=e.getCursorPosition(),n=e.session.getLine(t.row),r=u.retrievePrecedingIdentifier(n,t.column);return e.completers.forEach(function(e){e.identifierRegexps&&e.identifierRegexps.forEach(function(e){!r&&e&&(r=u.retrievePrecedingIdentifier(n,t.column,e))})}),r}var r=e("../snippets").snippetManager,i=e("../autocomplete").Autocomplete,s=e("../config"),o=e("../lib/lang"),u=e("../autocomplete/util"),a=e("../autocomplete/text_completer"),f={getCompletions:function(e,t,n,r,i){if(t.$mode.completer)return t.$mode.completer.getCompletions(e,t,n,r,i);var s=e.session.getState(n.row),o=t.$mode.getCompletions(s,t,n,r);i(null,o)}},l={getCompletions:function(e,t,n,i,s){var o=r.snippetMap,u=[];r.getActiveScopes(e).forEach(function(e){var t=o[e]||[];for(var n=t.length;n--;){var r=t[n],i=r.name||r.tabTrigger;if(!i)continue;u.push({caption:i,snippet:r.content,meta:r.tabTrigger&&!r.name?r.tabTrigger+"\u21e5 ":"snippet",type:"snippet"})}},this),s(null,u)},getDocTooltip:function(e){e.type=="snippet"&&!e.docHTML&&(e.docHTML=["<b>",o.escapeHTML(e.caption),"</b>","<hr></hr>",o.escapeHTML(e.snippet)].join(""))}},c=[l,a,f];t.setCompleters=function(e){c=e||[]},t.addCompleter=function(e){c.push(e)},t.textCompleter=a,t.keyWordCompleter=f,t.snippetCompleter=l;var h={name:"expandSnippet",exec:function(e){return r.expandWithTab(e)},bindKey:"Tab"},p=function(e,t){d(t.session.$mode)},d=function(e){var t=e.$id;r.files||(r.files={}),v(t),e.modes&&e.modes.forEach(d)},v=function(e){if(!e||r.files[e])return;var t=e.replace("mode","snippets");r.files[e]={},s.loadModule(t,function(t){t&&(r.files[e]=t,!t.snippets&&t.snippetText&&(t.snippets=r.parseSnippetFile(t.snippetText)),r.register(t.snippets||[],t.scope),t.includeScopes&&(r.snippetMap[t.scope].includeScopes=t.includeScopes,t.includeScopes.forEach(function(e){v("ace/mode/"+e)})))})},g=function(e){var t=e.editor,n=e.args||"",r=t.completer&&t.completer.activated;if(e.command.name==="backspace")r&&!m(t)&&t.completer.detach();else if(e.command.name==="insertstring"){var s=m(t);s&&!r&&(t.completer||(t.completer=new i),t.completer.autoSelect=!1,t.completer.autoInsert=!1,t.completer.showPopup(t))}},y=e("../editor").Editor;e("../config").defineOptions(y.prototype,"editor",{enableBasicAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:c),this.commands.addCommand(i.startCommand)):this.commands.removeCommand(i.startCommand)},value:!1},enableLiveAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:c),this.commands.on("afterExec",g)):this.commands.removeListener("afterExec",g)},value:!1},enableSnippets:{set:function(e){e?(this.commands.addCommand(h),this.on("changeMode",p),p(null,this)):(this.commands.removeCommand(h),this.off("changeMode",p))},value:!1}})});
2
- (function() {
3
- ace.require(["ace/ext/language_tools"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-linking.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/linking",["require","exports","module","ace/editor","ace/config"],function(e,t,n){function i(e){var t=e.editor,n=e.getAccelKey();if(n){var t=e.editor,r=e.getDocumentPosition(),i=t.session,s=i.getTokenAt(r.row,r.column);t._emit("linkHover",{position:r,token:s})}}function s(e){var t=e.getAccelKey(),n=e.getButton();if(n==0&&t){var r=e.editor,i=e.getDocumentPosition(),s=r.session,o=s.getTokenAt(i.row,i.column);r._emit("linkClick",{position:i,token:o})}}var r=e("ace/editor").Editor;e("../config").defineOptions(r.prototype,"editor",{enableLinking:{set:function(e){e?(this.on("click",s),this.on("mousemove",i)):(this.off("click",s),this.off("mousemove",i))},value:!1}})});
2
- (function() {
3
- ace.require(["ace/ext/linking"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-modelist.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/modelist",["require","exports","module"],function(e,t,n){"use strict";function i(e){var t=a.text,n=e.split(/[\/\\]/).pop();for(var i=0;i<r.length;i++)if(r[i].supportsFile(n)){t=r[i];break}return t}var r=[],s=function(e,t,n){this.name=e,this.caption=t,this.mode="ace/mode/"+e,this.extensions=n;if(/\^/.test(n))var r=n.replace(/\|(\^)?/g,function(e,t){return"$|"+(t?"^":"^.*\\.")})+"$";else var r="^.*\\.("+n+")$";this.extRe=new RegExp(r,"gi")};s.prototype.supportsFile=function(e){return e.match(this.extRe)};var o={ABAP:["abap"],ActionScript:["as"],ADA:["ada|adb"],Apache_Conf:["^htaccess|^htgroups|^htpasswd|^conf|htaccess|htgroups|htpasswd"],AsciiDoc:["asciidoc"],Assembly_x86:["asm"],AutoHotKey:["ahk"],BatchFile:["bat|cmd"],C9Search:["c9search_results"],C_Cpp:["cpp|c|cc|cxx|h|hh|hpp"],Cirru:["cirru|cr"],Clojure:["clj|cljs"],Cobol:["CBL|COB"],coffee:["coffee|cf|cson|^Cakefile"],ColdFusion:["cfm"],CSharp:["cs"],CSS:["css"],Curly:["curly"],D:["d|di"],Dart:["dart"],Diff:["diff|patch"],Dockerfile:["^Dockerfile"],Dot:["dot"],Dummy:["dummy"],DummySyntax:["dummy"],Eiffel:["e"],EJS:["ejs"],Elixir:["ex|exs"],Elm:["elm"],Erlang:["erl|hrl"],Forth:["frt|fs|ldr"],FTL:["ftl"],Gcode:["gcode"],Gherkin:["feature"],Gitignore:["^.gitignore"],Glsl:["glsl|frag|vert"],golang:["go"],Groovy:["groovy"],HAML:["haml"],Handlebars:["hbs|handlebars|tpl|mustache"],Haskell:["hs"],haXe:["hx"],HTML:["html|htm|xhtml"],HTML_Ruby:["erb|rhtml|html.erb"],INI:["ini|conf|cfg|prefs"],Io:["io"],Jack:["jack"],Jade:["jade"],Java:["java"],JavaScript:["js|jsm"],JSON:["json"],JSONiq:["jq"],JSP:["jsp"],JSX:["jsx"],Julia:["jl"],LaTeX:["tex|latex|ltx|bib"],LESS:["less"],Liquid:["liquid"],Lisp:["lisp"],LiveScript:["ls"],LogiQL:["logic|lql"],LSL:["lsl"],Lua:["lua"],LuaPage:["lp"],Lucene:["lucene"],Makefile:["^Makefile|^GNUmakefile|^makefile|^OCamlMakefile|make"],Markdown:["md|markdown"],Mask:["mask"],MATLAB:["matlab"],MEL:["mel"],MUSHCode:["mc|mush"],MySQL:["mysql"],Nix:["nix"],ObjectiveC:["m|mm"],OCaml:["ml|mli"],Pascal:["pas|p"],Perl:["pl|pm"],pgSQL:["pgsql"],PHP:["php|phtml"],Powershell:["ps1"],Praat:["praat|praatscript|psc|proc"],Prolog:["plg|prolog"],Properties:["properties"],Protobuf:["proto"],Python:["py"],R:["r"],RDoc:["Rd"],RHTML:["Rhtml"],Ruby:["rb|ru|gemspec|rake|^Guardfile|^Rakefile|^Gemfile"],Rust:["rs"],SASS:["sass"],SCAD:["scad"],Scala:["scala"],Scheme:["scm|rkt"],SCSS:["scss"],SH:["sh|bash|^.bashrc"],SJS:["sjs"],Smarty:["smarty|tpl"],snippets:["snippets"],Soy_Template:["soy"],Space:["space"],SQL:["sql"],Stylus:["styl|stylus"],SVG:["svg"],Tcl:["tcl"],Tex:["tex"],Text:["txt"],Textile:["textile"],Toml:["toml"],Twig:["twig"],Typescript:["ts|typescript|str"],Vala:["vala"],VBScript:["vbs|vb"],Velocity:["vm"],Verilog:["v|vh|sv|svh"],VHDL:["vhd|vhdl"],XML:["xml|rdf|rss|wsdl|xslt|atom|mathml|mml|xul|xbl"],XQuery:["xq"],YAML:["yaml|yml"]},u={ObjectiveC:"Objective-C",CSharp:"C#",golang:"Go",C_Cpp:"C and C++",coffee:"CoffeeScript",HTML_Ruby:"HTML (Ruby)",FTL:"FreeMarker"},a={};for(var f in o){var l=o[f],c=(u[f]||f).replace(/_/g," "),h=f.toLowerCase(),p=new s(h,c,l[0]);a[h]=p,r.push(p)}n.exports={getModeForPath:i,modes:r,modesByName:a}});
2
- (function() {
3
- ace.require(["ace/ext/modelist"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-old_ie.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/searchbox",["require","exports","module","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/keyboard/hash_handler","ace/lib/keys"],function(e,t,n){"use strict";var r=e("../lib/dom"),i=e("../lib/lang"),s=e("../lib/event"),o=".ace_search {background-color: #ddd;border: 1px solid #cbcbcb;border-top: 0 none;max-width: 325px;overflow: hidden;margin: 0;padding: 4px;padding-right: 6px;padding-bottom: 0;position: absolute;top: 0px;z-index: 99;white-space: normal;}.ace_search.left {border-left: 0 none;border-radius: 0px 0px 5px 0px;left: 0;}.ace_search.right {border-radius: 0px 0px 0px 5px;border-right: 0 none;right: 0;}.ace_search_form, .ace_replace_form {border-radius: 3px;border: 1px solid #cbcbcb;float: left;margin-bottom: 4px;overflow: hidden;}.ace_search_form.ace_nomatch {outline: 1px solid red;}.ace_search_field {background-color: white;border-right: 1px solid #cbcbcb;border: 0 none;-webkit-box-sizing: border-box;-moz-box-sizing: border-box;box-sizing: border-box;float: left;height: 22px;outline: 0;padding: 0 7px;width: 214px;margin: 0;}.ace_searchbtn,.ace_replacebtn {background: #fff;border: 0 none;border-left: 1px solid #dcdcdc;cursor: pointer;float: left;height: 22px;margin: 0;padding: 0;position: relative;}.ace_searchbtn:last-child,.ace_replacebtn:last-child {border-top-right-radius: 3px;border-bottom-right-radius: 3px;}.ace_searchbtn:disabled {background: none;cursor: default;}.ace_searchbtn {background-position: 50% 50%;background-repeat: no-repeat;width: 27px;}.ace_searchbtn.prev {background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAFCAYAAAB4ka1VAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAADFJREFUeNpiSU1NZUAC/6E0I0yACYskCpsJiySKIiY0SUZk40FyTEgCjGgKwTRAgAEAQJUIPCE+qfkAAAAASUVORK5CYII=); }.ace_searchbtn.next {background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAFCAYAAAB4ka1VAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAADRJREFUeNpiTE1NZQCC/0DMyIAKwGJMUAYDEo3M/s+EpvM/mkKwCQxYjIeLMaELoLMBAgwAU7UJObTKsvAAAAAASUVORK5CYII=); }.ace_searchbtn_close {background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAcCAYAAABRVo5BAAAAZ0lEQVR42u2SUQrAMAhDvazn8OjZBilCkYVVxiis8H4CT0VrAJb4WHT3C5xU2a2IQZXJjiQIRMdkEoJ5Q2yMqpfDIo+XY4k6h+YXOyKqTIj5REaxloNAd0xiKmAtsTHqW8sR2W5f7gCu5nWFUpVjZwAAAABJRU5ErkJggg==) no-repeat 50% 0;border-radius: 50%;border: 0 none;color: #656565;cursor: pointer;float: right;font: 16px/16px Arial;height: 14px;margin: 5px 1px 9px 5px;padding: 0;text-align: center;width: 14px;}.ace_searchbtn_close:hover {background-color: #656565;background-position: 50% 100%;color: white;}.ace_replacebtn.prev {width: 54px}.ace_replacebtn.next {width: 27px}.ace_button {margin-left: 2px;cursor: pointer;-webkit-user-select: none;-moz-user-select: none;-o-user-select: none;-ms-user-select: none;user-select: none;overflow: hidden;opacity: 0.7;border: 1px solid rgba(100,100,100,0.23);padding: 1px;-moz-box-sizing: border-box;box-sizing: border-box;color: black;}.ace_button:hover {background-color: #eee;opacity:1;}.ace_button:active {background-color: #ddd;}.ace_button.checked {border-color: #3399ff;opacity:1;}.ace_search_options{margin-bottom: 3px;text-align: right;-webkit-user-select: none;-moz-user-select: none;-o-user-select: none;-ms-user-select: none;user-select: none;}",u=e("../keyboard/hash_handler").HashHandler,a=e("../lib/keys");r.importCssString(o,"ace_searchbox");var f='<div class="ace_search right"> <button type="button" action="hide" class="ace_searchbtn_close"></button> <div class="ace_search_form"> <input class="ace_search_field" placeholder="Search for" spellcheck="false"></input> <button type="button" action="findNext" class="ace_searchbtn next"></button> <button type="button" action="findPrev" class="ace_searchbtn prev"></button> <button type="button" action="findAll" class="ace_searchbtn" title="Alt-Enter">All</button> </div> <div class="ace_replace_form"> <input class="ace_search_field" placeholder="Replace with" spellcheck="false"></input> <button type="button" action="replaceAndFindNext" class="ace_replacebtn">Replace</button> <button type="button" action="replaceAll" class="ace_replacebtn">All</button> </div> <div class="ace_search_options"> <span action="toggleRegexpMode" class="ace_button" title="RegExp Search">.*</span> <span action="toggleCaseSensitive" class="ace_button" title="CaseSensitive Search">Aa</span> <span action="toggleWholeWords" class="ace_button" title="Whole Word Search">\\b</span> </div></div>'.replace(/>\s+/g,">"),l=function(e,t,n){var i=r.createElement("div");i.innerHTML=f,this.element=i.firstChild,this.$init(),this.setEditor(e)};(function(){this.setEditor=function(e){e.searchBox=this,e.container.appendChild(this.element),this.editor=e},this.$initElements=function(e){this.searchBox=e.querySelector(".ace_search_form"),this.replaceBox=e.querySelector(".ace_replace_form"),this.searchOptions=e.querySelector(".ace_search_options"),this.regExpOption=e.querySelector("[action=toggleRegexpMode]"),this.caseSensitiveOption=e.querySelector("[action=toggleCaseSensitive]"),this.wholeWordOption=e.querySelector("[action=toggleWholeWords]"),this.searchInput=this.searchBox.querySelector(".ace_search_field"),this.replaceInput=this.replaceBox.querySelector(".ace_search_field")},this.$init=function(){var e=this.element;this.$initElements(e);var t=this;s.addListener(e,"mousedown",function(e){setTimeout(function(){t.activeInput.focus()},0),s.stopPropagation(e)}),s.addListener(e,"click",function(e){var n=e.target||e.srcElement,r=n.getAttribute("action");r&&t[r]?t[r]():t.$searchBarKb.commands[r]&&t.$searchBarKb.commands[r].exec(t),s.stopPropagation(e)}),s.addCommandKeyListener(e,function(e,n,r){var i=a.keyCodeToString(r),o=t.$searchBarKb.findKeyCommand(n,i);o&&o.exec&&(o.exec(t),s.stopEvent(e))}),this.$onChange=i.delayedCall(function(){t.find(!1,!1)}),s.addListener(this.searchInput,"input",function(){t.$onChange.schedule(20)}),s.addListener(this.searchInput,"focus",function(){t.activeInput=t.searchInput,t.searchInput.value&&t.highlight()}),s.addListener(this.replaceInput,"focus",function(){t.activeInput=t.replaceInput,t.searchInput.value&&t.highlight()})},this.$closeSearchBarKb=new u([{bindKey:"Esc",name:"closeSearchBar",exec:function(e){e.searchBox.hide()}}]),this.$searchBarKb=new u,this.$searchBarKb.bindKeys({"Ctrl-f|Command-f|Ctrl-H|Command-Option-F":function(e){var t=e.isReplace=!e.isReplace;e.replaceBox.style.display=t?"":"none",e[t?"replaceInput":"searchInput"].focus()},"Ctrl-G|Command-G":function(e){e.findNext()},"Ctrl-Shift-G|Command-Shift-G":function(e){e.findPrev()},esc:function(e){setTimeout(function(){e.hide()})},Return:function(e){e.activeInput==e.replaceInput&&e.replace(),e.findNext()},"Shift-Return":function(e){e.activeInput==e.replaceInput&&e.replace(),e.findPrev()},"Alt-Return":function(e){e.activeInput==e.replaceInput&&e.replaceAll(),e.findAll()},Tab:function(e){(e.activeInput==e.replaceInput?e.searchInput:e.replaceInput).focus()}}),this.$searchBarKb.addCommands([{name:"toggleRegexpMode",bindKey:{win:"Alt-R|Alt-/",mac:"Ctrl-Alt-R|Ctrl-Alt-/"},exec:function(e){e.regExpOption.checked=!e.regExpOption.checked,e.$syncOptions()}},{name:"toggleCaseSensitive",bindKey:{win:"Alt-C|Alt-I",mac:"Ctrl-Alt-R|Ctrl-Alt-I"},exec:function(e){e.caseSensitiveOption.checked=!e.caseSensitiveOption.checked,e.$syncOptions()}},{name:"toggleWholeWords",bindKey:{win:"Alt-B|Alt-W",mac:"Ctrl-Alt-B|Ctrl-Alt-W"},exec:function(e){e.wholeWordOption.checked=!e.wholeWordOption.checked,e.$syncOptions()}}]),this.$syncOptions=function(){r.setCssClass(this.regExpOption,"checked",this.regExpOption.checked),r.setCssClass(this.wholeWordOption,"checked",this.wholeWordOption.checked),r.setCssClass(this.caseSensitiveOption,"checked",this.caseSensitiveOption.checked),this.find(!1,!1)},this.highlight=function(e){this.editor.session.highlight(e||this.editor.$search.$options.re),this.editor.renderer.updateBackMarkers()},this.find=function(e,t){var n=this.editor.find(this.searchInput.value,{skipCurrent:e,backwards:t,wrap:!0,regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked}),i=!n&&this.searchInput.value;r.setCssClass(this.searchBox,"ace_nomatch",i),this.editor._emit("findSearchBox",{match:!i}),this.highlight()},this.findNext=function(){this.find(!0,!1)},this.findPrev=function(){this.find(!0,!0)},this.findAll=function(){var e=this.editor.findAll(this.searchInput.value,{regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked}),t=!e&&this.searchInput.value;r.setCssClass(this.searchBox,"ace_nomatch",t),this.editor._emit("findSearchBox",{match:!t}),this.highlight(),this.hide()},this.replace=function(){this.editor.getReadOnly()||this.editor.replace(this.replaceInput.value)},this.replaceAndFindNext=function(){this.editor.getReadOnly()||(this.editor.replace(this.replaceInput.value),this.findNext())},this.replaceAll=function(){this.editor.getReadOnly()||this.editor.replaceAll(this.replaceInput.value)},this.hide=function(){this.element.style.display="none",this.editor.keyBinding.removeKeyboardHandler(this.$closeSearchBarKb),this.editor.focus()},this.show=function(e,t){this.element.style.display="",this.replaceBox.style.display=t?"":"none",this.isReplace=t,e&&(this.searchInput.value=e),this.searchInput.focus(),this.searchInput.select(),this.editor.keyBinding.addKeyboardHandler(this.$closeSearchBarKb)},this.isFocused=function(){var e=document.activeElement;return e==this.searchInput||e==this.replaceInput}}).call(l.prototype),t.SearchBox=l,t.Search=function(e,t){var n=e.searchBox||new l(e);n.show(e.session.getTextRange(),t)}}),ace.define("ace/ext/old_ie",["require","exports","module","ace/lib/useragent","ace/tokenizer","ace/ext/searchbox","ace/mode/text"],function(require,exports,module){"use strict";function patch(obj,name,regexp,replacement){eval("obj['"+name+"']="+obj[name].toString().replace(regexp,replacement))}var MAX_TOKEN_COUNT=1e3,useragent=require("../lib/useragent"),TokenizerModule=require("../tokenizer");useragent.isIE&&useragent.isIE<10&&window.top.document.compatMode==="BackCompat"&&(useragent.isOldIE=!0);if(typeof document!="undefined"&&!document.documentElement.querySelector){useragent.isOldIE=!0;var qs=function(e,t){if(t.charAt(0)==".")var n=t.slice(1);else var r=t.match(/(\w+)=(\w+)/),i=r&&r[1],s=r&&r[2];for(var o=0;o<e.all.length;o++){var u=e.all[o];if(n){if(u.className.indexOf(n)!=-1)return u}else if(i&&u.getAttribute(i)==s)return u}},sb=require("./searchbox").SearchBox.prototype;patch(sb,"$initElements",/([^\s=]*).querySelector\((".*?")\)/g,"qs($1, $2)")}var compliantExecNpcg=/()??/.exec("")[1]===undefined;if(compliantExecNpcg)return;var proto=TokenizerModule.Tokenizer.prototype;TokenizerModule.Tokenizer_orig=TokenizerModule.Tokenizer,proto.getLineTokens_orig=proto.getLineTokens,patch(TokenizerModule,"Tokenizer","ruleRegExps.push(adjustedregex);\n",function(e){return e+' if (state[i].next && RegExp(adjustedregex).test(""))\n rule._qre = RegExp(adjustedregex, "g");\n '}),TokenizerModule.Tokenizer.prototype=proto,patch(proto,"getLineTokens",/if \(match\[i \+ 1\] === undefined\)\s*continue;/,"if (!match[i + 1]) {\n if (value)continue;\n var qre = state[mapping[i]]._qre;\n if (!qre) continue;\n qre.lastIndex = lastIndex;\n if (!qre.exec(line) || qre.lastIndex != lastIndex)\n continue;\n }"),patch(require("../mode/text").Mode.prototype,"getTokenizer",/Tokenizer/,"TokenizerModule.Tokenizer"),useragent.isOldIE=!0});
2
- (function() {
3
- ace.require(["ace/ext/old_ie"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-searchbox.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/searchbox",["require","exports","module","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/keyboard/hash_handler","ace/lib/keys"],function(e,t,n){"use strict";var r=e("../lib/dom"),i=e("../lib/lang"),s=e("../lib/event"),o=".ace_search {background-color: #ddd;border: 1px solid #cbcbcb;border-top: 0 none;max-width: 325px;overflow: hidden;margin: 0;padding: 4px;padding-right: 6px;padding-bottom: 0;position: absolute;top: 0px;z-index: 99;white-space: normal;}.ace_search.left {border-left: 0 none;border-radius: 0px 0px 5px 0px;left: 0;}.ace_search.right {border-radius: 0px 0px 0px 5px;border-right: 0 none;right: 0;}.ace_search_form, .ace_replace_form {border-radius: 3px;border: 1px solid #cbcbcb;float: left;margin-bottom: 4px;overflow: hidden;}.ace_search_form.ace_nomatch {outline: 1px solid red;}.ace_search_field {background-color: white;border-right: 1px solid #cbcbcb;border: 0 none;-webkit-box-sizing: border-box;-moz-box-sizing: border-box;box-sizing: border-box;float: left;height: 22px;outline: 0;padding: 0 7px;width: 214px;margin: 0;}.ace_searchbtn,.ace_replacebtn {background: #fff;border: 0 none;border-left: 1px solid #dcdcdc;cursor: pointer;float: left;height: 22px;margin: 0;padding: 0;position: relative;}.ace_searchbtn:last-child,.ace_replacebtn:last-child {border-top-right-radius: 3px;border-bottom-right-radius: 3px;}.ace_searchbtn:disabled {background: none;cursor: default;}.ace_searchbtn {background-position: 50% 50%;background-repeat: no-repeat;width: 27px;}.ace_searchbtn.prev {background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAFCAYAAAB4ka1VAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAADFJREFUeNpiSU1NZUAC/6E0I0yACYskCpsJiySKIiY0SUZk40FyTEgCjGgKwTRAgAEAQJUIPCE+qfkAAAAASUVORK5CYII=); }.ace_searchbtn.next {background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAFCAYAAAB4ka1VAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAADRJREFUeNpiTE1NZQCC/0DMyIAKwGJMUAYDEo3M/s+EpvM/mkKwCQxYjIeLMaELoLMBAgwAU7UJObTKsvAAAAAASUVORK5CYII=); }.ace_searchbtn_close {background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAcCAYAAABRVo5BAAAAZ0lEQVR42u2SUQrAMAhDvazn8OjZBilCkYVVxiis8H4CT0VrAJb4WHT3C5xU2a2IQZXJjiQIRMdkEoJ5Q2yMqpfDIo+XY4k6h+YXOyKqTIj5REaxloNAd0xiKmAtsTHqW8sR2W5f7gCu5nWFUpVjZwAAAABJRU5ErkJggg==) no-repeat 50% 0;border-radius: 50%;border: 0 none;color: #656565;cursor: pointer;float: right;font: 16px/16px Arial;height: 14px;margin: 5px 1px 9px 5px;padding: 0;text-align: center;width: 14px;}.ace_searchbtn_close:hover {background-color: #656565;background-position: 50% 100%;color: white;}.ace_replacebtn.prev {width: 54px}.ace_replacebtn.next {width: 27px}.ace_button {margin-left: 2px;cursor: pointer;-webkit-user-select: none;-moz-user-select: none;-o-user-select: none;-ms-user-select: none;user-select: none;overflow: hidden;opacity: 0.7;border: 1px solid rgba(100,100,100,0.23);padding: 1px;-moz-box-sizing: border-box;box-sizing: border-box;color: black;}.ace_button:hover {background-color: #eee;opacity:1;}.ace_button:active {background-color: #ddd;}.ace_button.checked {border-color: #3399ff;opacity:1;}.ace_search_options{margin-bottom: 3px;text-align: right;-webkit-user-select: none;-moz-user-select: none;-o-user-select: none;-ms-user-select: none;user-select: none;}",u=e("../keyboard/hash_handler").HashHandler,a=e("../lib/keys");r.importCssString(o,"ace_searchbox");var f='<div class="ace_search right"> <button type="button" action="hide" class="ace_searchbtn_close"></button> <div class="ace_search_form"> <input class="ace_search_field" placeholder="Search for" spellcheck="false"></input> <button type="button" action="findNext" class="ace_searchbtn next"></button> <button type="button" action="findPrev" class="ace_searchbtn prev"></button> <button type="button" action="findAll" class="ace_searchbtn" title="Alt-Enter">All</button> </div> <div class="ace_replace_form"> <input class="ace_search_field" placeholder="Replace with" spellcheck="false"></input> <button type="button" action="replaceAndFindNext" class="ace_replacebtn">Replace</button> <button type="button" action="replaceAll" class="ace_replacebtn">All</button> </div> <div class="ace_search_options"> <span action="toggleRegexpMode" class="ace_button" title="RegExp Search">.*</span> <span action="toggleCaseSensitive" class="ace_button" title="CaseSensitive Search">Aa</span> <span action="toggleWholeWords" class="ace_button" title="Whole Word Search">\\b</span> </div></div>'.replace(/>\s+/g,">"),l=function(e,t,n){var i=r.createElement("div");i.innerHTML=f,this.element=i.firstChild,this.$init(),this.setEditor(e)};(function(){this.setEditor=function(e){e.searchBox=this,e.container.appendChild(this.element),this.editor=e},this.$initElements=function(e){this.searchBox=e.querySelector(".ace_search_form"),this.replaceBox=e.querySelector(".ace_replace_form"),this.searchOptions=e.querySelector(".ace_search_options"),this.regExpOption=e.querySelector("[action=toggleRegexpMode]"),this.caseSensitiveOption=e.querySelector("[action=toggleCaseSensitive]"),this.wholeWordOption=e.querySelector("[action=toggleWholeWords]"),this.searchInput=this.searchBox.querySelector(".ace_search_field"),this.replaceInput=this.replaceBox.querySelector(".ace_search_field")},this.$init=function(){var e=this.element;this.$initElements(e);var t=this;s.addListener(e,"mousedown",function(e){setTimeout(function(){t.activeInput.focus()},0),s.stopPropagation(e)}),s.addListener(e,"click",function(e){var n=e.target||e.srcElement,r=n.getAttribute("action");r&&t[r]?t[r]():t.$searchBarKb.commands[r]&&t.$searchBarKb.commands[r].exec(t),s.stopPropagation(e)}),s.addCommandKeyListener(e,function(e,n,r){var i=a.keyCodeToString(r),o=t.$searchBarKb.findKeyCommand(n,i);o&&o.exec&&(o.exec(t),s.stopEvent(e))}),this.$onChange=i.delayedCall(function(){t.find(!1,!1)}),s.addListener(this.searchInput,"input",function(){t.$onChange.schedule(20)}),s.addListener(this.searchInput,"focus",function(){t.activeInput=t.searchInput,t.searchInput.value&&t.highlight()}),s.addListener(this.replaceInput,"focus",function(){t.activeInput=t.replaceInput,t.searchInput.value&&t.highlight()})},this.$closeSearchBarKb=new u([{bindKey:"Esc",name:"closeSearchBar",exec:function(e){e.searchBox.hide()}}]),this.$searchBarKb=new u,this.$searchBarKb.bindKeys({"Ctrl-f|Command-f|Ctrl-H|Command-Option-F":function(e){var t=e.isReplace=!e.isReplace;e.replaceBox.style.display=t?"":"none",e[t?"replaceInput":"searchInput"].focus()},"Ctrl-G|Command-G":function(e){e.findNext()},"Ctrl-Shift-G|Command-Shift-G":function(e){e.findPrev()},esc:function(e){setTimeout(function(){e.hide()})},Return:function(e){e.activeInput==e.replaceInput&&e.replace(),e.findNext()},"Shift-Return":function(e){e.activeInput==e.replaceInput&&e.replace(),e.findPrev()},"Alt-Return":function(e){e.activeInput==e.replaceInput&&e.replaceAll(),e.findAll()},Tab:function(e){(e.activeInput==e.replaceInput?e.searchInput:e.replaceInput).focus()}}),this.$searchBarKb.addCommands([{name:"toggleRegexpMode",bindKey:{win:"Alt-R|Alt-/",mac:"Ctrl-Alt-R|Ctrl-Alt-/"},exec:function(e){e.regExpOption.checked=!e.regExpOption.checked,e.$syncOptions()}},{name:"toggleCaseSensitive",bindKey:{win:"Alt-C|Alt-I",mac:"Ctrl-Alt-R|Ctrl-Alt-I"},exec:function(e){e.caseSensitiveOption.checked=!e.caseSensitiveOption.checked,e.$syncOptions()}},{name:"toggleWholeWords",bindKey:{win:"Alt-B|Alt-W",mac:"Ctrl-Alt-B|Ctrl-Alt-W"},exec:function(e){e.wholeWordOption.checked=!e.wholeWordOption.checked,e.$syncOptions()}}]),this.$syncOptions=function(){r.setCssClass(this.regExpOption,"checked",this.regExpOption.checked),r.setCssClass(this.wholeWordOption,"checked",this.wholeWordOption.checked),r.setCssClass(this.caseSensitiveOption,"checked",this.caseSensitiveOption.checked),this.find(!1,!1)},this.highlight=function(e){this.editor.session.highlight(e||this.editor.$search.$options.re),this.editor.renderer.updateBackMarkers()},this.find=function(e,t){var n=this.editor.find(this.searchInput.value,{skipCurrent:e,backwards:t,wrap:!0,regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked}),i=!n&&this.searchInput.value;r.setCssClass(this.searchBox,"ace_nomatch",i),this.editor._emit("findSearchBox",{match:!i}),this.highlight()},this.findNext=function(){this.find(!0,!1)},this.findPrev=function(){this.find(!0,!0)},this.findAll=function(){var e=this.editor.findAll(this.searchInput.value,{regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked}),t=!e&&this.searchInput.value;r.setCssClass(this.searchBox,"ace_nomatch",t),this.editor._emit("findSearchBox",{match:!t}),this.highlight(),this.hide()},this.replace=function(){this.editor.getReadOnly()||this.editor.replace(this.replaceInput.value)},this.replaceAndFindNext=function(){this.editor.getReadOnly()||(this.editor.replace(this.replaceInput.value),this.findNext())},this.replaceAll=function(){this.editor.getReadOnly()||this.editor.replaceAll(this.replaceInput.value)},this.hide=function(){this.element.style.display="none",this.editor.keyBinding.removeKeyboardHandler(this.$closeSearchBarKb),this.editor.focus()},this.show=function(e,t){this.element.style.display="",this.replaceBox.style.display=t?"":"none",this.isReplace=t,e&&(this.searchInput.value=e),this.searchInput.focus(),this.searchInput.select(),this.editor.keyBinding.addKeyboardHandler(this.$closeSearchBarKb)},this.isFocused=function(){var e=document.activeElement;return e==this.searchInput||e==this.replaceInput}}).call(l.prototype),t.SearchBox=l,t.Search=function(e,t){var n=e.searchBox||new l(e);n.show(e.session.getTextRange(),t)}});
2
- (function() {
3
- ace.require(["ace/ext/searchbox"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-settings_menu.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/menu_tools/element_generator",["require","exports","module"],function(e,t,n){"use strict";n.exports.createOption=function(t){var n,r=document.createElement("option");for(n in t)t.hasOwnProperty(n)&&(n==="selected"?r.setAttribute(n,t[n]):r[n]=t[n]);return r},n.exports.createCheckbox=function(t,n,r){var i=document.createElement("input");return i.setAttribute("type","checkbox"),i.setAttribute("id",t),i.setAttribute("name",t),i.setAttribute("value",n),i.setAttribute("class",r),n&&i.setAttribute("checked","checked"),i},n.exports.createInput=function(t,n,r){var i=document.createElement("input");return i.setAttribute("type","text"),i.setAttribute("id",t),i.setAttribute("name",t),i.setAttribute("value",n),i.setAttribute("class",r),i},n.exports.createLabel=function(t,n){var r=document.createElement("label");return r.setAttribute("for",n),r.textContent=t,r},n.exports.createSelection=function(t,r,i){var s=document.createElement("select");return s.setAttribute("id",t),s.setAttribute("name",t),s.setAttribute("class",i),r.forEach(function(e){s.appendChild(n.exports.createOption(e))}),s}}),ace.define("ace/ext/modelist",["require","exports","module"],function(e,t,n){"use strict";function i(e){var t=a.text,n=e.split(/[\/\\]/).pop();for(var i=0;i<r.length;i++)if(r[i].supportsFile(n)){t=r[i];break}return t}var r=[],s=function(e,t,n){this.name=e,this.caption=t,this.mode="ace/mode/"+e,this.extensions=n;if(/\^/.test(n))var r=n.replace(/\|(\^)?/g,function(e,t){return"$|"+(t?"^":"^.*\\.")})+"$";else var r="^.*\\.("+n+")$";this.extRe=new RegExp(r,"gi")};s.prototype.supportsFile=function(e){return e.match(this.extRe)};var o={ABAP:["abap"],ActionScript:["as"],ADA:["ada|adb"],Apache_Conf:["^htaccess|^htgroups|^htpasswd|^conf|htaccess|htgroups|htpasswd"],AsciiDoc:["asciidoc"],Assembly_x86:["asm"],AutoHotKey:["ahk"],BatchFile:["bat|cmd"],C9Search:["c9search_results"],C_Cpp:["cpp|c|cc|cxx|h|hh|hpp"],Cirru:["cirru|cr"],Clojure:["clj|cljs"],Cobol:["CBL|COB"],coffee:["coffee|cf|cson|^Cakefile"],ColdFusion:["cfm"],CSharp:["cs"],CSS:["css"],Curly:["curly"],D:["d|di"],Dart:["dart"],Diff:["diff|patch"],Dockerfile:["^Dockerfile"],Dot:["dot"],Dummy:["dummy"],DummySyntax:["dummy"],Eiffel:["e"],EJS:["ejs"],Elixir:["ex|exs"],Elm:["elm"],Erlang:["erl|hrl"],Forth:["frt|fs|ldr"],FTL:["ftl"],Gcode:["gcode"],Gherkin:["feature"],Gitignore:["^.gitignore"],Glsl:["glsl|frag|vert"],golang:["go"],Groovy:["groovy"],HAML:["haml"],Handlebars:["hbs|handlebars|tpl|mustache"],Haskell:["hs"],haXe:["hx"],HTML:["html|htm|xhtml"],HTML_Ruby:["erb|rhtml|html.erb"],INI:["ini|conf|cfg|prefs"],Io:["io"],Jack:["jack"],Jade:["jade"],Java:["java"],JavaScript:["js|jsm"],JSON:["json"],JSONiq:["jq"],JSP:["jsp"],JSX:["jsx"],Julia:["jl"],LaTeX:["tex|latex|ltx|bib"],LESS:["less"],Liquid:["liquid"],Lisp:["lisp"],LiveScript:["ls"],LogiQL:["logic|lql"],LSL:["lsl"],Lua:["lua"],LuaPage:["lp"],Lucene:["lucene"],Makefile:["^Makefile|^GNUmakefile|^makefile|^OCamlMakefile|make"],Markdown:["md|markdown"],Mask:["mask"],MATLAB:["matlab"],MEL:["mel"],MUSHCode:["mc|mush"],MySQL:["mysql"],Nix:["nix"],ObjectiveC:["m|mm"],OCaml:["ml|mli"],Pascal:["pas|p"],Perl:["pl|pm"],pgSQL:["pgsql"],PHP:["php|phtml"],Powershell:["ps1"],Praat:["praat|praatscript|psc|proc"],Prolog:["plg|prolog"],Properties:["properties"],Protobuf:["proto"],Python:["py"],R:["r"],RDoc:["Rd"],RHTML:["Rhtml"],Ruby:["rb|ru|gemspec|rake|^Guardfile|^Rakefile|^Gemfile"],Rust:["rs"],SASS:["sass"],SCAD:["scad"],Scala:["scala"],Scheme:["scm|rkt"],SCSS:["scss"],SH:["sh|bash|^.bashrc"],SJS:["sjs"],Smarty:["smarty|tpl"],snippets:["snippets"],Soy_Template:["soy"],Space:["space"],SQL:["sql"],Stylus:["styl|stylus"],SVG:["svg"],Tcl:["tcl"],Tex:["tex"],Text:["txt"],Textile:["textile"],Toml:["toml"],Twig:["twig"],Typescript:["ts|typescript|str"],Vala:["vala"],VBScript:["vbs|vb"],Velocity:["vm"],Verilog:["v|vh|sv|svh"],VHDL:["vhd|vhdl"],XML:["xml|rdf|rss|wsdl|xslt|atom|mathml|mml|xul|xbl"],XQuery:["xq"],YAML:["yaml|yml"]},u={ObjectiveC:"Objective-C",CSharp:"C#",golang:"Go",C_Cpp:"C and C++",coffee:"CoffeeScript",HTML_Ruby:"HTML (Ruby)",FTL:"FreeMarker"},a={};for(var f in o){var l=o[f],c=(u[f]||f).replace(/_/g," "),h=f.toLowerCase(),p=new s(h,c,l[0]);a[h]=p,r.push(p)}n.exports={getModeForPath:i,modes:r,modesByName:a}}),ace.define("ace/ext/themelist",["require","exports","module","ace/lib/fixoldbrowsers"],function(e,t,n){"use strict";e("ace/lib/fixoldbrowsers");var r=[["Chrome"],["Clouds"],["Crimson Editor"],["Dawn"],["Dreamweaver"],["Eclipse"],["GitHub"],["Solarized Light"],["TextMate"],["Tomorrow"],["XCode"],["Kuroir"],["KatzenMilch"],["Ambiance","ambiance","dark"],["Chaos","chaos","dark"],["Clouds Midnight","clouds_midnight","dark"],["Cobalt","cobalt","dark"],["idle Fingers","idle_fingers","dark"],["krTheme","kr_theme","dark"],["Merbivore","merbivore","dark"],["Merbivore Soft","merbivore_soft","dark"],["Mono Industrial","mono_industrial","dark"],["Monokai","monokai","dark"],["Pastel on dark","pastel_on_dark","dark"],["Solarized Dark","solarized_dark","dark"],["Terminal","terminal","dark"],["Tomorrow Night","tomorrow_night","dark"],["Tomorrow Night Blue","tomorrow_night_blue","dark"],["Tomorrow Night Bright","tomorrow_night_bright","dark"],["Tomorrow Night 80s","tomorrow_night_eighties","dark"],["Twilight","twilight","dark"],["Vibrant Ink","vibrant_ink","dark"]];t.themesByName={},t.themes=r.map(function(e){var n=e[1]||e[0].replace(/ /g,"_").toLowerCase(),r={caption:e[0],theme:"ace/theme/"+n,isDark:e[2]=="dark",name:n};return t.themesByName[n]=r,r})}),ace.define("ace/ext/menu_tools/add_editor_menu_options",["require","exports","module","ace/ext/modelist","ace/ext/themelist"],function(e,t,n){"use strict";n.exports.addEditorMenuOptions=function(n){var r=e("../modelist"),i=e("../themelist");n.menuOptions={setNewLineMode:[{textContent:"unix",value:"unix"},{textContent:"windows",value:"windows"},{textContent:"auto",value:"auto"}],setTheme:[],setMode:[],setKeyboardHandler:[{textContent:"ace",value:""},{textContent:"vim",value:"ace/keyboard/vim"},{textContent:"emacs",value:"ace/keyboard/emacs"},{textContent:"textarea",value:"ace/keyboard/textarea"},{textContent:"sublime",value:"ace/keyboard/sublime"}]},n.menuOptions.setTheme=i.themes.map(function(e){return{textContent:e.caption,value:e.theme}}),n.menuOptions.setMode=r.modes.map(function(e){return{textContent:e.name,value:e.mode}})}}),ace.define("ace/ext/menu_tools/get_set_functions",["require","exports","module"],function(e,t,n){"use strict";n.exports.getSetFunctions=function(t){var n=[],r={editor:t,session:t.session,renderer:t.renderer},i=[],s=["setOption","setUndoManager","setDocument","setValue","setBreakpoints","setScrollTop","setScrollLeft","setSelectionStyle","setWrapLimitRange"];return["renderer","session","editor"].forEach(function(e){var t=r[e],o=e;for(var u in t)s.indexOf(u)===-1&&/^set/.test(u)&&i.indexOf(u)===-1&&(i.push(u),n.push({functionName:u,parentObj:t,parentName:o}))}),n}}),ace.define("ace/ext/menu_tools/generate_settings_menu",["require","exports","module","ace/ext/menu_tools/element_generator","ace/ext/menu_tools/add_editor_menu_options","ace/ext/menu_tools/get_set_functions"],function(e,t,n){"use strict";var r=e("./element_generator"),i=e("./add_editor_menu_options").addEditorMenuOptions,s=e("./get_set_functions").getSetFunctions;n.exports.generateSettingsMenu=function(t){function o(){n.sort(function(e,t){var n=e.getAttribute("contains"),r=t.getAttribute("contains");return n.localeCompare(r)})}function u(){var e=document.createElement("div");e.setAttribute("id","ace_settingsmenu"),n.forEach(function(t){e.appendChild(t)});var t=e.appendChild(document.createElement("div")),r="1.1.8";return t.style.padding="1em",t.textContent="Ace version "+r,e}function a(e,n,i,s){var o,u=document.createElement("div");return u.setAttribute("contains",i),u.setAttribute("class","ace_optionsMenuEntry"),u.setAttribute("style","clear: both;"),u.appendChild(r.createLabel(i.replace(/^set/,"").replace(/([A-Z])/g," $1").trim(),i)),Array.isArray(s)?(o=r.createSelection(i,s,n),o.addEventListener("change",function(n){try{t.menuOptions[n.target.id].forEach(function(e){e.textContent!==n.target.textContent&&delete e.selected}),e[n.target.id](n.target.value)}catch(r){throw new Error(r)}})):typeof s=="boolean"?(o=r.createCheckbox(i,s,n),o.addEventListener("change",function(t){try{e[t.target.id](!!t.target.checked)}catch(n){throw new Error(n)}})):(o=r.createInput(i,s,n),o.addEventListener("change",function(t){try{t.target.value==="true"?e[t.target.id](!0):t.target.value==="false"?e[t.target.id](!1):e[t.target.id](t.target.value)}catch(n){throw new Error(n)}})),o.style.cssText="float:right;",u.appendChild(o),u}function f(e,n,r,i){var s=t.menuOptions[e],o=n[i]();return typeof o=="object"&&(o=o.$id),s.forEach(function(e){e.value===o&&(e.selected="selected")}),a(n,r,e,s)}function l(e){var r=e.functionName,i=e.parentObj,s=e.parentName,o,u=r.replace(/^set/,"get");if(t.menuOptions[r]!==undefined)n.push(f(r,i,s,u));else if(typeof i[u]=="function")try{o=i[u](),typeof o=="object"&&(o=o.$id),n.push(a(i,s,r,o))}catch(l){}}var n=[];return i(t),s(t).forEach(function(e){l(e)}),o(),u()}}),ace.define("ace/ext/menu_tools/overlay_page",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../../lib/dom"),i="#ace_settingsmenu, #kbshortcutmenu {background-color: #F7F7F7;color: black;box-shadow: -5px 4px 5px rgba(126, 126, 126, 0.55);padding: 1em 0.5em 2em 1em;overflow: auto;position: absolute;margin: 0;bottom: 0;right: 0;top: 0;z-index: 9991;cursor: default;}.ace_dark #ace_settingsmenu, .ace_dark #kbshortcutmenu {box-shadow: -20px 10px 25px rgba(126, 126, 126, 0.25);background-color: rgba(255, 255, 255, 0.6);color: black;}.ace_optionsMenuEntry:hover {background-color: rgba(100, 100, 100, 0.1);-webkit-transition: all 0.5s;transition: all 0.3s}.ace_closeButton {background: rgba(245, 146, 146, 0.5);border: 1px solid #F48A8A;border-radius: 50%;padding: 7px;position: absolute;right: -8px;top: -8px;z-index: 1000;}.ace_closeButton{background: rgba(245, 146, 146, 0.9);}.ace_optionsMenuKey {color: darkslateblue;font-weight: bold;}.ace_optionsMenuCommand {color: darkcyan;font-weight: normal;}";r.importCssString(i),n.exports.overlayPage=function(t,n,i,s,o,u){function l(e){e.keyCode===27&&a.click()}i=i?"top: "+i+";":"",o=o?"bottom: "+o+";":"",s=s?"right: "+s+";":"",u=u?"left: "+u+";":"";var a=document.createElement("div"),f=document.createElement("div");a.style.cssText="margin: 0; padding: 0; position: fixed; top:0; bottom:0; left:0; right:0;z-index: 9990; background-color: rgba(0, 0, 0, 0.3);",a.addEventListener("click",function(){document.removeEventListener("keydown",l),a.parentNode.removeChild(a),t.focus(),a=null}),document.addEventListener("keydown",l),f.style.cssText=i+s+o+u,f.addEventListener("click",function(e){e.stopPropagation()});var c=r.createElement("div");c.style.position="relative";var h=r.createElement("div");h.className="ace_closeButton",h.addEventListener("click",function(){a.click()}),c.appendChild(h),f.appendChild(c),f.appendChild(n),a.appendChild(f),document.body.appendChild(a),t.blur()}}),ace.define("ace/ext/settings_menu",["require","exports","module","ace/ext/menu_tools/generate_settings_menu","ace/ext/menu_tools/overlay_page","ace/editor"],function(e,t,n){"use strict";function s(e){var t=document.getElementById("ace_settingsmenu");t||i(e,r(e),"0","0","0")}var r=e("./menu_tools/generate_settings_menu").generateSettingsMenu,i=e("./menu_tools/overlay_page").overlayPage;n.exports.init=function(t){var n=e("ace/editor").Editor;n.prototype.showSettingsMenu=function(){s(this)}}});
2
- (function() {
3
- ace.require(["ace/ext/settings_menu"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-spellcheck.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/spellcheck",["require","exports","module","ace/lib/event","ace/editor","ace/config"],function(e,t,n){"use strict";var r=e("../lib/event");t.contextMenuHandler=function(e){var t=e.target,n=t.textInput.getElement();if(!t.selection.isEmpty())return;var i=t.getCursorPosition(),s=t.session.getWordRange(i.row,i.column),o=t.session.getTextRange(s);t.session.tokenRe.lastIndex=0;if(!t.session.tokenRe.test(o))return;var u="",a=o+" "+u;n.value=a,n.setSelectionRange(o.length,o.length+1),n.setSelectionRange(0,0),n.setSelectionRange(0,o.length);var f=!1;r.addListener(n,"keydown",function l(){r.removeListener(n,"keydown",l),f=!0}),t.textInput.setInputHandler(function(e){console.log(e,a,n.selectionStart,n.selectionEnd);if(e==a)return"";if(e.lastIndexOf(a,0)===0)return e.slice(a.length);if(e.substr(n.selectionEnd)==a)return e.slice(0,-a.length);if(e.slice(-2)==u){var r=e.slice(0,-2);if(r.slice(-1)==" ")return f?r.substring(0,n.selectionEnd):(r=r.slice(0,-1),t.session.replace(s,r),"")}return e})};var i=e("../editor").Editor;e("../config").defineOptions(i.prototype,"editor",{spellcheck:{set:function(e){var n=this.textInput.getElement();n.spellcheck=!!e,e?this.on("nativecontextmenu",t.contextMenuHandler):this.removeListener("nativecontextmenu",t.contextMenuHandler)},value:!0}})});
2
- (function() {
3
- ace.require(["ace/ext/spellcheck"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-split.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/split",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/editor","ace/virtual_renderer","ace/edit_session"],function(e,t,n){"use strict";function l(e,t){this.$u=e,this.$doc=t}var r=e("./lib/oop"),i=e("./lib/lang"),s=e("./lib/event_emitter").EventEmitter,o=e("./editor").Editor,u=e("./virtual_renderer").VirtualRenderer,a=e("./edit_session").EditSession,f=function(e,t,n){this.BELOW=1,this.BESIDE=0,this.$container=e,this.$theme=t,this.$splits=0,this.$editorCSS="",this.$editors=[],this.$orientation=this.BESIDE,this.setSplits(n||1),this.$cEditor=this.$editors[0],this.on("focus",function(e){this.$cEditor=e}.bind(this))};(function(){r.implement(this,s),this.$createEditor=function(){var e=document.createElement("div");e.className=this.$editorCSS,e.style.cssText="position: absolute; top:0px; bottom:0px",this.$container.appendChild(e);var t=new o(new u(e,this.$theme));return t.on("focus",function(){this._emit("focus",t)}.bind(this)),this.$editors.push(t),t.setFontSize(this.$fontSize),t},this.setSplits=function(e){var t;if(e<1)throw"The number of splits have to be > 0!";if(e==this.$splits)return;if(e>this.$splits){while(this.$splits<this.$editors.length&&this.$splits<e)t=this.$editors[this.$splits],this.$container.appendChild(t.container),t.setFontSize(this.$fontSize),this.$splits++;while(this.$splits<e)this.$createEditor(),this.$splits++}else while(this.$splits>e)t=this.$editors[this.$splits-1],this.$container.removeChild(t.container),this.$splits--;this.resize()},this.getSplits=function(){return this.$splits},this.getEditor=function(e){return this.$editors[e]},this.getCurrentEditor=function(){return this.$cEditor},this.focus=function(){this.$cEditor.focus()},this.blur=function(){this.$cEditor.blur()},this.setTheme=function(e){this.$editors.forEach(function(t){t.setTheme(e)})},this.setKeyboardHandler=function(e){this.$editors.forEach(function(t){t.setKeyboardHandler(e)})},this.forEach=function(e,t){this.$editors.forEach(e,t)},this.$fontSize="",this.setFontSize=function(e){this.$fontSize=e,this.forEach(function(t){t.setFontSize(e)})},this.$cloneSession=function(e){var t=new a(e.getDocument(),e.getMode()),n=e.getUndoManager();if(n){var r=new l(n,t);t.setUndoManager(r)}return t.$informUndoManager=i.delayedCall(function(){t.$deltas=[]}),t.setTabSize(e.getTabSize()),t.setUseSoftTabs(e.getUseSoftTabs()),t.setOverwrite(e.getOverwrite()),t.setBreakpoints(e.getBreakpoints()),t.setUseWrapMode(e.getUseWrapMode()),t.setUseWorker(e.getUseWorker()),t.setWrapLimitRange(e.$wrapLimitRange.min,e.$wrapLimitRange.max),t.$foldData=e.$cloneFoldData(),t},this.setSession=function(e,t){var n;t==null?n=this.$cEditor:n=this.$editors[t];var r=this.$editors.some(function(t){return t.session===e});return r&&(e=this.$cloneSession(e)),n.setSession(e),e},this.getOrientation=function(){return this.$orientation},this.setOrientation=function(e){if(this.$orientation==e)return;this.$orientation=e,this.resize()},this.resize=function(){var e=this.$container.clientWidth,t=this.$container.clientHeight,n;if(this.$orientation==this.BESIDE){var r=e/this.$splits;for(var i=0;i<this.$splits;i++)n=this.$editors[i],n.container.style.width=r+"px",n.container.style.top="0px",n.container.style.left=i*r+"px",n.container.style.height=t+"px",n.resize()}else{var s=t/this.$splits;for(var i=0;i<this.$splits;i++)n=this.$editors[i],n.container.style.width=e+"px",n.container.style.top=i*s+"px",n.container.style.left="0px",n.container.style.height=s+"px",n.resize()}}}).call(f.prototype),function(){this.execute=function(e){this.$u.execute(e)},this.undo=function(){var e=this.$u.undo(!0);e&&this.$doc.selection.setSelectionRange(e)},this.redo=function(){var e=this.$u.redo(!0);e&&this.$doc.selection.setSelectionRange(e)},this.reset=function(){this.$u.reset()},this.hasUndo=function(){return this.$u.hasUndo()},this.hasRedo=function(){return this.$u.hasRedo()}}.call(l.prototype),t.Split=f}),ace.define("ace/ext/split",["require","exports","module","ace/split"],function(e,t,n){"use strict";n.exports=e("../split")});
2
- (function() {
3
- ace.require(["ace/ext/split"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-static_highlight.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/static_highlight",["require","exports","module","ace/edit_session","ace/layer/text","ace/config","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../edit_session").EditSession,i=e("../layer/text").Text,s=".ace_static_highlight {font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', 'Droid Sans Mono', monospace;font-size: 12px;}.ace_static_highlight .ace_gutter {width: 25px !important;float: left;text-align: right;padding: 0 3px 0 0;margin-right: 3px;position: static !important;}.ace_static_highlight .ace_line { clear: both; }.ace_static_highlight .ace_gutter-cell {-moz-user-select: -moz-none;-khtml-user-select: none;-webkit-user-select: none;user-select: none;}.ace_static_highlight .ace_gutter-cell:before {content: counter(ace_line, decimal);counter-increment: ace_line;}.ace_static_highlight {counter-reset: ace_line;}",o=e("../config"),u=e("../lib/dom"),a=function(e,t,n){var r=e.className.match(/lang-(\w+)/),i=t.mode||r&&"ace/mode/"+r[1];if(!i)return!1;var s=t.theme||"ace/theme/textmate",o="",f=[];if(e.firstElementChild){var l=0;for(var c=0;c<e.childNodes.length;c++){var h=e.childNodes[c];h.nodeType==3?(l+=h.data.length,o+=h.data):f.push(l,h)}}else o=u.getInnerText(e),t.trim&&(o=o.trim());a.render(o,i,s,t.firstLineNumber,!t.showGutter,function(t){u.importCssString(t.css,"ace_highlight"),e.innerHTML=t.html;var r=e.firstChild.firstChild;for(var i=0;i<f.length;i+=2){var s=t.session.doc.indexToPosition(f[i]),o=f[i+1],a=r.children[s.row];a&&a.appendChild(o)}n&&n()})};a.render=function(e,t,n,i,s,u){function h(){var r=a.renderSync(e,t,n,i,s);return u?u(r):r}var f=1,l=r.prototype.$modes;typeof n=="string"&&(f++,o.loadModule(["theme",n],function(e){n=e,--f||h()}));var c;return t&&typeof t=="object"&&!t.getTokenizer&&(c=t,t=c.path),typeof t=="string"&&(f++,o.loadModule(["mode",t],function(e){if(!l[t]||c)l[t]=new e.Mode(c);t=l[t],--f||h()})),--f||h()},a.renderSync=function(e,t,n,o,u){o=parseInt(o||1,10);var a=new r("");a.setUseWorker(!1),a.setMode(t);var f=new i(document.createElement("div"));f.setSession(a),f.config={characterWidth:10,lineHeight:20},a.setValue(e);var l=[],c=a.getLength();for(var h=0;h<c;h++)l.push("<div class='ace_line'>"),u||l.push("<span class='ace_gutter ace_gutter-cell' unselectable='on'></span>"),f.$renderLine(l,h,!0,!1),l.push("\n</div>");var p="<div class='"+n.cssClass+"'>"+"<div class='ace_static_highlight' style='counter-reset:ace_line "+(o-1)+"'>"+l.join("")+"</div>"+"</div>";return f.destroy(),{css:s+n.cssText,html:p,session:a}},n.exports=a,n.exports.highlight=a});
2
- (function() {
3
- ace.require(["ace/ext/static_highlight"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-statusbar.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/statusbar",["require","exports","module","ace/lib/dom","ace/lib/lang"],function(e,t,n){"use strict";var r=e("ace/lib/dom"),i=e("ace/lib/lang"),s=function(e,t){this.element=r.createElement("div"),this.element.className="ace_status-indicator",this.element.style.cssText="display: inline-block;",t.appendChild(this.element);var n=i.delayedCall(function(){this.updateStatus(e)}.bind(this));e.on("changeStatus",function(){n.schedule(100)}),e.on("changeSelection",function(){n.schedule(100)})};(function(){this.updateStatus=function(e){function n(e,n){e&&t.push(e,n||"|")}var t=[];n(e.keyBinding.getStatusText(e)),e.commands.recording&&n("REC");var r=e.selection.lead;n(r.row+":"+r.column," ");if(!e.selection.isEmpty()){var i=e.getSelectionRange();n("("+(i.end.row-i.start.row)+":"+(i.end.column-i.start.column)+")")}t.pop(),this.element.textContent=t.join("")}}).call(s.prototype),t.StatusBar=s});
2
- (function() {
3
- ace.require(["ace/ext/statusbar"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-textarea.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/theme/textmate",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";t.isDark=!1,t.cssClass="ace-tm",t.cssText='.ace-tm .ace_gutter {background: #f0f0f0;color: #333;}.ace-tm .ace_print-margin {width: 1px;background: #e8e8e8;}.ace-tm .ace_fold {background-color: #6B72E6;}.ace-tm {background-color: #FFFFFF;color: black;}.ace-tm .ace_cursor {color: black;}.ace-tm .ace_invisible {color: rgb(191, 191, 191);}.ace-tm .ace_storage,.ace-tm .ace_keyword {color: blue;}.ace-tm .ace_constant {color: rgb(197, 6, 11);}.ace-tm .ace_constant.ace_buildin {color: rgb(88, 72, 246);}.ace-tm .ace_constant.ace_language {color: rgb(88, 92, 246);}.ace-tm .ace_constant.ace_library {color: rgb(6, 150, 14);}.ace-tm .ace_invalid {background-color: rgba(255, 0, 0, 0.1);color: red;}.ace-tm .ace_support.ace_function {color: rgb(60, 76, 114);}.ace-tm .ace_support.ace_constant {color: rgb(6, 150, 14);}.ace-tm .ace_support.ace_type,.ace-tm .ace_support.ace_class {color: rgb(109, 121, 222);}.ace-tm .ace_keyword.ace_operator {color: rgb(104, 118, 135);}.ace-tm .ace_string {color: rgb(3, 106, 7);}.ace-tm .ace_comment {color: rgb(76, 136, 107);}.ace-tm .ace_comment.ace_doc {color: rgb(0, 102, 255);}.ace-tm .ace_comment.ace_doc.ace_tag {color: rgb(128, 159, 191);}.ace-tm .ace_constant.ace_numeric {color: rgb(0, 0, 205);}.ace-tm .ace_variable {color: rgb(49, 132, 149);}.ace-tm .ace_xml-pe {color: rgb(104, 104, 91);}.ace-tm .ace_entity.ace_name.ace_function {color: #0000A2;}.ace-tm .ace_heading {color: rgb(12, 7, 255);}.ace-tm .ace_list {color:rgb(185, 6, 144);}.ace-tm .ace_meta.ace_tag {color:rgb(0, 22, 142);}.ace-tm .ace_string.ace_regex {color: rgb(255, 0, 0)}.ace-tm .ace_marker-layer .ace_selection {background: rgb(181, 213, 255);}.ace-tm.ace_multiselect .ace_selection.ace_start {box-shadow: 0 0 3px 0px white;border-radius: 2px;}.ace-tm .ace_marker-layer .ace_step {background: rgb(252, 255, 0);}.ace-tm .ace_marker-layer .ace_stack {background: rgb(164, 229, 101);}.ace-tm .ace_marker-layer .ace_bracket {margin: -1px 0 0 -1px;border: 1px solid rgb(192, 192, 192);}.ace-tm .ace_marker-layer .ace_active-line {background: rgba(0, 0, 0, 0.07);}.ace-tm .ace_gutter-active-line {background-color : #dcdcdc;}.ace-tm .ace_marker-layer .ace_selected-word {background: rgb(250, 250, 255);border: 1px solid rgb(200, 200, 250);}.ace-tm .ace_indent-guide {background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;}';var r=e("../lib/dom");r.importCssString(t.cssText,t.cssClass)}),ace.define("ace/ace",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/dom","ace/lib/event","ace/editor","ace/edit_session","ace/undomanager","ace/virtual_renderer","ace/worker/worker_client","ace/keyboard/hash_handler","ace/placeholder","ace/multi_select","ace/mode/folding/fold_mode","ace/theme/textmate","ace/ext/error_marker","ace/config"],function(e,t,n){"use strict";e("./lib/fixoldbrowsers");var r=e("./lib/dom"),i=e("./lib/event"),s=e("./editor").Editor,o=e("./edit_session").EditSession,u=e("./undomanager").UndoManager,a=e("./virtual_renderer").VirtualRenderer;e("./worker/worker_client"),e("./keyboard/hash_handler"),e("./placeholder"),e("./multi_select"),e("./mode/folding/fold_mode"),e("./theme/textmate"),e("./ext/error_marker"),t.config=e("./config"),t.require=e,t.edit=function(e){if(typeof e=="string"){var n=e;e=document.getElementById(n);if(!e)throw new Error("ace.edit can't find div #"+n)}if(e&&e.env&&e.env.editor instanceof s)return e.env.editor;var o="";if(e&&/input|textarea/i.test(e.tagName)){var u=e;o=u.value,e=r.createElement("pre"),u.parentNode.replaceChild(e,u)}else o=r.getInnerText(e),e.innerHTML="";var f=t.createEditSession(o),l=new s(new a(e));l.setSession(f);var c={document:f,editor:l,onResize:l.resize.bind(l,null)};return u&&(c.textarea=u),i.addListener(window,"resize",c.onResize),l.on("destroy",function(){i.removeListener(window,"resize",c.onResize),c.editor.container.env=null}),l.container.env=l.env=c,l},t.createEditSession=function(e,t){var n=new o(e,t);return n.setUndoManager(new u),n},t.EditSession=o,t.UndoManager=u}),ace.define("ace/ext/textarea",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/lib/net","ace/ace","ace/theme/textmate"],function(e,t,n){"use strict";function a(e,t){for(var n in t)e.style[n]=t[n]}function f(e,t){if(e.type!="textarea")throw new Error("Textarea required!");var n=e.parentNode,i=document.createElement("div"),s=function(){var t="position:relative;";["margin-top","margin-left","margin-right","margin-bottom"].forEach(function(n){t+=n+":"+u(e,i,n)+";"});var n=u(e,i,"width")||e.clientWidth+"px",r=u(e,i,"height")||e.clientHeight+"px";t+="height:"+r+";width:"+n+";",t+="display:inline-block;",i.setAttribute("style",t)};r.addListener(window,"resize",s),s(),n.insertBefore(i,e.nextSibling);while(n!==document){if(n.tagName.toUpperCase()==="FORM"){var o=n.onsubmit;n.onsubmit=function(n){e.value=t(),o&&o.call(this,n)};break}n=n.parentNode}return i}function l(t,n,r){s.loadScript(t,function(){e([n],r)})}function c(e,t,n,r,i,s){function a(e){return e==="true"||e==1}var o=e.getSession(),u=e.renderer;return s=s||l,e.setDisplaySettings=function(t){t==null&&(t=n.style.display=="none"),t?(n.style.display="block",n.hideButton.focus(),e.on("focus",function r(){e.removeListener("focus",r),n.style.display="none"})):e.focus()},e.$setOption=e.setOption,e.$getOption=e.getOption,e.setOption=function(t,n){switch(t){case"mode":e.$setOption("mode","ace/mode/"+n);break;case"theme":e.$setOption("theme","ace/theme/"+n);break;case"keybindings":switch(n){case"vim":e.setKeyboardHandler("ace/keyboard/vim");break;case"emacs":e.setKeyboardHandler("ace/keyboard/emacs");break;default:e.setKeyboardHandler(null)}break;case"softWrap":case"fontSize":e.$setOption(t,n);break;default:e.$setOption(t,a(n))}},e.getOption=function(t){switch(t){case"mode":return e.$getOption("mode").substr("ace/mode/".length);case"theme":return e.$getOption("theme").substr("ace/theme/".length);case"keybindings":var n=e.getKeyboardHandler();switch(n&&n.$id){case"ace/keyboard/vim":return"vim";case"ace/keyboard/emacs":return"emacs";default:return"ace"}break;default:return e.$getOption(t)}},e.setOptions(i),e}function h(e,n,i){function f(e,t,n,r){if(!n){e.push("<input type='checkbox' title='",t,"' ",r+""=="true"?"checked='true'":"","'></input>");return}e.push("<select title='"+t+"'>");for(var i in n)e.push("<option value='"+i+"' "),r==i&&e.push(" selected "),e.push(">",n[i],"</option>");e.push("</select>")}var s=null,o={mode:"Mode:",wrap:"Soft Wrap:",theme:"Theme:",fontSize:"Font Size:",showGutter:"Display Gutter:",keybindings:"Keyboard",showPrintMargin:"Show Print Margin:",useSoftTabs:"Use Soft Tabs:",showInvisibles:"Show Invisibles"},u={mode:{text:"Plain",javascript:"JavaScript",xml:"XML",html:"HTML",css:"CSS",scss:"SCSS",python:"Python",php:"PHP",java:"Java",ruby:"Ruby",c_cpp:"C/C++",coffee:"CoffeeScript",json:"json",perl:"Perl",clojure:"Clojure",ocaml:"OCaml",csharp:"C#",haxe:"haXe",svg:"SVG",textile:"Textile",groovy:"Groovy",liquid:"Liquid",Scala:"Scala"},theme:{clouds:"Clouds",clouds_midnight:"Clouds Midnight",cobalt:"Cobalt",crimson_editor:"Crimson Editor",dawn:"Dawn",eclipse:"Eclipse",idle_fingers:"Idle Fingers",kr_theme:"Kr Theme",merbivore:"Merbivore",merbivore_soft:"Merbivore Soft",mono_industrial:"Mono Industrial",monokai:"Monokai",pastel_on_dark:"Pastel On Dark",solarized_dark:"Solarized Dark",solarized_light:"Solarized Light",textmate:"Textmate",twilight:"Twilight",vibrant_ink:"Vibrant Ink"},showGutter:s,fontSize:{"10px":"10px","11px":"11px","12px":"12px","14px":"14px","16px":"16px"},wrap:{off:"Off",40:"40",80:"80",free:"Free"},keybindings:{ace:"ace",vim:"vim",emacs:"emacs"},showPrintMargin:s,useSoftTabs:s,showInvisibles:s},a=[];a.push("<table><tr><th>Setting</th><th>Value</th></tr>");for(var l in t.defaultOptions)a.push("<tr><td>",o[l],"</td>"),a.push("<td>"),f(a,l,u[l],i.getOption(l)),a.push("</td></tr>");a.push("</table>"),e.innerHTML=a.join("");var c=function(e){var t=e.currentTarget;i.setOption(t.title,t.value)},h=function(e){var t=e.currentTarget;i.setOption(t.title,t.checked)},p=e.getElementsByTagName("select");for(var d=0;d<p.length;d++)p[d].onchange=c;var v=e.getElementsByTagName("input");for(var d=0;d<v.length;d++)v[d].onclick=h;var m=document.createElement("input");m.type="button",m.value="Hide",r.addListener(m,"click",function(){i.setDisplaySettings(!1)}),e.appendChild(m),e.hideButton=m}var r=e("../lib/event"),i=e("../lib/useragent"),s=e("../lib/net"),o=e("../ace");e("../theme/textmate"),n.exports=t=o;var u=function(e,t,n){var r=e.style[n];r||(window.getComputedStyle?r=window.getComputedStyle(e,"").getPropertyValue(n):r=e.currentStyle[n]);if(!r||r=="auto"||r=="intrinsic")r=t.style[n];return r};t.transformTextarea=function(e,n){var s,u=f(e,function(){return s.getValue()});e.style.display="none",u.style.background="white";var p=document.createElement("div");a(p,{top:"0px",left:"0px",right:"0px",bottom:"0px",border:"1px solid gray",position:"absolute"}),u.appendChild(p);var d=document.createElement("div");a(d,{position:"absolute",right:"0px",bottom:"0px",background:"red",cursor:"nw-resize",borderStyle:"solid",borderWidth:"9px 8px 10px 9px",width:"2px",borderColor:"lightblue gray gray lightblue",zIndex:101});var v=document.createElement("div"),m={top:"0px",left:"20%",right:"0px",bottom:"0px",position:"absolute",padding:"5px",zIndex:100,color:"white",display:"none",overflow:"auto",fontSize:"14px",boxShadow:"-5px 2px 3px gray"};i.isOldIE?m.backgroundColor="#333":m.backgroundColor="rgba(0, 0, 0, 0.6)",a(v,m),u.appendChild(v),n=n||t.defaultOptions;var g=o.edit(p);s=g.getSession(),s.setValue(e.value||e.innerHTML),g.focus(),u.appendChild(d),c(g,p,v,o,n,l),h(v,d,g);var y="";return r.addListener(d,"mousemove",function(e){var t=this.getBoundingClientRect(),n=e.clientX-t.left,r=e.clientY-t.top;n+r<(t.width+t.height)/2?(this.style.cursor="pointer",y="toggle"):(y="resize",this.style.cursor="nw-resize")}),r.addListener(d,"mousedown",function(e){if(y=="toggle"){g.setDisplaySettings();return}u.style.zIndex=1e5;var t=u.getBoundingClientRect(),n=t.width+t.left-e.clientX,i=t.height+t.top-e.clientY;r.capture(d,function(e){u.style.width=e.clientX-t.left+n+"px",u.style.height=e.clientY-t.top+i+"px",g.resize()},function(){})}),g},t.defaultOptions={mode:"javascript",theme:"textmate",wrap:"off",fontSize:"12px",showGutter:"false",keybindings:"ace",showPrintMargin:"false",useSoftTabs:"true",showInvisibles:"false"}});
2
- (function() {
3
- ace.require(["ace/ext/textarea"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-themelist.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/themelist",["require","exports","module","ace/lib/fixoldbrowsers"],function(e,t,n){"use strict";e("ace/lib/fixoldbrowsers");var r=[["Chrome"],["Clouds"],["Crimson Editor"],["Dawn"],["Dreamweaver"],["Eclipse"],["GitHub"],["Solarized Light"],["TextMate"],["Tomorrow"],["XCode"],["Kuroir"],["KatzenMilch"],["Ambiance","ambiance","dark"],["Chaos","chaos","dark"],["Clouds Midnight","clouds_midnight","dark"],["Cobalt","cobalt","dark"],["idle Fingers","idle_fingers","dark"],["krTheme","kr_theme","dark"],["Merbivore","merbivore","dark"],["Merbivore Soft","merbivore_soft","dark"],["Mono Industrial","mono_industrial","dark"],["Monokai","monokai","dark"],["Pastel on dark","pastel_on_dark","dark"],["Solarized Dark","solarized_dark","dark"],["Terminal","terminal","dark"],["Tomorrow Night","tomorrow_night","dark"],["Tomorrow Night Blue","tomorrow_night_blue","dark"],["Tomorrow Night Bright","tomorrow_night_bright","dark"],["Tomorrow Night 80s","tomorrow_night_eighties","dark"],["Twilight","twilight","dark"],["Vibrant Ink","vibrant_ink","dark"]];t.themesByName={},t.themes=r.map(function(e){var n=e[1]||e[0].replace(/ /g,"_").toLowerCase(),r={caption:e[0],theme:"ace/theme/"+n,isDark:e[2]=="dark",name:n};return t.themesByName[n]=r,r})});
2
- (function() {
3
- ace.require(["ace/ext/themelist"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/ext-whitespace.js DELETED
@@ -1,5 +0,0 @@
1
- ace.define("ace/ext/whitespace",["require","exports","module","ace/lib/lang"],function(e,t,n){"use strict";var r=e("../lib/lang");t.$detectIndentation=function(e,t){function c(e){var t=0;for(var r=e;r<n.length;r+=e)t+=n[r]||0;return t}var n=[],r=[],i=0,s=0,o=Math.min(e.length,1e3);for(var u=0;u<o;u++){var a=e[u];if(!/^\s*[^*+\-\s]/.test(a))continue;a[0]==" "&&i++;var f=a.match(/^ */)[0].length;if(f&&a[f]!=" "){var l=f-s;l>0&&!(s%l)&&!(f%l)&&(r[l]=(r[l]||0)+1),n[f]=(n[f]||0)+1}s=f;while(u<o&&a[a.length-1]=="\\")a=e[u++]}var h=r.reduce(function(e,t){return e+t},0),p={score:0,length:0},d=0;for(var u=1;u<12;u++){var v=c(u);u==1?(d=v,v=n[1]?.9:.8,n.length||(v=0)):v/=d,r[u]&&(v+=r[u]/h),v>p.score&&(p={score:v,length:u})}if(p.score&&p.score>1.4)var m=p.length;if(i>d+1)return{ch:" ",length:m};if(d>i+1)return{ch:" ",length:m}},t.detectIndentation=function(e){var n=e.getLines(0,1e3),r=t.$detectIndentation(n)||{};return r.ch&&e.setUseSoftTabs(r.ch==" "),r.length&&e.setTabSize(r.length),r},t.trimTrailingSpace=function(e,t){var n=e.getDocument(),r=n.getAllLines(),i=t?-1:0;for(var s=0,o=r.length;s<o;s++){var u=r[s],a=u.search(/\s+$/);a>i&&n.removeInLine(s,a,u.length)}},t.convertIndentation=function(e,t,n){var i=e.getTabString()[0],s=e.getTabSize();n||(n=s),t||(t=i);var o=t==" "?t:r.stringRepeat(t,n),u=e.doc,a=u.getAllLines(),f={},l={};for(var c=0,h=a.length;c<h;c++){var p=a[c],d=p.match(/^\s*/)[0];if(d){var v=e.$getStringScreenWidth(d)[0],m=Math.floor(v/s),g=v%s,y=f[m]||(f[m]=r.stringRepeat(o,m));y+=l[g]||(l[g]=r.stringRepeat(" ",g)),y!=d&&(u.removeInLine(c,0,d.length),u.insertInLine({row:c,column:0},y))}}e.setTabSize(n),e.setUseSoftTabs(t==" ")},t.$parseStringArg=function(e){var t={};/t/.test(e)?t.ch=" ":/s/.test(e)&&(t.ch=" ");var n=e.match(/\d+/);return n&&(t.length=parseInt(n[0],10)),t},t.$parseArg=function(e){return e?typeof e=="string"?t.$parseStringArg(e):typeof e.text=="string"?t.$parseStringArg(e.text):e:{}},t.commands=[{name:"detectIndentation",exec:function(e){t.detectIndentation(e.session)}},{name:"trimTrailingSpace",exec:function(e){t.trimTrailingSpace(e.session)}},{name:"convertIndentation",exec:function(e,n){var r=t.$parseArg(n);t.convertIndentation(e.session,r.ch,r.length)}},{name:"setIndentation",exec:function(e,n){var r=t.$parseArg(n);r.length&&e.session.setTabSize(r.length),r.ch&&e.session.setUseSoftTabs(r.ch==" ")}}]});
2
- (function() {
3
- ace.require(["ace/ext/whitespace"], function() {});
4
- })();
5
-
 
 
 
 
 
js/ace/src-min-noconflict/keybinding-emacs.js DELETED
@@ -1 +0,0 @@
1
- ace.define("ace/occur",["require","exports","module","ace/lib/oop","ace/range","ace/search","ace/edit_session","ace/search_highlight","ace/lib/dom"],function(e,t,n){"use strict";function a(){}var r=e("./lib/oop"),i=e("./range").Range,s=e("./search").Search,o=e("./edit_session").EditSession,u=e("./search_highlight").SearchHighlight;r.inherits(a,s),function(){this.enter=function(e,t){if(!t.needle)return!1;var n=e.getCursorPosition();this.displayOccurContent(e,t);var r=this.originalToOccurPosition(e.session,n);return e.moveCursorToPosition(r),!0},this.exit=function(e,t){var n=t.translatePosition&&e.getCursorPosition(),r=n&&this.occurToOriginalPosition(e.session,n);return this.displayOriginalContent(e),r&&e.moveCursorToPosition(r),!0},this.highlight=function(e,t){var n=e.$occurHighlight=e.$occurHighlight||e.addDynamicMarker(new u(null,"ace_occur-highlight","text"));n.setRegexp(t),e._emit("changeBackMarker")},this.displayOccurContent=function(e,t){this.$originalSession=e.session;var n=this.matchingLines(e.session,t),r=n.map(function(e){return e.content}),i=new o(r.join("\n"));i.$occur=this,i.$occurMatchingLines=n,e.setSession(i),this.$useEmacsStyleLineStart=this.$originalSession.$useEmacsStyleLineStart,i.$useEmacsStyleLineStart=this.$useEmacsStyleLineStart,this.highlight(i,t.re),i._emit("changeBackMarker")},this.displayOriginalContent=function(e){e.setSession(this.$originalSession),this.$originalSession.$useEmacsStyleLineStart=this.$useEmacsStyleLineStart},this.originalToOccurPosition=function(e,t){var n=e.$occurMatchingLines,r={row:0,column:0};if(!n)return r;for(var i=0;i<n.length;i++)if(n[i].row===t.row)return{row:i,column:t.column};return r},this.occurToOriginalPosition=function(e,t){var n=e.$occurMatchingLines;return!n||!n[t.row]?t:{row:n[t.row].row,column:t.column}},this.matchingLines=function(e,t){t=r.mixin({},t);if(!e||!t.needle)return[];var n=new s;return n.set(t),n.findAll(e).reduce(function(t,n){var r=n.start.row,i=t[t.length-1];return i&&i.row===r?t:t.concat({row:r,content:e.getLine(r)})},[])}}.call(a.prototype);var f=e("./lib/dom");f.importCssString(".ace_occur-highlight {\n border-radius: 4px;\n background-color: rgba(87, 255, 8, 0.25);\n position: absolute;\n z-index: 4;\n -moz-box-sizing: border-box;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n box-shadow: 0 0 4px rgb(91, 255, 50);\n}\n.ace_dark .ace_occur-highlight {\n background-color: rgb(80, 140, 85);\n box-shadow: 0 0 4px rgb(60, 120, 70);\n}\n","incremental-occur-highlighting"),t.Occur=a}),ace.define("ace/commands/occur_commands",["require","exports","module","ace/config","ace/occur","ace/keyboard/hash_handler","ace/lib/oop"],function(e,t,n){function f(){}var r=e("../config"),i=e("../occur").Occur,s={name:"occur",exec:function(e,t){var n=!!e.session.$occur,r=(new i).enter(e,t);r&&!n&&f.installIn(e)},readOnly:!0},o=[{name:"occurexit",bindKey:"esc|Ctrl-G",exec:function(e){var t=e.session.$occur;if(!t)return;t.exit(e,{}),e.session.$occur||f.uninstallFrom(e)},readOnly:!0},{name:"occuraccept",bindKey:"enter",exec:function(e){var t=e.session.$occur;if(!t)return;t.exit(e,{translatePosition:!0}),e.session.$occur||f.uninstallFrom(e)},readOnly:!0}],u=e("../keyboard/hash_handler").HashHandler,a=e("../lib/oop");a.inherits(f,u),function(){this.isOccurHandler=!0,this.attach=function(e){u.call(this,o,e.commands.platform),this.$editor=e};var e=this.handleKeyboard;this.handleKeyboard=function(t,n,r,i){var s=e.call(this,t,n,r,i);return s&&s.command?s:undefined}}.call(f.prototype),f.installIn=function(e){var t=new this;e.keyBinding.addKeyboardHandler(t),e.commands.addCommands(o)},f.uninstallFrom=function(e){e.commands.removeCommands(o);var t=e.getKeyboardHandler();t.isOccurHandler&&e.keyBinding.removeKeyboardHandler(t)},t.occurStartCommand=s}),ace.define("ace/commands/incremental_search_commands",["require","exports","module","ace/config","ace/lib/oop","ace/keyboard/hash_handler","ace/commands/occur_commands"],function(e,t,n){function u(e){this.$iSearch=e}var r=e("../config"),i=e("../lib/oop"),s=e("../keyboard/hash_handler").HashHandler,o=e("./occur_commands").occurStartCommand;t.iSearchStartCommands=[{name:"iSearch",bindKey:{win:"Ctrl-F",mac:"Command-F"},exec:function(e,t){r.loadModule(["core","ace/incremental_search"],function(n){var r=n.iSearch=n.iSearch||new n.IncrementalSearch;r.activate(e,t.backwards),t.jumpToFirstMatch&&r.next(t)})},readOnly:!0},{name:"iSearchBackwards",exec:function(e,t){e.execCommand("iSearch",{backwards:!0})},readOnly:!0},{name:"iSearchAndGo",bindKey:{win:"Ctrl-K",mac:"Command-G"},exec:function(e,t){e.execCommand("iSearch",{jumpToFirstMatch:!0,useCurrentOrPrevSearch:!0})},readOnly:!0},{name:"iSearchBackwardsAndGo",bindKey:{win:"Ctrl-Shift-K",mac:"Command-Shift-G"},exec:function(e){e.execCommand("iSearch",{jumpToFirstMatch:!0,backwards:!0,useCurrentOrPrevSearch:!0})},readOnly:!0}],t.iSearchCommands=[{name:"restartSearch",bindKey:{win:"Ctrl-F",mac:"Command-F"},exec:function(e){e.cancelSearch(!0)},readOnly:!0,isIncrementalSearchCommand:!0},{name:"searchForward",bindKey:{win:"Ctrl-S|Ctrl-K",mac:"Ctrl-S|Command-G"},exec:function(e,t){t.useCurrentOrPrevSearch=!0,e.next(t)},readOnly:!0,isIncrementalSearchCommand:!0},{name:"searchBackward",bindKey:{win:"Ctrl-R|Ctrl-Shift-K",mac:"Ctrl-R|Command-Shift-G"},exec:function(e,t){t.useCurrentOrPrevSearch=!0,t.backwards=!0,e.next(t)},readOnly:!0,isIncrementalSearchCommand:!0},{name:"extendSearchTerm",exec:function(e,t){e.addString(t)},readOnly:!0,isIncrementalSearchCommand:!0},{name:"extendSearchTermSpace",bindKey:"space",exec:function(e){e.addString(" ")},readOnly:!0,isIncrementalSearchCommand:!0},{name:"shrinkSearchTerm",bindKey:"backspace",exec:function(e){e.removeChar()},readOnly:!0,isIncrementalSearchCommand:!0},{name:"confirmSearch",bindKey:"return",exec:function(e){e.deactivate()},readOnly:!0,isIncrementalSearchCommand:!0},{name:"cancelSearch",bindKey:"esc|Ctrl-G",exec:function(e){e.deactivate(!0)},readOnly:!0,isIncrementalSearchCommand:!0},{name:"occurisearch",bindKey:"Ctrl-O",exec:function(e){var t=i.mixin({},e.$options);e.deactivate(),o.exec(e.$editor,t)},readOnly:!0,isIncrementalSearchCommand:!0},{name:"yankNextWord",bindKey:"Ctrl-w",exec:function(e){var t=e.$editor,n=t.selection.getRangeOfMovements(function(e){e.moveCursorWordRight()}),r=t.session.getTextRange(n);e.addString(r)},readOnly:!0,isIncrementalSearchCommand:!0},{name:"yankNextChar",bindKey:"Ctrl-Alt-y",exec:function(e){var t=e.$editor,n=t.selection.getRangeOfMovements(function(e){e.moveCursorRight()}),r=t.session.getTextRange(n);e.addString(r)},readOnly:!0,isIncrementalSearchCommand:!0},{name:"recenterTopBottom",bindKey:"Ctrl-l",exec:function(e){e.$editor.execCommand("recenterTopBottom")},readOnly:!0,isIncrementalSearchCommand:!0},{name:"selectAllMatches",bindKey:"Ctrl-space",exec:function(e){var t=e.$editor,n=t.session.$isearchHighlight,r=n&&n.cache?n.cache.reduce(function(e,t){return e.concat(t?t:[])},[]):[];e.deactivate(!1),r.forEach(t.selection.addRange.bind(t.selection))},readOnly:!0,isIncrementalSearchCommand:!0},{name:"searchAsRegExp",bindKey:"Alt-r",exec:function(e){e.convertNeedleToRegExp()},readOnly:!0,isIncrementalSearchCommand:!0}],i.inherits(u,s),function(){this.attach=function(e){var n=this.$iSearch;s.call(this,t.iSearchCommands,e.commands.platform),this.$commandExecHandler=e.commands.addEventListener("exec",function(e){return e.command.isIncrementalSearchCommand?(e.stopPropagation(),e.preventDefault(),e.command.exec(n,e.args||{})):undefined})},this.detach=function(e){if(!this.$commandExecHandler)return;e.commands.removeEventListener("exec",this.$commandExecHandler),delete this.$commandExecHandler};var e=this.handleKeyboard;this.handleKeyboard=function(t,n,r,i){if((n===1||n===8)&&r==="v"||n===1&&r==="y")return null;var s=e.call(this,t,n,r,i);if(s.command)return s;if(n==-1){var o=this.commands.extendSearchTerm;if(o)return{command:o,args:r}}return{command:"null",passEvent:n==0||n==4}}}.call(u.prototype),t.IncrementalSearchKeyboardHandler=u}),ace.define("ace/incremental_search",["require","exports","module","ace/lib/oop","ace/range","ace/search","ace/search_highlight","ace/commands/incremental_search_commands","ace/lib/dom","ace/commands/command_manager","ace/editor","ace/config"],function(e,t,n){"use strict";function f(){this.$options={wrap:!1,skipCurrent:!1},this.$keyboardHandler=new a(this)}function l(e){return e instanceof RegExp}function c(e){var t=String(e),n=t.indexOf("/"),r=t.lastIndexOf("/");return{expression:t.slice(n+1,r),flags:t.slice(r+1)}}function h(e,t){try{return new RegExp(e,t)}catch(n){return e}}function p(e){return h(e.expression,e.flags)}var r=e("./lib/oop"),i=e("./range").Range,s=e("./search").Search,o=e("./search_highlight").SearchHighlight,u=e("./commands/incremental_search_commands"),a=u.IncrementalSearchKeyboardHandler;r.inherits(f,s),function(){this.activate=function(e,t){this.$editor=e,this.$startPos=this.$currentPos=e.getCursorPosition(),this.$options.needle="",this.$options.backwards=t,e.keyBinding.addKeyboardHandler(this.$keyboardHandler),this.$originalEditorOnPaste=e.onPaste,e.onPaste=this.onPaste.bind(this),this.$mousedownHandler=e.addEventListener("mousedown",this.onMouseDown.bind(this)),this.selectionFix(e),this.statusMessage(!0)},this.deactivate=function(e){this.cancelSearch(e);var t=this.$editor;t.keyBinding.removeKeyboardHandler(this.$keyboardHandler),this.$mousedownHandler&&(t.removeEventListener("mousedown",this.$mousedownHandler),delete this.$mousedownHandler),t.onPaste=this.$originalEditorOnPaste,this.message("")},this.selectionFix=function(e){e.selection.isEmpty()&&!e.session.$emacsMark&&e.clearSelection()},this.highlight=function(e){var t=this.$editor.session,n=t.$isearchHighlight=t.$isearchHighlight||t.addDynamicMarker(new o(null,"ace_isearch-result","text"));n.setRegexp(e),t._emit("changeBackMarker")},this.cancelSearch=function(e){var t=this.$editor;return this.$prevNeedle=this.$options.needle,this.$options.needle="",e?(t.moveCursorToPosition(this.$startPos),this.$currentPos=this.$startPos):t.pushEmacsMark&&t.pushEmacsMark(this.$startPos,!1),this.highlight(null),i.fromPoints(this.$currentPos,this.$currentPos)},this.highlightAndFindWithNeedle=function(e,t){if(!this.$editor)return null;var n=this.$options;t&&(n.needle=t.call(this,n.needle||"")||"");if(n.needle.length===0)return this.statusMessage(!0),this.cancelSearch(!0);n.start=this.$currentPos;var r=this.$editor.session,s=this.find(r),o=this.$editor.emacsMark?!!this.$editor.emacsMark():!this.$editor.selection.isEmpty();return s&&(n.backwards&&(s=i.fromPoints(s.end,s.start)),this.$editor.selection.setRange(i.fromPoints(o?this.$startPos:s.end,s.end)),e&&(this.$currentPos=s.end),this.highlight(n.re)),this.statusMessage(s),s},this.addString=function(e){return this.highlightAndFindWithNeedle(!1,function(t){if(!l(t))return t+e;var n=c(t);return n.expression+=e,p(n)})},this.removeChar=function(e){return this.highlightAndFindWithNeedle(!1,function(e){if(!l(e))return e.substring(0,e.length-1);var t=c(e);return t.expression=t.expression.substring(0,t.expression.length-1),p(t)})},this.next=function(e){return e=e||{},this.$options.backwards=!!e.backwards,this.$currentPos=this.$editor.getCursorPosition(),this.highlightAndFindWithNeedle(!0,function(t){return e.useCurrentOrPrevSearch&&t.length===0?this.$prevNeedle||"":t})},this.onMouseDown=function(e){return this.deactivate(),!0},this.onPaste=function(e){this.addString(e)},this.convertNeedleToRegExp=function(){return this.highlightAndFindWithNeedle(!1,function(e){return l(e)?e:h(e,"ig")})},this.convertNeedleToString=function(){return this.highlightAndFindWithNeedle(!1,function(e){return l(e)?c(e).expression:e})},this.statusMessage=function(e){var t=this.$options,n="";n+=t.backwards?"reverse-":"",n+="isearch: "+t.needle,n+=e?"":" (not found)",this.message(n)},this.message=function(e){this.$editor.showCommandLine?(this.$editor.showCommandLine(e),this.$editor.focus()):console.log(e)}}.call(f.prototype),t.IncrementalSearch=f;var d=e("./lib/dom");d.importCssString&&d.importCssString(".ace_marker-layer .ace_isearch-result { position: absolute; z-index: 6; -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box;}div.ace_isearch-result { border-radius: 4px; background-color: rgba(255, 200, 0, 0.5); box-shadow: 0 0 4px rgb(255, 200, 0);}.ace_dark div.ace_isearch-result { background-color: rgb(100, 110, 160); box-shadow: 0 0 4px rgb(80, 90, 140);}","incremental-search-highlighting");var v=e("./commands/command_manager");(function(){this.setupIncrementalSearch=function(e,t){if(this.usesIncrementalSearch==t)return;this.usesIncrementalSearch=t;var n=u.iSearchStartCommands,r=t?"addCommands":"removeCommands";this[r](n)}}).call(v.CommandManager.prototype);var m=e("./editor").Editor;e("./config").defineOptions(m.prototype,"editor",{useIncrementalSearch:{set:function(e){this.keyBinding.$handlers.forEach(function(t){t.setupIncrementalSearch&&t.setupIncrementalSearch(this,e)}),this._emit("incrementalSearchSettingChanged",{isEnabled:e})}}})}),ace.define("ace/keyboard/emacs",["require","exports","module","ace/lib/dom","ace/incremental_search","ace/commands/incremental_search_commands","ace/keyboard/hash_handler","ace/lib/keys"],function(e,t,n){"use strict";var r=e("../lib/dom");e("../incremental_search");var i=e("../commands/incremental_search_commands"),s=function(e,t){var n=this.scroller.getBoundingClientRect(),r=Math.floor((e+this.scrollLeft-n.left-this.$padding)/this.characterWidth),i=Math.floor((t+this.scrollTop-n.top)/this.lineHeight);return this.session.screenToDocumentPosition(i,r)},o=e("./hash_handler").HashHandler;t.handler=new o,t.handler.isEmacs=!0,t.handler.$id="ace/keyboard/emacs";var u=!1,a,f;t.handler.attach=function(e){u||(u=!0,r.importCssString(" .emacs-mode .ace_cursor{ border: 1px rgba(50,250,50,0.8) solid!important; -moz-box-sizing: border-box!important; -webkit-box-sizing: border-box!important; box-sizing: border-box!important; background-color: rgba(0,250,0,0.9); opacity: 0.5; } .emacs-mode .ace_hidden-cursors .ace_cursor{ opacity: 1; background-color: transparent; } .emacs-mode .ace_overwrite-cursors .ace_cursor { opacity: 1; background-color: transparent; border-width: 0 0 2px 2px !important; } .emacs-mode .ace_text-layer { z-index: 4 } .emacs-mode .ace_cursor-layer { z-index: 2 }","emacsMode")),a=e.session.$selectLongWords,e.session.$selectLongWords=!0,f=e.session.$useEmacsStyleLineStart,e.session.$useEmacsStyleLineStart=!0,e.session.$emacsMark=null,e.session.$emacsMarkRing=e.session.$emacsMarkRing||[],e.emacsMark=function(){return this.session.$emacsMark},e.setEmacsMark=function(e){this.session.$emacsMark=e},e.pushEmacsMark=function(e,t){var n=this.session.$emacsMark;n&&this.session.$emacsMarkRing.push(n),!e||t?this.setEmacsMark(e):this.session.$emacsMarkRing.push(e)},e.popEmacsMark=function(){var e=this.emacsMark();return e?(this.setEmacsMark(null),e):this.session.$emacsMarkRing.pop()},e.getLastEmacsMark=function(e){return this.session.$emacsMark||this.session.$emacsMarkRing.slice(-1)[0]},e.emacsMarkForSelection=function(e){var t=this.selection,n=this.multiSelect?this.multiSelect.getAllRanges().length:1,r=t.index||0,i=this.session.$emacsMarkRing,s=i.length-(n-r),o=i[s]||t.anchor;return e&&i.splice(s,1,"row"in e&&"column"in e?e:undefined),o},e.on("click",c),e.on("changeSession",l),e.renderer.screenToTextCoordinates=s,e.setStyle("emacs-mode"),e.commands.addCommands(v),t.handler.platform=e.commands.platform,e.$emacsModeHandler=this,e.addEventListener("copy",this.onCopy),e.addEventListener("paste",this.onPaste)},t.handler.detach=function(e){delete e.renderer.screenToTextCoordinates,e.session.$selectLongWords=a,e.session.$useEmacsStyleLineStart=f,e.removeEventListener("click",c),e.removeEventListener("changeSession",l),e.unsetStyle("emacs-mode"),e.commands.removeCommands(v),e.removeEventListener("copy",this.onCopy),e.removeEventListener("paste",this.onPaste),e.$emacsModeHandler=null};var l=function(e){e.oldSession&&(e.oldSession.$selectLongWords=a,e.oldSession.$useEmacsStyleLineStart=f),a=e.session.$selectLongWords,e.session.$selectLongWords=!0,f=e.session.$useEmacsStyleLineStart,e.session.$useEmacsStyleLineStart=!0,e.session.hasOwnProperty("$emacsMark")||(e.session.$emacsMark=null),e.session.hasOwnProperty("$emacsMarkRing")||(e.session.$emacsMarkRing=[])},c=function(e){e.editor.session.$emacsMark=null},h=e("../lib/keys").KEY_MODS,p={C:"ctrl",S:"shift",M:"alt",CMD:"command"},d=["C-S-M-CMD","S-M-CMD","C-M-CMD","C-S-CMD","C-S-M","M-CMD","S-CMD","S-M","C-CMD","C-M","C-S","CMD","M","S","C"];d.forEach(function(e){var t=0;e.split("-").forEach(function(e){t|=h[p[e]]}),p[t]=e.toLowerCase()+"-"}),t.handler.onCopy=function(e,n){if(n.$handlesEmacsOnCopy)return;n.$handlesEmacsOnCopy=!0,t.handler.commands.killRingSave.exec(n),n.$handlesEmacsOnCopy=!1},t.handler.onPaste=function(e,t){t.pushEmacsMark(t.getCursorPosition())},t.handler.bindKey=function(e,t){typeof e=="object"&&(e=e[this.platform]);if(!e)return;var n=this.commandKeyBinding;e.split("|").forEach(function(e){e=e.toLowerCase(),n[e]=t;var r=e.split(" ").slice(0,-1);r.reduce(function(e,t,n){var r=e[n-1]?e[n-1]+" ":"";return e.concat([r+t])},[]).forEach(function(e){n[e]||(n[e]="null")})},this)},t.handler.getStatusText=function(e,t){var n="";return t.count&&(n+=t.count),t.keyChain&&(n+=" "+t.keyChain),n},t.handler.handleKeyboard=function(e,t,n,r){if(r===-1)return undefined;var i=e.editor;i._signal("changeStatus");if(t==-1){i.pushEmacsMark();if(e.count){var s=(new Array(e.count+1)).join(n);return e.count=null,{command:"insertstring",args:s}}}var o=p[t];if(o=="c-"||e.count){var u=parseInt(n[n.length-1]);if(typeof u=="number"&&!isNaN(u))return e.count=Math.max(e.count,0)||0,e.count=10*e.count+u,{command:"null"}}o&&(n=o+n),e.keyChain&&(n=e.keyChain+=" "+n);var a=this.commandKeyBinding[n];e.keyChain=a=="null"?n:"";if(!a)return undefined;if(a==="null")return{command:"null"};if(a==="universalArgument")return e.count=-4,{command:"null"};var f;typeof a!="string"&&(f=a.args,a.command&&(a=a.command),a==="goorselect"&&(a=i.emacsMark()?f[1]:f[0],f=null));if(typeof a=="string"){(a==="insertstring"||a==="splitline"||a==="togglecomment")&&i.pushEmacsMark(),a=this.commands[a]||i.commands.commands[a];if(!a)return undefined}!a.readOnly&&!a.isYank&&(e.lastCommand=null),!a.readOnly&&i.emacsMark()&&i.setEmacsMark(null);if(e.count){var u=e.count;e.count=0;if(!a||!a.handlesCount)return{args:f,command:{exec:function(e,t){for(var n=0;n<u;n++)a.exec(e,t)},multiSelectAction:a.multiSelectAction}};f||(f={}),typeof f=="object"&&(f.count=u)}return{command:a,args:f}},t.emacsKeys={"Up|C-p":{command:"goorselect",args:["golineup","selectup"]},"Down|C-n":{command:"goorselect",args:["golinedown","selectdown"]},"Left|C-b":{command:"goorselect",args:["gotoleft","selectleft"]},"Right|C-f":{command:"goorselect",args:["gotoright","selectright"]},"C-Left|M-b":{command:"goorselect",args:["gotowordleft","selectwordleft"]},"C-Right|M-f":{command:"goorselect",args:["gotowordright","selectwordright"]},"Home|C-a":{command:"goorselect",args:["gotolinestart","selecttolinestart"]},"End|C-e":{command:"goorselect",args:["gotolineend","selecttolineend"]},"C-Home|S-M-,":{command:"goorselect",args:["gotostart","selecttostart"]},"C-End|S-M-.":{command:"goorselect",args:["gotoend","selecttoend"]},"S-Up|S-C-p":"selectup","S-Down|S-C-n":"selectdown","S-Left|S-C-b":"selectleft","S-Right|S-C-f":"selectright","S-C-Left|S-M-b":"selectwordleft","S-C-Right|S-M-f":"selectwordright","S-Home|S-C-a":"selecttolinestart","S-End|S-C-e":"selecttolineend","S-C-Home":"selecttostart","S-C-End":"selecttoend","C-l":"recenterTopBottom","M-s":"centerselection","M-g":"gotoline","C-x C-p":"selectall","C-Down":{command:"goorselect",args:["gotopagedown","selectpagedown"]},"C-Up":{command:"goorselect",args:["gotopageup","selectpageup"]},"PageDown|C-v":{command:"goorselect",args:["gotopagedown","selectpagedown"]},"PageUp|M-v":{command:"goorselect",args:["gotopageup","selectpageup"]},"S-C-Down":"selectpagedown","S-C-Up":"selectpageup","C-s":"iSearch","C-r":"iSearchBackwards","M-C-s":"findnext","M-C-r":"findprevious","S-M-5":"replace",Backspace:"backspace","Delete|C-d":"del","Return|C-m":{command:"insertstring",args:"\n"},"C-o":"splitline","M-d|C-Delete":{command:"killWord",args:"right"},"C-Backspace|M-Backspace|M-Delete":{command:"killWord",args:"left"},"C-k":"killLine","C-y|S-Delete":"yank","M-y":"yankRotate","C-g":"keyboardQuit","C-w|C-S-W":"killRegion","M-w":"killRingSave","C-Space":"setMark","C-x C-x":"exchangePointAndMark","C-t":"transposeletters","M-u":"touppercase","M-l":"tolowercase","M-/":"autocomplete","C-u":"universalArgument","M-;":"togglecomment","C-/|C-x u|S-C--|C-z":"undo","S-C-/|S-C-x u|C--|S-C-z":"redo","C-x r":"selectRectangularRegion","M-x":{command:"focusCommandLine",args:"M-x "}},t.handler.bindKeys(t.emacsKeys),t.handler.addCommands({recenterTopBottom:function(e){var t=e.renderer,n=t.$cursorLayer.getPixelPosition(),r=t.$size.scrollerHeight-t.lineHeight,i=t.scrollTop;Math.abs(n.top-i)<2?i=n.top-r:Math.abs(n.top-i-r*.5)<2?i=n.top:i=n.top-r*.5,e.session.setScrollTop(i)},selectRectangularRegion:function(e){e.multiSelect.toggleBlockSelection()},setMark:{exec:function(e,t){function u(){var t=e.popEmacsMark();t&&e.moveCursorToPosition(t)}if(t&&t.count){e.inMultiSelectMode?e.forEachSelection(u):u(),u();return}var n=e.emacsMark(),r=e.selection.getAllRanges(),i=r.map(function(e){return{row:e.start.row,column:e.start.column}}),s=!0,o=r.every(function(e){return e.isEmpty()});if(s&&(n||!o)){e.inMultiSelectMode?e.forEachSelection({exec:e.clearSelection.bind(e)}):e.clearSelection(),n&&e.pushEmacsMark(null);return}if(!n){i.forEach(function(t){e.pushEmacsMark(t)}),e.setEmacsMark(i[i.length-1]);return}},readOnly:!0,handlesCount:!0},exchangePointAndMark:{exec:function(t,n){var r=t.selection;if(!n.count&&!r.isEmpty()){r.setSelectionRange(r.getRange(),!r.isBackwards());return}if(n.count){var i={row:r.lead.row,column:r.lead.column};r.clearSelection(),r.moveCursorToPosition(t.emacsMarkForSelection(i))}else r.selectToPosition(t.emacsMarkForSelection())},readOnly:!0,handlesCount:!0,multiSelectAction:"forEach"},killWord:{exec:function(e,n){e.clearSelection(),n=="left"?e.selection.selectWordLeft():e.selection.selectWordRight();var r=e.getSelectionRange(),i=e.session.getTextRange(r);t.killRing.add(i),e.session.remove(r),e.clearSelection()},multiSelectAction:"forEach"},killLine:function(e){e.pushEmacsMark(null);var n=e.getCursorPosition();n.column===0&&e.session.doc.getLine(n.row).length===0?e.selection.selectLine():(e.clearSelection(),e.selection.selectLineEnd());var r=e.getSelectionRange(),i=e.session.getTextRange(r);t.killRing.add(i),e.session.remove(r),e.clearSelection()},yank:function(e){e.onPaste(t.killRing.get()||""),e.keyBinding.$data.lastCommand="yank"},yankRotate:function(e){if(e.keyBinding.$data.lastCommand!="yank")return;e.undo(),e.session.$emacsMarkRing.pop(),e.onPaste(t.killRing.rotate()),e.keyBinding.$data.lastCommand="yank"},killRegion:{exec:function(e){t.killRing.add(e.getCopyText()),e.commands.byName.cut.exec(e)},readOnly:!0,multiSelectAction:"forEach"},killRingSave:{exec:function(e){e.$handlesEmacsOnCopy=!0;var n=e.session.$emacsMarkRing.slice(),r=[];t.killRing.add(e.getCopyText()),setTimeout(function(){function t(){var t=e.selection,n=t.getRange(),i=t.isBackwards()?n.end:n.start;r.push({row:i.row,column:i.column}),t.clearSelection()}e.$handlesEmacsOnCopy=!1,e.inMultiSelectMode?e.forEachSelection({exec:t}):t(),e.session.$emacsMarkRing=n.concat(r.reverse())},0)},readOnly:!0},keyboardQuit:function(e){e.selection.clearSelection(),e.setEmacsMark(null),e.keyBinding.$data.count=null},focusCommandLine:function(e,t){e.showCommandLine&&e.showCommandLine(t)}}),t.handler.addCommands(i.iSearchStartCommands);var v=t.handler.commands;v.yank.isYank=!0,v.yankRotate.isYank=!0,t.killRing={$data:[],add:function(e){e&&this.$data.push(e),this.$data.length>30&&this.$data.shift()},get:function(e){return e=e||1,this.$data.slice(this.$data.length-e,this.$data.length).reverse().join("\n")},pop:function(){return this.$data.length>1&&this.$data.pop(),this.get()},rotate:function(){return this.$data.unshift(this.$data.pop()),this.get()}}})
 
js/ace/src-min-noconflict/keybinding-vim.js DELETED
@@ -1 +0,0 @@
1
- ace.define("ace/keyboard/vim",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/dom","ace/lib/oop","ace/lib/keys","ace/lib/event","ace/search","ace/lib/useragent","ace/search_highlight","ace/commands/multi_select_commands","ace/multi_select"],function(e,t,n){"use strict";function r(){function t(e){return typeof e!="object"?e+"":"line"in e?e.line+":"+e.ch:"anchor"in e?t(e.anchor)+"->"+t(e.head):Array.isArray(e)?"["+e.map(function(e){return t(e)})+"]":JSON.stringify(e)}var e="";for(var n=0;n<arguments.length;n++){var r=arguments[n],i=t(r);e+=i+" "}console.log(e)}function v(e){return{row:e.line,column:e.ch}}function m(e){return new b(e.row,e.column)}function T(e){var t=e.keyCode;if(w.indexOf(t)!=-1)return;var n=e.ctrlKey||e.metaKey,r=d.keyNames[t];r=E[r]||r;var i="";e.ctrlKey&&(i+="C-"),e.altKey&&(i+="A-");if(S&&e.metaKey||!n&&e.shiftKey&&r.length<2)return;return e.shiftKey&&!/^[A-Za-z]$/.test(r)&&(i+="S-"),r.length==1&&(r=r.toLowerCase()),i+=r,i.length>1&&(i="<"+i+">"),i}function N(e,t){var n=T(t);if(!n)return;d.signal(e,"vim-keypress",n),d.Vim.handleKey(e,n,"user")&&d.e_stop(t)}function C(e,t){var n=t.charCode||t.keyCode;if(t.ctrlKey||t.metaKey||t.altKey||t.shiftKey&&n<32)return;var r=String.fromCharCode(n);d.signal(e,"vim-keypress",r),d.Vim.handleKey(e,r,"user")&&d.e_stop(t)}function k(e){e.setOption("disableInput",!0),e.setOption("showCursorWhenSelecting",!1),d.signal(e,"vim-mode-change",{mode:"normal"}),e.on("cursorActivity",Rn),tt(e),d.on(e.getInputField(),"paste",M(e)),e.on("keypress",C),e.on("keydown",N)}function L(e){e.setOption("disableInput",!1),e.off("cursorActivity",Rn),d.off(e.getInputField(),"paste",M(e)),e.state.vim=null,e.off("keypress",C),e.off("keydown",N)}function A(e,t){this==d.keyMap.vim&&d.rmClass(e.getWrapperElement(),"cm-fat-cursor"),(!t||t.attach!=O)&&L(e,!1)}function O(e,t){this==d.keyMap.vim&&d.addClass(e.getWrapperElement(),"cm-fat-cursor"),(!t||t.attach!=O)&&k(e)}function M(e){var t=e.state.vim;return t.onPasteFn||(t.onPasteFn=function(){t.insertMode||(e.setCursor(yt(e.getCursor(),0,1)),vt.enterInsertMode(e,{},t))}),t.onPasteFn}function H(e,t){var n=[];for(var r=e;r<e+t;r++)n.push(String.fromCharCode(r));return n}function R(e,t){return t>=e.firstLine()&&t<=e.lastLine()}function U(e){return/^[a-z]$/.test(e)}function z(e){return"()[]{}".indexOf(e)!=-1}function W(e){return _.test(e)}function X(e){return/^[A-Z]$/.test(e)}function V(e){return/^\s*$/.test(e)}function $(e,t){for(var n=0;n<t.length;n++)if(t[n]==e)return!0;return!1}function K(e,t,n){if(t===undefined)throw Error("defaultValue is required");n||(n="string");var r=e;typeof e=="string"?r={type:n,defaultValue:t}:e=r.name,J[e]=r,Q(e,t)}function Q(e,t,n){var r=J[e];if(!r)throw Error("Unknown option: "+e);if(r.type=="boolean"){if(t&&t!==!0)throw Error("Invalid argument: "+e+"="+t);t!==!1&&(t=!0)}r.value=t,r.set&&r.set(t,n)}function G(e){var t=J[e];if(!t)throw Error("Unknown option: "+e);return t.value}function et(){this.latestRegister=undefined,this.isPlaying=!1,this.isRecording=!1,this.replaySearchQueries=[],this.onRecordingDone=undefined,this.lastInsertModeChanges=Z()}function tt(e){return e.state.vim||(e.state.vim={inputState:new ot,lastEditInputState:undefined,lastEditActionCommand:undefined,lastHPos:-1,lastHSPos:-1,lastMotion:null,marks:{},fakeCursor:null,insertMode:!1,insertModeRepeat:undefined,visualMode:!1,visualLine:!1,visualBlock:!1,lastSelection:null,lastPastedText:null,sel:{}}),e.state.vim}function rt(){nt={searchQuery:null,searchIsReversed:!1,lastSubstituteReplacePart:undefined,jumpList:Y(),macroModeState:new et,lastChararacterSearch:{increment:0,forward:!0,selectedCharacter:""},registerController:new ft({}),searchHistoryController:new lt({}),exCommandHistoryController:new lt({})};for(var e in J){var t=J[e];t.value=t.defaultValue}}function ot(){this.prefixRepeat=[],this.motionRepeat=[],this.operator=null,this.operatorArgs=null,this.motion=null,this.motionArgs=null,this.keyBuffer=[],this.registerName=null}function ut(e,t){e.state.vim.inputState=new ot,d.signal(e,"vim-command-done",t)}function at(e,t,n){this.clear(),this.keyBuffer=[e||""],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!!t,this.blockwise=!!n}function ft(e){this.registers=e,this.unnamedRegister=e['"']=new at,e["."]=new at,e[":"]=new at,e["/"]=new at}function lt(){this.historyBuffer=[],this.iterator,this.initialPrefix=null}function pt(e,t){var n=[];for(var r=0;r<t;r++)n.push(e);return n}function mt(e,t,n){var r=Math.min(Math.max(e.firstLine(),t.line),e.lastLine()),i=Ot(e,r)-1;i=n?i+1:i;var s=Math.min(Math.max(0,t.ch),i);return b(r,s)}function gt(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function yt(e,t,n){return typeof t=="object"&&(n=t.ch,t=t.line),b(e.line+t,e.ch+n)}function bt(e,t){return{line:t.line-e.line,ch:t.line-e.line}}function wt(e,t,n,r){var i,s=[],o=[];for(var u=0;u<t.length;u++){var a=t[u];if(n=="insert"&&a.context!="insert"||a.context&&a.context!=n||r.operator&&a.type=="action"||!(i=Et(e,a.keys)))continue;i=="partial"&&s.push(a),i=="full"&&o.push(a)}return{partial:s.length&&s,full:o.length&&o}}function Et(e,t){if(t.slice(-11)=="<character>"){var n=t.length-11,r=e.slice(0,n),i=t.slice(0,n);return r==i&&e.length>n?"full":i.indexOf(r)==0?"partial":!1}return e==t?"full":t.indexOf(e)==0?"partial":!1}function St(e){var t=/^.*(<[\w\-]+>)$/.exec(e),n=t?t[1]:e.slice(-1);if(n.length>1)switch(n){case"<CR>":n="\n";break;case"<Space>":n=" ";break;default:}return n}function xt(e,t,n){return function(){for(var r=0;r<n;r++)t(e)}}function Tt(e){return b(e.line,e.ch)}function Nt(e,t){return e.ch==t.ch&&e.line==t.line}function Ct(e,t){return e.line<t.line?!0:e.line==t.line&&e.ch<t.ch?!0:!1}function kt(e,t){return arguments.length>2&&(t=kt.apply(undefined,Array.prototype.slice.call(arguments,1))),Ct(e,t)?e:t}function Lt(e,t){return arguments.length>2&&(t=Lt.apply(undefined,Array.prototype.slice.call(arguments,1))),Ct(e,t)?t:e}function At(e,t,n){var r=Ct(e,t),i=Ct(t,n);return r&&i}function Ot(e,t){return e.getLine(t).length}function Mt(e){return e.split("").reverse().join("")}function _t(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Dt(e){return e.replace(/([.?*+$\[\]\/\\(){}|\-])/g,"\\$1")}function Pt(e,t,n){var r=Ot(e,t),i=(new Array(n-r+1)).join(" ");e.setCursor(b(t,r)),e.replaceRange(i,e.getCursor())}function Ht(e,t){var n=[],r=e.listSelections(),i=Tt(e.clipPos(t)),s=!Nt(t,i),o=e.getCursor("head"),u=jt(r,o),a=Nt(r[u].head,r[u].anchor),f=r.length-1,l=f-u>u?f:0,c=r[l].anchor,h=Math.min(c.line,i.line),p=Math.max(c.line,i.line),d=c.ch,v=i.ch,m=r[l].head.ch-d,g=v-d;m>0&&g<=0?(d++,s||v--):m<0&&g>=0?(d--,a||v++):m<0&&g==-1&&(d--,v++);for(var y=h;y<=p;y++){var w={anchor:new b(y,d),head:new b(y,v)};n.push(w)}return u=i.line==p?n.length-1:0,e.setSelections(n),t.ch=v,c.ch=d,c}function Bt(e,t,n){var r=[];for(var i=0;i<n;i++){var s=yt(t,i,0);r.push({anchor:s,head:s})}e.setSelections(r,0)}function jt(e,t,n){for(var r=0;r<e.length;r++){var i=n!="head"&&Nt(e[r].anchor,t),s=n!="anchor"&&Nt(e[r].head,t);if(i||s)return r}return-1}function Ft(e,t){var n=t.lastSelection,r=function(){var t=e.listSelections(),n=t[0],r=t[t.length-1],i=Ct(n.anchor,n.head)?n.anchor:n.head,s=Ct(r.anchor,r.head)?r.head:r.anchor;return[i,s]},i=function(){var t=e.getCursor(),r=e.getCursor(),i=n.visualBlock;if(i){var s=i.width,o=i.height;r=b(t.line+o,t.ch+s);var u=[];for(var a=t.line;a<r.line;a++){var f=b(a,t.ch),l=b(a,r.ch),c={anchor:f,head:l};u.push(c)}e.setSelections(u)}else{var h=n.anchorMark.find(),p=n.headMark.find(),d=p.line-h.line,v=p.ch-h.ch;r={line:r.line+d,ch:d?r.ch:v+r.ch},n.visualLine&&(t=b(t.line,0),r=b(r.line,Ot(e,r.line))),e.setSelection(t,r)}return[t,r]};return t.visualMode?r():i()}function It(e,t){var n=t.sel.anchor,r=t.sel.head;t.lastPastedText&&(r=e.posFromIndex(e.indexFromPos(n)+t.lastPastedText.length),t.lastPastedText=null),t.lastSelection={anchorMark:e.setBookmark(n),headMark:e.setBookmark(r),anchor:Tt(n),head:Tt(r),visualMode:t.visualMode,visualLine:t.visualLine,visualBlock:t.visualBlock}}function qt(e,t,n){var r=e.state.vim.sel,i=r.head,s=r.anchor,o;return Ct(n,t)&&(o=n,n=t,t=o),Ct(i,s)?(i=kt(t,i),s=Lt(s,n)):(s=kt(t,s),i=Lt(i,n),i=yt(i,0,-1),i.ch==-1&&i.line!=e.firstLine()&&(i=b(i.line-1,Ot(e,i.line-1)))),[s,i]}function Rt(e,t,n){var r=e.state.vim;t=t||r.sel;var n=n||r.visualLine?"line":r.visualBlock?"block":"char",i=Ut(e,t,n);e.setSelections(i.ranges,i.primary),Un(e)}function Ut(e,t,n,r){var i=Tt(t.head),s=Tt(t.anchor);if(n=="char"){var o=!r&&!Ct(t.head,t.anchor)?1:0,u=Ct(t.head,t.anchor)?1:0;return i=yt(t.head,0,o),s=yt(t.anchor,0,u),{ranges:[{anchor:s,head:i}],primary:0}}if(n=="line"){if(!Ct(t.head,t.anchor)){s.ch=0;var a=e.lastLine();i.line>a&&(i.line=a),i.ch=Ot(e,i.line)}else i.ch=0,s.ch=Ot(e,s.line);return{ranges:[{anchor:s,head:i}],primary:0}}if(n=="block"){var f=Math.min(s.line,i.line),l=Math.min(s.ch,i.ch),c=Math.max(s.line,i.line),h=Math.max(s.ch,i.ch)+1,p=c-f+1,d=i.line==f?0:p-1,v=[];for(var m=0;m<p;m++)v.push({anchor:b(f+m,l),head:b(f+m,h)});return{ranges:v,primary:d}}}function zt(e){var t=e.getCursor("head");return e.getSelection().length==1&&(t=kt(t,e.getCursor("anchor"))),t}function Wt(e,t){var n=e.state.vim;t!==!1&&e.setCursor(mt(e,n.sel.head)),It(e,n),n.visualMode=!1,n.visualLine=!1,n.visualBlock=!1,d.signal(e,"vim-mode-change",{mode:"normal"}),n.fakeCursor&&n.fakeCursor.clear()}function Xt(e,t,n){var r=e.getRange(t,n);if(/\n\s*$/.test(r)){var i=r.split("\n");i.pop();var s;for(var s=i.pop();i.length>0&&s&&V(s);s=i.pop())n.line--,n.ch=0;s?(n.line--,n.ch=Ot(e,n.line)):n.ch=0}}function Vt(e,t,n){t.ch=0,n.ch=0,n.line++}function $t(e){if(!e)return 0;var t=e.search(/\S/);return t==-1?e.length:t}function Jt(e,t,n,r,i){var s=zt(e),o=e.getLine(s.line),u=s.ch,a=o.substring(u),f;i?f=a.search(/\w/):f=a.search(/\S/);if(f==-1)return null;u+=f,a=o.substring(u);var l=o.substring(0,u),c;r?c=/^\S+/:/\w/.test(o.charAt(u))?c=/^\w+/:c=/^[^\w\s]+/;var h=c.exec(a),p=u,d=u+h[0].length,v=Mt(l),m=c.exec(v);m&&(p-=m[0].length);if(t){var g=o.substring(d),y=g.match(/^\s*/)[0].length;if(y>0)d+=y;else{var w=v.length-p,E=v.substring(w),S=E.match(/^\s*/)[0].length;p-=S}}return{start:b(s.line,p),end:b(s.line,d)}}function Kt(e,t,n){Nt(t,n)||nt.jumpList.add(e,t,n)}function Qt(e,t){nt.lastChararacterSearch.increment=e,nt.lastChararacterSearch.forward=t.forward,nt.lastChararacterSearch.selectedCharacter=t.selectedCharacter}function Zt(e,t,n,r){var i=Tt(e.getCursor()),s=n?1:-1,o=n?e.lineCount():-1,u=i.ch,a=i.line,f=e.getLine(a),l={lineText:f,nextCh:f.charAt(u),lastCh:null,index:u,symb:r,reverseSymb:(n?{")":"(","}":"{"}:{"(":")","{":"}"})[r],forward:n,depth:0,curMoveThrough:!1},c=Gt[r];if(!c)return i;var h=Yt[c].init,p=Yt[c].isComplete;h&&h(l);while(a!==o&&t){l.index+=s,l.nextCh=l.lineText.charAt(l.index);if(!l.nextCh){a+=s,l.lineText=e.getLine(a)||"";if(s>0)l.index=0;else{var d=l.lineText.length;l.index=d>0?d-1:0}l.nextCh=l.lineText.charAt(l.index)}p(l)&&(i.line=a,i.ch=l.index,t--)}return l.nextCh||l.curMoveThrough?b(a,l.index):i}function en(e,t,n,r,i){var s=t.line,o=t.ch,u=e.getLine(s),a=n?1:-1,f=r?P:D;if(i&&u==""){s+=a,u=e.getLine(s);if(!R(e,s))return null;o=n?0:u.length}for(;;){if(i&&u=="")return{from:0,to:0,line:s};var l=a>0?u.length:-1,c=l,h=l;while(o!=l){var p=!1;for(var d=0;d<f.length&&!p;++d)if(f[d].test(u.charAt(o))){c=o;while(o!=l&&f[d].test(u.charAt(o)))o+=a;h=o,p=c!=h;if(c==t.ch&&s==t.line&&h==c+a)continue;return{from:Math.min(c,h+1),to:Math.max(c,h),line:s}}p||(o+=a)}s+=a;if(!R(e,s))return null;u=e.getLine(s),o=a>0?0:u.length}throw new Error("The impossible happened.")}function tn(e,t,n,r,i,s){var o=Tt(t),u=[];(r&&!i||!r&&i)&&n++;var a=!r||!i;for(var f=0;f<n;f++){var l=en(e,t,r,s,a);if(!l){var c=Ot(e,e.lastLine());u.push(r?{line:e.lastLine(),from:c,to:c}:{line:0,from:0,to:0});break}u.push(l),t=b(l.line,r?l.to-1:l.from)}var h=u.length!=n,p=u[0],d=u.pop();return r&&!i?(!h&&(p.from!=o.ch||p.line!=o.line)&&(d=u.pop()),b(d.line,d.from)):r&&i?b(d.line,d.to-1):!r&&i?(!h&&(p.to!=o.ch||p.line!=o.line)&&(d=u.pop()),b(d.line,d.to)):b(d.line,d.from)}function nn(e,t,n,r){var i=e.getCursor(),s=i.ch,o;for(var u=0;u<t;u++){var a=e.getLine(i.line);o=on(s,a,r,n,!0);if(o==-1)return null;s=o}return b(e.getCursor().line,o)}function rn(e,t){var n=e.getCursor().line;return mt(e,b(n,t-1))}function sn(e,t,n,r){if(!$(n,I))return;t.marks[n]&&t.marks[n].clear(),t.marks[n]=e.setBookmark(r)}function on(e,t,n,r,i){var s;return r?(s=t.indexOf(n,e+1),s!=-1&&!i&&(s-=1)):(s=t.lastIndexOf(n,e-1),s!=-1&&!i&&(s+=1)),s}function un(e,t,n,r){var i=t,s,o,u={"(":/[()]/,")":/[()]/,"[":/[[\]]/,"]":/[[\]]/,"{":/[{}]/,"}":/[{}]/}[n],a={"(":"(",")":"(","[":"[","]":"[","{":"{","}":"{"}[n],f=e.getLine(i.line).charAt(i.ch),l=f===a?1:0;s=e.scanForBracket(b(i.line,i.ch+l),-1,null,{bracketRegex:u}),o=e.scanForBracket(b(i.line,i.ch+l),1,null,{bracketRegex:u});if(!s||!o)return{start:i,end:i};s=s.pos,o=o.pos;if(s.line==o.line&&s.ch>o.ch||s.line>o.line){var c=s;s=o,o=c}return r?o.ch+=1:s.ch+=1,{start:s,end:o}}function an(e,t,n,r){var i=Tt(t),s=e.getLine(i.line),o=s.split(""),u,a,f,l,c=o.indexOf(n);i.ch<c?i.ch=c:c<i.ch&&o[i.ch]==n&&(a=i.ch,--i.ch);if(o[i.ch]==n&&!a)u=i.ch+1;else for(f=i.ch;f>-1&&!u;f--)o[f]==n&&(u=f+1);if(u&&!a)for(f=u,l=o.length;f<l&&!a;f++)o[f]==n&&(a=f);return!u||!a?{start:i,end:i}:(r&&(--u,++a),{start:b(i.line,u),end:b(i.line,a)})}function fn(){}function ln(e){var t=e.state.vim;return t.searchState_||(t.searchState_=new fn)}function cn(e,t,n,r,i){e.openDialog?e.openDialog(t,r,{bottom:!0,value:i.value,onKeyDown:i.onKeyDown,onKeyUp:i.onKeyUp}):r(prompt(n,""))}function hn(e){var t=pn(e)||[];if(!t.length)return[];var n=[];if(t[0]!==0)return;for(var r=0;r<t.length;r++)typeof t[r]=="number"&&n.push(e.substring(t[r]+1,t[r+1]));return n}function pn(e){var t=!1,n=[];for(var r=0;r<e.length;r++){var i=e.charAt(r);!t&&i=="/"&&n.push(r),t=!t&&i=="\\"}return n}function dn(e){var t="|(){",n="}",r=!1,i=[];for(var s=-1;s<e.length;s++){var o=e.charAt(s)||"",u=e.charAt(s+1)||"",a=u&&t.indexOf(u)!=-1;r?((o!=="\\"||!a)&&i.push(o),r=!1):o==="\\"?(r=!0,u&&n.indexOf(u)!=-1&&(a=!0),(!a||u==="\\")&&i.push(o)):(i.push(o),a&&u!=="\\"&&i.push("\\"))}return i.join("")}function vn(e){var t=!1,n=[];for(var r=-1;r<e.length;r++){var i=e.charAt(r)||"",s=e.charAt(r+1)||"";t?(n.push(i),t=!1):i==="\\"?(t=!0,W(s)||s==="$"?n.push("$"):s!=="/"&&s!=="\\"&&n.push("\\")):(i==="$"&&n.push("$"),n.push(i),s==="/"&&n.push("\\"))}return n.join("")}function mn(e){var t=new d.StringStream(e),n=[];while(!t.eol()){while(t.peek()&&t.peek()!="\\")n.push(t.next());t.match("\\/",!0)?n.push("/"):t.match("\\\\",!0)?n.push("\\"):n.push(t.next())}return n.join("")}function gn(e,t,n){var r=nt.registerController.getRegister("/");r.setText(e);if(e instanceof RegExp)return e;var i=pn(e),s,o;if(!i.length)s=e;else{s=e.substring(0,i[0]);var u=e.substring(i[0]);o=u.indexOf("i")!=-1}if(!s)return null;G("pcre")||(s=dn(s)),n&&(t=/^[^A-Z]*$/.test(s));var a=new RegExp(s,t||o?"i":undefined);return a}function yn(e,t){e.openNotification?e.openNotification('<span style="color: red">'+t+"</span>",{bottom:!0,duration:5e3}):alert(t)}function bn(e,t){var n="";return e&&(n+='<span style="font-family: monospace">'+e+"</span>"),n+='<input type="text"/> <span style="color: #888">',t&&(n+='<span style="color: #888">',n+=t,n+="</span>"),n}function En(e,t){var n=(t.prefix||"")+" "+(t.desc||""),r=bn(t.prefix,t.desc);cn(e,r,n,t.onClose,t)}function Sn(e,t){if(e instanceof RegExp&&t instanceof RegExp){var n=["global","multiline","ignoreCase","source"];for(var r=0;r<n.length;r++){var i=n[r];if(e[i]!==t[i])return!1}return!0}return!1}function xn(e,t,n,r){if(!t)return;var i=ln(e),s=gn(t,!!n,!!r);if(!s)return;return Nn(e,s),Sn(s,i.getQuery())?s:(i.setQuery(s),s)}function Tn(e){if(e.source.charAt(0)=="^")var t=!0;return{token:function(n){if(t&&!n.sol()){n.skipToEnd();return}var r=n.match(e,!1);if(r){if(r[0].length==0)return n.next(),"searching";if(!n.sol()){n.backUp(1);if(!e.exec(n.next()+r[0]))return n.next(),null}return n.match(e),"searching"}while(!n.eol()){n.next();if(n.match(e,!1))break}},query:e}}function Nn(e,t){var n=ln(e).getOverlay();if(!n||t!=n.query)n&&e.removeOverlay(n),n=Tn(t),e.addOverlay(n),ln(e).setOverlay(n)}function Cn(e,t,n,r){return r===undefined&&(r=1),e.operation(function(){var i=e.getCursor(),s=e.getSearchCursor(n,i);for(var o=0;o<r;o++){var u=s.find(t);o==0&&u&&Nt(s.from(),i)&&(u=s.find(t));if(!u){s=e.getSearchCursor(n,t?b(e.lastLine()):b(e.firstLine(),0));if(!s.find(t))return}}return s.from()})}function kn(e){e.removeOverlay(ln(e).getOverlay()),ln(e).setOverlay(null)}function Ln(e,t,n){return typeof e!="number"&&(e=e.line),t instanceof Array?$(e,t):n?e>=t&&e<=n:e==t}function An(e){var t=e.ace.renderer;return{top:t.getFirstFullyVisibleRow(),bottom:t.getLastFullyVisibleRow()}}function Pn(e,t,n,r,i,s,o,u,a){function c(){e.operation(function(){while(!f)h(),p();v()})}function h(){var t=e.getRange(s.from(),s.to()),n=t.replace(o,u);s.replace(n)}function p(){var t;while(t=s.findNext()&&Ln(s.from(),r,i)){if(!n&&l&&s.from().line==l.line)continue;e.scrollIntoView(s.from(),30),e.setSelection(s.from(),s.to()),l=s.from(),f=!1;return}f=!0}function v(t){t&&t(),e.focus();if(l){e.setCursor(l);var n=e.state.vim;n.exMode=!1,n.lastHPos=n.lastHSPos=l.ch}a&&a()}function m(t,n,r){d.e_stop(t);var i=d.keyName(t);switch(i){case"Y":h(),p();break;case"N":p();break;case"A":var s=a;a=undefined,e.operation(c),a=s;break;case"L":h();case"Q":case"Esc":case"Ctrl-C":case"Ctrl-[":v(r)}return f&&v(r),!0}e.state.vim.exMode=!0;var f=!1,l=s.from();p();if(f){yn(e,"No matches for "+o.source);return}if(!t){c(),a&&a();return}En(e,{prefix:"replace with <strong>"+u+"</strong> (y/n/a/q/l)",onKeyDown:m})}function Hn(e){var t=e.state.vim,n=nt.macroModeState,r=nt.registerController.getRegister("."),i=n.isPlaying,s=n.lastInsertModeChanges,o=[];if(!i){var u=s.inVisualBlock?t.lastSelection.visualBlock.height:1,a=s.changes,o=[],f=0;while(f<a.length)o.push(a[f]),a[f]instanceof Wn?f++:f+=u;s.changes=o,e.off("change",qn),d.off(e.getInputField(),"keydown",Xn)}!i&&t.insertModeRepeat>1&&(Vn(e,t,t.insertModeRepeat-1,!0),t.lastEditInputState.repeatOverride=t.insertModeRepeat),delete t.insertModeRepeat,t.insertMode=!1,e.setCursor(e.getCursor().line,e.getCursor().ch-1),e.setOption("keyMap","vim"),e.setOption("disableInput",!0),e.toggleOverwrite(!1),r.setText(s.changes.join("")),d.signal(e,"vim-mode-change",{mode:"normal"}),n.isRecording&&Fn(n)}function Bn(e,t,n,r){var i=nt.registerController.getRegister(r),s=i.keyBuffer,o=0;n.isPlaying=!0,n.replaySearchQueries=i.searchQueries.slice(0);for(var u=0;u<s.length;u++){var a=s[u],f,l;while(a){f=/<\w+-.+?>|<\w+>|./.exec(a),l=f[0],a=a.substring(f.index+l.length),d.Vim.handleKey(e,l,"macro");if(t.insertMode){var c=i.insertModeChanges[o++].changes;nt.macroModeState.lastInsertModeChanges.changes=c,$n(e,c,1),Hn(e)}}}n.isPlaying=!1}function jn(e,t){if(e.isPlaying)return;var n=e.latestRegister,r=nt.registerController.getRegister(n);r&&r.pushText(t)}function Fn(e){if(e.isPlaying)return;var t=e.latestRegister,n=nt.registerController.getRegister(t);n&&n.pushInsertModeChanges(e.lastInsertModeChanges)}function In(e,t){if(e.isPlaying)return;var n=e.latestRegister,r=nt.registerController.getRegister(n);r&&r.pushSearchQuery(t)}function qn(e,t){var n=nt.macroModeState,r=n.lastInsertModeChanges;if(!n.isPlaying)while(t){r.expectCursorActivityForChange=!0;if(t.origin=="+input"||t.origin=="paste"||t.origin===undefined){var i=t.text.join("\n");r.changes.push(i)}t=t.next}}function Rn(e){var t=e.state.vim;if(t.insertMode){var n=nt.macroModeState;if(n.isPlaying)return;var r=n.lastInsertModeChanges;r.expectCursorActivityForChange?r.expectCursorActivityForChange=!1:r.changes=[]}else e.curOp.isVimOp||zn(e,t);t.visualMode&&Un(e)}function Un(e){var t=e.state.vim,n=Tt(t.sel.head),r=yt(n,0,1);t.fakeCursor&&t.fakeCursor.clear(),t.fakeCursor=e.markText(n,r,{className:"cm-animate-fat-cursor"})}function zn(e,t){var n=e.getCursor("anchor"),r=e.getCursor("head");t.visualMode&&Nt(r,n)&&Ot(e,r.line)>r.ch?Wt(e,!1):!t.visualMode&&!t.insertMode&&e.somethingSelected()&&(t.visualMode=!0,t.visualLine=!1,d.signal(e,"vim-mode-change",{mode:"visual"}));if(t.visualMode){var i=Ct(r,n)?0:-1,s=Ct(r,n)?-1:0;r=yt(r,0,i),n=yt(n,0,s),t.sel={anchor:n,head:r},sn(e,t,"<",kt(r,n)),sn(e,t,">",Lt(r,n))}else t.insertMode||(t.lastHPos=e.getCursor().ch)}function Wn(e){this.keyName=e}function Xn(e){function i(){return n.changes.push(new Wn(r)),!0}var t=nt.macroModeState,n=t.lastInsertModeChanges,r=d.keyName(e);(r.indexOf("Delete")!=-1||r.indexOf("Backspace")!=-1)&&d.lookupKey(r,"vim-insert",i)}function Vn(e,t,n,r){function u(){s?ct.processAction(e,t,t.lastEditActionCommand):ct.evalInput(e,t)}function a(n){if(i.lastInsertModeChanges.changes.length>0){n=t.lastEditActionCommand?n:1;var r=i.lastInsertModeChanges;$n(e,r.changes,n)}}var i=nt.macroModeState;i.isPlaying=!0;var s=!!t.lastEditActionCommand,o=t.inputState;t.inputState=t.lastEditInputState;if(s&&t.lastEditActionCommand.interlaceInsertRepeat)for(var f=0;f<n;f++)u(),a(1);else r||u(),a(n);t.inputState=o,t.insertMode&&!r&&Hn(e),i.isPlaying=!1}function $n(e,t,n){function r(t){return typeof t=="string"?d.commands[t](e):t(e),!0}var i=e.getCursor("head"),s=nt.macroModeState.lastInsertModeChanges.inVisualBlock;if(s){var o=e.state.vim,u=o.lastSelection,a=bt(u.anchor,u.head);Bt(e,i,a.line+1),n=e.listSelections().length,e.setCursor(i)}for(var f=0;f<n;f++){s&&e.setCursor(yt(i,f,0));for(var l=0;l<t.length;l++){var c=t[l];if(c instanceof Wn)d.lookupKey(c.keyName,"vim-insert",r);else{var h=e.getCursor();e.replaceRange(c,h,h)}}}s&&e.setCursor(yt(i,0,1))}function T(e,t,n){t.length>1&&t[0]=="n"&&(t=t.replace("numpad","")),t=E[t]||t;var r="";return n.ctrlKey&&(r+="C-"),n.altKey&&(r+="A-"),n.shiftKey&&(r+="S-"),r+=t,r.length>1&&(r="<"+r+">"),r}function Kn(e){var t=new e.constructor;return Object.keys(e).forEach(function(n){var r=e[n];Array.isArray(r)?r=r.slice():r&&typeof r=="object"&&r.constructor!=Object&&(r=Kn(r)),t[n]=r}),e.sel&&(t.sel={head:e.sel.head&&Tt(e.sel.head),anchor:e.sel.anchor&&Tt(e.sel.anchor)}),t}function Qn(e,t,n){var r=!1,i=x.maybeInitVimState_(e),s=i.visualBlock||i.wasInVisualBlock;i.wasInVisualBlock&&!e.ace.inMultiSelectMode?i.wasInVisualBlock=!1:e.ace.inMultiSelectMode&&i.visualBlock&&(i.wasInVisualBlock=!0);if(t=="<Esc>"&&!i.insertMode&&!i.visualMode&&e.ace.inMultiSelectMode)e.ace.exitMultiSelectMode();else if(s||!e.ace.inMultiSelectMode||e.ace.inVirtualSelectionMode)r=x.handleKey(e,t,n);else{var o=Kn(i);e.operation(function(){e.ace.forEachSelection(function(){var i=e.ace.selection;e.state.vim.lastHPos=i.$desiredColumn==null?i.lead.column:i.$desiredColumn;var s=e.getCursor("head"),u=e.getCursor("anchor"),a=Ct(s,u)?0:-1,f=Ct(s,u)?-1:0;s=yt(s,0,a),u=yt(u,0,f),e.state.vim.sel.head=s,e.state.vim.sel.anchor=u,r=Jn(e,t,n),i.$desiredColumn=e.state.vim.lastHPos==-1?null:e.state.vim.lastHPos,e.virtualSelectionMode()&&(e.state.vim=Kn(o))}),e.curOp.cursorActivity&&!r&&(e.curOp.cursorActivity=!1)},!0)}return r}function Zn(e,t){t.off("beforeEndOperation",Zn);var n=t.state.cm.vimCmd;n&&t.execCommand(n.exec?n:n.name,n.args),t.curOp=t.prevOp}var i=e("../range").Range,s=e("../lib/event_emitter").EventEmitter,o=e("../lib/dom"),u=e("../lib/oop"),a=e("../lib/keys"),f=e("../lib/event"),l=e("../search").Search,c=e("../lib/useragent"),h=e("../search_highlight").SearchHighlight,p=e("../commands/multi_select_commands");e("../multi_select");var d=function(e){this.ace=e,this.state={},this.marks={},this.$uid=0,this.onChange=this.onChange.bind(this),this.onSelectionChange=this.onSelectionChange.bind(this),this.onBeforeEndOperation=this.onBeforeEndOperation.bind(this),this.ace.on("change",this.onChange),this.ace.on("changeSelection",this.onSelectionChange),this.ace.on("beforeEndOperation",this.onBeforeEndOperation)};d.Pos=function(e,t){if(!(this instanceof b))return new b(e,t);this.line=e,this.ch=t},d.defineOption=function(e,t,n){},d.commands={redo:function(e){e.ace.redo()},undo:function(e){e.ace.undo()},newlineAndIndent:function(e){e.ace.insert("\n")}},d.keyMap={},d.addClass=d.rmClass=d.e_stop=function(){},d.keyName=function(e){if(e.key)return e.key;var t=a[e.keyCode]||"";return t.length==1&&(t=t.toUpperCase()),t=f.getModifierString(e).replace(/(^|-)\w/g,function(e){return e.toUpperCase()})+t,t},d.keyMap["default"]=function(e){return function(t){var n=t.ace.commands.commandKeyBinding[e.toLowerCase()];return n&&t.ace.execCommand(n)!==!1}},d.lookupKey=function er(e,t,n){typeof t=="string"&&(t=d.keyMap[t]);var r=typeof t=="function"?t(e):t[e];if(r===!1)return"nothing";if(r==="...")return"multi";if(r!=null&&n(r))return"handled";if(t.fallthrough){if(!Array.isArray(t.fallthrough))return er(e,t.fallthrough,n);for(var i=0;i<t.fallthrough.length;i++){var s=er(e,t.fallthrough[i],n);if(s)return s}}},d.signal=function(e,t,n){return e._signal(t,n)},d.on=f.addListener,d.off=f.removeListener,function(){u.implement(d.prototype,s),this.destroy=function(){this.ace.off("change",this.onChange),this.ace.off("changeSelection",this.onSelectionChange),this.ace.off("beforeEndOperation",this.onBeforeEndOperation),this.removeOverlay()},this.virtualSelectionMode=function(){return this.ace.inVirtualSelectionMode&&this.ace.selection.index},this.onChange=function(e){var t=e.data;e={start:t.range.start,end:t.range.end,action:t.action,lines:t.lines||[t.text]};if(e.action[0]=="i"){var n={text:e.lines},r=this.curOp=this.curOp||{};r.changeHandlers||(r.changeHandlers=this._eventRegistry.change&&this._eventRegistry.change.slice());if(this.virtualSelectionMode())return;r.lastChange?r.lastChange.next=r.lastChange=n:r.lastChange=r.change=n}this.$updateMarkers(e)},this.onSelectionChange=function(){var e=this.curOp=this.curOp||{};e.cursorActivityHandlers||(e.cursorActivityHandlers=this._eventRegistry.cursorActivity&&this._eventRegistry.cursorActivity.slice()),this.curOp.cursorActivity=!0,this.ace.inMultiSelectMode&&this.ace.keyBinding.removeKeyboardHandler(p.keyboardHandler)},this.operation=function(e,t){if(!t&&this.curOp||t&&this.curOp&&this.curOp.force)return e();(t||!this.ace.curOp)&&this.curOp&&this.onBeforeEndOperation();if(!this.ace.curOp){var n=this.ace.prevOp;this.ace.startOperation({command:{name:"vim",scrollIntoView:"cursor"}})}var r=this.curOp=this.curOp||{};this.curOp.force=t;var i=e();return this.ace.curOp&&this.ace.curOp.command.name=="vim"&&(this.ace.endOperation(),!r.cursorActivity&&!r.lastChange&&n&&(this.ace.prevOp=n)),(t||!this.ace.curOp)&&this.curOp&&this.onBeforeEndOperation(),i},this.onBeforeEndOperation=function(){var e=this.curOp;e&&(e.change&&this.signal("change",e.change,e),e&&e.cursorActivity&&this.signal("cursorActivity",null,e),this.curOp=null)},this.signal=function(e,t,n){var r=n?n[e+"Handlers"]:(this._eventRegistry||{})[e];if(!r)return;r=r.slice();for(var i=0;i<r.length;i++)r[i](this,t)},this.firstLine=function(){return 0},this.lastLine=function(){return this.ace.session.getLength()-1},this.lineCount=function(){return this.ace.session.getLength()},this.setCursor=function(e,t){typeof e=="object"&&(t=e.ch,e=e.line),this.ace.inVirtualSelectionMode||this.ace.exitMultiSelectMode(),this.ace.selection.moveTo(e,t)},this.getCursor=function(e){var t=this.ace.selection,n=e=="anchor"?t.isEmpty()?t.lead:t.anchor:e=="head"||!e?t.lead:t.getRange()[e];return m(n)},this.listSelections=function(e){var t=this.ace.multiSelect.rangeList.ranges;return!t.length||this.ace.inVirtualSelectionMode?[{anchor:this.getCursor("anchor"),head:this.getCursor("head")}]:t.map(function(e){return{anchor:this.clipPos(m(e.cursor==e.end?e.start:e.end)),head:this.clipPos(m(e.cursor))}},this)},this.setSelections=function(e,t){var n=this.ace.multiSelect,r=e.map(function(e){var t=v(e.anchor),n=v(e.head),r=i.comparePoints(t,n)<0?new i.fromPoints(t,n):new i.fromPoints(n,t);return r.cursor=i.comparePoints(r.start,n)?r.end:r.start,r});if(this.ace.inVirtualSelectionMode){this.ace.selection.fromOrientedRange(r[0]);return}t?r[t]&&r.push(r.splice(t,1)[0]):r=r.reverse(),n.toSingleRange(r[0].clone());var s=this.ace.session;for(var o=0;o<r.length;o++){var u=s.$clipRangeToDocument(r[o]);n.addRange(u)}},this.setSelection=function(e,t,n){var r=this.ace.selection;r.moveTo(e.line,e.ch),r.selectTo(t.line,t.ch),n&&n.origin=="*mouse"&&this.onBeforeEndOperation()},this.somethingSelected=function(e){return!this.ace.selection.isEmpty()},this.clipPos=function(e){var t=this.ace.session.$clipPositionToDocument(e.line,e.ch);return m(t)},this.markText=function(e){return{clear:function(){},find:function(){}}},this.$updateMarkers=function(e){var t=e.action=="insert",n=e.start,r=e.end,s=(r.row-n.row)*(t?1:-1),o=(r.column-n.column)*(t?1:-1);t&&(r=n);for(var u in this.marks){var a=this.marks[u],f=i.comparePoints(a,n);if(f<0)continue;if(f===0&&t){if(a.bias!=1){a.bias==-1;continue}f=1}var l=t?f:i.comparePoints(a,r);if(l>0){a.row+=s,a.column+=a.row==r.row?o:0;continue}!t&&l<=0&&(a.row=n.row,a.column=n.column,l===0&&(a.bias=1))}};var e=function(e,t,n,r){this.cm=e,this.id=t,this.row=n,this.column=r,e.marks[this.id]=this};e.prototype.clear=function(){delete this.cm.marks[this.id]},e.prototype.find=function(){return m(this)},this.setBookmark=function(t,n){var r=new e(this,this.$uid++,t.line,t.ch);if(!n||!n.insertLeft)r.$insertRight=!0;return this.marks[r.id]=r,r},this.moveH=function(e,t){if(t=="char"){var n=this.ace.selection;n.clearSelection(),n.moveCursorBy(0,e)}},this.findPosV=function(e,t,n,r){if(n=="line"){var i=this.ace.session.documentToScreenPosition(e.line,e.ch);r!=null&&(i.column=r),i.row+=t,i.row=Math.min(Math.max(0,i.row),this.ace.session.getScreenLength()-1);var s=this.ace.session.screenToDocumentPosition(i.row,i.column);return m(s)}debugger},this.charCoords=function(e,t){if(t=="div"||!t){var n=this.ace.session.documentToScreenPosition(e.line,e.ch);return{left:n.column,top:n.row}}if(t=="local"){var r=this.ace.renderer,n=this.ace.session.documentToScreenPosition(e.line,e.ch),i=r.layerConfig.lineHeight,s=r.layerConfig.characterWidth,o=i*n.row;return{left:n.column*s,top:o,bottom:o+i}}},this.coordsChar=function(e,t){var n=this.ace.renderer;if(t=="local"){var r=Math.max(0,Math.floor(e.top/n.lineHeight)),i=Math.max(0,Math.floor(e.left/n.characterWidth)),s=n.session.screenToDocumentPosition(r,i);return m(s)}if(t=="div")throw"not implemented"},this.openDialog=function(){debugger},this.getSearchCursor=function(e,t,n){var r=!1,i=!1;e instanceof RegExp&&!e.global&&(r=!e.ignoreCase,e=e.source,i=!0);var s=new l;t.ch==undefined&&(t.ch=Number.MAX_VALUE);var o={row:t.line,column:t.ch},u=this,a=null;return{findNext:function(){return this.find(!1)},findPrevious:function(){return this.find(!0)},find:function(t){s.setOptions({needle:e,caseSensitive:r,wrap:!1,backwards:t,regExp:i,start:a||o});var n=s.find(u.ace.session);return n&&n.isEmpty()&&u.getLine(n.start.row).length==n.start.column&&(s.$options.start=n,n=s.find(u.ace.session)),a=n,a},from:function(){return a&&m(a.start)},to:function(){return a&&m(a.end)},replace:function(e){a&&(a.end=u.ace.session.doc.replace(a,e))}}},this.scrollTo=function(e,t){var n=this.ace.renderer,r=n.layerConfig,i=r.maxHeight;i-=(n.$size.scrollerHeight-n.lineHeight)*n.$scrollPastEnd,t!=null&&this.ace.session.setScrollTop(Math.max(0,Math.min(t,i))),e!=null&&this.ace.session.setScrollLeft(Math.max(0,Math.min(e,r.width)))},this.scrollInfo=function(){return 0},this.scrollIntoView=function(e,t){e&&this.ace.renderer.scrollCursorIntoView(v(e),null,t)},this.getLine=function(e){return this.ace.session.getLine(e)},this.getRange=function(e,t){return this.ace.session.getTextRange(new i(e.line,e.ch,t.line,t.ch))},this.replaceRange=function(e,t,n){return n||(n=t),this.ace.session.replace(new i(t.line,t.ch,n.line,n.ch),e)},this.replaceSelections=function(e){var t=this.ace.selection;if(this.ace.inVirtualSelectionMode){this.ace.session.replace(t.getRange(),e[0]||"");return}t.inVirtualSelectionMode=!0;var n=t.rangeList.ranges;n.length||(n=[this.ace.multiSelect.getRange()]);for(var r=n.length;r--;)this.ace.session.replace(n[r],e[r]||"");t.inVirtualSelectionMode=!1},this.getSelection=function(){return this.ace.getSelectedText()},this.getSelections=function(){return this.listSelections().map(function(e){return this.getRange(e.anchor,e.head)},this)},this.getInputField=function(){return this.ace.textInput.getElement()},this.getWrapperElement=function(){return this.ace.containter};var t={indentWithTabs:"useSoftTabs",indentUnit:"tabSize",firstLineNumber:"firstLineNumber"};this.setOption=function(e,n){this.state[e]=n;switch(e){case"indentWithTabs":e=t[e],n=!n;break;default:e=t[e]}e&&this.ace.setOption(e,n)},this.getOption=function(e,n){var r=t[e];r&&(n=this.ace.getOption(r));switch(e){case"indentWithTabs":return e=t[e],!n}return r?n:this.state[e]},this.toggleOverwrite=function(e){return this.state.overwrite=e,this.ace.setOverwrite(e)},this.addOverlay=function(e){if(!this.$searchHighlight||!this.$searchHighlight.session){var t=new h(null,"ace_highlight-marker","text"),n=this.ace.session.addDynamicMarker(t);t.id=n.id,t.session=this.ace.session,t.destroy=function(e){t.session.off("change",t.updateOnChange),t.session.off("changeEditor",t.destroy),t.session.removeMarker(t.id),t.session=null},t.updateOnChange=function(e){e=e.data.range;var n=e.start.row;n==e.end.row?t.cache[n]=undefined:t.cache.splice(n,t.cache.length)},t.session.on("changeEditor",t.destroy),t.session.on("change",t.updateOnChange)}var r=new RegExp(e.query.source,"gmi");console.log(r),this.$searchHighlight=e.highlight=t,this.$searchHighlight.setRegexp(r),this.ace.renderer.updateBackMarkers()},this.removeOverlay=function(e){this.$searchHighlight&&this.$searchHighlight.session&&this.$searchHighlight.destroy()},this.getScrollInfo=function(){var e=this.ace.renderer,t=e.layerConfig;return{left:e.scrollLeft,top:e.scrollTop,height:t.maxHeight,width:t.width,clientHeight:t.height,clientWidth:t.width}},this.getValue=function(){return this.ace.getValue()},this.setValue=function(e){return this.ace.setValue(e)},this.getTokenTypeAt=function(e){var t=this.ace.session.getTokenAt(e.line,e.ch);return t&&/comment|string/.test(t.type)?"string":""},this.findMatchingBracket=function(e){var t=this.ace.session.findMatchingBracket(v(e));return{to:t&&m(t)}},this.indentLine=function(e,t){t===!0?this.ace.session.indentRows(e,e," "):t===!1&&this.ace.session.outdentRows(new i(e,0,e,0))},this.indexFromPos=function(e){return this.ace.session.doc.positionToIndex(v(e))},this.posFromIndex=function(e){return m(this.ace.session.doc.indexToPosition(e))},this.focus=function(e){return this.ace.focus()},this.blur=function(e){return this.ace.blur()},this.defaultTextHeight=function(e){return this.ace.renderer.layerConfig.lineHeight},this.scanForBracket=function(e,t,n,r){var i=r.bracketRegex.source;if(t==1)var s=this.ace.session.$findClosingBracket(i.slice(1,2),v(e),/paren|text/);else var s=this.ace.session.$findOpeningBracket(i.slice(-2,-1),{row:e.line,column:e.ch+1},/paren|text/);return s&&{pos:m(s)}},this.refresh=function(){return this.ace.resize(!0)}}.call(d.prototype);var g=d.StringStream=function(e,t){this.pos=this.start=0,this.string=e,this.tabSize=t||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0};g.prototype={eol:function(){return this.pos>=this.string.length},sol:function(){return this.pos==this.lineStart},peek:function(){return this.string.charAt(this.pos)||undefined},next:function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},eat:function(e){var t=this.string.charAt(this.pos);if(typeof e=="string")var n=t==e;else var n=t&&(e.test?e.test(t):e(t));if(n)return++this.pos,t},eatWhile:function(e){var t=this.pos;while(this.eat(e));return this.pos>t},eatSpace:function(){var e=this.pos;while(/[\s\u00a0]/.test(this.string.charAt(this.pos)))++this.pos;return this.pos>e},skipToEnd:function(){this.pos=this.string.length},skipTo:function(e){var t=this.string.indexOf(e,this.pos);if(t>-1)return this.pos=t,!0},backUp:function(e){this.pos-=e},column:function(){throw"not implemented"},indentation:function(){throw"not implemented"},match:function(e,t,n){if(typeof e!="string"){var s=this.string.slice(this.pos).match(e);return s&&s.index>0?null:(s&&t!==!1&&(this.pos+=s[0].length),s)}var r=function(e){return n?e.toLowerCase():e},i=this.string.substr(this.pos,e.length);if(r(i)==r(e))return t!==!1&&(this.pos+=e.length),!0},current:function(){return this.string.slice(this.start,this.pos)},hideFirstChars:function(e,t){this.lineStart+=e;try{return t()}finally{this.lineStart-=e}}},d.defineExtension=function(e,t){d.prototype[e]=t},o.importCssString(".normal-mode .ace_cursor{ border: 0!important; background-color: red; opacity: 0.5;}.ace_dialog { position: absolute; left: 0; right: 0; background: white; z-index: 15; padding: .1em .8em; overflow: hidden; color: #333;}.ace_dialog-top { border-bottom: 1px solid #eee; top: 0;}.ace_dialog-bottom { border-top: 1px solid #eee; bottom: 0;}.ace_dialog input { border: none; outline: none; background: transparent; width: 20em; color: inherit; font-family: monospace;}","vimMode"),function(){function e(e,t,n){var r=e.ace.container,i;return i=r.appendChild(document.createElement("div")),n?i.className="ace_dialog ace_dialog-bottom":i.className="ace_dialog ace_dialog-top",typeof t=="string"?i.innerHTML=t:i.appendChild(t),i}function t(e,t){e.state.currentNotificationClose&&e.state.currentNotificationClose(),e.state.currentNotificationClose=t}d.defineExtension("openDialog",function(n,r,i){function a(e){if(typeof e=="string")f.value=e;else{if(o)return;o=!0,s.parentNode.removeChild(s),u.focus(),i.onClose&&i.onClose(s)}}if(this.virtualSelectionMode())return;i||(i={}),t(this,null);var s=e(this,n,i.bottom),o=!1,u=this,f=s.getElementsByTagName("input")[0],l;if(f)i.value&&(f.value=i.value,f.select()),i.onInput&&d.on(f,"input",function(e){i.onInput(e,f.value,a)}),i.onKeyUp&&d.on(f,"keyup",function(e){i.onKeyUp(e,f.value,a)}),d.on(f,"keydown",function(e){if(i&&i.onKeyDown&&i.onKeyDown(e,f.value,a))return;if(e.keyCode==27||i.closeOnEnter!==!1&&e.keyCode==13)f.blur(),d.e_stop(e),a();e.keyCode==13&&r(f.value)}),i.closeOnBlur!==!1&&d.on(f,"blur",a),f.focus();else if(l=s.getElementsByTagName("button")[0])d.on(l,"click",function(){a(),u.focus()}),i.closeOnBlur!==!1&&d.on(l,"blur",a),l.focus();return a}),d.defineExtension("openNotification",function(n,r){function a(){if(s)return;s=!0,clearTimeout(o),i.parentNode.removeChild(i)}if(this.virtualSelectionMode())return;t(this,a);var i=e(this,n,r&&r.bottom),s=!1,o,u=r&&typeof r.duration!="undefined"?r.duration:5e3;return d.on(i,"click",function(e){d.e_preventDefault(e),a()}),u&&(o=setTimeout(a,u)),a})}();var y=[{keys:"<Left>",type:"keyToKey",toKeys:"h"},{keys:"<Right>",type:"keyToKey",toKeys:"l"},{keys:"<Up>",type:"keyToKey",toKeys:"k"},{keys:"<Down>",type:"keyToKey",toKeys:"j"},{keys:"<Space>",type:"keyToKey",toKeys:"l"},{keys:"<BS>",type:"keyToKey",toKeys:"h"},{keys:"<C-Space>",type:"keyToKey",toKeys:"W"},{keys:"<C-BS>",type:"keyToKey",toKeys:"B"},{keys:"<S-Space>",type:"keyToKey",toKeys:"w"},{keys:"<S-BS>",type:"keyToKey",toKeys:"b"},{keys:"<C-n>",type:"keyToKey",toKeys:"j"},{keys:"<C-p>",type:"keyToKey",toKeys:"k"},{keys:"<C-[>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-c>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-[>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"<C-c>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"s",type:"keyToKey",toKeys:"cl",context:"normal"},{keys:"s",type:"keyToKey",toKeys:"xi",context:"visual"},{keys:"S",type:"keyToKey",toKeys:"cc",context:"normal"},{keys:"S",type:"keyToKey",toKeys:"dcc",context:"visual"},{keys:"<Home>",type:"keyToKey",toKeys:"0"},{keys:"<End>",type:"keyToKey",toKeys:"$"},{keys:"<PageUp>",type:"keyToKey",toKeys:"<C-b>"},{keys:"<PageDown>",type:"keyToKey",toKeys:"<C-f>"},{keys:"<CR>",type:"keyToKey",toKeys:"j^",context:"normal"},{keys:"H",type:"motion",motion:"moveToTopLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"M",type:"motion",motion:"moveToMiddleLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"L",type:"motion",motion:"moveToBottomLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"h",type:"motion",motion:"moveByCharacters",motionArgs:{forward:!1}},{keys:"l",type:"motion",motion:"moveByCharacters",motionArgs:{forward:!0}},{keys:"j",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,linewise:!0}},{keys:"k",type:"motion",motion:"moveByLines",motionArgs:{forward:!1,linewise:!0}},{keys:"gj",type:"motion",motion:"moveByDisplayLines",motionArgs:{forward:!0}},{keys:"gk",type:"motion",motion:"moveByDisplayLines",motionArgs:{forward:!1}},{keys:"w",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!1}},{keys:"W",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!1,bigWord:!0}},{keys:"e",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!0,inclusive:!0}},{keys:"E",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!0,bigWord:!0,inclusive:!0}},{keys:"b",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1}},{keys:"B",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1,bigWord:!0}},{keys:"ge",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!0,inclusive:!0}},{keys:"gE",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!0,bigWord:!0,inclusive:!0}},{keys:"{",type:"motion",motion:"moveByParagraph",motionArgs:{forward:!1,toJumplist:!0}},{keys:"}",type:"motion",motion:"moveByParagraph",motionArgs:{forward:!0,toJumplist:!0}},{keys:"<C-f>",type:"motion",motion:"moveByPage",motionArgs:{forward:!0}},{keys:"<C-b>",type:"motion",motion:"moveByPage",motionArgs:{forward:!1}},{keys:"<C-d>",type:"motion",motion:"moveByScroll",motionArgs:{forward:!0,explicitRepeat:!0}},{keys:"<C-u>",type:"motion",motion:"moveByScroll",motionArgs:{forward:!1,explicitRepeat:!0}},{keys:"gg",type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!1,explicitRepeat:!0,linewise:!0,toJumplist:!0}},{keys:"G",type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!0,explicitRepeat:!0,linewise:!0,toJumplist:!0}},{keys:"0",type:"motion",motion:"moveToStartOfLine"},{keys:"^",type:"motion",motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"+",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,toFirstChar:!0}},{keys:"-",type:"motion",motion:"moveByLines",motionArgs:{forward:!1,toFirstChar:!0}},{keys:"_",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,toFirstChar:!0,repeatOffset:-1}},{keys:"$",type:"motion",motion:"moveToEol",motionArgs:{inclusive:!0}},{keys:"%",type:"motion",motion:"moveToMatchedSymbol",motionArgs:{inclusive:!0,toJumplist:!0}},{keys:"f<character>",type:"motion",motion:"moveToCharacter",motionArgs:{forward:!0,inclusive:!0}},{keys:"F<character>",type:"motion",motion:"moveToCharacter",motionArgs:{forward:!1}},{keys:"t<character>",type:"motion",motion:"moveTillCharacter",motionArgs:{forward:!0,inclusive:!0}},{keys:"T<character>",type:"motion",motion:"moveTillCharacter",motionArgs:{forward:!1}},{keys:";",type:"motion",motion:"repeatLastCharacterSearch",motionArgs:{forward:!0}},{keys:",",type:"motion",motion:"repeatLastCharacterSearch",motionArgs:{forward:!1}},{keys:"'<character>",type:"motion",motion:"goToMark",motionArgs:{toJumplist:!0,linewise:!0}},{keys:"`<character>",type:"motion",motion:"goToMark",motionArgs:{toJumplist:!0}},{keys:"]`",type:"motion",motion:"jumpToMark",motionArgs:{forward:!0}},{keys:"[`",type:"motion",motion:"jumpToMark",motionArgs:{forward:!1}},{keys:"]'",type:"motion",motion:"jumpToMark",motionArgs:{forward:!0,linewise:!0}},{keys:"['",type:"motion",motion:"jumpToMark",motionArgs:{forward:!1,linewise:!0}},{keys:"]p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!0,isEdit:!0,matchIndent:!0}},{keys:"[p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!1,isEdit:!0,matchIndent:!0}},{keys:"]<character>",type:"motion",motion:"moveToSymbol",motionArgs:{forward:!0,toJumplist:!0}},{keys:"[<character>",type:"motion",motion:"moveToSymbol",motionArgs:{forward:!1,toJumplist:!0}},{keys:"|",type:"motion",motion:"moveToColumn"},{keys:"o",type:"motion",motion:"moveToOtherHighlightedEnd",context:"visual"},{keys:"O",type:"motion",motion:"moveToOtherHighlightedEnd",motionArgs:{sameLine:!0},context:"visual"},{keys:"d",type:"operator",operator:"delete"},{keys:"y",type:"operator",operator:"yank"},{keys:"c",type:"operator",operator:"change"},{keys:">",type:"operator",operator:"indent",operatorArgs:{indentRight:!0}},{keys:"<",type:"operator",operator:"indent",operatorArgs:{indentRight:!1}},{keys:"g~",type:"operator",operator:"changeCase"},{keys:"gu",type:"operator",operator:"changeCase",operatorArgs:{toLower:!0},isEdit:!0},{keys:"gU",type:"operator",operator:"changeCase",operatorArgs:{toLower:!1},isEdit:!0},{keys:"n",type:"motion",motion:"findNext",motionArgs:{forward:!0,toJumplist:!0}},{keys:"N",type:"motion",motion:"findNext",motionArgs:{forward:!1,toJumplist:!0}},{keys:"x",type:"operatorMotion",operator:"delete",motion:"moveByCharacters",motionArgs:{forward:!0},operatorMotionArgs:{visualLine:!1}},{keys:"X",type:"operatorMotion",operator:"delete",motion:"moveByCharacters",motionArgs:{forward:!1},operatorMotionArgs:{visualLine:!0}},{keys:"D",type:"operatorMotion",operator:"delete",motion:"moveToEol",motionArgs:{inclusive:!0},context:"normal"},{keys:"D",type:"operator",operator:"delete",operatorArgs:{linewise:!0},context:"visual"},{keys:"Y",type:"operatorMotion",operator:"yank",motion:"moveToEol",motionArgs:{inclusive:!0},context:"normal"},{keys:"Y",type:"operator",operator:"yank",operatorArgs:{linewise:!0},context:"visual"},{keys:"C",type:"operatorMotion",operator:"change",motion:"moveToEol",motionArgs:{inclusive:!0},context:"normal"},{keys:"C",type:"operator",operator:"change",operatorArgs:{linewise:!0},context:"visual"},{keys:"~",type:"operatorMotion",operator:"changeCase",motion:"moveByCharacters",motionArgs:{forward:!0},operatorArgs:{shouldMoveCursor:!0},context:"normal"},{keys:"~",type:"operator",operator:"changeCase",context:"visual"},{keys:"<C-w>",type:"operatorMotion",operator:"delete",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1},context:"insert"},{keys:"<C-i>",type:"action",action:"jumpListWalk",actionArgs:{forward:!0}},{keys:"<C-o>",type:"action",action:"jumpListWalk",actionArgs:{forward:!1}},{keys:"<C-e>",type:"action",action:"scroll",actionArgs:{forward:!0,linewise:!0}},{keys:"<C-y>",type:"action",action:"scroll",actionArgs:{forward:!1,linewise:!0}},{keys:"a",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"charAfter"},context:"normal"},{keys:"A",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"eol"},context:"normal"},{keys:"A",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"endOfSelectedArea"},context:"visual"},{keys:"i",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"inplace"},context:"normal"},{keys:"I",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"firstNonBlank"},context:"normal"},{keys:"I",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"startOfSelectedArea"},context:"visual"},{keys:"o",type:"action",action:"newLineAndEnterInsertMode",isEdit:!0,interlaceInsertRepeat:!0,actionArgs:{after:!0},context:"normal"},{keys:"O",type:"action",action:"newLineAndEnterInsertMode",isEdit:!0,interlaceInsertRepeat:!0,actionArgs:{after:!1},context:"normal"},{keys:"v",type:"action",action:"toggleVisualMode"},{keys:"V",type:"action",action:"toggleVisualMode",actionArgs:{linewise:!0}},{keys:"<C-v>",type:"action",action:"toggleVisualMode",actionArgs:{blockwise:!0}},{keys:"gv",type:"action",action:"reselectLastSelection"},{keys:"J",type:"action",action:"joinLines",isEdit:!0},{keys:"p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!0,isEdit:!0}},{keys:"P",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!1,isEdit:!0}},{keys:"r<character>",type:"action",action:"replace",isEdit:!0},{keys:"@<character>",type:"action",action:"replayMacro"},{keys:"q<character>",type:"action",action:"enterMacroRecordMode"},{keys:"R",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{replace:!0}},{keys:"u",type:"action",action:"undo",context:"normal"},{keys:"u",type:"operator",operator:"changeCase",operatorArgs:{toLower:!0},context:"visual",isEdit:!0},{keys:"U",type:"operator",operator:"changeCase",operatorArgs:{toLower:!1},context:"visual",isEdit:!0},{keys:"<C-r>",type:"action",action:"redo"},{keys:"m<character>",type:"action",action:"setMark"},{keys:'"<character>',type:"action",action:"setRegister"},{keys:"zz",type:"action",action:"scrollToCursor",actionArgs:{position:"center"}},{keys:"z.",type:"action",action:"scrollToCursor",actionArgs:{position:"center"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"zt",type:"action",action:"scrollToCursor",actionArgs:{position:"top"}},{keys:"z<CR>",type:"action",action:"scrollToCursor",actionArgs:{position:"top"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"z-",type:"action",action:"scrollToCursor",actionArgs:{position:"bottom"}},{keys:"zb",type:"action",action:"scrollToCursor",actionArgs:{position:"bottom"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:".",type:"action",action:"repeatLastEdit"},{keys:"<C-a>",type:"action",action:"incrementNumberToken",isEdit:!0,actionArgs:{increase:!0,backtrack:!1}},{keys:"<C-x>",type:"action",action:"incrementNumberToken",isEdit:!0,actionArgs:{increase:!1,backtrack:!1}},{keys:"a<character>",type:"motion",motion:"textObjectManipulation"},{keys:"i<character>",type:"motion",motion:"textObjectManipulation",motionArgs:{textObjectInner:!0}},{keys:"/",type:"search",searchArgs:{forward:!0,querySrc:"prompt",toJumplist:!0}},{keys:"?",type:"search",searchArgs:{forward:!1,querySrc:"prompt",toJumplist:!0}},{keys:"*",type:"search",searchArgs:{forward:!0,querySrc:"wordUnderCursor",wholeWordOnly:!0,toJumplist:!0}},{keys:"#",type:"search",searchArgs:{forward:!1,querySrc:"wordUnderCursor",wholeWordOnly:!0,toJumplist:!0}},{keys:"g*",type:"search",searchArgs:{forward:!0,querySrc:"wordUnderCursor",toJumplist:!0}},{keys:"g#",type:"search",searchArgs:{forward:!1,querySrc:"wordUnderCursor",toJumplist:!0}},{keys:":",type:"ex"}],b=d.Pos,w=[16,17,18,91],E={Enter:"CR",Backspace:"BS",Delete:"Del"},S=/Mac/.test(navigator.platform),x=function(){return st};d.defineOption("vimMode",!1,function(e,t,n){t&&e.getOption("keyMap")!="vim"?e.setOption("keyMap","vim"):!t&&n!=d.Init&&/^vim/.test(e.getOption("keyMap"))&&e.setOption("keyMap","default")});var _=/[\d]/,D=[/\w/,/[^\w\s]/],P=[/\S/],B=H(65,26),j=H(97,26),F=H(48,10),I=[].concat(B,j,F,["<",">"]),q=[].concat(B,j,F,["-",'"',".",":","/"]),J={},Y=function(){function s(s,o,u){function l(n){var r=++t%e,o=i[r];o&&o.clear(),i[r]=s.setBookmark(n)}var a=t%e,f=i[a];if(f){var c=f.find();c&&!Nt(c,o)&&l(o)}else l(o);l(u),n=t,r=t-e+1,r<0&&(r=0)}function o(s,o){t+=o,t>n?t=n:t<r&&(t=r);var u=i[(e+t)%e];if(u&&!u.find()){var a=o>0?1:-1,f,l=s.getCursor();do{t+=a,u=i[(e+t)%e];if(u&&(f=u.find())&&!Nt(l,f))break}while(t<n&&t>r)}return u}var e=100,t=-1,n=0,r=0,i=new Array(e);return{cachedCursor:undefined,add:s,move:o}},Z=function(e){return e?{changes:e.changes,expectCursorActivityForChange:e.expectCursorActivityForChange}:{changes:[],expectCursorActivityForChange:!1}};et.prototype={exitMacroRecordMode:function(){var e=nt.macroModeState;e.onRecordingDone&&e.onRecordingDone(),e.onRecordingDone=undefined,e.isRecording=!1},enterMacroRecordMode:function(e,t){var n=nt.registerController.getRegister(t);n&&(n.clear(),this.latestRegister=t,e.openDialog&&(this.onRecordingDone=e.openDialog("(recording)["+t+"]",null,{bottom:!0})),this.isRecording=!0)}};var nt,it,st={buildKeyMap:function(){},getRegisterController:function(){return nt.registerController},resetVimGlobalState_:rt,getVimGlobalState_:function(){return nt},maybeInitVimState_:tt,InsertModeKey:Wn,map:function(e,t,n){Dn.map(e,t,n)},unmap:function(e,t){Dn.unmap(e,t)},setOption:Q,getOption:G,defineOption:K,defineEx:function(e,t,n){if(e.indexOf(t)!==0)throw new Error('(Vim.defineEx) "'+t+'" is not a prefix of "'+e+'", command not registered');_n[e]=n,Dn.commandMap_[t]={name:e,shortName:t,type:"api"}},handleKey:function(e,t,n){function i(){var r=nt.macroModeState;if(r.isRecording){if(t=="q")return r.exitMacroRecordMode(),ut(e),!0;n!="mapping"&&jn(r,t)}}function s(){if(t=="<Esc>")return ut(e),r.visualMode?Wt(e):r.insertMode&&Hn(e),!0}function o(n){var r;while(n)r=/<\w+-.+?>|<\w+>|./.exec(n),t=r[0],n=n.substring(r.index+t.length),d.Vim.handleKey(e,t,"mapping")}function u(){if(s())return!0;var n=r.inputState.keyBuffer=r.inputState.keyBuffer+t,i=t.length==1,u=ct.matchCommand(n,y,r.inputState,"insert");while(n.length>1&&u.type!="full"){var n=r.inputState.keyBuffer=n.slice(1),a=ct.matchCommand(n,y,r.inputState,"insert");a.type!="none"&&(u=a)}if(u.type=="none")return ut(e),!1;if(u.type=="partial")return it&&window.clearTimeout(it),it=window.setTimeout(function(){r.insertMode&&r.inputState.keyBuffer&&ut(e)},G("insertModeEscKeysTimeout")),!i;it&&window.clearTimeout(it);if(i){var f=e.getCursor();e.replaceRange("",yt(f,0,-(n.length-1)),f,"+input")}ut(e);var l=u.command;return l.type=="keyToKey"?o(l.toKeys):ct.processCommand(e,r,l),!0}function a(){if(i()||s())return!0;var n=r.inputState.keyBuffer=r.inputState.keyBuffer+t;if(/^[1-9]\d*$/.test(n))return!0;var u=/^(\d*)(.*)$/.exec(n);if(!u)return ut(e),!1;var a=r.visualMode?"visual":"normal",f=ct.matchCommand(u[2]||u[1],y,r.inputState,a);if(f.type=="none")return ut(e),!1;if(f.type=="partial")return!0;r.inputState.keyBuffer="";var l=f.command,u=/^(\d*)(.*)$/.exec(n);return u[1]&&u[1]!="0"&&r.inputState.pushRepeatDigit(u[1]),l.type=="keyToKey"?o(l.toKeys):ct.processCommand(e,r,l),!0}var r=tt(e);return e.operation(function(){e.curOp.isVimOp=!0;try{return r.insertMode?u():a()}catch(t){throw e.state.vim=undefined,tt(e),t}})},handleEx:function(e,t){Dn.processCommand(e,t)}};ot.prototype.pushRepeatDigit=function(e){this.operator?this.motionRepeat=this.motionRepeat.concat(e):this.prefixRepeat=this.prefixRepeat.concat(e)},ot.prototype.getRepeat=function(){var e=0;if(this.prefixRepeat.length>0||this.motionRepeat.length>0)e=1,this.prefixRepeat.length>0&&(e*=parseInt(this.prefixRepeat.join(""),10)),this.motionRepeat.length>0&&(e*=parseInt(this.motionRepeat.join(""),10));return e},at.prototype={setText:function(e,t,n){this.keyBuffer=[e||""],this.linewise=!!t,this.blockwise=!!n},pushText:function(e,t){t&&(this.linewise||this.keyBuffer.push("\n"),this.linewise=!0),this.keyBuffer.push(e)},pushInsertModeChanges:function(e){this.insertModeChanges.push(Z(e))},pushSearchQuery:function(e){this.searchQueries.push(e)},clear:function(){this.keyBuffer=[],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!1},toString:function(){return this.keyBuffer.join("")}},ft.prototype={pushText:function(e,t,n,r,i){r&&n.charAt(0)=="\n"&&(n=n.slice(1)+"\n"),r&&n.charAt(n.length-1)!=="\n"&&(n+="\n");var s=this.isValidRegister(e)?this.getRegister(e):null;if(!s){switch(t){case"yank":this.registers[0]=new at(n,r,i);break;case"delete":case"change":n.indexOf("\n")==-1?this.registers["-"]=new at(n,r):(this.shiftNumericRegisters_(),this.registers[1]=new at(n,r))}this.unnamedRegister.setText(n,r,i);return}var o=X(e);o?s.pushText(n,r):s.setText(n,r,i),this.unnamedRegister.setText(s.toString(),r)},getRegister:function(e){return this.isValidRegister(e)?(e=e.toLowerCase(),this.registers[e]||(this.registers[e]=new at),this.registers[e]):this.unnamedRegister},isValidRegister:function(e){return e&&$(e,q)},shiftNumericRegisters_:function(){for(var e=9;e>=2;e--)this.registers[e]=this.getRegister(""+(e-1))}},lt.prototype={nextMatch:function(e,t){var n=this.historyBuffer,r=t?-1:1;this.initialPrefix===null&&(this.initialPrefix=e);for(var i=this.iterator+r;t?i>=0:i<n.length;i+=r){var s=n[i];for(var o=0;o<=s.length;o++)if(this.initialPrefix==s.substring(0,o))return this.iterator=i,s}if(i>=n.length)return this.iterator=n.length,this.initialPrefix;if(i<0)return e},pushInput:function(e){var t=this.historyBuffer.indexOf(e);t>-1&&this.historyBuffer.splice(t,1),e.length&&this.historyBuffer.push(e)},reset:function(){this.initialPrefix=null,this.iterator=this.historyBuffer.length}};var ct={matchCommand:function(e,t,n,r){var i=wt(e,t,r,n);if(!i.full&&!i.partial)return{type:"none"};if(!i.full&&i.partial)return{type:"partial"};var s;for(var o=0;o<i.full.length;o++){var u=i.full[o];s||(s=u)}return s.keys.slice(-11)=="<character>"&&(n.selectedCharacter=St(e)),{type:"full",command:s}},processCommand:function(e,t,n){t.inputState.repeatOverride=n.repeatOverride;switch(n.type){case"motion":this.processMotion(e,t,n);break;case"operator":this.processOperator(e,t,n);break;case"operatorMotion":this.processOperatorMotion(e,t,n);break;case"action":this.processAction(e,t,n);break;case"search":this.processSearch(e,t,n),ut(e);break;case"ex":case"keyToEx":this.processEx(e,t,n),ut(e);break;default:}},processMotion:function(e,t,n){t.inputState.motion=n.motion,t.inputState.motionArgs=gt(n.motionArgs),this.evalInput(e,t)},processOperator:function(e,t,n){var r=t.inputState;if(r.operator){if(r.operator==n.operator){r.motion="expandToLine",r.motionArgs={linewise:!0},this.evalInput(e,t);return}ut(e)}r.operator=n.operator,r.operatorArgs=gt(n.operatorArgs),t.visualMode&&this.evalInput(e,t)},processOperatorMotion:function(e,t,n){var r=t.visualMode,i=gt(n.operatorMotionArgs);i&&r&&i.visualLine&&(t.visualLine=!0),this.processOperator(e,t,n),r||this.processMotion(e,t,n)},processAction:function(e,t,n){var r=t.inputState,i=r.getRepeat(),s=!!i,o=gt(n.actionArgs)||{};r.selectedCharacter&&(o.selectedCharacter=r.selectedCharacter),n.operator&&this.processOperator(e,t,n),n.motion&&this.processMotion(e,t,n),(n.motion||n.operator)&&this.evalInput(e,t),o.repeat=i||1,o.repeatIsExplicit=s,o.registerName=r.registerName,ut(e),t.lastMotion=null,n.isEdit&&this.recordLastEdit(t,r,n),vt[n.action](e,o,t)},processSearch:function(e,t,n){function a(r,i,s){nt.searchHistoryController.pushInput(r),nt.searchHistoryController.reset();try{xn(e,r,i,s)}catch(o){yn(e,"Invalid regex: "+r);return}ct.processMotion(e,t,{type:"motion",motion:"findNext",motionArgs:{forward:!0,toJumplist:n.searchArgs.toJumplist}})}function f(t){e.scrollTo(u.left,u.top),a(t,!0,!0);var n=nt.macroModeState;n.isRecording&&In(n,t)}function l(t,n,i){var s=d.keyName(t),o;s=="Up"||s=="Down"?(o=s=="Up"?!0:!1,n=nt.searchHistoryController.nextMatch(n,o)||"",i(n)):s!="Left"&&s!="Right"&&s!="Ctrl"&&s!="Alt"&&s!="Shift"&&nt.searchHistoryController.reset();var a;try{a=xn(e,n,!0,!0)}catch(t){}a?e.scrollIntoView(Cn(e,!r,a),30):(kn(e),e.scrollTo(u.left,u.top))}function c(t,n,r){var i=d.keyName(t);if(i=="Esc"||i=="Ctrl-C"||i=="Ctrl-[")nt.searchHistoryController.pushInput(n),nt.searchHistoryController.reset(),xn(e,o),kn(e),e.scrollTo(u.left,u.top),d.e_stop(t),r(),e.focus()}if(!e.getSearchCursor)return;var r=n.searchArgs.forward,i=n.searchArgs.wholeWordOnly;ln(e).setReversed(!r);var s=r?"/":"?",o=ln(e).getQuery(),u=e.getScrollInfo();switch(n.searchArgs.querySrc){case"prompt":var h=nt.macroModeState;if(h.isPlaying){var p=h.replaySearchQueries.shift();a(p,!0,!1)}else En(e,{onClose:f,prefix:s,desc:wn,onKeyUp:l,onKeyDown:c});break;case"wordUnderCursor":var v=Jt(e,!1,!0,!1,!0),m=!0;v||(v=Jt(e,!1,!0,!1,!1),m=!1);if(!v)return;var p=e.getLine(v.start.line).substring(v.start.ch,v.end.ch);m&&i?p="\\b"+p+"\\b":p=Dt(p),nt.jumpList.cachedCursor=e.getCursor(),e.setCursor(v.start),a(p,!0,!1)}},processEx:function(e,t,n){function r(t){nt.exCommandHistoryController.pushInput(t),nt.exCommandHistoryController.reset(),Dn.processCommand(e,t)}function i(t,n,r){var i=d.keyName(t),s;if(i=="Esc"||i=="Ctrl-C"||i=="Ctrl-[")nt.exCommandHistoryController.pushInput(n),nt.exCommandHistoryController.reset(),d.e_stop(t),r(),e.focus();i=="Up"||i=="Down"?(s=i=="Up"?!0:!1,n=nt.exCommandHistoryController.nextMatch(n,s)||"",r(n)):i!="Left"&&i!="Right"&&i!="Ctrl"&&i!="Alt"&&i!="Shift"&&nt.exCommandHistoryController.reset()}n.type=="keyToEx"?Dn.processCommand(e,n.exArgs.input):t.visualMode?En(e,{onClose:r,prefix:":",value:"'<,'>",onKeyDown:i}):En(e,{onClose:r,prefix:":",onKeyDown:i})},evalInput:function(e,t){var n=t.inputState,r=n.motion,i=n.motionArgs||{},s=n.operator,o=n.operatorArgs||{},u=n.registerName,a=t.sel,f=Tt(t.visualMode?a.head:e.getCursor("head")),l=Tt(t.visualMode?a.anchor:e.getCursor("anchor")),c=Tt(f),h=Tt(l),p,d,v;s&&this.recordLastEdit(t,n),n.repeatOverride!==undefined?v=n.repeatOverride:v=n.getRepeat();if(v>0&&i.explicitRepeat)i.repeatIsExplicit=!0;else if(i.noRepeat||!i.explicitRepeat&&v===0)v=1,i.repeatIsExplicit=!1;n.selectedCharacter&&(i.selectedCharacter=o.selectedCharacter=n.selectedCharacter),i.repeat=v,ut(e);if(r){var m=ht[r](e,f,i,t);t.lastMotion=ht[r];if(!m)return;if(i.toJumplist){var g=nt.jumpList,y=g.cachedCursor;y?(Kt(e,y,m),delete g.cachedCursor):Kt(e,f,m)}m instanceof Array?(d=m[0],p=m[1]):p=m,p||(p=Tt(f)),t.visualMode?(p=mt(e,p,!0),d&&(d=mt(e,d,!0)),d=d||h,a.anchor=d,a.head=p,Rt(e),sn(e,t,"<",Ct(d,p)?d:p),sn(e,t,">",Ct(d,p)?p:d)):s||(p=mt(e,p),e.setCursor(p.line,p.ch))}if(s){if(o.lastSel){d=h;var w=o.lastSel,E=Math.abs(w.head.line-w.anchor.line),S=Math.abs(w.head.ch-w.anchor.ch);w.visualLine?p=b(h.line+E,h.ch):w.visualBlock?p=b(h.line+E,h.ch+S):w.head.line==w.anchor.line?p=b(h.line,h.ch+S):p=b(h.line+E,h.ch),t.visualMode=!0,t.visualLine=w.visualLine,t.visualBlock=w.visualBlock,a=t.sel={anchor:d,head:p},Rt(e)}else t.visualMode&&(o.lastSel={anchor:Tt(a.anchor),head:Tt(a.head),visualBlock:t.visualBlock,visualLine:t.visualLine});var x,T,N,C,k;if(t.visualMode){x=kt(a.head,a.anchor),T=Lt(a.head,a.anchor),N=t.visualLine||o.linewise,C=t.visualBlock?"block":N?"line":"char",k=Ut(e,{anchor:x,head:T},C);if(N){var L=k.ranges;if(C=="block")for(var A=0;A<L.length;A++)L[A].head.ch=Ot(e,L[A].head.line);else C=="line"&&(L[0].head=b(L[0].head.line+1,0))}}else{x=Tt(d||h),T=Tt(p||c);if(Ct(T,x)){var O=x;x=T,T=O}N=i.linewise||o.linewise,N?Vt(e,x,T):i.forward&&Xt(e,x,T),C="char";var M=!i.inclusive||N;k=Ut(e,{anchor:x,head:T},C,M)}e.setSelections(k.ranges,k.primary),t.lastMotion=null,o.repeat=v,o.registerName=u,o.linewise=N;var _=dt[s](e,o,k.ranges,h,p);t.visualMode&&Wt(e),_&&e.setCursor(_)}},recordLastEdit:function(e,t,n){var r=nt.macroModeState;if(r.isPlaying)return;e.lastEditInputState=t,e.lastEditActionCommand=n,r.lastInsertModeChanges.changes=[],r.lastInsertModeChanges.expectCursorActivityForChange=!1}},ht={moveToTopLine:function(e,t,n){var r=An(e).top+n.repeat-1;return b(r,$t(e.getLine(r)))},moveToMiddleLine:function(e){var t=An(e),n=Math.floor((t.top+t.bottom)*.5);return b(n,$t(e.getLine(n)))},moveToBottomLine:function(e,t,n){var r=An(e).bottom-n.repeat+1;return b(r,$t(e.getLine(r)))},expandToLine:function(e,t,n){var r=t;return b(r.line+n.repeat-1,Infinity)},findNext:function(e,t,n){var r=ln(e),i=r.getQuery();if(!i)return;var s=!n.forward;return s=r.isReversed()?!s:s,Nn(e,i),Cn(e,s,i,n.repeat)},goToMark:function(e,t,n,r){var i=r.marks[n.selectedCharacter];if(i){var s=i.find();return n.linewise?{line:s.line,ch:$t(e.getLine(s.line))}:s}return null},moveToOtherHighlightedEnd:function(e,t,n,r){if(r.visualBlock&&n.sameLine){var i=r.sel;return[mt(e,b(i.anchor.line,i.head.ch)),mt(e,b(i.head.line,i.anchor.ch))]}return[r.sel.head,r.sel.anchor]},jumpToMark:function(e,t,n,r){var i=t;for(var s=0;s<n.repeat;s++){var o=i;for(var u in r.marks){if(!U(u))continue;var a=r.marks[u].find(),f=n.forward?Ct(a,o):Ct(o,a);if(f)continue;if(n.linewise&&a.line==o.line)continue;var l=Nt(o,i),c=n.forward?At(o,a,i):At(i,a,o);if(l||c)i=a}}return n.linewise&&(i=b(i.line,$t(e.getLine(i.line)))),i},moveByCharacters:function(e,t,n){var r=t,i=n.repeat,s=n.forward?r.ch+i:r.ch-i;return b(r.line,s)},moveByLines:function(e,t,n,r){var i=t,s=i.ch;switch(r.lastMotion){case this.moveByLines:case this.moveByDisplayLines:case this.moveByScroll:case this.moveToColumn:case this.moveToEol:s=r.lastHPos;break;default:r.lastHPos=s}var o=n.repeat+(n.repeatOffset||0),u=n.forward?i.line+o:i.line-o,a=e.firstLine(),f=e.lastLine();if(u<a&&i.line==a||u>f&&i.line==f)return;return n.toFirstChar&&(s=$t(e.getLine(u)),r.lastHPos=s),r.lastHSPos=e.charCoords(b(u,s),"div").left,b(u,s)},moveByDisplayLines:function(e,t,n,r){var i=t;switch(r.lastMotion){case this.moveByDisplayLines:case this.moveByScroll:case this.moveByLines:case this.moveToColumn:case this.moveToEol:break;default:r.lastHSPos=e.charCoords(i,"div").left}var s=n.repeat,o=e.findPosV(i,n.forward?s:-s,"line",r.lastHSPos);if(o.hitSide)if(n.forward)var u=e.charCoords(o,"div"),a={top:u.top+8,left:r.lastHSPos},o=e.coordsChar(a,"div");else{var f=e.charCoords(b(e.firstLine(),0),"div");f.left=r.lastHSPos,o=e.coordsChar(f,"div")}return r.lastHPos=o.ch,o},moveByPage:function(e,t,n){var r=t,i=n.repeat;return e.findPosV(r,n.forward?i:-i,"page")},moveByParagraph:function(e,t,n){var r=t.line,i=n.repeat,s=n.forward?1:-1;for(var o=0;o<i;o++){if(!n.forward&&r===e.firstLine()||n.forward&&r==e.lastLine())break;r+=s;while(r!==e.firstLine()&&r!=e.lastLine()&&e.getLine(r))r+=s}return b(r,0)},moveByScroll:function(e,t,n,r){var i=e.getScrollInfo(),s=null,o=n.repeat;o||(o=i.clientHeight/(2*e.defaultTextHeight()));var u=e.charCoords(t,"local");n.repeat=o;var s=ht.moveByDisplayLines(e,t,n,r);if(!s)return null;var a=e.charCoords(s,"local");return e.scrollTo(null,i.top+a.top-u.top),s},moveByWords:function(e,t,n){return tn(e,t,n.repeat,!!n.forward,!!n.wordEnd,!!n.bigWord)},moveTillCharacter:function(e,t,n){var r=n.repeat,i=nn(e,r,n.forward,n.selectedCharacter),s=n.forward?-1:1;return Qt(s,n),i?(i.ch+=s,i):null},moveToCharacter:function(e,t,n){var r=n.repeat;return Qt(0,n),nn(e,r,n.forward,n.selectedCharacter)||t},moveToSymbol:function(e,t,n){var r=n.repeat;return Zt(e,r,n.forward,n.selectedCharacter)||t},moveToColumn:function(e,t,n,r){var i=n.repeat;return r.lastHPos=i-1,r.lastHSPos=e.charCoords(t,"div").left,rn(e,i)},moveToEol:function(e,t,n,r){var i=t;r.lastHPos=Infinity;var s=b(i.line+n.repeat-1,Infinity),o=e.clipPos(s);return o.ch--,r.lastHSPos=e.charCoords(o,"div").left,s},moveToFirstNonWhiteSpaceCharacter:function(e,t){var n=t;return b(n.line,$t(e.getLine(n.line)))},moveToMatchedSymbol:function(e,t){var n=t,r=n.line,i=n.ch,s=e.getLine(r),o;do{o=s.charAt(i++);if(o&&z(o)){var u=e.getTokenTypeAt(b(r,i));if(u!=="string"&&u!=="comment")break}}while(o);if(o){var a=e.findMatchingBracket(b(r,i));return a.to}return n},moveToStartOfLine:function(e,t){return b(t.line,0)},moveToLineOrEdgeOfDocument:function(e,t,n){var r=n.forward?e.lastLine():e.firstLine();return n.repeatIsExplicit&&(r=n.repeat-e.getOption("firstLineNumber")),b(r,$t(e.getLine(r)))},textObjectManipulation:function(e,t,n){var r={"(":")",")":"(","{":"}","}":"{","[":"]","]":"["},i={"'":!0,'"':!0},s=n.selectedCharacter;s=="b"?s="(":s=="B"&&(s="{");var o=!n.textObjectInner,u;if(r[s])u=un(e,t,s,o);else if(i[s])u=an(e,t,s,o);else if(s==="W")u=Jt(e,o,!0,!0);else if(s==="w")u=Jt(e,o,!0,!1);else{if(s!=="p")return null;u=expandParagraphUnderCursor(e,o,!0,!1)}return e.state.vim.visualMode?qt(e,u.start,u.end):[u.start,u.end]},repeatLastCharacterSearch:function(e,t,n){var r=nt.lastChararacterSearch,i=n.repeat,s=n.forward===r.forward,o=(r.increment?1:0)*(s?-1:1);e.moveH(-o,"char"),n.inclusive=s?!0:!1;var u=nn(e,i,s,r.selectedCharacter);return u?(u.ch+=o,u):(e.moveH(o,"char"),t)}},dt={change:function(e,t,n){var r,i,s=e.state.vim;nt.macroModeState.lastInsertModeChanges.inVisualBlock=s.visualBlock;if(!s.visualMode){var o=n[0].anchor,u=n[0].head;i=e.getRange(o,u);if(!V(i)){var a=/\s+$/.exec(i);a&&(u=yt(u,0,-a[0].length),i=i.slice(0,-a[0].length))}var f=u.line-1==e.lastLine();e.replaceRange("",o,u),t.linewise&&!f&&(d.commands.newlineAndIndent(e),o.ch=null),r=o}else{i=e.getSelection();var l=pt("",n.length);e.replaceSelections(l),r=kt(n[0].head,n[0].anchor)}nt.registerController.pushText(t.registerName,"change",i,t.linewise,n.length>1),vt.enterInsertMode(e,{head:r},e.state.vim)},"delete":function(e,t,n){var r,i,s=e.state.vim;if(!s.visualBlock){var o=n[0].anchor,u=n[0].head;t.linewise&&u.line!=e.firstLine()&&o.line==e.lastLine()&&o.line==u.line-1&&(o.line==e.firstLine()?o.ch=0:o=b(o.line-1,Ot(e,o.line-1))),i=e.getRange(o,u),e.replaceRange("",o,u),r=o,t.linewise&&(r=ht.moveToFirstNonWhiteSpaceCharacter(e,o))}else{i=e.getSelection();var a=pt("",n.length);e.replaceSelections(a),r=n[0].anchor}return nt.registerController.pushText(t.registerName,"delete",i,t.linewise,s.visualBlock),r},indent:function(e,t,n){var r=e.state.vim,i=n[0].anchor.line,s=r.visualBlock?n[n.length-1].anchor.line:n[0].head.line,o=r.visualMode?t.repeat:1;t.linewise&&s--;for(var u=i;u<=s;u++)for(var a=0;a<o;a++)e.indentLine(u,t.indentRight);return ht.moveToFirstNonWhiteSpaceCharacter(e,n[0].anchor)},changeCase:function(e,t,n,r,i){var s=e.getSelections(),o=[],u=t.toLower;for(var a=0;a<s.length;a++){var f=s[a],l="";if(u===!0)l=f.toLowerCase();else if(u===!1)l=f.toUpperCase();else for(var c=0;c<f.length;c++){var h=f.charAt(c);l+=X(h)?h.toLowerCase():h.toUpperCase()}o.push(l)}return e.replaceSelections(o),t.shouldMoveCursor?i:!e.state.vim.visualMode&&t.linewise&&n[0].anchor.line+1==n[0].head.line?ht.moveToFirstNonWhiteSpaceCharacter(e,r):t.linewise?r:kt(n[0].anchor,n[0].head)},yank:function(e,t,n,r){var i=e.state.vim,s=e.getSelection(),o=i.visualMode?kt(i.sel.anchor,i.sel.head,n[0].head,n[0].anchor):r;return nt.registerController.pushText(t.registerName,"yank",s,t.linewise,i.visualBlock),o}},vt={jumpListWalk:function(e,t,n){if(n.visualMode)return;var r=t.repeat,i=t.forward,s=nt.jumpList,o=s.move(e,i?r:-r),u=o?o.find():undefined;u=u?u:e.getCursor(),e.setCursor(u)},scroll:function(e,t,n){if(n.visualMode)return;var r=t.repeat||1,i=e.defaultTextHeight(),s=e.getScrollInfo().top,o=i*r,u=t.forward?s+o:s-o,a=Tt(e.getCursor()),f=e.charCoords(a,"local");if(t.forward)u>f.top?(a.line+=(u-f.top)/i,a.line=Math.ceil(a.line),e.setCursor(a),f=e.charCoords(a,"local"),e.scrollTo(null,f.top)):e.scrollTo(null,u);else{var l=u+e.getScrollInfo().clientHeight;l<f.bottom?(a.line-=(f.bottom-l)/i,a.line=Math.floor(a.line),e.setCursor(a),f=e.charCoords(a,"local"),e.scrollTo(null,f.bottom-e.getScrollInfo().clientHeight)):e.scrollTo(null,u)}},scrollToCursor:function(e,t){var n=e.getCursor().line,r=e.charCoords(b(n,0),"local"),i=e.getScrollInfo().clientHeight,s=r.top,o=r.bottom-s;switch(t.position){case"center":s=s-i/2+o;break;case"bottom":s=s-i+o*1.4;break;case"top":s+=o*.4}e.scrollTo(null,s)},replayMacro:function(e,t,n){var r=t.selectedCharacter,i=t.repeat,s=nt.macroModeState;r=="@"&&(r=s.latestRegister);while(i--)Bn(e,n,s,r)},enterMacroRecordMode:function(e,t){var n=nt.macroModeState,r=t.selectedCharacter;n.enterMacroRecordMode(e,r)},enterInsertMode:function(e,t,n){if(e.getOption("readOnly"))return;n.insertMode=!0,n.insertModeRepeat=t&&t.repeat||1;var r=t?t.insertAt:null,i=n.sel,s=t.head||e.getCursor("head"),o=e.listSelections().length;if(r=="eol")s=b(s.line,Ot(e,s.line));else if(r=="charAfter")s=yt(s,0,1);else if(r=="firstNonBlank")s=ht.moveToFirstNonWhiteSpaceCharacter(e,s);else if(r=="startOfSelectedArea")n.visualBlock?(s=b(Math.min(i.head.line,i.anchor.line),Math.min(i.head.ch,i.anchor.ch)),o=Math.abs(i.head.line-i.anchor.line)+1):i.head.line<i.anchor.line?s=i.head:s=b(i.anchor.line,0);else if(r=="endOfSelectedArea")n.visualBlock?(s=b(Math.min(i.head.line,i.anchor.line),Math.max(i.head.ch+1,i.anchor.ch)),o=Math.abs(i.head.line-i.anchor.line)+1):i.head.line>=i.anchor.line?s=yt(i.head,0,1):s=b(i.anchor.line,0);else if(r=="inplace"&&n.visualMode)return;e.setOption("keyMap","vim-insert"),e.setOption("disableInput",!1),t&&t.replace?(e.toggleOverwrite(!0),e.setOption("keyMap","vim-replace"),d.signal(e,"vim-mode-change",{mode:"replace"})):(e.setOption("keyMap","vim-insert"),d.signal(e,"vim-mode-change",{mode:"insert"})),nt.macroModeState.isPlaying||(e.on("change",qn),d.on(e.getInputField(),"keydown",Xn)),n.visualMode&&Wt(e),Bt(e,s,o)},toggleVisualMode:function(e,t,n){var r=t.repeat,i=e.getCursor(),s;n.visualMode?n.visualLine^t.linewise||n.visualBlock^t.blockwise?(n.visualLine=!!t.linewise,n.visualBlock=!!t.blockwise,d.signal(e,"vim-mode-change",{mode:"visual",subMode:n.visualLine?"linewise":n.visualBlock?"blockwise":""}),Rt(e)):Wt(e):(n.visualMode=!0,n.visualLine=!!t.linewise,n.visualBlock=!!t.blockwise,s=mt(e,b(i.line,i.ch+r-1),!0),n.sel={anchor:i,head:s},d.signal(e,"vim-mode-change",{mode:"visual",subMode:n.visualLine?"linewise":n.visualBlock?"blockwise":""}),Rt(e),sn(e,n,"<",kt(i,s)),sn(e,n,">",Lt(i,s)))},reselectLastSelection:function(e,t,n){var r=n.lastSelection;n.visualMode&&It(e,n);if(r){var i=r.anchorMark.find(),s=r.headMark.find();if(!i||!s)return;n.sel={anchor:i,head:s},n.visualMode=!0,n.visualLine=r.visualLine,n.visualBlock=r.visualBlock,Rt(e),sn(e,n,"<",kt(i,s)),sn(e,n,">",Lt(i,s)),d.signal(e,"vim-mode-change",{mode:"visual",subMode:n.visualLine?"linewise":n.visualBlock?"blockwise":""})}},joinLines:function(e,t,n){var r,i;if(n.visualMode)r=e.getCursor("anchor"),i=e.getCursor("head"),i.ch=Ot(e,i.line)-1;else{var s=Math.max(t.repeat,2);r=e.getCursor(),i=mt(e,b(r.line+s-1,Infinity))}var o=0;for(var u=r.line;u<i.line;u++){o=Ot(e,r.line);var a=b(r.line+1,Ot(e,r.line+1)),f=e.getRange(r,a);f=f.replace(/\n\s*/g," "),e.replaceRange(f,r,a)}var l=b(r.line,o);e.setCursor(l),n.visualMode&&Wt(e)},newLineAndEnterInsertMode:function(e,t,n){n.insertMode=!0;var r=Tt(e.getCursor());if(r.line===e.firstLine()&&!t.after)e.replaceRange("\n",b(e.firstLine(),0)),e.setCursor(e.firstLine(),0);else{r.line=t.after?r.line:r.line-1,r.ch=Ot(e,r.line),e.setCursor(r);var i=d.commands.newlineAndIndentContinueComment||d.commands.newlineAndIndent;i(e)}this.enterInsertMode(e,{repeat:t.repeat},n)},paste:function(e,t,n){var r=Tt(e.getCursor()),i=nt.registerController.getRegister(t.registerName),s=i.toString();if(!s)return;if(t.matchIndent){var o=e.getOption("tabSize"),u=function(e){var t=e.split(" ").length-1,n=e.split(" ").length-1;return t*o+n*1},a=e.getLine(e.getCursor().line),f=u(a.match(/^\s*/)[0]),l=s.replace(/\n$/,""),c=s!==l,h=u(s.match(/^\s*/)[0]),s=l.replace(/^\s*/gm,function(t){var n=f+(u(t)-h);if(n<0)return"";if(e.getOption("indentWithTabs")){var r=Math.floor(n/o);return Array(r+1).join(" ")}return Array(n+1).join(" ")});s+=c?"\n":""}if(t.repeat>1)var s=Array(t.repeat+1).join(s);var p=i.linewise,d=i.blockwise;if(p)n.visualMode?s=n.visualLine?s.slice(0,-1):"\n"+s.slice(0,s.length-1)+"\n":t.after?(s="\n"+s.slice(0,s.length-1),r.ch=Ot(e,r.line)):r.ch=0;else{if(d){s=s.split("\n");for(var v=0;v<s.length;v++)s[v]=s[v]==""?" ":s[v]}r.ch+=t.after?1:0}var m,g;if(n.visualMode){n.lastPastedText=s;var y,w=Ft(e,n),E=w[0],S=w[1],x=e.getSelection(),T=e.listSelections(),N=(new Array(T.length)).join("1").split("1");n.lastSelection&&(y=n.lastSelection.headMark.find()),nt.registerController.unnamedRegister.setText(x),d?(e.replaceSelections(N),S=b(E.line+s.length-1,E.ch),e.setCursor(E),Ht(e,S),e.replaceSelections(s),m=E):n.visualBlock?(e.replaceSelections(N),e.setCursor(E),e.replaceRange(s,E,E),m=E):(e.replaceRange(s,E,S),m=e.posFromIndex(e.indexFromPos(E)+s.length-1)),y&&(n.lastSelection.headMark=e.setBookmark(y)),p&&(m.ch=0)}else if(d){e.setCursor(r);for(var v=0;v<s.length;v++){var C=r.line+v;C>e.lastLine()&&e.replaceRange("\n",b(C,0));var k=Ot(e,C);k<r.ch&&Pt(e,C,r.ch)}e.setCursor(r),Ht(e,b(r.line+s.length-1,r.ch)),e.replaceSelections(s),m=r}else e.replaceRange(s,r),p&&t.after?m=b(r.line+1,$t(e.getLine(r.line+1))):p&&!t.after?m=b(r.line,$t(e.getLine(r.line))):!p&&t.after?(g=e.indexFromPos(r),m=e.posFromIndex(g+s.length-1)):(g=e.indexFromPos(r),m=e.posFromIndex(g+s.length));n.visualMode&&Wt(e),e.setCursor(m)},undo:function(e,t){e.operation(function(){xt(e,d.commands.undo,t.repeat)(),e.setCursor(e.getCursor("anchor"))})},redo:function(e,t){xt(e,d.commands.redo,t.repeat)()},setRegister:function(e,t,n){n.inputState.registerName=t.selectedCharacter},setMark:function(e,t,n){var r=t.selectedCharacter;sn(e,n,r,e.getCursor())},replace:function(e,t,n){var r=t.selectedCharacter,i=e.getCursor(),s,o,u=e.listSelections();if(n.visualMode)i=e.getCursor("start"),o=e.getCursor("end");else{var a=e.getLine(i.line);s=i.ch+t.repeat,s>a.length&&(s=a.length),o=b(i.line,s)}if(r=="\n")n.visualMode||e.replaceRange("",i,o),(d.commands.newlineAndIndentContinueComment||d.commands.newlineAndIndent)(e);else{var f=e.getRange(i,o);f=f.replace(/[^\n]/g,r);if(n.visualBlock){var l=(new Array(e.getOption("tabSize")+1)).join(" ");f=e.getSelection(),f=f.replace(/\t/g,l).replace(/[^\n]/g,r).split("\n"),e.replaceSelections(f)}else e.replaceRange(f,i,o);n.visualMode?(i=Ct(u[0].anchor,u[0].head)?u[0].anchor:u[0].head,e.setCursor(i),Wt(e)):e.setCursor(yt(o,0,-1))}},incrementNumberToken:function(e,t){var n=e.getCursor(),r=e.getLine(n.line),i=/-?\d+/g,s,o,u,a,f;while((s=i.exec(r))!==null){f=s[0],o=s.index,u=o+f.length;if(n.ch<u)break}if(!t.backtrack&&u<=n.ch)return;if(!f)return;var l=t.increase?1:-1,c=parseInt(f)+l*t.repeat,h=b(n.line,o),p=b(n.line,u);a=c.toString(),e.replaceRange(a,h,p),e.setCursor(b(n.line,o+a.length-1))},repeatLastEdit:function(e,t,n){var r=n.lastEditInputState;if(!r)return;var i=t.repeat;i&&t.repeatIsExplicit?n.lastEditInputState.repeatOverride=i:i=n.lastEditInputState.repeatOverride||i,Vn(e,n,i,!1)},exitInsertMode:Hn},Gt={"(":"bracket",")":"bracket","{":"bracket","}":"bracket","[":"section","]":"section","*":"comment","/":"comment",m:"method",M:"method","#":"preprocess"},Yt={bracket:{isComplete:function(e){if(e.nextCh===e.symb){e.depth++;if(e.depth>=1)return!0}else e.nextCh===e.reverseSymb&&e.depth--;return!1}},section:{init:function(e){e.curMoveThrough=!0,e.symb=(e.forward?"]":"[")===e.symb?"{":"}"},isComplete:function(e){return e.index===0&&e.nextCh===e.symb}},comment:{isComplete:function(e){var t=e.lastCh==="*"&&e.nextCh==="/";return e.lastCh=e.nextCh,t}},method:{init:function(e){e.symb=e.symb==="m"?"{":"}",e.reverseSymb=e.symb==="{"?"}":"{"},isComplete:function(e){return e.nextCh===e.symb?!0:!1}},preprocess:{init:function(e){e.index=0},isComplete:function(e){if(e.nextCh==="#"){var t=e.lineText.match(/#(\w+)/)[1];if(t==="endif"){if(e.forward&&e.depth===0)return!0;e.depth++}else if(t==="if"){if(!e.forward&&e.depth===0)return!0;e.depth--}if(t==="else"&&e.depth===0)return!0}return!1}}};K("pcre",!0,"boolean"),fn.prototype={getQuery:function(){return nt.query},setQuery:function(e){nt.query=e},getOverlay:function(){return this.searchOverlay},setOverlay:function(e){this.searchOverlay=e},isReversed:function(){return nt.isReversed},setReversed:function(e){nt.isReversed=e}};var wn="(Javascript regexp)",On=[{name:"map"},{name:"imap",shortName:"im"},{name:"nmap",shortName:"nm"},{name:"vmap",shortName:"vm"},{name:"unmap"},{name:"write",shortName:"w"},{name:"undo",shortName:"u"},{name:"redo",shortName:"red"},{name:"set",shortName:"set"},{name:"sort",shortName:"sor"},{name:"substitute",shortName:"s",possiblyAsync:!0},{name:"nohlsearch",shortName:"noh"},{name:"delmarks",shortName:"delm"},{name:"registers",shortName:"reg",excludeFromCommandHistory:!0},{name:"global",shortName:"g"}],Mn=function(){this.buildCommandMap_()};Mn.prototype={processCommand:function(e,t,n){var r=e.state.vim,i=nt.registerController.getRegister(":"),s=i.toString();r.visualMode&&Wt(e);var o=new d.StringStream(t);i.setText(t);var u=n||{};u.input=t;try{this.parseInput_(e,o,u)}catch(a){throw yn(e,a),a}var f,l;if(!u.commandName)u.line!==undefined&&(l="move");else{f=this.matchCommand_(u.commandName);if(f){l=f.name,f.excludeFromCommandHistory&&i.setText(s),this.parseCommandArgs_(o,u,f);if(f.type=="exToKey"){for(var c=0;c<f.toKeys.length;c++)d.Vim.handleKey(e,f.toKeys[c],"mapping");return}if(f.type=="exToEx"){this.processCommand(e,f.toInput);return}}}if(!l){yn(e,'Not an editor command ":'+t+'"');return}try{_n[l](e,u),(!f||!f.possiblyAsync)&&u.callback&&u.callback()}catch(a){throw yn(e,a),a}},parseInput_:function(e,t,n){t.eatWhile(":"),t.eat("%")?(n.line=e.firstLine(),n.lineEnd=e.lastLine()):(n.line=this.parseLineSpec_(e,t),n.line!==undefined&&t.eat(",")&&(n.lineEnd=this.parseLineSpec_(e,t)));var r=t.match(/^(\w+)/);return r?n.commandName=r[1]:n.commandName=t.match(/.*/)[0],n},parseLineSpec_:function(e,t){var n=t.match(/^(\d+)/);if(n)return parseInt(n[1],10)-1;switch(t.next()){case".":return e.getCursor().line;case"$":return e.lastLine();case"'":var r=e.state.vim.marks[t.next()];if(r&&r.find())return r.find().line;throw new Error("Mark not set");default:return t.backUp(1),undefined}},parseCommandArgs_:function(e,t,n){if(e.eol())return;t.argString=e.match(/.*/)[0];var r=n.argDelimiter||/\s+/,i=_t(t.argString).split(r);i.length&&i[0]&&(t.args=i)},matchCommand_:function(e){for(var t=e.length;t>0;t--){var n=e.substring(0,t);if(this.commandMap_[n]){var r=this.commandMap_[n];if(r.name.indexOf(e)===0)return r}}return null},buildCommandMap_:function(){this.commandMap_={};for(var e=0;e<On.length;e++){var t=On[e],n=t.shortName||t.name;this.commandMap_[n]=t}},map:function(e,t,n){if(e!=":"&&e.charAt(0)==":"){if(n)throw Error("Mode not supported for ex mappings");var r=e.substring(1);t!=":"&&t.charAt(0)==":"?this.commandMap_[r]={name:r,type:"exToEx",toInput:t.substring(1),user:!0}:this.commandMap_[r]={name:r,type:"exToKey",toKeys:t,user:!0}}else if(t!=":"&&t.charAt(0)==":"){var i={keys:e,type:"keyToEx",exArgs:{input:t.substring(1)},user:!0};n&&(i.context=n),y.unshift(i)}else{var i={keys:e,type:"keyToKey",toKeys:t,user:!0};n&&(i.context=n),y.unshift(i)}},unmap:function(e,t){if(e!=":"&&e.charAt(0)==":"){if(t)throw Error("Mode not supported for ex mappings");var n=e.substring(1);if(this.commandMap_[n]&&this.commandMap_[n].user){delete this.commandMap_[n];return}}else{var r=e;for(var i=0;i<y.length;i++)if(r==y[i].keys&&y[i].context===t&&y[i].user){y.splice(i,1);return}}throw Error("No such mapping.")}};var _n={map:function(e,t,n){var r=t.args;if(!r||r.length<2){e&&yn(e,"Invalid mapping: "+t.input);return}Dn.map(r[0],r[1],n)},imap:function(e,t){this.map(e,t,"insert")},nmap:function(e,t){this.map(e,t,"normal")},vmap:function(e,t){this.map(e,t,"visual")},unmap:function(e,t,n){var r=t.args;if(!r||r.length<1){e&&yn(e,"No such mapping: "+t.input);return}Dn.unmap(r[0],n)},move:function(e,t){ct.processCommand(e,e.state.vim,{type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!1,explicitRepeat:!0,linewise:!0},repeatOverride:t.line+1})},set:function(e,t){var n=t.args;if(!n||n.length<1){e&&yn(e,"Invalid mapping: "+t.input);return}var r=n[0].split("="),i=r[0],s=r[1],o=!1;if(i.charAt(i.length-1)=="?"){if(s)throw Error("Trailing characters: "+t.argString);i=i.substring(0,i.length-1),o=!0}s===undefined&&i.substring(0,2)=="no"&&(i=i.substring(2),s=!1);var u=J[i]&&J[i].type=="boolean";u&&s==undefined&&(s=!0);if(!u&&!s||o){var a=G(i);a===!0||a===!1?yn(e," "+(a?"":"no")+i):yn(e," "+i+"="+a)}else Q(i,s,e)},registers:function(e,t){var n=t.args,r=nt.registerController.registers,i="----------Registers----------<br><br>";if(!n)for(var s in r){var o=r[s].toString();o.length&&(i+='"'+s+" "+o+"<br>")}else{var s;n=n.join("");for(var u=0;u<n.length;u++){s=n.charAt(u);if(!nt.registerController.isValidRegister(s))continue;var a=r[s]||new at;i+='"'+s+" "+a.toString()+"<br>"}}yn(e,i)},sort:function(e,t){function o(){if(t.argString){var e=new d.StringStream(t.argString);e.eat("!")&&(n=!0);if(e.eol())return;if(!e.eatSpace())return"Invalid arguments";var o=e.match(/[a-z]+/);if(o){o=o[0],r=o.indexOf("i")!=-1,i=o.indexOf("u")!=-1;var u=o.indexOf("d")!=-1&&1,a=o.indexOf("x")!=-1&&1,f=o.indexOf("o")!=-1&&1;if(u+a+f>1)return"Invalid arguments";s=u&&"decimal"||a&&"hex"||f&&"octal"}e.eatSpace()&&e.match(/\/.*\//)&&"patterns not supported"}}function w(e,t){if(n){var i;i=e,e=t,t=i}r&&(e=e.toLowerCase(),t=t.toLowerCase());var o=s&&p.exec(e),u=s&&p.exec(t);return o?(o=parseInt((o[1]+o[2]).toLowerCase(),v),u=parseInt((u[1]+u[2]).toLowerCase(),v),o-u):e<t?-1:1}var n,r,i,s,u=o();if(u){yn(e,u+": "+t.argString);return}var a=t.line||e.firstLine(),f=t.lineEnd||t.line||e.lastLine();if(a==f)return;var l=b(a,0),c=b(f,Ot(e,f)),h=e.getRange(l,c).split("\n"),p=s=="decimal"?/(-?)([\d]+)/:s=="hex"?/(-?)(?:0x)?([0-9a-f]+)/i:s=="octal"?/([0-7]+)/:null,v=s=="decimal"?10:s=="hex"?16:s=="octal"?8:null,m=[],g=[];if(s)for(var y=0;y<h.length;y++)p.exec(h[y])?m.push(h[y]):g.push(h[y]);else g=h;m.sort(w),g.sort(w),h=n?m.concat(g):g.concat(m);if(i){var E=h,S;h=[];for(var y=0;y<E.length;y++)E[y]!=S&&h.push(E[y]),S=E[y]}e.replaceRange(h.join("\n"),l,c)},global:function(e,t){var n=t.argString;if(!n){yn(e,"Regular Expression missing from global");return}var r=t.line!==undefined?t.line:e.firstLine(),i=t.lineEnd||t.line||e.lastLine(),s=hn(n),o=n,u;s.length&&(o=s[0],u=s.slice(1,s.length).join("/"));if(o)try{xn(e,o,!0,!0)}catch(a){yn(e,"Invalid regex: "+o);return}var f=ln(e).getQuery(),l=[],c="";for(var h=r;h<=i;h++){var p=f.test(e.getLine(h));p&&(l.push(h+1),c+=e.getLine(h)+"<br>")}if(!u){yn(e,c);return}var d=0,v=function(){if(d<l.length){var t=l[d]+u;Dn.processCommand(e,t,{callback:v})}d++};v()},substitute:function(e,t){if(!e.getSearchCursor)throw new Error("Search feature not available. Requires searchcursor.js or any other getSearchCursor implementation.");var n=t.argString,r=n?hn(n):[],i,s="",o,u,a,f=!1,l=!1;if(r.length)i=r[0],s=r[1],s!==undefined&&(G("pcre")?s=mn(s):s=vn(s),nt.lastSubstituteReplacePart=s),o=r[2]?r[2].split(" "):[];else if(n&&n.length){yn(e,"Substitutions should be of the form :s/pattern/replace/");return}o&&(u=o[0],a=parseInt(o[1]),u&&(u.indexOf("c")!=-1&&(f=!0,u.replace("c","")),u.indexOf("g")!=-1&&(l=!0,u.replace("g","")),i=i+"/"+u));if(i)try{xn(e,i,!0,!0)}catch(c){yn(e,"Invalid regex: "+i);return}s=s||nt.lastSubstituteReplacePart;if(s===undefined){yn(e,"No previous substitute regular expression");return}var h=ln(e),p=h.getQuery(),d=t.line!==undefined?t.line:e.getCursor().line,v=t.lineEnd||d;a&&(d=v,v=d+a-1);var m=mt(e,b(d,0)),g=e.getSearchCursor(p,m);Pn(e,f,l,d,v,g,p,s,t.callback)},redo:d.commands.redo,undo:d.commands.undo,write:function(e){d.commands.save?d.commands.save(e):e.save()},nohlsearch:function(e){kn(e)},delmarks:function(e,t){if(!t.argString||!_t(t.argString)){yn(e,"Argument required");return}var n=e.state.vim,r=new d.StringStream(_t(t.argString));while(!r.eol()){r.eatSpace();var i=r.pos;if(!r.match(/[a-zA-Z]/,!1)){yn(e,"Invalid argument: "+t.argString.substring(i));return}var s=r.next();if(r.match("-",!0)){if(!r.match(/[a-zA-Z]/,!1)){yn(e,"Invalid argument: "+t.argString.substring(i));return}var o=s,u=r.next();if(!(U(o)&&U(u)||X(o)&&X(u))){yn(e,"Invalid argument: "+o+"-");return}var a=o.charCodeAt(0),f=u.charCodeAt(0);if(a>=f){yn(e,"Invalid argument: "+t.argString.substring(i));return}for(var l=0;l<=f-a;l++){var c=String.fromCharCode(a+l);delete n.marks[c]}}else delete n.marks[s]}}},Dn=new Mn;d.keyMap.vim={attach:O,detach:A},K("insertModeEscKeysTimeout",200,"number"),d.keyMap["vim-insert"]={"Ctrl-N":"autocomplete","Ctrl-P":"autocomplete",Enter:function(e){var t=d.commands.newlineAndIndentContinueComment||d.commands.newlineAndIndent;t(e)},fallthrough:["default"],attach:O,detach:A},d.keyMap["await-second"]={fallthrough:["vim-insert"],attach:O,detach:A},d.keyMap["vim-replace"]={Backspace:"goCharLeft",fallthrough:["vim-insert"],attach:O,detach:A},rt(),d.Vim=x(),x=d.Vim,E={"return":"CR",backspace:"BS","delete":"Del",esc:"Esc",left:"Left",right:"Right",up:"Up",down:"Down",space:"Space",home:"Home",end:"End",pageup:"PageUp",pagedown:"PageDown",enter:"CR"};var Jn=x.handleKey;x.handleKey=function(e,t,n){return e.operation(function(){return Jn(e,t,n)},!0)},t.CodeMirror=d;var Gn=x.maybeInitVimState_;t.handler={$id:"ace/keyboard/vim",drawCursor:function(e,t,n,r,s){var o=this.state.vim||{},u=n.characterWidth,a=n.lineHeight,f=t.top,l=t.left;if(!o.insertMode){var c=r.cursor?i.comparePoints(r.cursor,r.start)<=0:s.selection.isBackwards()||s.selection.isEmpty();!c&&l>u&&(l-=u)}!o.insertMode&&o.status&&(a/=2,f+=a),e.left=l+"px",e.top=f+"px",e.width=u+"px",e.height=a+"px"},handleKeyboard:function(e,t,n,r,i){var s=e.editor,o=s.state.cm,u=Gn(o);if(r==-1)return;if(n=="c"&&t==1)return!c.isMac&&s.getCopyText()?(s.once("copy",function(){s.selection.clearSelection()}),{command:"null",passEvent:!0}):{command:coreCommands.stop};u.insertMode||c.isMac&&this.handleMacRepeat(e,t,n)&&(t=-1,n=e.inputChar);if(t==-1||t&1||t===0&&n.length>1){var a=u.insertMode,f=T(t,n,i||{});u.status==null&&(u.status="");var l=Qn(o,f,"user");u=Gn(o),l&&u.status!=null?u.status+=f:u.status==null&&(u.status=""),o._signal("changeStatus");if(!l&&(t!=-1||a))return;return{command:"null",passEvent:!l}}},attach:function(e){e.state||(e.state={});var t=new d(e);e.state.cm=t,e.$vimModeHandler=this,d.keyMap.vim.attach(t),Gn(t).status=null,t.on("vim-command-done",function(){if(t.virtualSelectionMode())return;Gn(t).status=null,t.ace._signal("changeStatus"),t.ace.session.markUndoGroup()}),t.on("changeStatus",function(){t.ace.renderer.updateCursor(),t.ace._signal("changeStatus")}),t.on("vim-mode-change",function(){if(t.virtualSelectionMode())return;t.ace.renderer.setStyle("normal-mode",!Gn(t).insertMode),t._signal("changeStatus")}),t.ace.renderer.setStyle("normal-mode",!Gn(t).insertMode),e.renderer.$cursorLayer.drawCursor=this.drawCursor.bind(t),this.updateMacCompositionHandlers(e,!0)},detach:function(e){var t=e.state.cm;d.keyMap.vim.detach(t),t.destroy(),e.state.cm=null,e.$vimModeHandler=null,e.renderer.$cursorLayer.drawCursor=null,e.renderer.setStyle("normal-mode",!1),this.updateMacCompositionHandlers(e,!1)},getStatusText:function(e){var t=e.state.cm,n=Gn(t);if(n.insertMode)return"INSERT";var r="";return n.visualMode&&(r+="VISUAL",n.visualLine&&(r+=" LINE"),n.visualBlock&&(r+=" BLOCK")),n.status&&(r+=(r?" ":"")+n.status),r},handleMacRepeat:function(e,t,n){if(t==-1)e.inputChar=n,e.lastEvent="input";else if(e.inputChar&&e.$lastHash==t&&e.$lastKey==n){if(e.lastEvent=="input")e.lastEvent="input1";else if(e.lastEvent=="input1")return!0}else e.$lastHash=t,e.$lastKey=n,e.lastEvent="keypress"},updateMacCompositionHandlers:function(e,t){var n=function(t){var n=e.state.cm,r=Gn(n);if(!r.insertMode){var i=this.textInput.getElement();i.blur(),i.focus(),i.value=t}else this.onCompositionUpdateOrig(t)},r=function(t){var n=e.state.cm,r=Gn(n);r.insertMode||this.onCompositionStartOrig(t)};t?e.onCompositionUpdateOrig||(e.onCompositionUpdateOrig=e.onCompositionUpdate,e.onCompositionUpdate=n,e.onCompositionStartOrig=e.onCompositionStart,e.onCompositionStart=r):e.onCompositionUpdateOrig&&(e.onCompositionUpdate=e.onCompositionUpdateOrig,e.onCompositionUpdateOrig=null,e.onCompositionStart=e.onCompositionStartOrig,e.onCompositionStartOrig=null)}};var Yn={getText:function(e,t){return(Math.abs(e.selection.lead.row-t)||t+1+(t<9?"\u00b7":""))+""},getWidth:function(e,t,n){return e.getLength().toString().length*n.characterWidth},update:function(e,t){t.renderer.$loop.schedule(t.renderer.CHANGE_GUTTER)},attach:function(e){e.renderer.$gutterLayer.$renderer=this,e.on("changeSelection",this.update)},detach:function(e){e.renderer.$gutterLayer.$renderer=null,e.off("changeSelection",this.update)}};x.defineOption({name:"wrap",set:function(e,t){t&&t.ace.setOption("wrap",e)},type:"boolean"},!1),y.push({keys:"zc",type:"action",action:"fold",actionArgs:{open:!1}},{keys:"zC",type:"action",action:"fold",actionArgs:{open:!1,all:!0}},{keys:"zo",type:"action",action:"fold",actionArgs:{open:!0}},{keys:"zO",type:"action",action:"fold",actionArgs:{open:!0,all:!0}},{keys:"za",type:"action",action:"fold",actionArgs:{toggle:!0}},{keys:"zA",type:"action",action:"fold",actionArgs:{toggle:!0,all:!0}},{keys:"zf",type:"action",action:"fold",actionArgs:{open:!0,all:!0}},{keys:"zd",type:"action",action:"fold",actionArgs:{open:!0,all:!0}},{keys:"<C-A-j>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorAbove"}},{keys:"<C-A-k>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorBelow"}},{keys:"<C-A-S-j>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorAboveSkipCurrent"}},{keys:"<C-A-S-k>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorBelowSkipCurrent"}},{keys:"<C-A-h>",type:"action",action:"aceCommand",actionArgs:{name:"selectMoreBefore"}},{keys:"<C-A-l>",type:"action",action:"aceCommand",actionArgs:{name:"selectMoreAfter"}},{keys:"<C-A-S-h>",type:"action",action:"aceCommand",actionArgs:{name:"selectNextBefore"}},{keys:"<C-A-S-l>",type:"action",action:"aceCommand",actionArgs:{name:"selectNextAfter"}}),vt.aceCommand=function(e,t,n){e.vimCmd=t,e.ace.inVirtualSelectionMode?e.ace.on("beforeEndOperation",Zn):Zn(null,e.ace)},vt.fold=function(e,t,n){e.ace.execCommand(["toggleFoldWidget","toggleFoldWidget","foldOther","unfoldall"][(t.all?2:0)+(t.open?1:0)])},t.handler.defaultKeymap=y,x.map("Y","yy")})
 
js/ace/src-min-noconflict/mode-css.js DELETED
@@ -1 +0,0 @@
1
- ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../lib/lang"),s=e("./text_highlight_rules").TextHighlightRules,o=t.supportType="animation-fill-mode|alignment-adjust|alignment-baseline|animation-delay|animation-direction|animation-duration|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|animation|appearance|azimuth|backface-visibility|background-attachment|background-break|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|background|baseline-shift|binding|bleed|bookmark-label|bookmark-level|bookmark-state|bookmark-target|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|border|bottom|box-align|box-decoration-break|box-direction|box-flex-group|box-flex|box-lines|box-ordinal-group|box-orient|box-pack|box-shadow|box-sizing|break-after|break-before|break-inside|caption-side|clear|clip|color-profile|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|crop|cue-after|cue-before|cue|cursor|direction|display|dominant-baseline|drop-initial-after-adjust|drop-initial-after-align|drop-initial-before-adjust|drop-initial-before-align|drop-initial-size|drop-initial-value|elevation|empty-cells|fit|fit-position|float-offset|float|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|font|grid-columns|grid-rows|hanging-punctuation|height|hyphenate-after|hyphenate-before|hyphenate-character|hyphenate-lines|hyphenate-resource|hyphens|icon|image-orientation|image-rendering|image-resolution|inline-box-align|left|letter-spacing|line-height|line-stacking-ruby|line-stacking-shift|line-stacking-strategy|line-stacking|list-style-image|list-style-position|list-style-type|list-style|margin-bottom|margin-left|margin-right|margin-top|margin|mark-after|mark-before|mark|marks|marquee-direction|marquee-play-count|marquee-speed|marquee-style|max-height|max-width|min-height|min-width|move-to|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|orphans|outline-color|outline-offset|outline-style|outline-width|outline|overflow-style|overflow-x|overflow-y|overflow|padding-bottom|padding-left|padding-right|padding-top|padding|page-break-after|page-break-before|page-break-inside|page-policy|page|pause-after|pause-before|pause|perspective-origin|perspective|phonemes|pitch-range|pitch|play-during|pointer-events|position|presentation-level|punctuation-trim|quotes|rendering-intent|resize|rest-after|rest-before|rest|richness|right|rotation-point|rotation|ruby-align|ruby-overhang|ruby-position|ruby-span|size|speak-header|speak-numeral|speak-punctuation|speak|speech-rate|stress|string-set|table-layout|target-name|target-new|target-position|target|text-align-last|text-align|text-decoration|text-emphasis|text-height|text-indent|text-justify|text-outline|text-shadow|text-transform|text-wrap|top|transform-origin|transform-style|transform|transition-delay|transition-duration|transition-property|transition-timing-function|transition|unicode-bidi|vertical-align|visibility|voice-balance|voice-duration|voice-family|voice-pitch-range|voice-pitch|voice-rate|voice-stress|voice-volume|volume|white-space-collapse|white-space|widows|width|word-break|word-spacing|word-wrap|z-index",u=t.supportFunction="rgb|rgba|url|attr|counter|counters",a=t.supportConstant="absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero",f=t.supportConstantColor="aqua|black|blue|fuchsia|gray|green|lime|maroon|navy|olive|orange|purple|red|silver|teal|white|yellow",l=t.supportConstantFonts="arial|century|comic|courier|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace",c=t.numRe="\\-?(?:(?:[0-9]+)|(?:[0-9]*\\.[0-9]+))",h=t.pseudoElements="(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b",p=t.pseudoClasses="(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b",d=function(){var e=this.createKeywordMapper({"support.function":u,"support.constant":a,"support.type":o,"support.constant.color":f,"support.constant.fonts":l},"text",!0);this.$rules={start:[{token:"comment",regex:"\\/\\*",push:"comment"},{token:"paren.lparen",regex:"\\{",push:"ruleset"},{token:"string",regex:"@.*?{",push:"media"},{token:"keyword",regex:"#[a-z0-9-_]+"},{token:"variable",regex:"\\.[a-z0-9-_]+"},{token:"string",regex:":[a-z0-9-_]+"},{token:"constant",regex:"[a-z0-9-_]+"},{caseInsensitive:!0}],media:[{token:"comment",regex:"\\/\\*",push:"comment"},{token:"paren.lparen",regex:"\\{",push:"ruleset"},{token:"string",regex:"\\}",next:"pop"},{token:"keyword",regex:"#[a-z0-9-_]+"},{token:"variable",regex:"\\.[a-z0-9-_]+"},{token:"string",regex:":[a-z0-9-_]+"},{token:"constant",regex:"[a-z0-9-_]+"},{caseInsensitive:!0}],comment:[{token:"comment",regex:"\\*\\/",next:"pop"},{defaultToken:"comment"}],ruleset:[{token:"paren.rparen",regex:"\\}",next:"pop"},{token:"comment",regex:"\\/\\*",push:"comment"},{token:"string",regex:'["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'},{token:"string",regex:"['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"},{token:["constant.numeric","keyword"],regex:"("+c+")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"},{token:"constant.numeric",regex:c},{token:"constant.numeric",regex:"#[a-f0-9]{6}"},{token:"constant.numeric",regex:"#[a-f0-9]{3}"},{token:["punctuation","entity.other.attribute-name.pseudo-element.css"],regex:h},{token:["punctuation","entity.other.attribute-name.pseudo-class.css"],regex:p},{token:["support.function","string","support.function"],regex:"(url\\()(.*)(\\))"},{token:e,regex:"\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"},{caseInsensitive:!0}]},this.normalizeRules()};r.inherits(d,s),t.CssHighlightRules=d}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("../range").Range,i=function(){};(function(){this.checkOutdent=function(e,t){return/^\s+$/.test(e)?/^\s*\}/.test(t):!1},this.autoOutdent=function(e,t){var n=e.getLine(t),i=n.match(/^(\s*\})/);if(!i)return 0;var s=i[1].length,o=e.findMatchingBracket({row:t,column:s});if(!o||o.row==t)return 0;var u=this.$getIndent(e.getLine(o.row));e.replace(new r(t,0,t,s-1),u)},this.$getIndent=function(e){return e.match(/^\s*/)[0]}}).call(i.prototype),t.MatchingBraceOutdent=i}),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],function(e,t,n){"use strict";var r=e("../../lib/oop"),i=e("../behaviour").Behaviour,s=e("../../token_iterator").TokenIterator,o=e("../../lib/lang"),u=["text","paren.rparen","punctuation.operator"],a=["text","paren.rparen","punctuation.operator","comment"],f,l={},c=function(e){var t=-1;e.multiSelect&&(t=e.selection.index,l.rangeCount!=e.multiSelect.rangeCount&&(l={rangeCount:e.multiSelect.rangeCount}));if(l[t])return f=l[t];f=l[t]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},h=function(){this.add("braces","insertion",function(e,t,n,r,i){var s=n.getCursorPosition(),u=r.doc.getLine(s.row);if(i=="{"){c(n);var a=n.getSelectionRange(),l=r.doc.getTextRange(a);if(l!==""&&l!=="{"&&n.getWrapBehavioursEnabled())return{text:"{"+l+"}",selection:!1};if(h.isSaneInsertion(n,r))return/[\]\}\)]/.test(u[s.column])||n.inMultiSelectMode?(h.recordAutoInsert(n,r,"}"),{text:"{}",selection:[1,1]}):(h.recordMaybeInsert(n,r,"{"),{text:"{",selection:[1,1]})}else if(i=="}"){c(n);var p=u.substring(s.column,s.column+1);if(p=="}"){var d=r.$findOpeningBracket("}",{column:s.column+1,row:s.row});if(d!==null&&h.isAutoInsertedClosing(s,u,i))return h.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}else{if(i=="\n"||i=="\r\n"){c(n);var v="";h.isMaybeInsertedClosing(s,u)&&(v=o.stringRepeat("}",f.maybeInsertedBrackets),h.clearMaybeInsertedClosing());var p=u.substring(s.column,s.column+1);if(p==="}"){var m=r.findMatchingBracket({row:s.row,column:s.column+1},"}");if(!m)return null;var g=this.$getIndent(r.getLine(m.row))}else{if(!v){h.clearMaybeInsertedClosing();return}var g=this.$getIndent(u)}var y=g+r.getTabString();return{text:"\n"+y+"\n"+g+v,selection:[1,y.length,1,y.length]}}h.clearMaybeInsertedClosing()}}),this.add("braces","deletion",function(e,t,n,r,i){var s=r.doc.getTextRange(i);if(!i.isMultiLine()&&s=="{"){c(n);var o=r.doc.getLine(i.start.row),u=o.substring(i.end.column,i.end.column+1);if(u=="}")return i.end.column++,i;f.maybeInsertedBrackets--}}),this.add("parens","insertion",function(e,t,n,r,i){if(i=="("){c(n);var s=n.getSelectionRange(),o=r.doc.getTextRange(s);if(o!==""&&n.getWrapBehavioursEnabled())return{text:"("+o+")",selection:!1};if(h.isSaneInsertion(n,r))return h.recordAutoInsert(n,r,")"),{text:"()",selection:[1,1]}}else if(i==")"){c(n);var u=n.getCursorPosition(),a=r.doc.getLine(u.row),f=a.substring(u.column,u.column+1);if(f==")"){var l=r.$findOpeningBracket(")",{column:u.column+1,row:u.row});if(l!==null&&h.isAutoInsertedClosing(u,a,i))return h.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("parens","deletion",function(e,t,n,r,i){var s=r.doc.getTextRange(i);if(!i.isMultiLine()&&s=="("){c(n);var o=r.doc.getLine(i.start.row),u=o.substring(i.start.column+1,i.start.column+2);if(u==")")return i.end.column++,i}}),this.add("brackets","insertion",function(e,t,n,r,i){if(i=="["){c(n);var s=n.getSelectionRange(),o=r.doc.getTextRange(s);if(o!==""&&n.getWrapBehavioursEnabled())return{text:"["+o+"]",selection:!1};if(h.isSaneInsertion(n,r))return h.recordAutoInsert(n,r,"]"),{text:"[]",selection:[1,1]}}else if(i=="]"){c(n);var u=n.getCursorPosition(),a=r.doc.getLine(u.row),f=a.substring(u.column,u.column+1);if(f=="]"){var l=r.$findOpeningBracket("]",{column:u.column+1,row:u.row});if(l!==null&&h.isAutoInsertedClosing(u,a,i))return h.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("brackets","deletion",function(e,t,n,r,i){var s=r.doc.getTextRange(i);if(!i.isMultiLine()&&s=="["){c(n);var o=r.doc.getLine(i.start.row),u=o.substring(i.start.column+1,i.start.column+2);if(u=="]")return i.end.column++,i}}),this.add("string_dquotes","insertion",function(e,t,n,r,i){if(i=='"'||i=="'"){c(n);var s=i,o=n.getSelectionRange(),u=r.doc.getTextRange(o);if(u!==""&&u!=="'"&&u!='"'&&n.getWrapBehavioursEnabled())return{text:s+u+s,selection:!1};var a=n.getCursorPosition(),f=r.doc.getLine(a.row),l=f.substring(a.column-1,a.column),h=f.substring(a.column,a.column+1),p=r.getTokenAt(a.row,a.column),d=r.getTokenAt(a.row,a.column+1);if(l=="\\"&&p&&/escape/.test(p.type))return null;var v=p&&/string/.test(p.type),m=!d||/string/.test(d.type),g;if(h==s)g=v!==m;else{if(v&&!m)return null;if(v&&m)return null;var y=r.$mode.tokenRe;y.lastIndex=0;var b=y.test(l);y.lastIndex=0;var w=y.test(l);if(b||w)return null;if(h&&!/[\s;,.})\]\\]/.test(h))return null;g=!0}return{text:g?s+s:"",selection:[1,1]}}}),this.add("string_dquotes","deletion",function(e,t,n,r,i){var s=r.doc.getTextRange(i);if(!i.isMultiLine()&&(s=='"'||s=="'")){c(n);var o=r.doc.getLine(i.start.row),u=o.substring(i.start.column+1,i.start.column+2);if(u==s)return i.end.column++,i}})};h.isSaneInsertion=function(e,t){var n=e.getCursorPosition(),r=new s(t,n.row,n.column);if(!this.$matchTokenType(r.getCurrentToken()||"text",u)){var i=new s(t,n.row,n.column+1);if(!this.$matchTokenType(i.getCurrentToken()||"text",u))return!1}return r.stepForward(),r.getCurrentTokenRow()!==n.row||this.$matchTokenType(r.getCurrentToken()||"text",a)},h.$matchTokenType=function(e,t){return t.indexOf(e.type||e)>-1},h.recordAutoInsert=function(e,t,n){var r=e.getCursorPosition(),i=t.doc.getLine(r.row);this.isAutoInsertedClosing(r,i,f.autoInsertedLineEnd[0])||(f.autoInsertedBrackets=0),f.autoInsertedRow=r.row,f.autoInsertedLineEnd=n+i.substr(r.column),f.autoInsertedBrackets++},h.recordMaybeInsert=function(e,t,n){var r=e.getCursorPosition(),i=t.doc.getLine(r.row);this.isMaybeInsertedClosing(r,i)||(f.maybeInsertedBrackets=0),f.maybeInsertedRow=r.row,f.maybeInsertedLineStart=i.substr(0,r.column)+n,f.maybeInsertedLineEnd=i.substr(r.column),f.maybeInsertedBrackets++},h.isAutoInsertedClosing=function(e,t,n){return f.autoInsertedBrackets>0&&e.row===f.autoInsertedRow&&n===f.autoInsertedLineEnd[0]&&t.substr(e.column)===f.autoInsertedLineEnd},h.isMaybeInsertedClosing=function(e,t){return f.maybeInsertedBrackets>0&&e.row===f.maybeInsertedRow&&t.substr(e.column)===f.maybeInsertedLineEnd&&t.substr(0,e.column)==f.maybeInsertedLineStart},h.popAutoInsertedClosing=function(){f.autoInsertedLineEnd=f.autoInsertedLineEnd.substr(1),f.autoInsertedBrackets--},h.clearMaybeInsertedClosing=function(){f&&(f.maybeInsertedBrackets=0,f.maybeInsertedRow=-1)},r.inherits(h,i),t.CstyleBehaviour=h}),ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"],function(e,t,n){"use strict";var r=e("../../lib/oop"),i=e("../behaviour").Behaviour,s=e("./cstyle").CstyleBehaviour,o=e("../../token_iterator").TokenIterator,u=function(){this.inherit(s),this.add("colon","insertion",function(e,t,n,r,i){if(i===":"){var s=n.getCursorPosition(),u=new o(r,s.row,s.column),a=u.getCurrentToken();a&&a.value.match(/\s+/)&&(a=u.stepBackward());if(a&&a.type==="support.type"){var f=r.doc.getLine(s.row),l=f.substring(s.column,s.column+1);if(l===":")return{text:"",selection:[1,1]};if(!f.substring(s.column).match(/^\s*;/))return{text:":;",selection:[1,1]}}}}),this.add("colon","deletion",function(e,t,n,r,i){var s=r.doc.getTextRange(i);if(!i.isMultiLine()&&s===":"){var u=n.getCursorPosition(),a=new o(r,u.row,u.column),f=a.getCurrentToken();f&&f.value.match(/\s+/)&&(f=a.stepBackward());if(f&&f.type==="support.type"){var l=r.doc.getLine(i.start.row),c=l.substring(i.end.column,i.end.column+1);if(c===";")return i.end.column++,i}}}),this.add("semicolon","insertion",function(e,t,n,r,i){if(i===";"){var s=n.getCursorPosition(),o=r.doc.getLine(s.row),u=o.substring(s.column,s.column+1);if(u===";")return{text:"",selection:[1,1]}}})};r.inherits(u,s),t.CssBehaviour=u}),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(e,t,n){"use strict";var r=e("../../lib/oop"),i=e("../../range").Range,s=e("./fold_mode").FoldMode,o=t.FoldMode=function(e){e&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+e.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+e.end)))};r.inherits(o,s),function(){this.foldingStartMarker=/(\{|\[)[^\}\]]*$|^\s*(\/\*)/,this.foldingStopMarker=/^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/,this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/,this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/,this.startRegionRe=/^\s*(\/\*|\/\/)#region\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(e,t,n){var r=e.getLine(n);if(this.singleLineBlockCommentRe.test(r)&&!this.startRegionRe.test(r)&&!this.tripleStarBlockCommentRe.test(r))return"";var i=this._getFoldWidgetBase(e,t,n);return!i&&this.startRegionRe.test(r)?"start":i},this.getFoldWidgetRange=function(e,t,n,r){var i=e.getLine(n);if(this.startRegionRe.test(i))return this.getCommentRegionBlock(e,i,n);var s=i.match(this.foldingStartMarker);if(s){var o=s.index;if(s[1])return this.openingBracketBlock(e,s[1],n,o);var u=e.getCommentFoldRange(n,o+s[0].length,1);return u&&!u.isMultiLine()&&(r?u=this.getSectionRange(e,n):t!="all"&&(u=null)),u}if(t==="markbegin")return;var s=i.match(this.foldingStopMarker);if(s){var o=s.index+s[0].length;return s[1]?this.closingBracketBlock(e,s[1],n,o):e.getCommentFoldRange(n,o,-1)}},this.getSectionRange=function(e,t){var n=e.getLine(t),r=n.search(/\S/),s=t,o=n.length;t+=1;var u=t,a=e.getLength();while(++t<a){n=e.getLine(t);var f=n.search(/\S/);if(f===-1)continue;if(r>f)break;var l=this.getFoldWidgetRange(e,"all",t);if(l){if(l.start.row<=s)break;if(l.isMultiLine())t=l.end.row;else if(r==f)break}u=t}return new i(s,o,u,e.getLine(u).length)},this.getCommentRegionBlock=function(e,t,n){var r=t.search(/\s*$/),s=e.getLength(),o=n,u=/^\s*(?:\/\*|\/\/)#(end)?region\b/,a=1;while(++n<s){t=e.getLine(n);var f=u.exec(t);if(!f)continue;f[1]?a--:a++;if(!a)break}var l=n;if(l>o)return new i(o,r,l,t.length)}}.call(o.prototype)}),ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/css","ace/mode/folding/cstyle"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("./text").Mode,s=e("./css_highlight_rules").CssHighlightRules,o=e("./matching_brace_outdent").MatchingBraceOutdent,u=e("../worker/worker_client").WorkerClient,a=e("./behaviour/css").CssBehaviour,f=e("./folding/cstyle").FoldM