From cafc75b2382241f7a1f8e52f66650c5c8a84c480 Mon Sep 17 00:00:00 2001 From: Gosha Arinich Date: Mon, 25 Feb 2013 19:42:20 +0300 Subject: [PATCH] remove trailing whitespaces :heart: --- README.md | 4 +- .../javascripts/admin/models/email_log.js | 1 - .../admin/routes/admin_customize_route.js | 2 - .../admin/routes/admin_email_logs_route.js | 2 - .../admin/routes/admin_flags_route.js | 2 - .../javascripts/admin/routes/admin_route.js | 2 - .../javascripts/admin/routes/admin_routes.js | 1 - .../admin/routes/admin_site_settings_route.js | 2 - .../admin/routes/admin_user_route.js | 3 - .../routes/admin_users_list_active_route.js | 2 - .../routes/admin_users_list_new_route.js | 2 - .../routes/admin_users_list_pending_route.js | 2 - .../admin/routes/admin_users_list_route.js | 2 - .../javascripts/admin/translations.js.erb | 2 +- .../admin/views/admin_customize_view.js | 2 - app/assets/javascripts/application.js.erb | 2 +- .../defer/html-sanitizer-bundle.js | 2 +- .../discourse/components/bbcode.js | 2 +- .../discourse/components/debounce.js | 2 +- .../discourse/components/probes.js | 22 +- .../discourse/components/screen_track.js | 2 - .../discourse/routes/user_route.js | 2 - .../javascripts/discourse/translations.js.erb | 2 +- .../views/modal/archetype_options_view.js | 2 - .../discourse/views/post_menu_view.js | 2 - .../javascripts/discourse/views/view.js | 2 - .../external/Markdown.Converter.js | 82 +- .../javascripts/external/Markdown.Editor.js | 44 +- .../external/Markdown.Sanitizer.js | 6 +- .../javascripts/external/bootstrap-button.js | 4 +- .../javascripts/external/chosen.jquery.js | 2 +- app/assets/javascripts/external/ember.js | 72 +- .../external/handlebars-1.0.rc.3.js | 160 +- .../external/jquery.ba-replacetext.js | 74 +- .../javascripts/external/jquery.tagsinput.js | 42 +- app/assets/javascripts/external/mousetrap.js | 12 +- app/assets/javascripts/external/show-html.js | 14 +- .../javascripts/external_production/ember.js | 72 +- app/assets/stylesheets/admin/admin_base.scss | 2 +- .../application/discourse.css.scss | 4 +- .../stylesheets/application/header.css.scss | 2 +- .../stylesheets/application/lightbox.scss | 4 +- .../stylesheets/application/mobile.scss | 6 +- .../stylesheets/application/modal.css.scss | 10 +- .../application/topic-post.css.scss | 8 +- .../stylesheets/application/user.css.scss | 4 +- .../application/username_tagsinput.css | 46 +- .../stylesheets/vendor/bootstrap.css.scss | 4 +- app/assets/stylesheets/vendor/chosen.css.erb | 14 +- app/controllers/application_controller.rb | 6 +- app/controllers/education_controller.rb | 6 +- app/controllers/post_actions_controller.rb | 2 +- app/controllers/posts_controller.rb | 8 +- app/controllers/robots_txt_controller.rb | 2 +- app/models/category.rb | 8 +- app/models/category_list.rb | 2 +- app/models/post.rb | 2 +- app/models/post_action.rb | 14 +- app/models/post_timing.rb | 4 +- app/models/topic.rb | 10 +- app/models/topic_user.rb | 2 +- app/models/user.rb | 12 +- app/models/user_action.rb | 18 +- app/models/user_search.rb | 10 +- app/serializers/basic_topic_serializer.rb | 22 +- app/serializers/category_serializer.rb | 8 +- app/serializers/category_topic_serializer.rb | 6 +- app/serializers/current_user_serializer.rb | 10 +- app/serializers/site_serializer.rb | 4 +- app/serializers/topic_link_serializer.rb | 10 +- app/serializers/topic_list_item_serializer.rb | 20 +- app/serializers/user_serializer.rb | 2 +- .../common/_discourse_javascript.html.erb | 4 +- .../common/_discourse_stylesheet.html.erb | 6 +- app/views/common/_special_font_face.html.erb | 8 +- app/views/email/unsubscribe.html.erb | 2 +- app/views/layouts/application.html.erb | 6 +- app/views/layouts/no_js.html.erb | 8 +- app/views/user_notifications/digest.text.erb | 2 +- app/views/users/activate_account.html.erb | 6 +- app/views/users/authorize_email.html.erb | 4 +- app/views/users/password_reset.html.erb | 8 +- .../apt/templates/default/acng.conf.erb | 12 +- .../discourse/files/default/redis.yml | 2 +- .../recipes/set_remote_path.rb | 4 +- config/application.rb | 12 +- config/clock.rb | 2 +- config/environments/development.rb | 6 +- config/environments/production.rb | 2 +- config/environments/test.rb | 2 +- config/initializers/message_bus.rb | 4 +- config/initializers/mini_profiler.rb | 8 +- config/initializers/quiet_logger.rb | 4 +- config/initializers/secret_token.rb | 12 +- config/initializers/silence_logger.rb | 4 +- config/initializers/site_settings.rb | 4 +- config/initializers/watch_for_restart.rb | 10 +- config/locales/client.nl.yml | 6 +- config/locales/server.en.yml | 2 +- config/locales/server.nl.yml | 50 +- .../20120311163914_create_forum_threads.rb | 2 +- db/migrate/20120311164326_create_posts.rb | 2 +- db/migrate/20120311201341_create_forums.rb | 4 +- ...2183240_add_created_by_to_forum_threads.rb | 8 +- ..._add_last_post_user_id_to_forum_threads.rb | 6 +- .../20120503205521_add_site_id_to_users.rb | 2 +- db/migrate/20120523180723_create_views.rb | 2 +- db/migrate/20120529202707_create_stars.rb | 2 +- ...20120530150726_create_forum_thread_user.rb | 12 +- ...0120530212912_create_forum_thread_links.rb | 2 +- ...20120614202024_add_quote_count_to_posts.rb | 2 +- db/migrate/20120619150807_fix_post_timings.rb | 4 +- db/migrate/20120619153349_drop_read_posts.rb | 2 +- ...45714_add_seen_notification_id_to_users.rb | 4 +- ...0120629143908_rename_expression_type_id.rb | 4 +- .../20120629182637_create_incoming_links.rb | 2 +- ...20703210004_add_bookmark_count_to_posts.rb | 12 +- .../20120704201743_add_view_count_to_posts.rb | 2 +- ...20708210305_add_last_posted_at_to_users.rb | 4 +- .../20120712150500_create_categories.rb | 4 +- ...151934_add_category_id_to_forum_threads.rb | 4 +- ...mail_hashed_password_name_salt_to_users.rb | 8 +- ...27005556_remove_excerpt_from_categories.rb | 2 +- ..._password_new_salt_email_token_to_users.rb | 2 +- db/migrate/20120807223020_create_actions.rb | 8 +- db/migrate/20120809020415_remove_site_id.rb | 6 +- ...0120809053414_correct_indexing_on_posts.rb | 8 +- .../20120809174649_create_post_actions.rb | 6 +- .../20120812235417_retire_expressions.rb | 4 +- ...3201426_create_forum_thread_link_clicks.rb | 2 +- ..._add_unique_index_to_forum_thread_links.rb | 2 +- ..._moderator_posts_count_to_forum_threads.rb | 2 +- ...538_add_starred_at_to_forum_thread_user.rb | 6 +- ...152846_add_has_best_of_to_forum_threads.rb | 2 +- .../20120921055428_add_twitter_user_info.rb | 6 +- ...21162512_add_meta_data_to_forum_threads.rb | 2 +- ...20120921163606_create_archetype_options.rb | 4 +- .../20120928170023_add_sort_order_to_posts.rb | 6 +- ...121018103721_rename_forum_thread_tables.rb | 14 +- ...121106015500_drop_avatar_url_from_users.rb | 6 +- ...0121123054127_make_post_number_distinct.rb | 16 +- .../20121129160035_create_email_tokens.rb | 2 +- ...129184948_remove_email_token_from_users.rb | 2 +- db/migrate/20121204183855_fix_link_post_id.rb | 2 +- ...000741_add_notifications_to_topic_users.rb | 2 +- ...12140_merge_mute_options_on_topic_users.rb | 2 +- ...ter_seconds_and_banning_and_dob_to_user.rb | 6 +- ...070909_auto_track_all_topics_replied_to.rb | 4 +- .../20130127213646_remove_trust_levels.rb | 2 +- ...20130128182013_trust_level_default_null.rb | 2 +- ...213021450_remove_topic_response_actions.rb | 4 +- ...add_new_topic_duration_minutes_to_users.rb | 6 +- ...221215017_add_description_to_categories.rb | 2 +- db/structure.sql | 2068 ++++++++++++++++- lib/archetype.rb | 6 +- lib/canonical_url.rb | 8 +- lib/content_buffer.rb | 22 +- lib/cooked_post_processor.rb | 28 +- lib/current_user.rb | 10 +- lib/diff_engine.rb | 6 +- lib/discourse.rb | 10 +- lib/discourse_observer.rb | 8 +- lib/discourse_plugin_registry.rb | 6 +- lib/discourse_redis.rb | 6 +- lib/distributed_hash.rb | 6 +- lib/email.rb | 6 +- lib/email_builder.rb | 4 +- lib/email_sender.rb | 2 +- lib/freedom_patches/active_record_base.rb | 6 +- lib/guardian.rb | 48 +- lib/headless-ember.js | 4 +- lib/image_optimizer.rb | 40 +- lib/image_sizer.rb | 4 +- lib/imgur.rb | 2 +- .../merge_mute_options_on_topic_users.rb | 4 +- lib/jobs.rb | 6 +- lib/jobs/calculate_avg_time.rb | 4 +- lib/jobs/enqueue_digest_emails.rb | 6 +- lib/jobs/process_post.rb | 2 +- lib/jobs/send_system_message.rb | 4 +- lib/jobs/user_email.rb | 8 +- lib/markdown_linker.rb | 6 +- lib/message_bus_diags.rb | 2 +- lib/multisite_i18n.rb | 6 +- lib/oneboxer.rb | 18 +- lib/oneboxer/amazon_onebox.rb | 6 +- lib/oneboxer/android_app_store_onebox.rb | 2 +- lib/oneboxer/apple_app_onebox.rb | 4 +- lib/oneboxer/base.rb | 6 +- lib/oneboxer/base_onebox.rb | 2 +- lib/oneboxer/gist_onebox.rb | 4 +- lib/oneboxer/github_blob_onebox.rb | 6 +- lib/oneboxer/handlebars_onebox.rb | 6 +- lib/oneboxer/oembed_onebox.rb | 2 +- lib/oneboxer/twitter_onebox.rb | 4 +- lib/oneboxer/whitelist.rb | 2 +- lib/oneboxer/wikipedia_onebox.rb | 2 +- lib/post_creator.rb | 16 +- lib/post_revisor.rb | 2 +- lib/pretty_text.rb | 70 +- lib/promotion.rb | 6 +- lib/rate_limiter.rb | 4 +- lib/rate_limiter/limit_exceeded.rb | 4 +- lib/rate_limiter/on_create_record.rb | 14 +- lib/score_calculator.rb | 12 +- lib/search.rb | 36 +- lib/site_setting_extension.rb | 60 +- lib/slug.rb | 2 +- lib/sql_builder.rb | 6 +- lib/system_message.rb | 6 +- lib/tasks/add_topic_to_quotes.rake | 2 +- lib/tasks/build.rake | 2 +- lib/tasks/build_test_topic.rake | 8 +- lib/tasks/cdn.rake | 8 +- lib/tasks/images.rake | 2 +- lib/tasks/posts.rake | 2 +- lib/tasks/search.rake | 18 +- lib/tasks/smoke_test.rake | 4 +- lib/tasks/user_actions.rake | 6 +- lib/text_sentinel.rb | 6 +- lib/topic_query.rb | 22 +- lib/topic_view.rb | 14 +- lib/trust_level.rb | 2 +- lib/unread.rb | 4 +- spec/components/category_list_spec.rb | 6 +- spec/components/content_buffer_spec.rb | 10 +- spec/components/cooked_post_processor_spec.rb | 24 +- spec/components/current_user_spec.rb | 4 +- .../discourse_plugin_registry_spec.rb | 6 +- spec/components/discourse_spec.rb | 2 +- spec/components/distributed_hash_spec.rb | 4 +- spec/components/email_sender_spec.rb | 12 +- spec/components/email_spec.rb | 4 +- spec/components/guardian_spec.rb | 42 +- spec/components/image_sizer_spec.rb | 2 +- .../jobs/enqueue_digest_emails_spec.rb | 6 +- .../jobs/feature_topic_users_spec.rb | 2 +- spec/components/jobs/jobs_base_spec.rb | 2 +- spec/components/jobs/process_post_spec.rb | 4 +- .../jobs/send_system_message_spec.rb | 4 +- spec/components/jobs/user_email_spec.rb | 10 +- spec/components/multisite_i18n_spec.rb | 4 +- .../components/oneboxer/amazon_onebox_spec.rb | 8 +- .../oneboxer/android_app_store_onebox_spec.rb | 8 +- .../oneboxer/apple_app_onebox_spec.rb | 6 +- .../components/oneboxer/flickr_onebox_spec.rb | 8 +- spec/components/oneboxer/gist_onebox_spec.rb | 4 +- .../oneboxer/wikipedia_onebox_spec.rb | 6 +- spec/components/oneboxer_spec.rb | 16 +- spec/components/post_creator_spec.rb | 10 +- spec/components/post_revisor_spec.rb | 4 +- spec/components/pretty_text_spec.rb | 90 +- spec/components/rate_limiter_spec.rb | 6 +- spec/components/score_calculator_spec.rb | 8 +- spec/components/search_spec.rb | 36 +- spec/components/slug_spec.rb | 4 +- spec/components/sql_builder_spec.rb | 18 +- spec/components/system_message_spec.rb | 2 +- spec/components/text_sentinel_spec.rb | 4 +- spec/components/topic_query_spec.rb | 36 +- spec/components/topic_view_spec.rb | 18 +- spec/components/unread_spec.rb | 12 +- .../admin/email_logs_controller_spec.rb | 6 +- .../admin/export_controller_spec.rb | 4 +- .../admin/flags_controller_spec.rb | 6 +- .../admin/impersonate_controller_spec.rb | 4 +- .../site_customizations_controller_spec.rb | 8 +- .../admin/site_settings_controller_spec.rb | 4 +- .../admin/users_controller_spec.rb | 14 +- .../controllers/categories_controller_spec.rb | 12 +- spec/controllers/clicks_controller_spec.rb | 12 +- spec/controllers/draft_controller_spec.rb | 4 +- spec/controllers/education_controller_spec.rb | 2 +- spec/controllers/email_controller_spec.rb | 4 +- spec/controllers/excerpt_controller_spec.rb | 6 +- spec/controllers/invites_controller_spec.rb | 38 +- spec/controllers/list_controller_spec.rb | 4 +- .../notifications_controller_spec.rb | 4 +- .../post_actions_controller_spec.rb | 14 +- spec/controllers/posts_controller_spec.rb | 24 +- .../request_access_controller_spec.rb | 4 +- .../controllers/robots_txt_controller_spec.rb | 6 +- spec/controllers/session_controller_spec.rb | 16 +- spec/controllers/static_controller_spec.rb | 2 +- spec/controllers/topics_controller_spec.rb | 42 +- spec/fabricators/post_fabricator.rb | 4 +- spec/fabricators/topic_fabricator.rb | 10 +- spec/fabricators/user_fabricator.rb | 6 +- spec/integrity/i18n_spec.rb | 2 +- spec/javascripts/sanitize_spec.js | 2 +- spec/javascripts/utilities_spec.js | 2 +- spec/mailers/invite_mailer_spec.rb | 2 +- spec/mailers/test_mailer_spec.rb | 2 +- spec/mailers/user_notifications_spec.rb | 8 +- spec/models/category_featured_topic_spec.rb | 2 +- spec/models/category_featured_user_spec.rb | 2 +- spec/models/category_spec.rb | 18 +- spec/models/draft_sequence_spec.rb | 2 +- spec/models/draft_spec.rb | 24 +- spec/models/email_log_spec.rb | 2 +- spec/models/email_token_spec.rb | 6 +- spec/models/error_log_spec.rb | 16 +- spec/models/incoming_link_spec.rb | 2 +- spec/models/invite_spec.rb | 16 +- spec/models/notification_spec.rb | 30 +- spec/models/onebox_render_spec.rb | 4 +- spec/models/post_action_spec.rb | 48 +- spec/models/post_alert_observer_spec.rb | 24 +- spec/models/post_spec.rb | 50 +- spec/models/post_timing_spec.rb | 18 +- spec/models/site_customization_spec.rb | 42 +- spec/models/site_setting_spec.rb | 42 +- spec/models/topic_invite_spec.rb | 4 +- spec/models/topic_link_click_spec.rb | 10 +- spec/models/topic_link_spec.rb | 32 +- spec/models/topic_spec.rb | 136 +- spec/models/topic_user_spec.rb | 64 +- spec/models/user_action_spec.rb | 90 +- spec/models/user_spec.rb | 14 +- spec/requests/store_incoming_spec.rb | 4 +- spec/spec_helper.rb | 8 +- .../complete.html.erb_spec.rb | 2 +- vendor/gems/discourse_emoji/Rakefile | 2 +- .../lib/discourse_emoji/engine.rb | 2 +- .../lib/discourse_emoji/plugin.rb | 4 +- .../gems/discourse_emoji/spec/plugin_spec.rb | 8 +- .../gems/discourse_emoji/spec/spec_helper.rb | 2 +- .../assets/javascripts/discourse_emoji.js | 14 +- vendor/gems/discourse_plugin/Rakefile | 2 +- .../gems/discourse_plugin/spec/spec_helper.rb | 2 +- vendor/gems/discourse_poll/Rakefile | 2 +- .../lib/discourse_poll/engine.rb | 4 +- .../lib/discourse_poll/locale/en.yml | 8 +- .../lib/discourse_poll/plugin.rb | 10 +- .../gems/discourse_poll/spec/plugin_spec.rb | 16 +- .../gems/discourse_poll/spec/spec_helper.rb | 2 +- .../javascripts/discourse_poll/models/post.js | 8 +- .../discourse_poll/models/post_action_type.js | 4 +- .../discourse_poll/views/post_view.js | 6 +- .../discourse_poll/views/prepend_post_view.js | 6 +- .../views/topic_footer_buttons_view.js | 2 +- .../views/topic_information_view.js | 2 +- .../discourse_poll/views/topic_status_view.js | 4 +- .../views/vote_controls_view.js | 2 +- vendor/gems/discourse_task/Rakefile | 2 +- vendor/gems/discourse_task/config/routes.rb | 6 +- .../lib/discourse_task/engine.rb | 4 +- .../lib/discourse_task/plugin.rb | 4 +- .../gems/discourse_task/spec/plugin_spec.rb | 12 +- .../gems/discourse_task/spec/spec_helper.rb | 2 +- .../controllers/topic_controller.js | 4 +- .../discourse_task/models/topic.js | 8 +- .../views/topic_footer_buttons_view.js | 14 +- .../discourse_task/views/topic_status_view.js | 4 +- .../views/topic_summary_view.js | 2 +- vendor/gems/message_bus/assets/application.js | 4 +- vendor/gems/message_bus/assets/ember.js | 86 +- vendor/gems/message_bus/assets/handlebars.js | 160 +- vendor/gems/message_bus/assets/message-bus.js | 2 +- vendor/gems/message_bus/lib/message_bus.rb | 54 +- .../message_bus/lib/message_bus/client.rb | 10 +- .../lib/message_bus/connection_manager.rb | 20 +- .../lib/message_bus/diagnostics.rb | 14 +- .../message_bus/lib/message_bus/message.rb | 4 +- .../lib/message_bus/message_handler.rb | 4 +- .../lib/message_bus/rack/diagnostics.rb | 8 +- .../lib/message_bus/rack/middleware.rb | 44 +- .../lib/message_bus/reliable_pub_sub.rb | 48 +- .../gems/message_bus/spec/lib/client_spec.rb | 14 +- .../spec/lib/connection_manager_spec.rb | 24 +- .../message_bus/spec/lib/message_bus_spec.rb | 26 +- .../spec/lib/message_handler_spec.rb | 10 +- .../message_bus/spec/lib/middleware_spec.rb | 30 +- .../spec/lib/multi_process_spec.rb | 10 +- .../spec/lib/reliable_pub_sub_spec.rb | 66 +- vendor/gems/rails_multisite/Rakefile | 2 +- .../rails_multisite/connection_management.rb | 24 +- .../lib/rails_multisite/railtie.rb | 2 +- .../rails_multisite/lib/tasks/generators.rake | 8 +- .../spec/connection_management_rack_spec.rb | 8 +- .../spec/connection_management_spec.rb | 2 +- .../rails_multisite/spec/fixtures/two_dbs.yml | 6 +- .../gems/rails_multisite/spec/spec_helper.rb | 2 +- 383 files changed, 4220 insertions(+), 2221 deletions(-) diff --git a/README.md b/README.md index 92bb8f3e3..f5e36046b 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ If you're familiar with how Rails works and are comfortable setting up your own ## Vision -Discourse is a **Civilized Discourse Construction Kit**, an 100% open-source discussion platform that is free for everyone to use and contribute to -- forever. +Discourse is a **Civilized Discourse Construction Kit**, an 100% open-source discussion platform that is free for everyone to use and contribute to -- forever. Key Discourse mission goals: @@ -44,7 +44,7 @@ This vision translates to the following functional commitments: - Internet Explorer 9.0, 10.0+ - Firefox 16+ - Google Chrome 23+ - - Safari 5+ + - Safari 5+ 2. Support the latest generation of tablets, 7" or larger - iPad 2+ - Android 4.1+ diff --git a/app/assets/javascripts/admin/models/email_log.js b/app/assets/javascripts/admin/models/email_log.js index 1fd292567..f7852501e 100644 --- a/app/assets/javascripts/admin/models/email_log.js +++ b/app/assets/javascripts/admin/models/email_log.js @@ -9,7 +9,6 @@ Discourse.EmailLog = Discourse.Model.extend({}); Discourse.EmailLog.reopenClass({ - create: function(attrs) { if (attrs.user) { attrs.user = Discourse.AdminUser.create(attrs.user); diff --git a/app/assets/javascripts/admin/routes/admin_customize_route.js b/app/assets/javascripts/admin/routes/admin_customize_route.js index e08579156..76f5b0874 100644 --- a/app/assets/javascripts/admin/routes/admin_customize_route.js +++ b/app/assets/javascripts/admin/routes/admin_customize_route.js @@ -15,5 +15,3 @@ Discourse.AdminCustomizeRoute = Discourse.Route.extend({ this.render({into: 'admin/templates/admin'}); } }); - - diff --git a/app/assets/javascripts/admin/routes/admin_email_logs_route.js b/app/assets/javascripts/admin/routes/admin_email_logs_route.js index f1fa42513..67a2a5587 100644 --- a/app/assets/javascripts/admin/routes/admin_email_logs_route.js +++ b/app/assets/javascripts/admin/routes/admin_email_logs_route.js @@ -15,5 +15,3 @@ Discourse.AdminEmailLogsRoute = Discourse.Route.extend({ this.render('admin/templates/email_logs'); } }); - - diff --git a/app/assets/javascripts/admin/routes/admin_flags_route.js b/app/assets/javascripts/admin/routes/admin_flags_route.js index 7def67540..19c7b1889 100644 --- a/app/assets/javascripts/admin/routes/admin_flags_route.js +++ b/app/assets/javascripts/admin/routes/admin_flags_route.js @@ -11,5 +11,3 @@ Discourse.AdminFlagsRoute = Discourse.Route.extend({ this.render('admin/templates/flags'); } }); - - diff --git a/app/assets/javascripts/admin/routes/admin_route.js b/app/assets/javascripts/admin/routes/admin_route.js index a28ffff2e..7bee2b183 100644 --- a/app/assets/javascripts/admin/routes/admin_route.js +++ b/app/assets/javascripts/admin/routes/admin_route.js @@ -11,5 +11,3 @@ Discourse.AdminRoute = Discourse.Route.extend({ this.render('admin/templates/admin'); } }); - - diff --git a/app/assets/javascripts/admin/routes/admin_routes.js b/app/assets/javascripts/admin/routes/admin_routes.js index 215a7ba14..bb583fdc9 100644 --- a/app/assets/javascripts/admin/routes/admin_routes.js +++ b/app/assets/javascripts/admin/routes/admin_routes.js @@ -6,7 +6,6 @@ **/ Discourse.buildRoutes(function() { this.resource('admin', { path: '/admin' }, function() { - this.route('dashboard', { path: '/' }); this.route('site_settings', { path: '/site_settings' }); this.route('email_logs', { path: '/email_logs' }); diff --git a/app/assets/javascripts/admin/routes/admin_site_settings_route.js b/app/assets/javascripts/admin/routes/admin_site_settings_route.js index 5043b40a0..f572d53b3 100644 --- a/app/assets/javascripts/admin/routes/admin_site_settings_route.js +++ b/app/assets/javascripts/admin/routes/admin_site_settings_route.js @@ -15,5 +15,3 @@ Discourse.AdminSiteSettingsRoute = Discourse.Route.extend({ this.render('admin/templates/site_settings', {into: 'admin/templates/admin'}); } }); - - diff --git a/app/assets/javascripts/admin/routes/admin_user_route.js b/app/assets/javascripts/admin/routes/admin_user_route.js index 343dce695..24598f09c 100644 --- a/app/assets/javascripts/admin/routes/admin_user_route.js +++ b/app/assets/javascripts/admin/routes/admin_user_route.js @@ -14,7 +14,4 @@ Discourse.AdminUserRoute = Discourse.Route.extend({ renderTemplate: function() { this.render('admin/templates/user', {into: 'admin/templates/admin'}); } - }); - - diff --git a/app/assets/javascripts/admin/routes/admin_users_list_active_route.js b/app/assets/javascripts/admin/routes/admin_users_list_active_route.js index 46b23537b..071a9cf7a 100644 --- a/app/assets/javascripts/admin/routes/admin_users_list_active_route.js +++ b/app/assets/javascripts/admin/routes/admin_users_list_active_route.js @@ -11,5 +11,3 @@ Discourse.AdminUsersListActiveRoute = Discourse.Route.extend({ return this.controllerFor('adminUsersList').show('active'); } }); - - diff --git a/app/assets/javascripts/admin/routes/admin_users_list_new_route.js b/app/assets/javascripts/admin/routes/admin_users_list_new_route.js index 48f22a38e..365c0e71a 100644 --- a/app/assets/javascripts/admin/routes/admin_users_list_new_route.js +++ b/app/assets/javascripts/admin/routes/admin_users_list_new_route.js @@ -11,5 +11,3 @@ Discourse.AdminUsersListNewRoute = Discourse.Route.extend({ return this.controllerFor('adminUsersList').show('new'); } }); - - diff --git a/app/assets/javascripts/admin/routes/admin_users_list_pending_route.js b/app/assets/javascripts/admin/routes/admin_users_list_pending_route.js index bd2efaf6a..8fb862f4a 100644 --- a/app/assets/javascripts/admin/routes/admin_users_list_pending_route.js +++ b/app/assets/javascripts/admin/routes/admin_users_list_pending_route.js @@ -11,5 +11,3 @@ Discourse.AdminUsersListPendingRoute = Discourse.Route.extend({ return this.controllerFor('adminUsersList').show('pending'); } }); - - diff --git a/app/assets/javascripts/admin/routes/admin_users_list_route.js b/app/assets/javascripts/admin/routes/admin_users_list_route.js index 757c7efa2..e08ee02f8 100644 --- a/app/assets/javascripts/admin/routes/admin_users_list_route.js +++ b/app/assets/javascripts/admin/routes/admin_users_list_route.js @@ -11,5 +11,3 @@ Discourse.AdminUsersListRoute = Discourse.Route.extend({ this.render('admin/templates/users_list', {into: 'admin/templates/admin'}); } }); - - diff --git a/app/assets/javascripts/admin/translations.js.erb b/app/assets/javascripts/admin/translations.js.erb index 275b322bf..1f70ef3fe 100644 --- a/app/assets/javascripts/admin/translations.js.erb +++ b/app/assets/javascripts/admin/translations.js.erb @@ -1,7 +1,7 @@ //= depend_on 'client.en.yml' <% SimplesIdeias::I18n.assert_usable_configuration! %> -<% admin = SimplesIdeias::I18n.translation_segments['app/assets/javascripts/i18n/admin.en.js'] +<% admin = SimplesIdeias::I18n.translation_segments['app/assets/javascripts/i18n/admin.en.js'] admin[:en][:js] = admin[:en].delete(:admin_js) %> jQuery.extend(true, I18n.translations, <%= admin.to_json %>); diff --git a/app/assets/javascripts/admin/views/admin_customize_view.js b/app/assets/javascripts/admin/views/admin_customize_view.js index 90bb032c2..213c385eb 100644 --- a/app/assets/javascripts/admin/views/admin_customize_view.js +++ b/app/assets/javascripts/admin/views/admin_customize_view.js @@ -46,5 +46,3 @@ Discourse.AdminCustomizeView = Discourse.View.extend({ } }); - - diff --git a/app/assets/javascripts/application.js.erb b/app/assets/javascripts/application.js.erb index 50d65abb6..b5da1a238 100644 --- a/app/assets/javascripts/application.js.erb +++ b/app/assets/javascripts/application.js.erb @@ -49,5 +49,5 @@ # Include javascripts DiscoursePluginRegistry.javascripts.each do |js| require_asset(js) - end + end %> diff --git a/app/assets/javascripts/defer/html-sanitizer-bundle.js b/app/assets/javascripts/defer/html-sanitizer-bundle.js index 16c375f4a..363a5ce40 100644 --- a/app/assets/javascripts/defer/html-sanitizer-bundle.js +++ b/app/assets/javascripts/defer/html-sanitizer-bundle.js @@ -414,7 +414,7 @@ URI.prototype.setPath = function (newPath) { URI.prototype.setRawPath = function (newPath) { if (newPath) { newPath = String(newPath); - this.path_ = + this.path_ = // Paths must start with '/' unless this is a path-relative URL. (!this.domain_ || /^\//.test(newPath)) ? newPath : '/' + newPath; } else { diff --git a/app/assets/javascripts/discourse/components/bbcode.js b/app/assets/javascripts/discourse/components/bbcode.js index dd474985d..dc4758157 100644 --- a/app/assets/javascripts/discourse/components/bbcode.js +++ b/app/assets/javascripts/discourse/components/bbcode.js @@ -190,4 +190,4 @@ Discourse.BBCode = { text = Discourse.BBCode.formatQuote(text, opts); return text; } -}; \ No newline at end of file +}; diff --git a/app/assets/javascripts/discourse/components/debounce.js b/app/assets/javascripts/discourse/components/debounce.js index 2c081cf48..9141e2fc3 100644 --- a/app/assets/javascripts/discourse/components/debounce.js +++ b/app/assets/javascripts/discourse/components/debounce.js @@ -31,7 +31,7 @@ Discourse.debounce = function(func, wait, trickle) { } else { currentWait = wait; } - + if (timeout) { clearTimeout(timeout); } diff --git a/app/assets/javascripts/discourse/components/probes.js b/app/assets/javascripts/discourse/components/probes.js index e2a497904..f341f944c 100644 --- a/app/assets/javascripts/discourse/components/probes.js +++ b/app/assets/javascripts/discourse/components/probes.js @@ -1,10 +1,9 @@ -/* +/* * JavaScript probing framework by Sam Saffron * MIT license * * - * Examples: - * + * Examples: * * someFunction = window.probes.measure(someFunction, { * name: "somename" // or function(args) { return "name"; }, @@ -26,10 +25,9 @@ * // minimal * someFunction = window.probes.measure(someFunction, "someFunction"); * - * * */ (function(){ - var measure, clear; + var measure, clear; clear = function() { window.probes = { @@ -48,14 +46,14 @@ if (typeof options === "string") { nameParam = options; } - else + else { nameParam = options.name; if (nameParam === "measure" || nameParam === "clear") { - throw new Error("can not be called measure or clear"); + throw new Error("can not be called measure or clear"); } - + if (!nameParam) { throw new Error("you must specify the name option measure(fn, {name: 'some name'})"); @@ -78,7 +76,7 @@ } var p = window.probes[name]; var owner = (!start); - + if (before) { // would like to avoid try catch so its optimised properly by chrome before(p, owner, arguments); @@ -94,14 +92,14 @@ start = now(); callStart = start; } - else if(after) + else if(after) { callStart = now(); } - var r = fn.apply(this, arguments); + var r = fn.apply(this, arguments); if (owner && start) { - p.time += now() - start; + p.time += now() - start; start = null; } p.count += 1; diff --git a/app/assets/javascripts/discourse/components/screen_track.js b/app/assets/javascripts/discourse/components/screen_track.js index 3d50638bf..45dbfde3d 100644 --- a/app/assets/javascripts/discourse/components/screen_track.js +++ b/app/assets/javascripts/discourse/components/screen_track.js @@ -155,5 +155,3 @@ Discourse.ScreenTrack = Ember.Object.extend({ } }); - - diff --git a/app/assets/javascripts/discourse/routes/user_route.js b/app/assets/javascripts/discourse/routes/user_route.js index 8ab984e8f..3e2e079f8 100644 --- a/app/assets/javascripts/discourse/routes/user_route.js +++ b/app/assets/javascripts/discourse/routes/user_route.js @@ -15,5 +15,3 @@ Discourse.UserRoute = Discourse.Route.extend({ return { username: Em.get(params, 'username').toLowerCase() }; } }); - - diff --git a/app/assets/javascripts/discourse/translations.js.erb b/app/assets/javascripts/discourse/translations.js.erb index 4058b0eb8..4f30f5b5a 100644 --- a/app/assets/javascripts/discourse/translations.js.erb +++ b/app/assets/javascripts/discourse/translations.js.erb @@ -1,5 +1,5 @@ //= depend_on 'client.en.yml' <% SimplesIdeias::I18n.assert_usable_configuration! %> -var I18n = I18n || {}; +var I18n = I18n || {}; I18n.translations = <%= SimplesIdeias::I18n.translation_segments['app/assets/javascripts/i18n/en.js'].to_json %>; diff --git a/app/assets/javascripts/discourse/views/modal/archetype_options_view.js b/app/assets/javascripts/discourse/views/modal/archetype_options_view.js index b403b37d9..fe853c519 100644 --- a/app/assets/javascripts/discourse/views/modal/archetype_options_view.js +++ b/app/assets/javascripts/discourse/views/modal/archetype_options_view.js @@ -28,5 +28,3 @@ Discourse.ArchetypeOptionsView = Em.ContainerView.extend({ } }); - - diff --git a/app/assets/javascripts/discourse/views/post_menu_view.js b/app/assets/javascripts/discourse/views/post_menu_view.js index 8bbc68964..36ccf9aa4 100644 --- a/app/assets/javascripts/discourse/views/post_menu_view.js +++ b/app/assets/javascripts/discourse/views/post_menu_view.js @@ -162,5 +162,3 @@ Discourse.PostMenuView = Discourse.View.extend({ } }); - - diff --git a/app/assets/javascripts/discourse/views/view.js b/app/assets/javascripts/discourse/views/view.js index aa796336b..69bf24b1e 100644 --- a/app/assets/javascripts/discourse/views/view.js +++ b/app/assets/javascripts/discourse/views/view.js @@ -8,5 +8,3 @@ @module Discourse **/ window.Discourse.View = Ember.View.extend(Discourse.Presence, {}); - - diff --git a/app/assets/javascripts/external/Markdown.Converter.js b/app/assets/javascripts/external/Markdown.Converter.js index 22808c5b3..39fbc5d83 100644 --- a/app/assets/javascripts/external/Markdown.Converter.js +++ b/app/assets/javascripts/external/Markdown.Converter.js @@ -4,7 +4,7 @@ if (typeof exports === "object" && typeof require === "function") // we're in a Markdown = exports; else Markdown = {}; - + // The following text is included for historical reasons, but should // be taken with a pinch of salt; it's not all true anymore. @@ -107,26 +107,26 @@ else Markdown.Converter = function () { var pluginHooks = this.hooks = new HookCollection(); - + // given a URL that was encountered by itself (without markup), should return the link text that's to be given to this link pluginHooks.addNoop("plainLinkText"); - + // called with the orignal text as given to makeHtml. The result of this plugin hook is the actual markdown source that will be cooked pluginHooks.addNoop("preConversion"); - + // called with the text once all normalizations have been completed (tabs to spaces, line endings, etc.), but before any conversions have pluginHooks.addNoop("postNormalization"); - + // Called with the text before / after creating block elements like code blocks and lists. Note that this is called recursively // with inner content, e.g. it's called with the full text, and then only with the content of a blockquote. The inner // call will receive outdented text. pluginHooks.addNoop("preBlockGamut"); pluginHooks.addNoop("postBlockGamut"); - + // called with the text of a single block element before / after the span-level conversions (bold, code spans, etc.) have been made pluginHooks.addNoop("preSpanGamut"); pluginHooks.addNoop("postSpanGamut"); - + // called with the final cooked HTML code. The result of this plugin hook is the actual output of makeHtml pluginHooks.addNoop("postConversion"); @@ -156,7 +156,7 @@ else // Don't do that. if (g_urls) throw new Error("Recursive call to converter.makeHtml"); - + // Create the private state objects. g_urls = new SaveHash(); g_titles = new SaveHash(); @@ -191,7 +191,7 @@ else // match consecutive blank lines with /\n+/ instead of something // contorted like /[ \t]*\n+/ . text = text.replace(/^[ \t]+$/mg, ""); - + text = pluginHooks.postNormalization(text); // Turn block-level HTML blocks into hash entries @@ -330,7 +330,7 @@ else text = text.replace(/^(<(p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math)\b[^\r]*?.*<\/\2>[ \t]*(?=\n+)\n)/gm, hashElement); // Special case just for
. It was easier to make a special case than - // to make the other regex more complicated. + // to make the other regex more complicated. /* text = text.replace(/ @@ -403,7 +403,7 @@ else return blockText; } - + var blockGamutHookCallback = function (t) { return _RunBlockGamut(t); } function _RunBlockGamut(text, doNotUnhash) { @@ -411,9 +411,9 @@ else // These are all the transformations that form block-level // tags like paragraphs, headers, and list items. // - + text = pluginHooks.preBlockGamut(text, blockGamutHookCallback); - + text = _DoHeaders(text); // Do Horizontal Rules: @@ -425,7 +425,7 @@ else text = _DoLists(text); text = _DoCodeBlocks(text); text = _DoBlockQuotes(text); - + text = pluginHooks.postBlockGamut(text, blockGamutHookCallback); // We already ran _HashHTMLBlocks() before, in Markdown(), but that @@ -445,7 +445,7 @@ else // text = pluginHooks.preSpanGamut(text); - + text = _DoCodeSpans(text); text = _EscapeSpecialCharsWithinTagAttributes(text); text = _EncodeBackslashEscapes(text); @@ -459,15 +459,15 @@ else // Must come after _DoAnchors(), because you can use < and > // delimiters in inline links like [this](). text = _DoAutoLinks(text); - + text = text.replace(/~P/g, "://"); // put in place to prevent autolinking; reset now - + text = _EncodeAmpsAndAngles(text); text = _DoItalicsAndBold(text); // Do hard breaks: text = text.replace(/ +\n/g, "
\n"); - + text = pluginHooks.postSpanGamut(text); return text; @@ -479,7 +479,7 @@ else // don't conflict with their use in Markdown for code, italics and strong. // - // Build a regex to find HTML tags and comments. See Friedl's + // Build a regex to find HTML tags and comments. See Friedl's // "Mastering Regular Expressions", 2nd Ed., pp. 200-201. // SE: changed the comment part of the regex @@ -553,7 +553,7 @@ else | [^()\s] )*? - )>? + )>? [ \t]* ( // $5 (['"]) // quote char = $6 @@ -692,7 +692,7 @@ else return text; } - + function attributeEncode(text) { // unconditionally replace angle brackets here -- what ends up in an attribute (e.g. alt or title) // never makes sense to have verbatim HTML in it (and the sanitizer would totally break it) @@ -725,7 +725,7 @@ else return whole_match; } } - + alt_text = escapeCharacters(attributeEncode(alt_text), "*_[]()"); url = escapeCharacters(url, "*_"); var result = "\""` blocks. - // + // /* text = text.replace(/ @@ -1004,26 +1004,26 @@ else function _DoCodeSpans(text) { // // * Backtick quotes are used for spans. - // + // // * You can use multiple backticks as the delimiters if you want to // include literal backticks in the code span. So, this input: - // + // // Just type ``foo `bar` baz`` at the prompt. - // + // // Will translate to: - // + // //

Just type foo `bar` baz at the prompt.

- // + // // There's no arbitrary limit to the number of backticks you // can use as delimters. If you need three consecutive backticks // in your code, use four for delimiters, etc. // // * You can use spaces to get literal backticks at the edges: - // + // // ... type `` `bar` `` ... - // + // // Turns to: - // + // // ... type `bar` ... // @@ -1156,7 +1156,7 @@ else var grafs = text.split(/\n{2,}/g); var grafsOut = []; - + var markerRe = /~K(\d+)K/; // @@ -1230,7 +1230,7 @@ else text = text.replace(/\\([`*_{}\[\]()>#+-.!])/g, escapeCharacters_callback); return text; } - + function handleTrailingParens(wholeMatch, lookbehind, protocol, link) { if (lookbehind) return wholeMatch; @@ -1257,7 +1257,7 @@ else return ""; }); } - + return "<" + protocol + link + ">" + tail; } @@ -1273,13 +1273,13 @@ else text = text.replace(/(="|='|<)?\b(https?|ftp)(:\/\/[-A-Z0-9+&@#\/%?=~_|\[\]\(\)!:,\.;]*[-A-Z0-9+&@#\/%=~_|\[\])])(?=$|\W)/gi, handleTrailingParens); // autolink anything like - - var replacer = function (wholematch, m1) { + + var replacer = function (wholematch, m1) { m1encoded = m1.replace(/\_\_/, '%5F%5F'); - return "" + pluginHooks.plainLinkText(m1) + ""; + return "" + pluginHooks.plainLinkText(m1) + ""; } text = text.replace(/<((https?|ftp):[^'">\s]+)>/gi, replacer); - + return text; } @@ -1337,7 +1337,7 @@ else var _problemUrlChars = /(?:["'*()[\]:]|~D)/g; - // hex-encodes some unusual "problem" chars in URLs to avoid URL detection problems + // hex-encodes some unusual "problem" chars in URLs to avoid URL detection problems function encodeProblemUrlChars(url) { if (!url) return ""; diff --git a/app/assets/javascripts/external/Markdown.Editor.js b/app/assets/javascripts/external/Markdown.Editor.js index 37ea886f3..7496bd062 100644 --- a/app/assets/javascripts/external/Markdown.Editor.js +++ b/app/assets/javascripts/external/Markdown.Editor.js @@ -77,7 +77,7 @@ // ------------------------------------------------------------------- // YOUR CHANGES GO HERE // - // I've tried to localize the things you are likely to change to + // I've tried to localize the things you are likely to change to // this area. // ------------------------------------------------------------------- @@ -109,7 +109,7 @@ // - run() actually starts the editor; should be called after all necessary plugins are registered. Calling this more than once is a no-op. // - refreshPreview() forces the preview to be updated. This method is only available after run() was called. Markdown.Editor = function (markdownConverter, idPostfix, options) { - + options = options || {}; if (typeof options.handler === "function") { //backwards compatible behavior @@ -230,7 +230,7 @@ beforeReplacer = function (s) { that.before += s; return ""; } afterReplacer = function (s) { that.after = s + that.after; return ""; } } - + this.selection = this.selection.replace(/^(\s*)/, beforeReplacer).replace(/(\s*)$/, afterReplacer); }; @@ -298,14 +298,14 @@ } }; - // end of Chunks + // end of Chunks // A collection of the important regions on the page. // Cached so we don't have to keep traversing the DOM. // Also holds ieCachedRange and ieCachedScrollTop, where necessary; working around // this issue: // Internet explorer has problems with CSS sprite buttons that use HTML - // lists. When you click on the background image "button", IE will + // lists. When you click on the background image "button", IE will // select the non-existent link text and discard the selection in the // textarea. The solution to this is to cache the textarea selection // on the button's mousedown event and set a flag. In the part of the @@ -652,7 +652,7 @@ setMode("escape"); } else if ((keyCode < 16 || keyCode > 20) && keyCode != 91) { - // 16-20 are shift, etc. + // 16-20 are shift, etc. // 91: left window key // I think this might be a little messed up since there are // a lot of nonprinting keys above 20. @@ -796,7 +796,7 @@ if (panels.ieCachedRange) stateObj.scrollTop = panels.ieCachedScrollTop; // this is set alongside with ieCachedRange - + panels.ieCachedRange = null; this.setInputAreaSelection(); @@ -907,7 +907,7 @@ pushPreviewHtml(text); }; - + // makePreviewHtml = window.probes.measure(makePreviewHtml, { // before: function(){ window.probes.clear(); }, // name: "makePreview", @@ -915,7 +915,7 @@ // }); - // TODO allow us to inject this in (its our debouncer) + // TODO allow us to inject this in (its our debouncer) var debounce = function(func,wait,trickle) { var timeout = null; return function(){ @@ -926,26 +926,26 @@ timeout = null; func.apply(context, args); }; - + if (timeout!=null && trickle) { return; } - var currentWait; + var currentWait; if (typeof wait == "function") { currentWait = wait(); } else { currentWait = wait; } - + //console.log(currentWait); if (timeout) { clearTimeout(timeout); } timeout = setTimeout(later, currentWait); } } - makePreviewHtml = debounce(makePreviewHtml, function(){ - return Math.min(Math.max((elapsedTime || 1) * 10, 80),1000); + makePreviewHtml = debounce(makePreviewHtml, function(){ + return Math.min(Math.max((elapsedTime || 1) * 10, 80),1000); }, true); @@ -1086,9 +1086,9 @@ var background = doc.createElement("div"), style = background.style; - + background.className = "wmd-prompt-background"; - + style.position = "absolute"; style.top = "0"; @@ -1400,7 +1400,7 @@ // // var link = CreateLinkDialog(); // makeMarkdownLink(link); - // + // // Instead of this straightforward method of handling a // dialog I have to pass any code which would execute // after the dialog is dismissed (e.g. link creation) @@ -1511,7 +1511,7 @@ var b = insertButtons[i]; makeButton(b.id, b.description, b.execute) } - } + } } buttons.bold = makeButton("wmd-bold-button", getString("bold"), bindCommand("doBold")); @@ -1767,7 +1767,7 @@ } else { - + // We're moving start and end tag back into the selection, since (as we're in the else block) we're not // *removing* a link, but *adding* one, so whatever findTags() found is now back to being part of the // link text. linkEnteredCallback takes care of escaping any brackets. @@ -1805,7 +1805,7 @@ // would mean a zero-width match at the start. Since zero-width matches advance the string position, // the first bracket could then not act as the "not a backslash" for the second. chunk.selection = (" " + chunk.selection).replace(/([^\\](?:\\\\)*)(?=[[\]])/g, "$1\\").substr(1); - + var linkDef = " [999]: " + properlyEncoded(link); var num = that.addLinkDef(chunk, linkDef); @@ -1847,7 +1847,7 @@ chunk.before = chunk.before.replace(/(\n|^)[ ]{0,3}([*+-]|\d+[.])[ \t]*\n$/, "\n\n"); chunk.before = chunk.before.replace(/(\n|^)[ ]{0,3}>[ \t]*\n$/, "\n\n"); chunk.before = chunk.before.replace(/(\n|^)[ \t]+\n$/, "\n\n"); - + // There's no selection, end the cursor wasn't at the end of the line: // The user wants to split the current list item / code line / blockquote line // (for the latter it doesn't really matter) in two. Temporarily select the @@ -1875,7 +1875,7 @@ commandMgr.doCode(chunk); } } - + if (fakeSelection) { chunk.after = chunk.selection + chunk.after; chunk.selection = ""; diff --git a/app/assets/javascripts/external/Markdown.Sanitizer.js b/app/assets/javascripts/external/Markdown.Sanitizer.js index cc5826fa8..c3283e590 100644 --- a/app/assets/javascripts/external/Markdown.Sanitizer.js +++ b/app/assets/javascripts/external/Markdown.Sanitizer.js @@ -7,7 +7,7 @@ output = window.Markdown; Converter = output.Converter; } - + output.getSanitizingConverter = function () { var converter = new Converter(); converter.hooks.chain("postConversion", sanitizeHtml); @@ -37,9 +37,9 @@ /// /// attempt to balance HTML tags in the html string /// by removing any unmatched opening or closing tags - /// IMPORTANT: we *assume* HTML has *already* been + /// IMPORTANT: we *assume* HTML has *already* been /// sanitized and is safe/sane before balancing! - /// + /// /// adapted from CODESNIPPET: A8591DBA-D1D3-11DE-947C-BA5556D89593 /// function balanceTags(html) { diff --git a/app/assets/javascripts/external/bootstrap-button.js b/app/assets/javascripts/external/bootstrap-button.js index 11ecb9d61..6c0371d3c 100644 --- a/app/assets/javascripts/external/bootstrap-button.js +++ b/app/assets/javascripts/external/bootstrap-button.js @@ -48,7 +48,7 @@ $el.addClass(d).attr(d, d) : $el.removeClass(d).removeAttr(d) }, 0) - } + } Button.prototype.toggle = function () { var $parent = this.$element.parent('[data-toggle="buttons-radio"]') @@ -93,4 +93,4 @@ }) }) -}(window.jQuery); \ No newline at end of file +}(window.jQuery); diff --git a/app/assets/javascripts/external/chosen.jquery.js b/app/assets/javascripts/external/chosen.jquery.js index d6e75eadf..9ae0bac34 100644 --- a/app/assets/javascripts/external/chosen.jquery.js +++ b/app/assets/javascripts/external/chosen.jquery.js @@ -1,6 +1,6 @@ // Chosen, a Select Box Enhancer for jQuery and Protoype // by Patrick Filler for Harvest, http://getharvest.com -// +// // Version 0.9.8 // Full source at https://github.com/harvesthq/chosen // Copyright (c) 2011 Harvest http://getharvest.com diff --git a/app/assets/javascripts/external/ember.js b/app/assets/javascripts/external/ember.js index ed42c6f05..158146f5f 100644 --- a/app/assets/javascripts/external/ember.js +++ b/app/assets/javascripts/external/ember.js @@ -1752,7 +1752,7 @@ var MapWithDefault = Ember.MapWithDefault = function(options) { @static @param [options] @param {anything} [options.defaultValue] - @return {Ember.MapWithDefault|Ember.Map} If options are passed, returns + @return {Ember.MapWithDefault|Ember.Map} If options are passed, returns `Ember.MapWithDefault` otherwise returns `Ember.Map` */ MapWithDefault.create = function(options) { @@ -1826,7 +1826,7 @@ var FIRST_KEY = /^([^\.\*]+)/; If you plan to run on IE8 and older browsers then you should use this method anytime you want to retrieve a property on an object that you don't - know for sure is private. (Properties beginning with an underscore '_' + know for sure is private. (Properties beginning with an underscore '_' are considered private.) On all newer browsers, you only need to use this method to retrieve @@ -1888,7 +1888,7 @@ get = function get(obj, keyName) { If you plan to run on IE8 and older browsers then you should use this method anytime you want to set a property on an object that you don't - know for sure is private. (Properties beginning with an underscore '_' + know for sure is private. (Properties beginning with an underscore '_' are considered private.) On all newer browsers, you only need to use this method to set @@ -4229,7 +4229,7 @@ Ember.RunLoop = RunLoop; ```javascript Ember.run(function(){ - // code to be execute within a RunLoop + // code to be execute within a RunLoop }); ``` @@ -4268,7 +4268,7 @@ var run = Ember.run; ```javascript Ember.run.begin(); - // code to be execute within a RunLoop + // code to be execute within a RunLoop Ember.run.end(); ``` @@ -4286,7 +4286,7 @@ Ember.run.begin = function() { ```javascript Ember.run.begin(); - // code to be execute within a RunLoop + // code to be execute within a RunLoop Ember.run.end(); ``` @@ -7358,7 +7358,7 @@ Ember.Enumerable = Ember.Mixin.create( @method nextObject @param {Number} index the current index of the iteration - @param {Object} previousObject the value returned by the last call to + @param {Object} previousObject the value returned by the last call to `nextObject`. @param {Object} context a context object you can use to maintain state. @return {Object} the next object in the iteration or undefined @@ -8425,9 +8425,9 @@ Ember.Array = Ember.Mixin.create(Ember.Enumerable, /** @scope Ember.Array.protot @method arrayContentWillChange @param {Number} startIdx The starting index in the array that will change. - @param {Number} removeAmt The number of items that will be removed. If you + @param {Number} removeAmt The number of items that will be removed. If you pass `null` assumes 0 - @param {Number} addAmt The number of items that will be added If you + @param {Number} addAmt The number of items that will be added If you pass `null` assumes 0. @return {Ember.Array} receiver */ @@ -8901,11 +8901,11 @@ Ember.MutableArray = Ember.Mixin.create(Ember.Array, Ember.MutableEnumerable, passed array. You should also call `this.enumerableContentDidChange()` @method replace - @param {Number} idx Starting index in the array to replace. If + @param {Number} idx Starting index in the array to replace. If idx >= length, then append to the end of the array. - @param {Number} amt Number of elements that should be removed from + @param {Number} amt Number of elements that should be removed from the array, starting at *idx*. - @param {Array} objects An array of zero or more objects that should be + @param {Array} objects An array of zero or more objects that should be inserted into the array at *idx* */ replace: Ember.required(), @@ -10160,14 +10160,14 @@ CoreObject.PrototypeMixin = Mixin.create({ view.get('classNames'); // ['ember-view', 'bar', 'foo', 'baz'] ``` Adding a single property that is not an array will just add it in the array: - + ```javascript var view = App.FooBarView.create({ classNames: 'baz' }) view.get('classNames'); // ['ember-view', 'bar', 'foo', 'baz'] ``` - + Using the `concatenatedProperties` property, we can tell to Ember that mix the content of the properties. @@ -14250,7 +14250,7 @@ class: * `mouseEnter` * `mouseLeave` - Form events: + Form events: * `submit` * `change` @@ -14258,7 +14258,7 @@ class: * `focusOut` * `input` - HTML5 drag and drop events: + HTML5 drag and drop events: * `dragStart` * `drag` @@ -15795,14 +15795,14 @@ Ember.View.reopenClass({ `className` and optional `falsyClassName`. - if a `className` or `falsyClassName` has been specified: - - if the value is truthy and `className` has been specified, + - if the value is truthy and `className` has been specified, `className` is returned - - if the value is falsy and `falsyClassName` has been specified, + - if the value is falsy and `falsyClassName` has been specified, `falsyClassName` is returned - otherwise `null` is returned - - if the value is `true`, the dasherized last part of the supplied path + - if the value is `true`, the dasherized last part of the supplied path is returned - - if the value is not `false`, `undefined` or `null`, the `value` + - if the value is not `false`, `undefined` or `null`, the `value` is returned - if none of the above rules apply, `null` is returned @@ -16652,7 +16652,7 @@ var get = Ember.get, set = Ember.set, fmt = Ember.String.fmt; Given an empty `` and the following code: - ```javascript + ```javascript someItemsView = Ember.CollectionView.create({ classNames: ['a-collection'], content: ['A','B','C'], @@ -17824,7 +17824,7 @@ Ember.Handlebars.registerHelper('helperMissing', function(path, options) { ## Example with bound options - Bound hash options are also supported. Example: + Bound hash options are also supported. Example: ```handlebars {{repeat text countBinding="numRepeats"}} @@ -17862,15 +17862,15 @@ Ember.Handlebars.registerHelper('helperMissing', function(path, options) { {{concatenate prop1 prop2 prop3}}. If any of the properties change, the helpr will re-render. Note that dependency keys cannot be using in conjunction with multi-property helpers, since it is ambiguous - which property the dependent keys would belong to. - + which property the dependent keys would belong to. + ## Use with unbound helper - The {{unbound}} helper can be used with bound helper invocations + The {{unbound}} helper can be used with bound helper invocations to render them in their unbound form, e.g. ```handlebars - {{unbound capitalize name}} + {{unbound capitalize name}} ``` In this example, if the name property changes, the helper @@ -17896,7 +17896,7 @@ Ember.Handlebars.registerBoundHelper = function(name, fn) { view = data.view, currentContext = (options.contexts && options.contexts[0]) || this, normalized, - pathRoot, path, + pathRoot, path, loc, hashOption; // Detect bound options (e.g. countBinding="otherCount") @@ -18002,7 +18002,7 @@ function evaluateMultiPropertyBoundHelper(context, fn, normalizedProperties, opt // Assemble liast of watched properties that'll re-render this helper. watchedProperties = []; for (boundOption in boundOptions) { - if (boundOptions.hasOwnProperty(boundOption)) { + if (boundOptions.hasOwnProperty(boundOption)) { watchedProperties.push(normalizePath(context, boundOptions[boundOption], data)); } } @@ -18937,14 +18937,14 @@ EmberHandlebars.registerHelper('unless', function(context, options) { Result in the following rendered output: - ```html + ```html ``` A boolean return value will insert a specified class name if the property returns `true` and remove the class name if the property returns `false`. - A class name is provided via the syntax + A class name is provided via the syntax `somePropertyName:class-name-if-true`. ```javascript @@ -19103,9 +19103,9 @@ EmberHandlebars.registerHelper('bindAttr', function(options) { @method bindClasses @for Ember.Handlebars @param {Ember.Object} context The context from which to lookup properties - @param {String} classBindings A string, space-separated, of class bindings + @param {String} classBindings A string, space-separated, of class bindings to use - @param {Ember.View} view The view in which observers should look for the + @param {Ember.View} view The view in which observers should look for the element to update @param {Srting} bindAttrId Optional bindAttr id used to lookup elements @return {Array} An array of class names to add @@ -19795,7 +19795,7 @@ Ember.Handlebars.registerHelper('unbound', function(property, fn) { // Unbound helper call. options.data.isUnbound = true; helper = Ember.Handlebars.helpers[arguments[0]] || Ember.Handlebars.helperMissing; - out = helper.apply(this, Array.prototype.slice.call(arguments, 1)); + out = helper.apply(this, Array.prototype.slice.call(arguments, 1)); delete options.data.isUnbound; return out; } @@ -21093,7 +21093,7 @@ helpers = helpers || Ember.Handlebars.helpers; data = data || {}; var buffer = '', stack1, hashTypes, escapeExpression=this.escapeExpression, self=this; function program1(depth0,data) { - + var buffer = '', hashTypes; data.buffer.push("