pwb 1.0.0 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/app/assets/javascripts/comfy/admin/cms/custom.js.coffee +1 -0
- data/app/assets/stylesheets/comfy/admin/cms/custom.sass +1 -0
- data/app/assets/stylesheets/pwb/themes/berlin/inmo.scss +6 -1
- data/app/assets/stylesheets/pwb/themes/berlin/main.scss +12 -11
- data/app/assets/stylesheets/pwb/themes/default/shame.scss +1 -1
- data/app/controllers/pwb/admin_panel_controller.rb +2 -2
- data/app/controllers/pwb/api/v1/cms_pages_controller.rb +102 -0
- data/app/controllers/pwb/api/v1/website_controller.rb +7 -0
- data/app/controllers/pwb/api_public/v1/props_controller.rb +2 -2
- data/app/controllers/pwb/application_api_controller.rb +3 -7
- data/app/controllers/pwb/application_controller.rb +2 -3
- data/app/controllers/pwb/comfy_controller.rb +106 -0
- data/app/controllers/pwb/css_controller.rb +1 -2
- data/app/controllers/pwb/devise/registrations_controller.rb +2 -5
- data/app/controllers/pwb/devise_controller.rb +3 -8
- data/app/controllers/pwb/export/properties_controller.rb +5 -6
- data/app/controllers/pwb/export/translations_controller.rb +1 -5
- data/app/controllers/pwb/export/web_contents_controller.rb +1 -4
- data/app/controllers/pwb/export/website_controller.rb +0 -1
- data/app/controllers/pwb/import/mls_controller.rb +3 -6
- data/app/controllers/pwb/import/properties_controller.rb +2 -4
- data/app/controllers/pwb/import/scrapper_controller.rb +6 -9
- data/app/controllers/pwb/props_controller.rb +10 -13
- data/app/controllers/pwb/search_controller.rb +16 -16
- data/app/controllers/pwb/sections_controller.rb +21 -22
- data/app/controllers/pwb/welcome_controller.rb +1 -2
- data/app/helpers/pwb/application_helper.rb +37 -0
- data/app/helpers/pwb/css_helper.rb +9 -0
- data/app/models/pwb/cms_page_container.rb +9 -0
- data/app/models/pwb/content.rb +10 -6
- data/app/models/pwb/prop.rb +12 -4
- data/app/models/pwb/section.rb +1 -1
- data/app/models/pwb/website.rb +14 -1
- data/app/resources/pwb/api/v1/cms_block_resource.rb +11 -0
- data/app/resources/pwb/api/v1/cms_page_resource.rb +27 -0
- data/app/themes/berlin/views/layouts/pwb/application.html.erb +25 -9
- data/app/themes/berlin/views/pwb/props/show.html.erb +5 -5
- data/app/themes/berlin/views/pwb/search/_search_results.html.erb +2 -1
- data/app/themes/berlin/views/pwb/search/buy.html.erb +1 -1
- data/app/themes/berlin/views/pwb/search/rent.html.erb +2 -1
- data/app/themes/berlin/views/pwb/sections/about_us.html.erb +3 -2
- data/app/themes/berlin/views/pwb/sections/cms.html.erb +34 -0
- data/app/themes/berlin/views/pwb/sections/contact_us.html.erb +2 -1
- data/app/themes/berlin/views/pwb/welcome/_about_us_to_del.html.erb +35 -0
- data/app/themes/berlin/views/pwb/welcome/{_adv_search.html.erb → _adv_search_to_del.html.erb} +0 -0
- data/app/themes/berlin/views/pwb/welcome/_landing_carousel.html.erb +1 -1
- data/app/themes/berlin/views/pwb/welcome/_latest_properties.html.erb +2 -1
- data/app/themes/default/views/layouts/pwb/application.html.erb +24 -3
- data/app/themes/default/views/pwb/sections/about_us.html.erb +1 -2
- data/app/themes/default/views/pwb/sections/cms.html.erb +30 -0
- data/app/themes/default/views/pwb/welcome/_single_property_row.html.erb +2 -1
- data/app/themes/default/views/pwb/welcome/index.html.erb +3 -1
- data/app/views/layouts/pwb/devise.html.erb +1 -0
- data/app/views/pwb/_analytics.html.erb +15 -0
- data/app/views/pwb/_footer.html.erb +0 -12
- data/app/views/pwb/custom_css/{berlin.css.erb → _berlin.css.erb} +0 -1
- data/app/views/pwb/custom_css/{default.css.erb → _default.css.erb} +0 -1
- data/app/views/pwb/custom_css/_shared.css.erb +1 -0
- data/app/views/pwb/props/_images_section_carousel.html.erb +13 -27
- data/app/views/pwb/props/_prop_info_list.html.erb +1 -1
- data/app/views/pwb/search/_search_result_item.html.erb +62 -64
- data/app/views/pwb/search/_search_result_item_to_del.html.erb +3 -3
- data/config/client_setups/default.json +59 -21
- data/config/cms_page_containers/about-us.json +18 -0
- data/config/cms_page_containers/about.json +107 -0
- data/config/cms_page_containers/landing.json +19 -0
- data/config/cms_page_containers/legal.json +17 -0
- data/config/cms_page_containers/sell.json +96 -0
- data/config/initializers/cloudinary.rb +3 -0
- data/config/initializers/comfortable_mexican_sofa.rb +142 -0
- data/config/locales/admin.en.yml +213 -0
- data/config/locales/admin.es.yml +32 -17
- data/config/locales/admin.ru.yml +432 -0
- data/config/locales/admin.zh.yml.tmp +226 -0
- data/config/locales/de.yml +31 -32
- data/config/locales/devise.zh-HK.yml +119 -0
- data/config/locales/en.yml +3 -0
- data/config/locales/es.yml +3 -5
- data/config/locales/rails.zh-HK.yml +210 -0
- data/config/locales/ru.yml +11 -11
- data/config/locales/zh-HK.yml +154 -0
- data/config/routes.rb +17 -2
- data/db/cms_fixtures/cms/categories/pages.yml +3 -0
- data/db/cms_fixtures/cms/files/_rerenting-landing_framed.png.yml +6 -0
- data/{spec/dummy/public/system/comfy/cms/files/files/000/000/003/original → db/cms_fixtures/cms/files}/rerenting-landing_framed.png +0 -0
- data/db/cms_fixtures/cms/layouts/about-us/attributes.yml +4 -0
- data/db/cms_fixtures/cms/layouts/about-us/content.html +0 -0
- data/db/cms_fixtures/cms/layouts/about-us/javascript.js +0 -0
- data/db/cms_fixtures/cms/layouts/about-us/people/attributes.yml +4 -0
- data/db/cms_fixtures/cms/layouts/about-us/people/content.html +55 -0
- data/db/cms_fixtures/cms/layouts/about-us/services/attributes.yml +4 -0
- data/db/cms_fixtures/cms/layouts/about-us/services/content.html +32 -0
- data/db/cms_fixtures/cms/layouts/about-us/services/javascript.js +0 -0
- data/db/cms_fixtures/cms/layouts/about-us/services/stylesheet.css +0 -0
- data/db/cms_fixtures/cms/layouts/about-us/stylesheet.css +0 -0
- data/db/cms_fixtures/cms/layouts/default-layout/attributes.yml +4 -0
- data/db/cms_fixtures/cms/layouts/default-layout/content.html +51 -0
- data/db/cms_fixtures/cms/layouts/default-layout/javascript.js +0 -0
- data/db/cms_fixtures/cms/layouts/default-layout/stylesheet.css +0 -0
- data/db/cms_fixtures/cms/pages/index/about-us/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_details_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_details_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_details_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_details_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_img_url_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_img_url_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_img_url_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_img_url_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_name_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_name_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_name_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_name_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_title_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_title_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_title_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/de/person_title_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_details_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_details_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_details_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_details_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_img_url_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_img_url_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_img_url_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_img_url_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_name_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_name_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_name_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_name_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_title_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_title_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_title_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/en/person_title_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_details_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_details_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_details_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_details_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_img_url_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_img_url_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_img_url_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_img_url_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_name_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_name_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_name_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_name_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_title_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_title_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_title_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/es/person_title_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_details_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_details_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_details_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_details_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_name_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_name_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_name_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_name_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_title_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_title_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_title_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/pt/person_title_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_details_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_details_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_details_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_details_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_img_url_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_img_url_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_img_url_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_img_url_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_name_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_name_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_name_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_name_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_title_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_title_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_title_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/people/ru/person_title_d.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/content_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/content_b.html +0 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/content_c.html +0 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/de/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/de/content_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/de/content_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/de/content_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/de/title_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/de/title_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/de/title_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/en/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/en/content_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/en/content_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/en/content_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/en/title_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/en/title_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/en/title_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/es/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/es/content_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/es/content_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/es/content_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/es/title_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/es/title_b.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/es/title_c.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/title_a.html +1 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/title_b.html +0 -0
- data/db/cms_fixtures/cms/pages/index/about-us/services/title_c.html +0 -0
- data/db/cms_fixtures/cms/pages/index/attributes.yml +8 -0
- data/db/cms_fixtures/cms/pages/index/content.html +1 -0
- data/db/cms_fixtures/cms/pages/index/title.html +0 -0
- data/db/cms_fixtures/cms/snippets/snippet1/attributes.yml +3 -0
- data/db/cms_fixtures/cms/snippets/snippet1/content.html +1 -0
- data/db/cms_fixtures/sample-site/categories/files.yml +1 -0
- data/db/cms_fixtures/sample-site/categories/pages.yml +1 -0
- data/db/cms_fixtures/sample-site/categories/snippets.yml +1 -0
- data/db/cms_fixtures/sample-site/files/_sample.jpg.yml +5 -0
- data/db/cms_fixtures/sample-site/files/sample.jpg +0 -0
- data/db/cms_fixtures/sample-site/layouts/default/attributes.yml +1 -0
- data/db/cms_fixtures/sample-site/layouts/default/content.html +5 -0
- data/db/cms_fixtures/sample-site/layouts/default/javascript.js +1 -0
- data/db/cms_fixtures/sample-site/layouts/default/nested/attributes.yml +2 -0
- data/db/cms_fixtures/sample-site/layouts/default/nested/content.haml +3 -0
- data/db/cms_fixtures/sample-site/layouts/default/nested/javascript.js +1 -0
- data/db/cms_fixtures/sample-site/layouts/default/nested/stylesheet.css +1 -0
- data/db/cms_fixtures/sample-site/layouts/default/stylesheet.css +1 -0
- data/db/cms_fixtures/sample-site/pages/index/attributes.yml +6 -0
- data/db/cms_fixtures/sample-site/pages/index/child/attributes.yml +3 -0
- data/db/cms_fixtures/sample-site/pages/index/child/left.haml +1 -0
- data/db/cms_fixtures/sample-site/pages/index/child/right.html +1 -0
- data/db/cms_fixtures/sample-site/pages/index/child/thumbnail.png +0 -0
- data/db/cms_fixtures/sample-site/pages/index/content.html +2 -0
- data/db/cms_fixtures/sample-site/snippets/default/attributes.yml +4 -0
- data/db/cms_fixtures/sample-site/snippets/default/content.html +1 -0
- data/db/migrate/20170513221300_create_cms.rb +133 -0
- data/db/seeds/spain/translations.rb +2 -2
- data/db/seeds/translations_ca.rb +92 -0
- data/db/seeds/translations_de.rb +86 -85
- data/db/seeds/translations_en.rb +73 -73
- data/db/seeds/translations_es.rb +79 -78
- data/db/seeds/translations_ru.rb +92 -0
- data/db/yml_seeds/prop/flat_for_rent.yml +4 -4
- data/db/yml_seeds/sections.yml +2 -2
- data/db/yml_seeds/website.yml +3 -1
- data/lib/pwb/cms_data_loader.rb +38 -0
- data/lib/pwb/engine.rb +1 -0
- data/lib/pwb/locale_loader.rb +47 -0
- data/lib/pwb/seeder.rb +8 -5
- data/lib/pwb/version.rb +1 -1
- data/lib/tasks/pwb_tasks.rake +1 -0
- data/spec/dummy/config/routes.rb +5 -0
- data/spec/dummy/config/secrets.yml +5 -0
- data/spec/dummy/db/schema.rb +111 -1
- data/spec/dummy/log/development.log +0 -0
- data/spec/features/pwb/admin_spec.rb +14 -40
- data/spec/features/pwb/admin_spec_tmp.rb +54 -0
- data/spec/fixtures/to_import/pwb-properties.csv +2 -2
- data/spec/views/pwb/application_layout.html.erb_spec.rb +1 -0
- metadata +207 -235
- data/app/themes/berlin/views/pwb/welcome/_about_us.html.erb +0 -36
- data/db/seeds/translations_others.rb +0 -215
- data/spec/dummy/public/assets/application-af04b226fd7202dfc532ce7aedb95a0128277937e90d3b3a3d35e1cce9e16886.css +0 -16
- data/spec/dummy/public/assets/application-af04b226fd7202dfc532ce7aedb95a0128277937e90d3b3a3d35e1cce9e16886.css.gz +0 -0
- data/spec/dummy/public/assets/application-ec8550e416fd8df1557ddb7f132ccd38baaafd36e4c5c9aff8420fbd47c0313f.js +0 -617
- data/spec/dummy/public/assets/application-ec8550e416fd8df1557ddb7f132ccd38baaafd36e4c5c9aff8420fbd47c0313f.js.gz +0 -0
- data/spec/dummy/public/assets/bootstrap/glyphicons-halflings-regular-13634da87d9e23f8c3ed9108ce1724d183a39ad072e73e1b3d8cbf646d2d0407.eot +0 -0
- data/spec/dummy/public/assets/bootstrap/glyphicons-halflings-regular-13634da87d9e23f8c3ed9108ce1724d183a39ad072e73e1b3d8cbf646d2d0407.eot.gz +0 -0
- data/spec/dummy/public/assets/bootstrap/glyphicons-halflings-regular-42f60659d265c1a3c30f9fa42abcbb56bd4a53af4d83d316d6dd7a36903c43e5.svg +0 -288
- data/spec/dummy/public/assets/bootstrap/glyphicons-halflings-regular-42f60659d265c1a3c30f9fa42abcbb56bd4a53af4d83d316d6dd7a36903c43e5.svg.gz +0 -0
- data/spec/dummy/public/assets/bootstrap/glyphicons-halflings-regular-a26394f7ede100ca118eff2eda08596275a9839b959c226e15439557a5a80742.woff +0 -0
- data/spec/dummy/public/assets/bootstrap/glyphicons-halflings-regular-e395044093757d82afcb138957d06a1ea9361bdcf0b442d06a18a8051af57456.ttf +0 -0
- data/spec/dummy/public/assets/bootstrap/glyphicons-halflings-regular-e395044093757d82afcb138957d06a1ea9361bdcf0b442d06a18a8051af57456.ttf.gz +0 -0
- data/spec/dummy/public/assets/bootstrap/glyphicons-halflings-regular-fe185d11a49676890d47bb783312a0cda5a44c4039214094e7957b4c040ef11c.woff2 +0 -0
- data/spec/dummy/public/assets/pwb/application-0dc6ff845cde8e032ed365593c17fe09c18a6966d44f551946bf1673d8d1ac51.css +0 -13
- data/spec/dummy/public/assets/pwb/application-0dc6ff845cde8e032ed365593c17fe09c18a6966d44f551946bf1673d8d1ac51.css.gz +0 -0
- data/spec/dummy/public/assets/pwb/application-b4df8e7ae7700a0d09d88175af77e7f457ca2fbe15ae08450551ebf3bfb0c4d1.js +0 -15656
- data/spec/dummy/public/assets/pwb/application-b4df8e7ae7700a0d09d88175af77e7f457ca2fbe15ae08450551ebf3bfb0c4d1.js.gz +0 -0
- data/spec/dummy/public/assets/pwb/themes/berlin-279c2e3a7fa11a902fdee83a6819dcc315ff8eb240cfad21b1322cedadb07ea7.js +0 -18690
- data/spec/dummy/public/assets/pwb/themes/berlin-279c2e3a7fa11a902fdee83a6819dcc315ff8eb240cfad21b1322cedadb07ea7.js.gz +0 -0
- data/spec/dummy/public/assets/pwb/themes/berlin-8038d5cfd670e73fbffb581f6bb8d8c00ac448957945622c5c34438c467d218b.css +0 -8582
- data/spec/dummy/public/assets/pwb/themes/berlin-8038d5cfd670e73fbffb581f6bb8d8c00ac448957945622c5c34438c467d218b.css.gz +0 -0
- data/spec/dummy/public/assets/pwb/themes/chic-facdff61de4827adfd797b6a36ffd6c8b432072df7190ed722d039f971caa539.css +0 -3500
- data/spec/dummy/public/assets/pwb/themes/chic-facdff61de4827adfd797b6a36ffd6c8b432072df7190ed722d039f971caa539.css.gz +0 -0
- data/spec/dummy/public/assets/pwb/themes/default-d697fb0c278f500986e614ddd7eb41fd7db502a54f3370b3e8166cc1714509d0.css +0 -8423
- data/spec/dummy/public/assets/pwb/themes/default-d697fb0c278f500986e614ddd7eb41fd7db502a54f3370b3e8166cc1714509d0.css.gz +0 -0
- data/spec/dummy/public/assets/pwb_admin_panel/application-2d624898965d7a347eb7f365feab34257032c25051633370811ed7dfd24d7c8c.js +0 -61
- data/spec/dummy/public/assets/pwb_admin_panel/application-2d624898965d7a347eb7f365feab34257032c25051633370811ed7dfd24d7c8c.js.gz +0 -0
- data/spec/dummy/public/assets/pwb_admin_panel/application-f0e38d58d1ce32501b22edd16697f45b561fa44b5be9265398a05e8dee169885.css +0 -17970
- data/spec/dummy/public/assets/pwb_admin_panel/application-f0e38d58d1ce32501b22edd16697f45b561fa44b5be9265398a05e8dee169885.css.gz +0 -0
- data/spec/dummy/public/img/about-us.png +0 -0
- data/spec/dummy/public/img/agents/agent-1.png +0 -0
- data/spec/dummy/public/img/agents/agent-3.png +0 -0
- data/spec/dummy/public/img/agents/agent-4.png +0 -0
- data/spec/dummy/public/img/agents/agent-5.png +0 -0
- data/spec/dummy/public/img/banner-ads.jpg +0 -0
- data/spec/dummy/public/img/blog-img-1.jpg +0 -0
- data/spec/dummy/public/img/blog-img-2.jpg +0 -0
- data/spec/dummy/public/img/blog-img-3.jpg +0 -0
- data/spec/dummy/public/img/client-brand-1.png +0 -0
- data/spec/dummy/public/img/client-brand-2.png +0 -0
- data/spec/dummy/public/img/client-brand-3.png +0 -0
- data/spec/dummy/public/img/client-brand-4.png +0 -0
- data/spec/dummy/public/img/client-brand-5.png +0 -0
- data/spec/dummy/public/img/favicon.ico +0 -0
- data/spec/dummy/public/img/gallery/big/1.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/10.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/11 - Copy.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/12.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/2.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/3.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/4.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/5.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/6.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/7.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/8.jpg +0 -0
- data/spec/dummy/public/img/gallery/big/9.jpg +0 -0
- data/spec/dummy/public/img/gallery/fancybox_buttons.png +0 -0
- data/spec/dummy/public/img/gallery/fancybox_loading.gif +0 -0
- data/spec/dummy/public/img/gallery/fancybox_loading@2x.gif +0 -0
- data/spec/dummy/public/img/gallery/fancybox_overlay.png +0 -0
- data/spec/dummy/public/img/gallery/fancybox_sprite.png +0 -0
- data/spec/dummy/public/img/gallery/fancybox_sprite@2x.png +0 -0
- data/spec/dummy/public/img/gallery/small/1.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/10.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/11.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/12.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/2.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/3.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/4.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/5.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/6.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/7.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/8.jpg +0 -0
- data/spec/dummy/public/img/gallery/small/9.jpg +0 -0
- data/spec/dummy/public/img/item/1.jpg +0 -0
- data/spec/dummy/public/img/item/2.jpg +0 -0
- data/spec/dummy/public/img/item/3.jpg +0 -0
- data/spec/dummy/public/img/item/4.jpg +0 -0
- data/spec/dummy/public/img/item/5.jpg +0 -0
- data/spec/dummy/public/img/item/6.jpg +0 -0
- data/spec/dummy/public/img/logo.png +0 -0
- data/spec/dummy/public/img/promo-banner.jpg +0 -0
- data/spec/dummy/public/img/property-header-bg.jpg +0 -0
- data/spec/dummy/public/img/property-view-2.jpg +0 -0
- data/spec/dummy/public/img/signin-bg.jpg +0 -0
- data/spec/dummy/public/img/slider/1.jpg +0 -0
- data/spec/dummy/public/img/slider/2.jpg +0 -0
- data/spec/dummy/public/img/slider/3.jpg +0 -0
- data/spec/dummy/public/img/slider/4.jpg +0 -0
- data/spec/dummy/public/img/slider/5.jpg +0 -0
- data/spec/dummy/public/img/slider/6.jpg +0 -0
- data/spec/dummy/public/img/testimonial-1.png +0 -0
- data/spec/dummy/public/img/testimonial-2.png +0 -0
- data/spec/dummy/public/img/testimonial-3.png +0 -0
- data/spec/dummy/public/img/testimonial-bg.jpg +0 -0
- data/spec/dummy/public/js/bootstrap.js +0 -2363
- data/spec/dummy/public/js/custom.js +0 -355
- data/spec/dummy/public/js/jquery.fancybox.pack.js +0 -46
- data/spec/dummy/public/js/jquery.min.js +0 -5
- data/spec/dummy/public/js/jquery.mixitup.js +0 -2098
- data/spec/dummy/public/js/nouislider.js +0 -1899
- data/spec/dummy/public/js/slick.js +0 -2670
- data/spec/dummy/public/system/comfy/cms/files/files/000/000/003/cms_thumb/rerenting-landing_framed.png +0 -0
@@ -1,355 +0,0 @@
|
|
1
|
-
/**
|
2
|
-
* Template Name: Home Property
|
3
|
-
* Version: 1.0
|
4
|
-
* Template Scripts
|
5
|
-
* Author: MarkUps
|
6
|
-
* Author URI: http://www.markups.io/
|
7
|
-
|
8
|
-
Custom JS
|
9
|
-
|
10
|
-
|
11
|
-
1. FIXED NAVBAR
|
12
|
-
2. AGENTS SLIDER
|
13
|
-
3. TESTIMONIAL SLIDER
|
14
|
-
4. CLIENT BRAND SLIDER (SLICK SLIDER)
|
15
|
-
5. TOP SLIDER (SLICK SLIDER)
|
16
|
-
6. LATEST PRODUCT SLIDER (SLICK SLIDER)
|
17
|
-
7. HOVER DROPDOWN MENU
|
18
|
-
8. ADVANCE SEARCH FILTER (noUiSlider SLIDER)
|
19
|
-
9. MIXIT FILTER ( FOR GALLERY )
|
20
|
-
10. FANCYBOX ( FOR PORTFOLIO POPUP VIEW )
|
21
|
-
11. SCROLL TOP BUTTON
|
22
|
-
12. PRELOADER
|
23
|
-
13. GRID AND LIST LAYOUT CHANGER
|
24
|
-
14.RELATED ITEM SLIDER (SLICK SLIDER)
|
25
|
-
|
26
|
-
|
27
|
-
**/
|
28
|
-
|
29
|
-
jQuery(function($){
|
30
|
-
|
31
|
-
|
32
|
-
/* ----------------------------------------------------------- */
|
33
|
-
/* 1. FIXED NAVBAR
|
34
|
-
/* ----------------------------------------------------------- */
|
35
|
-
|
36
|
-
|
37
|
-
jQuery(window).bind('scroll', function () {
|
38
|
-
if (jQuery(window).scrollTop() > 200) {
|
39
|
-
jQuery('.main-navbar').addClass('navbar-fixed-top');
|
40
|
-
|
41
|
-
} else {
|
42
|
-
jQuery('.main-navbar').removeClass('navbar-fixed-top');
|
43
|
-
}
|
44
|
-
});
|
45
|
-
|
46
|
-
/* ----------------------------------------------------------- */
|
47
|
-
/* 2. AGENTS SLIDER
|
48
|
-
/* ----------------------------------------------------------- */
|
49
|
-
|
50
|
-
jQuery('.aa-agents-slider').slick({
|
51
|
-
dots: false,
|
52
|
-
arrows: false,
|
53
|
-
infinite: true,
|
54
|
-
speed: 300,
|
55
|
-
slidesToShow: 4,
|
56
|
-
slidesToScroll: 1,
|
57
|
-
autoplay: true,
|
58
|
-
autoplaySpeed: 2500,
|
59
|
-
responsive: [
|
60
|
-
{
|
61
|
-
breakpoint: 1024,
|
62
|
-
settings: {
|
63
|
-
slidesToShow: 3,
|
64
|
-
slidesToScroll: 3,
|
65
|
-
infinite: true,
|
66
|
-
dots: true
|
67
|
-
}
|
68
|
-
},
|
69
|
-
{
|
70
|
-
breakpoint: 600,
|
71
|
-
settings: {
|
72
|
-
slidesToShow: 2,
|
73
|
-
slidesToScroll: 2
|
74
|
-
}
|
75
|
-
},
|
76
|
-
{
|
77
|
-
breakpoint: 480,
|
78
|
-
settings: {
|
79
|
-
slidesToShow: 1,
|
80
|
-
slidesToScroll: 1
|
81
|
-
}
|
82
|
-
}
|
83
|
-
// You can unslick at a given breakpoint now by adding:
|
84
|
-
// settings: "unslick"
|
85
|
-
// instead of a settings object
|
86
|
-
]
|
87
|
-
});
|
88
|
-
|
89
|
-
/* ----------------------------------------------------------- */
|
90
|
-
/* 3. TESTIMONIAL SLIDER
|
91
|
-
/* ----------------------------------------------------------- */
|
92
|
-
|
93
|
-
jQuery('.aa-testimonial-slider').slick({
|
94
|
-
dots: false,
|
95
|
-
infinite: true,
|
96
|
-
speed: 500,
|
97
|
-
cssEase: 'linear'
|
98
|
-
});
|
99
|
-
|
100
|
-
/* ----------------------------------------------------------- */
|
101
|
-
/* 4. CLIENT BRAND SLIDER (SLICK SLIDER)
|
102
|
-
/* ----------------------------------------------------------- */
|
103
|
-
|
104
|
-
jQuery('.aa-client-brand-slider').slick({
|
105
|
-
dots: false,
|
106
|
-
arrows: false,
|
107
|
-
infinite: true,
|
108
|
-
speed: 300,
|
109
|
-
slidesToShow: 5,
|
110
|
-
slidesToScroll: 1,
|
111
|
-
autoplay: true,
|
112
|
-
autoplaySpeed: 2500,
|
113
|
-
responsive: [
|
114
|
-
{
|
115
|
-
breakpoint: 1024,
|
116
|
-
settings: {
|
117
|
-
slidesToShow: 4,
|
118
|
-
slidesToScroll: 4,
|
119
|
-
infinite: true,
|
120
|
-
dots: true
|
121
|
-
}
|
122
|
-
},
|
123
|
-
{
|
124
|
-
breakpoint: 600,
|
125
|
-
settings: {
|
126
|
-
slidesToShow: 2,
|
127
|
-
slidesToScroll: 2
|
128
|
-
}
|
129
|
-
},
|
130
|
-
{
|
131
|
-
breakpoint: 480,
|
132
|
-
settings: {
|
133
|
-
slidesToShow: 1,
|
134
|
-
slidesToScroll: 1
|
135
|
-
}
|
136
|
-
}
|
137
|
-
// You can unslick at a given breakpoint now by adding:
|
138
|
-
// settings: "unslick"
|
139
|
-
// instead of a settings object
|
140
|
-
]
|
141
|
-
});
|
142
|
-
|
143
|
-
|
144
|
-
/* ----------------------------------------------------------- */
|
145
|
-
/* 5. TOP SLIDER (SLICK SLIDER)
|
146
|
-
/* ----------------------------------------------------------- */
|
147
|
-
|
148
|
-
jQuery('.aa-top-slider').slick({
|
149
|
-
dots: false,
|
150
|
-
infinite: true,
|
151
|
-
arrows: true,
|
152
|
-
speed: 500,
|
153
|
-
fade: true,
|
154
|
-
cssEase: 'linear'
|
155
|
-
});
|
156
|
-
|
157
|
-
/* ----------------------------------------------------------- */
|
158
|
-
/* 6. LATEST PRODUCT SLIDER (SLICK SLIDER)
|
159
|
-
/* ----------------------------------------------------------- */
|
160
|
-
|
161
|
-
jQuery('.aa-properties-details-img').slick({
|
162
|
-
dots: false,
|
163
|
-
infinite: true,
|
164
|
-
arrows: true,
|
165
|
-
speed: 500,
|
166
|
-
cssEase: 'linear'
|
167
|
-
});
|
168
|
-
|
169
|
-
|
170
|
-
/* ----------------------------------------------------------- */
|
171
|
-
/* 7. HOVER DROPDOWN MENU
|
172
|
-
/* ----------------------------------------------------------- */
|
173
|
-
|
174
|
-
// for hover dropdown menu
|
175
|
-
jQuery('ul.nav li.dropdown').hover(function() {
|
176
|
-
jQuery(this).find('.dropdown-menu').stop(true, true).delay(200).fadeIn(200);
|
177
|
-
}, function() {
|
178
|
-
jQuery(this).find('.dropdown-menu').stop(true, true).delay(200).fadeOut(200);
|
179
|
-
});
|
180
|
-
|
181
|
-
|
182
|
-
/* ----------------------------------------------------------- */
|
183
|
-
/* 8. ADVANCE SEARCH FILTER (noUiSlider SLIDER)
|
184
|
-
/* ----------------------------------------------------------- */
|
185
|
-
|
186
|
-
jQuery(function(){
|
187
|
-
if(jQuery('body').is('.aa-price-range')){
|
188
|
-
// FOR AREA SECTION
|
189
|
-
var skipSlider = document.getElementById('aa-sqrfeet-range');
|
190
|
-
noUiSlider.create(skipSlider, {
|
191
|
-
range: {
|
192
|
-
'min': 0,
|
193
|
-
'10%': 100,
|
194
|
-
'20%': 200,
|
195
|
-
'30%': 300,
|
196
|
-
'40%': 400,
|
197
|
-
'50%': 500,
|
198
|
-
'60%': 600,
|
199
|
-
'70%': 700,
|
200
|
-
'80%': 800,
|
201
|
-
'90%': 900,
|
202
|
-
'max': 1000
|
203
|
-
},
|
204
|
-
snap: true,
|
205
|
-
connect: true,
|
206
|
-
start: [200, 700]
|
207
|
-
});
|
208
|
-
// for value print
|
209
|
-
var skipValues = [
|
210
|
-
document.getElementById('skip-value-lower'),
|
211
|
-
document.getElementById('skip-value-upper')
|
212
|
-
];
|
213
|
-
|
214
|
-
skipSlider.noUiSlider.on('update', function( values, handle ) {
|
215
|
-
skipValues[handle].innerHTML = values[handle];
|
216
|
-
});
|
217
|
-
|
218
|
-
// FOR PRICE SECTION
|
219
|
-
|
220
|
-
var skipSlider2 = document.getElementById('aa-price-range');
|
221
|
-
noUiSlider.create(skipSlider2, {
|
222
|
-
range: {
|
223
|
-
'min': 0,
|
224
|
-
'10%': 100,
|
225
|
-
'20%': 200,
|
226
|
-
'30%': 300,
|
227
|
-
'40%': 400,
|
228
|
-
'50%': 500,
|
229
|
-
'60%': 600,
|
230
|
-
'70%': 700,
|
231
|
-
'80%': 800,
|
232
|
-
'90%': 900,
|
233
|
-
'max': 1000
|
234
|
-
},
|
235
|
-
snap: true,
|
236
|
-
connect: true,
|
237
|
-
start: [200, 700]
|
238
|
-
});
|
239
|
-
// for value print
|
240
|
-
var skipValues2 = [
|
241
|
-
document.getElementById('skip-value-lower2'),
|
242
|
-
document.getElementById('skip-value-upper2')
|
243
|
-
];
|
244
|
-
|
245
|
-
skipSlider2.noUiSlider.on('update', function( values, handle ) {
|
246
|
-
skipValues2[handle].innerHTML = values[handle];
|
247
|
-
});
|
248
|
-
}
|
249
|
-
});
|
250
|
-
|
251
|
-
/* ----------------------------------------------------------- */
|
252
|
-
/* 9. MIXIT FILTER ( FOR GALLERY )
|
253
|
-
/* ----------------------------------------------------------- */
|
254
|
-
|
255
|
-
jQuery(function(){
|
256
|
-
jQuery('#mixit-container').mixItUp();
|
257
|
-
});
|
258
|
-
|
259
|
-
/* ----------------------------------------------------------- */
|
260
|
-
/* 10. FANCYBOX ( FOR PORTFOLIO POPUP VIEW )
|
261
|
-
/* ----------------------------------------------------------- */
|
262
|
-
|
263
|
-
jQuery(document).ready(function() {
|
264
|
-
jQuery(".fancybox").fancybox();
|
265
|
-
});
|
266
|
-
|
267
|
-
|
268
|
-
/* ----------------------------------------------------------- */
|
269
|
-
/* 11. SCROLL TOP BUTTON
|
270
|
-
/* ----------------------------------------------------------- */
|
271
|
-
|
272
|
-
//Check to see if the window is top if not then display button
|
273
|
-
|
274
|
-
jQuery(window).scroll(function(){
|
275
|
-
if (jQuery(this).scrollTop() > 300) {
|
276
|
-
jQuery('.scrollToTop').fadeIn();
|
277
|
-
} else {
|
278
|
-
jQuery('.scrollToTop').fadeOut();
|
279
|
-
}
|
280
|
-
});
|
281
|
-
|
282
|
-
//Click event to scroll to top
|
283
|
-
|
284
|
-
jQuery('.scrollToTop').click(function(){
|
285
|
-
jQuery('html, body').animate({scrollTop : 0},800);
|
286
|
-
return false;
|
287
|
-
});
|
288
|
-
|
289
|
-
/* ----------------------------------------------------------- */
|
290
|
-
/* 12. PRELOADER
|
291
|
-
/* ----------------------------------------------------------- */
|
292
|
-
|
293
|
-
jQuery(window).load(function() { // makes sure the whole site is loaded
|
294
|
-
jQuery('#aa-preloader-area').delay(300).fadeOut('slow'); // will fade out
|
295
|
-
})
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
/* ----------------------------------------------------------- */
|
300
|
-
/* 13. GRID AND LIST LAYOUT CHANGER
|
301
|
-
/* ----------------------------------------------------------- */
|
302
|
-
|
303
|
-
jQuery("#aa-list-properties").click(function(e){
|
304
|
-
e.preventDefault(e);
|
305
|
-
jQuery(".aa-properties-nav").addClass("aa-list-view");
|
306
|
-
});
|
307
|
-
jQuery("#aa-grid-properties").click(function(e){
|
308
|
-
e.preventDefault(e);
|
309
|
-
jQuery(".aa-properties-nav").removeClass("aa-list-view");
|
310
|
-
});
|
311
|
-
|
312
|
-
|
313
|
-
/* ----------------------------------------------------------- */
|
314
|
-
/* 14. RELATED ITEM SLIDER (SLICK SLIDER)
|
315
|
-
/* ----------------------------------------------------------- */
|
316
|
-
|
317
|
-
jQuery('.aa-related-item-slider').slick({
|
318
|
-
dots: false,
|
319
|
-
infinite: false,
|
320
|
-
speed: 300,
|
321
|
-
slidesToShow: 4,
|
322
|
-
slidesToScroll: 4,
|
323
|
-
responsive: [
|
324
|
-
{
|
325
|
-
breakpoint: 1024,
|
326
|
-
settings: {
|
327
|
-
slidesToShow: 3,
|
328
|
-
slidesToScroll: 3,
|
329
|
-
infinite: true,
|
330
|
-
dots: true
|
331
|
-
}
|
332
|
-
},
|
333
|
-
{
|
334
|
-
breakpoint: 600,
|
335
|
-
settings: {
|
336
|
-
slidesToShow: 2,
|
337
|
-
slidesToScroll: 2
|
338
|
-
}
|
339
|
-
},
|
340
|
-
{
|
341
|
-
breakpoint: 480,
|
342
|
-
settings: {
|
343
|
-
slidesToShow: 1,
|
344
|
-
slidesToScroll: 1
|
345
|
-
}
|
346
|
-
}
|
347
|
-
// You can unslick at a given breakpoint now by adding:
|
348
|
-
// settings: "unslick"
|
349
|
-
// instead of a settings object
|
350
|
-
]
|
351
|
-
});
|
352
|
-
|
353
|
-
|
354
|
-
});
|
355
|
-
|
@@ -1,46 +0,0 @@
|
|
1
|
-
/*! fancyBox v2.1.5 fancyapps.com | fancyapps.com/fancybox/#license */
|
2
|
-
(function(s,H,f,w){var K=f("html"),q=f(s),p=f(H),b=f.fancybox=function(){b.open.apply(this,arguments)},J=navigator.userAgent.match(/msie/i),C=null,t=H.createTouch!==w,u=function(a){return a&&a.hasOwnProperty&&a instanceof f},r=function(a){return a&&"string"===f.type(a)},F=function(a){return r(a)&&0<a.indexOf("%")},m=function(a,d){var e=parseInt(a,10)||0;d&&F(a)&&(e*=b.getViewport()[d]/100);return Math.ceil(e)},x=function(a,b){return m(a,b)+"px"};f.extend(b,{version:"2.1.5",defaults:{padding:15,margin:20,
|
3
|
-
width:800,height:600,minWidth:100,minHeight:100,maxWidth:9999,maxHeight:9999,pixelRatio:1,autoSize:!0,autoHeight:!1,autoWidth:!1,autoResize:!0,autoCenter:!t,fitToView:!0,aspectRatio:!1,topRatio:0.5,leftRatio:0.5,scrolling:"auto",wrapCSS:"",arrows:!0,closeBtn:!0,closeClick:!1,nextClick:!1,mouseWheel:!0,autoPlay:!1,playSpeed:3E3,preload:3,modal:!1,loop:!0,ajax:{dataType:"html",headers:{"X-fancyBox":!0}},iframe:{scrolling:"auto",preload:!0},swf:{wmode:"transparent",allowfullscreen:"true",allowscriptaccess:"always"},
|
4
|
-
keys:{next:{13:"left",34:"up",39:"left",40:"up"},prev:{8:"right",33:"down",37:"right",38:"down"},close:[27],play:[32],toggle:[70]},direction:{next:"left",prev:"right"},scrollOutside:!0,index:0,type:null,href:null,content:null,title:null,tpl:{wrap:'<div class="fancybox-wrap" tabIndex="-1"><div class="fancybox-skin"><div class="fancybox-outer"><div class="fancybox-inner"></div></div></div></div>',image:'<img class="fancybox-image" src="{href}" alt="" />',iframe:'<iframe id="fancybox-frame{rnd}" name="fancybox-frame{rnd}" class="fancybox-iframe" frameborder="0" vspace="0" hspace="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen'+
|
5
|
-
(J?' allowtransparency="true"':"")+"></iframe>",error:'<p class="fancybox-error">The requested content cannot be loaded.<br/>Please try again later.</p>',closeBtn:'<a title="Close" class="fancybox-item fancybox-close" href="javascript:;"></a>',next:'<a title="Next" class="fancybox-nav fancybox-next" href="javascript:;"><span></span></a>',prev:'<a title="Previous" class="fancybox-nav fancybox-prev" href="javascript:;"><span></span></a>'},openEffect:"fade",openSpeed:250,openEasing:"swing",openOpacity:!0,
|
6
|
-
openMethod:"zoomIn",closeEffect:"fade",closeSpeed:250,closeEasing:"swing",closeOpacity:!0,closeMethod:"zoomOut",nextEffect:"elastic",nextSpeed:250,nextEasing:"swing",nextMethod:"changeIn",prevEffect:"elastic",prevSpeed:250,prevEasing:"swing",prevMethod:"changeOut",helpers:{overlay:!0,title:!0},onCancel:f.noop,beforeLoad:f.noop,afterLoad:f.noop,beforeShow:f.noop,afterShow:f.noop,beforeChange:f.noop,beforeClose:f.noop,afterClose:f.noop},group:{},opts:{},previous:null,coming:null,current:null,isActive:!1,
|
7
|
-
isOpen:!1,isOpened:!1,wrap:null,skin:null,outer:null,inner:null,player:{timer:null,isActive:!1},ajaxLoad:null,imgPreload:null,transitions:{},helpers:{},open:function(a,d){if(a&&(f.isPlainObject(d)||(d={}),!1!==b.close(!0)))return f.isArray(a)||(a=u(a)?f(a).get():[a]),f.each(a,function(e,c){var l={},g,h,k,n,m;"object"===f.type(c)&&(c.nodeType&&(c=f(c)),u(c)?(l={href:c.data("fancybox-href")||c.attr("href"),title:f("<div/>").text(c.data("fancybox-title")||c.attr("title")).html(),isDom:!0,element:c},
|
8
|
-
f.metadata&&f.extend(!0,l,c.metadata())):l=c);g=d.href||l.href||(r(c)?c:null);h=d.title!==w?d.title:l.title||"";n=(k=d.content||l.content)?"html":d.type||l.type;!n&&l.isDom&&(n=c.data("fancybox-type"),n||(n=(n=c.prop("class").match(/fancybox\.(\w+)/))?n[1]:null));r(g)&&(n||(b.isImage(g)?n="image":b.isSWF(g)?n="swf":"#"===g.charAt(0)?n="inline":r(c)&&(n="html",k=c)),"ajax"===n&&(m=g.split(/\s+/,2),g=m.shift(),m=m.shift()));k||("inline"===n?g?k=f(r(g)?g.replace(/.*(?=#[^\s]+$)/,""):g):l.isDom&&(k=c):
|
9
|
-
"html"===n?k=g:n||g||!l.isDom||(n="inline",k=c));f.extend(l,{href:g,type:n,content:k,title:h,selector:m});a[e]=l}),b.opts=f.extend(!0,{},b.defaults,d),d.keys!==w&&(b.opts.keys=d.keys?f.extend({},b.defaults.keys,d.keys):!1),b.group=a,b._start(b.opts.index)},cancel:function(){var a=b.coming;a&&!1===b.trigger("onCancel")||(b.hideLoading(),a&&(b.ajaxLoad&&b.ajaxLoad.abort(),b.ajaxLoad=null,b.imgPreload&&(b.imgPreload.onload=b.imgPreload.onerror=null),a.wrap&&a.wrap.stop(!0,!0).trigger("onReset").remove(),
|
10
|
-
b.coming=null,b.current||b._afterZoomOut(a)))},close:function(a){b.cancel();!1!==b.trigger("beforeClose")&&(b.unbindEvents(),b.isActive&&(b.isOpen&&!0!==a?(b.isOpen=b.isOpened=!1,b.isClosing=!0,f(".fancybox-item, .fancybox-nav").remove(),b.wrap.stop(!0,!0).removeClass("fancybox-opened"),b.transitions[b.current.closeMethod]()):(f(".fancybox-wrap").stop(!0).trigger("onReset").remove(),b._afterZoomOut())))},play:function(a){var d=function(){clearTimeout(b.player.timer)},e=function(){d();b.current&&b.player.isActive&&
|
11
|
-
(b.player.timer=setTimeout(b.next,b.current.playSpeed))},c=function(){d();p.unbind(".player");b.player.isActive=!1;b.trigger("onPlayEnd")};!0===a||!b.player.isActive&&!1!==a?b.current&&(b.current.loop||b.current.index<b.group.length-1)&&(b.player.isActive=!0,p.bind({"onCancel.player beforeClose.player":c,"onUpdate.player":e,"beforeLoad.player":d}),e(),b.trigger("onPlayStart")):c()},next:function(a){var d=b.current;d&&(r(a)||(a=d.direction.next),b.jumpto(d.index+1,a,"next"))},prev:function(a){var d=
|
12
|
-
b.current;d&&(r(a)||(a=d.direction.prev),b.jumpto(d.index-1,a,"prev"))},jumpto:function(a,d,e){var c=b.current;c&&(a=m(a),b.direction=d||c.direction[a>=c.index?"next":"prev"],b.router=e||"jumpto",c.loop&&(0>a&&(a=c.group.length+a%c.group.length),a%=c.group.length),c.group[a]!==w&&(b.cancel(),b._start(a)))},reposition:function(a,d){var e=b.current,c=e?e.wrap:null,l;c&&(l=b._getPosition(d),a&&"scroll"===a.type?(delete l.position,c.stop(!0,!0).animate(l,200)):(c.css(l),e.pos=f.extend({},e.dim,l)))},
|
13
|
-
update:function(a){var d=a&&a.originalEvent&&a.originalEvent.type,e=!d||"orientationchange"===d;e&&(clearTimeout(C),C=null);b.isOpen&&!C&&(C=setTimeout(function(){var c=b.current;c&&!b.isClosing&&(b.wrap.removeClass("fancybox-tmp"),(e||"load"===d||"resize"===d&&c.autoResize)&&b._setDimension(),"scroll"===d&&c.canShrink||b.reposition(a),b.trigger("onUpdate"),C=null)},e&&!t?0:300))},toggle:function(a){b.isOpen&&(b.current.fitToView="boolean"===f.type(a)?a:!b.current.fitToView,t&&(b.wrap.removeAttr("style").addClass("fancybox-tmp"),
|
14
|
-
b.trigger("onUpdate")),b.update())},hideLoading:function(){p.unbind(".loading");f("#fancybox-loading").remove()},showLoading:function(){var a,d;b.hideLoading();a=f('<div id="fancybox-loading"><div></div></div>').click(b.cancel).appendTo("body");p.bind("keydown.loading",function(a){27===(a.which||a.keyCode)&&(a.preventDefault(),b.cancel())});b.defaults.fixed||(d=b.getViewport(),a.css({position:"absolute",top:0.5*d.h+d.y,left:0.5*d.w+d.x}));b.trigger("onLoading")},getViewport:function(){var a=b.current&&
|
15
|
-
b.current.locked||!1,d={x:q.scrollLeft(),y:q.scrollTop()};a&&a.length?(d.w=a[0].clientWidth,d.h=a[0].clientHeight):(d.w=t&&s.innerWidth?s.innerWidth:q.width(),d.h=t&&s.innerHeight?s.innerHeight:q.height());return d},unbindEvents:function(){b.wrap&&u(b.wrap)&&b.wrap.unbind(".fb");p.unbind(".fb");q.unbind(".fb")},bindEvents:function(){var a=b.current,d;a&&(q.bind("orientationchange.fb"+(t?"":" resize.fb")+(a.autoCenter&&!a.locked?" scroll.fb":""),b.update),(d=a.keys)&&p.bind("keydown.fb",function(e){var c=
|
16
|
-
e.which||e.keyCode,l=e.target||e.srcElement;if(27===c&&b.coming)return!1;e.ctrlKey||e.altKey||e.shiftKey||e.metaKey||l&&(l.type||f(l).is("[contenteditable]"))||f.each(d,function(d,l){if(1<a.group.length&&l[c]!==w)return b[d](l[c]),e.preventDefault(),!1;if(-1<f.inArray(c,l))return b[d](),e.preventDefault(),!1})}),f.fn.mousewheel&&a.mouseWheel&&b.wrap.bind("mousewheel.fb",function(d,c,l,g){for(var h=f(d.target||null),k=!1;h.length&&!(k||h.is(".fancybox-skin")||h.is(".fancybox-wrap"));)k=h[0]&&!(h[0].style.overflow&&
|
17
|
-
"hidden"===h[0].style.overflow)&&(h[0].clientWidth&&h[0].scrollWidth>h[0].clientWidth||h[0].clientHeight&&h[0].scrollHeight>h[0].clientHeight),h=f(h).parent();0!==c&&!k&&1<b.group.length&&!a.canShrink&&(0<g||0<l?b.prev(0<g?"down":"left"):(0>g||0>l)&&b.next(0>g?"up":"right"),d.preventDefault())}))},trigger:function(a,d){var e,c=d||b.coming||b.current;if(c){f.isFunction(c[a])&&(e=c[a].apply(c,Array.prototype.slice.call(arguments,1)));if(!1===e)return!1;c.helpers&&f.each(c.helpers,function(d,e){if(e&&
|
18
|
-
b.helpers[d]&&f.isFunction(b.helpers[d][a]))b.helpers[d][a](f.extend(!0,{},b.helpers[d].defaults,e),c)})}p.trigger(a)},isImage:function(a){return r(a)&&a.match(/(^data:image\/.*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg)((\?|#).*)?$)/i)},isSWF:function(a){return r(a)&&a.match(/\.(swf)((\?|#).*)?$/i)},_start:function(a){var d={},e,c;a=m(a);e=b.group[a]||null;if(!e)return!1;d=f.extend(!0,{},b.opts,e);e=d.margin;c=d.padding;"number"===f.type(e)&&(d.margin=[e,e,e,e]);"number"===f.type(c)&&(d.padding=[c,c,
|
19
|
-
c,c]);d.modal&&f.extend(!0,d,{closeBtn:!1,closeClick:!1,nextClick:!1,arrows:!1,mouseWheel:!1,keys:null,helpers:{overlay:{closeClick:!1}}});d.autoSize&&(d.autoWidth=d.autoHeight=!0);"auto"===d.width&&(d.autoWidth=!0);"auto"===d.height&&(d.autoHeight=!0);d.group=b.group;d.index=a;b.coming=d;if(!1===b.trigger("beforeLoad"))b.coming=null;else{c=d.type;e=d.href;if(!c)return b.coming=null,b.current&&b.router&&"jumpto"!==b.router?(b.current.index=a,b[b.router](b.direction)):!1;b.isActive=!0;if("image"===
|
20
|
-
c||"swf"===c)d.autoHeight=d.autoWidth=!1,d.scrolling="visible";"image"===c&&(d.aspectRatio=!0);"iframe"===c&&t&&(d.scrolling="scroll");d.wrap=f(d.tpl.wrap).addClass("fancybox-"+(t?"mobile":"desktop")+" fancybox-type-"+c+" fancybox-tmp "+d.wrapCSS).appendTo(d.parent||"body");f.extend(d,{skin:f(".fancybox-skin",d.wrap),outer:f(".fancybox-outer",d.wrap),inner:f(".fancybox-inner",d.wrap)});f.each(["Top","Right","Bottom","Left"],function(a,b){d.skin.css("padding"+b,x(d.padding[a]))});b.trigger("onReady");
|
21
|
-
if("inline"===c||"html"===c){if(!d.content||!d.content.length)return b._error("content")}else if(!e)return b._error("href");"image"===c?b._loadImage():"ajax"===c?b._loadAjax():"iframe"===c?b._loadIframe():b._afterLoad()}},_error:function(a){f.extend(b.coming,{type:"html",autoWidth:!0,autoHeight:!0,minWidth:0,minHeight:0,scrolling:"no",hasError:a,content:b.coming.tpl.error});b._afterLoad()},_loadImage:function(){var a=b.imgPreload=new Image;a.onload=function(){this.onload=this.onerror=null;b.coming.width=
|
22
|
-
this.width/b.opts.pixelRatio;b.coming.height=this.height/b.opts.pixelRatio;b._afterLoad()};a.onerror=function(){this.onload=this.onerror=null;b._error("image")};a.src=b.coming.href;!0!==a.complete&&b.showLoading()},_loadAjax:function(){var a=b.coming;b.showLoading();b.ajaxLoad=f.ajax(f.extend({},a.ajax,{url:a.href,error:function(a,e){b.coming&&"abort"!==e?b._error("ajax",a):b.hideLoading()},success:function(d,e){"success"===e&&(a.content=d,b._afterLoad())}}))},_loadIframe:function(){var a=b.coming,
|
23
|
-
d=f(a.tpl.iframe.replace(/\{rnd\}/g,(new Date).getTime())).attr("scrolling",t?"auto":a.iframe.scrolling).attr("src",a.href);f(a.wrap).bind("onReset",function(){try{f(this).find("iframe").hide().attr("src","//about:blank").end().empty()}catch(a){}});a.iframe.preload&&(b.showLoading(),d.one("load",function(){f(this).data("ready",1);t||f(this).bind("load.fb",b.update);f(this).parents(".fancybox-wrap").width("100%").removeClass("fancybox-tmp").show();b._afterLoad()}));a.content=d.appendTo(a.inner);a.iframe.preload||
|
24
|
-
b._afterLoad()},_preloadImages:function(){var a=b.group,d=b.current,e=a.length,c=d.preload?Math.min(d.preload,e-1):0,f,g;for(g=1;g<=c;g+=1)f=a[(d.index+g)%e],"image"===f.type&&f.href&&((new Image).src=f.href)},_afterLoad:function(){var a=b.coming,d=b.current,e,c,l,g,h;b.hideLoading();if(a&&!1!==b.isActive)if(!1===b.trigger("afterLoad",a,d))a.wrap.stop(!0).trigger("onReset").remove(),b.coming=null;else{d&&(b.trigger("beforeChange",d),d.wrap.stop(!0).removeClass("fancybox-opened").find(".fancybox-item, .fancybox-nav").remove());
|
25
|
-
b.unbindEvents();e=a.content;c=a.type;l=a.scrolling;f.extend(b,{wrap:a.wrap,skin:a.skin,outer:a.outer,inner:a.inner,current:a,previous:d});g=a.href;switch(c){case "inline":case "ajax":case "html":a.selector?e=f("<div>").html(e).find(a.selector):u(e)&&(e.data("fancybox-placeholder")||e.data("fancybox-placeholder",f('<div class="fancybox-placeholder"></div>').insertAfter(e).hide()),e=e.show().detach(),a.wrap.bind("onReset",function(){f(this).find(e).length&&e.hide().replaceAll(e.data("fancybox-placeholder")).data("fancybox-placeholder",
|
26
|
-
!1)}));break;case "image":e=a.tpl.image.replace(/\{href\}/g,g);break;case "swf":e='<object id="fancybox-swf" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="100%" height="100%"><param name="movie" value="'+g+'"></param>',h="",f.each(a.swf,function(a,b){e+='<param name="'+a+'" value="'+b+'"></param>';h+=" "+a+'="'+b+'"'}),e+='<embed src="'+g+'" type="application/x-shockwave-flash" width="100%" height="100%"'+h+"></embed></object>"}u(e)&&e.parent().is(a.inner)||a.inner.append(e);b.trigger("beforeShow");
|
27
|
-
a.inner.css("overflow","yes"===l?"scroll":"no"===l?"hidden":l);b._setDimension();b.reposition();b.isOpen=!1;b.coming=null;b.bindEvents();if(!b.isOpened)f(".fancybox-wrap").not(a.wrap).stop(!0).trigger("onReset").remove();else if(d.prevMethod)b.transitions[d.prevMethod]();b.transitions[b.isOpened?a.nextMethod:a.openMethod]();b._preloadImages()}},_setDimension:function(){var a=b.getViewport(),d=0,e=!1,c=!1,e=b.wrap,l=b.skin,g=b.inner,h=b.current,c=h.width,k=h.height,n=h.minWidth,v=h.minHeight,p=h.maxWidth,
|
28
|
-
q=h.maxHeight,t=h.scrolling,r=h.scrollOutside?h.scrollbarWidth:0,y=h.margin,z=m(y[1]+y[3]),s=m(y[0]+y[2]),w,A,u,D,B,G,C,E,I;e.add(l).add(g).width("auto").height("auto").removeClass("fancybox-tmp");y=m(l.outerWidth(!0)-l.width());w=m(l.outerHeight(!0)-l.height());A=z+y;u=s+w;D=F(c)?(a.w-A)*m(c)/100:c;B=F(k)?(a.h-u)*m(k)/100:k;if("iframe"===h.type){if(I=h.content,h.autoHeight&&1===I.data("ready"))try{I[0].contentWindow.document.location&&(g.width(D).height(9999),G=I.contents().find("body"),r&&G.css("overflow-x",
|
29
|
-
"hidden"),B=G.outerHeight(!0))}catch(H){}}else if(h.autoWidth||h.autoHeight)g.addClass("fancybox-tmp"),h.autoWidth||g.width(D),h.autoHeight||g.height(B),h.autoWidth&&(D=g.width()),h.autoHeight&&(B=g.height()),g.removeClass("fancybox-tmp");c=m(D);k=m(B);E=D/B;n=m(F(n)?m(n,"w")-A:n);p=m(F(p)?m(p,"w")-A:p);v=m(F(v)?m(v,"h")-u:v);q=m(F(q)?m(q,"h")-u:q);G=p;C=q;h.fitToView&&(p=Math.min(a.w-A,p),q=Math.min(a.h-u,q));A=a.w-z;s=a.h-s;h.aspectRatio?(c>p&&(c=p,k=m(c/E)),k>q&&(k=q,c=m(k*E)),c<n&&(c=n,k=m(c/
|
30
|
-
E)),k<v&&(k=v,c=m(k*E))):(c=Math.max(n,Math.min(c,p)),h.autoHeight&&"iframe"!==h.type&&(g.width(c),k=g.height()),k=Math.max(v,Math.min(k,q)));if(h.fitToView)if(g.width(c).height(k),e.width(c+y),a=e.width(),z=e.height(),h.aspectRatio)for(;(a>A||z>s)&&c>n&&k>v&&!(19<d++);)k=Math.max(v,Math.min(q,k-10)),c=m(k*E),c<n&&(c=n,k=m(c/E)),c>p&&(c=p,k=m(c/E)),g.width(c).height(k),e.width(c+y),a=e.width(),z=e.height();else c=Math.max(n,Math.min(c,c-(a-A))),k=Math.max(v,Math.min(k,k-(z-s)));r&&"auto"===t&&k<B&&
|
31
|
-
c+y+r<A&&(c+=r);g.width(c).height(k);e.width(c+y);a=e.width();z=e.height();e=(a>A||z>s)&&c>n&&k>v;c=h.aspectRatio?c<G&&k<C&&c<D&&k<B:(c<G||k<C)&&(c<D||k<B);f.extend(h,{dim:{width:x(a),height:x(z)},origWidth:D,origHeight:B,canShrink:e,canExpand:c,wPadding:y,hPadding:w,wrapSpace:z-l.outerHeight(!0),skinSpace:l.height()-k});!I&&h.autoHeight&&k>v&&k<q&&!c&&g.height("auto")},_getPosition:function(a){var d=b.current,e=b.getViewport(),c=d.margin,f=b.wrap.width()+c[1]+c[3],g=b.wrap.height()+c[0]+c[2],c={position:"absolute",
|
32
|
-
top:c[0],left:c[3]};d.autoCenter&&d.fixed&&!a&&g<=e.h&&f<=e.w?c.position="fixed":d.locked||(c.top+=e.y,c.left+=e.x);c.top=x(Math.max(c.top,c.top+(e.h-g)*d.topRatio));c.left=x(Math.max(c.left,c.left+(e.w-f)*d.leftRatio));return c},_afterZoomIn:function(){var a=b.current;a&&((b.isOpen=b.isOpened=!0,b.wrap.css("overflow","visible").addClass("fancybox-opened"),b.update(),(a.closeClick||a.nextClick&&1<b.group.length)&&b.inner.css("cursor","pointer").bind("click.fb",function(d){f(d.target).is("a")||f(d.target).parent().is("a")||
|
33
|
-
(d.preventDefault(),b[a.closeClick?"close":"next"]())}),a.closeBtn&&f(a.tpl.closeBtn).appendTo(b.skin).bind("click.fb",function(a){a.preventDefault();b.close()}),a.arrows&&1<b.group.length&&((a.loop||0<a.index)&&f(a.tpl.prev).appendTo(b.outer).bind("click.fb",b.prev),(a.loop||a.index<b.group.length-1)&&f(a.tpl.next).appendTo(b.outer).bind("click.fb",b.next)),b.trigger("afterShow"),a.loop||a.index!==a.group.length-1)?b.opts.autoPlay&&!b.player.isActive&&(b.opts.autoPlay=!1,b.play(!0)):b.play(!1))},
|
34
|
-
_afterZoomOut:function(a){a=a||b.current;f(".fancybox-wrap").trigger("onReset").remove();f.extend(b,{group:{},opts:{},router:!1,current:null,isActive:!1,isOpened:!1,isOpen:!1,isClosing:!1,wrap:null,skin:null,outer:null,inner:null});b.trigger("afterClose",a)}});b.transitions={getOrigPosition:function(){var a=b.current,d=a.element,e=a.orig,c={},f=50,g=50,h=a.hPadding,k=a.wPadding,n=b.getViewport();!e&&a.isDom&&d.is(":visible")&&(e=d.find("img:first"),e.length||(e=d));u(e)?(c=e.offset(),e.is("img")&&
|
35
|
-
(f=e.outerWidth(),g=e.outerHeight())):(c.top=n.y+(n.h-g)*a.topRatio,c.left=n.x+(n.w-f)*a.leftRatio);if("fixed"===b.wrap.css("position")||a.locked)c.top-=n.y,c.left-=n.x;return c={top:x(c.top-h*a.topRatio),left:x(c.left-k*a.leftRatio),width:x(f+k),height:x(g+h)}},step:function(a,d){var e,c,f=d.prop;c=b.current;var g=c.wrapSpace,h=c.skinSpace;if("width"===f||"height"===f)e=d.end===d.start?1:(a-d.start)/(d.end-d.start),b.isClosing&&(e=1-e),c="width"===f?c.wPadding:c.hPadding,c=a-c,b.skin[f](m("width"===
|
36
|
-
f?c:c-g*e)),b.inner[f](m("width"===f?c:c-g*e-h*e))},zoomIn:function(){var a=b.current,d=a.pos,e=a.openEffect,c="elastic"===e,l=f.extend({opacity:1},d);delete l.position;c?(d=this.getOrigPosition(),a.openOpacity&&(d.opacity=0.1)):"fade"===e&&(d.opacity=0.1);b.wrap.css(d).animate(l,{duration:"none"===e?0:a.openSpeed,easing:a.openEasing,step:c?this.step:null,complete:b._afterZoomIn})},zoomOut:function(){var a=b.current,d=a.closeEffect,e="elastic"===d,c={opacity:0.1};e&&(c=this.getOrigPosition(),a.closeOpacity&&
|
37
|
-
(c.opacity=0.1));b.wrap.animate(c,{duration:"none"===d?0:a.closeSpeed,easing:a.closeEasing,step:e?this.step:null,complete:b._afterZoomOut})},changeIn:function(){var a=b.current,d=a.nextEffect,e=a.pos,c={opacity:1},f=b.direction,g;e.opacity=0.1;"elastic"===d&&(g="down"===f||"up"===f?"top":"left","down"===f||"right"===f?(e[g]=x(m(e[g])-200),c[g]="+=200px"):(e[g]=x(m(e[g])+200),c[g]="-=200px"));"none"===d?b._afterZoomIn():b.wrap.css(e).animate(c,{duration:a.nextSpeed,easing:a.nextEasing,complete:b._afterZoomIn})},
|
38
|
-
changeOut:function(){var a=b.previous,d=a.prevEffect,e={opacity:0.1},c=b.direction;"elastic"===d&&(e["down"===c||"up"===c?"top":"left"]=("up"===c||"left"===c?"-":"+")+"=200px");a.wrap.animate(e,{duration:"none"===d?0:a.prevSpeed,easing:a.prevEasing,complete:function(){f(this).trigger("onReset").remove()}})}};b.helpers.overlay={defaults:{closeClick:!0,speedOut:200,showEarly:!0,css:{},locked:!t,fixed:!0},overlay:null,fixed:!1,el:f("html"),create:function(a){var d;a=f.extend({},this.defaults,a);this.overlay&&
|
39
|
-
this.close();d=b.coming?b.coming.parent:a.parent;this.overlay=f('<div class="fancybox-overlay"></div>').appendTo(d&&d.lenth?d:"body");this.fixed=!1;a.fixed&&b.defaults.fixed&&(this.overlay.addClass("fancybox-overlay-fixed"),this.fixed=!0)},open:function(a){var d=this;a=f.extend({},this.defaults,a);this.overlay?this.overlay.unbind(".overlay").width("auto").height("auto"):this.create(a);this.fixed||(q.bind("resize.overlay",f.proxy(this.update,this)),this.update());a.closeClick&&this.overlay.bind("click.overlay",
|
40
|
-
function(a){if(f(a.target).hasClass("fancybox-overlay"))return b.isActive?b.close():d.close(),!1});this.overlay.css(a.css).show()},close:function(){q.unbind("resize.overlay");this.el.hasClass("fancybox-lock")&&(f(".fancybox-margin").removeClass("fancybox-margin"),this.el.removeClass("fancybox-lock"),q.scrollTop(this.scrollV).scrollLeft(this.scrollH));f(".fancybox-overlay").remove().hide();f.extend(this,{overlay:null,fixed:!1})},update:function(){var a="100%",b;this.overlay.width(a).height("100%");
|
41
|
-
J?(b=Math.max(H.documentElement.offsetWidth,H.body.offsetWidth),p.width()>b&&(a=p.width())):p.width()>q.width()&&(a=p.width());this.overlay.width(a).height(p.height())},onReady:function(a,b){var e=this.overlay;f(".fancybox-overlay").stop(!0,!0);e||this.create(a);a.locked&&this.fixed&&b.fixed&&(b.locked=this.overlay.append(b.wrap),b.fixed=!1);!0===a.showEarly&&this.beforeShow.apply(this,arguments)},beforeShow:function(a,b){b.locked&&!this.el.hasClass("fancybox-lock")&&(!1!==this.fixPosition&&f("*").filter(function(){return"fixed"===
|
42
|
-
f(this).css("position")&&!f(this).hasClass("fancybox-overlay")&&!f(this).hasClass("fancybox-wrap")}).addClass("fancybox-margin"),this.el.addClass("fancybox-margin"),this.scrollV=q.scrollTop(),this.scrollH=q.scrollLeft(),this.el.addClass("fancybox-lock"),q.scrollTop(this.scrollV).scrollLeft(this.scrollH));this.open(a)},onUpdate:function(){this.fixed||this.update()},afterClose:function(a){this.overlay&&!b.coming&&this.overlay.fadeOut(a.speedOut,f.proxy(this.close,this))}};b.helpers.title={defaults:{type:"float",
|
43
|
-
position:"bottom"},beforeShow:function(a){var d=b.current,e=d.title,c=a.type;f.isFunction(e)&&(e=e.call(d.element,d));if(r(e)&&""!==f.trim(e)){d=f('<div class="fancybox-title fancybox-title-'+c+'-wrap">'+e+"</div>");switch(c){case "inside":c=b.skin;break;case "outside":c=b.wrap;break;case "over":c=b.inner;break;default:c=b.skin,d.appendTo("body"),J&&d.width(d.width()),d.wrapInner('<span class="child"></span>'),b.current.margin[2]+=Math.abs(m(d.css("margin-bottom")))}d["top"===a.position?"prependTo":
|
44
|
-
"appendTo"](c)}}};f.fn.fancybox=function(a){var d,e=f(this),c=this.selector||"",l=function(g){var h=f(this).blur(),k=d,l,m;g.ctrlKey||g.altKey||g.shiftKey||g.metaKey||h.is(".fancybox-wrap")||(l=a.groupAttr||"data-fancybox-group",m=h.attr(l),m||(l="rel",m=h.get(0)[l]),m&&""!==m&&"nofollow"!==m&&(h=c.length?f(c):e,h=h.filter("["+l+'="'+m+'"]'),k=h.index(this)),a.index=k,!1!==b.open(h,a)&&g.preventDefault())};a=a||{};d=a.index||0;c&&!1!==a.live?p.undelegate(c,"click.fb-start").delegate(c+":not('.fancybox-item, .fancybox-nav')",
|
45
|
-
"click.fb-start",l):e.unbind("click.fb-start").bind("click.fb-start",l);this.filter("[data-fancybox-start=1]").trigger("click");return this};p.ready(function(){var a,d;f.scrollbarWidth===w&&(f.scrollbarWidth=function(){var a=f('<div style="width:50px;height:50px;overflow:auto"><div/></div>').appendTo("body"),b=a.children(),b=b.innerWidth()-b.height(99).innerWidth();a.remove();return b});f.support.fixedPosition===w&&(f.support.fixedPosition=function(){var a=f('<div style="position:fixed;top:20px;"></div>').appendTo("body"),
|
46
|
-
b=20===a[0].offsetTop||15===a[0].offsetTop;a.remove();return b}());f.extend(b.defaults,{scrollbarWidth:f.scrollbarWidth(),fixed:f.support.fixedPosition,parent:f("body")});a=f(s).width();K.addClass("fancybox-lock-test");d=f(s).width();K.removeClass("fancybox-lock-test");f("<style type='text/css'>.fancybox-margin{margin-right:"+(d-a)+"px;}</style>").appendTo("head")})})(window,document,jQuery);
|
@@ -1,5 +0,0 @@
|
|
1
|
-
/*! jQuery v1.12.3 | (c) jQuery Foundation | jquery.org/license */
|
2
|
-
!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=a.document,e=c.slice,f=c.concat,g=c.push,h=c.indexOf,i={},j=i.toString,k=i.hasOwnProperty,l={},m="1.12.3",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return e.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:e.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a){return n.each(this,a)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(e.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor()},push:g,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(e=arguments[h]))for(d in e)a=g[d],c=e[d],g!==c&&(j&&c&&(n.isPlainObject(c)||(b=n.isArray(c)))?(b?(b=!1,f=a&&n.isArray(a)?a:[]):f=a&&n.isPlainObject(a)?a:{},g[d]=n.extend(j,f,c)):void 0!==c&&(g[d]=c));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray||function(a){return"array"===n.type(a)},isWindow:function(a){return null!=a&&a==a.window},isNumeric:function(a){var b=a&&a.toString();return!n.isArray(a)&&b-parseFloat(b)+1>=0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},isPlainObject:function(a){var b;if(!a||"object"!==n.type(a)||a.nodeType||n.isWindow(a))return!1;try{if(a.constructor&&!k.call(a,"constructor")&&!k.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}if(!l.ownFirst)for(b in a)return k.call(a,b);for(b in a);return void 0===b||k.call(a,b)},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?i[j.call(a)]||"object":typeof a},globalEval:function(b){b&&n.trim(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b){var c,d=0;if(s(a)){for(c=a.length;c>d;d++)if(b.call(a[d],d,a[d])===!1)break}else for(d in a)if(b.call(a[d],d,a[d])===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):g.call(c,a)),c},inArray:function(a,b,c){var d;if(b){if(h)return h.call(b,a,c);for(d=b.length,c=c?0>c?Math.max(0,d+c):c:0;d>c;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,b){var c=+b.length,d=0,e=a.length;while(c>d)a[e++]=b[d++];if(c!==c)while(void 0!==b[d])a[e++]=b[d++];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,e,g=0,h=[];if(s(a))for(d=a.length;d>g;g++)e=b(a[g],g,c),null!=e&&h.push(e);else for(g in a)e=b(a[g],g,c),null!=e&&h.push(e);return f.apply([],h)},guid:1,proxy:function(a,b){var c,d,f;return"string"==typeof b&&(f=a[b],b=a,a=f),n.isFunction(a)?(c=e.call(arguments,2),d=function(){return a.apply(b||this,c.concat(e.call(arguments)))},d.guid=a.guid=a.guid||n.guid++,d):void 0},now:function(){return+new Date},support:l}),"function"==typeof Symbol&&(n.fn[Symbol.iterator]=c[Symbol.iterator]),n.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(a,b){i["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=!!a&&"length"in a&&a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+1*new Date,v=a.document,w=0,x=0,y=ga(),z=ga(),A=ga(),B=function(a,b){return a===b&&(l=!0),0},C=1<<31,D={}.hasOwnProperty,E=[],F=E.pop,G=E.push,H=E.push,I=E.slice,J=function(a,b){for(var c=0,d=a.length;d>c;c++)if(a[c]===b)return c;return-1},K="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",L="[\\x20\\t\\r\\n\\f]",M="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",N="\\["+L+"*("+M+")(?:"+L+"*([*^$|!~]?=)"+L+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+M+"))|)"+L+"*\\]",O=":("+M+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+N+")*)|.*)\\)|)",P=new RegExp(L+"+","g"),Q=new RegExp("^"+L+"+|((?:^|[^\\\\])(?:\\\\.)*)"+L+"+$","g"),R=new RegExp("^"+L+"*,"+L+"*"),S=new RegExp("^"+L+"*([>+~]|"+L+")"+L+"*"),T=new RegExp("="+L+"*([^\\]'\"]*?)"+L+"*\\]","g"),U=new RegExp(O),V=new RegExp("^"+M+"$"),W={ID:new RegExp("^#("+M+")"),CLASS:new RegExp("^\\.("+M+")"),TAG:new RegExp("^("+M+"|[*])"),ATTR:new RegExp("^"+N),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+K+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},X=/^(?:input|select|textarea|button)$/i,Y=/^h\d$/i,Z=/^[^{]+\{\s*\[native \w/,$=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,_=/[+~]/,aa=/'|\\/g,ba=new RegExp("\\\\([\\da-f]{1,6}"+L+"?|("+L+")|.)","ig"),ca=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)},da=function(){m()};try{H.apply(E=I.call(v.childNodes),v.childNodes),E[v.childNodes.length].nodeType}catch(ea){H={apply:E.length?function(a,b){G.apply(a,I.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fa(a,b,d,e){var f,h,j,k,l,o,r,s,w=b&&b.ownerDocument,x=b?b.nodeType:9;if(d=d||[],"string"!=typeof a||!a||1!==x&&9!==x&&11!==x)return d;if(!e&&((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,p)){if(11!==x&&(o=$.exec(a)))if(f=o[1]){if(9===x){if(!(j=b.getElementById(f)))return d;if(j.id===f)return d.push(j),d}else if(w&&(j=w.getElementById(f))&&t(b,j)&&j.id===f)return d.push(j),d}else{if(o[2])return H.apply(d,b.getElementsByTagName(a)),d;if((f=o[3])&&c.getElementsByClassName&&b.getElementsByClassName)return H.apply(d,b.getElementsByClassName(f)),d}if(c.qsa&&!A[a+" "]&&(!q||!q.test(a))){if(1!==x)w=b,s=a;else if("object"!==b.nodeName.toLowerCase()){(k=b.getAttribute("id"))?k=k.replace(aa,"\\$&"):b.setAttribute("id",k=u),r=g(a),h=r.length,l=V.test(k)?"#"+k:"[id='"+k+"']";while(h--)r[h]=l+" "+qa(r[h]);s=r.join(","),w=_.test(a)&&oa(b.parentNode)||b}if(s)try{return H.apply(d,w.querySelectorAll(s)),d}catch(y){}finally{k===u&&b.removeAttribute("id")}}}return i(a.replace(Q,"$1"),b,d,e)}function ga(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function ha(a){return a[u]=!0,a}function ia(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function ja(a,b){var c=a.split("|"),e=c.length;while(e--)d.attrHandle[c[e]]=b}function ka(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||C)-(~a.sourceIndex||C);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function la(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function ma(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function na(a){return ha(function(b){return b=+b,ha(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function oa(a){return a&&"undefined"!=typeof a.getElementsByTagName&&a}c=fa.support={},f=fa.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fa.setDocument=function(a){var b,e,g=a?a.ownerDocument||a:v;return g!==n&&9===g.nodeType&&g.documentElement?(n=g,o=n.documentElement,p=!f(n),(e=n.defaultView)&&e.top!==e&&(e.addEventListener?e.addEventListener("unload",da,!1):e.attachEvent&&e.attachEvent("onunload",da)),c.attributes=ia(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ia(function(a){return a.appendChild(n.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Z.test(n.getElementsByClassName),c.getById=ia(function(a){return o.appendChild(a).id=u,!n.getElementsByName||!n.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c=b.getElementById(a);return c?[c]:[]}},d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){var c="undefined"!=typeof a.getAttributeNode&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return"undefined"!=typeof b.getElementsByTagName?b.getElementsByTagName(a):c.qsa?b.querySelectorAll(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return"undefined"!=typeof b.getElementsByClassName&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=Z.test(n.querySelectorAll))&&(ia(function(a){o.appendChild(a).innerHTML="<a id='"+u+"'></a><select id='"+u+"-\r\\' msallowcapture=''><option selected=''></option></select>",a.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+L+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+L+"*(?:value|"+K+")"),a.querySelectorAll("[id~="+u+"-]").length||q.push("~="),a.querySelectorAll(":checked").length||q.push(":checked"),a.querySelectorAll("a#"+u+"+*").length||q.push(".#.+[+~]")}),ia(function(a){var b=n.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+L+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=Z.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ia(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",O)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=Z.test(o.compareDocumentPosition),t=b||Z.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===n||a.ownerDocument===v&&t(v,a)?-1:b===n||b.ownerDocument===v&&t(v,b)?1:k?J(k,a)-J(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,e=a.parentNode,f=b.parentNode,g=[a],h=[b];if(!e||!f)return a===n?-1:b===n?1:e?-1:f?1:k?J(k,a)-J(k,b):0;if(e===f)return ka(a,b);c=a;while(c=c.parentNode)g.unshift(c);c=b;while(c=c.parentNode)h.unshift(c);while(g[d]===h[d])d++;return d?ka(g[d],h[d]):g[d]===v?-1:h[d]===v?1:0},n):n},fa.matches=function(a,b){return fa(a,null,null,b)},fa.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(T,"='$1']"),c.matchesSelector&&p&&!A[b+" "]&&(!r||!r.test(b))&&(!q||!q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fa(b,n,null,[a]).length>0},fa.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fa.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&D.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fa.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fa.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fa.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fa.selectors={cacheLength:50,createPseudo:ha,match:W,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ba,ca),a[3]=(a[3]||a[4]||a[5]||"").replace(ba,ca),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fa.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fa.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return W.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&U.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(ba,ca).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+L+")"+a+"("+L+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||"undefined"!=typeof a.getAttribute&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fa.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e.replace(P," ")+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h,t=!1;if(q){if(f){while(p){m=b;while(m=m[p])if(h?m.nodeName.toLowerCase()===r:1===m.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){m=q,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n&&j[2],m=n&&q.childNodes[n];while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if(1===m.nodeType&&++t&&m===b){k[a]=[w,n,t];break}}else if(s&&(m=b,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n),t===!1)while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if((h?m.nodeName.toLowerCase()===r:1===m.nodeType)&&++t&&(s&&(l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),k[a]=[w,t]),m===b))break;return t-=e,t===d||t%d===0&&t/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fa.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?ha(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=J(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:ha(function(a){var b=[],c=[],d=h(a.replace(Q,"$1"));return d[u]?ha(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),b[0]=null,!c.pop()}}),has:ha(function(a){return function(b){return fa(a,b).length>0}}),contains:ha(function(a){return a=a.replace(ba,ca),function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:ha(function(a){return V.test(a||"")||fa.error("unsupported lang: "+a),a=a.replace(ba,ca).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Y.test(a.nodeName)},input:function(a){return X.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:na(function(){return[0]}),last:na(function(a,b){return[b-1]}),eq:na(function(a,b,c){return[0>c?c+b:c]}),even:na(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:na(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:na(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:na(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=la(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=ma(b);function pa(){}pa.prototype=d.filters=d.pseudos,d.setFilters=new pa,g=fa.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){c&&!(e=R.exec(h))||(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=S.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(Q," ")}),h=h.slice(c.length));for(g in d.filter)!(e=W[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?fa.error(a):z(a,i).slice(0)};function qa(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function ra(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j,k=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(j=b[u]||(b[u]={}),i=j[b.uniqueID]||(j[b.uniqueID]={}),(h=i[d])&&h[0]===w&&h[1]===f)return k[2]=h[2];if(i[d]=k,k[2]=a(b,c,g))return!0}}}function sa(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function ta(a,b,c){for(var d=0,e=b.length;e>d;d++)fa(a,b[d],c);return c}function ua(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(c&&!c(f,d,e)||(g.push(f),j&&b.push(h)));return g}function va(a,b,c,d,e,f){return d&&!d[u]&&(d=va(d)),e&&!e[u]&&(e=va(e,f)),ha(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||ta(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ua(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ua(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?J(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ua(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):H.apply(g,r)})}function wa(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=ra(function(a){return a===b},h,!0),l=ra(function(a){return J(b,a)>-1},h,!0),m=[function(a,c,d){var e=!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d));return b=null,e}];f>i;i++)if(c=d.relative[a[i].type])m=[ra(sa(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return va(i>1&&sa(m),i>1&&qa(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(Q,"$1"),c,e>i&&wa(a.slice(i,e)),f>e&&wa(a=a.slice(e)),f>e&&qa(a))}m.push(c)}return sa(m)}function xa(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,o,q,r=0,s="0",t=f&&[],u=[],v=j,x=f||e&&d.find.TAG("*",k),y=w+=null==v?1:Math.random()||.1,z=x.length;for(k&&(j=g===n||g||k);s!==z&&null!=(l=x[s]);s++){if(e&&l){o=0,g||l.ownerDocument===n||(m(l),h=!p);while(q=a[o++])if(q(l,g||n,h)){i.push(l);break}k&&(w=y)}c&&((l=!q&&l)&&r--,f&&t.push(l))}if(r+=s,c&&s!==r){o=0;while(q=b[o++])q(t,u,g,h);if(f){if(r>0)while(s--)t[s]||u[s]||(u[s]=F.call(i));u=ua(u)}H.apply(i,u),k&&!f&&u.length>0&&r+b.length>1&&fa.uniqueSort(i)}return k&&(w=y,j=v),t};return c?ha(f):f}return h=fa.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wa(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xa(e,d)),f.selector=a}return f},i=fa.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(ba,ca),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=W.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(ba,ca),_.test(j[0].type)&&oa(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qa(j),!a)return H.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,!b||_.test(a)&&oa(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ia(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ia(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||ja("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ia(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||ja("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ia(function(a){return null==a.getAttribute("disabled")})||ja(K,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fa}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.uniqueSort=n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},v=function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c},w=n.expr.match.needsContext,x=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,y=/^.[^:#\[\.,]*$/;function z(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(y.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return n.inArray(a,b)>-1!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=[],d=this,e=d.length;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;e>b;b++)if(n.contains(d[b],this))return!0}));for(b=0;e>b;b++)n.find(a,d[b],c);return c=this.pushStack(e>1?n.unique(c):c),c.selector=this.selector?this.selector+" "+a:a,c},filter:function(a){return this.pushStack(z(this,a||[],!1))},not:function(a){return this.pushStack(z(this,a||[],!0))},is:function(a){return!!z(this,"string"==typeof a&&w.test(a)?n(a):a||[],!1).length}});var A,B=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,C=n.fn.init=function(a,b,c){var e,f;if(!a)return this;if(c=c||A,"string"==typeof a){if(e="<"===a.charAt(0)&&">"===a.charAt(a.length-1)&&a.length>=3?[null,a,null]:B.exec(a),!e||!e[1]&&b)return!b||b.jquery?(b||c).find(a):this.constructor(b).find(a);if(e[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(e[1],b&&b.nodeType?b.ownerDocument||b:d,!0)),x.test(e[1])&&n.isPlainObject(b))for(e in b)n.isFunction(this[e])?this[e](b[e]):this.attr(e,b[e]);return this}if(f=d.getElementById(e[2]),f&&f.parentNode){if(f.id!==e[2])return A.find(a);this.length=1,this[0]=f}return this.context=d,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof c.ready?c.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};C.prototype=n.fn,A=n(d);var D=/^(?:parents|prev(?:Until|All))/,E={children:!0,contents:!0,next:!0,prev:!0};n.fn.extend({has:function(a){var b,c=n(a,this),d=c.length;return this.filter(function(){for(b=0;d>b;b++)if(n.contains(this,c[b]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=w.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.uniqueSort(f):f)},index:function(a){return a?"string"==typeof a?n.inArray(this[0],n(a)):n.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.uniqueSort(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function F(a,b){do a=a[b];while(a&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return u(a,"parentNode")},parentsUntil:function(a,b,c){return u(a,"parentNode",c)},next:function(a){return F(a,"nextSibling")},prev:function(a){return F(a,"previousSibling")},nextAll:function(a){return u(a,"nextSibling")},prevAll:function(a){return u(a,"previousSibling")},nextUntil:function(a,b,c){return u(a,"nextSibling",c)},prevUntil:function(a,b,c){return u(a,"previousSibling",c)},siblings:function(a){return v((a.parentNode||{}).firstChild,a)},children:function(a){return v(a.firstChild)},contents:function(a){return n.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(E[a]||(e=n.uniqueSort(e)),D.test(a)&&(e=e.reverse())),this.pushStack(e)}});var G=/\S+/g;function H(a){var b={};return n.each(a.match(G)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?H(a):n.extend({},a);var b,c,d,e,f=[],g=[],h=-1,i=function(){for(e=a.once,d=b=!0;g.length;h=-1){c=g.shift();while(++h<f.length)f[h].apply(c[0],c[1])===!1&&a.stopOnFalse&&(h=f.length,c=!1)}a.memory||(c=!1),b=!1,e&&(f=c?[]:"")},j={add:function(){return f&&(c&&!b&&(h=f.length-1,g.push(c)),function d(b){n.each(b,function(b,c){n.isFunction(c)?a.unique&&j.has(c)||f.push(c):c&&c.length&&"string"!==n.type(c)&&d(c)})}(arguments),c&&!b&&i()),this},remove:function(){return n.each(arguments,function(a,b){var c;while((c=n.inArray(b,f,c))>-1)f.splice(c,1),h>=c&&h--}),this},has:function(a){return a?n.inArray(a,f)>-1:f.length>0},empty:function(){return f&&(f=[]),this},disable:function(){return e=g=[],f=c="",this},disabled:function(){return!f},lock:function(){return e=!0,c||j.disable(),this},locked:function(){return!!e},fireWith:function(a,c){return e||(c=c||[],c=[a,c.slice?c.slice():c],g.push(c),b||i()),this},fire:function(){return j.fireWith(this,arguments),this},fired:function(){return!!d}};return j},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().progress(c.notify).done(c.resolve).fail(c.reject):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=e.call(arguments),d=c.length,f=1!==d||a&&n.isFunction(a.promise)?d:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(d){b[a]=this,c[a]=arguments.length>1?e.call(arguments):d,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(d>1)for(i=new Array(d),j=new Array(d),k=new Array(d);d>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().progress(h(b,j,i)).done(h(b,k,c)).fail(g.reject):--f;return f||g.resolveWith(k,c),g.promise()}});var I;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(I.resolveWith(d,[n]),n.fn.triggerHandler&&(n(d).triggerHandler("ready"),n(d).off("ready"))))}});function J(){d.addEventListener?(d.removeEventListener("DOMContentLoaded",K),a.removeEventListener("load",K)):(d.detachEvent("onreadystatechange",K),a.detachEvent("onload",K))}function K(){(d.addEventListener||"load"===a.event.type||"complete"===d.readyState)&&(J(),n.ready())}n.ready.promise=function(b){if(!I)if(I=n.Deferred(),"complete"===d.readyState||"loading"!==d.readyState&&!d.documentElement.doScroll)a.setTimeout(n.ready);else if(d.addEventListener)d.addEventListener("DOMContentLoaded",K),a.addEventListener("load",K);else{d.attachEvent("onreadystatechange",K),a.attachEvent("onload",K);var c=!1;try{c=null==a.frameElement&&d.documentElement}catch(e){}c&&c.doScroll&&!function f(){if(!n.isReady){try{c.doScroll("left")}catch(b){return a.setTimeout(f,50)}J(),n.ready()}}()}return I.promise(b)},n.ready.promise();var L;for(L in n(l))break;l.ownFirst="0"===L,l.inlineBlockNeedsLayout=!1,n(function(){var a,b,c,e;c=d.getElementsByTagName("body")[0],c&&c.style&&(b=d.createElement("div"),e=d.createElement("div"),e.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",c.appendChild(e).appendChild(b),"undefined"!=typeof b.style.zoom&&(b.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",l.inlineBlockNeedsLayout=a=3===b.offsetWidth,a&&(c.style.zoom=1)),c.removeChild(e))}),function(){var a=d.createElement("div");l.deleteExpando=!0;try{delete a.test}catch(b){l.deleteExpando=!1}a=null}();var M=function(a){var b=n.noData[(a.nodeName+" ").toLowerCase()],c=+a.nodeType||1;return 1!==c&&9!==c?!1:!b||b!==!0&&a.getAttribute("classid")===b},N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){if(void 0===c&&1===a.nodeType){var d="data-"+b.replace(O,"-$1").toLowerCase();if(c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}n.data(a,b,c)}else c=void 0;
|
3
|
-
}return c}function Q(a){var b;for(b in a)if(("data"!==b||!n.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function R(a,b,d,e){if(M(a)){var f,g,h=n.expando,i=a.nodeType,j=i?n.cache:a,k=i?a[h]:a[h]&&h;if(k&&j[k]&&(e||j[k].data)||void 0!==d||"string"!=typeof b)return k||(k=i?a[h]=c.pop()||n.guid++:h),j[k]||(j[k]=i?{}:{toJSON:n.noop}),"object"!=typeof b&&"function"!=typeof b||(e?j[k]=n.extend(j[k],b):j[k].data=n.extend(j[k].data,b)),g=j[k],e||(g.data||(g.data={}),g=g.data),void 0!==d&&(g[n.camelCase(b)]=d),"string"==typeof b?(f=g[b],null==f&&(f=g[n.camelCase(b)])):f=g,f}}function S(a,b,c){if(M(a)){var d,e,f=a.nodeType,g=f?n.cache:a,h=f?a[n.expando]:n.expando;if(g[h]){if(b&&(d=c?g[h]:g[h].data)){n.isArray(b)?b=b.concat(n.map(b,n.camelCase)):b in d?b=[b]:(b=n.camelCase(b),b=b in d?[b]:b.split(" ")),e=b.length;while(e--)delete d[b[e]];if(c?!Q(d):!n.isEmptyObject(d))return}(c||(delete g[h].data,Q(g[h])))&&(f?n.cleanData([a],!0):l.deleteExpando||g!=g.window?delete g[h]:g[h]=void 0)}}}n.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(a){return a=a.nodeType?n.cache[a[n.expando]]:a[n.expando],!!a&&!Q(a)},data:function(a,b,c){return R(a,b,c)},removeData:function(a,b){return S(a,b)},_data:function(a,b,c){return R(a,b,c,!0)},_removeData:function(a,b){return S(a,b,!0)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=n.data(f),1===f.nodeType&&!n._data(f,"parsedAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d])));n._data(f,"parsedAttrs",!0)}return e}return"object"==typeof a?this.each(function(){n.data(this,a)}):arguments.length>1?this.each(function(){n.data(this,a,b)}):f?P(f,a,n.data(f,a)):void 0},removeData:function(a){return this.each(function(){n.removeData(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=n._data(a,b),c&&(!d||n.isArray(c)?d=n._data(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return n._data(a,c)||n._data(a,c,{empty:n.Callbacks("once memory").add(function(){n._removeData(a,b+"queue"),n._removeData(a,c)})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?n.queue(this[0],a):void 0===b?this:this.each(function(){var c=n.queue(this,a,b);n._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&n.dequeue(this,a)})},dequeue:function(a){return this.each(function(){n.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=n.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=n._data(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}}),function(){var a;l.shrinkWrapBlocks=function(){if(null!=a)return a;a=!1;var b,c,e;return c=d.getElementsByTagName("body")[0],c&&c.style?(b=d.createElement("div"),e=d.createElement("div"),e.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",c.appendChild(e).appendChild(b),"undefined"!=typeof b.style.zoom&&(b.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:1px;width:1px;zoom:1",b.appendChild(d.createElement("div")).style.width="5px",a=3!==b.offsetWidth),c.removeChild(e),a):void 0}}();var T=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,U=new RegExp("^(?:([+-])=|)("+T+")([a-z%]*)$","i"),V=["Top","Right","Bottom","Left"],W=function(a,b){return a=b||a,"none"===n.css(a,"display")||!n.contains(a.ownerDocument,a)};function X(a,b,c,d){var e,f=1,g=20,h=d?function(){return d.cur()}:function(){return n.css(a,b,"")},i=h(),j=c&&c[3]||(n.cssNumber[b]?"":"px"),k=(n.cssNumber[b]||"px"!==j&&+i)&&U.exec(n.css(a,b));if(k&&k[3]!==j){j=j||k[3],c=c||[],k=+i||1;do f=f||".5",k/=f,n.style(a,b,k+j);while(f!==(f=h()/i)&&1!==f&&--g)}return c&&(k=+k||+i||0,e=c[1]?k+(c[1]+1)*c[2]:+c[2],d&&(d.unit=j,d.start=k,d.end=e)),e}var Y=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)Y(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},Z=/^(?:checkbox|radio)$/i,$=/<([\w:-]+)/,_=/^$|\/(?:java|ecma)script/i,aa=/^\s+/,ba="abbr|article|aside|audio|bdi|canvas|data|datalist|details|dialog|figcaption|figure|footer|header|hgroup|main|mark|meter|nav|output|picture|progress|section|summary|template|time|video";function ca(a){var b=ba.split("|"),c=a.createDocumentFragment();if(c.createElement)while(b.length)c.createElement(b.pop());return c}!function(){var a=d.createElement("div"),b=d.createDocumentFragment(),c=d.createElement("input");a.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",l.leadingWhitespace=3===a.firstChild.nodeType,l.tbody=!a.getElementsByTagName("tbody").length,l.htmlSerialize=!!a.getElementsByTagName("link").length,l.html5Clone="<:nav></:nav>"!==d.createElement("nav").cloneNode(!0).outerHTML,c.type="checkbox",c.checked=!0,b.appendChild(c),l.appendChecked=c.checked,a.innerHTML="<textarea>x</textarea>",l.noCloneChecked=!!a.cloneNode(!0).lastChild.defaultValue,b.appendChild(a),c=d.createElement("input"),c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),a.appendChild(c),l.checkClone=a.cloneNode(!0).cloneNode(!0).lastChild.checked,l.noCloneEvent=!!a.addEventListener,a[n.expando]=1,l.attributes=!a.getAttribute(n.expando)}();var da={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:l.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]};da.optgroup=da.option,da.tbody=da.tfoot=da.colgroup=da.caption=da.thead,da.th=da.td;function ea(a,b){var c,d,e=0,f="undefined"!=typeof a.getElementsByTagName?a.getElementsByTagName(b||"*"):"undefined"!=typeof a.querySelectorAll?a.querySelectorAll(b||"*"):void 0;if(!f)for(f=[],c=a.childNodes||a;null!=(d=c[e]);e++)!b||n.nodeName(d,b)?f.push(d):n.merge(f,ea(d,b));return void 0===b||b&&n.nodeName(a,b)?n.merge([a],f):f}function fa(a,b){for(var c,d=0;null!=(c=a[d]);d++)n._data(c,"globalEval",!b||n._data(b[d],"globalEval"))}var ga=/<|&#?\w+;/,ha=/<tbody/i;function ia(a){Z.test(a.type)&&(a.defaultChecked=a.checked)}function ja(a,b,c,d,e){for(var f,g,h,i,j,k,m,o=a.length,p=ca(b),q=[],r=0;o>r;r++)if(g=a[r],g||0===g)if("object"===n.type(g))n.merge(q,g.nodeType?[g]:g);else if(ga.test(g)){i=i||p.appendChild(b.createElement("div")),j=($.exec(g)||["",""])[1].toLowerCase(),m=da[j]||da._default,i.innerHTML=m[1]+n.htmlPrefilter(g)+m[2],f=m[0];while(f--)i=i.lastChild;if(!l.leadingWhitespace&&aa.test(g)&&q.push(b.createTextNode(aa.exec(g)[0])),!l.tbody){g="table"!==j||ha.test(g)?"<table>"!==m[1]||ha.test(g)?0:i:i.firstChild,f=g&&g.childNodes.length;while(f--)n.nodeName(k=g.childNodes[f],"tbody")&&!k.childNodes.length&&g.removeChild(k)}n.merge(q,i.childNodes),i.textContent="";while(i.firstChild)i.removeChild(i.firstChild);i=p.lastChild}else q.push(b.createTextNode(g));i&&p.removeChild(i),l.appendChecked||n.grep(ea(q,"input"),ia),r=0;while(g=q[r++])if(d&&n.inArray(g,d)>-1)e&&e.push(g);else if(h=n.contains(g.ownerDocument,g),i=ea(p.appendChild(g),"script"),h&&fa(i),c){f=0;while(g=i[f++])_.test(g.type||"")&&c.push(g)}return i=null,p}!function(){var b,c,e=d.createElement("div");for(b in{submit:!0,change:!0,focusin:!0})c="on"+b,(l[b]=c in a)||(e.setAttribute(c,"t"),l[b]=e.attributes[c].expando===!1);e=null}();var ka=/^(?:input|select|textarea)$/i,la=/^key/,ma=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,na=/^(?:focusinfocus|focusoutblur)$/,oa=/^([^.]*)(?:\.(.+)|)/;function pa(){return!0}function qa(){return!1}function ra(){try{return d.activeElement}catch(a){}}function sa(a,b,c,d,e,f){var g,h;if("object"==typeof b){"string"!=typeof c&&(d=d||c,c=void 0);for(h in b)sa(a,h,c,d,b[h],f);return a}if(null==d&&null==e?(e=c,d=c=void 0):null==e&&("string"==typeof c?(e=d,d=void 0):(e=d,d=c,c=void 0)),e===!1)e=qa;else if(!e)return a;return 1===f&&(g=e,e=function(a){return n().off(a),g.apply(this,arguments)},e.guid=g.guid||(g.guid=n.guid++)),a.each(function(){n.event.add(this,b,e,d,c)})}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n._data(a);if(r){c.handler&&(i=c,c=i.handler,e=i.selector),c.guid||(c.guid=n.guid++),(g=r.events)||(g=r.events={}),(k=r.handle)||(k=r.handle=function(a){return"undefined"==typeof n||a&&n.event.triggered===a.type?void 0:n.event.dispatch.apply(k.elem,arguments)},k.elem=a),b=(b||"").match(G)||[""],h=b.length;while(h--)f=oa.exec(b[h])||[],o=q=f[1],p=(f[2]||"").split(".").sort(),o&&(j=n.event.special[o]||{},o=(e?j.delegateType:j.bindType)||o,j=n.event.special[o]||{},l=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},i),(m=g[o])||(m=g[o]=[],m.delegateCount=0,j.setup&&j.setup.call(a,d,p,k)!==!1||(a.addEventListener?a.addEventListener(o,k,!1):a.attachEvent&&a.attachEvent("on"+o,k))),j.add&&(j.add.call(a,l),l.handler.guid||(l.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,l):m.push(l),n.event.global[o]=!0);a=null}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n.hasData(a)&&n._data(a);if(r&&(k=r.events)){b=(b||"").match(G)||[""],j=b.length;while(j--)if(h=oa.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=k[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),i=f=m.length;while(f--)g=m[f],!e&&q!==g.origType||c&&c.guid!==g.guid||h&&!h.test(g.namespace)||d&&d!==g.selector&&("**"!==d||!g.selector)||(m.splice(f,1),g.selector&&m.delegateCount--,l.remove&&l.remove.call(a,g));i&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete k[o])}else for(o in k)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(k)&&(delete r.handle,n._removeData(a,"events"))}},trigger:function(b,c,e,f){var g,h,i,j,l,m,o,p=[e||d],q=k.call(b,"type")?b.type:b,r=k.call(b,"namespace")?b.namespace.split("."):[];if(i=m=e=e||d,3!==e.nodeType&&8!==e.nodeType&&!na.test(q+n.event.triggered)&&(q.indexOf(".")>-1&&(r=q.split("."),q=r.shift(),r.sort()),h=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=f?2:3,b.namespace=r.join("."),b.rnamespace=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=e),c=null==c?[b]:n.makeArray(c,[b]),l=n.event.special[q]||{},f||!l.trigger||l.trigger.apply(e,c)!==!1)){if(!f&&!l.noBubble&&!n.isWindow(e)){for(j=l.delegateType||q,na.test(j+q)||(i=i.parentNode);i;i=i.parentNode)p.push(i),m=i;m===(e.ownerDocument||d)&&p.push(m.defaultView||m.parentWindow||a)}o=0;while((i=p[o++])&&!b.isPropagationStopped())b.type=o>1?j:l.bindType||q,g=(n._data(i,"events")||{})[b.type]&&n._data(i,"handle"),g&&g.apply(i,c),g=h&&i[h],g&&g.apply&&M(i)&&(b.result=g.apply(i,c),b.result===!1&&b.preventDefault());if(b.type=q,!f&&!b.isDefaultPrevented()&&(!l._default||l._default.apply(p.pop(),c)===!1)&&M(e)&&h&&e[q]&&!n.isWindow(e)){m=e[h],m&&(e[h]=null),n.event.triggered=q;try{e[q]()}catch(s){}n.event.triggered=void 0,m&&(e[h]=m)}return b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,d,f,g,h=[],i=e.call(arguments),j=(n._data(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())a.rnamespace&&!a.rnamespace.test(g.namespace)||(a.handleObj=g,a.data=g.data,d=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==d&&(a.result=d)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&("click"!==a.type||isNaN(a.button)||a.button<1))for(;i!=this;i=i.parentNode||this)if(1===i.nodeType&&(i.disabled!==!0||"click"!==a.type)){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>-1:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},fix:function(a){if(a[n.expando])return a;var b,c,e,f=a.type,g=a,h=this.fixHooks[f];h||(this.fixHooks[f]=h=ma.test(f)?this.mouseHooks:la.test(f)?this.keyHooks:{}),e=h.props?this.props.concat(h.props):this.props,a=new n.Event(g),b=e.length;while(b--)c=e[b],a[c]=g[c];return a.target||(a.target=g.srcElement||d),3===a.target.nodeType&&(a.target=a.target.parentNode),a.metaKey=!!a.metaKey,h.filter?h.filter(a,g):a},props:"altKey bubbles cancelable ctrlKey currentTarget detail eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,e,f,g=b.button,h=b.fromElement;return null==a.pageX&&null!=b.clientX&&(e=a.target.ownerDocument||d,f=e.documentElement,c=e.body,a.pageX=b.clientX+(f&&f.scrollLeft||c&&c.scrollLeft||0)-(f&&f.clientLeft||c&&c.clientLeft||0),a.pageY=b.clientY+(f&&f.scrollTop||c&&c.scrollTop||0)-(f&&f.clientTop||c&&c.clientTop||0)),!a.relatedTarget&&h&&(a.relatedTarget=h===a.target?b.toElement:h),a.which||void 0===g||(a.which=1&g?1:2&g?3:4&g?2:0),a}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==ra()&&this.focus)try{return this.focus(),!1}catch(a){}},delegateType:"focusin"},blur:{trigger:function(){return this===ra()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return n.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):void 0},_default:function(a){return n.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}},simulate:function(a,b,c){var d=n.extend(new n.Event,c,{type:a,isSimulated:!0});n.event.trigger(d,null,b),d.isDefaultPrevented()&&c.preventDefault()}},n.removeEvent=d.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c)}:function(a,b,c){var d="on"+b;a.detachEvent&&("undefined"==typeof a[d]&&(a[d]=null),a.detachEvent(d,c))},n.Event=function(a,b){return this instanceof n.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?pa:qa):this.type=a,b&&n.extend(this,b),this.timeStamp=a&&a.timeStamp||n.now(),void(this[n.expando]=!0)):new n.Event(a,b)},n.Event.prototype={constructor:n.Event,isDefaultPrevented:qa,isPropagationStopped:qa,isImmediatePropagationStopped:qa,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=pa,a&&(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=pa,a&&!this.isSimulated&&(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=pa,a&&a.stopImmediatePropagation&&a.stopImmediatePropagation(),this.stopPropagation()}},n.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){n.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return e&&(e===d||n.contains(d,e))||(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),l.submit||(n.event.special.submit={setup:function(){return n.nodeName(this,"form")?!1:void n.event.add(this,"click._submit keypress._submit",function(a){var b=a.target,c=n.nodeName(b,"input")||n.nodeName(b,"button")?n.prop(b,"form"):void 0;c&&!n._data(c,"submit")&&(n.event.add(c,"submit._submit",function(a){a._submitBubble=!0}),n._data(c,"submit",!0))})},postDispatch:function(a){a._submitBubble&&(delete a._submitBubble,this.parentNode&&!a.isTrigger&&n.event.simulate("submit",this.parentNode,a))},teardown:function(){return n.nodeName(this,"form")?!1:void n.event.remove(this,"._submit")}}),l.change||(n.event.special.change={setup:function(){return ka.test(this.nodeName)?("checkbox"!==this.type&&"radio"!==this.type||(n.event.add(this,"propertychange._change",function(a){"checked"===a.originalEvent.propertyName&&(this._justChanged=!0)}),n.event.add(this,"click._change",function(a){this._justChanged&&!a.isTrigger&&(this._justChanged=!1),n.event.simulate("change",this,a)})),!1):void n.event.add(this,"beforeactivate._change",function(a){var b=a.target;ka.test(b.nodeName)&&!n._data(b,"change")&&(n.event.add(b,"change._change",function(a){!this.parentNode||a.isSimulated||a.isTrigger||n.event.simulate("change",this.parentNode,a)}),n._data(b,"change",!0))})},handle:function(a){var b=a.target;return this!==b||a.isSimulated||a.isTrigger||"radio"!==b.type&&"checkbox"!==b.type?a.handleObj.handler.apply(this,arguments):void 0},teardown:function(){return n.event.remove(this,"._change"),!ka.test(this.nodeName)}}),l.focusin||n.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){n.event.simulate(b,a.target,n.event.fix(a))};n.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=n._data(d,b);e||d.addEventListener(a,c,!0),n._data(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=n._data(d,b)-1;e?n._data(d,b,e):(d.removeEventListener(a,c,!0),n._removeData(d,b))}}}),n.fn.extend({on:function(a,b,c,d){return sa(this,a,b,c,d)},one:function(a,b,c,d){return sa(this,a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,n(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return b!==!1&&"function"!=typeof b||(c=b,b=void 0),c===!1&&(c=qa),this.each(function(){n.event.remove(this,a,c,b)})},trigger:function(a,b){return this.each(function(){n.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?n.event.trigger(a,b,c,!0):void 0}});var ta=/ jQuery\d+="(?:null|\d+)"/g,ua=new RegExp("<(?:"+ba+")[\\s/>]","i"),va=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,wa=/<script|<style|<link/i,xa=/checked\s*(?:[^=]|=\s*.checked.)/i,ya=/^true\/(.*)/,za=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,Aa=ca(d),Ba=Aa.appendChild(d.createElement("div"));function Ca(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function Da(a){return a.type=(null!==n.find.attr(a,"type"))+"/"+a.type,a}function Ea(a){var b=ya.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function Fa(a,b){if(1===b.nodeType&&n.hasData(a)){var c,d,e,f=n._data(a),g=n._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;e>d;d++)n.event.add(b,c,h[c][d])}g.data&&(g.data=n.extend({},g.data))}}function Ga(a,b){var c,d,e;if(1===b.nodeType){if(c=b.nodeName.toLowerCase(),!l.noCloneEvent&&b[n.expando]){e=n._data(b);for(d in e.events)n.removeEvent(b,d,e.handle);b.removeAttribute(n.expando)}"script"===c&&b.text!==a.text?(Da(b).text=a.text,Ea(b)):"object"===c?(b.parentNode&&(b.outerHTML=a.outerHTML),l.html5Clone&&a.innerHTML&&!n.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):"input"===c&&Z.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):"option"===c?b.defaultSelected=b.selected=a.defaultSelected:"input"!==c&&"textarea"!==c||(b.defaultValue=a.defaultValue)}}function Ha(a,b,c,d){b=f.apply([],b);var e,g,h,i,j,k,m=0,o=a.length,p=o-1,q=b[0],r=n.isFunction(q);if(r||o>1&&"string"==typeof q&&!l.checkClone&&xa.test(q))return a.each(function(e){var f=a.eq(e);r&&(b[0]=q.call(this,e,f.html())),Ha(f,b,c,d)});if(o&&(k=ja(b,a[0].ownerDocument,!1,a,d),e=k.firstChild,1===k.childNodes.length&&(k=e),e||d)){for(i=n.map(ea(k,"script"),Da),h=i.length;o>m;m++)g=k,m!==p&&(g=n.clone(g,!0,!0),h&&n.merge(i,ea(g,"script"))),c.call(a[m],g,m);if(h)for(j=i[i.length-1].ownerDocument,n.map(i,Ea),m=0;h>m;m++)g=i[m],_.test(g.type||"")&&!n._data(g,"globalEval")&&n.contains(j,g)&&(g.src?n._evalUrl&&n._evalUrl(g.src):n.globalEval((g.text||g.textContent||g.innerHTML||"").replace(za,"")));k=e=null}return a}function Ia(a,b,c){for(var d,e=b?n.filter(b,a):a,f=0;null!=(d=e[f]);f++)c||1!==d.nodeType||n.cleanData(ea(d)),d.parentNode&&(c&&n.contains(d.ownerDocument,d)&&fa(ea(d,"script")),d.parentNode.removeChild(d));return a}n.extend({htmlPrefilter:function(a){return a.replace(va,"<$1></$2>")},clone:function(a,b,c){var d,e,f,g,h,i=n.contains(a.ownerDocument,a);if(l.html5Clone||n.isXMLDoc(a)||!ua.test("<"+a.nodeName+">")?f=a.cloneNode(!0):(Ba.innerHTML=a.outerHTML,Ba.removeChild(f=Ba.firstChild)),!(l.noCloneEvent&&l.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(d=ea(f),h=ea(a),g=0;null!=(e=h[g]);++g)d[g]&&Ga(e,d[g]);if(b)if(c)for(h=h||ea(a),d=d||ea(f),g=0;null!=(e=h[g]);g++)Fa(e,d[g]);else Fa(a,f);return d=ea(f,"script"),d.length>0&&fa(d,!i&&ea(a,"script")),d=h=e=null,f},cleanData:function(a,b){for(var d,e,f,g,h=0,i=n.expando,j=n.cache,k=l.attributes,m=n.event.special;null!=(d=a[h]);h++)if((b||M(d))&&(f=d[i],g=f&&j[f])){if(g.events)for(e in g.events)m[e]?n.event.remove(d,e):n.removeEvent(d,e,g.handle);j[f]&&(delete j[f],k||"undefined"==typeof d.removeAttribute?d[i]=void 0:d.removeAttribute(i),c.push(f))}}}),n.fn.extend({domManip:Ha,detach:function(a){return Ia(this,a,!0)},remove:function(a){return Ia(this,a)},text:function(a){return Y(this,function(a){return void 0===a?n.text(this):this.empty().append((this[0]&&this[0].ownerDocument||d).createTextNode(a))},null,a,arguments.length)},append:function(){return Ha(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ca(this,a);b.appendChild(a)}})},prepend:function(){return Ha(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ca(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return Ha(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return Ha(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},empty:function(){for(var a,b=0;null!=(a=this[b]);b++){1===a.nodeType&&n.cleanData(ea(a,!1));while(a.firstChild)a.removeChild(a.firstChild);a.options&&n.nodeName(a,"select")&&(a.options.length=0)}return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return Y(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a)return 1===b.nodeType?b.innerHTML.replace(ta,""):void 0;if("string"==typeof a&&!wa.test(a)&&(l.htmlSerialize||!ua.test(a))&&(l.leadingWhitespace||!aa.test(a))&&!da[($.exec(a)||["",""])[1].toLowerCase()]){a=n.htmlPrefilter(a);try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(ea(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=[];return Ha(this,arguments,function(b){var c=this.parentNode;n.inArray(this,a)<0&&(n.cleanData(ea(this)),c&&c.replaceChild(b,this))},a)}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=0,e=[],f=n(a),h=f.length-1;h>=d;d++)c=d===h?this:this.clone(!0),n(f[d])[b](c),g.apply(e,c.get());return this.pushStack(e)}});var Ja,Ka={HTML:"block",BODY:"block"};function La(a,b){var c=n(b.createElement(a)).appendTo(b.body),d=n.css(c[0],"display");return c.detach(),d}function Ma(a){var b=d,c=Ka[a];return c||(c=La(a,b),"none"!==c&&c||(Ja=(Ja||n("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=(Ja[0].contentWindow||Ja[0].contentDocument).document,b.write(),b.close(),c=La(a,b),Ja.detach()),Ka[a]=c),c}var Na=/^margin/,Oa=new RegExp("^("+T+")(?!px)[a-z%]+$","i"),Pa=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e},Qa=d.documentElement;!function(){var b,c,e,f,g,h,i=d.createElement("div"),j=d.createElement("div");if(j.style){j.style.cssText="float:left;opacity:.5",l.opacity="0.5"===j.style.opacity,l.cssFloat=!!j.style.cssFloat,j.style.backgroundClip="content-box",j.cloneNode(!0).style.backgroundClip="",l.clearCloneStyle="content-box"===j.style.backgroundClip,i=d.createElement("div"),i.style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",j.innerHTML="",i.appendChild(j),l.boxSizing=""===j.style.boxSizing||""===j.style.MozBoxSizing||""===j.style.WebkitBoxSizing,n.extend(l,{reliableHiddenOffsets:function(){return null==b&&k(),f},boxSizingReliable:function(){return null==b&&k(),e},pixelMarginRight:function(){return null==b&&k(),c},pixelPosition:function(){return null==b&&k(),b},reliableMarginRight:function(){return null==b&&k(),g},reliableMarginLeft:function(){return null==b&&k(),h}});function k(){var k,l,m=d.documentElement;m.appendChild(i),j.style.cssText="-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",b=e=h=!1,c=g=!0,a.getComputedStyle&&(l=a.getComputedStyle(j),b="1%"!==(l||{}).top,h="2px"===(l||{}).marginLeft,e="4px"===(l||{width:"4px"}).width,j.style.marginRight="50%",c="4px"===(l||{marginRight:"4px"}).marginRight,k=j.appendChild(d.createElement("div")),k.style.cssText=j.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",k.style.marginRight=k.style.width="0",j.style.width="1px",g=!parseFloat((a.getComputedStyle(k)||{}).marginRight),j.removeChild(k)),j.style.display="none",f=0===j.getClientRects().length,f&&(j.style.display="",j.innerHTML="<table><tr><td></td><td>t</td></tr></table>",k=j.getElementsByTagName("td"),k[0].style.cssText="margin:0;border:0;padding:0;display:none",f=0===k[0].offsetHeight,f&&(k[0].style.display="",k[1].style.display="none",f=0===k[0].offsetHeight)),m.removeChild(i)}}}();var Ra,Sa,Ta=/^(top|right|bottom|left)$/;a.getComputedStyle?(Ra=function(b){var c=b.ownerDocument.defaultView;return c&&c.opener||(c=a),c.getComputedStyle(b)},Sa=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Ra(a),g=c?c.getPropertyValue(b)||c[b]:void 0,""!==g&&void 0!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),c&&!l.pixelMarginRight()&&Oa.test(g)&&Na.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f),void 0===g?g:g+""}):Qa.currentStyle&&(Ra=function(a){return a.currentStyle},Sa=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Ra(a),g=c?c[b]:void 0,null==g&&h&&h[b]&&(g=h[b]),Oa.test(g)&&!Ta.test(b)&&(d=h.left,e=a.runtimeStyle,f=e&&e.left,f&&(e.left=a.currentStyle.left),h.left="fontSize"===b?"1em":g,g=h.pixelLeft+"px",h.left=d,f&&(e.left=f)),void 0===g?g:g+""||"auto"});function Ua(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}var Va=/alpha\([^)]*\)/i,Wa=/opacity\s*=\s*([^)]*)/i,Xa=/^(none|table(?!-c[ea]).+)/,Ya=new RegExp("^("+T+")(.*)$","i"),Za={position:"absolute",visibility:"hidden",display:"block"},$a={letterSpacing:"0",fontWeight:"400"},_a=["Webkit","O","Moz","ms"],ab=d.createElement("div").style;function bb(a){if(a in ab)return a;var b=a.charAt(0).toUpperCase()+a.slice(1),c=_a.length;while(c--)if(a=_a[c]+b,a in ab)return a}function cb(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=n._data(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&W(d)&&(f[g]=n._data(d,"olddisplay",Ma(d.nodeName)))):(e=W(d),(c&&"none"!==c||!e)&&n._data(d,"olddisplay",e?c:n.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}function db(a,b,c){var d=Ya.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function eb(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=n.css(a,c+V[f],!0,e)),d?("content"===c&&(g-=n.css(a,"padding"+V[f],!0,e)),"margin"!==c&&(g-=n.css(a,"border"+V[f]+"Width",!0,e))):(g+=n.css(a,"padding"+V[f],!0,e),"padding"!==c&&(g+=n.css(a,"border"+V[f]+"Width",!0,e)));return g}function fb(b,c,e){var f=!0,g="width"===c?b.offsetWidth:b.offsetHeight,h=Ra(b),i=l.boxSizing&&"border-box"===n.css(b,"boxSizing",!1,h);if(d.msFullscreenElement&&a.top!==a&&b.getClientRects().length&&(g=Math.round(100*b.getBoundingClientRect()[c])),0>=g||null==g){if(g=Sa(b,c,h),(0>g||null==g)&&(g=b.style[c]),Oa.test(g))return g;f=i&&(l.boxSizingReliable()||g===b.style[c]),g=parseFloat(g)||0}return g+eb(b,c,e||(i?"border":"content"),f,h)+"px"}n.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=Sa(a,"opacity");return""===c?"1":c}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":l.cssFloat?"cssFloat":"styleFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=n.camelCase(b),i=a.style;if(b=n.cssProps[h]||(n.cssProps[h]=bb(h)||h),g=n.cssHooks[b]||n.cssHooks[h],void 0===c)return g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b];if(f=typeof c,"string"===f&&(e=U.exec(c))&&e[1]&&(c=X(a,b,e),f="number"),null!=c&&c===c&&("number"===f&&(c+=e&&e[3]||(n.cssNumber[h]?"":"px")),l.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),!(g&&"set"in g&&void 0===(c=g.set(a,c,d)))))try{i[b]=c}catch(j){}}},css:function(a,b,c,d){var e,f,g,h=n.camelCase(b);return b=n.cssProps[h]||(n.cssProps[h]=bb(h)||h),g=n.cssHooks[b]||n.cssHooks[h],g&&"get"in g&&(f=g.get(a,!0,c)),void 0===f&&(f=Sa(a,b,d)),"normal"===f&&b in $a&&(f=$a[b]),""===c||c?(e=parseFloat(f),c===!0||isFinite(e)?e||0:f):f}}),n.each(["height","width"],function(a,b){n.cssHooks[b]={get:function(a,c,d){return c?Xa.test(n.css(a,"display"))&&0===a.offsetWidth?Pa(a,Za,function(){return fb(a,b,d)}):fb(a,b,d):void 0},set:function(a,c,d){var e=d&&Ra(a);return db(a,c,d?eb(a,b,d,l.boxSizing&&"border-box"===n.css(a,"boxSizing",!1,e),e):0)}}}),l.opacity||(n.cssHooks.opacity={get:function(a,b){return Wa.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=n.isNumeric(b)?"alpha(opacity="+100*b+")":"",f=d&&d.filter||c.filter||"";c.zoom=1,(b>=1||""===b)&&""===n.trim(f.replace(Va,""))&&c.removeAttribute&&(c.removeAttribute("filter"),""===b||d&&!d.filter)||(c.filter=Va.test(f)?f.replace(Va,e):f+" "+e)}}),n.cssHooks.marginRight=Ua(l.reliableMarginRight,function(a,b){return b?Pa(a,{display:"inline-block"},Sa,[a,"marginRight"]):void 0}),n.cssHooks.marginLeft=Ua(l.reliableMarginLeft,function(a,b){
|
4
|
-
return b?(parseFloat(Sa(a,"marginLeft"))||(n.contains(a.ownerDocument,a)?a.getBoundingClientRect().left-Pa(a,{marginLeft:0},function(){return a.getBoundingClientRect().left}):0))+"px":void 0}),n.each({margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+V[d]+b]=f[d]||f[d-2]||f[0];return e}},Na.test(a)||(n.cssHooks[a+b].set=db)}),n.fn.extend({css:function(a,b){return Y(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=Ra(a),e=b.length;e>g;g++)f[b[g]]=n.css(a,b[g],!1,d);return f}return void 0!==c?n.style(a,b,c):n.css(a,b)},a,b,arguments.length>1)},show:function(){return cb(this,!0)},hide:function(){return cb(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){W(this)?n(this).show():n(this).hide()})}});function gb(a,b,c,d,e){return new gb.prototype.init(a,b,c,d,e)}n.Tween=gb,gb.prototype={constructor:gb,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||n.easing._default,this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=gb.propHooks[this.prop];return a&&a.get?a.get(this):gb.propHooks._default.get(this)},run:function(a){var b,c=gb.propHooks[this.prop];return this.options.duration?this.pos=b=n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):this.pos=b=a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):gb.propHooks._default.set(this),this}},gb.prototype.init.prototype=gb.prototype,gb.propHooks={_default:{get:function(a){var b;return 1!==a.elem.nodeType||null!=a.elem[a.prop]&&null==a.elem.style[a.prop]?a.elem[a.prop]:(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0)},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):1!==a.elem.nodeType||null==a.elem.style[n.cssProps[a.prop]]&&!n.cssHooks[a.prop]?a.elem[a.prop]=a.now:n.style(a.elem,a.prop,a.now+a.unit)}}},gb.propHooks.scrollTop=gb.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2},_default:"swing"},n.fx=gb.prototype.init,n.fx.step={};var hb,ib,jb=/^(?:toggle|show|hide)$/,kb=/queueHooks$/;function lb(){return a.setTimeout(function(){hb=void 0}),hb=n.now()}function mb(a,b){var c,d={height:a},e=0;for(b=b?1:0;4>e;e+=2-b)c=V[e],d["margin"+c]=d["padding"+c]=a;return b&&(d.opacity=d.width=a),d}function nb(a,b,c){for(var d,e=(qb.tweeners[b]||[]).concat(qb.tweeners["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function ob(a,b,c){var d,e,f,g,h,i,j,k,m=this,o={},p=a.style,q=a.nodeType&&W(a),r=n._data(a,"fxshow");c.queue||(h=n._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,m.always(function(){m.always(function(){h.unqueued--,n.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[p.overflow,p.overflowX,p.overflowY],j=n.css(a,"display"),k="none"===j?n._data(a,"olddisplay")||Ma(a.nodeName):j,"inline"===k&&"none"===n.css(a,"float")&&(l.inlineBlockNeedsLayout&&"inline"!==Ma(a.nodeName)?p.zoom=1:p.display="inline-block")),c.overflow&&(p.overflow="hidden",l.shrinkWrapBlocks()||m.always(function(){p.overflow=c.overflow[0],p.overflowX=c.overflow[1],p.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],jb.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(q?"hide":"show")){if("show"!==e||!r||void 0===r[d])continue;q=!0}o[d]=r&&r[d]||n.style(a,d)}else j=void 0;if(n.isEmptyObject(o))"inline"===("none"===j?Ma(a.nodeName):j)&&(p.display=j);else{r?"hidden"in r&&(q=r.hidden):r=n._data(a,"fxshow",{}),f&&(r.hidden=!q),q?n(a).show():m.done(function(){n(a).hide()}),m.done(function(){var b;n._removeData(a,"fxshow");for(b in o)n.style(a,b,o[b])});for(d in o)g=nb(q?r[d]:0,d,m),d in r||(r[d]=g.start,q&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function pb(a,b){var c,d,e,f,g;for(c in a)if(d=n.camelCase(c),e=b[d],f=a[c],n.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=n.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function qb(a,b,c){var d,e,f=0,g=qb.prefilters.length,h=n.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=hb||lb(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:n.extend({},b),opts:n.extend(!0,{specialEasing:{},easing:n.easing._default},c),originalProperties:b,originalOptions:c,startTime:hb||lb(),duration:c.duration,tweens:[],createTween:function(b,c){var d=n.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?(h.notifyWith(a,[j,1,0]),h.resolveWith(a,[j,b])):h.rejectWith(a,[j,b]),this}}),k=j.props;for(pb(k,j.opts.specialEasing);g>f;f++)if(d=qb.prefilters[f].call(j,a,k,j.opts))return n.isFunction(d.stop)&&(n._queueHooks(j.elem,j.opts.queue).stop=n.proxy(d.stop,d)),d;return n.map(k,nb,j),n.isFunction(j.opts.start)&&j.opts.start.call(a,j),n.fx.timer(n.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}n.Animation=n.extend(qb,{tweeners:{"*":[function(a,b){var c=this.createTween(a,b);return X(c.elem,a,U.exec(b),c),c}]},tweener:function(a,b){n.isFunction(a)?(b=a,a=["*"]):a=a.match(G);for(var c,d=0,e=a.length;e>d;d++)c=a[d],qb.tweeners[c]=qb.tweeners[c]||[],qb.tweeners[c].unshift(b)},prefilters:[ob],prefilter:function(a,b){b?qb.prefilters.unshift(a):qb.prefilters.push(a)}}),n.speed=function(a,b,c){var d=a&&"object"==typeof a?n.extend({},a):{complete:c||!c&&b||n.isFunction(a)&&a,duration:a,easing:c&&b||b&&!n.isFunction(b)&&b};return d.duration=n.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in n.fx.speeds?n.fx.speeds[d.duration]:n.fx.speeds._default,null!=d.queue&&d.queue!==!0||(d.queue="fx"),d.old=d.complete,d.complete=function(){n.isFunction(d.old)&&d.old.call(this),d.queue&&n.dequeue(this,d.queue)},d},n.fn.extend({fadeTo:function(a,b,c,d){return this.filter(W).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=n.isEmptyObject(a),f=n.speed(b,c,d),g=function(){var b=qb(this,n.extend({},a),f);(e||n._data(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=n.timers,g=n._data(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&kb.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));!b&&c||n.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=n._data(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=n.timers,g=d?d.length:0;for(c.finish=!0,n.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),n.each(["toggle","show","hide"],function(a,b){var c=n.fn[b];n.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(mb(b,!0),a,d,e)}}),n.each({slideDown:mb("show"),slideUp:mb("hide"),slideToggle:mb("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){n.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),n.timers=[],n.fx.tick=function(){var a,b=n.timers,c=0;for(hb=n.now();c<b.length;c++)a=b[c],a()||b[c]!==a||b.splice(c--,1);b.length||n.fx.stop(),hb=void 0},n.fx.timer=function(a){n.timers.push(a),a()?n.fx.start():n.timers.pop()},n.fx.interval=13,n.fx.start=function(){ib||(ib=a.setInterval(n.fx.tick,n.fx.interval))},n.fx.stop=function(){a.clearInterval(ib),ib=null},n.fx.speeds={slow:600,fast:200,_default:400},n.fn.delay=function(b,c){return b=n.fx?n.fx.speeds[b]||b:b,c=c||"fx",this.queue(c,function(c,d){var e=a.setTimeout(c,b);d.stop=function(){a.clearTimeout(e)}})},function(){var a,b=d.createElement("input"),c=d.createElement("div"),e=d.createElement("select"),f=e.appendChild(d.createElement("option"));c=d.createElement("div"),c.setAttribute("className","t"),c.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",a=c.getElementsByTagName("a")[0],b.setAttribute("type","checkbox"),c.appendChild(b),a=c.getElementsByTagName("a")[0],a.style.cssText="top:1px",l.getSetAttribute="t"!==c.className,l.style=/top/.test(a.getAttribute("style")),l.hrefNormalized="/a"===a.getAttribute("href"),l.checkOn=!!b.value,l.optSelected=f.selected,l.enctype=!!d.createElement("form").enctype,e.disabled=!0,l.optDisabled=!f.disabled,b=d.createElement("input"),b.setAttribute("value",""),l.input=""===b.getAttribute("value"),b.value="t",b.setAttribute("type","radio"),l.radioValue="t"===b.value}();var rb=/\r/g,sb=/[\x20\t\r\n\f]+/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(rb,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.trim(n.text(a)).replace(sb," ")}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],(c.selected||i===e)&&(l.optDisabled?!c.disabled:null===c.getAttribute("disabled"))&&(!c.parentNode.disabled||!n.nodeName(c.parentNode,"optgroup"))){if(b=n(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=n.makeArray(b),g=e.length;while(g--)if(d=e[g],n.inArray(n.valHooks.option.get(d),f)>-1)try{d.selected=c=!0}catch(h){d.scrollHeight}else d.selected=!1;return c||(a.selectedIndex=-1),e}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){return n.isArray(b)?a.checked=n.inArray(n(a).val(),b)>-1:void 0}},l.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})});var tb,ub,vb=n.expr.attrHandle,wb=/^(?:checked|selected)$/i,xb=l.getSetAttribute,yb=l.input;n.fn.extend({attr:function(a,b){return Y(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return"undefined"==typeof a.getAttribute?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),e=n.attrHooks[b]||(n.expr.match.bool.test(b)?ub:tb)),void 0!==c?null===c?void n.removeAttr(a,b):e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:(a.setAttribute(b,c+""),c):e&&"get"in e&&null!==(d=e.get(a,b))?d:(d=n.find.attr(a,b),null==d?void 0:d))},attrHooks:{type:{set:function(a,b){if(!l.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(G);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)?yb&&xb||!wb.test(c)?a[d]=!1:a[n.camelCase("default-"+c)]=a[d]=!1:n.attr(a,c,""),a.removeAttribute(xb?c:d)}}),ub={set:function(a,b,c){return b===!1?n.removeAttr(a,c):yb&&xb||!wb.test(c)?a.setAttribute(!xb&&n.propFix[c]||c,c):a[n.camelCase("default-"+c)]=a[c]=!0,c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=vb[b]||n.find.attr;yb&&xb||!wb.test(b)?vb[b]=function(a,b,d){var e,f;return d||(f=vb[b],vb[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,vb[b]=f),e}:vb[b]=function(a,b,c){return c?void 0:a[n.camelCase("default-"+b)]?b.toLowerCase():null}}),yb&&xb||(n.attrHooks.value={set:function(a,b,c){return n.nodeName(a,"input")?void(a.defaultValue=b):tb&&tb.set(a,b,c)}}),xb||(tb={set:function(a,b,c){var d=a.getAttributeNode(c);return d||a.setAttributeNode(d=a.ownerDocument.createAttribute(c)),d.value=b+="","value"===c||b===a.getAttribute(c)?b:void 0}},vb.id=vb.name=vb.coords=function(a,b,c){var d;return c?void 0:(d=a.getAttributeNode(b))&&""!==d.value?d.value:null},n.valHooks.button={get:function(a,b){var c=a.getAttributeNode(b);return c&&c.specified?c.value:void 0},set:tb.set},n.attrHooks.contenteditable={set:function(a,b,c){tb.set(a,""===b?!1:b,c)}},n.each(["width","height"],function(a,b){n.attrHooks[b]={set:function(a,c){return""===c?(a.setAttribute(b,"auto"),c):void 0}}})),l.style||(n.attrHooks.style={get:function(a){return a.style.cssText||void 0},set:function(a,b){return a.style.cssText=b+""}});var zb=/^(?:input|select|textarea|button|object)$/i,Ab=/^(?:a|area)$/i;n.fn.extend({prop:function(a,b){return Y(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return a=n.propFix[a]||a,this.each(function(){try{this[a]=void 0,delete this[a]}catch(b){}})}}),n.extend({prop:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return 1===f&&n.isXMLDoc(a)||(b=n.propFix[b]||b,e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){var b=n.find.attr(a,"tabindex");return b?parseInt(b,10):zb.test(a.nodeName)||Ab.test(a.nodeName)&&a.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),l.hrefNormalized||n.each(["href","src"],function(a,b){n.propHooks[b]={get:function(a){return a.getAttribute(b,4)}}}),l.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex),null},set:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this}),l.enctype||(n.propFix.enctype="encoding");var Bb=/[\t\r\n\f]/g;function Cb(a){return n.attr(a,"class")||""}n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h,i=0;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,Cb(this)))});if("string"==typeof a&&a){b=a.match(G)||[];while(c=this[i++])if(e=Cb(c),d=1===c.nodeType&&(" "+e+" ").replace(Bb," ")){g=0;while(f=b[g++])d.indexOf(" "+f+" ")<0&&(d+=f+" ");h=n.trim(d),e!==h&&n.attr(c,"class",h)}}return this},removeClass:function(a){var b,c,d,e,f,g,h,i=0;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,Cb(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof a&&a){b=a.match(G)||[];while(c=this[i++])if(e=Cb(c),d=1===c.nodeType&&(" "+e+" ").replace(Bb," ")){g=0;while(f=b[g++])while(d.indexOf(" "+f+" ")>-1)d=d.replace(" "+f+" "," ");h=n.trim(d),e!==h&&n.attr(c,"class",h)}}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):n.isFunction(a)?this.each(function(c){n(this).toggleClass(a.call(this,c,Cb(this),b),b)}):this.each(function(){var b,d,e,f;if("string"===c){d=0,e=n(this),f=a.match(G)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else void 0!==a&&"boolean"!==c||(b=Cb(this),b&&n._data(this,"__className__",b),n.attr(this,"class",b||a===!1?"":n._data(this,"__className__")||""))})},hasClass:function(a){var b,c,d=0;b=" "+a+" ";while(c=this[d++])if(1===c.nodeType&&(" "+Cb(c)+" ").replace(Bb," ").indexOf(b)>-1)return!0;return!1}}),n.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});var Db=a.location,Eb=n.now(),Fb=/\?/,Gb=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;n.parseJSON=function(b){if(a.JSON&&a.JSON.parse)return a.JSON.parse(b+"");var c,d=null,e=n.trim(b+"");return e&&!n.trim(e.replace(Gb,function(a,b,e,f){return c&&b&&(d=0),0===d?a:(c=e||b,d+=!f-!e,"")}))?Function("return "+e)():n.error("Invalid JSON: "+b)},n.parseXML=function(b){var c,d;if(!b||"string"!=typeof b)return null;try{a.DOMParser?(d=new a.DOMParser,c=d.parseFromString(b,"text/xml")):(c=new a.ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b))}catch(e){c=void 0}return c&&c.documentElement&&!c.getElementsByTagName("parsererror").length||n.error("Invalid XML: "+b),c};var Hb=/#.*$/,Ib=/([?&])_=[^&]*/,Jb=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Kb=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Lb=/^(?:GET|HEAD)$/,Mb=/^\/\//,Nb=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,Ob={},Pb={},Qb="*/".concat("*"),Rb=Db.href,Sb=Nb.exec(Rb.toLowerCase())||[];function Tb(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(G)||[];if(n.isFunction(c))while(d=f[e++])"+"===d.charAt(0)?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function Ub(a,b,c,d){var e={},f=a===Pb;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function Vb(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(d in b)void 0!==b[d]&&((e[d]?a:c||(c={}))[d]=b[d]);return c&&n.extend(!0,a,c),a}function Wb(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===e&&(e=a.mimeType||b.getResponseHeader("Content-Type"));if(e)for(g in h)if(h[g]&&h[g].test(e)){i.unshift(g);break}if(i[0]in c)f=i[0];else{for(g in c){if(!i[0]||a.converters[g+" "+i[0]]){f=g;break}d||(d=g)}f=f||d}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function Xb(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Rb,type:"GET",isLocal:Kb.test(Sb[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Qb,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?Vb(Vb(a,n.ajaxSettings),b):Vb(n.ajaxSettings,a)},ajaxPrefilter:Tb(Ob),ajaxTransport:Tb(Pb),ajax:function(b,c){"object"==typeof b&&(c=b,b=void 0),c=c||{};var d,e,f,g,h,i,j,k,l=n.ajaxSetup({},c),m=l.context||l,o=l.context&&(m.nodeType||m.jquery)?n(m):n.event,p=n.Deferred(),q=n.Callbacks("once memory"),r=l.statusCode||{},s={},t={},u=0,v="canceled",w={readyState:0,getResponseHeader:function(a){var b;if(2===u){if(!k){k={};while(b=Jb.exec(g))k[b[1].toLowerCase()]=b[2]}b=k[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===u?g:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return u||(a=t[c]=t[c]||a,s[a]=b),this},overrideMimeType:function(a){return u||(l.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>u)for(b in a)r[b]=[r[b],a[b]];else w.always(a[w.status]);return this},abort:function(a){var b=a||v;return j&&j.abort(b),y(0,b),this}};if(p.promise(w).complete=q.add,w.success=w.done,w.error=w.fail,l.url=((b||l.url||Rb)+"").replace(Hb,"").replace(Mb,Sb[1]+"//"),l.type=c.method||c.type||l.method||l.type,l.dataTypes=n.trim(l.dataType||"*").toLowerCase().match(G)||[""],null==l.crossDomain&&(d=Nb.exec(l.url.toLowerCase()),l.crossDomain=!(!d||d[1]===Sb[1]&&d[2]===Sb[2]&&(d[3]||("http:"===d[1]?"80":"443"))===(Sb[3]||("http:"===Sb[1]?"80":"443")))),l.data&&l.processData&&"string"!=typeof l.data&&(l.data=n.param(l.data,l.traditional)),Ub(Ob,l,c,w),2===u)return w;i=n.event&&l.global,i&&0===n.active++&&n.event.trigger("ajaxStart"),l.type=l.type.toUpperCase(),l.hasContent=!Lb.test(l.type),f=l.url,l.hasContent||(l.data&&(f=l.url+=(Fb.test(f)?"&":"?")+l.data,delete l.data),l.cache===!1&&(l.url=Ib.test(f)?f.replace(Ib,"$1_="+Eb++):f+(Fb.test(f)?"&":"?")+"_="+Eb++)),l.ifModified&&(n.lastModified[f]&&w.setRequestHeader("If-Modified-Since",n.lastModified[f]),n.etag[f]&&w.setRequestHeader("If-None-Match",n.etag[f])),(l.data&&l.hasContent&&l.contentType!==!1||c.contentType)&&w.setRequestHeader("Content-Type",l.contentType),w.setRequestHeader("Accept",l.dataTypes[0]&&l.accepts[l.dataTypes[0]]?l.accepts[l.dataTypes[0]]+("*"!==l.dataTypes[0]?", "+Qb+"; q=0.01":""):l.accepts["*"]);for(e in l.headers)w.setRequestHeader(e,l.headers[e]);if(l.beforeSend&&(l.beforeSend.call(m,w,l)===!1||2===u))return w.abort();v="abort";for(e in{success:1,error:1,complete:1})w[e](l[e]);if(j=Ub(Pb,l,c,w)){if(w.readyState=1,i&&o.trigger("ajaxSend",[w,l]),2===u)return w;l.async&&l.timeout>0&&(h=a.setTimeout(function(){w.abort("timeout")},l.timeout));try{u=1,j.send(s,y)}catch(x){if(!(2>u))throw x;y(-1,x)}}else y(-1,"No Transport");function y(b,c,d,e){var k,s,t,v,x,y=c;2!==u&&(u=2,h&&a.clearTimeout(h),j=void 0,g=e||"",w.readyState=b>0?4:0,k=b>=200&&300>b||304===b,d&&(v=Wb(l,w,d)),v=Xb(l,v,w,k),k?(l.ifModified&&(x=w.getResponseHeader("Last-Modified"),x&&(n.lastModified[f]=x),x=w.getResponseHeader("etag"),x&&(n.etag[f]=x)),204===b||"HEAD"===l.type?y="nocontent":304===b?y="notmodified":(y=v.state,s=v.data,t=v.error,k=!t)):(t=y,!b&&y||(y="error",0>b&&(b=0))),w.status=b,w.statusText=(c||y)+"",k?p.resolveWith(m,[s,y,w]):p.rejectWith(m,[w,y,t]),w.statusCode(r),r=void 0,i&&o.trigger(k?"ajaxSuccess":"ajaxError",[w,l,k?s:t]),q.fireWith(m,[w,y]),i&&(o.trigger("ajaxComplete",[w,l]),--n.active||n.event.trigger("ajaxStop")))}return w},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax(n.extend({url:a,type:b,dataType:e,data:c,success:d},n.isPlainObject(a)&&a))}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,"throws":!0})},n.fn.extend({wrapAll:function(a){if(n.isFunction(a))return this.each(function(b){n(this).wrapAll(a.call(this,b))});if(this[0]){var b=n(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&1===a.firstChild.nodeType)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return n.isFunction(a)?this.each(function(b){n(this).wrapInner(a.call(this,b))}):this.each(function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}});function Yb(a){return a.style&&a.style.display||n.css(a,"display")}function Zb(a){while(a&&1===a.nodeType){if("none"===Yb(a)||"hidden"===a.type)return!0;a=a.parentNode}return!1}n.expr.filters.hidden=function(a){return l.reliableHiddenOffsets()?a.offsetWidth<=0&&a.offsetHeight<=0&&!a.getClientRects().length:Zb(a)},n.expr.filters.visible=function(a){return!n.expr.filters.hidden(a)};var $b=/%20/g,_b=/\[\]$/,ac=/\r?\n/g,bc=/^(?:submit|button|image|reset|file)$/i,cc=/^(?:input|select|textarea|keygen)/i;function dc(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||_b.test(a)?d(a,e):dc(a+"["+("object"==typeof e&&null!=e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)dc(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)dc(c,a[c],b,e);return d.join("&").replace($b,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&cc.test(this.nodeName)&&!bc.test(a)&&(this.checked||!Z.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(ac,"\r\n")}}):{name:b.name,value:c.replace(ac,"\r\n")}}).get()}}),n.ajaxSettings.xhr=void 0!==a.ActiveXObject?function(){return this.isLocal?ic():d.documentMode>8?hc():/^(get|post|head|put|delete|options)$/i.test(this.type)&&hc()||ic()}:hc;var ec=0,fc={},gc=n.ajaxSettings.xhr();a.attachEvent&&a.attachEvent("onunload",function(){for(var a in fc)fc[a](void 0,!0)}),l.cors=!!gc&&"withCredentials"in gc,gc=l.ajax=!!gc,gc&&n.ajaxTransport(function(b){if(!b.crossDomain||l.cors){var c;return{send:function(d,e){var f,g=b.xhr(),h=++ec;if(g.open(b.type,b.url,b.async,b.username,b.password),b.xhrFields)for(f in b.xhrFields)g[f]=b.xhrFields[f];b.mimeType&&g.overrideMimeType&&g.overrideMimeType(b.mimeType),b.crossDomain||d["X-Requested-With"]||(d["X-Requested-With"]="XMLHttpRequest");for(f in d)void 0!==d[f]&&g.setRequestHeader(f,d[f]+"");g.send(b.hasContent&&b.data||null),c=function(a,d){var f,i,j;if(c&&(d||4===g.readyState))if(delete fc[h],c=void 0,g.onreadystatechange=n.noop,d)4!==g.readyState&&g.abort();else{j={},f=g.status,"string"==typeof g.responseText&&(j.text=g.responseText);try{i=g.statusText}catch(k){i=""}f||!b.isLocal||b.crossDomain?1223===f&&(f=204):f=j.text?200:404}j&&e(f,i,j,g.getAllResponseHeaders())},b.async?4===g.readyState?a.setTimeout(c):g.onreadystatechange=fc[h]=c:c()},abort:function(){c&&c(void 0,!0)}}}});function hc(){try{return new a.XMLHttpRequest}catch(b){}}function ic(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c=d.head||n("head")[0]||d.documentElement;return{send:function(e,f){b=d.createElement("script"),b.async=!0,a.scriptCharset&&(b.charset=a.scriptCharset),b.src=a.url,b.onload=b.onreadystatechange=function(a,c){(c||!b.readyState||/loaded|complete/.test(b.readyState))&&(b.onload=b.onreadystatechange=null,b.parentNode&&b.parentNode.removeChild(b),b=null,c||f(200,"success"))},c.insertBefore(b,c.firstChild)},abort:function(){b&&b.onload(void 0,!0)}}}});var jc=[],kc=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=jc.pop()||n.expando+"_"+Eb++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(kc.test(b.url)?"url":"string"==typeof b.data&&0===(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&kc.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(kc,"$1"+e):b.jsonp!==!1&&(b.url+=(Fb.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){void 0===f?n(a).removeProp(e):a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,jc.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||d;var e=x.exec(a),f=!c&&[];return e?[b.createElement(e[1])]:(e=ja([a],b,f),f&&f.length&&n(f).remove(),n.merge([],e.childNodes))};var lc=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&lc)return lc.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>-1&&(d=n.trim(a.slice(h,a.length)),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&n.ajax({url:a,type:e||"GET",dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?n("<div>").append(n.parseHTML(a)).find(d):a)}).always(c&&function(a,b){g.each(function(){c.apply(this,f||[a.responseText,b,a])})}),this},n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};function mc(a){return n.isWindow(a)?a:9===a.nodeType?a.defaultView||a.parentWindow:!1}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&n.inArray("auto",[f,i])>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,n.extend({},h))),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d={top:0,left:0},e=this[0],f=e&&e.ownerDocument;if(f)return b=f.documentElement,n.contains(b,e)?("undefined"!=typeof e.getBoundingClientRect&&(d=e.getBoundingClientRect()),c=mc(f),{top:d.top+(c.pageYOffset||b.scrollTop)-(b.clientTop||0),left:d.left+(c.pageXOffset||b.scrollLeft)-(b.clientLeft||0)}):d},position:function(){if(this[0]){var a,b,c={top:0,left:0},d=this[0];return"fixed"===n.css(d,"position")?b=d.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(c=a.offset()),c.top+=n.css(a[0],"borderTopWidth",!0),c.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-c.top-n.css(d,"marginTop",!0),left:b.left-c.left-n.css(d,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent;while(a&&!n.nodeName(a,"html")&&"static"===n.css(a,"position"))a=a.offsetParent;return a||Qa})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,b){var c=/Y/.test(b);n.fn[a]=function(d){return Y(this,function(a,d,e){var f=mc(a);return void 0===e?f?b in f?f[b]:f.document.documentElement[d]:a[d]:void(f?f.scrollTo(c?n(f).scrollLeft():e,c?e:n(f).scrollTop()):a[d]=e)},a,d,arguments.length,null)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=Ua(l.pixelPosition,function(a,c){return c?(c=Sa(a,b),Oa.test(c)?n(a).position()[b]+"px":c):void 0;
|
5
|
-
})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return Y(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.extend({bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}}),n.fn.size=function(){return this.length},n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var nc=a.jQuery,oc=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=oc),b&&a.jQuery===n&&(a.jQuery=nc),n},b||(a.jQuery=a.$=n),n});
|
@@ -1,2098 +0,0 @@
|
|
1
|
-
/**!
|
2
|
-
* MixItUp v2.1.10
|
3
|
-
*
|
4
|
-
* @copyright Copyright 2015 KunkaLabs Limited.
|
5
|
-
* @author KunkaLabs Limited.
|
6
|
-
* @link https://mixitup.kunkalabs.com
|
7
|
-
*
|
8
|
-
* @license Commercial use requires a commercial license.
|
9
|
-
* https://mixitup.kunkalabs.com/licenses/
|
10
|
-
*
|
11
|
-
* Non-commercial use permitted under terms of CC-BY-NC license.
|
12
|
-
* http://creativecommons.org/licenses/by-nc/3.0/
|
13
|
-
*/
|
14
|
-
|
15
|
-
(function($, undf){
|
16
|
-
'use strict';
|
17
|
-
|
18
|
-
/**
|
19
|
-
* MixItUp Constructor Function
|
20
|
-
* @constructor
|
21
|
-
* @extends jQuery
|
22
|
-
*/
|
23
|
-
|
24
|
-
$.MixItUp = function(){
|
25
|
-
var self = this;
|
26
|
-
|
27
|
-
self._execAction('_constructor', 0);
|
28
|
-
|
29
|
-
$.extend(self, {
|
30
|
-
|
31
|
-
/* Public Properties
|
32
|
-
---------------------------------------------------------------------- */
|
33
|
-
|
34
|
-
selectors: {
|
35
|
-
target: '.mix',
|
36
|
-
filter: '.filter',
|
37
|
-
sort: '.sort'
|
38
|
-
},
|
39
|
-
|
40
|
-
animation: {
|
41
|
-
enable: true,
|
42
|
-
effects: 'fade scale',
|
43
|
-
duration: 600,
|
44
|
-
easing: 'ease',
|
45
|
-
perspectiveDistance: '3000',
|
46
|
-
perspectiveOrigin: '50% 50%',
|
47
|
-
queue: true,
|
48
|
-
queueLimit: 1,
|
49
|
-
animateChangeLayout: false,
|
50
|
-
animateResizeContainer: true,
|
51
|
-
animateResizeTargets: false,
|
52
|
-
staggerSequence: false,
|
53
|
-
reverseOut: false
|
54
|
-
},
|
55
|
-
|
56
|
-
callbacks: {
|
57
|
-
onMixLoad: false,
|
58
|
-
onMixStart: false,
|
59
|
-
onMixBusy: false,
|
60
|
-
onMixEnd: false,
|
61
|
-
onMixFail: false,
|
62
|
-
_user: false
|
63
|
-
},
|
64
|
-
|
65
|
-
controls: {
|
66
|
-
enable: true,
|
67
|
-
live: false,
|
68
|
-
toggleFilterButtons: false,
|
69
|
-
toggleLogic: 'or',
|
70
|
-
activeClass: 'active'
|
71
|
-
},
|
72
|
-
|
73
|
-
layout: {
|
74
|
-
display: 'inline-block',
|
75
|
-
containerClass: '',
|
76
|
-
containerClassFail: 'fail'
|
77
|
-
},
|
78
|
-
|
79
|
-
load: {
|
80
|
-
filter: 'all',
|
81
|
-
sort: false
|
82
|
-
},
|
83
|
-
|
84
|
-
/* Private Properties
|
85
|
-
---------------------------------------------------------------------- */
|
86
|
-
|
87
|
-
_$body: null,
|
88
|
-
_$container: null,
|
89
|
-
_$targets: null,
|
90
|
-
_$parent: null,
|
91
|
-
_$sortButtons: null,
|
92
|
-
_$filterButtons: null,
|
93
|
-
|
94
|
-
_suckMode: false,
|
95
|
-
_mixing: false,
|
96
|
-
_sorting: false,
|
97
|
-
_clicking: false,
|
98
|
-
_loading: true,
|
99
|
-
_changingLayout: false,
|
100
|
-
_changingClass: false,
|
101
|
-
_changingDisplay: false,
|
102
|
-
|
103
|
-
_origOrder: [],
|
104
|
-
_startOrder: [],
|
105
|
-
_newOrder: [],
|
106
|
-
_activeFilter: null,
|
107
|
-
_toggleArray: [],
|
108
|
-
_toggleString: '',
|
109
|
-
_activeSort: 'default:asc',
|
110
|
-
_newSort: null,
|
111
|
-
_startHeight: null,
|
112
|
-
_newHeight: null,
|
113
|
-
_incPadding: true,
|
114
|
-
_newDisplay: null,
|
115
|
-
_newClass: null,
|
116
|
-
_targetsBound: 0,
|
117
|
-
_targetsDone: 0,
|
118
|
-
_queue: [],
|
119
|
-
|
120
|
-
_$show: $(),
|
121
|
-
_$hide: $()
|
122
|
-
});
|
123
|
-
|
124
|
-
self._execAction('_constructor', 1);
|
125
|
-
};
|
126
|
-
|
127
|
-
/**
|
128
|
-
* MixItUp Prototype
|
129
|
-
* @override
|
130
|
-
*/
|
131
|
-
|
132
|
-
$.MixItUp.prototype = {
|
133
|
-
constructor: $.MixItUp,
|
134
|
-
|
135
|
-
/* Static Properties
|
136
|
-
---------------------------------------------------------------------- */
|
137
|
-
|
138
|
-
_instances: {},
|
139
|
-
_handled: {
|
140
|
-
_filter: {},
|
141
|
-
_sort: {}
|
142
|
-
},
|
143
|
-
_bound: {
|
144
|
-
_filter: {},
|
145
|
-
_sort: {}
|
146
|
-
},
|
147
|
-
_actions: {},
|
148
|
-
_filters: {},
|
149
|
-
|
150
|
-
/* Static Methods
|
151
|
-
---------------------------------------------------------------------- */
|
152
|
-
|
153
|
-
/**
|
154
|
-
* Extend
|
155
|
-
* @since 2.1.0
|
156
|
-
* @param {object} new properties/methods
|
157
|
-
* @extends {object} prototype
|
158
|
-
*/
|
159
|
-
|
160
|
-
extend: function(extension){
|
161
|
-
for(var key in extension){
|
162
|
-
$.MixItUp.prototype[key] = extension[key];
|
163
|
-
}
|
164
|
-
},
|
165
|
-
|
166
|
-
/**
|
167
|
-
* Add Action
|
168
|
-
* @since 2.1.0
|
169
|
-
* @param {string} hook name
|
170
|
-
* @param {string} namespace
|
171
|
-
* @param {function} function to execute
|
172
|
-
* @param {number} priority
|
173
|
-
* @extends {object} $.MixItUp.prototype._actions
|
174
|
-
*/
|
175
|
-
|
176
|
-
addAction: function(hook, name, func, priority){
|
177
|
-
$.MixItUp.prototype._addHook('_actions', hook, name, func, priority);
|
178
|
-
},
|
179
|
-
|
180
|
-
/**
|
181
|
-
* Add Filter
|
182
|
-
* @since 2.1.0
|
183
|
-
* @param {string} hook name
|
184
|
-
* @param {string} namespace
|
185
|
-
* @param {function} function to execute
|
186
|
-
* @param {number} priority
|
187
|
-
* @extends {object} $.MixItUp.prototype._filters
|
188
|
-
*/
|
189
|
-
|
190
|
-
addFilter: function(hook, name, func, priority){
|
191
|
-
$.MixItUp.prototype._addHook('_filters', hook, name, func, priority);
|
192
|
-
},
|
193
|
-
|
194
|
-
/**
|
195
|
-
* Add Hook
|
196
|
-
* @since 2.1.0
|
197
|
-
* @param {string} type of hook
|
198
|
-
* @param {string} hook name
|
199
|
-
* @param {function} function to execute
|
200
|
-
* @param {number} priority
|
201
|
-
* @extends {object} $.MixItUp.prototype._filters
|
202
|
-
*/
|
203
|
-
|
204
|
-
_addHook: function(type, hook, name, func, priority){
|
205
|
-
var collection = $.MixItUp.prototype[type],
|
206
|
-
obj = {};
|
207
|
-
|
208
|
-
priority = (priority === 1 || priority === 'post') ? 'post' : 'pre';
|
209
|
-
|
210
|
-
obj[hook] = {};
|
211
|
-
obj[hook][priority] = {};
|
212
|
-
obj[hook][priority][name] = func;
|
213
|
-
|
214
|
-
$.extend(true, collection, obj);
|
215
|
-
},
|
216
|
-
|
217
|
-
|
218
|
-
/* Private Methods
|
219
|
-
---------------------------------------------------------------------- */
|
220
|
-
|
221
|
-
/**
|
222
|
-
* Initialise
|
223
|
-
* @since 2.0.0
|
224
|
-
* @param {object} domNode
|
225
|
-
* @param {object} config
|
226
|
-
*/
|
227
|
-
|
228
|
-
_init: function(domNode, config){
|
229
|
-
var self = this;
|
230
|
-
|
231
|
-
self._execAction('_init', 0, arguments);
|
232
|
-
|
233
|
-
config && $.extend(true, self, config);
|
234
|
-
|
235
|
-
self._$body = $('body');
|
236
|
-
self._domNode = domNode;
|
237
|
-
self._$container = $(domNode);
|
238
|
-
self._$container.addClass(self.layout.containerClass);
|
239
|
-
self._id = domNode.id;
|
240
|
-
|
241
|
-
self._platformDetect();
|
242
|
-
|
243
|
-
self._brake = self._getPrefixedCSS('transition', 'none');
|
244
|
-
|
245
|
-
self._refresh(true);
|
246
|
-
|
247
|
-
self._$parent = self._$targets.parent().length ? self._$targets.parent() : self._$container;
|
248
|
-
|
249
|
-
if(self.load.sort){
|
250
|
-
self._newSort = self._parseSort(self.load.sort);
|
251
|
-
self._newSortString = self.load.sort;
|
252
|
-
self._activeSort = self.load.sort;
|
253
|
-
self._sort();
|
254
|
-
self._printSort();
|
255
|
-
}
|
256
|
-
|
257
|
-
self._activeFilter = self.load.filter === 'all' ?
|
258
|
-
self.selectors.target :
|
259
|
-
self.load.filter === 'none' ?
|
260
|
-
'' :
|
261
|
-
self.load.filter;
|
262
|
-
|
263
|
-
self.controls.enable && self._bindHandlers();
|
264
|
-
|
265
|
-
if(self.controls.toggleFilterButtons){
|
266
|
-
self._buildToggleArray();
|
267
|
-
|
268
|
-
for(var i = 0; i < self._toggleArray.length; i++){
|
269
|
-
self._updateControls({filter: self._toggleArray[i], sort: self._activeSort}, true);
|
270
|
-
};
|
271
|
-
} else if(self.controls.enable){
|
272
|
-
self._updateControls({filter: self._activeFilter, sort: self._activeSort});
|
273
|
-
}
|
274
|
-
|
275
|
-
self._filter();
|
276
|
-
|
277
|
-
self._init = true;
|
278
|
-
|
279
|
-
self._$container.data('mixItUp',self);
|
280
|
-
|
281
|
-
self._execAction('_init', 1, arguments);
|
282
|
-
|
283
|
-
self._buildState();
|
284
|
-
|
285
|
-
self._$targets.css(self._brake);
|
286
|
-
|
287
|
-
self._goMix(self.animation.enable);
|
288
|
-
},
|
289
|
-
|
290
|
-
/**
|
291
|
-
* Platform Detect
|
292
|
-
* @since 2.0.0
|
293
|
-
*/
|
294
|
-
|
295
|
-
_platformDetect: function(){
|
296
|
-
var self = this,
|
297
|
-
vendorsTrans = ['Webkit', 'Moz', 'O', 'ms'],
|
298
|
-
vendorsRAF = ['webkit', 'moz'],
|
299
|
-
chrome = window.navigator.appVersion.match(/Chrome\/(\d+)\./) || false,
|
300
|
-
ff = typeof InstallTrigger !== 'undefined',
|
301
|
-
prefix = function(el){
|
302
|
-
for (var i = 0; i < vendorsTrans.length; i++){
|
303
|
-
if (vendorsTrans[i] + 'Transition' in el.style){
|
304
|
-
return {
|
305
|
-
prefix: '-'+vendorsTrans[i].toLowerCase()+'-',
|
306
|
-
vendor: vendorsTrans[i]
|
307
|
-
};
|
308
|
-
};
|
309
|
-
};
|
310
|
-
return 'transition' in el.style ? '' : false;
|
311
|
-
},
|
312
|
-
transPrefix = prefix(self._domNode);
|
313
|
-
|
314
|
-
self._execAction('_platformDetect', 0);
|
315
|
-
|
316
|
-
self._chrome = chrome ? parseInt(chrome[1], 10) : false;
|
317
|
-
self._ff = ff ? parseInt(window.navigator.userAgent.match(/rv:([^)]+)\)/)[1]) : false;
|
318
|
-
self._prefix = transPrefix.prefix;
|
319
|
-
self._vendor = transPrefix.vendor;
|
320
|
-
self._suckMode = window.atob && self._prefix ? false : true;
|
321
|
-
|
322
|
-
self._suckMode && (self.animation.enable = false);
|
323
|
-
(self._ff && self._ff <= 4) && (self.animation.enable = false);
|
324
|
-
|
325
|
-
/* Polyfills
|
326
|
-
---------------------------------------------------------------------- */
|
327
|
-
|
328
|
-
/**
|
329
|
-
* window.requestAnimationFrame
|
330
|
-
*/
|
331
|
-
|
332
|
-
for(var x = 0; x < vendorsRAF.length && !window.requestAnimationFrame; x++){
|
333
|
-
window.requestAnimationFrame = window[vendorsRAF[x]+'RequestAnimationFrame'];
|
334
|
-
}
|
335
|
-
|
336
|
-
/**
|
337
|
-
* Object.getPrototypeOf
|
338
|
-
*/
|
339
|
-
|
340
|
-
if(typeof Object.getPrototypeOf !== 'function'){
|
341
|
-
if(typeof 'test'.__proto__ === 'object'){
|
342
|
-
Object.getPrototypeOf = function(object){
|
343
|
-
return object.__proto__;
|
344
|
-
};
|
345
|
-
} else {
|
346
|
-
Object.getPrototypeOf = function(object){
|
347
|
-
return object.constructor.prototype;
|
348
|
-
};
|
349
|
-
}
|
350
|
-
}
|
351
|
-
|
352
|
-
/**
|
353
|
-
* Element.nextElementSibling
|
354
|
-
*/
|
355
|
-
|
356
|
-
if(self._domNode.nextElementSibling === undf){
|
357
|
-
Object.defineProperty(Element.prototype, 'nextElementSibling',{
|
358
|
-
get: function(){
|
359
|
-
var el = this.nextSibling;
|
360
|
-
|
361
|
-
while(el){
|
362
|
-
if(el.nodeType ===1){
|
363
|
-
return el;
|
364
|
-
}
|
365
|
-
el = el.nextSibling;
|
366
|
-
}
|
367
|
-
return null;
|
368
|
-
}
|
369
|
-
});
|
370
|
-
}
|
371
|
-
|
372
|
-
self._execAction('_platformDetect', 1);
|
373
|
-
},
|
374
|
-
|
375
|
-
/**
|
376
|
-
* Refresh
|
377
|
-
* @since 2.0.0
|
378
|
-
* @param {boolean} init
|
379
|
-
* @param {boolean} force
|
380
|
-
*/
|
381
|
-
|
382
|
-
_refresh: function(init, force){
|
383
|
-
var self = this;
|
384
|
-
|
385
|
-
self._execAction('_refresh', 0, arguments);
|
386
|
-
|
387
|
-
self._$targets = self._$container.find(self.selectors.target);
|
388
|
-
|
389
|
-
for(var i = 0; i < self._$targets.length; i++){
|
390
|
-
var target = self._$targets[i];
|
391
|
-
|
392
|
-
if(target.dataset === undf || force){
|
393
|
-
|
394
|
-
target.dataset = {};
|
395
|
-
|
396
|
-
for(var j = 0; j < target.attributes.length; j++){
|
397
|
-
|
398
|
-
var attr = target.attributes[j],
|
399
|
-
name = attr.name,
|
400
|
-
val = attr.value;
|
401
|
-
|
402
|
-
if(name.indexOf('data-') > -1){
|
403
|
-
var dataName = self._helpers._camelCase(name.substring(5,name.length));
|
404
|
-
target.dataset[dataName] = val;
|
405
|
-
}
|
406
|
-
}
|
407
|
-
}
|
408
|
-
|
409
|
-
if(target.mixParent === undf){
|
410
|
-
target.mixParent = self._id;
|
411
|
-
}
|
412
|
-
}
|
413
|
-
|
414
|
-
if(
|
415
|
-
(self._$targets.length && init) ||
|
416
|
-
(!self._origOrder.length && self._$targets.length)
|
417
|
-
){
|
418
|
-
self._origOrder = [];
|
419
|
-
|
420
|
-
for(var i = 0; i < self._$targets.length; i++){
|
421
|
-
var target = self._$targets[i];
|
422
|
-
|
423
|
-
self._origOrder.push(target);
|
424
|
-
}
|
425
|
-
}
|
426
|
-
|
427
|
-
self._execAction('_refresh', 1, arguments);
|
428
|
-
},
|
429
|
-
|
430
|
-
/**
|
431
|
-
* Bind Handlers
|
432
|
-
* @since 2.0.0
|
433
|
-
*/
|
434
|
-
|
435
|
-
_bindHandlers: function(){
|
436
|
-
var self = this,
|
437
|
-
filters = $.MixItUp.prototype._bound._filter,
|
438
|
-
sorts = $.MixItUp.prototype._bound._sort;
|
439
|
-
|
440
|
-
self._execAction('_bindHandlers', 0);
|
441
|
-
|
442
|
-
if(self.controls.live){
|
443
|
-
self._$body
|
444
|
-
.on('click.mixItUp.'+self._id, self.selectors.sort, function(){
|
445
|
-
self._processClick($(this), 'sort');
|
446
|
-
})
|
447
|
-
.on('click.mixItUp.'+self._id, self.selectors.filter, function(){
|
448
|
-
self._processClick($(this), 'filter');
|
449
|
-
});
|
450
|
-
} else {
|
451
|
-
self._$sortButtons = $(self.selectors.sort);
|
452
|
-
self._$filterButtons = $(self.selectors.filter);
|
453
|
-
|
454
|
-
self._$sortButtons.on('click.mixItUp.'+self._id, function(){
|
455
|
-
self._processClick($(this), 'sort');
|
456
|
-
});
|
457
|
-
|
458
|
-
self._$filterButtons.on('click.mixItUp.'+self._id, function(){
|
459
|
-
self._processClick($(this), 'filter');
|
460
|
-
});
|
461
|
-
}
|
462
|
-
|
463
|
-
filters[self.selectors.filter] = (filters[self.selectors.filter] === undf) ? 1 : filters[self.selectors.filter] + 1;
|
464
|
-
sorts[self.selectors.sort] = (sorts[self.selectors.sort] === undf) ? 1 : sorts[self.selectors.sort] + 1;
|
465
|
-
|
466
|
-
self._execAction('_bindHandlers', 1);
|
467
|
-
},
|
468
|
-
|
469
|
-
/**
|
470
|
-
* Process Click
|
471
|
-
* @since 2.0.0
|
472
|
-
* @param {object} $button
|
473
|
-
* @param {string} type
|
474
|
-
*/
|
475
|
-
|
476
|
-
_processClick: function($button, type){
|
477
|
-
var self = this,
|
478
|
-
trackClick = function($button, type, off){
|
479
|
-
var proto = $.MixItUp.prototype;
|
480
|
-
|
481
|
-
proto._handled['_'+type][self.selectors[type]] = (proto._handled['_'+type][self.selectors[type]] === undf) ?
|
482
|
-
1 :
|
483
|
-
proto._handled['_'+type][self.selectors[type]] + 1;
|
484
|
-
|
485
|
-
if(proto._handled['_'+type][self.selectors[type]] === proto._bound['_'+type][self.selectors[type]]){
|
486
|
-
$button[(off ? 'remove' : 'add')+'Class'](self.controls.activeClass);
|
487
|
-
delete proto._handled['_'+type][self.selectors[type]];
|
488
|
-
}
|
489
|
-
};
|
490
|
-
|
491
|
-
self._execAction('_processClick', 0, arguments);
|
492
|
-
|
493
|
-
if(!self._mixing || (self.animation.queue && self._queue.length < self.animation.queueLimit)){
|
494
|
-
self._clicking = true;
|
495
|
-
|
496
|
-
if(type === 'sort'){
|
497
|
-
var sort = $button.attr('data-sort');
|
498
|
-
|
499
|
-
if(!$button.hasClass(self.controls.activeClass) || sort.indexOf('random') > -1){
|
500
|
-
$(self.selectors.sort).removeClass(self.controls.activeClass);
|
501
|
-
trackClick($button, type);
|
502
|
-
self.sort(sort);
|
503
|
-
}
|
504
|
-
}
|
505
|
-
|
506
|
-
if(type === 'filter') {
|
507
|
-
var filter = $button.attr('data-filter'),
|
508
|
-
ndx,
|
509
|
-
seperator = self.controls.toggleLogic === 'or' ? ',' : '';
|
510
|
-
|
511
|
-
if(!self.controls.toggleFilterButtons){
|
512
|
-
if(!$button.hasClass(self.controls.activeClass)){
|
513
|
-
$(self.selectors.filter).removeClass(self.controls.activeClass);
|
514
|
-
trackClick($button, type);
|
515
|
-
self.filter(filter);
|
516
|
-
}
|
517
|
-
} else {
|
518
|
-
self._buildToggleArray();
|
519
|
-
|
520
|
-
if(!$button.hasClass(self.controls.activeClass)){
|
521
|
-
trackClick($button, type);
|
522
|
-
|
523
|
-
self._toggleArray.push(filter);
|
524
|
-
} else {
|
525
|
-
trackClick($button, type, true);
|
526
|
-
ndx = self._toggleArray.indexOf(filter);
|
527
|
-
self._toggleArray.splice(ndx, 1);
|
528
|
-
}
|
529
|
-
|
530
|
-
self._toggleArray = $.grep(self._toggleArray,function(n){return(n);});
|
531
|
-
|
532
|
-
self._toggleString = self._toggleArray.join(seperator);
|
533
|
-
|
534
|
-
self.filter(self._toggleString);
|
535
|
-
}
|
536
|
-
}
|
537
|
-
|
538
|
-
self._execAction('_processClick', 1, arguments);
|
539
|
-
} else {
|
540
|
-
if(typeof self.callbacks.onMixBusy === 'function'){
|
541
|
-
self.callbacks.onMixBusy.call(self._domNode, self._state, self);
|
542
|
-
}
|
543
|
-
self._execAction('_processClickBusy', 1, arguments);
|
544
|
-
}
|
545
|
-
},
|
546
|
-
|
547
|
-
/**
|
548
|
-
* Build Toggle Array
|
549
|
-
* @since 2.0.0
|
550
|
-
*/
|
551
|
-
|
552
|
-
_buildToggleArray: function(){
|
553
|
-
var self = this,
|
554
|
-
activeFilter = self._activeFilter.replace(/\s/g, '');
|
555
|
-
|
556
|
-
self._execAction('_buildToggleArray', 0, arguments);
|
557
|
-
|
558
|
-
if(self.controls.toggleLogic === 'or'){
|
559
|
-
self._toggleArray = activeFilter.split(',');
|
560
|
-
} else {
|
561
|
-
self._toggleArray = activeFilter.split('.');
|
562
|
-
|
563
|
-
!self._toggleArray[0] && self._toggleArray.shift();
|
564
|
-
|
565
|
-
for(var i = 0, filter; filter = self._toggleArray[i]; i++){
|
566
|
-
self._toggleArray[i] = '.'+filter;
|
567
|
-
}
|
568
|
-
}
|
569
|
-
|
570
|
-
self._execAction('_buildToggleArray', 1, arguments);
|
571
|
-
},
|
572
|
-
|
573
|
-
/**
|
574
|
-
* Update Controls
|
575
|
-
* @since 2.0.0
|
576
|
-
* @param {object} command
|
577
|
-
* @param {boolean} multi
|
578
|
-
*/
|
579
|
-
|
580
|
-
_updateControls: function(command, multi){
|
581
|
-
var self = this,
|
582
|
-
output = {
|
583
|
-
filter: command.filter,
|
584
|
-
sort: command.sort
|
585
|
-
},
|
586
|
-
update = function($el, filter){
|
587
|
-
try {
|
588
|
-
(multi && type === 'filter' && !(output.filter === 'none' || output.filter === '')) ?
|
589
|
-
$el.filter(filter).addClass(self.controls.activeClass) :
|
590
|
-
$el.removeClass(self.controls.activeClass).filter(filter).addClass(self.controls.activeClass);
|
591
|
-
} catch(e) {}
|
592
|
-
},
|
593
|
-
type = 'filter',
|
594
|
-
$el = null;
|
595
|
-
|
596
|
-
self._execAction('_updateControls', 0, arguments);
|
597
|
-
|
598
|
-
(command.filter === undf) && (output.filter = self._activeFilter);
|
599
|
-
(command.sort === undf) && (output.sort = self._activeSort);
|
600
|
-
(output.filter === self.selectors.target) && (output.filter = 'all');
|
601
|
-
|
602
|
-
for(var i = 0; i < 2; i++){
|
603
|
-
$el = self.controls.live ? $(self.selectors[type]) : self['_$'+type+'Buttons'];
|
604
|
-
$el && update($el, '[data-'+type+'="'+output[type]+'"]');
|
605
|
-
type = 'sort';
|
606
|
-
}
|
607
|
-
|
608
|
-
self._execAction('_updateControls', 1, arguments);
|
609
|
-
},
|
610
|
-
|
611
|
-
/**
|
612
|
-
* Filter (private)
|
613
|
-
* @since 2.0.0
|
614
|
-
*/
|
615
|
-
|
616
|
-
_filter: function(){
|
617
|
-
var self = this;
|
618
|
-
|
619
|
-
self._execAction('_filter', 0);
|
620
|
-
|
621
|
-
for(var i = 0; i < self._$targets.length; i++){
|
622
|
-
var $target = $(self._$targets[i]);
|
623
|
-
|
624
|
-
if($target.is(self._activeFilter)){
|
625
|
-
self._$show = self._$show.add($target);
|
626
|
-
} else {
|
627
|
-
self._$hide = self._$hide.add($target);
|
628
|
-
}
|
629
|
-
}
|
630
|
-
|
631
|
-
self._execAction('_filter', 1);
|
632
|
-
},
|
633
|
-
|
634
|
-
/**
|
635
|
-
* Sort (private)
|
636
|
-
* @since 2.0.0
|
637
|
-
*/
|
638
|
-
|
639
|
-
_sort: function(){
|
640
|
-
var self = this,
|
641
|
-
arrayShuffle = function(oldArray){
|
642
|
-
var newArray = oldArray.slice(),
|
643
|
-
len = newArray.length,
|
644
|
-
i = len;
|
645
|
-
|
646
|
-
while(i--){
|
647
|
-
var p = parseInt(Math.random()*len);
|
648
|
-
var t = newArray[i];
|
649
|
-
newArray[i] = newArray[p];
|
650
|
-
newArray[p] = t;
|
651
|
-
};
|
652
|
-
return newArray;
|
653
|
-
};
|
654
|
-
|
655
|
-
self._execAction('_sort', 0);
|
656
|
-
|
657
|
-
self._startOrder = [];
|
658
|
-
|
659
|
-
for(var i = 0; i < self._$targets.length; i++){
|
660
|
-
var target = self._$targets[i];
|
661
|
-
|
662
|
-
self._startOrder.push(target);
|
663
|
-
}
|
664
|
-
|
665
|
-
switch(self._newSort[0].sortBy){
|
666
|
-
case 'default':
|
667
|
-
self._newOrder = self._origOrder;
|
668
|
-
break;
|
669
|
-
case 'random':
|
670
|
-
self._newOrder = arrayShuffle(self._startOrder);
|
671
|
-
break;
|
672
|
-
case 'custom':
|
673
|
-
self._newOrder = self._newSort[0].order;
|
674
|
-
break;
|
675
|
-
default:
|
676
|
-
self._newOrder = self._startOrder.concat().sort(function(a, b){
|
677
|
-
return self._compare(a, b);
|
678
|
-
});
|
679
|
-
}
|
680
|
-
|
681
|
-
self._execAction('_sort', 1);
|
682
|
-
},
|
683
|
-
|
684
|
-
/**
|
685
|
-
* Compare Algorithm
|
686
|
-
* @since 2.0.0
|
687
|
-
* @param {string|number} a
|
688
|
-
* @param {string|number} b
|
689
|
-
* @param {number} depth (recursion)
|
690
|
-
* @return {number}
|
691
|
-
*/
|
692
|
-
|
693
|
-
_compare: function(a, b, depth){
|
694
|
-
depth = depth ? depth : 0;
|
695
|
-
|
696
|
-
var self = this,
|
697
|
-
order = self._newSort[depth].order,
|
698
|
-
getData = function(el){
|
699
|
-
return el.dataset[self._newSort[depth].sortBy] || 0;
|
700
|
-
},
|
701
|
-
attrA = isNaN(getData(a) * 1) ? getData(a).toLowerCase() : getData(a) * 1,
|
702
|
-
attrB = isNaN(getData(b) * 1) ? getData(b).toLowerCase() : getData(b) * 1;
|
703
|
-
|
704
|
-
if(attrA < attrB)
|
705
|
-
return order === 'asc' ? -1 : 1;
|
706
|
-
if(attrA > attrB)
|
707
|
-
return order === 'asc' ? 1 : -1;
|
708
|
-
if(attrA === attrB && self._newSort.length > depth+1)
|
709
|
-
return self._compare(a, b, depth+1);
|
710
|
-
|
711
|
-
return 0;
|
712
|
-
},
|
713
|
-
|
714
|
-
/**
|
715
|
-
* Print Sort
|
716
|
-
* @since 2.0.0
|
717
|
-
* @param {boolean} reset
|
718
|
-
*/
|
719
|
-
|
720
|
-
_printSort: function(reset){
|
721
|
-
var self = this,
|
722
|
-
order = reset ? self._startOrder : self._newOrder,
|
723
|
-
targets = self._$parent[0].querySelectorAll(self.selectors.target),
|
724
|
-
nextSibling = targets.length ? targets[targets.length -1].nextElementSibling : null,
|
725
|
-
frag = document.createDocumentFragment();
|
726
|
-
|
727
|
-
self._execAction('_printSort', 0, arguments);
|
728
|
-
|
729
|
-
for(var i = 0; i < targets.length; i++){
|
730
|
-
var target = targets[i],
|
731
|
-
whiteSpace = target.nextSibling;
|
732
|
-
|
733
|
-
if(target.style.position === 'absolute') continue;
|
734
|
-
|
735
|
-
if(whiteSpace && whiteSpace.nodeName === '#text'){
|
736
|
-
self._$parent[0].removeChild(whiteSpace);
|
737
|
-
}
|
738
|
-
|
739
|
-
self._$parent[0].removeChild(target);
|
740
|
-
}
|
741
|
-
|
742
|
-
for(var i = 0; i < order.length; i++){
|
743
|
-
var el = order[i];
|
744
|
-
|
745
|
-
if(self._newSort[0].sortBy === 'default' && self._newSort[0].order === 'desc' && !reset){
|
746
|
-
var firstChild = frag.firstChild;
|
747
|
-
frag.insertBefore(el, firstChild);
|
748
|
-
frag.insertBefore(document.createTextNode(' '), el);
|
749
|
-
} else {
|
750
|
-
frag.appendChild(el);
|
751
|
-
frag.appendChild(document.createTextNode(' '));
|
752
|
-
}
|
753
|
-
}
|
754
|
-
|
755
|
-
nextSibling ?
|
756
|
-
self._$parent[0].insertBefore(frag, nextSibling) :
|
757
|
-
self._$parent[0].appendChild(frag);
|
758
|
-
|
759
|
-
self._execAction('_printSort', 1, arguments);
|
760
|
-
},
|
761
|
-
|
762
|
-
/**
|
763
|
-
* Parse Sort
|
764
|
-
* @since 2.0.0
|
765
|
-
* @param {string} sortString
|
766
|
-
* @return {array} newSort
|
767
|
-
*/
|
768
|
-
|
769
|
-
_parseSort: function(sortString){
|
770
|
-
var self = this,
|
771
|
-
rules = typeof sortString === 'string' ? sortString.split(' ') : [sortString],
|
772
|
-
newSort = [];
|
773
|
-
|
774
|
-
for(var i = 0; i < rules.length; i++){
|
775
|
-
var rule = typeof sortString === 'string' ? rules[i].split(':') : ['custom', rules[i]],
|
776
|
-
ruleObj = {
|
777
|
-
sortBy: self._helpers._camelCase(rule[0]),
|
778
|
-
order: rule[1] || 'asc'
|
779
|
-
};
|
780
|
-
|
781
|
-
newSort.push(ruleObj);
|
782
|
-
|
783
|
-
if(ruleObj.sortBy === 'default' || ruleObj.sortBy === 'random') break;
|
784
|
-
}
|
785
|
-
|
786
|
-
return self._execFilter('_parseSort', newSort, arguments);
|
787
|
-
},
|
788
|
-
|
789
|
-
/**
|
790
|
-
* Parse Effects
|
791
|
-
* @since 2.0.0
|
792
|
-
* @return {object} effects
|
793
|
-
*/
|
794
|
-
|
795
|
-
_parseEffects: function(){
|
796
|
-
var self = this,
|
797
|
-
effects = {
|
798
|
-
opacity: '',
|
799
|
-
transformIn: '',
|
800
|
-
transformOut: '',
|
801
|
-
filter: ''
|
802
|
-
},
|
803
|
-
parse = function(effect, extract, reverse){
|
804
|
-
if(self.animation.effects.indexOf(effect) > -1){
|
805
|
-
if(extract){
|
806
|
-
var propIndex = self.animation.effects.indexOf(effect+'(');
|
807
|
-
if(propIndex > -1){
|
808
|
-
var str = self.animation.effects.substring(propIndex),
|
809
|
-
match = /\(([^)]+)\)/.exec(str),
|
810
|
-
val = match[1];
|
811
|
-
|
812
|
-
return {val: val};
|
813
|
-
}
|
814
|
-
}
|
815
|
-
return true;
|
816
|
-
} else {
|
817
|
-
return false;
|
818
|
-
}
|
819
|
-
},
|
820
|
-
negate = function(value, invert){
|
821
|
-
if(invert){
|
822
|
-
return value.charAt(0) === '-' ? value.substr(1, value.length) : '-'+value;
|
823
|
-
} else {
|
824
|
-
return value;
|
825
|
-
}
|
826
|
-
},
|
827
|
-
buildTransform = function(key, invert){
|
828
|
-
var transforms = [
|
829
|
-
['scale', '.01'],
|
830
|
-
['translateX', '20px'],
|
831
|
-
['translateY', '20px'],
|
832
|
-
['translateZ', '20px'],
|
833
|
-
['rotateX', '90deg'],
|
834
|
-
['rotateY', '90deg'],
|
835
|
-
['rotateZ', '180deg'],
|
836
|
-
];
|
837
|
-
|
838
|
-
for(var i = 0; i < transforms.length; i++){
|
839
|
-
var prop = transforms[i][0],
|
840
|
-
def = transforms[i][1],
|
841
|
-
inverted = invert && prop !== 'scale';
|
842
|
-
|
843
|
-
effects[key] += parse(prop) ? prop+'('+negate(parse(prop, true).val || def, inverted)+') ' : '';
|
844
|
-
}
|
845
|
-
};
|
846
|
-
|
847
|
-
effects.opacity = parse('fade') ? parse('fade',true).val || '0' : '1';
|
848
|
-
|
849
|
-
buildTransform('transformIn');
|
850
|
-
|
851
|
-
self.animation.reverseOut ? buildTransform('transformOut', true) : (effects.transformOut = effects.transformIn);
|
852
|
-
|
853
|
-
effects.transition = {};
|
854
|
-
|
855
|
-
effects.transition = self._getPrefixedCSS('transition','all '+self.animation.duration+'ms '+self.animation.easing+', opacity '+self.animation.duration+'ms linear');
|
856
|
-
|
857
|
-
self.animation.stagger = parse('stagger') ? true : false;
|
858
|
-
self.animation.staggerDuration = parseInt(parse('stagger') ? (parse('stagger',true).val ? parse('stagger',true).val : 100) : 100);
|
859
|
-
|
860
|
-
return self._execFilter('_parseEffects', effects);
|
861
|
-
},
|
862
|
-
|
863
|
-
/**
|
864
|
-
* Build State
|
865
|
-
* @since 2.0.0
|
866
|
-
* @param {boolean} future
|
867
|
-
* @return {object} futureState
|
868
|
-
*/
|
869
|
-
|
870
|
-
_buildState: function(future){
|
871
|
-
var self = this,
|
872
|
-
state = {};
|
873
|
-
|
874
|
-
self._execAction('_buildState', 0);
|
875
|
-
|
876
|
-
state = {
|
877
|
-
activeFilter: self._activeFilter === '' ? 'none' : self._activeFilter,
|
878
|
-
activeSort: future && self._newSortString ? self._newSortString : self._activeSort,
|
879
|
-
fail: !self._$show.length && self._activeFilter !== '',
|
880
|
-
$targets: self._$targets,
|
881
|
-
$show: self._$show,
|
882
|
-
$hide: self._$hide,
|
883
|
-
totalTargets: self._$targets.length,
|
884
|
-
totalShow: self._$show.length,
|
885
|
-
totalHide: self._$hide.length,
|
886
|
-
display: future && self._newDisplay ? self._newDisplay : self.layout.display
|
887
|
-
};
|
888
|
-
|
889
|
-
if(future){
|
890
|
-
return self._execFilter('_buildState', state);
|
891
|
-
} else {
|
892
|
-
self._state = state;
|
893
|
-
|
894
|
-
self._execAction('_buildState', 1);
|
895
|
-
}
|
896
|
-
},
|
897
|
-
|
898
|
-
/**
|
899
|
-
* Go Mix
|
900
|
-
* @since 2.0.0
|
901
|
-
* @param {boolean} animate
|
902
|
-
*/
|
903
|
-
|
904
|
-
_goMix: function(animate){
|
905
|
-
var self = this,
|
906
|
-
phase1 = function(){
|
907
|
-
if(self._chrome && (self._chrome === 31)){
|
908
|
-
chromeFix(self._$parent[0]);
|
909
|
-
}
|
910
|
-
|
911
|
-
self._setInter();
|
912
|
-
|
913
|
-
phase2();
|
914
|
-
},
|
915
|
-
phase2 = function(){
|
916
|
-
var scrollTop = window.pageYOffset,
|
917
|
-
scrollLeft = window.pageXOffset,
|
918
|
-
docHeight = document.documentElement.scrollHeight;
|
919
|
-
|
920
|
-
self._getInterMixData();
|
921
|
-
|
922
|
-
self._setFinal();
|
923
|
-
|
924
|
-
self._getFinalMixData();
|
925
|
-
|
926
|
-
(window.pageYOffset !== scrollTop) && window.scrollTo(scrollLeft, scrollTop);
|
927
|
-
|
928
|
-
self._prepTargets();
|
929
|
-
|
930
|
-
if(window.requestAnimationFrame){
|
931
|
-
requestAnimationFrame(phase3);
|
932
|
-
} else {
|
933
|
-
setTimeout(function(){
|
934
|
-
phase3();
|
935
|
-
},20);
|
936
|
-
}
|
937
|
-
},
|
938
|
-
phase3 = function(){
|
939
|
-
self._animateTargets();
|
940
|
-
|
941
|
-
if(self._targetsBound === 0){
|
942
|
-
self._cleanUp();
|
943
|
-
}
|
944
|
-
},
|
945
|
-
chromeFix = function(grid){
|
946
|
-
var parent = grid.parentElement,
|
947
|
-
placeholder = document.createElement('div'),
|
948
|
-
frag = document.createDocumentFragment();
|
949
|
-
|
950
|
-
parent.insertBefore(placeholder, grid);
|
951
|
-
frag.appendChild(grid);
|
952
|
-
parent.replaceChild(grid, placeholder);
|
953
|
-
},
|
954
|
-
futureState = self._buildState(true);
|
955
|
-
|
956
|
-
self._execAction('_goMix', 0, arguments);
|
957
|
-
|
958
|
-
!self.animation.duration && (animate = false);
|
959
|
-
|
960
|
-
self._mixing = true;
|
961
|
-
|
962
|
-
self._$container.removeClass(self.layout.containerClassFail);
|
963
|
-
|
964
|
-
if(typeof self.callbacks.onMixStart === 'function'){
|
965
|
-
self.callbacks.onMixStart.call(self._domNode, self._state, futureState, self);
|
966
|
-
}
|
967
|
-
|
968
|
-
self._$container.trigger('mixStart', [self._state, futureState, self]);
|
969
|
-
|
970
|
-
self._getOrigMixData();
|
971
|
-
|
972
|
-
if(animate && !self._suckMode){
|
973
|
-
|
974
|
-
window.requestAnimationFrame ?
|
975
|
-
requestAnimationFrame(phase1) :
|
976
|
-
phase1();
|
977
|
-
|
978
|
-
} else {
|
979
|
-
self._cleanUp();
|
980
|
-
}
|
981
|
-
|
982
|
-
self._execAction('_goMix', 1, arguments);
|
983
|
-
},
|
984
|
-
|
985
|
-
/**
|
986
|
-
* Get Target Data
|
987
|
-
* @since 2.0.0
|
988
|
-
*/
|
989
|
-
|
990
|
-
_getTargetData: function(el, stage){
|
991
|
-
var self = this,
|
992
|
-
elStyle;
|
993
|
-
|
994
|
-
el.dataset[stage+'PosX'] = el.offsetLeft;
|
995
|
-
el.dataset[stage+'PosY'] = el.offsetTop;
|
996
|
-
|
997
|
-
if(self.animation.animateResizeTargets){
|
998
|
-
elStyle = !self._suckMode ?
|
999
|
-
window.getComputedStyle(el) :
|
1000
|
-
{
|
1001
|
-
marginBottom: '',
|
1002
|
-
marginRight: ''
|
1003
|
-
};
|
1004
|
-
|
1005
|
-
el.dataset[stage+'MarginBottom'] = parseInt(elStyle.marginBottom);
|
1006
|
-
el.dataset[stage+'MarginRight'] = parseInt(elStyle.marginRight);
|
1007
|
-
el.dataset[stage+'Width'] = el.offsetWidth;
|
1008
|
-
el.dataset[stage+'Height'] = el.offsetHeight;
|
1009
|
-
}
|
1010
|
-
},
|
1011
|
-
|
1012
|
-
/**
|
1013
|
-
* Get Original Mix Data
|
1014
|
-
* @since 2.0.0
|
1015
|
-
*/
|
1016
|
-
|
1017
|
-
_getOrigMixData: function(){
|
1018
|
-
var self = this,
|
1019
|
-
parentStyle = !self._suckMode ? window.getComputedStyle(self._$parent[0]) : {boxSizing: ''},
|
1020
|
-
parentBS = parentStyle.boxSizing || parentStyle[self._vendor+'BoxSizing'];
|
1021
|
-
|
1022
|
-
self._incPadding = (parentBS === 'border-box');
|
1023
|
-
|
1024
|
-
self._execAction('_getOrigMixData', 0);
|
1025
|
-
|
1026
|
-
!self._suckMode && (self.effects = self._parseEffects());
|
1027
|
-
|
1028
|
-
self._$toHide = self._$hide.filter(':visible');
|
1029
|
-
self._$toShow = self._$show.filter(':hidden');
|
1030
|
-
self._$pre = self._$targets.filter(':visible');
|
1031
|
-
|
1032
|
-
self._startHeight = self._incPadding ?
|
1033
|
-
self._$parent.outerHeight() :
|
1034
|
-
self._$parent.height();
|
1035
|
-
|
1036
|
-
for(var i = 0; i < self._$pre.length; i++){
|
1037
|
-
var el = self._$pre[i];
|
1038
|
-
|
1039
|
-
self._getTargetData(el, 'orig');
|
1040
|
-
}
|
1041
|
-
|
1042
|
-
self._execAction('_getOrigMixData', 1);
|
1043
|
-
},
|
1044
|
-
|
1045
|
-
/**
|
1046
|
-
* Set Intermediate Positions
|
1047
|
-
* @since 2.0.0
|
1048
|
-
*/
|
1049
|
-
|
1050
|
-
_setInter: function(){
|
1051
|
-
var self = this;
|
1052
|
-
|
1053
|
-
self._execAction('_setInter', 0);
|
1054
|
-
|
1055
|
-
if(self._changingLayout && self.animation.animateChangeLayout){
|
1056
|
-
self._$toShow.css('display',self._newDisplay);
|
1057
|
-
|
1058
|
-
if(self._changingClass){
|
1059
|
-
self._$container
|
1060
|
-
.removeClass(self.layout.containerClass)
|
1061
|
-
.addClass(self._newClass);
|
1062
|
-
}
|
1063
|
-
} else {
|
1064
|
-
self._$toShow.css('display', self.layout.display);
|
1065
|
-
}
|
1066
|
-
|
1067
|
-
self._execAction('_setInter', 1);
|
1068
|
-
},
|
1069
|
-
|
1070
|
-
/**
|
1071
|
-
* Get Intermediate Mix Data
|
1072
|
-
* @since 2.0.0
|
1073
|
-
*/
|
1074
|
-
|
1075
|
-
_getInterMixData: function(){
|
1076
|
-
var self = this;
|
1077
|
-
|
1078
|
-
self._execAction('_getInterMixData', 0);
|
1079
|
-
|
1080
|
-
for(var i = 0; i < self._$toShow.length; i++){
|
1081
|
-
var el = self._$toShow[i];
|
1082
|
-
|
1083
|
-
self._getTargetData(el, 'inter');
|
1084
|
-
}
|
1085
|
-
|
1086
|
-
for(var i = 0; i < self._$pre.length; i++){
|
1087
|
-
var el = self._$pre[i];
|
1088
|
-
|
1089
|
-
self._getTargetData(el, 'inter');
|
1090
|
-
}
|
1091
|
-
|
1092
|
-
self._execAction('_getInterMixData', 1);
|
1093
|
-
},
|
1094
|
-
|
1095
|
-
/**
|
1096
|
-
* Set Final Positions
|
1097
|
-
* @since 2.0.0
|
1098
|
-
*/
|
1099
|
-
|
1100
|
-
_setFinal: function(){
|
1101
|
-
var self = this;
|
1102
|
-
|
1103
|
-
self._execAction('_setFinal', 0);
|
1104
|
-
|
1105
|
-
self._sorting && self._printSort();
|
1106
|
-
|
1107
|
-
self._$toHide.removeStyle('display');
|
1108
|
-
|
1109
|
-
if(self._changingLayout && self.animation.animateChangeLayout){
|
1110
|
-
self._$pre.css('display',self._newDisplay);
|
1111
|
-
}
|
1112
|
-
|
1113
|
-
self._execAction('_setFinal', 1);
|
1114
|
-
},
|
1115
|
-
|
1116
|
-
/**
|
1117
|
-
* Get Final Mix Data
|
1118
|
-
* @since 2.0.0
|
1119
|
-
*/
|
1120
|
-
|
1121
|
-
_getFinalMixData: function(){
|
1122
|
-
var self = this;
|
1123
|
-
|
1124
|
-
self._execAction('_getFinalMixData', 0);
|
1125
|
-
|
1126
|
-
for(var i = 0; i < self._$toShow.length; i++){
|
1127
|
-
var el = self._$toShow[i];
|
1128
|
-
|
1129
|
-
self._getTargetData(el, 'final');
|
1130
|
-
}
|
1131
|
-
|
1132
|
-
for(var i = 0; i < self._$pre.length; i++){
|
1133
|
-
var el = self._$pre[i];
|
1134
|
-
|
1135
|
-
self._getTargetData(el, 'final');
|
1136
|
-
}
|
1137
|
-
|
1138
|
-
self._newHeight = self._incPadding ?
|
1139
|
-
self._$parent.outerHeight() :
|
1140
|
-
self._$parent.height();
|
1141
|
-
|
1142
|
-
self._sorting && self._printSort(true);
|
1143
|
-
|
1144
|
-
self._$toShow.removeStyle('display');
|
1145
|
-
|
1146
|
-
self._$pre.css('display',self.layout.display);
|
1147
|
-
|
1148
|
-
if(self._changingClass && self.animation.animateChangeLayout){
|
1149
|
-
self._$container
|
1150
|
-
.removeClass(self._newClass)
|
1151
|
-
.addClass(self.layout.containerClass);
|
1152
|
-
}
|
1153
|
-
|
1154
|
-
self._execAction('_getFinalMixData', 1);
|
1155
|
-
},
|
1156
|
-
|
1157
|
-
/**
|
1158
|
-
* Prepare Targets
|
1159
|
-
* @since 2.0.0
|
1160
|
-
*/
|
1161
|
-
|
1162
|
-
_prepTargets: function(){
|
1163
|
-
var self = this,
|
1164
|
-
transformCSS = {
|
1165
|
-
_in: self._getPrefixedCSS('transform', self.effects.transformIn),
|
1166
|
-
_out: self._getPrefixedCSS('transform', self.effects.transformOut)
|
1167
|
-
};
|
1168
|
-
|
1169
|
-
self._execAction('_prepTargets', 0);
|
1170
|
-
|
1171
|
-
if(self.animation.animateResizeContainer){
|
1172
|
-
self._$parent.css('height',self._startHeight+'px');
|
1173
|
-
}
|
1174
|
-
|
1175
|
-
for(var i = 0; i < self._$toShow.length; i++){
|
1176
|
-
var el = self._$toShow[i],
|
1177
|
-
$el = $(el);
|
1178
|
-
|
1179
|
-
el.style.opacity = self.effects.opacity;
|
1180
|
-
el.style.display = (self._changingLayout && self.animation.animateChangeLayout) ?
|
1181
|
-
self._newDisplay :
|
1182
|
-
self.layout.display;
|
1183
|
-
|
1184
|
-
$el.css(transformCSS._in);
|
1185
|
-
|
1186
|
-
if(self.animation.animateResizeTargets){
|
1187
|
-
el.style.width = el.dataset.finalWidth+'px';
|
1188
|
-
el.style.height = el.dataset.finalHeight+'px';
|
1189
|
-
el.style.marginRight = -(el.dataset.finalWidth - el.dataset.interWidth) + (el.dataset.finalMarginRight * 1)+'px';
|
1190
|
-
el.style.marginBottom = -(el.dataset.finalHeight - el.dataset.interHeight) + (el.dataset.finalMarginBottom * 1)+'px';
|
1191
|
-
}
|
1192
|
-
}
|
1193
|
-
|
1194
|
-
for(var i = 0; i < self._$pre.length; i++){
|
1195
|
-
var el = self._$pre[i],
|
1196
|
-
$el = $(el),
|
1197
|
-
translate = {
|
1198
|
-
x: el.dataset.origPosX - el.dataset.interPosX,
|
1199
|
-
y: el.dataset.origPosY - el.dataset.interPosY
|
1200
|
-
},
|
1201
|
-
transformCSS = self._getPrefixedCSS('transform','translate('+translate.x+'px,'+translate.y+'px)');
|
1202
|
-
|
1203
|
-
$el.css(transformCSS);
|
1204
|
-
|
1205
|
-
if(self.animation.animateResizeTargets){
|
1206
|
-
el.style.width = el.dataset.origWidth+'px';
|
1207
|
-
el.style.height = el.dataset.origHeight+'px';
|
1208
|
-
|
1209
|
-
if(el.dataset.origWidth - el.dataset.finalWidth){
|
1210
|
-
el.style.marginRight = -(el.dataset.origWidth - el.dataset.interWidth) + (el.dataset.origMarginRight * 1)+'px';
|
1211
|
-
}
|
1212
|
-
|
1213
|
-
if(el.dataset.origHeight - el.dataset.finalHeight){
|
1214
|
-
el.style.marginBottom = -(el.dataset.origHeight - el.dataset.interHeight) + (el.dataset.origMarginBottom * 1) +'px';
|
1215
|
-
}
|
1216
|
-
}
|
1217
|
-
}
|
1218
|
-
|
1219
|
-
self._execAction('_prepTargets', 1);
|
1220
|
-
},
|
1221
|
-
|
1222
|
-
/**
|
1223
|
-
* Animate Targets
|
1224
|
-
* @since 2.0.0
|
1225
|
-
*/
|
1226
|
-
|
1227
|
-
_animateTargets: function(){
|
1228
|
-
var self = this;
|
1229
|
-
|
1230
|
-
self._execAction('_animateTargets', 0);
|
1231
|
-
|
1232
|
-
self._targetsDone = 0;
|
1233
|
-
self._targetsBound = 0;
|
1234
|
-
|
1235
|
-
self._$parent
|
1236
|
-
.css(self._getPrefixedCSS('perspective', self.animation.perspectiveDistance+'px'))
|
1237
|
-
.css(self._getPrefixedCSS('perspective-origin', self.animation.perspectiveOrigin));
|
1238
|
-
|
1239
|
-
if(self.animation.animateResizeContainer){
|
1240
|
-
self._$parent
|
1241
|
-
.css(self._getPrefixedCSS('transition','height '+self.animation.duration+'ms ease'))
|
1242
|
-
.css('height',self._newHeight+'px');
|
1243
|
-
}
|
1244
|
-
|
1245
|
-
for(var i = 0; i < self._$toShow.length; i++){
|
1246
|
-
var el = self._$toShow[i],
|
1247
|
-
$el = $(el),
|
1248
|
-
translate = {
|
1249
|
-
x: el.dataset.finalPosX - el.dataset.interPosX,
|
1250
|
-
y: el.dataset.finalPosY - el.dataset.interPosY
|
1251
|
-
},
|
1252
|
-
delay = self._getDelay(i),
|
1253
|
-
toShowCSS = {};
|
1254
|
-
|
1255
|
-
el.style.opacity = '';
|
1256
|
-
|
1257
|
-
for(var j = 0; j < 2; j++){
|
1258
|
-
var a = j === 0 ? a = self._prefix : '';
|
1259
|
-
|
1260
|
-
if(self._ff && self._ff <= 20){
|
1261
|
-
toShowCSS[a+'transition-property'] = 'all';
|
1262
|
-
toShowCSS[a+'transition-timing-function'] = self.animation.easing+'ms';
|
1263
|
-
toShowCSS[a+'transition-duration'] = self.animation.duration+'ms';
|
1264
|
-
}
|
1265
|
-
|
1266
|
-
toShowCSS[a+'transition-delay'] = delay+'ms';
|
1267
|
-
toShowCSS[a+'transform'] = 'translate('+translate.x+'px,'+translate.y+'px)';
|
1268
|
-
}
|
1269
|
-
|
1270
|
-
if(self.effects.transform || self.effects.opacity){
|
1271
|
-
self._bindTargetDone($el);
|
1272
|
-
}
|
1273
|
-
|
1274
|
-
(self._ff && self._ff <= 20) ?
|
1275
|
-
$el.css(toShowCSS) :
|
1276
|
-
$el.css(self.effects.transition).css(toShowCSS);
|
1277
|
-
}
|
1278
|
-
|
1279
|
-
for(var i = 0; i < self._$pre.length; i++){
|
1280
|
-
var el = self._$pre[i],
|
1281
|
-
$el = $(el),
|
1282
|
-
translate = {
|
1283
|
-
x: el.dataset.finalPosX - el.dataset.interPosX,
|
1284
|
-
y: el.dataset.finalPosY - el.dataset.interPosY
|
1285
|
-
},
|
1286
|
-
delay = self._getDelay(i);
|
1287
|
-
|
1288
|
-
if(!(
|
1289
|
-
el.dataset.finalPosX === el.dataset.origPosX &&
|
1290
|
-
el.dataset.finalPosY === el.dataset.origPosY
|
1291
|
-
)){
|
1292
|
-
self._bindTargetDone($el);
|
1293
|
-
}
|
1294
|
-
|
1295
|
-
$el.css(self._getPrefixedCSS('transition', 'all '+self.animation.duration+'ms '+self.animation.easing+' '+delay+'ms'));
|
1296
|
-
$el.css(self._getPrefixedCSS('transform', 'translate('+translate.x+'px,'+translate.y+'px)'));
|
1297
|
-
|
1298
|
-
if(self.animation.animateResizeTargets){
|
1299
|
-
if(el.dataset.origWidth - el.dataset.finalWidth && el.dataset.finalWidth * 1){
|
1300
|
-
el.style.width = el.dataset.finalWidth+'px';
|
1301
|
-
el.style.marginRight = -(el.dataset.finalWidth - el.dataset.interWidth)+(el.dataset.finalMarginRight * 1)+'px';
|
1302
|
-
}
|
1303
|
-
|
1304
|
-
if(el.dataset.origHeight - el.dataset.finalHeight && el.dataset.finalHeight * 1){
|
1305
|
-
el.style.height = el.dataset.finalHeight+'px';
|
1306
|
-
el.style.marginBottom = -(el.dataset.finalHeight - el.dataset.interHeight)+(el.dataset.finalMarginBottom * 1) +'px';
|
1307
|
-
}
|
1308
|
-
}
|
1309
|
-
}
|
1310
|
-
|
1311
|
-
if(self._changingClass){
|
1312
|
-
self._$container
|
1313
|
-
.removeClass(self.layout.containerClass)
|
1314
|
-
.addClass(self._newClass);
|
1315
|
-
}
|
1316
|
-
|
1317
|
-
for(var i = 0; i < self._$toHide.length; i++){
|
1318
|
-
var el = self._$toHide[i],
|
1319
|
-
$el = $(el),
|
1320
|
-
delay = self._getDelay(i),
|
1321
|
-
toHideCSS = {};
|
1322
|
-
|
1323
|
-
for(var j = 0; j<2; j++){
|
1324
|
-
var a = j === 0 ? a = self._prefix : '';
|
1325
|
-
|
1326
|
-
toHideCSS[a+'transition-delay'] = delay+'ms';
|
1327
|
-
toHideCSS[a+'transform'] = self.effects.transformOut;
|
1328
|
-
toHideCSS.opacity = self.effects.opacity;
|
1329
|
-
}
|
1330
|
-
|
1331
|
-
$el.css(self.effects.transition).css(toHideCSS);
|
1332
|
-
|
1333
|
-
if(self.effects.transform || self.effects.opacity){
|
1334
|
-
self._bindTargetDone($el);
|
1335
|
-
};
|
1336
|
-
}
|
1337
|
-
|
1338
|
-
self._execAction('_animateTargets', 1);
|
1339
|
-
|
1340
|
-
},
|
1341
|
-
|
1342
|
-
/**
|
1343
|
-
* Bind Targets TransitionEnd
|
1344
|
-
* @since 2.0.0
|
1345
|
-
* @param {object} $el
|
1346
|
-
*/
|
1347
|
-
|
1348
|
-
_bindTargetDone: function($el){
|
1349
|
-
var self = this,
|
1350
|
-
el = $el[0];
|
1351
|
-
|
1352
|
-
self._execAction('_bindTargetDone', 0, arguments);
|
1353
|
-
|
1354
|
-
if(!el.dataset.bound){
|
1355
|
-
|
1356
|
-
el.dataset.bound = true;
|
1357
|
-
self._targetsBound++;
|
1358
|
-
|
1359
|
-
$el.on('webkitTransitionEnd.mixItUp transitionend.mixItUp',function(e){
|
1360
|
-
if(
|
1361
|
-
(e.originalEvent.propertyName.indexOf('transform') > -1 ||
|
1362
|
-
e.originalEvent.propertyName.indexOf('opacity') > -1) &&
|
1363
|
-
$(e.originalEvent.target).is(self.selectors.target)
|
1364
|
-
){
|
1365
|
-
$el.off('.mixItUp');
|
1366
|
-
delete el.dataset.bound;
|
1367
|
-
self._targetDone();
|
1368
|
-
}
|
1369
|
-
});
|
1370
|
-
}
|
1371
|
-
|
1372
|
-
self._execAction('_bindTargetDone', 1, arguments);
|
1373
|
-
},
|
1374
|
-
|
1375
|
-
/**
|
1376
|
-
* Target Done
|
1377
|
-
* @since 2.0.0
|
1378
|
-
*/
|
1379
|
-
|
1380
|
-
_targetDone: function(){
|
1381
|
-
var self = this;
|
1382
|
-
|
1383
|
-
self._execAction('_targetDone', 0);
|
1384
|
-
|
1385
|
-
self._targetsDone++;
|
1386
|
-
|
1387
|
-
(self._targetsDone === self._targetsBound) && self._cleanUp();
|
1388
|
-
|
1389
|
-
self._execAction('_targetDone', 1);
|
1390
|
-
},
|
1391
|
-
|
1392
|
-
/**
|
1393
|
-
* Clean Up
|
1394
|
-
* @since 2.0.0
|
1395
|
-
*/
|
1396
|
-
|
1397
|
-
_cleanUp: function(){
|
1398
|
-
var self = this,
|
1399
|
-
targetStyles = self.animation.animateResizeTargets ?
|
1400
|
-
'transform opacity width height margin-bottom margin-right' :
|
1401
|
-
'transform opacity',
|
1402
|
-
unBrake = function(){
|
1403
|
-
self._$targets.removeStyle('transition', self._prefix);
|
1404
|
-
};
|
1405
|
-
|
1406
|
-
self._execAction('_cleanUp', 0);
|
1407
|
-
|
1408
|
-
!self._changingLayout ?
|
1409
|
-
self._$show.css('display',self.layout.display) :
|
1410
|
-
self._$show.css('display',self._newDisplay);
|
1411
|
-
|
1412
|
-
self._$targets.css(self._brake);
|
1413
|
-
|
1414
|
-
self._$targets
|
1415
|
-
.removeStyle(targetStyles, self._prefix)
|
1416
|
-
.removeAttr('data-inter-pos-x data-inter-pos-y data-final-pos-x data-final-pos-y data-orig-pos-x data-orig-pos-y data-orig-height data-orig-width data-final-height data-final-width data-inter-width data-inter-height data-orig-margin-right data-orig-margin-bottom data-inter-margin-right data-inter-margin-bottom data-final-margin-right data-final-margin-bottom');
|
1417
|
-
|
1418
|
-
self._$hide.removeStyle('display');
|
1419
|
-
|
1420
|
-
self._$parent.removeStyle('height transition perspective-distance perspective perspective-origin-x perspective-origin-y perspective-origin perspectiveOrigin', self._prefix);
|
1421
|
-
|
1422
|
-
if(self._sorting){
|
1423
|
-
self._printSort();
|
1424
|
-
self._activeSort = self._newSortString;
|
1425
|
-
self._sorting = false;
|
1426
|
-
}
|
1427
|
-
|
1428
|
-
if(self._changingLayout){
|
1429
|
-
if(self._changingDisplay){
|
1430
|
-
self.layout.display = self._newDisplay;
|
1431
|
-
self._changingDisplay = false;
|
1432
|
-
}
|
1433
|
-
|
1434
|
-
if(self._changingClass){
|
1435
|
-
self._$parent.removeClass(self.layout.containerClass).addClass(self._newClass);
|
1436
|
-
self.layout.containerClass = self._newClass;
|
1437
|
-
self._changingClass = false;
|
1438
|
-
}
|
1439
|
-
|
1440
|
-
self._changingLayout = false;
|
1441
|
-
}
|
1442
|
-
|
1443
|
-
self._refresh();
|
1444
|
-
|
1445
|
-
self._buildState();
|
1446
|
-
|
1447
|
-
if(self._state.fail){
|
1448
|
-
self._$container.addClass(self.layout.containerClassFail);
|
1449
|
-
}
|
1450
|
-
|
1451
|
-
self._$show = $();
|
1452
|
-
self._$hide = $();
|
1453
|
-
|
1454
|
-
if(window.requestAnimationFrame){
|
1455
|
-
requestAnimationFrame(unBrake);
|
1456
|
-
}
|
1457
|
-
|
1458
|
-
self._mixing = false;
|
1459
|
-
|
1460
|
-
if(typeof self.callbacks._user === 'function'){
|
1461
|
-
self.callbacks._user.call(self._domNode, self._state, self);
|
1462
|
-
}
|
1463
|
-
|
1464
|
-
if(typeof self.callbacks.onMixEnd === 'function'){
|
1465
|
-
self.callbacks.onMixEnd.call(self._domNode, self._state, self);
|
1466
|
-
}
|
1467
|
-
|
1468
|
-
self._$container.trigger('mixEnd', [self._state, self]);
|
1469
|
-
|
1470
|
-
if(self._state.fail){
|
1471
|
-
(typeof self.callbacks.onMixFail === 'function') && self.callbacks.onMixFail.call(self._domNode, self._state, self);
|
1472
|
-
self._$container.trigger('mixFail', [self._state, self]);
|
1473
|
-
}
|
1474
|
-
|
1475
|
-
if(self._loading){
|
1476
|
-
(typeof self.callbacks.onMixLoad === 'function') && self.callbacks.onMixLoad.call(self._domNode, self._state, self);
|
1477
|
-
self._$container.trigger('mixLoad', [self._state, self]);
|
1478
|
-
}
|
1479
|
-
|
1480
|
-
if(self._queue.length){
|
1481
|
-
self._execAction('_queue', 0);
|
1482
|
-
|
1483
|
-
self.multiMix(self._queue[0][0],self._queue[0][1],self._queue[0][2]);
|
1484
|
-
self._queue.splice(0, 1);
|
1485
|
-
}
|
1486
|
-
|
1487
|
-
self._execAction('_cleanUp', 1);
|
1488
|
-
|
1489
|
-
self._loading = false;
|
1490
|
-
},
|
1491
|
-
|
1492
|
-
/**
|
1493
|
-
* Get Prefixed CSS
|
1494
|
-
* @since 2.0.0
|
1495
|
-
* @param {string} property
|
1496
|
-
* @param {string} value
|
1497
|
-
* @param {boolean} prefixValue
|
1498
|
-
* @return {object} styles
|
1499
|
-
*/
|
1500
|
-
|
1501
|
-
_getPrefixedCSS: function(property, value, prefixValue){
|
1502
|
-
var self = this,
|
1503
|
-
styles = {},
|
1504
|
-
prefix = '',
|
1505
|
-
i = -1;
|
1506
|
-
|
1507
|
-
for(i = 0; i < 2; i++){
|
1508
|
-
prefix = i === 0 ? self._prefix : '';
|
1509
|
-
prefixValue ? styles[prefix+property] = prefix+value : styles[prefix+property] = value;
|
1510
|
-
}
|
1511
|
-
|
1512
|
-
return self._execFilter('_getPrefixedCSS', styles, arguments);
|
1513
|
-
},
|
1514
|
-
|
1515
|
-
/**
|
1516
|
-
* Get Delay
|
1517
|
-
* @since 2.0.0
|
1518
|
-
* @param {number} i
|
1519
|
-
* @return {number} delay
|
1520
|
-
*/
|
1521
|
-
|
1522
|
-
_getDelay: function(i){
|
1523
|
-
var self = this,
|
1524
|
-
n = typeof self.animation.staggerSequence === 'function' ? self.animation.staggerSequence.call(self._domNode, i, self._state) : i,
|
1525
|
-
delay = self.animation.stagger ? n * self.animation.staggerDuration : 0;
|
1526
|
-
|
1527
|
-
return self._execFilter('_getDelay', delay, arguments);
|
1528
|
-
},
|
1529
|
-
|
1530
|
-
/**
|
1531
|
-
* Parse MultiMix Arguments
|
1532
|
-
* @since 2.0.0
|
1533
|
-
* @param {array} args
|
1534
|
-
* @return {object} output
|
1535
|
-
*/
|
1536
|
-
|
1537
|
-
_parseMultiMixArgs: function(args){
|
1538
|
-
var self = this,
|
1539
|
-
output = {
|
1540
|
-
command: null,
|
1541
|
-
animate: self.animation.enable,
|
1542
|
-
callback: null
|
1543
|
-
};
|
1544
|
-
|
1545
|
-
for(var i = 0; i < args.length; i++){
|
1546
|
-
var arg = args[i];
|
1547
|
-
|
1548
|
-
if(arg !== null){
|
1549
|
-
if(typeof arg === 'object' || typeof arg === 'string'){
|
1550
|
-
output.command = arg;
|
1551
|
-
} else if(typeof arg === 'boolean'){
|
1552
|
-
output.animate = arg;
|
1553
|
-
} else if(typeof arg === 'function'){
|
1554
|
-
output.callback = arg;
|
1555
|
-
}
|
1556
|
-
}
|
1557
|
-
}
|
1558
|
-
|
1559
|
-
return self._execFilter('_parseMultiMixArgs', output, arguments);
|
1560
|
-
},
|
1561
|
-
|
1562
|
-
/**
|
1563
|
-
* Parse Insert Arguments
|
1564
|
-
* @since 2.0.0
|
1565
|
-
* @param {array} args
|
1566
|
-
* @return {object} output
|
1567
|
-
*/
|
1568
|
-
|
1569
|
-
_parseInsertArgs: function(args){
|
1570
|
-
var self = this,
|
1571
|
-
output = {
|
1572
|
-
index: 0,
|
1573
|
-
$object: $(),
|
1574
|
-
multiMix: {filter: self._state.activeFilter},
|
1575
|
-
callback: null
|
1576
|
-
};
|
1577
|
-
|
1578
|
-
for(var i = 0; i < args.length; i++){
|
1579
|
-
var arg = args[i];
|
1580
|
-
|
1581
|
-
if(typeof arg === 'number'){
|
1582
|
-
output.index = arg;
|
1583
|
-
} else if(typeof arg === 'object' && arg instanceof $){
|
1584
|
-
output.$object = arg;
|
1585
|
-
} else if(typeof arg === 'object' && self._helpers._isElement(arg)){
|
1586
|
-
output.$object = $(arg);
|
1587
|
-
} else if(typeof arg === 'object' && arg !== null){
|
1588
|
-
output.multiMix = arg;
|
1589
|
-
} else if(typeof arg === 'boolean' && !arg){
|
1590
|
-
output.multiMix = false;
|
1591
|
-
} else if(typeof arg === 'function'){
|
1592
|
-
output.callback = arg;
|
1593
|
-
}
|
1594
|
-
}
|
1595
|
-
|
1596
|
-
return self._execFilter('_parseInsertArgs', output, arguments);
|
1597
|
-
},
|
1598
|
-
|
1599
|
-
/**
|
1600
|
-
* Execute Action
|
1601
|
-
* @since 2.0.0
|
1602
|
-
* @param {string} methodName
|
1603
|
-
* @param {boolean} isPost
|
1604
|
-
* @param {array} args
|
1605
|
-
*/
|
1606
|
-
|
1607
|
-
_execAction: function(methodName, isPost, args){
|
1608
|
-
var self = this,
|
1609
|
-
context = isPost ? 'post' : 'pre';
|
1610
|
-
|
1611
|
-
if(!self._actions.isEmptyObject && self._actions.hasOwnProperty(methodName)){
|
1612
|
-
for(var key in self._actions[methodName][context]){
|
1613
|
-
self._actions[methodName][context][key].call(self, args);
|
1614
|
-
}
|
1615
|
-
}
|
1616
|
-
},
|
1617
|
-
|
1618
|
-
/**
|
1619
|
-
* Execute Filter
|
1620
|
-
* @since 2.0.0
|
1621
|
-
* @param {string} methodName
|
1622
|
-
* @param {mixed} value
|
1623
|
-
* @return {mixed} value
|
1624
|
-
*/
|
1625
|
-
|
1626
|
-
_execFilter: function(methodName, value, args){
|
1627
|
-
var self = this;
|
1628
|
-
|
1629
|
-
if(!self._filters.isEmptyObject && self._filters.hasOwnProperty(methodName)){
|
1630
|
-
for(var key in self._filters[methodName]){
|
1631
|
-
return self._filters[methodName][key].call(self, args);
|
1632
|
-
}
|
1633
|
-
} else {
|
1634
|
-
return value;
|
1635
|
-
}
|
1636
|
-
},
|
1637
|
-
|
1638
|
-
/* Helpers
|
1639
|
-
---------------------------------------------------------------------- */
|
1640
|
-
|
1641
|
-
_helpers: {
|
1642
|
-
|
1643
|
-
/**
|
1644
|
-
* CamelCase
|
1645
|
-
* @since 2.0.0
|
1646
|
-
* @param {string}
|
1647
|
-
* @return {string}
|
1648
|
-
*/
|
1649
|
-
|
1650
|
-
_camelCase: function(string){
|
1651
|
-
return string.replace(/-([a-z])/g, function(g){
|
1652
|
-
return g[1].toUpperCase();
|
1653
|
-
});
|
1654
|
-
},
|
1655
|
-
|
1656
|
-
/**
|
1657
|
-
* Is Element
|
1658
|
-
* @since 2.1.3
|
1659
|
-
* @param {object} element to test
|
1660
|
-
* @return {boolean}
|
1661
|
-
*/
|
1662
|
-
|
1663
|
-
_isElement: function(el){
|
1664
|
-
if(window.HTMLElement){
|
1665
|
-
return el instanceof HTMLElement;
|
1666
|
-
} else {
|
1667
|
-
return (
|
1668
|
-
el !== null &&
|
1669
|
-
el.nodeType === 1 &&
|
1670
|
-
el.nodeName === 'string'
|
1671
|
-
);
|
1672
|
-
}
|
1673
|
-
}
|
1674
|
-
},
|
1675
|
-
|
1676
|
-
/* Public Methods
|
1677
|
-
---------------------------------------------------------------------- */
|
1678
|
-
|
1679
|
-
/**
|
1680
|
-
* Is Mixing
|
1681
|
-
* @since 2.0.0
|
1682
|
-
* @return {boolean}
|
1683
|
-
*/
|
1684
|
-
|
1685
|
-
isMixing: function(){
|
1686
|
-
var self = this;
|
1687
|
-
|
1688
|
-
return self._execFilter('isMixing', self._mixing);
|
1689
|
-
},
|
1690
|
-
|
1691
|
-
/**
|
1692
|
-
* Filter (public)
|
1693
|
-
* @since 2.0.0
|
1694
|
-
* @param {array} arguments
|
1695
|
-
*/
|
1696
|
-
|
1697
|
-
filter: function(){
|
1698
|
-
var self = this,
|
1699
|
-
args = self._parseMultiMixArgs(arguments);
|
1700
|
-
|
1701
|
-
self._clicking && (self._toggleString = '');
|
1702
|
-
|
1703
|
-
self.multiMix({filter: args.command}, args.animate, args.callback);
|
1704
|
-
},
|
1705
|
-
|
1706
|
-
/**
|
1707
|
-
* Sort (public)
|
1708
|
-
* @since 2.0.0
|
1709
|
-
* @param {array} arguments
|
1710
|
-
*/
|
1711
|
-
|
1712
|
-
sort: function(){
|
1713
|
-
var self = this,
|
1714
|
-
args = self._parseMultiMixArgs(arguments);
|
1715
|
-
|
1716
|
-
self.multiMix({sort: args.command}, args.animate, args.callback);
|
1717
|
-
},
|
1718
|
-
|
1719
|
-
/**
|
1720
|
-
* Change Layout (public)
|
1721
|
-
* @since 2.0.0
|
1722
|
-
* @param {array} arguments
|
1723
|
-
*/
|
1724
|
-
|
1725
|
-
changeLayout: function(){
|
1726
|
-
var self = this,
|
1727
|
-
args = self._parseMultiMixArgs(arguments);
|
1728
|
-
|
1729
|
-
self.multiMix({changeLayout: args.command}, args.animate, args.callback);
|
1730
|
-
},
|
1731
|
-
|
1732
|
-
/**
|
1733
|
-
* MultiMix
|
1734
|
-
* @since 2.0.0
|
1735
|
-
* @param {array} arguments
|
1736
|
-
*/
|
1737
|
-
|
1738
|
-
multiMix: function(){
|
1739
|
-
var self = this,
|
1740
|
-
args = self._parseMultiMixArgs(arguments);
|
1741
|
-
|
1742
|
-
self._execAction('multiMix', 0, arguments);
|
1743
|
-
|
1744
|
-
if(!self._mixing){
|
1745
|
-
if(self.controls.enable && !self._clicking){
|
1746
|
-
self.controls.toggleFilterButtons && self._buildToggleArray();
|
1747
|
-
self._updateControls(args.command, self.controls.toggleFilterButtons);
|
1748
|
-
}
|
1749
|
-
|
1750
|
-
(self._queue.length < 2) && (self._clicking = false);
|
1751
|
-
|
1752
|
-
delete self.callbacks._user;
|
1753
|
-
if(args.callback) self.callbacks._user = args.callback;
|
1754
|
-
|
1755
|
-
var sort = args.command.sort,
|
1756
|
-
filter = args.command.filter,
|
1757
|
-
changeLayout = args.command.changeLayout;
|
1758
|
-
|
1759
|
-
self._refresh();
|
1760
|
-
|
1761
|
-
if(sort){
|
1762
|
-
self._newSort = self._parseSort(sort);
|
1763
|
-
self._newSortString = sort;
|
1764
|
-
|
1765
|
-
self._sorting = true;
|
1766
|
-
self._sort();
|
1767
|
-
}
|
1768
|
-
|
1769
|
-
if(filter !== undf){
|
1770
|
-
filter = (filter === 'all') ? self.selectors.target : filter;
|
1771
|
-
|
1772
|
-
self._activeFilter = filter;
|
1773
|
-
}
|
1774
|
-
|
1775
|
-
self._filter();
|
1776
|
-
|
1777
|
-
if(changeLayout){
|
1778
|
-
self._newDisplay = (typeof changeLayout === 'string') ? changeLayout : changeLayout.display || self.layout.display;
|
1779
|
-
self._newClass = changeLayout.containerClass || '';
|
1780
|
-
|
1781
|
-
if(
|
1782
|
-
self._newDisplay !== self.layout.display ||
|
1783
|
-
self._newClass !== self.layout.containerClass
|
1784
|
-
){
|
1785
|
-
self._changingLayout = true;
|
1786
|
-
|
1787
|
-
self._changingClass = (self._newClass !== self.layout.containerClass);
|
1788
|
-
self._changingDisplay = (self._newDisplay !== self.layout.display);
|
1789
|
-
}
|
1790
|
-
}
|
1791
|
-
|
1792
|
-
self._$targets.css(self._brake);
|
1793
|
-
|
1794
|
-
self._goMix(args.animate ^ self.animation.enable ? args.animate : self.animation.enable);
|
1795
|
-
|
1796
|
-
self._execAction('multiMix', 1, arguments);
|
1797
|
-
|
1798
|
-
} else {
|
1799
|
-
if(self.animation.queue && self._queue.length < self.animation.queueLimit){
|
1800
|
-
self._queue.push(arguments);
|
1801
|
-
|
1802
|
-
(self.controls.enable && !self._clicking) && self._updateControls(args.command);
|
1803
|
-
|
1804
|
-
self._execAction('multiMixQueue', 1, arguments);
|
1805
|
-
|
1806
|
-
} else {
|
1807
|
-
if(typeof self.callbacks.onMixBusy === 'function'){
|
1808
|
-
self.callbacks.onMixBusy.call(self._domNode, self._state, self);
|
1809
|
-
}
|
1810
|
-
self._$container.trigger('mixBusy', [self._state, self]);
|
1811
|
-
|
1812
|
-
self._execAction('multiMixBusy', 1, arguments);
|
1813
|
-
}
|
1814
|
-
}
|
1815
|
-
},
|
1816
|
-
|
1817
|
-
/**
|
1818
|
-
* Insert
|
1819
|
-
* @since 2.0.0
|
1820
|
-
* @param {array} arguments
|
1821
|
-
*/
|
1822
|
-
|
1823
|
-
insert: function(){
|
1824
|
-
var self = this,
|
1825
|
-
args = self._parseInsertArgs(arguments),
|
1826
|
-
callback = (typeof args.callback === 'function') ? args.callback : null,
|
1827
|
-
frag = document.createDocumentFragment(),
|
1828
|
-
target = (function(){
|
1829
|
-
self._refresh();
|
1830
|
-
|
1831
|
-
if(self._$targets.length){
|
1832
|
-
return (args.index < self._$targets.length || !self._$targets.length) ?
|
1833
|
-
self._$targets[args.index] :
|
1834
|
-
self._$targets[self._$targets.length-1].nextElementSibling;
|
1835
|
-
} else {
|
1836
|
-
return self._$parent[0].children[0];
|
1837
|
-
}
|
1838
|
-
})();
|
1839
|
-
|
1840
|
-
self._execAction('insert', 0, arguments);
|
1841
|
-
|
1842
|
-
if(args.$object){
|
1843
|
-
for(var i = 0; i < args.$object.length; i++){
|
1844
|
-
var el = args.$object[i];
|
1845
|
-
|
1846
|
-
frag.appendChild(el);
|
1847
|
-
frag.appendChild(document.createTextNode(' '));
|
1848
|
-
}
|
1849
|
-
|
1850
|
-
self._$parent[0].insertBefore(frag, target);
|
1851
|
-
}
|
1852
|
-
|
1853
|
-
self._execAction('insert', 1, arguments);
|
1854
|
-
|
1855
|
-
if(typeof args.multiMix === 'object'){
|
1856
|
-
self.multiMix(args.multiMix, callback);
|
1857
|
-
}
|
1858
|
-
},
|
1859
|
-
|
1860
|
-
/**
|
1861
|
-
* Prepend
|
1862
|
-
* @since 2.0.0
|
1863
|
-
* @param {array} arguments
|
1864
|
-
*/
|
1865
|
-
|
1866
|
-
prepend: function(){
|
1867
|
-
var self = this,
|
1868
|
-
args = self._parseInsertArgs(arguments);
|
1869
|
-
|
1870
|
-
self.insert(0, args.$object, args.multiMix, args.callback);
|
1871
|
-
},
|
1872
|
-
|
1873
|
-
/**
|
1874
|
-
* Append
|
1875
|
-
* @since 2.0.0
|
1876
|
-
* @param {array} arguments
|
1877
|
-
*/
|
1878
|
-
|
1879
|
-
append: function(){
|
1880
|
-
var self = this,
|
1881
|
-
args = self._parseInsertArgs(arguments);
|
1882
|
-
|
1883
|
-
self.insert(self._state.totalTargets, args.$object, args.multiMix, args.callback);
|
1884
|
-
},
|
1885
|
-
|
1886
|
-
/**
|
1887
|
-
* Get Option
|
1888
|
-
* @since 2.0.0
|
1889
|
-
* @param {string} string
|
1890
|
-
* @return {mixed} value
|
1891
|
-
*/
|
1892
|
-
|
1893
|
-
getOption: function(string){
|
1894
|
-
var self = this,
|
1895
|
-
getProperty = function(obj, prop){
|
1896
|
-
var parts = prop.split('.'),
|
1897
|
-
last = parts.pop(),
|
1898
|
-
l = parts.length,
|
1899
|
-
i = 1,
|
1900
|
-
current = parts[0] || prop;
|
1901
|
-
|
1902
|
-
while((obj = obj[current]) && i < l){
|
1903
|
-
current = parts[i];
|
1904
|
-
i++;
|
1905
|
-
}
|
1906
|
-
|
1907
|
-
if(obj !== undf){
|
1908
|
-
return obj[last] !== undf ? obj[last] : obj;
|
1909
|
-
}
|
1910
|
-
};
|
1911
|
-
|
1912
|
-
return string ? self._execFilter('getOption', getProperty(self, string), arguments) : self;
|
1913
|
-
},
|
1914
|
-
|
1915
|
-
/**
|
1916
|
-
* Set Options
|
1917
|
-
* @since 2.0.0
|
1918
|
-
* @param {object} config
|
1919
|
-
*/
|
1920
|
-
|
1921
|
-
setOptions: function(config){
|
1922
|
-
var self = this;
|
1923
|
-
|
1924
|
-
self._execAction('setOptions', 0, arguments);
|
1925
|
-
|
1926
|
-
typeof config === 'object' && $.extend(true, self, config);
|
1927
|
-
|
1928
|
-
self._execAction('setOptions', 1, arguments);
|
1929
|
-
},
|
1930
|
-
|
1931
|
-
/**
|
1932
|
-
* Get State
|
1933
|
-
* @since 2.0.0
|
1934
|
-
* @return {object} state
|
1935
|
-
*/
|
1936
|
-
|
1937
|
-
getState: function(){
|
1938
|
-
var self = this;
|
1939
|
-
|
1940
|
-
return self._execFilter('getState', self._state, self);
|
1941
|
-
},
|
1942
|
-
|
1943
|
-
/**
|
1944
|
-
* Force Refresh
|
1945
|
-
* @since 2.1.2
|
1946
|
-
*/
|
1947
|
-
|
1948
|
-
forceRefresh: function(){
|
1949
|
-
var self = this;
|
1950
|
-
|
1951
|
-
self._refresh(false, true);
|
1952
|
-
},
|
1953
|
-
|
1954
|
-
/**
|
1955
|
-
* Destroy
|
1956
|
-
* @since 2.0.0
|
1957
|
-
* @param {boolean} hideAll
|
1958
|
-
*/
|
1959
|
-
|
1960
|
-
destroy: function(hideAll){
|
1961
|
-
var self = this,
|
1962
|
-
filters = $.MixItUp.prototype._bound._filter,
|
1963
|
-
sorts = $.MixItUp.prototype._bound._sort;
|
1964
|
-
|
1965
|
-
self._execAction('destroy', 0, arguments);
|
1966
|
-
|
1967
|
-
self._$body
|
1968
|
-
.add($(self.selectors.sort))
|
1969
|
-
.add($(self.selectors.filter))
|
1970
|
-
.off('.mixItUp');
|
1971
|
-
|
1972
|
-
for(var i = 0; i < self._$targets.length; i++){
|
1973
|
-
var target = self._$targets[i];
|
1974
|
-
|
1975
|
-
hideAll && (target.style.display = '');
|
1976
|
-
|
1977
|
-
delete target.mixParent;
|
1978
|
-
}
|
1979
|
-
|
1980
|
-
self._execAction('destroy', 1, arguments);
|
1981
|
-
|
1982
|
-
if(filters[self.selectors.filter] && filters[self.selectors.filter] > 1) {
|
1983
|
-
filters[self.selectors.filter]--;
|
1984
|
-
} else if(filters[self.selectors.filter] === 1) {
|
1985
|
-
delete filters[self.selectors.filter];
|
1986
|
-
}
|
1987
|
-
|
1988
|
-
if(sorts[self.selectors.sort] && sorts[self.selectors.sort] > 1) {
|
1989
|
-
sorts[self.selectors.sort]--;
|
1990
|
-
} else if(sorts[self.selectors.sort] === 1) {
|
1991
|
-
delete sorts[self.selectors.sort];
|
1992
|
-
}
|
1993
|
-
|
1994
|
-
delete $.MixItUp.prototype._instances[self._id];
|
1995
|
-
}
|
1996
|
-
|
1997
|
-
};
|
1998
|
-
|
1999
|
-
/* jQuery Methods
|
2000
|
-
---------------------------------------------------------------------- */
|
2001
|
-
|
2002
|
-
/**
|
2003
|
-
* jQuery .mixItUp() method
|
2004
|
-
* @since 2.0.0
|
2005
|
-
* @extends $.fn
|
2006
|
-
*/
|
2007
|
-
|
2008
|
-
$.fn.mixItUp = function(){
|
2009
|
-
var args = arguments,
|
2010
|
-
dataReturn = [],
|
2011
|
-
eachReturn,
|
2012
|
-
_instantiate = function(domNode, settings){
|
2013
|
-
var instance = new $.MixItUp(),
|
2014
|
-
rand = function(){
|
2015
|
-
return ('00000'+(Math.random()*16777216<<0).toString(16)).substr(-6).toUpperCase();
|
2016
|
-
};
|
2017
|
-
|
2018
|
-
instance._execAction('_instantiate', 0, arguments);
|
2019
|
-
|
2020
|
-
domNode.id = !domNode.id ? 'MixItUp'+rand() : domNode.id;
|
2021
|
-
|
2022
|
-
if(!instance._instances[domNode.id]){
|
2023
|
-
instance._instances[domNode.id] = instance;
|
2024
|
-
instance._init(domNode, settings);
|
2025
|
-
}
|
2026
|
-
|
2027
|
-
instance._execAction('_instantiate', 1, arguments);
|
2028
|
-
};
|
2029
|
-
|
2030
|
-
eachReturn = this.each(function(){
|
2031
|
-
if(args && typeof args[0] === 'string'){
|
2032
|
-
var instance = $.MixItUp.prototype._instances[this.id];
|
2033
|
-
if(args[0] === 'isLoaded'){
|
2034
|
-
dataReturn.push(instance ? true : false);
|
2035
|
-
} else {
|
2036
|
-
var data = instance[args[0]](args[1], args[2], args[3]);
|
2037
|
-
if(data !== undf)dataReturn.push(data);
|
2038
|
-
}
|
2039
|
-
} else {
|
2040
|
-
_instantiate(this, args[0]);
|
2041
|
-
}
|
2042
|
-
});
|
2043
|
-
|
2044
|
-
if(dataReturn.length){
|
2045
|
-
return dataReturn.length > 1 ? dataReturn : dataReturn[0];
|
2046
|
-
} else {
|
2047
|
-
return eachReturn;
|
2048
|
-
}
|
2049
|
-
};
|
2050
|
-
|
2051
|
-
/**
|
2052
|
-
* jQuery .removeStyle() method
|
2053
|
-
* @since 2.0.0
|
2054
|
-
* @extends $.fn
|
2055
|
-
*/
|
2056
|
-
|
2057
|
-
$.fn.removeStyle = function(style, prefix){
|
2058
|
-
prefix = prefix ? prefix : '';
|
2059
|
-
|
2060
|
-
return this.each(function(){
|
2061
|
-
var el = this,
|
2062
|
-
styles = style.split(' ');
|
2063
|
-
|
2064
|
-
for(var i = 0; i < styles.length; i++){
|
2065
|
-
for(var j = 0; j < 4; j++){
|
2066
|
-
switch (j) {
|
2067
|
-
case 0:
|
2068
|
-
var prop = styles[i];
|
2069
|
-
break;
|
2070
|
-
case 1:
|
2071
|
-
var prop = $.MixItUp.prototype._helpers._camelCase(prop);
|
2072
|
-
break;
|
2073
|
-
case 2:
|
2074
|
-
var prop = prefix+styles[i];
|
2075
|
-
break;
|
2076
|
-
case 3:
|
2077
|
-
var prop = $.MixItUp.prototype._helpers._camelCase(prefix+styles[i]);
|
2078
|
-
}
|
2079
|
-
|
2080
|
-
if(
|
2081
|
-
el.style[prop] !== undf &&
|
2082
|
-
typeof el.style[prop] !== 'unknown' &&
|
2083
|
-
el.style[prop].length > 0
|
2084
|
-
){
|
2085
|
-
el.style[prop] = '';
|
2086
|
-
}
|
2087
|
-
|
2088
|
-
if(!prefix && j === 1)break;
|
2089
|
-
}
|
2090
|
-
}
|
2091
|
-
|
2092
|
-
if(el.attributes && el.attributes.style && el.attributes.style !== undf && el.attributes.style.value === ''){
|
2093
|
-
el.attributes.removeNamedItem('style');
|
2094
|
-
}
|
2095
|
-
});
|
2096
|
-
};
|
2097
|
-
|
2098
|
-
})(jQuery);
|