diff options
author | Peter Smit <peter@smitmail.eu> | 2015-02-05 11:08:10 +0200 |
---|---|---|
committer | Peter Smit <peter@smitmail.eu> | 2015-02-05 11:08:10 +0200 |
commit | 03af37554e34582e8c5a9d98ec9f2d3c9884f0d8 (patch) | |
tree | e13334fb2bd83e02fdd05ec6895681d27876cd0f | |
parent | fd1df86c44bfbd13b4df0a66840113b0d18695bc (diff) | |
parent | 02c5bade0fabc24b9b7c05a74c65965e2e53f687 (diff) | |
download | gitea-03af37554e34582e8c5a9d98ec9f2d3c9884f0d8.tar.gz gitea-03af37554e34582e8c5a9d98ec9f2d3c9884f0d8.zip |
Merge branch 'dev' into newcollaboration
47 files changed, 1296 insertions, 358 deletions
diff --git a/.travis.yml b/.travis.yml index b060c69392..85e5f396ea 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,5 +3,13 @@ language: go go: - 1.2 - 1.3 + - 1.4 + - tip sudo: false + +script: go build -v + +notifications: + email: + - u@gogs.io
\ No newline at end of file @@ -1,18 +1,19 @@ -Gogs - Go Git Service [![wercker status](https://app.wercker.com/status/ad0bdb0bc450ac6f09bc56b9640a50aa/s/ "wercker status")](https://app.wercker.com/project/bykey/ad0bdb0bc450ac6f09bc56b9640a50aa) [![Build Status](https://travis-ci.org/gogits/gogs.svg?branch=master)](https://travis-ci.org/gogits/gogs) +Gogs - Go Git Service [![Build Status](https://travis-ci.org/gogits/gogs.svg?branch=master)](https://travis-ci.org/gogits/gogs) ===================== [![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/gogits/gogs?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) Gogs(Go Git Service) is a painless self-hosted Git Service written in Go. -![Demo](https://gowalker.org/public/gogs_demo.gif) +![Demo](http://gogs.qiniudn.com/gogs_demo.gif) -##### Current version: 0.5.11 Beta +##### Current version: 0.5.12 Beta ### NOTICES -- Due to testing purpose, data of [try.gogs.io](https://try.gogs.io) has been reset in **June 21, 2014** and will reset multiple times after. Please do **NOT** put your important data on the site. +- Due to testing purpose, data of [try.gogs.io](https://try.gogs.io) has been reset in **Jan 28, 2015** and will reset multiple times after. Please do **NOT** put your important data on the site. - Demo site [try.gogs.io](https://try.gogs.io) is running under `dev` branch. +- If you think there are vulnerabilities in the project, please talk private to **u@gogs.io**, thanks! #### Other language version @@ -50,7 +51,7 @@ The goal of this project is to make the easiest, fastest and most painless way t - Drone CI integration - Supports MySQL, PostgreSQL and SQLite3 - Social account login(GitHub, Google, QQ, Weibo) -- Multi-language support([7 languages](https://crowdin.com/project/gogs)) +- Multi-language support([9 languages](https://crowdin.com/project/gogs)) ## System Requirements diff --git a/README_ZH.md b/README_ZH.md index a91b0ce57c..be3a2b1bc4 100644 --- a/README_ZH.md +++ b/README_ZH.md @@ -3,9 +3,9 @@ Gogs - Go Git Service [![wercker status](https://app.wercker.com/status/ad0bdb0b Gogs(Go Git Service) 是一个基于 Go 语言的自助 Git 服务。 -![Demo](https://gowalker.org/public/gogs_demo.gif) +![Demo](http://gogs.qiniudn.com/gogs_demo.gif) -##### 当前版本:0.5.11 Beta +##### 当前版本:0.5.12 Beta ## 开发目的 @@ -39,7 +39,7 @@ Gogs 的目标是打造一个最简单、最快速和最轻松的方式搭建自 - Drone CI 持续部署集成 - 支持 MySQL、PostgreSQL 以及 SQLite3 数据库 - 社交帐号登录(GitHub、Google、QQ、微博) -- 多语言支持([7 种语言]([more](https://crowdin.com/project/gogs))) +- 多语言支持([9 种语言]([more](https://crowdin.com/project/gogs))) ## 系统要求 diff --git a/cmd/fix.go b/cmd/fix.go index 5122ff32c7..eff85d6282 100644 --- a/cmd/fix.go +++ b/cmd/fix.go @@ -164,7 +164,7 @@ func runFixLocation(ctx *cli.Context) { fmt.Scanln() // Fix in authorized_keys file. - sshPath := path.Join(models.SshPath, "authorized_keys") + sshPath := path.Join(models.SSHPath, "authorized_keys") if com.IsFile(sshPath) { fmt.Printf("Fixing pathes in file: %s\n", sshPath) if err := rewriteAuthorizedKeys(sshPath, oldPath, execPath); err != nil { diff --git a/cmd/web.go b/cmd/web.go index 241abf2c9c..55b6bf0874 100644 --- a/cmd/web.go +++ b/cmd/web.go @@ -53,7 +53,9 @@ var CmdWeb = cli.Command{ Description: `Gogs web server is the only thing you need to run, and it takes care of all the other things for you`, Action: runWeb, - Flags: []cli.Flag{}, + Flags: []cli.Flag{ + cli.StringFlag{"port, p", "3000", "Temporary port number to prevent conflict", ""}, + }, } type VerChecker struct { @@ -75,13 +77,13 @@ func checkVersion() { // Check dependency version. checkers := []VerChecker{ - {"github.com/Unknwon/macaron", macaron.Version, "0.5.0"}, + {"github.com/Unknwon/macaron", macaron.Version, "0.5.1"}, {"github.com/macaron-contrib/binding", binding.Version, "0.0.4"}, {"github.com/macaron-contrib/cache", cache.Version, "0.0.7"}, - {"github.com/macaron-contrib/csrf", csrf.Version, "0.0.1"}, + {"github.com/macaron-contrib/csrf", csrf.Version, "0.0.3"}, {"github.com/macaron-contrib/i18n", i18n.Version, "0.0.5"}, {"github.com/macaron-contrib/session", session.Version, "0.1.6"}, - {"gopkg.in/ini.v1", ini.Version, "1.0.1"}, + {"gopkg.in/ini.v1", ini.Version, "1.2.0"}, } for _, c := range checkers { ver := strings.Join(strings.Split(c.Version(), ".")[:3], ".") @@ -162,7 +164,7 @@ func newMacaron() *macaron.Macaron { return m } -func runWeb(*cli.Context) { +func runWeb(ctx *cli.Context) { routers.GlobalInit() checkVersion() @@ -179,9 +181,9 @@ func runWeb(*cli.Context) { // Routers. m.Get("/", ignSignIn, routers.Home) m.Get("/explore", ignSignIn, routers.Explore) - // FIXME: when i'm binding form here??? - m.Get("/install", bindIgnErr(auth.InstallForm{}), routers.Install) - m.Post("/install", bindIgnErr(auth.InstallForm{}), routers.InstallPost) + m.Combo("/install", routers.InstallInit). + Get(routers.Install). + Post(bindIgnErr(auth.InstallForm{}), routers.InstallPost) m.Group("", func() { m.Get("/pulls", user.Pulls) m.Get("/issues", user.Issues) @@ -460,6 +462,12 @@ func runWeb(*cli.Context) { // Not found handler. m.NotFound(routers.NotFound) + // Flag for port number in case first time run conflict. + if ctx.IsSet("port") { + setting.AppUrl = strings.Replace(setting.AppUrl, setting.HttpPort, ctx.String("port"), 1) + setting.HttpPort = ctx.String("port") + } + var err error listenAddr := fmt.Sprintf("%s:%s", setting.HttpAddr, setting.HttpPort) log.Info("Listen: %v://%s%s", setting.Protocol, listenAddr, setting.AppSubUrl) diff --git a/conf/app.ini b/conf/app.ini index 1af480a825..b7a0f1a7c5 100644 --- a/conf/app.ini +++ b/conf/app.ini @@ -1,3 +1,6 @@ +# NEVER EVER MODIFY THIS FILE +# PLEASE MAKE CHANGES ON CORRESPONDING CUSTOM CONFIG FILE + ; App name that shows on every page title APP_NAME = Gogs: Go Git Service ; Change it if you run locally @@ -275,5 +278,5 @@ INTERVAL = 24 ARGS = [i18n] -LANGS = en-US,zh-CN,zh-HK,de-DE,fr-CA,nl-NL,lv-LV,ru-RU -NAMES = English,简体中文,繁體中文,Deutsch,Français,Nederlands,Latviešu,Русский +LANGS = en-US,zh-CN,zh-HK,de-DE,fr-CA,nl-NL,lv-LV,ru-RU,ja-JP +NAMES = English,简体中文,繁體中文,Deutsch,Français,Nederlands,Latviešu,Русский,日本语 diff --git a/conf/locale/TRANSLATORS b/conf/locale/TRANSLATORS index 38e4ddc274..6c72f3342a 100644 --- a/conf/locale/TRANSLATORS +++ b/conf/locale/TRANSLATORS @@ -1,6 +1,9 @@ # This file lists all PUBLIC individuals having contributed content to the translation. # Order of name is meaningless. +Akihiro YAGASAKI <yaggytter@momiage.com> +Christoph Kisfeld <christoph.kisfeld@gmail.com> Thomas Fanninger <gogs.thomas@fanninger.at> Łukasz Jan Niemier <lukasz@niemier.pl> -Lafriks <lafriks@gmail.com>
\ No newline at end of file +Lafriks <lafriks@gmail.com> +Miguel de la Cruz <miguel@mcrx.me>
\ No newline at end of file diff --git a/conf/locale/locale_en-US.ini b/conf/locale/locale_en-US.ini index 7db7ca0d47..660fb253bb 100644 --- a/conf/locale/locale_en-US.ini +++ b/conf/locale/locale_en-US.ini @@ -59,12 +59,14 @@ run_user = Run User run_user_helper = The user must have access to Repository Root Path and run Gogs. domain = Domain domain_helper = This affects SSH clone URLs. +http_port = HTTP Port +http_port_helper = Port number which application will listen on. app_url = Application URL app_url_helper = This affects HTTP/HTTPS clone URL and somewhere in e-mail. email_title = E-mail Service Settings (Optional) smtp_host = SMTP Host mailer_user = Sender E-mail -mailer_password = Sender Password +mailer_password = Sender Password notify_title = Notification Settings(Optional) register_confirm = Enable Register Confirmation mail_notify = Enable Mail Notification @@ -512,6 +514,8 @@ dashboard.delete_repo_archives = Delete all repositories archives dashboard.delete_repo_archives_success = All repositories archives have been deleted successfully. dashboard.git_gc_repos = Do garbage collection on repositories dashboard.git_gc_repos_success = All repositories have done garbage collection successfully. +dashboard.resync_all_sshkeys = Rewrite '.ssh/autorized_key' file(caution: non-Gogs keys will be lost) +dashboard.resync_all_sshkeys_success = All public keys have been rewritten successfully. dashboard.server_uptime = Server Uptime dashboard.current_goroutine = Current Goroutines dashboard.current_memory_usage = Current Memory Usage @@ -712,16 +716,3 @@ months = %d months %s years = %d years %s raw_seconds = seconds raw_minutes = minutes - - - - - - - - - - - - - diff --git a/conf/locale/locale_ja-JP.ini b/conf/locale/locale_ja-JP.ini new file mode 100755 index 0000000000..1d1d61493d --- /dev/null +++ b/conf/locale/locale_ja-JP.ini @@ -0,0 +1,728 @@ +app_desc=Go言語で実装したセルフホストGitサーバ
+
+home=ホーム
+dashboard=ダッシュボード
+explore=エスクプローラ
+help=ヘルプ
+sign_in=サインイン
+social_sign_in=SNSでサインイン: ステップ2 <small>アカウント連携</small>
+sign_out=サインアウト
+sign_up=サインアップ
+register=登録
+website=WEBサイト
+version=バージョン
+page=ページ
+template=テンプレート
+language=言語
+
+username=ユーザ名
+email=E-mail
+password=パスワード
+re_type=再入力
+captcha=キャプチャ
+
+repository=リポジトリ
+organization=組織
+mirror=ミラー
+new_repo=新しいリポジトリ
+new_migrate=新しい移行
+new_fork=新しいフォークのリポジトリ
+new_org=新しい組織
+manage_org=組織を管理
+admin_panel=管理者パネル
+account_settings=アカウント設定
+settings=設定
+
+news_feed=ニュースのフィード
+pull_requests=プルリクエスト
+issues=課題
+
+cancel=キャンセル
+
+[install]
+install=インストール
+title=初回実行のインストール手順
+requite_db_desc=Gogs には、MySQL や PostgreSQL 、SQLite3 が必要です。
+db_type=データベースの種類
+host=ホスト
+user=ユーザ
+password=パスワード
+db_name=データベース名
+db_helper=Mysql INNODB エンジン utf8_general_ci の文字セットを使用してください。
+ssl_mode=SSL モード
+path=パス
+sqlite_helper=SQLite3 データベースのファイル パス
+general_title=Gogs の全般設定
+repo_path=リポジトリのルートパス
+repo_path_helper=すべての Git リモート リポジトリはこのディレクトリに保存されます。
+run_user=実行ユーザ
+run_user_helper=ユーザーはリポジトリ ルートパスへのアクセス、及びGogs を実行する権限を所有する必要があります。
+domain=ドメイン
+domain_helper=これはSSHクローンURLに影響する。
+app_url=アプリケーションの URL
+app_url_helper=この設定は、HTTP / HTTPSのクローンURLおよび、一部のメールボックスへのリンクに影響を与えます。
+email_title=E-mailサービス設定(Optional)
+smtp_host=SMTP ホスト
+mailer_user=送信者の電子メール
+mailer_password=送信者のパスワード
+notify_title=通知 Settings(Optional)
+register_confirm=登録の確認を有効にする
+mail_notify=メール通知を有効にする
+admin_title=管理者アカウントの設定
+admin_name=ユーザ名
+admin_password=パスワード
+confirm_password=パスワード確認
+admin_email=E-mail
+install_gogs=Gogs をインストール
+test_git_failed='Git' コマンドテストに失敗: %v
+sqlite3_not_available=このリリース バージョンは SQLite3 をサポートしていません。gobuild バージョンではない、公式のバイナリ バージョンを %s からダウンロードしてください。
+invalid_db_setting=データベースの設定が正しくありません: %v
+invalid_repo_path=リポジトリのルート パスが無効です: %v
+run_user_not_match=実行ユーザーは、現在のユーザーではない: %s-> %s
+save_config_failed=構成の保存に失敗した: %v
+invalid_admin_setting=管理者アカウントの設定が無効です: %v
+install_success=ようこそ!我々はあなたが Gogs を選んでくれて嬉しいです!楽しみましょう!
+
+[home]
+uname_holder=ユーザー名またはEメール
+password_holder=パスワード
+switch_dashboard_context=ダッシュ ボードのコンテキストを切替
+my_repos=私のリポジトリ
+collaborative_repos=共同リポジトリ
+my_orgs=私の組織
+my_mirrors=私のミラー
+
+[explore]
+repos=リポジトリ
+
+[auth]
+create_new_account=新規アカウントを作成
+register_hepler_msg=すでにアカウントをお持ちですか?今すぐログイン !
+social_register_hepler_msg=すでにアカウントをお持ちですか?今すぐバインド !
+disable_register_prompt=申し訳ありませんが、登録が無効になっています。サイト管理者に問い合わせてください。
+disable_register_mail=申し訳ありませんが、登録メールの確認機能が無効になっています。
+remember_me=ログイン状態を保持する
+forgot_password=パスワードを忘れた
+forget_password=パスワードを忘れた?
+sign_up_now=アカウントが必要ですか?今すぐサインアップ
+confirmation_mail_sent_prompt=新しい確認メールを <b>%s</b> に送りました。登録を完了させるために、%d時間以内にあなたのメールボックスを確認してください。
+sign_in_email=E-mailでサイイン
+active_your_account=アカウントをアクティブ
+resent_limit_prompt=申し訳ありませんが、アクティベーションメールは頻繁に送信しています。3 分お待ちください。
+has_unconfirmed_mail=こんにちは %s さん、あなたの電子メール アドレス (<b>%s</b>) は未確認です。もし確認メールをまだ確認できていないか、改めて再送信する場合は、下のボタンをクリックしてください。
+resend_mail=アクティベーションメールを再送信するにはここをクリック
+email_not_associate=この電子メール アドレスは、アカウントには関連付けられません。
+send_reset_mail=パスワードリセットのメールを再送するにはここをクリック
+reset_password=パスワードリセット
+invalid_code=申し訳ありませんが、確認用コードが期限切れまたは無効です。
+reset_password_helper=パスワードをリセットするにはここをクリック
+password_too_short=6文字未満のパスワードは設定できません。
+
+[form]
+UserName=ユーザ名
+RepoName=リポジトリ名
+Email=Eメールアドレス
+Password=パスワード
+Retype=パスワードを再入力
+SSHTitle=SSH キーの名前
+HttpsUrl=HTTPS URL
+PayloadUrl=ペイロードの URL
+TeamName=チーム名
+AuthName=承認名
+AdminEmail=管理者の電子メール
+
+require_error=空にできません
+alpha_dash_error=アルファベット、数字、ハイフン"-"、アンダースコア"_"のいずれかの必要があります
+alpha_dash_dot_error=' アルファベット、数値、ダッシュ(-)、アンダースコア(_) 、ドット(.)のいずれかを入力する必要があります。 '
+min_size_error=' 少なくとも %s 文字の必要があります '
+max_size_error=' %s 文字以下の必要があります '
+email_error=' は有効な電子メール アドレスではない '
+url_error=' は有効な URL はありません。 '
+unknown_error=不明なエラー:
+captcha_incorrect=Captcha が一致しませんでした。
+password_not_match=パスワードと確認用パスワードが一致同していません。
+
+username_been_taken=ユーザー名は既に使用されています。
+repo_name_been_taken=リポジトリ名は既に使用されています。
+org_name_been_taken=組織名は既に使用されています。
+team_name_been_taken=チーム名は既に使用されています。
+email_been_used=電子メール アドレスは既に使用されています。
+ssh_key_been_used=パブリック キー名が使用されています。
+illegal_username=あなたのユーザ名に無効な文字が含まれます。
+illegal_repo_name=リポジトリ名には無効な文字が含まれています。
+illegal_org_name=組織名に無効な文字が含まれています。
+illegal_team_name=チーム名に無効な文字が含まれています。
+username_password_incorrect=ユーザー名またはパスワードが正しくありません。
+enterred_invalid_repo_name=入力したリポジトリの名前が正しいかどうかを確認してください。
+enterred_invalid_owner_name=入力された所有者名が正しいかどうかを確認してください。
+enterred_invalid_password=入力したパスワードが正しいかを確認してください。
+user_not_exist=指定されたユーザーは存在しません。
+last_org_owner=削除するユーザーはチームの最後のメンバーです。別の所有者設定が必要です。
+
+invalid_ssh_key=SSHを確認できません:%s
+unable_verify_ssh_key=GogsはあなたのSSH keyを確認できません。しかし、我々は有効とみなしますので、自分自身で確認してください。
+auth_failed=認証に失敗しました: %v
+
+still_own_repo=アカウント所有のリポジトリがあり、リポジトリの削除または所有者の移譲が必要です。
+still_has_org=アカウントはまだ組織のメンバーであり、組織から退出するか削除する必要があります。
+org_still_own_repo=この組織はまだリポジトリの所有しています、リポジトリを削除または転送する必要があります。
+
+still_own_user=この認証はまだ一部のユーザーによって使用されています。一部のユーザを移動させてから、もう一度削除してください。
+
+target_branch_not_exist=ターゲットブランチが存在しない
+
+[user]
+change_avatar=gravatar.com で自分のアバターを変更
+change_custom_avatar=設定で自分のアバターを変更
+join_on=参加しました
+repositories=リポジトリ
+activity=パブリック・アクティビティ
+followers=フォロワー
+starred=スター
+following=フォロー
+
+[settings]
+profile=プロフィール
+password=パスワード
+ssh_keys=SSH キー
+social=SNSアカウント
+applications=アプリケーション
+orgs=組織
+delete=アカウントを削除
+uid=Uid
+
+public_profile=パブリック プロフィール
+profile_desc=あなたのメールアドレスは公開され、任意のアカウント関連の通知に使用されます。また、Webベースの操作はサイトを介して行います。
+full_name=フルネーム
+website=WEBサイト
+location=ロケーション
+update_profile=プロファイル更新
+update_profile_success=あなたのプロフィールが更新されました。
+change_username=ユーザー名が変更されました
+change_username_desc=ユーザー名が変更されている、継続したいですか?これはあなたのアカウントに関連するすべてのリンクに影響を与える。
+continue=続行
+cancel=キャンセル
+
+enable_custom_avatar=カスタムのアバターを有効にする
+enable_custom_avatar_helper=Gravatarからのフェッチを無効にするのを、有効にします
+choose_new_avatar=新しいアバターを選択
+update_avatar=アバターの設定を更新
+uploaded_avatar_not_a_image=アップロードされたファイルは画像ではない。
+no_custom_avatar_available=利用可能なカスタム アバターがないため、有効にできません。
+update_avatar_success=あなたのアバターの設定が更新されました。
+
+change_password=パスワードを変更
+old_password=現在のパスワード
+new_password=新しいパスワード
+password_incorrect=現在のパスワードが正しくありません。
+change_password_success=パスワードが正常に変更されました。今すぐ新しいパスワード経由でサインインすることができます。
+
+emails=E-mail アドレス
+manage_emails=E-mail アドレスを管理
+email_desc=あなたのプライマリメールアドレスは、通知やその他の操作に使用されます。
+primary=プライマリー
+primary_email=プライマリに設定
+delete_email=削除
+add_new_email=新しいe-mailアドレスを追加
+add_email=電子メールを追加します。
+add_email_success=新しいe-mail アドレスが追加されました。
+
+manage_ssh_keys=SSH キーを管理
+add_key=キーを追加
+ssh_desc=これはあなたのアカウントに関連付けられている SSH キーの一覧です。あなたが認識していないキーを削除します。
+ssh_helper=<strong>ヘルプが必要ですか?</strong> 我々のガイドをご覧ください。 <a href="%s"> SSH キーを生成</a> <a href="%s"> SSH の一般的な問題</a>
+add_new_key=SSH キーを追加
+key_name=キーの名前
+key_content=コンテンツ
+add_key_success=新しい SSH キーが追加されました !
+delete_key=削除
+add_on=追加された
+last_used=最終使用日
+no_activity=最近の活動なし
+
+manage_social=関連付けられているSNSアカウントを管理
+social_desc=これは関連付けられたソーシャルアカウントのリストです。あなたが認識していない結び付けを削除します。
+unbind=バインド解除
+unbind_success=SNSアカウントがバインドされていない。
+
+manage_access_token=個人のアクセス トークンを管理
+generate_new_token=新しいトークンを生成
+tokens_desc=生成したトークンを利用して Gogs の API にアクセスすることができます。
+new_token_desc=今のところ、全てのトークンはあなたのアカウントにフルアクセスできます。
+token_name=トークン名
+generate_token=トークンを生成
+generate_token_succees=新しいアクセス トークンは正常に生成されました !今すぐあなたの新しいアクセス トークンをコピーしておいてください。二度と見ることはできませんので確認してください!
+delete_token=削除
+delete_token_success=個人のアクセス トークンは正常に削除されました!同時にあなたのアプリケーションを更新することを忘れないでください。
+
+delete_account=アカウントを削除
+delete_prompt=この操作はあなたのアカウントを完全に削除し、復旧<strong>できない</strong> !
+confirm_delete_account=削除の確認
+delete_account_title=アカウントの削除
+delete_account_desc=このアカウントは永久に削除しようとしている、継続しますか?
+
+[repo]
+owner=オーナー
+repo_name=リポジトリ名
+repo_name_helper=偉大なリポジトリ名は短い。思い出に残り、そして<strong>一意</strong>だ。
+visibility=ビジビリティ
+visiblity_helper=このリポジトリは <span class="label label-red label-radius"> プライベート</span> です。
+fork_repo=フォークのリポジトリ
+fork_from=フォーク元
+fork_visiblity_helper=フォークされたリポジトリは可視状態を変更できません
+repo_desc=説明
+repo_lang=言語
+repo_lang_helper=.gitignore ファイルを選択
+license=ライセンス
+license_helper=ライセンス ファイルを選択
+init_readme=README.md 付きでリポジトリを初期化
+create_repo=リポジトリを作成
+default_branch=デフォルトのブランチ
+mirror_interval=ミラー 間隔(時)
+goget_meta=Go-Get メタ
+goget_meta_helper=このリポジトリは <span class="label label-blue label-radius"> Go-Getable </span> になります
+
+need_auth=認証が必要
+migrate_type=マイグレーションの種類
+migrate_type_helper=このリポジトリは <span class="label label-blue label-radius"> ミラー</span> になります
+migrate_repo=リポジトリを移行
+
+copy_link=コピー
+click_to_copy=クリップボードにコピー
+copied=コピー成功
+clone_helper=クローニングのヘルプが必要ですか?<a target="_blank"href="%s"> ヘルプ</a> を参照してください!
+unwatch=Unwatch
+watch=Watch
+unstar=Unstar
+star=Star
+fork=Fork
+
+no_desc=説明なし
+quick_guide=クイック ガイド
+clone_this_repo=このリポジトリのクローンを作成
+create_new_repo_command=コマンドラインで新しいリポジトリを作成します。
+push_exist_repo=コマンド ・ ラインから既存のリポジトリをプッシュ
+
+branch=ブランチ
+tree=ツリー
+branch_and_tags=ブランチ& タグ
+branches=ブランチ
+tags=タグ
+issues=課題
+commits=コミット
+releases=リリース
+file_raw=生データ
+file_history=履歴
+file_view_raw=生データを見る
+
+commits.commits=コミット
+commits.search=コミットの検索
+commits.find=検索
+commits.author=作者
+commits.message=メッセージ
+commits.date=日付
+commits.older=古い
+commits.newer=新しい
+
+settings=設定
+settings.options=オプション
+settings.collaboration=コラボレーション
+settings.hooks=Webhooks
+settings.githooks=Git のフック
+settings.deploy_keys=デプロイキー
+settings.basic_settings=基本設定
+settings.danger_zone=危険地帯
+settings.site=公式サイト
+settings.update_settings=設定の更新
+settings.change_reponame=リポジトリ名が変更されました
+settings.change_reponame_desc=リポジトリの名前が変更されています、継続しますか?このリポジトリ関連すべてのリンクに影響を与えます。
+settings.transfer=オーナー移転
+settings.transfer_desc=リポジトリをあなたが管理者権限を持っている別のユーザーまた組織に移譲します。
+settings.new_owner_has_same_repo=新しいオーナーは、既に同じ名前のリポジトリを持っています。
+settings.delete=このリポジトリを削除
+settings.delete_desc=リポジトリを削除すると元に戻せません。確実に確認してください。
+settings.transfer_notices=<p>-新オーナーは個人ユーザの場合、あなたはにアクセスできなくなります。</p><p>-新オーナーは組織であり、かつあなたが組織のオーナーに所属する場合、あなたはアクセス権を維持します。</p>
+settings.update_settings_success=リポジトリ オプションが更新されました。
+settings.transfer_owner=新しいオーナー
+settings.make_transfer=転送
+settings.transfer_succeed=リポジトリの所有権は正常に転送されました。
+settings.confirm_delete=削除の確認
+settings.add_collaborator=新しい共同編集者を追加
+settings.add_collaborator_success=新しい共同編集者が追加されました。
+settings.remove_collaborator_success=共同編集者が削除されました。
+settings.user_is_org_member=ユーザーは組織の一員なので、共同編集者として追加することはできません。
+settings.add_webhook=Webhook を追加
+settings.hooks_desc=Webhooksは、Gogsで特定のイベントの発生時に指定された外部サービスに通知を許可します。イベントが発生すると、それぞれ指定されたUrlに、POSTリクエストが送られます。詳細はこちらのの <a target="_blank"href="%s"> Webhooks ガイド</a>をご覧ください。
+settings.githooks_desc=Git のフックは Git 自体によって提供されています。以下のリストのファイルを編集して、サポートされているフックのカスタム操作を適用することができます。
+settings.githook_edit_desc=もしフックがアクティブではない場合は、サンプルコンテンツが表示されます。コンテンツを空白にするにはこのフックを無効にします。
+settings.githook_name=フックの名前
+settings.githook_content=コンテンツをフック
+settings.update_githook=フックを更新
+settings.remove_hook_success=Webhookが削除されました。
+settings.add_webhook_desc=私たちは、指定されたURLに購読されたイベントの詳細を <code>POST</code>リクエストとして送信します。あなたは、異なるデータ受信モード(JSONまたは, <code>x-www-form-urlencoded</code>, <em>その他</em>) を設定することができます。詳細については、<a target="_blank" href="%s">Webhookガイド</a>を参照してください。
+settings.payload_url=ペイロードの URL
+settings.content_type=コンテンツ タイプ
+settings.secret=秘密
+settings.event_desc=どのイベントをこのWEBフックのトリガーにしますか?
+settings.event_push_only=<code>push</code> イベントのみ
+settings.active=アクティブ
+settings.active_helper=このフックのトリガーが引かれた時に、イベントの詳細を配信します。
+settings.add_hook_success=新しい webhook が追加されました。
+settings.update_webhook=Webhookを更新
+settings.update_hook_success=Webhook を更新しました。
+settings.delete_webhook=Webhook を削除
+settings.recent_deliveries=最近のデリバリー
+settings.hook_type=フックタイプ
+settings.add_slack_hook_desc=<a href="%s"> Slack</a> インテグレーションをリポジトリに追加します。
+settings.slack_token=トークン
+settings.slack_domain=ドメイン
+settings.slack_channel=チャンネル
+
+diff.browse_source=ソースを参照
+diff.parent=親
+diff.commit=コミット
+diff.data_not_available=差分データは利用できません。
+diff.show_diff_stats=差分情報を表示
+diff.stats_desc=共有<strong>%d 個のファイルを変更した</strong>、<strong>%d 個の追加</strong> と <strong>%d 個の削除</strong>を含む
+diff.bin=BIN
+diff.view_file=ファイルの表示
+
+release.releases=リリース
+release.new_release=新しいリリース
+release.draft=ドラフト
+release.prerelease=プレリリース
+release.stable=安定
+release.edit=編集
+release.ahead=このリリース以降 %s へ <strong>%d</strong> コミット
+release.source_code=ソース コード
+release.tag_name=タグ名
+release.target=ターゲット
+release.tag_helper=既存のタグを選択するか、新しいタグを作成し発行します。
+release.release_title=リリース タイトル
+release.content_with_md=<a href="%s"> Markdown</a> コンテンツ
+release.write=書込み
+release.preview=プレビュー
+release.content_placeholder=コンテンツを書く
+release.loading=読み込み中…
+release.prerelease_desc=これはリリース前のものです
+release.prerelease_helper=このリリースは非プロダクション利用として識別します。
+release.publish=リリースを発行
+release.save_draft=下書きを保存
+release.edit_release=リリースを編集
+release.tag_name_already_exist=このタグ名には既にリリースが存在します。
+
+[org]
+org_name_holder=組織名
+org_name_helper=偉大な組織の名は短く覚えやすいです。
+org_email_helper=組織の電子メールはすべての通知や確認を受け取ります。
+create_org=組織を作成
+repo_updated=更新した
+people=人々
+invite_someone=誰かを招待
+teams=チーム
+lower_members=メンバー
+lower_repositories=リポジトリ
+create_new_team=新しいチームを作成
+org_desc=説明
+team_name=チーム名
+team_desc=説明
+team_name_helper=会話の時、この名前を使用しチーム名を表明します。
+team_desc_helper=このチームに関する全ての情報は?
+team_permission_desc=このチームに必要な権限レベルは?
+
+settings=設定
+settings.options=オプション
+settings.full_name=フルネーム
+settings.website=WEBサイト
+settings.location=ロケーション
+settings.update_settings=設定の更新
+settings.change_orgname=組織名が変更されました
+settings.change_orgname_desc=組織名が変更されています、継続しますか?これはすべての関連リンクに影響を与えます。
+settings.update_setting_success=組織の設定が更新されました。
+settings.delete=組織を削除
+settings.delete_account=この組織を削除
+settings.delete_prompt=操作はこの組織を完全に削除し、復旧<strong>できない</strong>!
+settings.confirm_delete_account=削除の確認
+settings.delete_org_title=組織の削除
+settings.delete_org_desc=この組織は完全に削除されます、継続しますか?
+settings.hooks_desc=この組織のもとで <strong>すべてのリポジトリ</strong> に対してトリガーされる webhook を追加します。
+
+members.public=パブリック
+members.public_helper=プライベートにする
+members.private=プライベート
+members.private_helper=公開する
+members.owner=オーナー
+members.member=メンバー
+members.conceal=隠す
+members.remove=削除
+members.leave=退出
+members.invite_desc=%s に招待する新しいメンバーをユーザ名を入力してください:
+members.invite_now=今すぐ招待
+
+teams.join=参加
+teams.leave=退出
+teams.read_access=読み取りアクセス権
+teams.read_access_helper=このチームはリポジトリの閲覧とクローンをすることができます。
+teams.write_access=書き込みアクセス権
+teams.write_access_helper=このチームはリポジトリを読むだけではなく、プッシュすることもできます。
+teams.admin_access=管理者のアクセス権
+teams.admin_access_helper=このチームはリポジトリにプッシュ/プル、及び他の共同編集者を追加することができます。
+teams.no_desc=このチームは説明がありません。
+teams.settings=設定
+teams.owners_permission_desc=オーナーは<strong>すべてのリポジトリ</strong> へのフルアクセス権、組織の <strong>管理権限</strong>を持ちます。
+teams.members=チーム メンバー
+teams.update_settings=設定の更新
+teams.delete_team=このチームを削除
+teams.add_team_member=チーム メンバーを追加
+teams.delete_team_title=チームの削除
+teams.delete_team_desc=このチームを削除します、継続しますか?このチームのメンバーはいくつかのリポジトリへのアクセスを失う可能性があります。
+teams.delete_team_success=指定のチームが正常に削除されました。
+teams.read_permission_desc=このチームは<strong>読み取り</strong>権限を持ち: メンバーはリポジトリの表示及びクローンの作成ができます。
+teams.write_permission_desc=このチームは<strong>書き込み</strong>権限を持ち: メンバーはリポジトリの表示及リポジトリへのプッシュができます。
+teams.admin_permission_desc=このチームは<strong>管理者</strong>の権限を持ち: メンバーはチームのリポジトリに対して、読み取り、プッシュや共同編集者の追加ができます。
+teams.repositories=チームのリポジトリ
+teams.add_team_repository=チームのリポジトリを追加
+teams.remove_repo=削除(Remove)
+teams.add_nonexistent_repo=追加しようとしているリポジトリは存在しません。まずはじめに作成してください。
+
+[admin]
+dashboard=ダッシュボード
+users=ユーザ
+organizations=組織
+repositories=リポジトリ
+authentication=認証
+config=コンフィギュレーション
+notices=システム通知
+monitor=モニタリング
+prev=前へ
+next=次へ
+
+dashboard.statistic=統計
+dashboard.operations=操作
+dashboard.system_status=システム モニターのステータス
+dashboard.statistic_info=Gogs データベースは <b>%d</b> ユーザ, <b>%d</b> 組織, <b>%d</b> 公開鍵, <b>%d</b> リポジトリ, <b>%d</b> ウォッチ, <b>%d</b> スター, <b>%d</b> 行動, <b>%d</b> アクセス, <b>%d</b> 問題, <b>%d</b> コメント, <b>%d</b> ソーシャルアカウント, <b>%d</b> フォロー, <b>%d</b> ミラー, <b>%d</b> リリース, <b>%d</b> ログイン元, <b>%d</b> webhook, <b>%d</b> マイルストーン, <b>%d</b> ラベル, <b>%d</b> フックタスク, <b>%d</b> チーム, <b>%d</b> アップデートタスク, <b>%d</b> 添付ファイル の情報を持っています。
+dashboard.operation_name=操作の名前
+dashboard.operation_switch=スイッチ
+dashboard.operation_run=実行
+dashboard.clean_unbind_oauth=結び付けられていない OAuth をクリーン
+dashboard.clean_unbind_oauth_success=結び付けられていない全ての OAuth を正常に削除しました。
+dashboard.delete_inactivate_accounts=非アクティブのアカウントをすべて削除
+dashboard.delete_inactivate_accounts_success=すべての非アクティブアカウントは正常に削除されました。
+dashboard.delete_repo_archives=リポジトリのすべてのアーカイブを削除
+dashboard.delete_repo_archives_success=リポジトリのすべてのアーカイブが正常に削除されました。
+dashboard.git_gc_repos=リポジトリでのガベージコレクションを実行します。
+dashboard.git_gc_repos_success=すべてのリポジトリは正常にガベージ コレクションを行いました。
+dashboard.server_uptime=サーバーの稼働時間
+dashboard.current_goroutine=現在のGoroutine
+dashboard.current_memory_usage=現在のメモリ使用量
+dashboard.total_memory_allocated=割り当てられたメモリの合計
+dashboard.memory_obtained=配分されたメモリ量
+dashboard.pointer_lookup_times=ポインタ参照回数
+dashboard.memory_allocate_times=メモリ割当回数
+dashboard.memory_free_times=メモリ解放回数
+dashboard.current_heap_usage=現在のヒープ使用量
+dashboard.heap_memory_obtained=配分されたヒープ メモリ量
+dashboard.heap_memory_idle=アイドルのヒープ メモリ量
+dashboard.heap_memory_in_use=使用中のヒープ メモリ
+dashboard.heap_memory_released=ヒープ メモリが解放されました
+dashboard.heap_objects=ヒープ オブジェクト
+dashboard.bootstrap_stack_usage=ブートストラップスタック使用量
+dashboard.stack_memory_obtained=配分されたスタック メモリ量
+dashboard.mspan_structures_usage=MSpan 構造体の使用量
+dashboard.mspan_structures_obtained=配分されたMSpan 構造体
+dashboard.mcache_structures_usage=MCache 構造体の使用量
+dashboard.mcache_structures_obtained=分配されたMCache 構造体
+dashboard.profiling_bucket_hash_table_obtained=ハッシュテーブル分析に割り当てられたメモリ
+dashboard.gc_metadata_obtained=GCメタデータ取得
+dashboard.other_system_allocation_obtained=他のシステムに割り当てられたメモリ
+dashboard.next_gc_recycle=次回のGCリサイクル
+dashboard.last_gc_time=前回GCからの時間
+dashboard.total_gc_time=GC一時停止の合計
+dashboard.total_gc_pause=GC一時停止の合計
+dashboard.last_gc_pause=直近のGC一時停止
+dashboard.gc_times=GC実行回数
+
+users.user_manage_panel=ユーザー管理パネル
+users.new_account=新規アカウントを作成
+users.name=名前
+users.activated=アクティブ化
+users.admin=アドミン
+users.repos=リポジトリ
+users.created=作成されました
+users.edit=編集
+users.auth_source=認証元
+users.local=ローカル
+users.auth_login_name=認証ログイン名
+users.update_profile_success=アカウントのプロファイルが更新されました。
+users.edit_account=アカウントの編集
+users.is_activated=アカウントがアクティブされました
+users.is_admin=このアカウントには管理者の権限を持つ
+users.allow_git_hook=このアカウントには Git のフックを作成する権限を持つ
+users.update_profile=アカウント ・ プロファイルを更新
+users.delete_account=このアカウントを削除
+users.still_own_repo=アカウント所有のリポジトリがあり、リポジトリの削除または所有者の移譲が必要です。
+users.still_has_org=アカウントはまだ組織のメンバーであり、組織から退出するか削除する必要があります。
+
+orgs.org_manage_panel=組織の管理パネル
+orgs.name=名前
+orgs.teams=チーム
+orgs.members=メンバー
+
+repos.repo_manage_panel=リポジトリの管理パネル
+repos.owner=オーナー
+repos.name=名前
+repos.private=プライベート
+repos.watches=Watches
+repos.stars=Stars
+repos.issues=課題
+
+auths.auth_manage_panel=承認の管理パネル
+auths.new=新しい認証元を追加
+auths.name=名前
+auths.type=タイプ
+auths.enabled=Enabled
+auths.updated=Updated
+auths.auth_type=認証の種類
+auths.auth_name=認証名
+auths.domain=ドメイン
+auths.host=ホスト
+auths.port=ポート
+auths.base_dn=ベースのドメイン名
+auths.attributes=属性検索
+auths.filter=検索フィルター
+auths.ms_ad_sa=Ms Ad SA
+auths.smtp_auth=SMTP 認証の種類
+auths.smtphost=SMTP ホスト
+auths.smtpport=SMTP ポート
+auths.enable_tls=TLS 暗号化を有効にする
+auths.enable_auto_register=自動登録を有効にする
+auths.tips=ヒント
+auths.edit=認証設定を編集
+auths.activated=認証がアクティブされました
+auths.update_success=認証の設定が正常に更新されました。
+auths.update=認証設定の更新
+auths.delete=この権限を削除
+auths.delete_auth_title=認証の削除
+auths.delete_auth_desc=認証を削除します、継続しますか?
+
+config.server_config=サーバーの構成
+config.app_name=アプリケーション名
+config.app_ver=アプリケーションのバージョン
+config.app_url=アプリケーションの URL
+config.domain=ドメイン
+config.offline_mode=オフラインモード
+config.disable_router_log=ルーターのログを無効にする
+config.run_user=実行ユーザ
+config.run_mode=実行モード
+config.repo_root_path=リポジトリのルートパス
+config.static_file_root_path=静的ファイルのルートパス
+config.log_file_root_path=ログ ファイルのルート パス
+config.script_type=スクリプトの種類
+config.reverse_auth_user=リバース認証ユーザ
+config.db_config=データベースの構成
+config.db_type=タイプ
+config.db_host=ホスト
+config.db_name=名前
+config.db_user=ユーザ
+config.db_ssl_mode=SSL モード
+config.db_ssl_mode_helper=(「postgres」のみ)
+config.db_path=パス
+config.db_path_helper=(「sqlite3」のみ)
+config.service_config=サービスの構成
+config.register_email_confirm=電子メールの確認を必要
+config.disable_register=登録を無効にする
+config.require_sign_in_view=サインインを要求
+config.mail_notify=メール通知
+config.enable_cache_avatar=アバターのキャッシュを有効にします。
+config.active_code_lives=コードリンクの有効期限をアクティブ
+config.reset_password_code_lives=パスワードリンクの有効期限をリセット
+config.webhook_config=Webhook設定
+config.task_interval=タスクの間隔
+config.deliver_timeout=送信タイムアウト
+config.mailer_config=メーラーの構成
+config.mailer_enabled=有効にした
+config.mailer_name=名前
+config.mailer_host=ホスト
+config.mailer_user=ユーザ
+config.oauth_config=OAuth 構成
+config.oauth_enabled=Enabled
+config.cache_config=キャッシュの構成
+config.cache_adapter=キャッシュ アダプター
+config.cache_interval=キャッシュ間隔
+config.cache_conn=キャッシュ接続
+config.session_config=セッションの構成
+config.session_provider=セッション プロバイダー
+config.provider_config=プロバイダーの構成
+config.cookie_name=クッキー名
+config.enable_set_cookie=クッキーの設定を有効にする
+config.gc_interval_time=GC 間隔
+config.session_life_time=セッションのライフタイム
+config.https_only=HTTPS のみ
+config.cookie_life_time=クッキーのライフタイム
+config.picture_config=画像構成
+config.picture_service=画像サービス
+config.disable_gravatar=グラバターを無効にする
+config.log_config=ログの構成
+config.log_mode=ログ モード
+
+monitor.cron=Cron タスク
+monitor.name=名前
+monitor.schedule=スケジュール
+monitor.next=次回
+monitor.previous=前回
+monitor.execute_times=実行回数
+monitor.process=実行中のプロセス
+monitor.desc=説明
+monitor.start=開始日時
+monitor.execute_time=実行時間:
+
+notices.system_notice_list=システム通知
+notices.type=タイプ
+notices.type_1=リポジトリ
+notices.desc=説明
+notices.op=Op。
+notices.delete_success=システム通知が正常に削除されました。
+
+[action]
+create_repo=リポジトリ <a href="%s/%s"> %s</a>を作成しました
+commit_repo=<a href="%s/%s">%s</a>を<a href="%s/%s/src/%s">%s</a>にプッシュしました
+create_issue=問題 <a href="%s/%s/issues/%s"> %s #%s</a> を開きました
+comment_issue=問題 <a href="%s/%s/issues/%s"> %s #%s</a> のコメント
+transfer_repo=リポジトリ <code>%s</code> を <a href="/%s%s">%s</a> へ転送しました
+push_tag=<a href="%s/%s">%s</a> に タグ <a href="%s/%s/src/%s">%s</a> をプッシュしました
+compare_2_commits=これら 2 のコミットの比較を閲覧する
+
+[tool]
+ago=前
+from_now=今から
+now=今
+1s=1 秒 %s
+1m=1 分 %s
+1h=1 時間 %s
+1d=1 日 %s
+1w=1 週間 %s
+1mon=1 ヶ月 %s
+1y=1 年間 %s
+seconds=%d 秒 %s
+minutes=%d 分の %s
+hours=%d 時間 %s
+days=%d 日 %s
+weeks=%d 週間 %s
+months=%d ヶ月 %s
+years=%d 年 %s
+raw_seconds=秒
+raw_minutes=分
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/conf/locale/locale_ru-RU.ini b/conf/locale/locale_ru-RU.ini index 6655342fe0..b0da5c550f 100755 --- a/conf/locale/locale_ru-RU.ini +++ b/conf/locale/locale_ru-RU.ini @@ -61,7 +61,7 @@ domain=Домен domain_helper=This affects SSH clone URLs.
app_url=URL приложения
app_url_helper=This affects HTTP/HTTPS clone URL and somewhere in e-mail.
-email_title=E-mail Service Settings (Optional)
+email_title=Настройки службы электронной почты (опционально)
smtp_host=Узел SMTP
mailer_user=Электронная почта отправителя
mailer_password=Пароль отправителя
@@ -75,7 +75,7 @@ confirm_password=Подтвердить пароль admin_email=Эл. почта
install_gogs=Установить Gogs
test_git_failed=Не удалось проверить 'git' команду: %v
-sqlite3_not_available=Your release version does not support SQLite3, please download the official binary version from %s, NOT the gobuild version.
+sqlite3_not_available=Ваша версия не поддерживает SQLite3, пожалуйста скачайте официальную бинарную версию от %s, а не версию gobuild.
invalid_db_setting=Настройки базы данных не правильные: %v
invalid_repo_path=Недопустимый путь к корню репозитория: %v
run_user_not_match=Run user isn't the current user: %s -> %s
@@ -98,9 +98,9 @@ repos=Репозитории [auth]
create_new_account=Создать новый аккаунт
register_hepler_msg=Уже есть аккаунт? Авторизуйтесь!
-social_register_hepler_msg=Уже есть учетная запись? Свяжите ее соцсетью!
+social_register_hepler_msg=Уже есть учетная запись? Свяжите ее с соцсетью!
disable_register_prompt=Извините, возможность регистрации отключена. Пожалуйста, свяжитесь с администратором сайта.
-disable_register_mail=Sorry, Register Mail Confirmation has been disabled.
+disable_register_mail=К сожалению подтверждение регистрации по почте отключено.
remember_me=Запомнить меня
forgot_password=Забыли пароль
forget_password=Забыли пароль?
@@ -109,7 +109,7 @@ confirmation_mail_sent_prompt=Новое письмо для подтвержд sign_in_email=Войдите в свой адрес электронной почты
active_your_account=Активируйте свой аккаунт
resent_limit_prompt=Вы слишком часто отправляете письмо с активацией. Подождите 3 минуты, пожалуйста.
-has_unconfirmed_mail=Hi %s, you have an unconfirmed e-mail address <b>%s</b>). If you haven't received a confirmation e-mail or need to resend a new one, please click on the button below.
+has_unconfirmed_mail=Здравствуйте, %s! У вас есть неподтвержденный адрес электронной почты (<b>%s</b>). Если вам не приходило письмо с подтверждением или нужно выслать новое письмо, нажмите на кнопку ниже.
resend_mail=Нажмите здесь, чтобы переотправить активационное письмо
email_not_associate=Этот адрес электронной почты не связан ни с одной учетной записью.
send_reset_mail=Нажмите сюда, чтобы отправить письмо для сброса пароля
@@ -157,17 +157,17 @@ enterred_invalid_repo_name=Пожалуйста, убедитесь, что вв enterred_invalid_owner_name=Убедитесь, что введенное имя владельца верное.
enterred_invalid_password=Убедитесь, что введенный пароль верен.
user_not_exist=Данный пользователь не существует.
-last_org_owner=The user to remove is the last member in owner team. There must be another owner.
+last_org_owner=Удаляемый пользователь является последним в команде владельцев. Должен быть хотя бы один владелец.
invalid_ssh_key=К сожалению, мы не смогли проверить ваш SSH-ключ: %s
unable_verify_ssh_key=Gogs не может проверить ваш SSH-ключ, но мы допускаем, что он действителен. Пожалуйста, удостоверьтесь самостоятельно, что ключ действителен.
auth_failed=Ошибка аутентификации: %v
-still_own_repo=Your account still have ownership of repository, you have to delete or transfer them first.
-still_has_org=Your account still have membership of organization, you have to left or delete them first.
+still_own_repo=На вашем аккаунте все еще остается как минимум один репозиторий, сначала вам нужно удалить или передать его.
+still_has_org=Вы находитесь в организации, сперва Вам необходимо покинуть ее или удалить.
org_still_own_repo=Данная организация все еще является владельцем репозиториев, необходимо удалить или переместить их в начале.
-still_own_user=This authentication still has used by some users, you should move them and then delete again.
+still_own_user=Эта проверка подлинности по-прежнему используется некоторыми пользователями, вы должны переместить их и затем снова удалить.
target_branch_not_exist=Целевая ветка не существует
@@ -192,7 +192,7 @@ delete=Удалить аккаунт uid=UID
public_profile=Открытый профиль
-profile_desc=Your E-mail address is public and will be used for any account related notifications, and any web based operations made via the site.
+profile_desc=Адрес вашей электронной почты является публичным и будет использован для любых уведомлений, связанных с аккаунтом, а также для любых действий, совершенных через сайт.
full_name=ФИО
website=Веб-сайт
location=Местоположение
@@ -217,15 +217,15 @@ new_password=Новый пароль password_incorrect=Текущий пароль не правильный.
change_password_success=Пароль сменен успешно. Теперь вы можете войти с новым паролем.
-emails=E-mail Addresses
-manage_emails=Manage e-mail addresses
-email_desc=Your primary e-mail address will be used for notifications and other operations.
-primary=Primary
-primary_email=Set as primary
-delete_email=Delete
-add_new_email=Add new e-mail address
-add_email=Add e-mail
-add_email_success=Your new E-mail address was successfully added.
+emails=Адреса электронной почты
+manage_emails=Управление адресами электронной почты
+email_desc=Ваш основной адрес электронной почты будет использован для уведомлений и других операций.
+primary=Основной
+primary_email=Установить как основной
+delete_email=Удалить
+add_new_email=Добавить новый адрес электронной почты
+add_email=Добавить электронную почту
+add_email_success=Новый адрес электронной почты успешно добавлен.
manage_ssh_keys=Управление SSH ключами
add_key=Добавить ключ
@@ -240,20 +240,20 @@ add_on=Добавлено last_used=Последний раз использовался
no_activity=Еще не применялся
-manage_social=Manage Associated Social Accounts
-social_desc=This is a list of associated social accounts. Remove any binding that you do not recognize.
+manage_social=Управление привязанными учетными записями в соцсетях
+social_desc=Это список привязанных учетных записей в соцсетях. Удаляйте любые неизвестные вам привязки.
unbind=Отвязать
unbind_success=Социальная учетная запись отвязана.
-manage_access_token=Manage Personal Access Tokens
+manage_access_token=Управление Токенами Персонального Доступа
generate_new_token=Создать новый token
-tokens_desc=Tokens you have generated that can be used to access the Gogs API.
-new_token_desc=As for now, every token will have full access to your account.
+tokens_desc=Созданные вами токены могут использоваться для доступа к Gogs API.
+new_token_desc=Пока что каждый токен будет иметь полный доступ к вашей учетной записи.
token_name=Имя маркера
generate_token=Генерировать маркер
-generate_token_succees=New access token has been generated successfully! Make sure to copy your new personal access token now. You won't be able to see it again!
+generate_token_succees=Успешно создан новый токен доступа! Пожалуйста сделайте копию вашего нового токена персонального доступа. Вы не сможете увидеть его снова!
delete_token=Удалить
-delete_token_success=Personal access token has been deleted successfully! Don't forget to update your applications as well.
+delete_token_success=Персональный токен доступа был успешно удален! Не забудьте так же обновить ваши приложения.
delete_account=Удалить свой аккаунт
delete_prompt=Этим действием вы удалите свою учетную запись навсегда и <strong>НЕ СМОЖЕТЕ</strong> ее вернуть!
@@ -285,7 +285,7 @@ goget_meta_helper=This repository will be <span class="label label-blue label-ra need_auth=Требуется авторизация
migrate_type=Тип миграции
migrate_type_helper=Этот репозиторий будет <span class="label label-blue label-radius">зеркалом</span>
-migrate_repo=Migrate Repository
+migrate_repo=Перенос репозитория
copy_link=Копировать
click_to_copy=Скопировать в буфер обмена
@@ -322,7 +322,7 @@ commits.author=Автор commits.message=Сообщение
commits.date=Дата
commits.older=Раньше
-commits.newer=Newer
+commits.newer=Новее
settings=Настройки
settings.options=Опции
@@ -347,9 +347,9 @@ settings.transfer_owner=Новый владелец settings.make_transfer=Выполнить передачу
settings.transfer_succeed=Repository ownership has been transferred successfully.
settings.confirm_delete=Подтвердить удаление
-settings.add_collaborator=Add New Collaborator
-settings.add_collaborator_success=New collaborator has been added.
-settings.remove_collaborator_success=Collaborator has been removed.
+settings.add_collaborator=Добавить нового соавтора
+settings.add_collaborator_success=Был добавлен новый соавтор.
+settings.remove_collaborator_success=Соавтор был удален.
settings.user_is_org_member=User is organization member who cannot be added as a collaborator.
settings.add_webhook=Добавить Webhook
settings.hooks_desc=Webhooks allow external services to be notified when certain events happen on Gogs. When the specified events happen, we'll send a POST request to each of the URLs you provide. Learn more in our <a target="_blank" href="%s">Webhooks Guide</a>.
@@ -462,14 +462,14 @@ members.invite_now=Пригласите сейчас teams.join=Объединить
teams.leave=Выйти
teams.read_access=Доступ на чтение
-teams.read_access_helper=This team will be able to view and clone its repositories.
+teams.read_access_helper=Эта команда будет иметь возможность просматривать и клонировать ее репозитории.
teams.write_access=Доступ на запись
-teams.write_access_helper=This team will be able to read its repositories, as well as push to them.
+teams.write_access_helper=Эта команда будет в состоянии прочитать ее репозитории, а также посылать изменения.
teams.admin_access=Доступ администратора
teams.admin_access_helper=This team will be able to push/pull to its repositories, as well as add other collaborators to them.
teams.no_desc=Эта группа не имеет описания
teams.settings=Настройки
-teams.owners_permission_desc=Owners have full access to <strong>all repositories</strong> and have <strong>admin rights</strong> to the organization.
+teams.owners_permission_desc=Владельцы имеют полный доступ ко <strong>всем репозиториям</strong> и имеют <strong>права администратора</strong> организации.
teams.members=Члены группы разработки
teams.update_settings=Обновить настройки
teams.delete_team=Удалить эту группу разработки
@@ -486,7 +486,7 @@ teams.remove_repo=Удалить teams.add_nonexistent_repo=Вы добавляете в отсутствующий репозиторий, пожалуйста сначала его создайте.
[admin]
-dashboard=Dashboard
+dashboard=Панель управления
users=Пользователи
organizations=Организации
repositories=Репозитории
@@ -508,14 +508,14 @@ dashboard.clean_unbind_oauth=Clean unbound OAuthes dashboard.clean_unbind_oauth_success=All unbind OAuthes have been deleted successfully.
dashboard.delete_inactivate_accounts=Удалить все неактивированные учетные записи
dashboard.delete_inactivate_accounts_success=Все неактивированные учетные записи удалены успешно.
-dashboard.delete_repo_archives=Delete all repositories archives
-dashboard.delete_repo_archives_success=All repositories archives have been deleted successfully.
-dashboard.git_gc_repos=Do garbage collection on repositories
-dashboard.git_gc_repos_success=All repositories have done garbage collection successfully.
+dashboard.delete_repo_archives=Удаление всех архивов репозиториев
+dashboard.delete_repo_archives_success=Все архивы репозиториев были успешно удалены.
+dashboard.git_gc_repos=Выполнить сборку мусора на репозиториях
+dashboard.git_gc_repos_success=Сборка мусора на всех репозиториях успешно выполнена.
dashboard.server_uptime=Время непрерывной работы сервера
dashboard.current_goroutine=Current Goroutines
dashboard.current_memory_usage=Текущее использование памяти
-dashboard.total_memory_allocated=Total Memory Allocated
+dashboard.total_memory_allocated=Всего памяти выделено
dashboard.memory_obtained=Memory Obtained
dashboard.pointer_lookup_times=Pointer Lookup Times
dashboard.memory_allocate_times=Memory Allocate Times
@@ -543,7 +543,7 @@ dashboard.last_gc_pause=Last GC Pause dashboard.gc_times=GC Times
users.user_manage_panel=User Manage Panel
-users.new_account=Create New Account
+users.new_account=Создать новый аккаунт
users.name=Имя
users.activated=Активирован
users.admin=Администратор
@@ -560,7 +560,7 @@ users.is_admin=У этой учетной записи есть права ад users.allow_git_hook=Пользователь имеет право создать Git перехватчик
users.update_profile=Обновить профиль учетной записи
users.delete_account=Удалить эту учетную запись
-users.still_own_repo=This account still have ownership of repository, you have to delete or transfer them first.
+users.still_own_repo=На вашем аккаунте все еще остается как минимум один репозиторий, сначала вам нужно удалить или передать его.
users.still_has_org=This account still have membership of organization, you have to left or delete them first.
orgs.org_manage_panel=Управление группами
@@ -630,30 +630,30 @@ config.db_path=Path config.db_path_helper=(for "sqlite3" only)
config.service_config=Service Configuration
config.register_email_confirm=Require E-mail Confirmation
-config.disable_register=Disable Registration
-config.require_sign_in_view=Require Sign In View
-config.mail_notify=Mail Notification
-config.enable_cache_avatar=Enable Cache Avatar
+config.disable_register=Отключить регистрацию
+config.require_sign_in_view=Для просмотра необходима авторизация
+config.mail_notify=Почтовые уведомления
+config.enable_cache_avatar=Кешировать аватар
config.active_code_lives=Active Code Lives
config.reset_password_code_lives=Reset Password Code Lives
config.webhook_config=Настройка автоматического обновления репозиции
-config.task_interval=Task Interval
-config.deliver_timeout=Deliver Timeout
-config.mailer_config=Mailer Configuration
-config.mailer_enabled=Enabled
-config.mailer_name=Name
-config.mailer_host=Host
-config.mailer_user=User
-config.oauth_config=OAuth Configuration
-config.oauth_enabled=Enabled
-config.cache_config=Cache Configuration
+config.task_interval=Интервал задания
+config.deliver_timeout=Задержка доставки
+config.mailer_config=Настройки почты
+config.mailer_enabled=Включено
+config.mailer_name=Имя
+config.mailer_host=Сервер
+config.mailer_user=Пользователь
+config.oauth_config=Конфигурация OAuth
+config.oauth_enabled=Включено
+config.cache_config=Настройки кеша
config.cache_adapter=Cache Adapter
config.cache_interval=Cache Interval
config.cache_conn=Cache Connection
config.session_config=Session Configuration
config.session_provider=Session Provider
config.provider_config=Provider Config
-config.cookie_name=Cookie Name
+config.cookie_name=Имя файла cookie
config.enable_set_cookie=Enable Set Cookie
config.gc_interval_time=GC Interval Time
config.session_life_time=Время жизни сессии
@@ -674,7 +674,7 @@ monitor.execute_times=Execute Times monitor.process=Запущенные процессы
monitor.desc=Описание
monitor.start=Start Time
-monitor.execute_time=Execution Time
+monitor.execute_time=Время выполнения
notices.system_notice_list=Система уведомлений
notices.type=Тип
@@ -684,7 +684,7 @@ notices.op=Op. notices.delete_success=System notice has been deleted successfully.
[action]
-create_repo=created repository <a href="%s/%s">%s</a>
+create_repo=создан репозиторий <a href="%s/%s"> %s</a>
commit_repo=pushed to <a href="%s/%s/src/%s">%s</a> at <a href="%s/%s">%s</a>
create_issue=opened issue <a href="%s/%s/issues/%s">%s#%s</a>
comment_issue=commented on issue <a href="%s/%s/issues/%s">%s#%s</a>
@@ -703,9 +703,9 @@ now=сейчас 1w=1 week %s
1mon=1 month %s
1y=1 year %s
-seconds=%d seconds %s
-minutes=%d minutes %s
-hours=%d hours %s
+seconds=%d секунд %s
+minutes=%d минут %s
+hours=%d часов %s
days=%d days %s
weeks=%d weeks %s
months=%d months %s
@@ -17,7 +17,7 @@ import ( "github.com/gogits/gogs/modules/setting" ) -const APP_VER = "0.5.12.0120 Beta" +const APP_VER = "0.5.12.0204 Beta" func init() { runtime.GOMAXPROCS(runtime.NumCPU()) diff --git a/models/action.go b/models/action.go index de2cdd12cc..318a5f6ad4 100644 --- a/models/action.go +++ b/models/action.go @@ -41,12 +41,14 @@ var ( var ( // Same as Github. See https://help.github.com/articles/closing-issues-via-commit-messages - IssueKeywords = []string{"close", "closes", "closed", "fix", "fixes", "fixed", "resolve", "resolves", "resolved"} - IssueKeywordsPat *regexp.Regexp + IssueCloseKeywords = []string{"close", "closes", "closed", "fix", "fixes", "fixed", "resolve", "resolves", "resolved"} + IssueCloseKeywordsPat *regexp.Regexp + IssueReferenceKeywordsPat *regexp.Regexp ) func init() { - IssueKeywordsPat = regexp.MustCompile(fmt.Sprintf(`(?i)(?:%s) \S+`, strings.Join(IssueKeywords, "|"))) + IssueCloseKeywordsPat = regexp.MustCompile(fmt.Sprintf(`(?i)(?:%s) \S+`, strings.Join(IssueCloseKeywords, "|"))) + IssueReferenceKeywordsPat = regexp.MustCompile(fmt.Sprintf(`(?i)(?:) \S+`)) } // Action represents user operation type and other information to repository., @@ -110,13 +112,13 @@ func (a Action) GetIssueInfos() []string { func updateIssuesCommit(userId, repoId int64, repoUserName, repoName string, commits []*base.PushCommit) error { for _, c := range commits { - refs := IssueKeywordsPat.FindAllString(c.Message, -1) - - for _, ref := range refs { + references := IssueReferenceKeywordsPat.FindAllString(c.Message, -1) + + for _, ref := range references { ref := ref[strings.IndexByte(ref, byte(' '))+1:] ref = strings.TrimRightFunc(ref, func(c rune) bool { - return !unicode.IsDigit(c) - }) + return !unicode.IsDigit(c) + }) if len(ref) == 0 { continue @@ -144,6 +146,35 @@ func updateIssuesCommit(userId, repoId int64, repoUserName, repoName string, com if _, err = CreateComment(userId, issue.RepoId, issue.Id, 0, 0, COMMIT, message, nil); err != nil { return err } + } + + closes := IssueCloseKeywordsPat.FindAllString(c.Message, -1) + + for _, ref := range closes { + ref := ref[strings.IndexByte(ref, byte(' '))+1:] + ref = strings.TrimRightFunc(ref, func(c rune) bool { + return !unicode.IsDigit(c) + }) + + if len(ref) == 0 { + continue + } + + // Add repo name if missing + if ref[0] == '#' { + ref = fmt.Sprintf("%s/%s%s", repoUserName, repoName, ref) + } else if strings.Contains(ref, "/") == false { + // We don't support User#ID syntax yet + // return ErrNotImplemented + + continue + } + + issue, err := GetIssueByRef(ref) + + if err != nil { + return err + } if issue.RepoId == repoId { if issue.IsClosed { @@ -168,6 +199,7 @@ func updateIssuesCommit(userId, repoId int64, repoUserName, repoName string, com } } } + } return nil diff --git a/models/models.go b/models/models.go index cf4e291cff..1a67041b4a 100644 --- a/models/models.go +++ b/models/models.go @@ -33,7 +33,7 @@ var ( HasEngine bool DbCfg struct { - Type, Host, Name, User, Pwd, Path, SslMode string + Type, Host, Name, User, Passwd, Path, SSLMode string } EnableSQLite3 bool @@ -59,10 +59,10 @@ func LoadModelsConfig() { DbCfg.Host = sec.Key("HOST").String() DbCfg.Name = sec.Key("NAME").String() DbCfg.User = sec.Key("USER").String() - if len(DbCfg.Pwd) == 0 { - DbCfg.Pwd = sec.Key("PASSWD").String() + if len(DbCfg.Passwd) == 0 { + DbCfg.Passwd = sec.Key("PASSWD").String() } - DbCfg.SslMode = sec.Key("SSL_MODE").String() + DbCfg.SSLMode = sec.Key("SSL_MODE").String() DbCfg.Path = sec.Key("PATH").MustString("data/gogs.db") } @@ -71,7 +71,7 @@ func getEngine() (*xorm.Engine, error) { switch DbCfg.Type { case "mysql": cnnstr = fmt.Sprintf("%s:%s@tcp(%s)/%s?charset=utf8", - DbCfg.User, DbCfg.Pwd, DbCfg.Host, DbCfg.Name) + DbCfg.User, DbCfg.Passwd, DbCfg.Host, DbCfg.Name) case "postgres": var host, port = "127.0.0.1", "5432" fields := strings.Split(DbCfg.Host, ":") @@ -82,7 +82,7 @@ func getEngine() (*xorm.Engine, error) { port = fields[1] } cnnstr = fmt.Sprintf("user=%s password=%s host=%s port=%s dbname=%s sslmode=%s", - DbCfg.User, DbCfg.Pwd, host, port, DbCfg.Name, DbCfg.SslMode) + DbCfg.User, DbCfg.Passwd, host, port, DbCfg.Name, DbCfg.SSLMode) case "sqlite3": if !EnableSQLite3 { return nil, fmt.Errorf("Unknown database type: %s", DbCfg.Type) @@ -98,7 +98,7 @@ func getEngine() (*xorm.Engine, error) { func NewTestEngine(x *xorm.Engine) (err error) { x, err = getEngine() if err != nil { - return fmt.Errorf("models.init(fail to connect to database): %v", err) + return fmt.Errorf("connect to database: %v", err) } x.SetMapper(core.GonicMapper{}) @@ -108,7 +108,7 @@ func NewTestEngine(x *xorm.Engine) (err error) { func SetEngine() (err error) { x, err = getEngine() if err != nil { - return fmt.Errorf("models.init(fail to connect to database): %v", err) + return fmt.Errorf("connect to database: %v", err) } x.SetMapper(core.GonicMapper{}) diff --git a/models/publickey.go b/models/publickey.go index 566814e841..67ab4242f2 100644 --- a/models/publickey.go +++ b/models/publickey.go @@ -33,7 +33,7 @@ const ( ) var ( - ErrKeyAlreadyExist = errors.New("Public key already exist") + ErrKeyAlreadyExist = errors.New("Public key already exists") ErrKeyNotExist = errors.New("Public key does not exist") ErrKeyUnableVerify = errors.New("Unable to verify public key") ) @@ -41,7 +41,7 @@ var ( var sshOpLocker = sync.Mutex{} var ( - SshPath string // SSH directory. + SSHPath string // SSH directory. appPath string // Execution(binary) path. ) @@ -72,9 +72,9 @@ func init() { appPath = strings.Replace(appPath, "\\", "/", -1) // Determine and create .ssh path. - SshPath = filepath.Join(homeDir(), ".ssh") - if err = os.MkdirAll(SshPath, 0700); err != nil { - log.Fatal(4, "fail to create SshPath(%s): %v\n", SshPath, err) + SSHPath = filepath.Join(homeDir(), ".ssh") + if err = os.MkdirAll(SSHPath, 0700); err != nil { + log.Fatal(4, "fail to create '%s': %v", SSHPath, err) } } @@ -244,16 +244,17 @@ func CheckPublicKeyString(content string) (bool, error) { } // saveAuthorizedKeyFile writes SSH key content to authorized_keys file. -func saveAuthorizedKeyFile(key *PublicKey) error { +func saveAuthorizedKeyFile(keys ...*PublicKey) error { sshOpLocker.Lock() defer sshOpLocker.Unlock() - fpath := filepath.Join(SshPath, "authorized_keys") + fpath := filepath.Join(SSHPath, "authorized_keys") f, err := os.OpenFile(fpath, os.O_CREATE|os.O_WRONLY|os.O_APPEND, 0600) if err != nil { return err } defer f.Close() + finfo, err := f.Stat() if err != nil { return err @@ -269,8 +270,12 @@ func saveAuthorizedKeyFile(key *PublicKey) error { } } - _, err = f.WriteString(key.GetAuthorizedString()) - return err + for _, key := range keys { + if _, err = f.WriteString(key.GetAuthorizedString()); err != nil { + return err + } + } + return nil } // AddPublicKey adds new public key to database and authorized_keys file. @@ -413,8 +418,8 @@ func DeletePublicKey(key *PublicKey) error { return err } - fpath := filepath.Join(SshPath, "authorized_keys") - tmpPath := filepath.Join(SshPath, "authorized_keys.tmp") + fpath := filepath.Join(SSHPath, "authorized_keys") + tmpPath := filepath.Join(SSHPath, "authorized_keys.tmp") if err = rewriteAuthorizedKeys(key, fpath, tmpPath); err != nil { return err } else if err = os.Remove(fpath); err != nil { @@ -422,3 +427,37 @@ func DeletePublicKey(key *PublicKey) error { } return os.Rename(tmpPath, fpath) } + +// RewriteAllPublicKeys removes any authorized key and rewrite all keys from database again. +func RewriteAllPublicKeys() error { + sshOpLocker.Lock() + defer sshOpLocker.Unlock() + + tmpPath := filepath.Join(SSHPath, "authorized_keys.tmp") + f, err := os.Create(tmpPath) + if err != nil { + return err + } + defer os.Remove(tmpPath) + + err = x.Iterate(new(PublicKey), func(idx int, bean interface{}) (err error) { + _, err = f.WriteString((bean.(*PublicKey)).GetAuthorizedString()) + return err + }) + f.Close() + if err != nil { + return err + } + + fpath := filepath.Join(SSHPath, "authorized_keys") + if com.IsExist(fpath) { + if err = os.Remove(fpath); err != nil { + return err + } + } + if err = os.Rename(tmpPath, fpath); err != nil { + return err + } + + return nil +} diff --git a/models/repo.go b/models/repo.go index 663e227ae4..a06f1d3e4e 100644 --- a/models/repo.go +++ b/models/repo.go @@ -7,7 +7,6 @@ package models import ( "errors" "fmt" - "html" "html/template" "io/ioutil" "os" @@ -218,11 +217,9 @@ func (repo *Repository) HasAccess(uname string) bool { // DescriptionHtml does special handles to description and return HTML string. func (repo *Repository) DescriptionHtml() template.HTML { sanitize := func(s string) string { - // TODO(nuss-justin): Improve sanitization. Strip all tags? - ss := html.EscapeString(s) - return fmt.Sprintf(`<a href="%s" target="_blank">%s</a>`, ss, ss) + return fmt.Sprintf(`<a href="%[1]s" target="_blank">%[1]s</a>`, s) } - return template.HTML(DescPattern.ReplaceAllStringFunc(base.XSSString(repo.Description), sanitize)) + return template.HTML(DescPattern.ReplaceAllStringFunc(base.Sanitizer.Sanitize(repo.Description), sanitize)) } // IsRepositoryExist returns true if the repository with given name under user has already existed. @@ -507,6 +504,11 @@ func initRepository(f string, u *User, repo *Repository, initReadme bool, repoLa } if len(fileName) == 0 { + // Re-fetch the repository from database before updating it (else it would + // override changes that were done earlier with sql) + if repo, err = GetRepositoryById(repo.Id); err != nil { + return err + } repo.IsBare = true repo.DefaultBranch = "master" return UpdateRepository(repo) diff --git a/models/user.go b/models/user.go index f16fbca344..2da0881c81 100644 --- a/models/user.go +++ b/models/user.go @@ -477,6 +477,7 @@ func UpdateUser(u *User) error { } u.Avatar = avatar.HashEmail(u.AvatarEmail) + u.FullName = base.Sanitizer.Sanitize(u.FullName) _, err = x.Id(u.Id).AllCols().Update(u) return err } diff --git a/modules/auth/auth.go b/modules/auth/auth.go index 1dd96d8d40..ad7ce5b9ad 100644 --- a/modules/auth/auth.go +++ b/modules/auth/auth.go @@ -9,6 +9,7 @@ import ( "reflect" "strings" + "github.com/Unknwon/com" "github.com/Unknwon/macaron" "github.com/macaron-contrib/binding" "github.com/macaron-contrib/session" @@ -135,6 +136,10 @@ type Form interface { binding.Validator } +func init() { + binding.SetNameMapper(com.ToSnakeCase) +} + // AssignForm assign form values back to the template data. func AssignForm(form interface{}, data map[string]interface{}) { typ := reflect.TypeOf(form) @@ -152,6 +157,8 @@ func AssignForm(form interface{}, data map[string]interface{}) { // Allow ignored fields in the struct if fieldName == "-" { continue + } else if len(fieldName) == 0 { + fieldName = com.ToSnakeCase(field.Name) } data[fieldName] = val.Field(i).Interface() diff --git a/modules/auth/user_form.go b/modules/auth/user_form.go index becd5cbca8..3c0ff65174 100644 --- a/modules/auth/user_form.go +++ b/modules/auth/user_form.go @@ -12,26 +12,27 @@ import ( ) type InstallForm struct { - Database string `form:"database" binding:"Required"` - DbHost string `form:"host"` - DbUser string `form:"user"` - DbPasswd string `form:"passwd"` - DatabaseName string `form:"database_name"` - SslMode string `form:"ssl_mode"` - DatabasePath string `form:"database_path"` - RepoRootPath string `form:"repo_path" binding:"Required"` - RunUser string `form:"run_user" binding:"Required"` - Domain string `form:"domain" binding:"Required"` - AppUrl string `form:"app_url" binding:"Required"` - SmtpHost string `form:"smtp_host"` - SmtpEmail string `form:"mailer_user"` - SmtpPasswd string `form:"mailer_pwd"` - RegisterConfirm string `form:"register_confirm"` - MailNotify string `form:"mail_notify"` - AdminName string `form:"admin_name" binding:"Required;AlphaDashDot;MaxSize(30)"` - AdminPasswd string `form:"admin_pwd" binding:"Required;MinSize(6);MaxSize(255)"` - ConfirmPasswd string `form:"confirm_passwd" binding:"Required;MinSize(6);MaxSize(255)"` - AdminEmail string `form:"admin_email" binding:"Required;Email;MaxSize(50)"` + DbType string `binding:"Required"` + DbHost string + DbUser string + DbPasswd string + DbName string + SSLMode string + DbPath string + RepoRootPath string `binding:"Required"` + RunUser string `binding:"Required"` + Domain string `binding:"Required"` + HTTPPort string `binding:"Required"` + AppUrl string `binding:"Required"` + SMTPHost string + SMTPEmail string + SMTPPasswd string + RegisterConfirm string + MailNotify string + AdminName string `binding:"Required;AlphaDashDot;MaxSize(30)"` + AdminPasswd string `binding:"Required;MinSize(6);MaxSize(255)"` + AdminConfirmPasswd string `binding:"Required;MinSize(6);MaxSize(255)"` + AdminEmail string `binding:"Required;Email;MaxSize(50)"` } func (f *InstallForm) Validate(ctx *macaron.Context, errs binding.Errors) binding.Errors { diff --git a/modules/base/markdown.go b/modules/base/markdown.go index b2f94c480b..d3f3e5feaf 100644 --- a/modules/base/markdown.go +++ b/modules/base/markdown.go @@ -63,12 +63,18 @@ func IsImageFile(data []byte) (string, bool) { return contentType, false } +// IsReadmeFile returns true if given file name suppose to be a README file. func IsReadmeFile(name string) bool { name = strings.ToLower(name) if len(name) < 6 { return false + } else if len(name) == 6 { + if name == "readme" { + return true + } + return false } - if name[:6] == "readme" { + if name[:7] == "readme." { return true } return false @@ -103,7 +109,7 @@ var ( MentionPattern = regexp.MustCompile(`@[0-9a-zA-Z_]{1,}`) commitPattern = regexp.MustCompile(`(\s|^)https?.*commit/[0-9a-zA-Z]+(#+[0-9a-zA-Z-]*)?`) issueFullPattern = regexp.MustCompile(`(\s|^)https?.*issues/[0-9]+(#+[0-9a-zA-Z-]*)?`) - issueIndexPattern = regexp.MustCompile(`#[0-9]+`) + issueIndexPattern = regexp.MustCompile(`( |^)#[0-9]+`) sha1CurrentPattern = regexp.MustCompile(`\b[0-9a-f]{40}\b`) ) @@ -212,7 +218,7 @@ func RenderRawMarkdown(body []byte, urlPrefix string) []byte { func RenderMarkdown(rawBytes []byte, urlPrefix string) []byte { body := RenderSpecialLink(rawBytes, urlPrefix) body = RenderRawMarkdown(body, urlPrefix) - body = XSS(body) + body = Sanitizer.SanitizeBytes(body) return body } diff --git a/modules/base/template.go b/modules/base/template.go index 829999d1c9..f3fa138578 100644 --- a/modules/base/template.go +++ b/modules/base/template.go @@ -13,7 +13,6 @@ import ( "strings" "time" - "github.com/microcosm-cc/bluemonday" "golang.org/x/net/html/charset" "golang.org/x/text/transform" @@ -21,11 +20,8 @@ import ( "github.com/gogits/gogs/modules/setting" ) -// FIXME: use me to Markdown API renders -var p = bluemonday.UGCPolicy() - func Str2html(raw string) template.HTML { - return template.HTML(p.Sanitize(raw)) + return template.HTML(Sanitizer.Sanitize(raw)) } func Range(l int) []int { @@ -90,6 +86,11 @@ func ToUtf8(content string) string { return res } +// RenderCommitMessage renders commit message with XSS-safe and special links. +func RenderCommitMessage(msg, urlPrefix string) template.HTML { + return template.HTML(string(RenderIssueIndexPattern([]byte(template.HTMLEscapeString(msg)), urlPrefix))) +} + var mailDomains = map[string]string{ "gmail.com": "gmail.com", } @@ -163,6 +164,7 @@ var TemplateFuncs template.FuncMap = map[string]interface{}{ "EscapePound": func(str string) string { return strings.Replace(str, "#", "%23", -1) }, + "RenderCommitMessage": RenderCommitMessage, } type Actioner interface { diff --git a/modules/base/tool.go b/modules/base/tool.go index ff5a4f4cd9..5043364cec 100644 --- a/modules/base/tool.go +++ b/modules/base/tool.go @@ -15,17 +15,19 @@ import ( "hash" "html/template" "math" - "regexp" "strings" "time" "github.com/Unknwon/com" "github.com/Unknwon/i18n" + "github.com/microcosm-cc/bluemonday" "github.com/gogits/gogs/modules/avatar" "github.com/gogits/gogs/modules/setting" ) +var Sanitizer = bluemonday.UGCPolicy() + // Encode string to md5 hex value. func EncodeMd5(str string) string { m := md5.New() @@ -473,29 +475,3 @@ func DateFormat(t time.Time, format string) string { format = replacer.Replace(format) return t.Format(format) } - -type xssFilter struct { - reg *regexp.Regexp - repl []byte -} - -var ( - whiteSpace = []byte(" ") - xssFilters = []xssFilter{ - {regexp.MustCompile(`\ [ONon]\w*=["]*`), whiteSpace}, - {regexp.MustCompile(`<[SCRIPTscript]{6}`), whiteSpace}, - {regexp.MustCompile(`=[` + "`" + `'"]*[JAVASCRIPTjavascript \t\0
]*:`), whiteSpace}, - } -) - -// XSS goes through all the XSS filters to make user input content as safe as possible. -func XSS(in []byte) []byte { - for _, filter := range xssFilters { - in = filter.reg.ReplaceAll(in, filter.repl) - } - return in -} - -func XSSString(in string) string { - return string(XSS([]byte(in))) -} diff --git a/modules/middleware/auth.go b/modules/middleware/auth.go index 94bb1c14a4..b0bcd87f54 100644 --- a/modules/middleware/auth.go +++ b/modules/middleware/auth.go @@ -54,7 +54,7 @@ func Toggle(options *ToggleOptions) macaron.Handler { if strings.HasSuffix(ctx.Req.RequestURI, "watch") { return } - ctx.SetCookie("redirect_to", "/"+url.QueryEscape(setting.AppSubUrl+ctx.Req.RequestURI), 0, setting.AppSubUrl) + ctx.SetCookie("redirect_to", url.QueryEscape(setting.AppSubUrl+ctx.Req.RequestURI), 0, setting.AppSubUrl) ctx.Redirect(setting.AppSubUrl + "/user/login") return } else if !ctx.User.IsActive && setting.Service.RegisterEmailConfirm { diff --git a/modules/setting/setting.go b/modules/setting/setting.go index bc9da3c63a..e7c44cdd4f 100644 --- a/modules/setting/setting.go +++ b/modules/setting/setting.go @@ -178,7 +178,7 @@ func NewConfigContext() { log.Fatal(4, "Fail to load custom 'conf/app.ini': %v", err) } } else { - log.Warn("No custom 'conf/app.ini' found, please go to '/install'") + log.Warn("No custom 'conf/app.ini' found, ignore this if you're running first time") } Cfg.NameMapper = ini.AllCapsUnderscore diff --git a/public/js/app.js b/public/js/app.js index 23b629e3e1..61539148e9 100644 --- a/public/js/app.js +++ b/public/js/app.js @@ -1052,22 +1052,6 @@ function initRepoSetting() { return; } Gogits.getUsers($this.val(), $this.next()); - /*$.ajax({ - url: '/api/v1/users/search?q=' + $this.val(), - dataType: "json", - success: function (json) { - if (json.ok && json.data.length) { - var html = ''; - $.each(json.data, function (i, item) { - html += '<li><img src="' + item.avatar + '">' + item.username + '</li>'; - }); - $this.next().toggleShow(); - $this.next().find('ul').html(html); - } else { - $this.next().toggleHide(); - } - } - });*/ }).on('focus', function () { if (!$(this).val()) { $(this).next().toggleHide(); diff --git a/public/ng/css/gogs.css b/public/ng/css/gogs.css index 12ae89ed4b..dc451a7051 100644 --- a/public/ng/css/gogs.css +++ b/public/ng/css/gogs.css @@ -1630,6 +1630,10 @@ The register and sign-in page style background-color: #d1ffd6 !important; border-color: #b4e2b4 !important; } +.diff-file-box .code-diff tbody tr.add-code td.selected-line, +.diff-file-box .code-diff tbody tr.add-code td.selected-line pre { + background-color: #ffffdd !important; +} .diff-file-box .code-diff tbody tr:hover td, .diff-file-box .code-diff tbody tr:hover pre { background-color: #FFF8D2 !important; @@ -1761,6 +1765,7 @@ The register and sign-in page style #org-setting-form, #repo-setting-form, #user-profile-form, +#add-email-form, .repo-setting-form { background-color: #FFF; padding: 30px 0; @@ -1769,6 +1774,7 @@ The register and sign-in page style #org-setting-form textarea, #repo-setting-form textarea, #user-profile-form textarea, +#add-email-form textarea, .repo-setting-form textarea { margin-left: 4px; height: 100px; @@ -1777,11 +1783,13 @@ The register and sign-in page style #org-setting-form label, #repo-setting-form label, #user-profile-form label, +#add-email-form label, .repo-setting-form label, #auth-setting-form .form-label, #org-setting-form .form-label, #repo-setting-form .form-label, #user-profile-form .form-label, +#add-email-form .form-label, .repo-setting-form .form-label { width: 240px; } @@ -1789,6 +1797,7 @@ The register and sign-in page style #org-setting-form .ipt, #repo-setting-form .ipt, #user-profile-form .ipt, +#add-email-form .ipt, .repo-setting-form .ipt { width: 360px; } @@ -1796,6 +1805,7 @@ The register and sign-in page style #org-setting-form .field, #repo-setting-form .field, #user-profile-form .field, +#add-email-form .field, .repo-setting-form .field { margin-bottom: 24px; } @@ -1813,6 +1823,7 @@ The register and sign-in page style #repo-hooks-history-panel, #user-social-panel, #user-applications-panel, +#user-email-panel, #user-ssh-panel { margin-bottom: 20px; } @@ -1820,6 +1831,7 @@ The register and sign-in page style #repo-hooks-history-panel .setting-list, #user-social-panel .setting-list, #user-applications-panel .setting-list, +#user-email-panel .setting-list, #user-ssh-panel .setting-list { background-color: #FFF; } @@ -1827,6 +1839,7 @@ The register and sign-in page style #repo-hooks-history-panel .setting-list li, #user-social-panel .setting-list li, #user-applications-panel .setting-list li, +#user-email-panel .setting-list li, #user-ssh-panel .setting-list li { padding: 8px 20px; border-bottom: 1px solid #eaeaea; @@ -1835,6 +1848,7 @@ The register and sign-in page style #repo-hooks-history-panel .setting-list li.ssh:hover, #user-social-panel .setting-list li.ssh:hover, #user-applications-panel .setting-list li.ssh:hover, +#user-email-panel .setting-list li.ssh:hover, #user-ssh-panel .setting-list li.ssh:hover { background-color: #ffffEE; } @@ -1842,6 +1856,7 @@ The register and sign-in page style #repo-hooks-history-panel .setting-list li i, #user-social-panel .setting-list li i, #user-applications-panel .setting-list li i, +#user-email-panel .setting-list li i, #user-ssh-panel .setting-list li i { padding-right: 5px; } @@ -1849,6 +1864,7 @@ The register and sign-in page style #repo-hooks-history-panel .active-icon, #user-social-panel .active-icon, #user-applications-panel .active-icon, +#user-email-panel .active-icon, #user-ssh-panel .active-icon { width: 10px; height: 10px; @@ -1861,6 +1877,7 @@ The register and sign-in page style #repo-hooks-history-panel .ssh-content, #user-social-panel .ssh-content, #user-applications-panel .ssh-content, +#user-email-panel .ssh-content, #user-ssh-panel .ssh-content { margin-left: 24px; } @@ -1868,6 +1885,7 @@ The register and sign-in page style #repo-hooks-history-panel .ssh-content .octicon, #user-social-panel .ssh-content .octicon, #user-applications-panel .ssh-content .octicon, +#user-email-panel .ssh-content .octicon, #user-ssh-panel .ssh-content .octicon { margin-right: 4px; } @@ -1875,16 +1893,19 @@ The register and sign-in page style #repo-hooks-history-panel .ssh-content .print, #user-social-panel .ssh-content .print, #user-applications-panel .ssh-content .print, +#user-email-panel .ssh-content .print, #user-ssh-panel .ssh-content .print, #repo-hooks-panel .ssh-content .access, #repo-hooks-history-panel .ssh-content .access, #user-social-panel .ssh-content .access, #user-applications-panel .ssh-content .access, +#user-email-panel .ssh-content .access, #user-ssh-panel .ssh-content .access, #repo-hooks-panel .ssh-content .activity, #repo-hooks-history-panel .ssh-content .activity, #user-social-panel .ssh-content .activity, #user-applications-panel .ssh-content .activity, +#user-email-panel .ssh-content .activity, #user-ssh-panel .ssh-content .activity { color: #888; } @@ -1892,6 +1913,7 @@ The register and sign-in page style #repo-hooks-history-panel .ssh-content .access, #user-social-panel .ssh-content .access, #user-applications-panel .ssh-content .access, +#user-email-panel .ssh-content .access, #user-ssh-panel .ssh-content .access { max-width: 500px; } @@ -1899,6 +1921,7 @@ The register and sign-in page style #repo-hooks-history-panel .ssh-btn, #user-social-panel .ssh-btn, #user-applications-panel .ssh-btn, +#user-email-panel .ssh-btn, #user-ssh-panel .ssh-btn { margin-top: 6px; } diff --git a/public/ng/js/gogs.js b/public/ng/js/gogs.js index ff38bda9d6..e9b44d6575 100644 --- a/public/ng/js/gogs.js +++ b/public/ng/js/gogs.js @@ -202,6 +202,78 @@ var Gogs = {}; }).trigger('hashchange'); }; + // Render diff view. + Gogs.renderDiffView = function () { + function selectRange($list, $select, $from) { + $list.removeClass('active'); + $list.parents('tr').find('td').removeClass('selected-line'); + if ($from) { + var a = parseInt($select.attr('rel').substr(1)); + var b = parseInt($from.attr('rel').substr(1)); + var c; + if (a != b) { + if (a > b) { + c = a; + a = b; + b = c; + } + var classes = []; + for (i = a; i <= b; i++) { + classes.push('[rel=L' + i + ']'); + } + $list.filter(classes.join(',')).addClass('active'); + $list.filter(classes.join(',')).parents('tr').find('td').addClass('selected-line'); + $.changeHash('#L' + a + '-' + 'L' + b); + return + } + } + $select.addClass('active'); + $select.parents('tr').find('td').addClass('selected-line'); + $.changeHash('#' + $select.attr('rel')); + } + + $(document).on('click', '.code-diff .lines-num span', function (e) { + var $select = $(this); + var $list = $select.parent().siblings('.lines-code').parents().find('td.lines-num > span'); + selectRange( + $list, + $list.filter('[rel=' + $select.attr('rel') + ']'), + (e.shiftKey && $list.filter('.active').length ? $list.filter('.active').eq(0) : null) + ); + $.deSelect(); + }); + + $('.code-diff .lines-code > pre').each(function () { + var $pre = $(this); + var $lineCode = $pre.parent(); + var $lineNums = $lineCode.siblings('.lines-num'); + if ($lineNums.length > 0) { + var nums = $pre.find('ol.linenums > li').length; + for (var i = 1; i <= nums; i++) { + $lineNums.append('<span id="L' + i + '" rel="L' + i + '">' + i + '</span>'); + } + } + }); + + $(window).on('hashchange', function (e) { + var m = window.location.hash.match(/^#(L\d+)\-(L\d+)$/); + var $list = $('.code-diff td.lines-num > span'); + var $first; + if (m) { + $first = $list.filter('[rel=' + m[1] + ']'); + selectRange($list, $first, $list.filter('[rel=' + m[2] + ']')); + $("html, body").scrollTop($first.offset().top - 200); + return; + } + m = window.location.hash.match(/^#(L\d+)$/); + if (m) { + $first = $list.filter('[rel=' + m[1] + ']'); + selectRange($list, $first); + $("html, body").scrollTop($first.offset().top - 200); + } + }).trigger('hashchange'); + }; + // Search users by keyword. Gogs.searchUsers = function (val, $target) { var notEmpty = function (str) { @@ -287,7 +359,12 @@ var Gogs = {}; function initCore() { Gogs.renderMarkdown(); - Gogs.renderCodeView(); + + if ($('.code-diff').length == 0) { + Gogs.renderCodeView(); + } else { + Gogs.renderDiffView(); + } // Switch list. $('.js-tab-nav').click(function (e) { @@ -508,7 +585,7 @@ function initRepoSetting() { $ul.toggleShow(); } }).next().next().find('ul').on("click", 'li', function () { - $('#repo-collaborator').val($(this).text()); + $('#repo-collaborator').val($(this).find('.username').text()); $ul.toggleHide(); }); } @@ -608,7 +685,7 @@ function initTeamMembersList() { $ul.toggleShow(); } }).next().next().find('ul').on("click", 'li', function () { - $('#org-team-members-add').val($(this).text()); + $('#org-team-members-add').val($(this).find('.username').text()); $ul.toggleHide(); }); } diff --git a/public/ng/js/min/gogs-min.js b/public/ng/js/min/gogs-min.js index a132e4a9a8..77304d7880 100644 --- a/public/ng/js/min/gogs-min.js +++ b/public/ng/js/min/gogs-min.js @@ -1,5 +1,5 @@ -function Tabs(e){function t(e){console.log("hide",e),e.removeClass("js-tab-nav-show"),$(e.data("tab-target")).removeClass("js-tab-show").hide()}function n(e){console.log("show",e),e.addClass("js-tab-nav-show"),$(e.data("tab-target")).addClass("js-tab-show").show()}var r=$(e);if(r.length){var i=r.find(".js-tab-nav-show");i.length&&$(i.data("tab-target")).addClass("js-tab-show"),r.on("click",".js-tab-nav",function(e){e.preventDefault();var o=$(this);o.hasClass("js-tab-nav-show")||(i=r.find(".js-tab-nav-show").eq(0),t(i),n(o))}),console.log("init tabs @",e)}}function Preview(e,t){function n(e){return e.find(".js-preview-input").eq(0)}function r(e){return e.hasClass("js-preview-container")?e:e.find(".js-preview-container").eq(0)}var i=$(e),o=$(t),a=n(o);if(!a.length)return void console.log("[preview]: no preview input");var s=r(o);return s.length?(i.on("click",function(){$.post("/api/v1/markdown",{text:a.val()},function(e){s.html(e)})}),void console.log("[preview]: init preview @",e,"&",t)):void console.log("[preview]: no preview container")}function initCore(){Gogs.renderMarkdown(),Gogs.renderCodeView(),$(".js-tab-nav").click(function(e){$(this).hasClass("js-tab-nav-show")||($(this).parent().find(".js-tab-nav-show").each(function(){$(this).removeClass("js-tab-nav-show"),$($(this).data("tab-target")).hide()}),$(this).addClass("js-tab-nav-show"),$($(this).data("tab-target")).show()),e.preventDefault()}),$(document).on("click",".popup-modal-dismiss",function(e){e.preventDefault(),$.magnificPopup.close()}),$(".collapse").hide(),$(".tipsy-tooltip").tipsy({fade:!0})}function initUserSetting(){var t=$("#username"),n=$("#user-profile-form");$("#change-username-btn").magnificPopup({modal:!0,callbacks:{open:function(){t.data("uname")==t.val()&&($.magnificPopup.close(),n.submit())}}}).click(function(){return t.data("uname")!=t.val()?(e.preventDefault(),!0):void 0}),$("#change-username-submit").click(function(){$.magnificPopup.close(),n.submit()}),$(".show-form-btn").click(function(){$($(this).data("target-form")).removeClass("hide")}),$("#delete-account-btn").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-account-submit").click(function(){$.magnificPopup.close(),$("#delete-account-form").submit()})}function initRepoCreate(){$("#repo-create-owner-list").on("click","li",function(){if(!$(this).hasClass("checked")){var e=$(this).data("uid");$("#repo-owner-id").val(e),$("#repo-owner-avatar").attr("src",$(this).find("img").attr("src")),$("#repo-owner-name").text($(this).text().trim()),$(this).parent().find(".checked").removeClass("checked"),$(this).addClass("checked"),console.log("set repo owner to uid :",e,$(this).text().trim())}}),$("#auth-button").click(function(e){$("#repo-migrate-auth").slideToggle("fast"),e.preventDefault()}),console.log("initRepoCreate")}function initRepo(){$("#repo-clone-ssh").click(function(){$(this).removeClass("btn-gray").addClass("btn-blue"),$("#repo-clone-https").removeClass("btn-blue").addClass("btn-gray"),$("#repo-clone-url").val($(this).data("link")),$(".clone-url").text($(this).data("link"))}),$("#repo-clone-https").click(function(){$(this).removeClass("btn-gray").addClass("btn-blue"),$("#repo-clone-ssh").removeClass("btn-blue").addClass("btn-gray"),$("#repo-clone-url").val($(this).data("link")),$(".clone-url").text($(this).data("link"))});var e=$("#repo-clone-copy");e.hover(function(){Gogs.bindCopy($(this))}),e.tipsy({fade:!0}),$(".markdown-preview").click(function(){var e=$(this);e.toggleAjax(function(t){$(e.data("preview")).html(t)},function(){$(e.data("preview")).html("no content")})})}function initHookTypeChange(){$("select#hook-type").on("change",function(){hookTypes=["Gogs","Slack"];var e=$(this).val();hookTypes.forEach(function(t){e===t?$("div#"+t.toLowerCase()).toggleShow():$("div#"+t.toLowerCase()).toggleHide()})})}function initRepoRelease(){$("#release-new-target-branch-list li").click(function(){$(this).hasClass("checked")||($("#repo-branch-current").text($(this).text()),$("#tag-target").val($(this).text()),$(this).parent().find(".checked").removeClass("checked"),$(this).addClass("checked"))})}function initRepoSetting(){var t=$("#repo_name"),n=$("#repo-setting-form");$("#change-reponame-btn").magnificPopup({modal:!0,callbacks:{open:function(){t.data("repo-name")==t.val()&&($.magnificPopup.close(),n.submit())}}}).click(function(){return t.data("repo-name")!=t.val()?(e.preventDefault(),!0):void 0}),$("#change-reponame-submit").click(function(){$.magnificPopup.close(),n.submit()}),initHookTypeChange(),$("#transfer-repo-btn").magnificPopup({modal:!0}),$("#transfer-repo-submit").click(function(){$.magnificPopup.close(),$("#transfer-repo-form").submit()}),$("#delete-repo-btn").magnificPopup({modal:!0}),$("#delete-repo-submit").click(function(){$.magnificPopup.close(),$("#delete-repo-form").submit()}),$("#repo-collab-list hr:last-child").remove();var r=$("#repo-collaborator").next().next().find("ul");$("#repo-collaborator").on("keyup",function(){var e=$(this);return e.val()?void Gogs.searchUsers(e.val(),r):void r.toggleHide()}).on("focus",function(){$(this).val()?r.toggleShow():r.toggleHide()}).next().next().find("ul").on("click","li",function(){$("#repo-collaborator").val($(this).text()),r.toggleHide()})}function initOrgSetting(){var t=$("#orgname"),n=$("#org-setting-form");$("#change-orgname-btn").magnificPopup({modal:!0,callbacks:{open:function(){t.data("orgname")==t.val()&&($.magnificPopup.close(),n.submit())}}}).click(function(){return t.data("orgname")!=t.val()?(e.preventDefault(),!0):void 0}),$("#change-orgname-submit").click(function(){$.magnificPopup.close(),n.submit()}),$("#delete-org-btn").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-org-submit").click(function(){$.magnificPopup.close(),$("#delete-org-form").submit()}),initHookTypeChange()}function initInvite(){var e=$("#org-member-invite-list");$("#org-member-invite").on("keyup",function(){var t=$(this);return t.val()?void Gogs.searchUsers(t.val(),e):void e.toggleHide()}).on("focus",function(){$(this).val()?e.toggleShow():e.toggleHide()}).next().next().find("ul").on("click","li",function(){$("#org-member-invite").val($(this).find(".username").text()),e.toggleHide()})}function initOrgTeamCreate(){$("#org-team-delete").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-team-submit").click(function(){$.magnificPopup.close();var e=$("#team-create-form");e.attr("action",e.data("delete-url"))})}function initTeamMembersList(){var e=$("#org-team-members-list");$("#org-team-members-add").on("keyup",function(){var t=$(this);return t.val()?void Gogs.searchUsers(t.val(),e):void e.toggleHide()}).on("focus",function(){$(this).val()?e.toggleShow():e.toggleHide()}).next().next().find("ul").on("click","li",function(){$("#org-team-members-add").val($(this).text()),e.toggleHide()})}function initTeamRepositoriesList(){var e=$("#org-team-repositories-list");$("#org-team-repositories-add").on("keyup",function(){var t=$(this);return t.val()?void Gogs.searchRepos(t.val(),e,"uid="+t.data("uid")):void e.toggleHide()}).on("focus",function(){$(this).val()?e.toggleShow():e.toggleHide()}).next().next().find("ul").on("click","li",function(){$("#org-team-repositories-add").val($(this).text()),e.toggleHide()})}function initAdmin(){$("#login-type").on("change",function(){var e=$(this).val();e.indexOf("0-")+1?($(".auth-name").toggleHide(),$(".pwd").find("input").attr("required","required").end().toggleShow()):($(".pwd").find("input").removeAttr("required").end().toggleHide(),$(".auth-name").toggleShow())}),$("#delete-account-btn").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-account-submit").click(function(){$.magnificPopup.close();var e=$("#user-profile-form");e.attr("action",e.data("delete-url"))}),$("#auth-type").on("change",function(){var e=$(this).val();2==e&&($(".ldap").toggleShow(),$(".smtp").toggleHide()),3==e&&($(".smtp").toggleShow(),$(".ldap").toggleHide())}),$("#delete-auth-btn").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-auth-submit").click(function(){$.magnificPopup.close();var e=$("#auth-setting-form");e.attr("action",e.data("delete-url"))})}function initInstall(){!function(){var e="127.0.0.1:3306",t="127.0.0.1:5432";$("#install-database").on("change",function(){var n=$(this).val();"SQLite3"!=n?($(".server-sql").show(),$(".sqlite-setting").addClass("hide"),"PostgreSQL"==n?($(".pgsql-setting").removeClass("hide"),$("#database-host").val()==e&&$("#database-host").val(t)):"MySQL"==n?($(".pgsql-setting").addClass("hide"),$("#database-host").val()==t&&$("#database-host").val(e)):$(".pgsql-setting").addClass("hide")):($(".server-sql").hide(),$(".pgsql-setting").hide(),$(".sqlite-setting").removeClass("hide"))})}()}function initProfile(){$("#profile-avatar").tipsy({fade:!0})}function initTimeSwitch(){$(".time-since[title]").on("click",function(){var e=$(this),t=e.attr("title"),n=e.text();e.text(t),e.attr("title",n)})}function initDiff(){$(".diff-detail-box>a").click(function(){$($(this).data("target")).slideToggle(100)});var e=$(".diff-counter");e.length<1||e.each(function(e,t){var n=$(t),r=n.find("span[data-line].add").data("line"),i=n.find("span[data-line].del").data("line"),o=parseFloat(r)/(parseFloat(r)+parseFloat(i))*100;n.find(".bar .add").css("width",o+"%")})}function homepage(){$("#promo-form").submit(function(e){return""===$("#username").val()?(e.preventDefault(),window.location.href=Gogs.AppSubUrl+"/user/login",!0):void 0}),$("#register-button").click(function(e){return""===$("#username").val()?(e.preventDefault(),window.location.href=Gogs.AppSubUrl+"/user/sign_up",!0):void $("#promo-form").attr("action",Gogs.AppSubUrl+"/user/sign_up")})}!function(e,t){"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(e,t){function n(e){var t=e.length,n=ot.type(e);return"function"===n||ot.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e}function r(e,t,n){if(ot.isFunction(t))return ot.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return ot.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(pt.test(t))return ot.filter(t,e,n);t=ot.filter(t,e)}return ot.grep(e,function(e){return ot.inArray(e,t)>=0!==n})}function i(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}function o(e){var t=wt[e]={};return ot.each(e.match(xt)||[],function(e,n){t[n]=!0}),t}function a(){mt.addEventListener?(mt.removeEventListener("DOMContentLoaded",s,!1),e.removeEventListener("load",s,!1)):(mt.detachEvent("onreadystatechange",s),e.detachEvent("onload",s))}function s(){(mt.addEventListener||"load"===event.type||"complete"===mt.readyState)&&(a(),ot.ready())}function l(e,t,n){if(void 0===n&&1===e.nodeType){var r="data-"+t.replace(Tt,"-$1").toLowerCase();if(n=e.getAttribute(r),"string"==typeof n){try{n="true"===n?!0:"false"===n?!1:"null"===n?null:+n+""===n?+n:St.test(n)?ot.parseJSON(n):n}catch(i){}ot.data(e,t,n)}else n=void 0}return n}function c(e){var t;for(t in e)if(("data"!==t||!ot.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}function u(e,t,n,r){if(ot.acceptData(e)){var i,o,a=ot.expando,s=e.nodeType,l=s?ot.cache:e,c=s?e[a]:e[a]&&a;if(c&&l[c]&&(r||l[c].data)||void 0!==n||"string"!=typeof t)return c||(c=s?e[a]=V.pop()||ot.guid++:a),l[c]||(l[c]=s?{}:{toJSON:ot.noop}),("object"==typeof t||"function"==typeof t)&&(r?l[c]=ot.extend(l[c],t):l[c].data=ot.extend(l[c].data,t)),o=l[c],r||(o.data||(o.data={}),o=o.data),void 0!==n&&(o[ot.camelCase(t)]=n),"string"==typeof t?(i=o[t],null==i&&(i=o[ot.camelCase(t)])):i=o,i}}function d(e,t,n){if(ot.acceptData(e)){var r,i,o=e.nodeType,a=o?ot.cache:e,s=o?e[ot.expando]:ot.expando;if(a[s]){if(t&&(r=n?a[s]:a[s].data)){ot.isArray(t)?t=t.concat(ot.map(t,ot.camelCase)):t in r?t=[t]:(t=ot.camelCase(t),t=t in r?[t]:t.split(" ")),i=t.length;for(;i--;)delete r[t[i]];if(n?!c(r):!ot.isEmptyObject(r))return}(n||(delete a[s].data,c(a[s])))&&(o?ot.cleanData([e],!0):rt.deleteExpando||a!=a.window?delete a[s]:a[s]=null)}}}function f(){return!0}function p(){return!1}function h(){try{return mt.activeElement}catch(e){}}function m(e){var t=Ht.split("|"),n=e.createDocumentFragment();if(n.createElement)for(;t.length;)n.createElement(t.pop());return n}function g(e,t){var n,r,i=0,o=typeof e.getElementsByTagName!==kt?e.getElementsByTagName(t||"*"):typeof e.querySelectorAll!==kt?e.querySelectorAll(t||"*"):void 0;if(!o)for(o=[],n=e.childNodes||e;null!=(r=n[i]);i++)!t||ot.nodeName(r,t)?o.push(r):ot.merge(o,g(r,t));return void 0===t||t&&ot.nodeName(e,t)?ot.merge([e],o):o}function v(e){Dt.test(e.type)&&(e.defaultChecked=e.checked)}function y(e,t){return ot.nodeName(e,"table")&&ot.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function b(e){return e.type=(null!==ot.find.attr(e,"type"))+"/"+e.type,e}function x(e){var t=Zt.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function w(e,t){for(var n,r=0;null!=(n=e[r]);r++)ot._data(n,"globalEval",!t||ot._data(t[r],"globalEval"))}function C(e,t){if(1===t.nodeType&&ot.hasData(e)){var n,r,i,o=ot._data(e),a=ot._data(t,o),s=o.events;if(s){delete a.handle,a.events={};for(n in s)for(r=0,i=s[n].length;i>r;r++)ot.event.add(t,n,s[n][r])}a.data&&(a.data=ot.extend({},a.data))}}function k(e,t){var n,r,i;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!rt.noCloneEvent&&t[ot.expando]){i=ot._data(t);for(r in i.events)ot.removeEvent(t,r,i.handle);t.removeAttribute(ot.expando)}"script"===n&&t.text!==e.text?(b(t).text=e.text,x(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),rt.html5Clone&&e.innerHTML&&!ot.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&Dt.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}}function S(t,n){var r,i=ot(n.createElement(t)).appendTo(n.body),o=e.getDefaultComputedStyle&&(r=e.getDefaultComputedStyle(i[0]))?r.display:ot.css(i[0],"display");return i.detach(),o}function T(e){var t=mt,n=Jt[e];return n||(n=S(e,t),"none"!==n&&n||(Kt=(Kt||ot("<iframe frameborder='0' width='0' height='0'/>")).appendTo(t.documentElement),t=(Kt[0].contentWindow||Kt[0].contentDocument).document,t.write(),t.close(),n=S(e,t),Kt.detach()),Jt[e]=n),n}function E(e,t){return{get:function(){var n=e();return null!=n?n?void delete this.get:(this.get=t).apply(this,arguments):void 0}}}function N(e,t){if(t in e)return t;for(var n=t.charAt(0).toUpperCase()+t.slice(1),r=t,i=pn.length;i--;)if(t=pn[i]+n,t in e)return t;return r}function L(e,t){for(var n,r,i,o=[],a=0,s=e.length;s>a;a++)r=e[a],r.style&&(o[a]=ot._data(r,"olddisplay"),n=r.style.display,t?(o[a]||"none"!==n||(r.style.display=""),""===r.style.display&&Lt(r)&&(o[a]=ot._data(r,"olddisplay",T(r.nodeName)))):(i=Lt(r),(n&&"none"!==n||!i)&&ot._data(r,"olddisplay",i?n:ot.css(r,"display"))));for(a=0;s>a;a++)r=e[a],r.style&&(t&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=t?o[a]||"":"none"));return e}function A(e,t,n){var r=cn.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function D(e,t,n,r,i){for(var o=n===(r?"border":"content")?4:"width"===t?1:0,a=0;4>o;o+=2)"margin"===n&&(a+=ot.css(e,n+Nt[o],!0,i)),r?("content"===n&&(a-=ot.css(e,"padding"+Nt[o],!0,i)),"margin"!==n&&(a-=ot.css(e,"border"+Nt[o]+"Width",!0,i))):(a+=ot.css(e,"padding"+Nt[o],!0,i),"padding"!==n&&(a+=ot.css(e,"border"+Nt[o]+"Width",!0,i)));return a}function j(e,t,n){var r=!0,i="width"===t?e.offsetWidth:e.offsetHeight,o=nn(e),a=rt.boxSizing&&"border-box"===ot.css(e,"boxSizing",!1,o);if(0>=i||null==i){if(i=rn(e,t,o),(0>i||null==i)&&(i=e.style[t]),tn.test(i))return i;r=a&&(rt.boxSizingReliable()||i===e.style[t]),i=parseFloat(i)||0}return i+D(e,t,n||(a?"border":"content"),r,o)+"px"}function R(e,t,n,r,i){return new R.prototype.init(e,t,n,r,i)}function P(){return setTimeout(function(){hn=void 0}),hn=ot.now()}function _(e,t){var n,r={height:e},i=0;for(t=t?1:0;4>i;i+=2-t)n=Nt[i],r["margin"+n]=r["padding"+n]=e;return t&&(r.opacity=r.width=e),r}function H(e,t,n){for(var r,i=(xn[t]||[]).concat(xn["*"]),o=0,a=i.length;a>o;o++)if(r=i[o].call(n,t,e))return r}function O(e,t,n){var r,i,o,a,s,l,c,u,d=this,f={},p=e.style,h=e.nodeType&&Lt(e),m=ot._data(e,"fxshow");n.queue||(s=ot._queueHooks(e,"fx"),null==s.unqueued&&(s.unqueued=0,l=s.empty.fire,s.empty.fire=function(){s.unqueued||l()}),s.unqueued++,d.always(function(){d.always(function(){s.unqueued--,ot.queue(e,"fx").length||s.empty.fire()})})),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],c=ot.css(e,"display"),u="none"===c?ot._data(e,"olddisplay")||T(e.nodeName):c,"inline"===u&&"none"===ot.css(e,"float")&&(rt.inlineBlockNeedsLayout&&"inline"!==T(e.nodeName)?p.zoom=1:p.display="inline-block")),n.overflow&&(p.overflow="hidden",rt.shrinkWrapBlocks()||d.always(function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]}));for(r in t)if(i=t[r],gn.exec(i)){if(delete t[r],o=o||"toggle"===i,i===(h?"hide":"show")){if("show"!==i||!m||void 0===m[r])continue;h=!0}f[r]=m&&m[r]||ot.style(e,r)}else c=void 0;if(ot.isEmptyObject(f))"inline"===("none"===c?T(e.nodeName):c)&&(p.display=c);else{m?"hidden"in m&&(h=m.hidden):m=ot._data(e,"fxshow",{}),o&&(m.hidden=!h),h?ot(e).show():d.done(function(){ot(e).hide()}),d.done(function(){var t;ot._removeData(e,"fxshow");for(t in f)ot.style(e,t,f[t])});for(r in f)a=H(h?m[r]:0,r,d),r in m||(m[r]=a.start,h&&(a.end=a.start,a.start="width"===r||"height"===r?1:0))}}function q(e,t){var n,r,i,o,a;for(n in e)if(r=ot.camelCase(n),i=t[r],o=e[n],ot.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),a=ot.cssHooks[r],a&&"expand"in a){o=a.expand(o),delete e[r];for(n in o)n in e||(e[n]=o[n],t[n]=i)}else t[r]=i}function M(e,t,n){var r,i,o=0,a=bn.length,s=ot.Deferred().always(function(){delete l.elem}),l=function(){if(i)return!1;for(var t=hn||P(),n=Math.max(0,c.startTime+c.duration-t),r=n/c.duration||0,o=1-r,a=0,l=c.tweens.length;l>a;a++)c.tweens[a].run(o);return s.notifyWith(e,[c,o,n]),1>o&&l?n:(s.resolveWith(e,[c]),!1)},c=s.promise({elem:e,props:ot.extend({},t),opts:ot.extend(!0,{specialEasing:{}},n),originalProperties:t,originalOptions:n,startTime:hn||P(),duration:n.duration,tweens:[],createTween:function(t,n){var r=ot.Tween(e,c.opts,t,n,c.opts.specialEasing[t]||c.opts.easing);return c.tweens.push(r),r},stop:function(t){var n=0,r=t?c.tweens.length:0;if(i)return this;for(i=!0;r>n;n++)c.tweens[n].run(1);return t?s.resolveWith(e,[c,t]):s.rejectWith(e,[c,t]),this}}),u=c.props;for(q(u,c.opts.specialEasing);a>o;o++)if(r=bn[o].call(c,e,u,c.opts))return r;return ot.map(u,H,c),ot.isFunction(c.opts.start)&&c.opts.start.call(e,c),ot.fx.timer(ot.extend(l,{elem:e,anim:c,queue:c.opts.queue})),c.progress(c.opts.progress).done(c.opts.done,c.opts.complete).fail(c.opts.fail).always(c.opts.always)}function z(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(xt)||[];if(ot.isFunction(n))for(;r=o[i++];)"+"===r.charAt(0)?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function F(e,t,n,r){function i(s){var l;return o[s]=!0,ot.each(e[s]||[],function(e,s){var c=s(t,n,r);return"string"!=typeof c||a||o[c]?a?!(l=c):void 0:(t.dataTypes.unshift(c),i(c),!1)}),l}var o={},a=e===Wn;return i(t.dataTypes[0])||!o["*"]&&i("*")}function B(e,t){var n,r,i=ot.ajaxSettings.flatOptions||{};for(r in t)void 0!==t[r]&&((i[r]?e:n||(n={}))[r]=t[r]);return n&&ot.extend(!0,e,n),e}function I(e,t,n){for(var r,i,o,a,s=e.contents,l=e.dataTypes;"*"===l[0];)l.shift(),void 0===i&&(i=e.mimeType||t.getResponseHeader("Content-Type"));if(i)for(a in s)if(s[a]&&s[a].test(i)){l.unshift(a);break}if(l[0]in n)o=l[0];else{for(a in n){if(!l[0]||e.converters[a+" "+l[0]]){o=a;break}r||(r=a)}o=o||r}return o?(o!==l[0]&&l.unshift(o),n[o]):void 0}function W(e,t,n,r){var i,o,a,s,l,c={},u=e.dataTypes.slice();if(u[1])for(a in e.converters)c[a.toLowerCase()]=e.converters[a];for(o=u.shift();o;)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!l&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),l=o,o=u.shift())if("*"===o)o=l;else if("*"!==l&&l!==o){if(a=c[l+" "+o]||c["* "+o],!a)for(i in c)if(s=i.split(" "),s[1]===o&&(a=c[l+" "+s[0]]||c["* "+s[0]])){a===!0?a=c[i]:c[i]!==!0&&(o=s[0],u.unshift(s[1]));break}if(a!==!0)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(d){return{state:"parsererror",error:a?d:"No conversion from "+l+" to "+o}}}return{state:"success",data:t}}function U(e,t,n,r){var i;if(ot.isArray(t))ot.each(t,function(t,i){n||Gn.test(e)?r(e,i):U(e+"["+("object"==typeof i?t:"")+"]",i,n,r)});else if(n||"object"!==ot.type(t))r(e,t);else for(i in t)U(e+"["+i+"]",t[i],n,r)}function X(){try{return new e.XMLHttpRequest}catch(t){}}function Z(){try{return new e.ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}function G(e){return ot.isWindow(e)?e:9===e.nodeType?e.defaultView||e.parentWindow:!1}var V=[],Q=V.slice,Y=V.concat,K=V.push,J=V.indexOf,et={},tt=et.toString,nt=et.hasOwnProperty,rt={},it="1.11.1",ot=function(e,t){return new ot.fn.init(e,t)},at=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,st=/^-ms-/,lt=/-([\da-z])/gi,ct=function(e,t){return t.toUpperCase()};ot.fn=ot.prototype={jquery:it,constructor:ot,selector:"",length:0,toArray:function(){return Q.call(this)},get:function(e){return null!=e?0>e?this[e+this.length]:this[e]:Q.call(this)},pushStack:function(e){var t=ot.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e,t){return ot.each(this,e,t)},map:function(e){return this.pushStack(ot.map(this,function(t,n){return e.call(t,n,t)}))},slice:function(){return this.pushStack(Q.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(0>e?t:0);return this.pushStack(n>=0&&t>n?[this[n]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:K,sort:V.sort,splice:V.splice},ot.extend=ot.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,l=arguments.length,c=!1;for("boolean"==typeof a&&(c=a,a=arguments[s]||{},s++),"object"==typeof a||ot.isFunction(a)||(a={}),s===l&&(a=this,s--);l>s;s++)if(null!=(i=arguments[s]))for(r in i)e=a[r],n=i[r],a!==n&&(c&&n&&(ot.isPlainObject(n)||(t=ot.isArray(n)))?(t?(t=!1,o=e&&ot.isArray(e)?e:[]):o=e&&ot.isPlainObject(e)?e:{},a[r]=ot.extend(c,o,n)):void 0!==n&&(a[r]=n));return a},ot.extend({expando:"jQuery"+(it+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isFunction:function(e){return"function"===ot.type(e)},isArray:Array.isArray||function(e){return"array"===ot.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){return!ot.isArray(e)&&e-parseFloat(e)>=0},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},isPlainObject:function(e){var t;if(!e||"object"!==ot.type(e)||e.nodeType||ot.isWindow(e))return!1;try{if(e.constructor&&!nt.call(e,"constructor")&&!nt.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(n){return!1}if(rt.ownLast)for(t in e)return nt.call(e,t);for(t in e);return void 0===t||nt.call(e,t)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?et[tt.call(e)]||"object":typeof e},globalEval:function(t){t&&ot.trim(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(st,"ms-").replace(lt,ct)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t,r){var i,o=0,a=e.length,s=n(e);if(r){if(s)for(;a>o&&(i=t.apply(e[o],r),i!==!1);o++);else for(o in e)if(i=t.apply(e[o],r),i===!1)break}else if(s)for(;a>o&&(i=t.call(e[o],o,e[o]),i!==!1);o++);else for(o in e)if(i=t.call(e[o],o,e[o]),i===!1)break;return e},trim:function(e){return null==e?"":(e+"").replace(at,"")},makeArray:function(e,t){var r=t||[];return null!=e&&(n(Object(e))?ot.merge(r,"string"==typeof e?[e]:e):K.call(r,e)),r},inArray:function(e,t,n){var r;if(t){if(J)return J.call(t,e,n);for(r=t.length,n=n?0>n?Math.max(0,r+n):n:0;r>n;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;n>r;)e[i++]=t[r++];if(n!==n)for(;void 0!==t[r];)e[i++]=t[r++];return e.length=i,e},grep:function(e,t,n){for(var r,i=[],o=0,a=e.length,s=!n;a>o;o++)r=!t(e[o],o),r!==s&&i.push(e[o]);return i},map:function(e,t,r){var i,o=0,a=e.length,s=n(e),l=[];if(s)for(;a>o;o++)i=t(e[o],o,r),null!=i&&l.push(i);else for(o in e)i=t(e[o],o,r),null!=i&&l.push(i);return Y.apply([],l)},guid:1,proxy:function(e,t){var n,r,i;return"string"==typeof t&&(i=e[t],t=e,e=i),ot.isFunction(e)?(n=Q.call(arguments,2),r=function(){return e.apply(t||this,n.concat(Q.call(arguments)))},r.guid=e.guid=e.guid||ot.guid++,r):void 0},now:function(){return+new Date},support:rt}),ot.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(e,t){et["[object "+t+"]"]=t.toLowerCase()});var ut=function(e){function t(e,t,n,r){var i,o,a,s,l,c,d,p,h,m;if((t?t.ownerDocument||t:F)!==R&&j(t),t=t||R,n=n||[],!e||"string"!=typeof e)return n;if(1!==(s=t.nodeType)&&9!==s)return[];if(_&&!r){if(i=yt.exec(e))if(a=i[1]){if(9===s){if(o=t.getElementById(a),!o||!o.parentNode)return n;if(o.id===a)return n.push(o),n}else if(t.ownerDocument&&(o=t.ownerDocument.getElementById(a))&&M(t,o)&&o.id===a)return n.push(o),n}else{if(i[2])return et.apply(n,t.getElementsByTagName(e)),n;if((a=i[3])&&w.getElementsByClassName&&t.getElementsByClassName)return et.apply(n,t.getElementsByClassName(a)),n}if(w.qsa&&(!H||!H.test(e))){if(p=d=z,h=t,m=9===s&&e,1===s&&"object"!==t.nodeName.toLowerCase()){for(c=T(e),(d=t.getAttribute("id"))?p=d.replace(xt,"\\$&"):t.setAttribute("id",p),p="[id='"+p+"'] ",l=c.length;l--;)c[l]=p+f(c[l]);h=bt.test(e)&&u(t.parentNode)||t,m=c.join(",")}if(m)try{return et.apply(n,h.querySelectorAll(m)),n}catch(g){}finally{d||t.removeAttribute("id")}}}return N(e.replace(ct,"$1"),t,n,r)}function n(){function e(n,r){return t.push(n+" ")>C.cacheLength&&delete e[t.shift()],e[n+" "]=r}var t=[];return e}function r(e){return e[z]=!0,e}function i(e){var t=R.createElement("div");try{return!!e(t)}catch(n){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function o(e,t){for(var n=e.split("|"),r=e.length;r--;)C.attrHandle[n[r]]=t}function a(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||V)-(~e.sourceIndex||V);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function s(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function l(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function c(e){return r(function(t){return t=+t,r(function(n,r){for(var i,o=e([],n.length,t),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}function u(e){return e&&typeof e.getElementsByTagName!==G&&e}function d(){}function f(e){for(var t=0,n=e.length,r="";n>t;t++)r+=e[t].value;return r}function p(e,t,n){var r=t.dir,i=n&&"parentNode"===r,o=I++;return t.first?function(t,n,o){for(;t=t[r];)if(1===t.nodeType||i)return e(t,n,o)}:function(t,n,a){var s,l,c=[B,o];if(a){for(;t=t[r];)if((1===t.nodeType||i)&&e(t,n,a))return!0}else for(;t=t[r];)if(1===t.nodeType||i){if(l=t[z]||(t[z]={}),(s=l[r])&&s[0]===B&&s[1]===o)return c[2]=s[2];if(l[r]=c,c[2]=e(t,n,a))return!0}}}function h(e){return e.length>1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function m(e,n,r){for(var i=0,o=n.length;o>i;i++)t(e,n[i],r);return r}function g(e,t,n,r,i){for(var o,a=[],s=0,l=e.length,c=null!=t;l>s;s++)(o=e[s])&&(!n||n(o,r,i))&&(a.push(o),c&&t.push(s));return a}function v(e,t,n,i,o,a){return i&&!i[z]&&(i=v(i)),o&&!o[z]&&(o=v(o,a)),r(function(r,a,s,l){var c,u,d,f=[],p=[],h=a.length,v=r||m(t||"*",s.nodeType?[s]:s,[]),y=!e||!r&&t?v:g(v,f,e,s,l),b=n?o||(r?e:h||i)?[]:a:y;if(n&&n(y,b,s,l),i)for(c=g(b,p),i(c,[],s,l),u=c.length;u--;)(d=c[u])&&(b[p[u]]=!(y[p[u]]=d));if(r){if(o||e){if(o){for(c=[],u=b.length;u--;)(d=b[u])&&c.push(y[u]=d);o(null,b=[],c,l)}for(u=b.length;u--;)(d=b[u])&&(c=o?nt.call(r,d):f[u])>-1&&(r[c]=!(a[c]=d))}}else b=g(b===a?b.splice(h,b.length):b),o?o(null,a,b,l):et.apply(a,b)})}function y(e){for(var t,n,r,i=e.length,o=C.relative[e[0].type],a=o||C.relative[" "],s=o?1:0,l=p(function(e){return e===t},a,!0),c=p(function(e){return nt.call(t,e)>-1},a,!0),u=[function(e,n,r){return!o&&(r||n!==L)||((t=n).nodeType?l(e,n,r):c(e,n,r))}];i>s;s++)if(n=C.relative[e[s].type])u=[p(h(u),n)];else{if(n=C.filter[e[s].type].apply(null,e[s].matches),n[z]){for(r=++s;i>r&&!C.relative[e[r].type];r++);return v(s>1&&h(u),s>1&&f(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace(ct,"$1"),n,r>s&&y(e.slice(s,r)),i>r&&y(e=e.slice(r)),i>r&&f(e))}u.push(n)}return h(u)}function b(e,n){var i=n.length>0,o=e.length>0,a=function(r,a,s,l,c){var u,d,f,p=0,h="0",m=r&&[],v=[],y=L,b=r||o&&C.find.TAG("*",c),x=B+=null==y?1:Math.random()||.1,w=b.length;for(c&&(L=a!==R&&a);h!==w&&null!=(u=b[h]);h++){if(o&&u){for(d=0;f=e[d++];)if(f(u,a,s)){l.push(u);break}c&&(B=x)}i&&((u=!f&&u)&&p--,r&&m.push(u))}if(p+=h,i&&h!==p){for(d=0;f=n[d++];)f(m,v,a,s);if(r){if(p>0)for(;h--;)m[h]||v[h]||(v[h]=K.call(l));v=g(v)}et.apply(l,v),c&&!r&&v.length>0&&p+n.length>1&&t.uniqueSort(l)}return c&&(B=x,L=y),m};return i?r(a):a}var x,w,C,k,S,T,E,N,L,A,D,j,R,P,_,H,O,q,M,z="sizzle"+-new Date,F=e.document,B=0,I=0,W=n(),U=n(),X=n(),Z=function(e,t){return e===t&&(D=!0),0},G="undefined",V=1<<31,Q={}.hasOwnProperty,Y=[],K=Y.pop,J=Y.push,et=Y.push,tt=Y.slice,nt=Y.indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(this[t]===e)return t;return-1},rt="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",it="[\\x20\\t\\r\\n\\f]",ot="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",at=ot.replace("w","w#"),st="\\["+it+"*("+ot+")(?:"+it+"*([*^$|!~]?=)"+it+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+at+"))|)"+it+"*\\]",lt=":("+ot+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+st+")*)|.*)\\)|)",ct=new RegExp("^"+it+"+|((?:^|[^\\\\])(?:\\\\.)*)"+it+"+$","g"),ut=new RegExp("^"+it+"*,"+it+"*"),dt=new RegExp("^"+it+"*([>+~]|"+it+")"+it+"*"),ft=new RegExp("="+it+"*([^\\]'\"]*?)"+it+"*\\]","g"),pt=new RegExp(lt),ht=new RegExp("^"+at+"$"),mt={ID:new RegExp("^#("+ot+")"),CLASS:new RegExp("^\\.("+ot+")"),TAG:new RegExp("^("+ot.replace("w","w*")+")"),ATTR:new RegExp("^"+st),PSEUDO:new RegExp("^"+lt),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+it+"*(even|odd|(([+-]|)(\\d*)n|)"+it+"*(?:([+-]|)"+it+"*(\\d+)|))"+it+"*\\)|)","i"),bool:new RegExp("^(?:"+rt+")$","i"),needsContext:new RegExp("^"+it+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+it+"*((?:-\\d)?\\d*)"+it+"*\\)|)(?=[^-]|$)","i")},gt=/^(?:input|select|textarea|button)$/i,vt=/^h\d$/i,$=/^[^{]+\{\s*\[native \w/,yt=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,bt=/[+~]/,xt=/'|\\/g,wt=new RegExp("\\\\([\\da-f]{1,6}"+it+"?|("+it+")|.)","ig"),Ct=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:0>r?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)};try{et.apply(Y=tt.call(F.childNodes),F.childNodes),Y[F.childNodes.length].nodeType}catch(kt){et={apply:Y.length?function(e,t){J.apply(e,tt.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}w=t.support={},S=t.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?"HTML"!==t.nodeName:!1},j=t.setDocument=function(e){var t,n=e?e.ownerDocument||e:F,r=n.defaultView;return n!==R&&9===n.nodeType&&n.documentElement?(R=n,P=n.documentElement,_=!S(n),r&&r!==r.top&&(r.addEventListener?r.addEventListener("unload",function(){j()},!1):r.attachEvent&&r.attachEvent("onunload",function(){j() -})),w.attributes=i(function(e){return e.className="i",!e.getAttribute("className")}),w.getElementsByTagName=i(function(e){return e.appendChild(n.createComment("")),!e.getElementsByTagName("*").length}),w.getElementsByClassName=$.test(n.getElementsByClassName)&&i(function(e){return e.innerHTML="<div class='a'></div><div class='a i'></div>",e.firstChild.className="i",2===e.getElementsByClassName("i").length}),w.getById=i(function(e){return P.appendChild(e).id=z,!n.getElementsByName||!n.getElementsByName(z).length}),w.getById?(C.find.ID=function(e,t){if(typeof t.getElementById!==G&&_){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},C.filter.ID=function(e){var t=e.replace(wt,Ct);return function(e){return e.getAttribute("id")===t}}):(delete C.find.ID,C.filter.ID=function(e){var t=e.replace(wt,Ct);return function(e){var n=typeof e.getAttributeNode!==G&&e.getAttributeNode("id");return n&&n.value===t}}),C.find.TAG=w.getElementsByTagName?function(e,t){return typeof t.getElementsByTagName!==G?t.getElementsByTagName(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},C.find.CLASS=w.getElementsByClassName&&function(e,t){return typeof t.getElementsByClassName!==G&&_?t.getElementsByClassName(e):void 0},O=[],H=[],(w.qsa=$.test(n.querySelectorAll))&&(i(function(e){e.innerHTML="<select msallowclip=''><option selected=''></option></select>",e.querySelectorAll("[msallowclip^='']").length&&H.push("[*^$]="+it+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||H.push("\\["+it+"*(?:value|"+rt+")"),e.querySelectorAll(":checked").length||H.push(":checked")}),i(function(e){var t=n.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&H.push("name"+it+"*[*^$|!~]?="),e.querySelectorAll(":enabled").length||H.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),H.push(",.*:")})),(w.matchesSelector=$.test(q=P.matches||P.webkitMatchesSelector||P.mozMatchesSelector||P.oMatchesSelector||P.msMatchesSelector))&&i(function(e){w.disconnectedMatch=q.call(e,"div"),q.call(e,"[s!='']:x"),O.push("!=",lt)}),H=H.length&&new RegExp(H.join("|")),O=O.length&&new RegExp(O.join("|")),t=$.test(P.compareDocumentPosition),M=t||$.test(P.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},Z=t?function(e,t){if(e===t)return D=!0,0;var r=!e.compareDocumentPosition-!t.compareDocumentPosition;return r?r:(r=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1,1&r||!w.sortDetached&&t.compareDocumentPosition(e)===r?e===n||e.ownerDocument===F&&M(F,e)?-1:t===n||t.ownerDocument===F&&M(F,t)?1:A?nt.call(A,e)-nt.call(A,t):0:4&r?-1:1)}:function(e,t){if(e===t)return D=!0,0;var r,i=0,o=e.parentNode,s=t.parentNode,l=[e],c=[t];if(!o||!s)return e===n?-1:t===n?1:o?-1:s?1:A?nt.call(A,e)-nt.call(A,t):0;if(o===s)return a(e,t);for(r=e;r=r.parentNode;)l.unshift(r);for(r=t;r=r.parentNode;)c.unshift(r);for(;l[i]===c[i];)i++;return i?a(l[i],c[i]):l[i]===F?-1:c[i]===F?1:0},n):R},t.matches=function(e,n){return t(e,null,null,n)},t.matchesSelector=function(e,n){if((e.ownerDocument||e)!==R&&j(e),n=n.replace(ft,"='$1']"),!(!w.matchesSelector||!_||O&&O.test(n)||H&&H.test(n)))try{var r=q.call(e,n);if(r||w.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(i){}return t(n,R,null,[e]).length>0},t.contains=function(e,t){return(e.ownerDocument||e)!==R&&j(e),M(e,t)},t.attr=function(e,t){(e.ownerDocument||e)!==R&&j(e);var n=C.attrHandle[t.toLowerCase()],r=n&&Q.call(C.attrHandle,t.toLowerCase())?n(e,t,!_):void 0;return void 0!==r?r:w.attributes||!_?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},t.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},t.uniqueSort=function(e){var t,n=[],r=0,i=0;if(D=!w.detectDuplicates,A=!w.sortStable&&e.slice(0),e.sort(Z),D){for(;t=e[i++];)t===e[i]&&(r=n.push(i));for(;r--;)e.splice(n[r],1)}return A=null,e},k=t.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=k(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r++];)n+=k(t);return n},C=t.selectors={cacheLength:50,createPseudo:r,match:mt,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(wt,Ct),e[3]=(e[3]||e[4]||e[5]||"").replace(wt,Ct),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||t.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&t.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return mt.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&pt.test(n)&&(t=T(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(wt,Ct).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=W[e+" "];return t||(t=new RegExp("(^|"+it+")"+e+"("+it+"|$)"))&&W(e,function(e){return t.test("string"==typeof e.className&&e.className||typeof e.getAttribute!==G&&e.getAttribute("class")||"")})},ATTR:function(e,n,r){return function(i){var o=t.attr(i,e);return null==o?"!="===n:n?(o+="","="===n?o===r:"!="===n?o!==r:"^="===n?r&&0===o.indexOf(r):"*="===n?r&&o.indexOf(r)>-1:"$="===n?r&&o.slice(-r.length)===r:"~="===n?(" "+o+" ").indexOf(r)>-1:"|="===n?o===r||o.slice(0,r.length+1)===r+"-":!1):!0}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,l){var c,u,d,f,p,h,m=o!==a?"nextSibling":"previousSibling",g=t.parentNode,v=s&&t.nodeName.toLowerCase(),y=!l&&!s;if(g){if(o){for(;m;){for(d=t;d=d[m];)if(s?d.nodeName.toLowerCase()===v:1===d.nodeType)return!1;h=m="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?g.firstChild:g.lastChild],a&&y){for(u=g[z]||(g[z]={}),c=u[e]||[],p=c[0]===B&&c[1],f=c[0]===B&&c[2],d=p&&g.childNodes[p];d=++p&&d&&d[m]||(f=p=0)||h.pop();)if(1===d.nodeType&&++f&&d===t){u[e]=[B,p,f];break}}else if(y&&(c=(t[z]||(t[z]={}))[e])&&c[0]===B)f=c[1];else for(;(d=++p&&d&&d[m]||(f=p=0)||h.pop())&&((s?d.nodeName.toLowerCase()!==v:1!==d.nodeType)||!++f||(y&&((d[z]||(d[z]={}))[e]=[B,f]),d!==t)););return f-=i,f===r||f%r===0&&f/r>=0}}},PSEUDO:function(e,n){var i,o=C.pseudos[e]||C.setFilters[e.toLowerCase()]||t.error("unsupported pseudo: "+e);return o[z]?o(n):o.length>1?(i=[e,e,"",n],C.setFilters.hasOwnProperty(e.toLowerCase())?r(function(e,t){for(var r,i=o(e,n),a=i.length;a--;)r=nt.call(e,i[a]),e[r]=!(t[r]=i[a])}):function(e){return o(e,0,i)}):o}},pseudos:{not:r(function(e){var t=[],n=[],i=E(e.replace(ct,"$1"));return i[z]?r(function(e,t,n,r){for(var o,a=i(e,null,r,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,r,o){return t[0]=e,i(t,null,o,n),!n.pop()}}),has:r(function(e){return function(n){return t(e,n).length>0}}),contains:r(function(e){return function(t){return(t.textContent||t.innerText||k(t)).indexOf(e)>-1}}),lang:r(function(e){return ht.test(e||"")||t.error("unsupported lang: "+e),e=e.replace(wt,Ct).toLowerCase(),function(t){var n;do if(n=_?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===P},focus:function(e){return e===R.activeElement&&(!R.hasFocus||R.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!C.pseudos.empty(e)},header:function(e){return vt.test(e.nodeName)},input:function(e){return gt.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:c(function(){return[0]}),last:c(function(e,t){return[t-1]}),eq:c(function(e,t,n){return[0>n?n+t:n]}),even:c(function(e,t){for(var n=0;t>n;n+=2)e.push(n);return e}),odd:c(function(e,t){for(var n=1;t>n;n+=2)e.push(n);return e}),lt:c(function(e,t,n){for(var r=0>n?n+t:n;--r>=0;)e.push(r);return e}),gt:c(function(e,t,n){for(var r=0>n?n+t:n;++r<t;)e.push(r);return e})}},C.pseudos.nth=C.pseudos.eq;for(x in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})C.pseudos[x]=s(x);for(x in{submit:!0,reset:!0})C.pseudos[x]=l(x);return d.prototype=C.filters=C.pseudos,C.setFilters=new d,T=t.tokenize=function(e,n){var r,i,o,a,s,l,c,u=U[e+" "];if(u)return n?0:u.slice(0);for(s=e,l=[],c=C.preFilter;s;){(!r||(i=ut.exec(s)))&&(i&&(s=s.slice(i[0].length)||s),l.push(o=[])),r=!1,(i=dt.exec(s))&&(r=i.shift(),o.push({value:r,type:i[0].replace(ct," ")}),s=s.slice(r.length));for(a in C.filter)!(i=mt[a].exec(s))||c[a]&&!(i=c[a](i))||(r=i.shift(),o.push({value:r,type:a,matches:i}),s=s.slice(r.length));if(!r)break}return n?s.length:s?t.error(e):U(e,l).slice(0)},E=t.compile=function(e,t){var n,r=[],i=[],o=X[e+" "];if(!o){for(t||(t=T(e)),n=t.length;n--;)o=y(t[n]),o[z]?r.push(o):i.push(o);o=X(e,b(i,r)),o.selector=e}return o},N=t.select=function(e,t,n,r){var i,o,a,s,l,c="function"==typeof e&&e,d=!r&&T(e=c.selector||e);if(n=n||[],1===d.length){if(o=d[0]=d[0].slice(0),o.length>2&&"ID"===(a=o[0]).type&&w.getById&&9===t.nodeType&&_&&C.relative[o[1].type]){if(t=(C.find.ID(a.matches[0].replace(wt,Ct),t)||[])[0],!t)return n;c&&(t=t.parentNode),e=e.slice(o.shift().value.length)}for(i=mt.needsContext.test(e)?0:o.length;i--&&(a=o[i],!C.relative[s=a.type]);)if((l=C.find[s])&&(r=l(a.matches[0].replace(wt,Ct),bt.test(o[0].type)&&u(t.parentNode)||t))){if(o.splice(i,1),e=r.length&&f(o),!e)return et.apply(n,r),n;break}}return(c||E(e,d))(r,t,!_,n,bt.test(e)&&u(t.parentNode)||t),n},w.sortStable=z.split("").sort(Z).join("")===z,w.detectDuplicates=!!D,j(),w.sortDetached=i(function(e){return 1&e.compareDocumentPosition(R.createElement("div"))}),i(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||o("type|href|height|width",function(e,t,n){return n?void 0:e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),w.attributes&&i(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||o("value",function(e,t,n){return n||"input"!==e.nodeName.toLowerCase()?void 0:e.defaultValue}),i(function(e){return null==e.getAttribute("disabled")})||o(rt,function(e,t,n){var r;return n?void 0:e[t]===!0?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),t}(e);ot.find=ut,ot.expr=ut.selectors,ot.expr[":"]=ot.expr.pseudos,ot.unique=ut.uniqueSort,ot.text=ut.getText,ot.isXMLDoc=ut.isXML,ot.contains=ut.contains;var dt=ot.expr.match.needsContext,ft=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,pt=/^.[^:#\[\.,]*$/;ot.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?ot.find.matchesSelector(r,e)?[r]:[]:ot.find.matches(e,ot.grep(t,function(e){return 1===e.nodeType}))},ot.fn.extend({find:function(e){var t,n=[],r=this,i=r.length;if("string"!=typeof e)return this.pushStack(ot(e).filter(function(){for(t=0;i>t;t++)if(ot.contains(r[t],this))return!0}));for(t=0;i>t;t++)ot.find(e,r[t],n);return n=this.pushStack(i>1?ot.unique(n):n),n.selector=this.selector?this.selector+" "+e:e,n},filter:function(e){return this.pushStack(r(this,e||[],!1))},not:function(e){return this.pushStack(r(this,e||[],!0))},is:function(e){return!!r(this,"string"==typeof e&&dt.test(e)?ot(e):e||[],!1).length}});var ht,mt=e.document,gt=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,vt=ot.fn.init=function(e,t){var n,r;if(!e)return this;if("string"==typeof e){if(n="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:gt.exec(e),!n||!n[1]&&t)return!t||t.jquery?(t||ht).find(e):this.constructor(t).find(e);if(n[1]){if(t=t instanceof ot?t[0]:t,ot.merge(this,ot.parseHTML(n[1],t&&t.nodeType?t.ownerDocument||t:mt,!0)),ft.test(n[1])&&ot.isPlainObject(t))for(n in t)ot.isFunction(this[n])?this[n](t[n]):this.attr(n,t[n]);return this}if(r=mt.getElementById(n[2]),r&&r.parentNode){if(r.id!==n[2])return ht.find(e);this.length=1,this[0]=r}return this.context=mt,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):ot.isFunction(e)?"undefined"!=typeof ht.ready?ht.ready(e):e(ot):(void 0!==e.selector&&(this.selector=e.selector,this.context=e.context),ot.makeArray(e,this))};vt.prototype=ot.fn,ht=ot(mt);var yt=/^(?:parents|prev(?:Until|All))/,bt={children:!0,contents:!0,next:!0,prev:!0};ot.extend({dir:function(e,t,n){for(var r=[],i=e[t];i&&9!==i.nodeType&&(void 0===n||1!==i.nodeType||!ot(i).is(n));)1===i.nodeType&&r.push(i),i=i[t];return r},sibling:function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}}),ot.fn.extend({has:function(e){var t,n=ot(e,this),r=n.length;return this.filter(function(){for(t=0;r>t;t++)if(ot.contains(this,n[t]))return!0})},closest:function(e,t){for(var n,r=0,i=this.length,o=[],a=dt.test(e)||"string"!=typeof e?ot(e,t||this.context):0;i>r;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&ot.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?ot.unique(o):o)},index:function(e){return e?"string"==typeof e?ot.inArray(this[0],ot(e)):ot.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(ot.unique(ot.merge(this.get(),ot(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),ot.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return ot.dir(e,"parentNode")},parentsUntil:function(e,t,n){return ot.dir(e,"parentNode",n)},next:function(e){return i(e,"nextSibling")},prev:function(e){return i(e,"previousSibling")},nextAll:function(e){return ot.dir(e,"nextSibling")},prevAll:function(e){return ot.dir(e,"previousSibling")},nextUntil:function(e,t,n){return ot.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return ot.dir(e,"previousSibling",n)},siblings:function(e){return ot.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return ot.sibling(e.firstChild)},contents:function(e){return ot.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:ot.merge([],e.childNodes)}},function(e,t){ot.fn[e]=function(n,r){var i=ot.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=ot.filter(r,i)),this.length>1&&(bt[e]||(i=ot.unique(i)),yt.test(e)&&(i=i.reverse())),this.pushStack(i)}});var xt=/\S+/g,wt={};ot.Callbacks=function(e){e="string"==typeof e?wt[e]||o(e):ot.extend({},e);var t,n,r,i,a,s,l=[],c=!e.once&&[],u=function(o){for(n=e.memory&&o,r=!0,a=s||0,s=0,i=l.length,t=!0;l&&i>a;a++)if(l[a].apply(o[0],o[1])===!1&&e.stopOnFalse){n=!1;break}t=!1,l&&(c?c.length&&u(c.shift()):n?l=[]:d.disable())},d={add:function(){if(l){var r=l.length;!function o(t){ot.each(t,function(t,n){var r=ot.type(n);"function"===r?e.unique&&d.has(n)||l.push(n):n&&n.length&&"string"!==r&&o(n)})}(arguments),t?i=l.length:n&&(s=r,u(n))}return this},remove:function(){return l&&ot.each(arguments,function(e,n){for(var r;(r=ot.inArray(n,l,r))>-1;)l.splice(r,1),t&&(i>=r&&i--,a>=r&&a--)}),this},has:function(e){return e?ot.inArray(e,l)>-1:!(!l||!l.length)},empty:function(){return l=[],i=0,this},disable:function(){return l=c=n=void 0,this},disabled:function(){return!l},lock:function(){return c=void 0,n||d.disable(),this},locked:function(){return!c},fireWith:function(e,n){return!l||r&&!c||(n=n||[],n=[e,n.slice?n.slice():n],t?c.push(n):u(n)),this},fire:function(){return d.fireWith(this,arguments),this},fired:function(){return!!r}};return d},ot.extend({Deferred:function(e){var t=[["resolve","done",ot.Callbacks("once memory"),"resolved"],["reject","fail",ot.Callbacks("once memory"),"rejected"],["notify","progress",ot.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return ot.Deferred(function(n){ot.each(t,function(t,o){var a=ot.isFunction(e[t])&&e[t];i[o[1]](function(){var e=a&&a.apply(this,arguments);e&&ot.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[o[0]+"With"](this===r?n.promise():this,a?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?ot.extend(e,r):r}},i={};return r.pipe=r.then,ot.each(t,function(e,o){var a=o[2],s=o[3];r[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=a.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t=0,n=Q.call(arguments),r=n.length,i=1!==r||e&&ot.isFunction(e.promise)?r:0,o=1===i?e:ot.Deferred(),a=function(e,t,n){return function(r){t[e]=this,n[e]=arguments.length>1?Q.call(arguments):r,n===s?o.notifyWith(t,n):--i||o.resolveWith(t,n)}},s,l,c;if(r>1)for(s=new Array(r),l=new Array(r),c=new Array(r);r>t;t++)n[t]&&ot.isFunction(n[t].promise)?n[t].promise().done(a(t,c,n)).fail(o.reject).progress(a(t,l,s)):--i;return i||o.resolveWith(c,n),o.promise()}});var Ct;ot.fn.ready=function(e){return ot.ready.promise().done(e),this},ot.extend({isReady:!1,readyWait:1,holdReady:function(e){e?ot.readyWait++:ot.ready(!0)},ready:function(e){if(e===!0?!--ot.readyWait:!ot.isReady){if(!mt.body)return setTimeout(ot.ready);ot.isReady=!0,e!==!0&&--ot.readyWait>0||(Ct.resolveWith(mt,[ot]),ot.fn.triggerHandler&&(ot(mt).triggerHandler("ready"),ot(mt).off("ready")))}}}),ot.ready.promise=function(t){if(!Ct)if(Ct=ot.Deferred(),"complete"===mt.readyState)setTimeout(ot.ready);else if(mt.addEventListener)mt.addEventListener("DOMContentLoaded",s,!1),e.addEventListener("load",s,!1);else{mt.attachEvent("onreadystatechange",s),e.attachEvent("onload",s);var n=!1;try{n=null==e.frameElement&&mt.documentElement}catch(r){}n&&n.doScroll&&!function i(){if(!ot.isReady){try{n.doScroll("left")}catch(e){return setTimeout(i,50)}a(),ot.ready()}}()}return Ct.promise(t)};var kt="undefined",$t;for($t in ot(rt))break;rt.ownLast="0"!==$t,rt.inlineBlockNeedsLayout=!1,ot(function(){var e,t,n,r;n=mt.getElementsByTagName("body")[0],n&&n.style&&(t=mt.createElement("div"),r=mt.createElement("div"),r.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(r).appendChild(t),typeof t.style.zoom!==kt&&(t.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",rt.inlineBlockNeedsLayout=e=3===t.offsetWidth,e&&(n.style.zoom=1)),n.removeChild(r))}),function(){var e=mt.createElement("div");if(null==rt.deleteExpando){rt.deleteExpando=!0;try{delete e.test}catch(t){rt.deleteExpando=!1}}e=null}(),ot.acceptData=function(e){var t=ot.noData[(e.nodeName+" ").toLowerCase()],n=+e.nodeType||1;return 1!==n&&9!==n?!1:!t||t!==!0&&e.getAttribute("classid")===t};var St=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Tt=/([A-Z])/g;ot.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return e=e.nodeType?ot.cache[e[ot.expando]]:e[ot.expando],!!e&&!c(e)},data:function(e,t,n){return u(e,t,n)},removeData:function(e,t){return d(e,t)},_data:function(e,t,n){return u(e,t,n,!0)},_removeData:function(e,t){return d(e,t,!0)}}),ot.fn.extend({data:function(e,t){var n,r,i,o=this[0],a=o&&o.attributes;if(void 0===e){if(this.length&&(i=ot.data(o),1===o.nodeType&&!ot._data(o,"parsedAttrs"))){for(n=a.length;n--;)a[n]&&(r=a[n].name,0===r.indexOf("data-")&&(r=ot.camelCase(r.slice(5)),l(o,r,i[r])));ot._data(o,"parsedAttrs",!0)}return i}return"object"==typeof e?this.each(function(){ot.data(this,e)}):arguments.length>1?this.each(function(){ot.data(this,e,t)}):o?l(o,e,ot.data(o,e)):void 0},removeData:function(e){return this.each(function(){ot.removeData(this,e)})}}),ot.extend({queue:function(e,t,n){var r;return e?(t=(t||"fx")+"queue",r=ot._data(e,t),n&&(!r||ot.isArray(n)?r=ot._data(e,t,ot.makeArray(n)):r.push(n)),r||[]):void 0},dequeue:function(e,t){t=t||"fx";var n=ot.queue(e,t),r=n.length,i=n.shift(),o=ot._queueHooks(e,t),a=function(){ot.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return ot._data(e,n)||ot._data(e,n,{empty:ot.Callbacks("once memory").add(function(){ot._removeData(e,t+"queue"),ot._removeData(e,n)})})}}),ot.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?ot.queue(this[0],e):void 0===t?this:this.each(function(){var n=ot.queue(this,e,t);ot._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&ot.dequeue(this,e)})},dequeue:function(e){return this.each(function(){ot.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=ot.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof e&&(t=e,e=void 0),e=e||"fx";a--;)n=ot._data(o[a],e+"queueHooks"),n&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var Et=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,Nt=["Top","Right","Bottom","Left"],Lt=function(e,t){return e=t||e,"none"===ot.css(e,"display")||!ot.contains(e.ownerDocument,e)},At=ot.access=function(e,t,n,r,i,o,a){var s=0,l=e.length,c=null==n;if("object"===ot.type(n)){i=!0;for(s in n)ot.access(e,t,s,n[s],!0,o,a)}else if(void 0!==r&&(i=!0,ot.isFunction(r)||(a=!0),c&&(a?(t.call(e,r),t=null):(c=t,t=function(e,t,n){return c.call(ot(e),n)})),t))for(;l>s;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:c?t.call(e):l?t(e[0],n):o},Dt=/^(?:checkbox|radio)$/i;!function(){var e=mt.createElement("input"),t=mt.createElement("div"),n=mt.createDocumentFragment();if(t.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",rt.leadingWhitespace=3===t.firstChild.nodeType,rt.tbody=!t.getElementsByTagName("tbody").length,rt.htmlSerialize=!!t.getElementsByTagName("link").length,rt.html5Clone="<:nav></:nav>"!==mt.createElement("nav").cloneNode(!0).outerHTML,e.type="checkbox",e.checked=!0,n.appendChild(e),rt.appendChecked=e.checked,t.innerHTML="<textarea>x</textarea>",rt.noCloneChecked=!!t.cloneNode(!0).lastChild.defaultValue,n.appendChild(t),t.innerHTML="<input type='radio' checked='checked' name='t'/>",rt.checkClone=t.cloneNode(!0).cloneNode(!0).lastChild.checked,rt.noCloneEvent=!0,t.attachEvent&&(t.attachEvent("onclick",function(){rt.noCloneEvent=!1}),t.cloneNode(!0).click()),null==rt.deleteExpando){rt.deleteExpando=!0;try{delete t.test}catch(r){rt.deleteExpando=!1}}}(),function(){var t,n,r=mt.createElement("div");for(t in{submit:!0,change:!0,focusin:!0})n="on"+t,(rt[t+"Bubbles"]=n in e)||(r.setAttribute(n,"t"),rt[t+"Bubbles"]=r.attributes[n].expando===!1);r=null}();var jt=/^(?:input|select|textarea)$/i,Rt=/^key/,Pt=/^(?:mouse|pointer|contextmenu)|click/,$=/^(?:focusinfocus|focusoutblur)$/,_t=/^([^.]*)(?:\.(.+)|)$/;ot.event={global:{},add:function(e,t,n,r,i){var o,a,s,l,c,u,d,f,p,h,m,g=ot._data(e);if(g){for(n.handler&&(l=n,n=l.handler,i=l.selector),n.guid||(n.guid=ot.guid++),(a=g.events)||(a=g.events={}),(u=g.handle)||(u=g.handle=function(e){return typeof ot===kt||e&&ot.event.triggered===e.type?void 0:ot.event.dispatch.apply(u.elem,arguments)},u.elem=e),t=(t||"").match(xt)||[""],s=t.length;s--;)o=_t.exec(t[s])||[],p=m=o[1],h=(o[2]||"").split(".").sort(),p&&(c=ot.event.special[p]||{},p=(i?c.delegateType:c.bindType)||p,c=ot.event.special[p]||{},d=ot.extend({type:p,origType:m,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&ot.expr.match.needsContext.test(i),namespace:h.join(".")},l),(f=a[p])||(f=a[p]=[],f.delegateCount=0,c.setup&&c.setup.call(e,r,h,u)!==!1||(e.addEventListener?e.addEventListener(p,u,!1):e.attachEvent&&e.attachEvent("on"+p,u))),c.add&&(c.add.call(e,d),d.handler.guid||(d.handler.guid=n.guid)),i?f.splice(f.delegateCount++,0,d):f.push(d),ot.event.global[p]=!0);e=null}},remove:function(e,t,n,r,i){var o,a,s,l,c,u,d,f,p,h,m,g=ot.hasData(e)&&ot._data(e);if(g&&(u=g.events)){for(t=(t||"").match(xt)||[""],c=t.length;c--;)if(s=_t.exec(t[c])||[],p=m=s[1],h=(s[2]||"").split(".").sort(),p){for(d=ot.event.special[p]||{},p=(r?d.delegateType:d.bindType)||p,f=u[p]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),l=o=f.length;o--;)a=f[o],!i&&m!==a.origType||n&&n.guid!==a.guid||s&&!s.test(a.namespace)||r&&r!==a.selector&&("**"!==r||!a.selector)||(f.splice(o,1),a.selector&&f.delegateCount--,d.remove&&d.remove.call(e,a));l&&!f.length&&(d.teardown&&d.teardown.call(e,h,g.handle)!==!1||ot.removeEvent(e,p,g.handle),delete u[p])}else for(p in u)ot.event.remove(e,p+t[c],n,r,!0);ot.isEmptyObject(u)&&(delete g.handle,ot._removeData(e,"events"))}},trigger:function(t,n,r,i){var o,a,s,l,c,u,d,f=[r||mt],p=nt.call(t,"type")?t.type:t,h=nt.call(t,"namespace")?t.namespace.split("."):[];if(s=u=r=r||mt,3!==r.nodeType&&8!==r.nodeType&&!$.test(p+ot.event.triggered)&&(p.indexOf(".")>=0&&(h=p.split("."),p=h.shift(),h.sort()),a=p.indexOf(":")<0&&"on"+p,t=t[ot.expando]?t:new ot.Event(p,"object"==typeof t&&t),t.isTrigger=i?2:3,t.namespace=h.join("."),t.namespace_re=t.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=r),n=null==n?[t]:ot.makeArray(n,[t]),c=ot.event.special[p]||{},i||!c.trigger||c.trigger.apply(r,n)!==!1)){if(!i&&!c.noBubble&&!ot.isWindow(r)){for(l=c.delegateType||p,$.test(l+p)||(s=s.parentNode);s;s=s.parentNode)f.push(s),u=s;u===(r.ownerDocument||mt)&&f.push(u.defaultView||u.parentWindow||e)}for(d=0;(s=f[d++])&&!t.isPropagationStopped();)t.type=d>1?l:c.bindType||p,o=(ot._data(s,"events")||{})[t.type]&&ot._data(s,"handle"),o&&o.apply(s,n),o=a&&s[a],o&&o.apply&&ot.acceptData(s)&&(t.result=o.apply(s,n),t.result===!1&&t.preventDefault());if(t.type=p,!i&&!t.isDefaultPrevented()&&(!c._default||c._default.apply(f.pop(),n)===!1)&&ot.acceptData(r)&&a&&r[p]&&!ot.isWindow(r)){u=r[a],u&&(r[a]=null),ot.event.triggered=p;try{r[p]()}catch(m){}ot.event.triggered=void 0,u&&(r[a]=u)}return t.result}},dispatch:function(e){e=ot.event.fix(e);var t,n,r,i,o,a=[],s=Q.call(arguments),l=(ot._data(this,"events")||{})[e.type]||[],c=ot.event.special[e.type]||{};if(s[0]=e,e.delegateTarget=this,!c.preDispatch||c.preDispatch.call(this,e)!==!1){for(a=ot.event.handlers.call(this,e,l),t=0;(i=a[t++])&&!e.isPropagationStopped();)for(e.currentTarget=i.elem,o=0;(r=i.handlers[o++])&&!e.isImmediatePropagationStopped();)(!e.namespace_re||e.namespace_re.test(r.namespace))&&(e.handleObj=r,e.data=r.data,n=((ot.event.special[r.origType]||{}).handle||r.handler).apply(i.elem,s),void 0!==n&&(e.result=n)===!1&&(e.preventDefault(),e.stopPropagation()));return c.postDispatch&&c.postDispatch.call(this,e),e.result}},handlers:function(e,t){var n,r,i,o,a=[],s=t.delegateCount,l=e.target;if(s&&l.nodeType&&(!e.button||"click"!==e.type))for(;l!=this;l=l.parentNode||this)if(1===l.nodeType&&(l.disabled!==!0||"click"!==e.type)){for(i=[],o=0;s>o;o++)r=t[o],n=r.selector+" ",void 0===i[n]&&(i[n]=r.needsContext?ot(n,this).index(l)>=0:ot.find(n,this,null,[l]).length),i[n]&&i.push(r);i.length&&a.push({elem:l,handlers:i})}return s<t.length&&a.push({elem:this,handlers:t.slice(s)}),a},fix:function(e){if(e[ot.expando])return e;var t,n,r,i=e.type,o=e,a=this.fixHooks[i];for(a||(this.fixHooks[i]=a=Pt.test(i)?this.mouseHooks:Rt.test(i)?this.keyHooks:{}),r=a.props?this.props.concat(a.props):this.props,e=new ot.Event(o),t=r.length;t--;)n=r[t],e[n]=o[n];return e.target||(e.target=o.srcElement||mt),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,a.filter?a.filter(e,o):e},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,t){var n,r,i,o=t.button,a=t.fromElement;return null==e.pageX&&null!=t.clientX&&(r=e.target.ownerDocument||mt,i=r.documentElement,n=r.body,e.pageX=t.clientX+(i&&i.scrollLeft||n&&n.scrollLeft||0)-(i&&i.clientLeft||n&&n.clientLeft||0),e.pageY=t.clientY+(i&&i.scrollTop||n&&n.scrollTop||0)-(i&&i.clientTop||n&&n.clientTop||0)),!e.relatedTarget&&a&&(e.relatedTarget=a===e.target?t.toElement:a),e.which||void 0===o||(e.which=1&o?1:2&o?3:4&o?2:0),e}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==h()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){return this===h()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return ot.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):void 0},_default:function(e){return ot.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n,r){var i=ot.extend(new ot.Event,n,{type:e,isSimulated:!0,originalEvent:{}});r?ot.event.trigger(i,null,t):ot.event.dispatch.call(t,i),i.isDefaultPrevented()&&n.preventDefault()}},ot.removeEvent=mt.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var r="on"+t;e.detachEvent&&(typeof e[r]===kt&&(e[r]=null),e.detachEvent(r,n))},ot.Event=function(e,t){return this instanceof ot.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&e.returnValue===!1?f:p):this.type=e,t&&ot.extend(this,t),this.timeStamp=e&&e.timeStamp||ot.now(),void(this[ot.expando]=!0)):new ot.Event(e,t)},ot.Event.prototype={isDefaultPrevented:p,isPropagationStopped:p,isImmediatePropagationStopped:p,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=f,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=f,e&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=f,e&&e.stopImmediatePropagation&&e.stopImmediatePropagation(),this.stopPropagation()}},ot.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,t){ot.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return(!i||i!==r&&!ot.contains(r,i))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),rt.submitBubbles||(ot.event.special.submit={setup:function(){return ot.nodeName(this,"form")?!1:void ot.event.add(this,"click._submit keypress._submit",function(e){var t=e.target,n=ot.nodeName(t,"input")||ot.nodeName(t,"button")?t.form:void 0;n&&!ot._data(n,"submitBubbles")&&(ot.event.add(n,"submit._submit",function(e){e._submit_bubble=!0}),ot._data(n,"submitBubbles",!0))})},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&ot.event.simulate("submit",this.parentNode,e,!0)) -},teardown:function(){return ot.nodeName(this,"form")?!1:void ot.event.remove(this,"._submit")}}),rt.changeBubbles||(ot.event.special.change={setup:function(){return jt.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(ot.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._just_changed=!0)}),ot.event.add(this,"click._change",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),ot.event.simulate("change",this,e,!0)})),!1):void ot.event.add(this,"beforeactivate._change",function(e){var t=e.target;jt.test(t.nodeName)&&!ot._data(t,"changeBubbles")&&(ot.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||ot.event.simulate("change",this.parentNode,e,!0)}),ot._data(t,"changeBubbles",!0))})},handle:function(e){var t=e.target;return this!==t||e.isSimulated||e.isTrigger||"radio"!==t.type&&"checkbox"!==t.type?e.handleObj.handler.apply(this,arguments):void 0},teardown:function(){return ot.event.remove(this,"._change"),!jt.test(this.nodeName)}}),rt.focusinBubbles||ot.each({focus:"focusin",blur:"focusout"},function(e,t){var n=function(e){ot.event.simulate(t,e.target,ot.event.fix(e),!0)};ot.event.special[t]={setup:function(){var r=this.ownerDocument||this,i=ot._data(r,t);i||r.addEventListener(e,n,!0),ot._data(r,t,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this,i=ot._data(r,t)-1;i?ot._data(r,t,i):(r.removeEventListener(e,n,!0),ot._removeData(r,t))}}}),ot.fn.extend({on:function(e,t,n,r,i){var o,a;if("object"==typeof e){"string"!=typeof t&&(n=n||t,t=void 0);for(o in e)this.on(o,t,n,e[o],i);return this}if(null==n&&null==r?(r=t,n=t=void 0):null==r&&("string"==typeof t?(r=n,n=void 0):(r=n,n=t,t=void 0)),r===!1)r=p;else if(!r)return this;return 1===i&&(a=r,r=function(e){return ot().off(e),a.apply(this,arguments)},r.guid=a.guid||(a.guid=ot.guid++)),this.each(function(){ot.event.add(this,e,r,n,t)})},one:function(e,t,n,r){return this.on(e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,ot(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return(t===!1||"function"==typeof t)&&(n=t,t=void 0),n===!1&&(n=p),this.each(function(){ot.event.remove(this,e,n,t)})},trigger:function(e,t){return this.each(function(){ot.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];return n?ot.event.trigger(e,t,n,!0):void 0}});var Ht="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",Ot=/ jQuery\d+="(?:null|\d+)"/g,qt=new RegExp("<(?:"+Ht+")[\\s/>]","i"),Mt=/^\s+/,zt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,Ft=/<([\w:]+)/,Bt=/<tbody/i,It=/<|&#?\w+;/,Wt=/<(?:script|style|link)/i,Ut=/checked\s*(?:[^=]|=\s*.checked.)/i,Xt=/^$|\/(?:java|ecma)script/i,Zt=/^true\/(.*)/,Gt=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,Vt={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:rt.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]},Qt=m(mt),Yt=Qt.appendChild(mt.createElement("div"));Vt.optgroup=Vt.option,Vt.tbody=Vt.tfoot=Vt.colgroup=Vt.caption=Vt.thead,Vt.th=Vt.td,ot.extend({clone:function(e,t,n){var r,i,o,a,s,l=ot.contains(e.ownerDocument,e);if(rt.html5Clone||ot.isXMLDoc(e)||!qt.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(Yt.innerHTML=e.outerHTML,Yt.removeChild(o=Yt.firstChild)),!(rt.noCloneEvent&&rt.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||ot.isXMLDoc(e)))for(r=g(o),s=g(e),a=0;null!=(i=s[a]);++a)r[a]&&k(i,r[a]);if(t)if(n)for(s=s||g(e),r=r||g(o),a=0;null!=(i=s[a]);a++)C(i,r[a]);else C(e,o);return r=g(o,"script"),r.length>0&&w(r,!l&&g(e,"script")),r=s=i=null,o},buildFragment:function(e,t,n,r){for(var i,o,a,s,l,c,u,d=e.length,f=m(t),p=[],h=0;d>h;h++)if(o=e[h],o||0===o)if("object"===ot.type(o))ot.merge(p,o.nodeType?[o]:o);else if(It.test(o)){for(s=s||f.appendChild(t.createElement("div")),l=(Ft.exec(o)||["",""])[1].toLowerCase(),u=Vt[l]||Vt._default,s.innerHTML=u[1]+o.replace(zt,"<$1></$2>")+u[2],i=u[0];i--;)s=s.lastChild;if(!rt.leadingWhitespace&&Mt.test(o)&&p.push(t.createTextNode(Mt.exec(o)[0])),!rt.tbody)for(o="table"!==l||Bt.test(o)?"<table>"!==u[1]||Bt.test(o)?0:s:s.firstChild,i=o&&o.childNodes.length;i--;)ot.nodeName(c=o.childNodes[i],"tbody")&&!c.childNodes.length&&o.removeChild(c);for(ot.merge(p,s.childNodes),s.textContent="";s.firstChild;)s.removeChild(s.firstChild);s=f.lastChild}else p.push(t.createTextNode(o));for(s&&f.removeChild(s),rt.appendChecked||ot.grep(g(p,"input"),v),h=0;o=p[h++];)if((!r||-1===ot.inArray(o,r))&&(a=ot.contains(o.ownerDocument,o),s=g(f.appendChild(o),"script"),a&&w(s),n))for(i=0;o=s[i++];)Xt.test(o.type||"")&&n.push(o);return s=null,f},cleanData:function(e,t){for(var n,r,i,o,a=0,s=ot.expando,l=ot.cache,c=rt.deleteExpando,u=ot.event.special;null!=(n=e[a]);a++)if((t||ot.acceptData(n))&&(i=n[s],o=i&&l[i])){if(o.events)for(r in o.events)u[r]?ot.event.remove(n,r):ot.removeEvent(n,r,o.handle);l[i]&&(delete l[i],c?delete n[s]:typeof n.removeAttribute!==kt?n.removeAttribute(s):n[s]=null,V.push(i))}}}),ot.fn.extend({text:function(e){return At(this,function(e){return void 0===e?ot.text(this):this.empty().append((this[0]&&this[0].ownerDocument||mt).createTextNode(e))},null,e,arguments.length)},append:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=y(this,e);t.appendChild(e)}})},prepend:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=y(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){for(var n,r=e?ot.filter(e,this):this,i=0;null!=(n=r[i]);i++)t||1!==n.nodeType||ot.cleanData(g(n)),n.parentNode&&(t&&ot.contains(n.ownerDocument,n)&&w(g(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){for(var e,t=0;null!=(e=this[t]);t++){for(1===e.nodeType&&ot.cleanData(g(e,!1));e.firstChild;)e.removeChild(e.firstChild);e.options&&ot.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return ot.clone(this,e,t)})},html:function(e){return At(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e)return 1===t.nodeType?t.innerHTML.replace(Ot,""):void 0;if(!("string"!=typeof e||Wt.test(e)||!rt.htmlSerialize&&qt.test(e)||!rt.leadingWhitespace&&Mt.test(e)||Vt[(Ft.exec(e)||["",""])[1].toLowerCase()])){e=e.replace(zt,"<$1></$2>");try{for(;r>n;n++)t=this[n]||{},1===t.nodeType&&(ot.cleanData(g(t,!1)),t.innerHTML=e);t=0}catch(i){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=arguments[0];return this.domManip(arguments,function(t){e=this.parentNode,ot.cleanData(g(this)),e&&e.replaceChild(t,this)}),e&&(e.length||e.nodeType)?this:this.remove()},detach:function(e){return this.remove(e,!0)},domManip:function(e,t){e=Y.apply([],e);var n,r,i,o,a,s,l=0,c=this.length,u=this,d=c-1,f=e[0],p=ot.isFunction(f);if(p||c>1&&"string"==typeof f&&!rt.checkClone&&Ut.test(f))return this.each(function(n){var r=u.eq(n);p&&(e[0]=f.call(this,n,r.html())),r.domManip(e,t)});if(c&&(s=ot.buildFragment(e,this[0].ownerDocument,!1,this),n=s.firstChild,1===s.childNodes.length&&(s=n),n)){for(o=ot.map(g(s,"script"),b),i=o.length;c>l;l++)r=s,l!==d&&(r=ot.clone(r,!0,!0),i&&ot.merge(o,g(r,"script"))),t.call(this[l],r,l);if(i)for(a=o[o.length-1].ownerDocument,ot.map(o,x),l=0;i>l;l++)r=o[l],Xt.test(r.type||"")&&!ot._data(r,"globalEval")&&ot.contains(a,r)&&(r.src?ot._evalUrl&&ot._evalUrl(r.src):ot.globalEval((r.text||r.textContent||r.innerHTML||"").replace(Gt,"")));s=n=null}return this}}),ot.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){ot.fn[e]=function(e){for(var n,r=0,i=[],o=ot(e),a=o.length-1;a>=r;r++)n=r===a?this:this.clone(!0),ot(o[r])[t](n),K.apply(i,n.get());return this.pushStack(i)}});var Kt,Jt={};!function(){var e;rt.shrinkWrapBlocks=function(){if(null!=e)return e;e=!1;var t,n,r;return n=mt.getElementsByTagName("body")[0],n&&n.style?(t=mt.createElement("div"),r=mt.createElement("div"),r.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(r).appendChild(t),typeof t.style.zoom!==kt&&(t.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",t.appendChild(mt.createElement("div")).style.width="5px",e=3!==t.offsetWidth),n.removeChild(r),e):void 0}}();var en=/^margin/,tn=new RegExp("^("+Et+")(?!px)[a-z%]+$","i"),nn,rn,on=/^(top|right|bottom|left)$/;e.getComputedStyle?(nn=function(e){return e.ownerDocument.defaultView.getComputedStyle(e,null)},rn=function(e,t,n){var r,i,o,a,s=e.style;return n=n||nn(e),a=n?n.getPropertyValue(t)||n[t]:void 0,n&&(""!==a||ot.contains(e.ownerDocument,e)||(a=ot.style(e,t)),tn.test(a)&&en.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0===a?a:a+""}):mt.documentElement.currentStyle&&(nn=function(e){return e.currentStyle},rn=function(e,t,n){var r,i,o,a,s=e.style;return n=n||nn(e),a=n?n[t]:void 0,null==a&&s&&s[t]&&(a=s[t]),tn.test(a)&&!on.test(t)&&(r=s.left,i=e.runtimeStyle,o=i&&i.left,o&&(i.left=e.currentStyle.left),s.left="fontSize"===t?"1em":a,a=s.pixelLeft+"px",s.left=r,o&&(i.left=o)),void 0===a?a:a+""||"auto"}),!function(){function t(){var t,n,r,i;n=mt.getElementsByTagName("body")[0],n&&n.style&&(t=mt.createElement("div"),r=mt.createElement("div"),r.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(r).appendChild(t),t.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",o=a=!1,l=!0,e.getComputedStyle&&(o="1%"!==(e.getComputedStyle(t,null)||{}).top,a="4px"===(e.getComputedStyle(t,null)||{width:"4px"}).width,i=t.appendChild(mt.createElement("div")),i.style.cssText=t.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",i.style.marginRight=i.style.width="0",t.style.width="1px",l=!parseFloat((e.getComputedStyle(i,null)||{}).marginRight)),t.innerHTML="<table><tr><td></td><td>t</td></tr></table>",i=t.getElementsByTagName("td"),i[0].style.cssText="margin:0;border:0;padding:0;display:none",s=0===i[0].offsetHeight,s&&(i[0].style.display="",i[1].style.display="none",s=0===i[0].offsetHeight),n.removeChild(r))}var n,r,i,o,a,s,l;n=mt.createElement("div"),n.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",i=n.getElementsByTagName("a")[0],(r=i&&i.style)&&(r.cssText="float:left;opacity:.5",rt.opacity="0.5"===r.opacity,rt.cssFloat=!!r.cssFloat,n.style.backgroundClip="content-box",n.cloneNode(!0).style.backgroundClip="",rt.clearCloneStyle="content-box"===n.style.backgroundClip,rt.boxSizing=""===r.boxSizing||""===r.MozBoxSizing||""===r.WebkitBoxSizing,ot.extend(rt,{reliableHiddenOffsets:function(){return null==s&&t(),s},boxSizingReliable:function(){return null==a&&t(),a},pixelPosition:function(){return null==o&&t(),o},reliableMarginRight:function(){return null==l&&t(),l}}))}(),ot.swap=function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i};var an=/alpha\([^)]*\)/i,sn=/opacity\s*=\s*([^)]*)/,ln=/^(none|table(?!-c[ea]).+)/,cn=new RegExp("^("+Et+")(.*)$","i"),un=new RegExp("^([+-])=("+Et+")","i"),dn={position:"absolute",visibility:"hidden",display:"block"},fn={letterSpacing:"0",fontWeight:"400"},pn=["Webkit","O","Moz","ms"];ot.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=rn(e,"opacity");return""===n?"1":n}}}},cssNumber:{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":rt.cssFloat?"cssFloat":"styleFloat"},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=ot.camelCase(t),l=e.style;if(t=ot.cssProps[s]||(ot.cssProps[s]=N(l,s)),a=ot.cssHooks[t]||ot.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];if(o=typeof n,"string"===o&&(i=un.exec(n))&&(n=(i[1]+1)*i[2]+parseFloat(ot.css(e,t)),o="number"),null!=n&&n===n&&("number"!==o||ot.cssNumber[s]||(n+="px"),rt.clearCloneStyle||""!==n||0!==t.indexOf("background")||(l[t]="inherit"),!(a&&"set"in a&&void 0===(n=a.set(e,n,r)))))try{l[t]=n}catch(c){}}},css:function(e,t,n,r){var i,o,a,s=ot.camelCase(t);return t=ot.cssProps[s]||(ot.cssProps[s]=N(e.style,s)),a=ot.cssHooks[t]||ot.cssHooks[s],a&&"get"in a&&(o=a.get(e,!0,n)),void 0===o&&(o=rn(e,t,r)),"normal"===o&&t in fn&&(o=fn[t]),""===n||n?(i=parseFloat(o),n===!0||ot.isNumeric(i)?i||0:o):o}}),ot.each(["height","width"],function(e,t){ot.cssHooks[t]={get:function(e,n,r){return n?ln.test(ot.css(e,"display"))&&0===e.offsetWidth?ot.swap(e,dn,function(){return j(e,t,r)}):j(e,t,r):void 0},set:function(e,n,r){var i=r&&nn(e);return A(e,n,r?D(e,t,r,rt.boxSizing&&"border-box"===ot.css(e,"boxSizing",!1,i),i):0)}}}),rt.opacity||(ot.cssHooks.opacity={get:function(e,t){return sn.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,r=e.currentStyle,i=ot.isNumeric(t)?"alpha(opacity="+100*t+")":"",o=r&&r.filter||n.filter||"";n.zoom=1,(t>=1||""===t)&&""===ot.trim(o.replace(an,""))&&n.removeAttribute&&(n.removeAttribute("filter"),""===t||r&&!r.filter)||(n.filter=an.test(o)?o.replace(an,i):o+" "+i)}}),ot.cssHooks.marginRight=E(rt.reliableMarginRight,function(e,t){return t?ot.swap(e,{display:"inline-block"},rn,[e,"marginRight"]):void 0}),ot.each({margin:"",padding:"",border:"Width"},function(e,t){ot.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];4>r;r++)i[e+Nt[r]+t]=o[r]||o[r-2]||o[0];return i}},en.test(e)||(ot.cssHooks[e+t].set=A)}),ot.fn.extend({css:function(e,t){return At(this,function(e,t,n){var r,i,o={},a=0;if(ot.isArray(t)){for(r=nn(e),i=t.length;i>a;a++)o[t[a]]=ot.css(e,t[a],!1,r);return o}return void 0!==n?ot.style(e,t,n):ot.css(e,t)},e,t,arguments.length>1)},show:function(){return L(this,!0)},hide:function(){return L(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){Lt(this)?ot(this).show():ot(this).hide()})}}),ot.Tween=R,R.prototype={constructor:R,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||"swing",this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(ot.cssNumber[n]?"":"px")},cur:function(){var e=R.propHooks[this.prop];return e&&e.get?e.get(this):R.propHooks._default.get(this)},run:function(e){var t,n=R.propHooks[this.prop];return this.pos=t=this.options.duration?ot.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):R.propHooks._default.set(this),this}},R.prototype.init.prototype=R.prototype,R.propHooks={_default:{get:function(e){var t;return null==e.elem[e.prop]||e.elem.style&&null!=e.elem.style[e.prop]?(t=ot.css(e.elem,e.prop,""),t&&"auto"!==t?t:0):e.elem[e.prop]},set:function(e){ot.fx.step[e.prop]?ot.fx.step[e.prop](e):e.elem.style&&(null!=e.elem.style[ot.cssProps[e.prop]]||ot.cssHooks[e.prop])?ot.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},R.propHooks.scrollTop=R.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},ot.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},ot.fx=R.prototype.init,ot.fx.step={};var hn,mn,gn=/^(?:toggle|show|hide)$/,vn=new RegExp("^(?:([+-])=|)("+Et+")([a-z%]*)$","i"),yn=/queueHooks$/,bn=[O],xn={"*":[function(e,t){var n=this.createTween(e,t),r=n.cur(),i=vn.exec(t),o=i&&i[3]||(ot.cssNumber[e]?"":"px"),a=(ot.cssNumber[e]||"px"!==o&&+r)&&vn.exec(ot.css(n.elem,e)),s=1,l=20;if(a&&a[3]!==o){o=o||a[3],i=i||[],a=+r||1;do s=s||".5",a/=s,ot.style(n.elem,e,a+o);while(s!==(s=n.cur()/r)&&1!==s&&--l)}return i&&(a=n.start=+a||+r||0,n.unit=o,n.end=i[1]?a+(i[1]+1)*i[2]:+i[2]),n}]};ot.Animation=ot.extend(M,{tweener:function(e,t){ot.isFunction(e)?(t=e,e=["*"]):e=e.split(" ");for(var n,r=0,i=e.length;i>r;r++)n=e[r],xn[n]=xn[n]||[],xn[n].unshift(t)},prefilter:function(e,t){t?bn.unshift(e):bn.push(e)}}),ot.speed=function(e,t,n){var r=e&&"object"==typeof e?ot.extend({},e):{complete:n||!n&&t||ot.isFunction(e)&&e,duration:e,easing:n&&t||t&&!ot.isFunction(t)&&t};return r.duration=ot.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in ot.fx.speeds?ot.fx.speeds[r.duration]:ot.fx.speeds._default,(null==r.queue||r.queue===!0)&&(r.queue="fx"),r.old=r.complete,r.complete=function(){ot.isFunction(r.old)&&r.old.call(this),r.queue&&ot.dequeue(this,r.queue)},r},ot.fn.extend({fadeTo:function(e,t,n,r){return this.filter(Lt).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=ot.isEmptyObject(e),o=ot.speed(t,n,r),a=function(){var t=M(this,ot.extend({},e),o);(i||ot._data(this,"finish"))&&t.stop(!0)};return a.finish=a,i||o.queue===!1?this.each(a):this.queue(o.queue,a)},stop:function(e,t,n){var r=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=void 0),t&&e!==!1&&this.queue(e||"fx",[]),this.each(function(){var t=!0,i=null!=e&&e+"queueHooks",o=ot.timers,a=ot._data(this);if(i)a[i]&&a[i].stop&&r(a[i]);else for(i in a)a[i]&&a[i].stop&&yn.test(i)&&r(a[i]);for(i=o.length;i--;)o[i].elem!==this||null!=e&&o[i].queue!==e||(o[i].anim.stop(n),t=!1,o.splice(i,1));(t||!n)&&ot.dequeue(this,e)})},finish:function(e){return e!==!1&&(e=e||"fx"),this.each(function(){var t,n=ot._data(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=ot.timers,a=r?r.length:0;for(n.finish=!0,ot.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;a>t;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}}),ot.each(["toggle","show","hide"],function(e,t){var n=ot.fn[t];ot.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(_(t,!0),e,r,i)}}),ot.each({slideDown:_("show"),slideUp:_("hide"),slideToggle:_("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){ot.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),ot.timers=[],ot.fx.tick=function(){var e,t=ot.timers,n=0;for(hn=ot.now();n<t.length;n++)e=t[n],e()||t[n]!==e||t.splice(n--,1);t.length||ot.fx.stop(),hn=void 0},ot.fx.timer=function(e){ot.timers.push(e),e()?ot.fx.start():ot.timers.pop()},ot.fx.interval=13,ot.fx.start=function(){mn||(mn=setInterval(ot.fx.tick,ot.fx.interval))},ot.fx.stop=function(){clearInterval(mn),mn=null},ot.fx.speeds={slow:600,fast:200,_default:400},ot.fn.delay=function(e,t){return e=ot.fx?ot.fx.speeds[e]||e:e,t=t||"fx",this.queue(t,function(t,n){var r=setTimeout(t,e);n.stop=function(){clearTimeout(r)}})},function(){var e,t,n,r,i;t=mt.createElement("div"),t.setAttribute("className","t"),t.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",r=t.getElementsByTagName("a")[0],n=mt.createElement("select"),i=n.appendChild(mt.createElement("option")),e=t.getElementsByTagName("input")[0],r.style.cssText="top:1px",rt.getSetAttribute="t"!==t.className,rt.style=/top/.test(r.getAttribute("style")),rt.hrefNormalized="/a"===r.getAttribute("href"),rt.checkOn=!!e.value,rt.optSelected=i.selected,rt.enctype=!!mt.createElement("form").enctype,n.disabled=!0,rt.optDisabled=!i.disabled,e=mt.createElement("input"),e.setAttribute("value",""),rt.input=""===e.getAttribute("value"),e.value="t",e.setAttribute("type","radio"),rt.radioValue="t"===e.value}();var wn=/\r/g;ot.fn.extend({val:function(e){var t,n,r,i=this[0];return arguments.length?(r=ot.isFunction(e),this.each(function(n){var i;1===this.nodeType&&(i=r?e.call(this,n,ot(this).val()):e,null==i?i="":"number"==typeof i?i+="":ot.isArray(i)&&(i=ot.map(i,function(e){return null==e?"":e+""})),t=ot.valHooks[this.type]||ot.valHooks[this.nodeName.toLowerCase()],t&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))})):i?(t=ot.valHooks[i.type]||ot.valHooks[i.nodeName.toLowerCase()],t&&"get"in t&&void 0!==(n=t.get(i,"value"))?n:(n=i.value,"string"==typeof n?n.replace(wn,""):null==n?"":n)):void 0}}),ot.extend({valHooks:{option:{get:function(e){var t=ot.find.attr(e,"value");return null!=t?t:ot.trim(ot.text(e))}},select:{get:function(e){for(var t,n,r=e.options,i=e.selectedIndex,o="select-one"===e.type||0>i,a=o?null:[],s=o?i+1:r.length,l=0>i?s:o?i:0;s>l;l++)if(n=r[l],!(!n.selected&&l!==i||(rt.optDisabled?n.disabled:null!==n.getAttribute("disabled"))||n.parentNode.disabled&&ot.nodeName(n.parentNode,"optgroup"))){if(t=ot(n).val(),o)return t;a.push(t)}return a},set:function(e,t){for(var n,r,i=e.options,o=ot.makeArray(t),a=i.length;a--;)if(r=i[a],ot.inArray(ot.valHooks.option.get(r),o)>=0)try{r.selected=n=!0}catch(s){r.scrollHeight}else r.selected=!1;return n||(e.selectedIndex=-1),i}}}}),ot.each(["radio","checkbox"],function(){ot.valHooks[this]={set:function(e,t){return ot.isArray(t)?e.checked=ot.inArray(ot(e).val(),t)>=0:void 0}},rt.checkOn||(ot.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var Cn,kn,$n=ot.expr.attrHandle,Sn=/^(?:checked|selected)$/i,Tn=rt.getSetAttribute,En=rt.input;ot.fn.extend({attr:function(e,t){return At(this,ot.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){ot.removeAttr(this,e)})}}),ot.extend({attr:function(e,t,n){var r,i,o=e.nodeType;return e&&3!==o&&8!==o&&2!==o?typeof e.getAttribute===kt?ot.prop(e,t,n):(1===o&&ot.isXMLDoc(e)||(t=t.toLowerCase(),r=ot.attrHooks[t]||(ot.expr.match.bool.test(t)?kn:Cn)),void 0===n?r&&"get"in r&&null!==(i=r.get(e,t))?i:(i=ot.find.attr(e,t),null==i?void 0:i):null!==n?r&&"set"in r&&void 0!==(i=r.set(e,n,t))?i:(e.setAttribute(t,n+""),n):void ot.removeAttr(e,t)):void 0},removeAttr:function(e,t){var n,r,i=0,o=t&&t.match(xt);if(o&&1===e.nodeType)for(;n=o[i++];)r=ot.propFix[n]||n,ot.expr.match.bool.test(n)?En&&Tn||!Sn.test(n)?e[r]=!1:e[ot.camelCase("default-"+n)]=e[r]=!1:ot.attr(e,n,""),e.removeAttribute(Tn?n:r)},attrHooks:{type:{set:function(e,t){if(!rt.radioValue&&"radio"===t&&ot.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}}}),kn={set:function(e,t,n){return t===!1?ot.removeAttr(e,n):En&&Tn||!Sn.test(n)?e.setAttribute(!Tn&&ot.propFix[n]||n,n):e[ot.camelCase("default-"+n)]=e[n]=!0,n}},ot.each(ot.expr.match.bool.source.match(/\w+/g),function(e,t){var n=$n[t]||ot.find.attr;$n[t]=En&&Tn||!Sn.test(t)?function(e,t,r){var i,o;return r||(o=$n[t],$n[t]=i,i=null!=n(e,t,r)?t.toLowerCase():null,$n[t]=o),i}:function(e,t,n){return n?void 0:e[ot.camelCase("default-"+t)]?t.toLowerCase():null}}),En&&Tn||(ot.attrHooks.value={set:function(e,t,n){return ot.nodeName(e,"input")?void(e.defaultValue=t):Cn&&Cn.set(e,t,n)}}),Tn||(Cn={set:function(e,t,n){var r=e.getAttributeNode(n);return r||e.setAttributeNode(r=e.ownerDocument.createAttribute(n)),r.value=t+="","value"===n||t===e.getAttribute(n)?t:void 0}},$n.id=$n.name=$n.coords=function(e,t,n){var r;return n?void 0:(r=e.getAttributeNode(t))&&""!==r.value?r.value:null},ot.valHooks.button={get:function(e,t){var n=e.getAttributeNode(t);return n&&n.specified?n.value:void 0},set:Cn.set},ot.attrHooks.contenteditable={set:function(e,t,n){Cn.set(e,""===t?!1:t,n)}},ot.each(["width","height"],function(e,t){ot.attrHooks[t]={set:function(e,n){return""===n?(e.setAttribute(t,"auto"),n):void 0}}})),rt.style||(ot.attrHooks.style={get:function(e){return e.style.cssText||void 0},set:function(e,t){return e.style.cssText=t+""}});var Nn=/^(?:input|select|textarea|button|object)$/i,Ln=/^(?:a|area)$/i;ot.fn.extend({prop:function(e,t){return At(this,ot.prop,e,t,arguments.length>1)},removeProp:function(e){return e=ot.propFix[e]||e,this.each(function(){try{this[e]=void 0,delete this[e]}catch(t){}})}}),ot.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(e,t,n){var r,i,o,a=e.nodeType;return e&&3!==a&&8!==a&&2!==a?(o=1!==a||!ot.isXMLDoc(e),o&&(t=ot.propFix[t]||t,i=ot.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]):void 0},propHooks:{tabIndex:{get:function(e){var t=ot.find.attr(e,"tabindex");return t?parseInt(t,10):Nn.test(e.nodeName)||Ln.test(e.nodeName)&&e.href?0:-1}}}}),rt.hrefNormalized||ot.each(["href","src"],function(e,t){ot.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}}),rt.optSelected||(ot.propHooks.selected={get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}}),ot.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){ot.propFix[this.toLowerCase()]=this}),rt.enctype||(ot.propFix.enctype="encoding");var An=/[\t\r\n\f]/g;ot.fn.extend({addClass:function(e){var t,n,r,i,o,a,s=0,l=this.length,c="string"==typeof e&&e;if(ot.isFunction(e))return this.each(function(t){ot(this).addClass(e.call(this,t,this.className))});if(c)for(t=(e||"").match(xt)||[];l>s;s++)if(n=this[s],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(An," "):" ")){for(o=0;i=t[o++];)r.indexOf(" "+i+" ")<0&&(r+=i+" ");a=ot.trim(r),n.className!==a&&(n.className=a)}return this},removeClass:function(e){var t,n,r,i,o,a,s=0,l=this.length,c=0===arguments.length||"string"==typeof e&&e;if(ot.isFunction(e))return this.each(function(t){ot(this).removeClass(e.call(this,t,this.className))});if(c)for(t=(e||"").match(xt)||[];l>s;s++)if(n=this[s],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(An," "):"")){for(o=0;i=t[o++];)for(;r.indexOf(" "+i+" ")>=0;)r=r.replace(" "+i+" "," ");a=e?ot.trim(r):"",n.className!==a&&(n.className=a)}return this},toggleClass:function(e,t){var n=typeof e;return"boolean"==typeof t&&"string"===n?t?this.addClass(e):this.removeClass(e):this.each(ot.isFunction(e)?function(n){ot(this).toggleClass(e.call(this,n,this.className,t),t)}:function(){if("string"===n)for(var t,r=0,i=ot(this),o=e.match(xt)||[];t=o[r++];)i.hasClass(t)?i.removeClass(t):i.addClass(t);else(n===kt||"boolean"===n)&&(this.className&&ot._data(this,"__className__",this.className),this.className=this.className||e===!1?"":ot._data(this,"__className__")||"")})},hasClass:function(e){for(var t=" "+e+" ",n=0,r=this.length;r>n;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(An," ").indexOf(t)>=0)return!0;return!1}}),ot.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(e,t){ot.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),ot.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}});var Dn=ot.now(),jn=/\?/,Rn=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;ot.parseJSON=function(t){if(e.JSON&&e.JSON.parse)return e.JSON.parse(t+"");var n,r=null,i=ot.trim(t+"");return i&&!ot.trim(i.replace(Rn,function(e,t,i,o){return n&&t&&(r=0),0===r?e:(n=i||t,r+=!o-!i,"")}))?Function("return "+i)():ot.error("Invalid JSON: "+t)},ot.parseXML=function(t){var n,r;if(!t||"string"!=typeof t)return null;try{e.DOMParser?(r=new DOMParser,n=r.parseFromString(t,"text/xml")):(n=new ActiveXObject("Microsoft.XMLDOM"),n.async="false",n.loadXML(t))}catch(i){n=void 0}return n&&n.documentElement&&!n.getElementsByTagName("parsererror").length||ot.error("Invalid XML: "+t),n};var Pn,_n,Hn=/#.*$/,On=/([?&])_=[^&]*/,qn=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Mn=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,zn=/^(?:GET|HEAD)$/,Fn=/^\/\//,Bn=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,In={},Wn={},Un="*/".concat("*");try{_n=location.href}catch(Xn){_n=mt.createElement("a"),_n.href="",_n=_n.href}Pn=Bn.exec(_n.toLowerCase())||[],ot.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:_n,type:"GET",isLocal:Mn.test(Pn[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Un,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":ot.parseJSON,"text xml":ot.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?B(B(e,ot.ajaxSettings),t):B(ot.ajaxSettings,e)},ajaxPrefilter:z(In),ajaxTransport:z(Wn),ajax:function(e,t){function n(e,t,n,r){var i,u,v,y,x,C=t;2!==b&&(b=2,s&&clearTimeout(s),c=void 0,a=r||"",w.readyState=e>0?4:0,i=e>=200&&300>e||304===e,n&&(y=I(d,w,n)),y=W(d,y,w,i),i?(d.ifModified&&(x=w.getResponseHeader("Last-Modified"),x&&(ot.lastModified[o]=x),x=w.getResponseHeader("etag"),x&&(ot.etag[o]=x)),204===e||"HEAD"===d.type?C="nocontent":304===e?C="notmodified":(C=y.state,u=y.data,v=y.error,i=!v)):(v=C,(e||!C)&&(C="error",0>e&&(e=0))),w.status=e,w.statusText=(t||C)+"",i?h.resolveWith(f,[u,C,w]):h.rejectWith(f,[w,C,v]),w.statusCode(g),g=void 0,l&&p.trigger(i?"ajaxSuccess":"ajaxError",[w,d,i?u:v]),m.fireWith(f,[w,C]),l&&(p.trigger("ajaxComplete",[w,d]),--ot.active||ot.event.trigger("ajaxStop")))}"object"==typeof e&&(t=e,e=void 0),t=t||{};var r,i,o,a,s,l,c,u,d=ot.ajaxSetup({},t),f=d.context||d,p=d.context&&(f.nodeType||f.jquery)?ot(f):ot.event,h=ot.Deferred(),m=ot.Callbacks("once memory"),g=d.statusCode||{},v={},y={},b=0,x="canceled",w={readyState:0,getResponseHeader:function(e){var t;if(2===b){if(!u)for(u={};t=qn.exec(a);)u[t[1].toLowerCase()]=t[2];t=u[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===b?a:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return b||(e=y[n]=y[n]||e,v[e]=t),this},overrideMimeType:function(e){return b||(d.mimeType=e),this},statusCode:function(e){var t;if(e)if(2>b)for(t in e)g[t]=[g[t],e[t]];else w.always(e[w.status]);return this},abort:function(e){var t=e||x;return c&&c.abort(t),n(0,t),this}};if(h.promise(w).complete=m.add,w.success=w.done,w.error=w.fail,d.url=((e||d.url||_n)+"").replace(Hn,"").replace(Fn,Pn[1]+"//"),d.type=t.method||t.type||d.method||d.type,d.dataTypes=ot.trim(d.dataType||"*").toLowerCase().match(xt)||[""],null==d.crossDomain&&(r=Bn.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]===Pn[1]&&r[2]===Pn[2]&&(r[3]||("http:"===r[1]?"80":"443"))===(Pn[3]||("http:"===Pn[1]?"80":"443")))),d.data&&d.processData&&"string"!=typeof d.data&&(d.data=ot.param(d.data,d.traditional)),F(In,d,t,w),2===b)return w;l=d.global,l&&0===ot.active++&&ot.event.trigger("ajaxStart"),d.type=d.type.toUpperCase(),d.hasContent=!zn.test(d.type),o=d.url,d.hasContent||(d.data&&(o=d.url+=(jn.test(o)?"&":"?")+d.data,delete d.data),d.cache===!1&&(d.url=On.test(o)?o.replace(On,"$1_="+Dn++):o+(jn.test(o)?"&":"?")+"_="+Dn++)),d.ifModified&&(ot.lastModified[o]&&w.setRequestHeader("If-Modified-Since",ot.lastModified[o]),ot.etag[o]&&w.setRequestHeader("If-None-Match",ot.etag[o])),(d.data&&d.hasContent&&d.contentType!==!1||t.contentType)&&w.setRequestHeader("Content-Type",d.contentType),w.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+("*"!==d.dataTypes[0]?", "+Un+"; q=0.01":""):d.accepts["*"]); -for(i in d.headers)w.setRequestHeader(i,d.headers[i]);if(d.beforeSend&&(d.beforeSend.call(f,w,d)===!1||2===b))return w.abort();x="abort";for(i in{success:1,error:1,complete:1})w[i](d[i]);if(c=F(Wn,d,t,w)){w.readyState=1,l&&p.trigger("ajaxSend",[w,d]),d.async&&d.timeout>0&&(s=setTimeout(function(){w.abort("timeout")},d.timeout));try{b=1,c.send(v,n)}catch(C){if(!(2>b))throw C;n(-1,C)}}else n(-1,"No Transport");return w},getJSON:function(e,t,n){return ot.get(e,t,n,"json")},getScript:function(e,t){return ot.get(e,void 0,t,"script")}}),ot.each(["get","post"],function(e,t){ot[t]=function(e,n,r,i){return ot.isFunction(n)&&(i=i||r,r=n,n=void 0),ot.ajax({url:e,type:t,dataType:i,data:n,success:r})}}),ot.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){ot.fn[t]=function(e){return this.on(t,e)}}),ot._evalUrl=function(e){return ot.ajax({url:e,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},ot.fn.extend({wrapAll:function(e){if(ot.isFunction(e))return this.each(function(t){ot(this).wrapAll(e.call(this,t))});if(this[0]){var t=ot(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstChild&&1===e.firstChild.nodeType;)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return this.each(ot.isFunction(e)?function(t){ot(this).wrapInner(e.call(this,t))}:function(){var t=ot(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=ot.isFunction(e);return this.each(function(n){ot(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){ot.nodeName(this,"body")||ot(this).replaceWith(this.childNodes)}).end()}}),ot.expr.filters.hidden=function(e){return e.offsetWidth<=0&&e.offsetHeight<=0||!rt.reliableHiddenOffsets()&&"none"===(e.style&&e.style.display||ot.css(e,"display"))},ot.expr.filters.visible=function(e){return!ot.expr.filters.hidden(e)};var Zn=/%20/g,Gn=/\[\]$/,Vn=/\r?\n/g,Qn=/^(?:submit|button|image|reset|file)$/i,Yn=/^(?:input|select|textarea|keygen)/i;ot.param=function(e,t){var n,r=[],i=function(e,t){t=ot.isFunction(t)?t():null==t?"":t,r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(void 0===t&&(t=ot.ajaxSettings&&ot.ajaxSettings.traditional),ot.isArray(e)||e.jquery&&!ot.isPlainObject(e))ot.each(e,function(){i(this.name,this.value)});else for(n in e)U(n,e[n],t,i);return r.join("&").replace(Zn,"+")},ot.fn.extend({serialize:function(){return ot.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=ot.prop(this,"elements");return e?ot.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!ot(this).is(":disabled")&&Yn.test(this.nodeName)&&!Qn.test(e)&&(this.checked||!Dt.test(e))}).map(function(e,t){var n=ot(this).val();return null==n?null:ot.isArray(n)?ot.map(n,function(e){return{name:t.name,value:e.replace(Vn,"\r\n")}}):{name:t.name,value:n.replace(Vn,"\r\n")}}).get()}}),ot.ajaxSettings.xhr=void 0!==e.ActiveXObject?function(){return!this.isLocal&&/^(get|post|head|put|delete|options)$/i.test(this.type)&&X()||Z()}:X;var Kn=0,Jn={},er=ot.ajaxSettings.xhr();e.ActiveXObject&&ot(e).on("unload",function(){for(var e in Jn)Jn[e](void 0,!0)}),rt.cors=!!er&&"withCredentials"in er,er=rt.ajax=!!er,er&&ot.ajaxTransport(function(e){if(!e.crossDomain||rt.cors){var t;return{send:function(n,r){var i,o=e.xhr(),a=++Kn;if(o.open(e.type,e.url,e.async,e.username,e.password),e.xhrFields)for(i in e.xhrFields)o[i]=e.xhrFields[i];e.mimeType&&o.overrideMimeType&&o.overrideMimeType(e.mimeType),e.crossDomain||n["X-Requested-With"]||(n["X-Requested-With"]="XMLHttpRequest");for(i in n)void 0!==n[i]&&o.setRequestHeader(i,n[i]+"");o.send(e.hasContent&&e.data||null),t=function(n,i){var s,l,c;if(t&&(i||4===o.readyState))if(delete Jn[a],t=void 0,o.onreadystatechange=ot.noop,i)4!==o.readyState&&o.abort();else{c={},s=o.status,"string"==typeof o.responseText&&(c.text=o.responseText);try{l=o.statusText}catch(u){l=""}s||!e.isLocal||e.crossDomain?1223===s&&(s=204):s=c.text?200:404}c&&r(s,l,c,o.getAllResponseHeaders())},e.async?4===o.readyState?setTimeout(t):o.onreadystatechange=Jn[a]=t:t()},abort:function(){t&&t(void 0,!0)}}}}),ot.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(e){return ot.globalEval(e),e}}}),ot.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),ot.ajaxTransport("script",function(e){if(e.crossDomain){var t,n=mt.head||ot("head")[0]||mt.documentElement;return{send:function(r,i){t=mt.createElement("script"),t.async=!0,e.scriptCharset&&(t.charset=e.scriptCharset),t.src=e.url,t.onload=t.onreadystatechange=function(e,n){(n||!t.readyState||/loaded|complete/.test(t.readyState))&&(t.onload=t.onreadystatechange=null,t.parentNode&&t.parentNode.removeChild(t),t=null,n||i(200,"success"))},n.insertBefore(t,n.firstChild)},abort:function(){t&&t.onload(void 0,!0)}}}});var tr=[],nr=/(=)\?(?=&|$)|\?\?/;ot.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=tr.pop()||ot.expando+"_"+Dn++;return this[e]=!0,e}}),ot.ajaxPrefilter("json jsonp",function(t,n,r){var i,o,a,s=t.jsonp!==!1&&(nr.test(t.url)?"url":"string"==typeof t.data&&!(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&nr.test(t.data)&&"data");return s||"jsonp"===t.dataTypes[0]?(i=t.jsonpCallback=ot.isFunction(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(nr,"$1"+i):t.jsonp!==!1&&(t.url+=(jn.test(t.url)?"&":"?")+t.jsonp+"="+i),t.converters["script json"]=function(){return a||ot.error(i+" was not called"),a[0]},t.dataTypes[0]="json",o=e[i],e[i]=function(){a=arguments},r.always(function(){e[i]=o,t[i]&&(t.jsonpCallback=n.jsonpCallback,tr.push(i)),a&&ot.isFunction(o)&&o(a[0]),a=o=void 0}),"script"):void 0}),ot.parseHTML=function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||mt;var r=ft.exec(e),i=!n&&[];return r?[t.createElement(r[1])]:(r=ot.buildFragment([e],t,i),i&&i.length&&ot(i).remove(),ot.merge([],r.childNodes))};var rr=ot.fn.load;ot.fn.load=function(e,t,n){if("string"!=typeof e&&rr)return rr.apply(this,arguments);var r,i,o,a=this,s=e.indexOf(" ");return s>=0&&(r=ot.trim(e.slice(s,e.length)),e=e.slice(0,s)),ot.isFunction(t)?(n=t,t=void 0):t&&"object"==typeof t&&(o="POST"),a.length>0&&ot.ajax({url:e,type:o,dataType:"html",data:t}).done(function(e){i=arguments,a.html(r?ot("<div>").append(ot.parseHTML(e)).find(r):e)}).complete(n&&function(e,t){a.each(n,i||[e.responseText,t,e])}),this},ot.expr.filters.animated=function(e){return ot.grep(ot.timers,function(t){return e===t.elem}).length};var ir=e.document.documentElement;ot.offset={setOffset:function(e,t,n){var r,i,o,a,s,l,c,u=ot.css(e,"position"),d=ot(e),f={};"static"===u&&(e.style.position="relative"),s=d.offset(),o=ot.css(e,"top"),l=ot.css(e,"left"),c=("absolute"===u||"fixed"===u)&&ot.inArray("auto",[o,l])>-1,c?(r=d.position(),a=r.top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(l)||0),ot.isFunction(t)&&(t=t.call(e,n,s)),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):d.css(f)}},ot.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){ot.offset.setOffset(this,e,t)});var t,n,r={top:0,left:0},i=this[0],o=i&&i.ownerDocument;return o?(t=o.documentElement,ot.contains(t,i)?(typeof i.getBoundingClientRect!==kt&&(r=i.getBoundingClientRect()),n=G(o),{top:r.top+(n.pageYOffset||t.scrollTop)-(t.clientTop||0),left:r.left+(n.pageXOffset||t.scrollLeft)-(t.clientLeft||0)}):r):void 0},position:function(){if(this[0]){var e,t,n={top:0,left:0},r=this[0];return"fixed"===ot.css(r,"position")?t=r.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),ot.nodeName(e[0],"html")||(n=e.offset()),n.top+=ot.css(e[0],"borderTopWidth",!0),n.left+=ot.css(e[0],"borderLeftWidth",!0)),{top:t.top-n.top-ot.css(r,"marginTop",!0),left:t.left-n.left-ot.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent||ir;e&&!ot.nodeName(e,"html")&&"static"===ot.css(e,"position");)e=e.offsetParent;return e||ir})}}),ot.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,t){var n=/Y/.test(t);ot.fn[e]=function(r){return At(this,function(e,r,i){var o=G(e);return void 0===i?o?t in o?o[t]:o.document.documentElement[r]:e[r]:void(o?o.scrollTo(n?ot(o).scrollLeft():i,n?i:ot(o).scrollTop()):e[r]=i)},e,r,arguments.length,null)}}),ot.each(["top","left"],function(e,t){ot.cssHooks[t]=E(rt.pixelPosition,function(e,n){return n?(n=rn(e,t),tn.test(n)?ot(e).position()[t]+"px":n):void 0})}),ot.each({Height:"height",Width:"width"},function(e,t){ot.each({padding:"inner"+e,content:t,"":"outer"+e},function(n,r){ot.fn[r]=function(r,i){var o=arguments.length&&(n||"boolean"!=typeof r),a=n||(r===!0||i===!0?"margin":"border");return At(this,function(t,n,r){var i;return ot.isWindow(t)?t.document.documentElement["client"+e]:9===t.nodeType?(i=t.documentElement,Math.max(t.body["scroll"+e],i["scroll"+e],t.body["offset"+e],i["offset"+e],i["client"+e])):void 0===r?ot.css(t,n,a):ot.style(t,n,r,a)},t,o?r:void 0,o,null)}})}),ot.fn.size=function(){return this.length},ot.fn.andSelf=ot.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return ot});var or=e.jQuery,ar=e.$;return ot.noConflict=function(t){return e.$===ot&&(e.$=ar),t&&e.jQuery===ot&&(e.jQuery=or),ot},typeof t===kt&&(e.jQuery=e.$=ot),ot}),!function(){var e=null;window.PR_SHOULD_USE_CONTINUATION=!0,function(){function t(e){function t(e){var t=e.charCodeAt(0);if(92!==t)return t;var n=e.charAt(1);return(t=d[n])?t:n>="0"&&"7">=n?parseInt(e.substring(1),8):"u"===n||"x"===n?parseInt(e.substring(2),16):e.charCodeAt(1)}function n(e){return 32>e?(16>e?"\\x0":"\\x")+e.toString(16):(e=String.fromCharCode(e),"\\"===e||"-"===e||"]"===e||"^"===e?"\\"+e:e)}function r(e){var r=e.substring(1,e.length-1).match(/\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\[0-3][0-7]{0,2}|\\[0-7]{1,2}|\\[\S\s]|[^\\]/g),e=[],i="^"===r[0],o=["["];i&&o.push("^");for(var i=i?1:0,a=r.length;a>i;++i){var s=r[i];if(/\\[bdsw]/i.test(s))o.push(s);else{var s=t(s),l;a>i+2&&"-"===r[i+1]?(l=t(r[i+2]),i+=2):l=s,e.push([s,l]),65>l||s>122||(65>l||s>90||e.push([32|Math.max(65,s),32|Math.min(l,90)]),97>l||s>122||e.push([-33&Math.max(97,s),-33&Math.min(l,122)]))}}for(e.sort(function(e,t){return e[0]-t[0]||t[1]-e[1]}),r=[],a=[],i=0;i<e.length;++i)s=e[i],s[0]<=a[1]+1?a[1]=Math.max(a[1],s[1]):r.push(a=s);for(i=0;i<r.length;++i)s=r[i],o.push(n(s[0])),s[1]>s[0]&&(s[1]+1>s[0]&&o.push("-"),o.push(n(s[1])));return o.push("]"),o.join("")}function i(e){for(var t=e.source.match(/\[(?:[^\\\]]|\\[\S\s])*]|\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\\d+|\\[^\dux]|\(\?[!:=]|[()^]|[^()[\\^]+/g),i=t.length,s=[],l=0,c=0;i>l;++l){var u=t[l];"("===u?++c:"\\"===u.charAt(0)&&(u=+u.substring(1))&&(c>=u?s[u]=-1:t[l]=n(u))}for(l=1;l<s.length;++l)-1===s[l]&&(s[l]=++o);for(c=l=0;i>l;++l)u=t[l],"("===u?(++c,s[c]||(t[l]="(?:")):"\\"===u.charAt(0)&&(u=+u.substring(1))&&c>=u&&(t[l]="\\"+s[u]);for(l=0;i>l;++l)"^"===t[l]&&"^"!==t[l+1]&&(t[l]="");if(e.ignoreCase&&a)for(l=0;i>l;++l)u=t[l],e=u.charAt(0),u.length>=2&&"["===e?t[l]=r(u):"\\"!==e&&(t[l]=u.replace(/[A-Za-z]/g,function(e){return e=e.charCodeAt(0),"["+String.fromCharCode(-33&e,32|e)+"]"}));return t.join("")}for(var o=0,a=!1,s=!1,l=0,c=e.length;c>l;++l){var u=e[l];if(u.ignoreCase)s=!0;else if(/[a-z]/i.test(u.source.replace(/\\u[\da-f]{4}|\\x[\da-f]{2}|\\[^UXux]/gi,""))){a=!0,s=!1;break}}for(var d={b:8,t:9,n:10,v:11,f:12,r:13},f=[],l=0,c=e.length;c>l;++l){if(u=e[l],u.global||u.multiline)throw Error(""+u);f.push("(?:"+i(u)+")")}return RegExp(f.join("|"),s?"gi":"g")}function n(e,t){function n(e){var l=e.nodeType;if(1==l){if(!r.test(e.className)){for(l=e.firstChild;l;l=l.nextSibling)n(l);l=e.nodeName.toLowerCase(),("br"===l||"li"===l)&&(i[s]="\n",a[s<<1]=o++,a[s++<<1|1]=e)}}else(3==l||4==l)&&(l=e.nodeValue,l.length&&(l=t?l.replace(/\r\n?/g,"\n"):l.replace(/[\t\n\r ]+/g," "),i[s]=l,a[s<<1]=o,o+=l.length,a[s++<<1|1]=e))}var r=/(?:^|\s)nocode(?:\s|$)/,i=[],o=0,a=[],s=0;return n(e),{a:i.join("").replace(/\n$/,""),d:a}}function r(e,t,n,r){t&&(e={a:t,e:e},n(e),r.push.apply(r,e.g))}function i(e){for(var t=void 0,n=e.firstChild;n;n=n.nextSibling)var r=n.nodeType,t=1===r?t?e:n:3===r&&w.test(n.nodeValue)?e:t;return t===e?void 0:t}function o(n,i){function o(e){for(var t=e.e,n=[t,"pln"],u=0,d=e.a.match(s)||[],f={},p=0,h=d.length;h>p;++p){var m=d[p],g=f[m],v=void 0,y;if("string"==typeof g)y=!1;else{var b=a[m.charAt(0)];if(b)v=m.match(b[1]),g=b[0];else{for(y=0;l>y;++y)if(b=i[y],v=m.match(b[1])){g=b[0];break}v||(g="pln")}!(y=g.length>=5&&"lang-"===g.substring(0,5))||v&&"string"==typeof v[1]||(y=!1,g="src"),y||(f[m]=g)}if(b=u,u+=m.length,y){y=v[1];var x=m.indexOf(y),w=x+y.length;v[2]&&(w=m.length-v[2].length,x=w-y.length),g=g.substring(5),r(t+b,m.substring(0,x),o,n),r(t+b+x,y,c(g,y),n),r(t+b+w,m.substring(w),o,n)}else n.push(t+b,g)}e.g=n}var a={},s;!function(){for(var r=n.concat(i),o=[],l={},c=0,u=r.length;u>c;++c){var d=r[c],f=d[3];if(f)for(var p=f.length;--p>=0;)a[f.charAt(p)]=d;d=d[1],f=""+d,l.hasOwnProperty(f)||(o.push(d),l[f]=e)}o.push(/[\S\s]/),s=t(o)}();var l=i.length;return o}function a(t){var n=[],r=[];n.push(t.tripleQuotedStrings?["str",/^(?:'''(?:[^'\\]|\\[\S\s]|''?(?=[^']))*(?:'''|$)|"""(?:[^"\\]|\\[\S\s]|""?(?=[^"]))*(?:"""|$)|'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$))/,e,"'\""]:t.multiLineStrings?["str",/^(?:'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$)|`(?:[^\\`]|\\[\S\s])*(?:`|$))/,e,"'\"`"]:["str",/^(?:'(?:[^\n\r'\\]|\\.)*(?:'|$)|"(?:[^\n\r"\\]|\\.)*(?:"|$))/,e,"\"'"]),t.verbatimStrings&&r.push(["str",/^@"(?:[^"]|"")*(?:"|$)/,e]);var i=t.hashComments;if(i&&(t.cStyleComments?(n.push(i>1?["com",/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,e,"#"]:["com",/^#(?:(?:define|e(?:l|nd)if|else|error|ifn?def|include|line|pragma|undef|warning)\b|[^\n\r]*)/,e,"#"]),r.push(["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h(?:h|pp|\+\+)?|[a-z]\w*)>/,e])):n.push(["com",/^#[^\n\r]*/,e,"#"])),t.cStyleComments&&(r.push(["com",/^\/\/[^\n\r]*/,e]),r.push(["com",/^\/\*[\S\s]*?(?:\*\/|$)/,e])),i=t.regexLiterals){var a=(i=i>1?"":"\n\r")?".":"[\\S\\s]";r.push(["lang-regex",RegExp("^(?:^^\\.?|[+-]|[!=]=?=?|\\#|%=?|&&?=?|\\(|\\*=?|[+\\-]=|->|\\/=?|::?|<<?=?|>>?>?=?|,|;|\\?|@|\\[|~|{|\\^\\^?=?|\\|\\|?=?|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*("+("/(?=[^/*"+i+"])(?:[^/\\x5B\\x5C"+i+"]|\\x5C"+a+"|\\x5B(?:[^\\x5C\\x5D"+i+"]|\\x5C"+a+")*(?:\\x5D|$))+/")+")")])}return(i=t.types)&&r.push(["typ",i]),i=(""+t.keywords).replace(/^ | $/g,""),i.length&&r.push(["kwd",RegExp("^(?:"+i.replace(/[\s,]+/g,"|")+")\\b"),e]),n.push(["pln",/^\s+/,e," \r\n "]),i="^.[^\\s\\w.$@'\"`/\\\\]*",t.regexLiterals&&(i+="(?!s*/)"),r.push(["lit",/^@[$_a-z][\w$@]*/i,e],["typ",/^(?:[@_]?[A-Z]+[a-z][\w$@]*|\w+_t\b)/,e],["pln",/^[$_a-z][\w$@]*/i,e],["lit",/^(?:0x[\da-f]+|(?:\d(?:_\d+)*\d*(?:\.\d*)?|\.\d\+)(?:e[+-]?\d+)?)[a-z]*/i,e,"0123456789"],["pln",/^\\[\S\s]?/,e],["pun",RegExp(i),e]),o(n,r)}function s(e,t,n){function r(e){var t=e.nodeType;if(1!=t||o.test(e.className)){if((3==t||4==t)&&n){var l=e.nodeValue,c=l.match(a);c&&(t=l.substring(0,c.index),e.nodeValue=t,(l=l.substring(c.index+c[0].length))&&e.parentNode.insertBefore(s.createTextNode(l),e.nextSibling),i(e),t||e.parentNode.removeChild(e))}}else if("br"===e.nodeName)i(e),e.parentNode&&e.parentNode.removeChild(e);else for(e=e.firstChild;e;e=e.nextSibling)r(e)}function i(e){function t(e,n){var r=n?e.cloneNode(!1):e,i=e.parentNode;if(i){var i=t(i,1),o=e.nextSibling;i.appendChild(r);for(var a=o;a;a=o)o=a.nextSibling,i.appendChild(a)}return r}for(;!e.nextSibling;)if(e=e.parentNode,!e)return;for(var e=t(e.nextSibling,0),n;(n=e.parentNode)&&1===n.nodeType;)e=n;c.push(e)}for(var o=/(?:^|\s)nocode(?:\s|$)/,a=/\r\n?|\n/,s=e.ownerDocument,l=s.createElement("li");e.firstChild;)l.appendChild(e.firstChild);for(var c=[l],u=0;u<c.length;++u)r(c[u]);t===(0|t)&&c[0].setAttribute("value",t);var d=s.createElement("ol");d.className="linenums";for(var t=Math.max(0,t-1|0)||0,u=0,f=c.length;f>u;++u)l=c[u],l.setAttribute("rel","L"+(u+t+1)),l.className="L"+(u+t+1),l.firstChild||l.appendChild(s.createTextNode(" ")),d.appendChild(l);e.appendChild(d)}function l(e,t){for(var n=t.length;--n>=0;){var r=t[n];k.hasOwnProperty(r)?d.console&&console.warn("cannot override language handler %s",r):k[r]=e}}function c(e,t){return e&&k.hasOwnProperty(e)||(e=/^\s*</.test(t)?"default-markup":"default-code"),k[e]}function u(e){var t=e.h;try{var r=n(e.c,e.i),i=r.a;e.a=i,e.d=r.d,e.e=0,c(t,i)(e);var o=/\bMSIE\s(\d+)/.exec(navigator.userAgent),o=o&&+o[1]<=8,t=/\n/g,a=e.a,s=a.length,r=0,l=e.d,u=l.length,i=0,f=e.g,p=f.length,h=0;f[p]=s;var m,g;for(g=m=0;p>g;)f[g]!==f[g+2]?(f[m++]=f[g++],f[m++]=f[g++]):g+=2;for(p=m,g=m=0;p>g;){for(var v=f[g],y=f[g+1],b=g+2;p>=b+2&&f[b+1]===y;)b+=2;f[m++]=v,f[m++]=y,g=b}f.length=m;var x=e.c,w;x&&(w=x.style.display,x.style.display="none");try{for(;u>i;){var C=l[i+2]||s,k=f[h+2]||s,b=Math.min(C,k),S=l[i+1],T;if(1!==S.nodeType&&(T=a.substring(r,b))){o&&(T=T.replace(t,"\r")),S.nodeValue=T;var E=S.ownerDocument,N=E.createElement("span");N.className=f[h+1];var L=S.parentNode;L.replaceChild(N,S),N.appendChild(S),C>r&&(l[i+1]=S=E.createTextNode(a.substring(b,C)),L.insertBefore(S,N.nextSibling))}r=b,r>=C&&(i+=2),r>=k&&(h+=2)}}finally{x&&(x.style.display=w)}}catch(A){d.console&&console.log(A&&A.stack||A)}}var d=window,f=["break,continue,do,else,for,if,return,while"],p=[[f,"auto,case,char,const,default,double,enum,extern,float,goto,inline,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"],"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"],h=[p,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,delegate,dynamic_cast,explicit,export,friend,generic,late_check,mutable,namespace,nullptr,property,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"],m=[p,"abstract,assert,boolean,byte,extends,final,finally,implements,import,instanceof,interface,null,native,package,strictfp,super,synchronized,throws,transient"],g=[m,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,internal,into,is,let,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var,virtual,where"],p=[p,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"],v=[f,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"],y=[f,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"],b=[f,"as,assert,const,copy,drop,enum,extern,fail,false,fn,impl,let,log,loop,match,mod,move,mut,priv,pub,pure,ref,self,static,struct,true,trait,type,unsafe,use"],f=[f,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"],x=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)\b/,w=/\S/,C=a({keywords:[h,g,p,"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",v,y,f],hashComments:!0,cStyleComments:!0,multiLineStrings:!0,regexLiterals:!0}),k={};l(C,["default-code"]),l(o([],[["pln",/^[^<?]+/],["dec",/^<!\w[^>]*(?:>|$)/],["com",/^<\!--[\S\s]*?(?:--\>|$)/],["lang-",/^<\?([\S\s]+?)(?:\?>|$)/],["lang-",/^<%([\S\s]+?)(?:%>|$)/],["pun",/^(?:<[%?]|[%?]>)/],["lang-",/^<xmp\b[^>]*>([\S\s]+?)<\/xmp\b[^>]*>/i],["lang-js",/^<script\b[^>]*>([\S\s]*?)(<\/script\b[^>]*>)/i],["lang-css",/^<style\b[^>]*>([\S\s]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]),l(o([["pln",/^\s+/,e," \r\n"],["atv",/^(?:"[^"]*"?|'[^']*'?)/,e,"\"'"]],[["tag",/^^<\/?[a-z](?:[\w-.:]*\w)?|\/?>$/i],["atn",/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^\s"'>]*(?:[^\s"'/>]|\/(?=\s)))/],["pun",/^[/<->]+/],["lang-js",/^on\w+\s*=\s*"([^"]+)"/i],["lang-js",/^on\w+\s*=\s*'([^']+)'/i],["lang-js",/^on\w+\s*=\s*([^\s"'>]+)/i],["lang-css",/^style\s*=\s*"([^"]+)"/i],["lang-css",/^style\s*=\s*'([^']+)'/i],["lang-css",/^style\s*=\s*([^\s"'>]+)/i]]),["in.tag"]),l(o([],[["atv",/^[\S\s]+/]]),["uq.val"]),l(a({keywords:h,hashComments:!0,cStyleComments:!0,types:x}),["c","cc","cpp","cxx","cyc","m"]),l(a({keywords:"null,true,false"}),["json"]),l(a({keywords:g,hashComments:!0,cStyleComments:!0,verbatimStrings:!0,types:x}),["cs"]),l(a({keywords:m,cStyleComments:!0}),["java"]),l(a({keywords:f,hashComments:!0,multiLineStrings:!0}),["bash","bsh","csh","sh"]),l(a({keywords:v,hashComments:!0,multiLineStrings:!0,tripleQuotedStrings:!0}),["cv","py","python"]),l(a({keywords:"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",hashComments:!0,multiLineStrings:!0,regexLiterals:2}),["perl","pl","pm"]),l(a({keywords:y,hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["rb","ruby"]),l(a({keywords:p,cStyleComments:!0,regexLiterals:!0}),["javascript","js"]),l(a({keywords:"all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,throw,true,try,unless,until,when,while,yes",hashComments:3,cStyleComments:!0,multilineStrings:!0,tripleQuotedStrings:!0,regexLiterals:!0}),["coffee"]),l(a({keywords:b,cStyleComments:!0,multilineStrings:!0}),["rc","rs","rust"]),l(o([],[["str",/^[\S\s]+/]]),["regex"]);var S=d.PR={createSimpleLexer:o,registerLangHandler:l,sourceDecorator:a,PR_ATTRIB_NAME:"atn",PR_ATTRIB_VALUE:"atv",PR_COMMENT:"com",PR_DECLARATION:"dec",PR_KEYWORD:"kwd",PR_LITERAL:"lit",PR_NOCODE:"nocode",PR_PLAIN:"pln",PR_PUNCTUATION:"pun",PR_SOURCE:"src",PR_STRING:"str",PR_TAG:"tag",PR_TYPE:"typ",prettyPrintOne:d.prettyPrintOne=function(e,t,n){var r=document.createElement("div");return r.innerHTML="<pre>"+e+"</pre>",r=r.firstChild,n&&s(r,n,!0),u({h:t,j:n,c:r,i:1}),r.innerHTML},prettyPrint:d.prettyPrint=function(t,n){function r(){for(var n=d.PR_SHOULD_USE_CONTINUATION?h.now()+250:1/0;m<l.length&&h.now()<n;m++){for(var o=l[m],c=k,f=o;f=f.previousSibling;){var p=f.nodeType,S=(7===p||8===p)&&f.nodeValue;if(S?!/^\??prettify\b/.test(S):3!==p||/\S/.test(f.nodeValue))break;if(S){c={},S.replace(/\b(\w+)=([\w%+\-.:]+)/g,function(e,t,n){c[t]=n});break}}if(f=o.className,(c!==k||y.test(f))&&!b.test(f)){for(p=!1,S=o.parentNode;S;S=S.parentNode)if(C.test(S.tagName)&&S.className&&y.test(S.className)){p=!0;break}if(!p){if(o.className+=" prettyprinted",p=c.lang,!p){var p=f.match(v),T;!p&&(T=i(o))&&w.test(T.tagName)&&(p=T.className.match(v)),p&&(p=p[1])}if(x.test(o.tagName))S=1;else var S=o.currentStyle,E=a.defaultView,S=(S=S?S.whiteSpace:E&&E.getComputedStyle?E.getComputedStyle(o,e).getPropertyValue("white-space"):0)&&"pre"===S.substring(0,3);E=c.linenums,(E="true"===E||+E)||(E=(E=f.match(/\blinenums\b(?::(\d+))?/))?E[1]&&E[1].length?+E[1]:!0:!1),E&&s(o,E,S),g={h:p,c:o,j:E,i:S},u(g)}}}m<l.length?setTimeout(r,250):"function"==typeof t&&t()}for(var o=n||document.body,a=o.ownerDocument||document,o=[o.getElementsByTagName("pre"),o.getElementsByTagName("code"),o.getElementsByTagName("xmp")],l=[],c=0;c<o.length;++c)for(var f=0,p=o[c].length;p>f;++f)l.push(o[c][f]);var o=e,h=Date;h.now||(h={now:function(){return+new Date}});var m=0,g,v=/\blang(?:uage)?-([\w.]+)(?!\S)/,y=/\bprettyprint\b/,b=/\bprettyprinted\b/,x=/pre|xmp/i,w=/^code$/i,C=/^(?:pre|code|xmp)$/i,k={};r()}};"function"==typeof define&&define.amd&&define("google-code-prettify",[],function(){return S})}()}(),PR.registerLangHandler(PR.createSimpleLexer([["com",/^#[^\n\r]*/,null,"#"],["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,null,'"']],[["kwd",/^(?:ADS|AD|AUG|BZF|BZMF|CAE|CAF|CA|CCS|COM|CS|DAS|DCA|DCOM|DCS|DDOUBL|DIM|DOUBLE|DTCB|DTCF|DV|DXCH|EDRUPT|EXTEND|INCR|INDEX|NDX|INHINT|LXCH|MASK|MSK|MP|MSU|NOOP|OVSK|QXCH|RAND|READ|RELINT|RESUME|RETURN|ROR|RXOR|SQUARE|SU|TCR|TCAA|OVSK|TCF|TC|TS|WAND|WOR|WRITE|XCH|XLQ|XXALQ|ZL|ZQ|ADD|ADZ|SUB|SUZ|MPY|MPR|MPZ|DVP|COM|ABS|CLA|CLZ|LDQ|STO|STQ|ALS|LLS|LRS|TRA|TSQ|TMI|TOV|AXT|TIX|DLY|INP|OUT)\s/,null],["typ",/^(?:-?GENADR|=MINUS|2BCADR|VN|BOF|MM|-?2CADR|-?[1-6]DNADR|ADRES|BBCON|[ES]?BANK=?|BLOCK|BNKSUM|E?CADR|COUNT\*?|2?DEC\*?|-?DNCHAN|-?DNPTR|EQUALS|ERASE|MEMORY|2?OCT|REMADR|SETLOC|SUBRO|ORG|BSS|BES|SYN|EQU|DEFINE|END)\s/,null],["lit",/^'(?:-*(?:\w|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?)?/],["pln",/^-*(?:[!-z]|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?/],["pun",/^[^\w\t\n\r "'-);\\\xa0]+/]]),["apollo","agc","aea"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["str",/^"(?:[^\n\r"\\]|\\.)*(?:"|$)/,a,'"'],["pln",/^\s+/,a," \r\n "]],[["com",/^REM[^\n\r]*/,a],["kwd",/^\b(?:AND|CLOSE|CLR|CMD|CONT|DATA|DEF ?FN|DIM|END|FOR|GET|GOSUB|GOTO|IF|INPUT|LET|LIST|LOAD|NEW|NEXT|NOT|ON|OPEN|OR|POKE|PRINT|READ|RESTORE|RETURN|RUN|SAVE|STEP|STOP|SYS|THEN|TO|VERIFY|WAIT)\b/,a],["pln",/^[a-z][^\W_]?(?:\$|%)?/i,a],["lit",/^(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?/i,a,"0123456789"],["pun",/^.[^\s\w"$%.]*/,a]]),["basic","cbm"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["opn",/^[([{]+/,a,"([{"],["clo",/^[)\]}]+/,a,")]}"],["com",/^;[^\n\r]*/,a,";"],["pln",/^[\t\n\r \xa0]+/,a," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,a,'"']],[["kwd",/^(?:def|if|do|let|quote|var|fn|loop|recur|throw|try|monitor-enter|monitor-exit|defmacro|defn|defn-|macroexpand|macroexpand-1|for|doseq|dosync|dotimes|and|or|when|not|assert|doto|proxy|defstruct|first|rest|cons|defprotocol|deftype|defrecord|reify|defmulti|defmethod|meta|with-meta|ns|in-ns|create-ns|import|intern|refer|alias|namespace|resolve|ref|deref|refset|new|set!|memfn|to-array|into-array|aset|gen-class|reduce|map|filter|find|nil?|empty?|hash-map|hash-set|vec|vector|seq|flatten|reverse|assoc|dissoc|list|list?|disj|get|union|difference|intersection|extend|extend-type|extend-protocol|prn)\b/,a],["typ",/^:[\dA-Za-z-]+/]]),["clj"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\f\r ]+/,null," \r\n\f"]],[["str",/^"(?:[^\n\f\r"\\]|\\(?:\r\n?|\n|\f)|\\[\S\s])*"/,null],["str",/^'(?:[^\n\f\r'\\]|\\(?:\r\n?|\n|\f)|\\[\S\s])*'/,null],["lang-css-str",/^url\(([^"')]+)\)/i],["kwd",/^(?:url|rgb|!important|@import|@page|@media|@charset|inherit)(?=[^\w-]|$)/i,null],["lang-css-kw",/^(-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*)\s*:/i],["com",/^\/\*[^*]*\*+(?:[^*/][^*]*\*+)*\//],["com",/^(?:<\!--|--\>)/],["lit",/^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],["lit",/^#[\da-f]{3,6}\b/i],["pln",/^-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*/i],["pun",/^[^\s\w"']+/]]),["css"]),PR.registerLangHandler(PR.createSimpleLexer([],[["kwd",/^-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*/i]]),["css-kw"]),PR.registerLangHandler(PR.createSimpleLexer([],[["str",/^[^"')]+/]]),["css-str"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "]],[["com",/^#!.*/],["kwd",/^\b(?:import|library|part of|part|as|show|hide)\b/i],["com",/^\/\/.*/],["com",/^\/\*[^*]*\*+(?:[^*/][^*]*\*+)*\//],["kwd",/^\b(?:class|interface)\b/i],["kwd",/^\b(?:assert|break|case|catch|continue|default|do|else|finally|for|if|in|is|new|return|super|switch|this|throw|try|while)\b/i],["kwd",/^\b(?:abstract|const|extends|factory|final|get|implements|native|operator|set|static|typedef|var)\b/i],["typ",/^\b(?:bool|double|dynamic|int|num|object|string|void)\b/i],["kwd",/^\b(?:false|null|true)\b/i],["str",/^r?'''[\S\s]*?[^\\]'''/],["str",/^r?"""[\S\s]*?[^\\]"""/],["str",/^r?'('|[^\n\f\r]*?[^\\]')/],["str",/^r?"("|[^\n\f\r]*?[^\\]")/],["pln",/^[$_a-z]\w*/i],["pun",/^[!%&*+/:<-?^|~-]/],["lit",/^\b0x[\da-f]+/i],["lit",/^\b\d+(?:\.\d*)?(?:e[+-]?\d+)?/i],["lit",/^\b\.\d+(?:e[+-]?\d+)?/i],["pun",/^[(),.;[\]{}]/]]),["dart"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t-\r ]+/,null," \n\f\r "],["str",/^"(?:[^\n\f\r"\\]|\\[\S\s])*(?:"|$)/,null,'"'],["lit",/^[a-z]\w*/],["lit",/^'(?:[^\n\f\r'\\]|\\[^&])+'?/,null,"'"],["lit",/^\?[^\t\n ({]+/,null,"?"],["lit",/^(?:0o[0-7]+|0x[\da-f]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)/i,null,"0123456789"]],[["com",/^%[^\n]*/],["kwd",/^(?:module|attributes|do|let|in|letrec|apply|call|primop|case|of|end|when|fun|try|catch|receive|after|char|integer|float,atom,string,var)\b/],["kwd",/^-[_a-z]+/],["typ",/^[A-Z_]\w*/],["pun",/^[,.;]/]]),["erlang","erl"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t-\r ]+/,null," \n\f\r "],["str",/^"(?:[^\n\f\r"\\]|\\[\S\s])*(?:"|$)/,null,'"'],["str",/^'(?:[^\n\f\r'\\]|\\[^&])'?/,null,"'"],["lit",/^(?:0o[0-7]+|0x[\da-f]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)/i,null,"0123456789"]],[["com",/^(?:--+[^\n\f\r]*|{-(?:[^-]|-+[^}-])*-})/],["kwd",/^(?:case|class|data|default|deriving|do|else|if|import|in|infix|infixl|infixr|instance|let|module|newtype|of|then|type|where|_)(?=[^\d'A-Za-z]|$)/,null],["pln",/^(?:[A-Z][\w']*\.)*[A-Za-z][\w']*/],["pun",/^[^\d\t-\r "'A-Za-z]+/]]),["hs"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["opn",/^\(+/,a,"("],["clo",/^\)+/,a,")"],["com",/^;[^\n\r]*/,a,";"],["pln",/^[\t\n\r \xa0]+/,a," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,a,'"']],[["kwd",/^(?:block|c[ad]+r|catch|con[ds]|def(?:ine|un)|do|eq|eql|equal|equalp|eval-when|flet|format|go|if|labels|lambda|let|load-time-value|locally|macrolet|multiple-value-call|nil|progn|progv|quote|require|return-from|setq|symbol-macrolet|t|tagbody|the|throw|unwind)\b/,a],["lit",/^[+-]?(?:[#0]x[\da-f]+|\d+\/\d+|(?:\.\d+|\d+(?:\.\d*)?)(?:[de][+-]?\d+)?)/i],["lit",/^'(?:-*(?:\w|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?)?/],["pln",/^-*(?:[_a-z]|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?/i],["pun",/^[^\w\t\n\r "'-);\\\xa0]+/]]),["cl","el","lisp","lsp","scm","ss","rkt"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^!?"(?:[^"\\]|\\[\S\s])*(?:"|$)/,null,'"'],["com",/^;[^\n\r]*/,null,";"]],[["pln",/^[!%@](?:[$\-.A-Z_a-z][\w$\-.]*|\d+)/],["kwd",/^[^\W\d]\w*/,null],["lit",/^\d+\.\d+/],["lit",/^(?:\d+|0[Xx][\dA-Fa-f]+)/],["pun",/^[(-*,:<->[\]{}]|\.\.\.$/]]),["llvm","ll"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^(?:"(?:[^"\\]|\\[\S\s])*(?:"|$)|'(?:[^'\\]|\\[\S\s])*(?:'|$))/,null,"\"'"]],[["com",/^--(?:\[(=*)\[[\S\s]*?(?:]\1]|$)|[^\n\r]*)/],["str",/^\[(=*)\[[\S\s]*?(?:]\1]|$)/],["kwd",/^(?:and|break|do|else|elseif|end|false|for|function|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,null],["lit",/^[+-]?(?:0x[\da-f]+|(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?)/i],["pln",/^[_a-z]\w*/i],["pun",/^[^\w\t\n\r \xa0][^\w\t\n\r "'+=\xa0-]*/]]),["lua"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["com",/^#(?:if[\t\n\r \xa0]+(?:[$_a-z][\w']*|``[^\t\n\r`]*(?:``|$))|else|endif|light)/i,null,"#"],["str",/^(?:"(?:[^"\\]|\\[\S\s])*(?:"|$)|'(?:[^'\\]|\\[\S\s])(?:'|$))/,null,"\"'"]],[["com",/^(?:\/\/[^\n\r]*|\(\*[\S\s]*?\*\))/],["kwd",/^(?:abstract|and|as|assert|begin|class|default|delegate|do|done|downcast|downto|elif|else|end|exception|extern|false|finally|for|fun|function|if|in|inherit|inline|interface|internal|lazy|let|match|member|module|mutable|namespace|new|null|of|open|or|override|private|public|rec|return|static|struct|then|to|true|try|type|upcast|use|val|void|when|while|with|yield|asr|land|lor|lsl|lsr|lxor|mod|sig|atomic|break|checked|component|const|constraint|constructor|continue|eager|event|external|fixed|functor|global|include|method|mixin|object|parallel|process|protected|pure|sealed|trait|virtual|volatile)\b/],["lit",/^[+-]?(?:0x[\da-f]+|(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?)/i],["pln",/^(?:[_a-z][\w']*[!#?]?|``[^\t\n\r`]*(?:``|$))/i],["pun",/^[^\w\t\n\r "'\xa0]+/]]),["fs","ml"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^"(?:[^"]|\\.)*"/,null,'"']],[["com",/^;[^\n\r]*/,null,";"],["dec",/^\$(?:d|device|ec|ecode|es|estack|et|etrap|h|horolog|i|io|j|job|k|key|p|principal|q|quit|st|stack|s|storage|sy|system|t|test|tl|tlevel|tr|trestart|x|y|z[a-z]*|a|ascii|c|char|d|data|e|extract|f|find|fn|fnumber|g|get|j|justify|l|length|na|name|o|order|p|piece|ql|qlength|qs|qsubscript|q|query|r|random|re|reverse|s|select|st|stack|t|text|tr|translate|nan)\b/i,null],["kwd",/^(?:[^$]b|break|c|close|d|do|e|else|f|for|g|goto|h|halt|h|hang|i|if|j|job|k|kill|l|lock|m|merge|n|new|o|open|q|quit|r|read|s|set|tc|tcommit|tre|trestart|tro|trollback|ts|tstart|u|use|v|view|w|write|x|xecute)\b/i,null],["lit",/^[+-]?(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?/i],["pln",/^[a-z][^\W_]*/i],["pun",/^[^\w\t\n\r"$%;^\xa0]|_/]]),["mumps"]); -var a=null;PR.registerLangHandler(PR.createSimpleLexer([["str",/^(?:'(?:[^\n\r'\\]|\\.)*'|"(?:[^\n\r"\\]|\\.)*(?:"|$))/,a,'"'],["com",/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\n\r]*)/,a,"#"],["pln",/^\s+/,a," \r\n "]],[["str",/^@"(?:[^"]|"")*(?:"|$)/,a],["str",/^<#[^#>]*(?:#>|$)/,a],["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,a],["com",/^\/\/[^\n\r]*/,a],["com",/^\/\*[\S\s]*?(?:\*\/|$)/,a],["kwd",/^(?:abstract|and|as|base|catch|class|def|delegate|enum|event|extern|false|finally|fun|implements|interface|internal|is|macro|match|matches|module|mutable|namespace|new|null|out|override|params|partial|private|protected|public|ref|sealed|static|struct|syntax|this|throw|true|try|type|typeof|using|variant|virtual|volatile|when|where|with|assert|assert2|async|break|checked|continue|do|else|ensures|for|foreach|if|late|lock|new|nolate|otherwise|regexp|repeat|requires|return|surroundwith|unchecked|unless|using|while|yield)\b/,a],["typ",/^(?:array|bool|byte|char|decimal|double|float|int|list|long|object|sbyte|short|string|ulong|uint|ufloat|ulong|ushort|void)\b/,a],["lit",/^@[$_a-z][\w$@]*/i,a],["typ",/^@[A-Z]+[a-z][\w$@]*/,a],["pln",/^'?[$_a-z][\w$@]*/i,a],["lit",/^(?:0x[\da-f]+|(?:\d(?:_\d+)*\d*(?:\.\d*)?|\.\d\+)(?:e[+-]?\d+)?)[a-z]*/i,a,"0123456789"],["pun",/^.[^\s\w"-$'./@`]*/,a]]),["n","nemerle"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["str",/^'(?:[^\n\r'\\]|\\.)*(?:'|$)/,a,"'"],["pln",/^\s+/,a," \r\n "]],[["com",/^\(\*[\S\s]*?(?:\*\)|$)|^{[\S\s]*?(?:}|$)/,a],["kwd",/^(?:absolute|and|array|asm|assembler|begin|case|const|constructor|destructor|div|do|downto|else|end|external|for|forward|function|goto|if|implementation|in|inline|interface|interrupt|label|mod|not|object|of|or|packed|procedure|program|record|repeat|set|shl|shr|then|to|type|unit|until|uses|var|virtual|while|with|xor)\b/i,a],["lit",/^(?:true|false|self|nil)/i,a],["pln",/^[a-z][^\W_]*/i,a],["lit",/^(?:\$[\da-f]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?)/i,a,"0123456789"],["pun",/^.[^\s\w$'./@]*/,a]]),["pascal"]),PR.registerLangHandler(PR.sourceDecorator({keywords:"bytes,default,double,enum,extend,extensions,false,group,import,max,message,option,optional,package,repeated,required,returns,rpc,service,syntax,to,true",types:/^(bool|(double|s?fixed|[su]?int)(32|64)|float|string)\b/,cStyleComments:!0}),["proto"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,null,'"'],["str",/^'(?:[^'\\]|\\[\S\s])*(?:'|$)/,null,"'"]],[["com",/^#.*/],["kwd",/^(?:if|else|for|while|repeat|in|next|break|return|switch|function)(?![\w.])/],["lit",/^0[Xx][\dA-Fa-f]+([Pp]\d+)?[Li]?/],["lit",/^[+-]?(\d+(\.\d+)?|\.\d+)([Ee][+-]?\d+)?[Li]?/],["lit",/^(?:NULL|NA(?:_(?:integer|real|complex|character)_)?|Inf|TRUE|FALSE|NaN|\.\.(?:\.|\d+))(?![\w.])/],["pun",/^(?:<<?-|->>?|-|==|<=|>=|<|>|&&?|!=|\|\|?|[!*+/^]|%.*?%|[$=@~]|:{1,3}|[(),;?[\]{}])/],["pln",/^(?:[A-Za-z]+[\w.]*|\.[^\W\d][\w.]*)(?![\w.])/],["str",/^`.+`/]]),["r","s","R","S","Splus"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["com",/^%[^\n\r]*/,null,"%"]],[["lit",/^\\(?:cr|l?dots|R|tab)\b/],["kwd",/^\\[@-Za-z]+/],["kwd",/^#(?:ifn?def|endif)/],["pln",/^\\[{}]/],["pun",/^[()[\]{}]+/]]),["Rd","rd"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^"(?:""(?:""?(?!")|[^"\\]|\\.)*"{0,3}|(?:[^\n\r"\\]|\\.)*"?)/,null,'"'],["lit",/^`(?:[^\n\r\\`]|\\.)*`?/,null,"`"],["pun",/^[!#%&(--:-@[-^{-~]+/,null,"!#%&()*+,-:;<=>?@[\\]^{|}~"]],[["str",/^'(?:[^\n\r'\\]|\\(?:'|[^\n\r']+))'/],["lit",/^'[$A-Z_a-z][\w$]*(?![\w$'])/],["kwd",/^(?:abstract|case|catch|class|def|do|else|extends|final|finally|for|forSome|if|implicit|import|lazy|match|new|object|override|package|private|protected|requires|return|sealed|super|throw|trait|try|type|val|var|while|with|yield)\b/],["lit",/^(?:true|false|null|this)\b/],["lit",/^(?:0(?:[0-7]+|x[\da-f]+)l?|(?:0|[1-9]\d*)(?:(?:\.\d+)?(?:e[+-]?\d+)?f?|l?)|\\.\d+(?:e[+-]?\d+)?f?)/i],["typ",/^[$_]*[A-Z][\d$A-Z_]*[a-z][\w$]*/],["pln",/^[$A-Z_a-z][\w$]*/],["com",/^\/(?:\/.*|\*(?:\/|\**[^*/])*(?:\*+\/?)?)/],["pun",/^(?:\.+|\/)/]]),["scala"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^(?:"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*')/,null,"\"'"]],[["com",/^(?:--[^\n\r]*|\/\*[\S\s]*?(?:\*\/|$))/],["kwd",/^(?:add|all|alter|and|any|apply|as|asc|authorization|backup|begin|between|break|browse|bulk|by|cascade|case|check|checkpoint|close|clustered|coalesce|collate|column|commit|compute|connect|constraint|contains|containstable|continue|convert|create|cross|current|current_date|current_time|current_timestamp|current_user|cursor|database|dbcc|deallocate|declare|default|delete|deny|desc|disk|distinct|distributed|double|drop|dummy|dump|else|end|errlvl|escape|except|exec|execute|exists|exit|fetch|file|fillfactor|following|for|foreign|freetext|freetexttable|from|full|function|goto|grant|group|having|holdlock|identity|identitycol|identity_insert|if|in|index|inner|insert|intersect|into|is|join|key|kill|left|like|lineno|load|match|matched|merge|natural|national|nocheck|nonclustered|nocycle|not|null|nullif|of|off|offsets|on|open|opendatasource|openquery|openrowset|openxml|option|or|order|outer|over|partition|percent|pivot|plan|preceding|precision|primary|print|proc|procedure|public|raiserror|read|readtext|reconfigure|references|replication|restore|restrict|return|revoke|right|rollback|rowcount|rowguidcol|rows?|rule|save|schema|select|session_user|set|setuser|shutdown|some|start|statistics|system_user|table|textsize|then|to|top|tran|transaction|trigger|truncate|tsequal|unbounded|union|unique|unpivot|update|updatetext|use|user|using|values|varying|view|waitfor|when|where|while|with|within|writetext|xml)(?=[^\w-]|$)/i,null],["lit",/^[+-]?(?:0x[\da-f]+|(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?)/i],["pln",/^[_a-z][\w-]*/i],["pun",/^[^\w\t\n\r "'\xa0][^\w\t\n\r "'+\xa0-]*/]]),["sql"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["opn",/^{+/,a,"{"],["clo",/^}+/,a,"}"],["com",/^#[^\n\r]*/,a,"#"],["pln",/^[\t\n\r \xa0]+/,a," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,a,'"']],[["kwd",/^(?:after|append|apply|array|break|case|catch|continue|error|eval|exec|exit|expr|for|foreach|if|incr|info|proc|return|set|switch|trace|uplevel|upvar|while)\b/,a],["lit",/^[+-]?(?:[#0]x[\da-f]+|\d+\/\d+|(?:\.\d+|\d+(?:\.\d*)?)(?:[de][+-]?\d+)?)/i],["lit",/^'(?:-*(?:\w|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?)?/],["pln",/^-*(?:[_a-z]|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?/i],["pun",/^[^\w\t\n\r "'-);\\\xa0]+/]]),["tcl"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["com",/^%[^\n\r]*/,null,"%"]],[["kwd",/^\\[@-Za-z]+/],["kwd",/^\\./],["typ",/^[$&]/],["lit",/[+-]?(?:\.\d+|\d+(?:\.\d*)?)(cm|em|ex|in|pc|pt|bp|mm)/i],["pun",/^[()=[\]{}]+/]]),["latex","tex"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0\u2028\u2029]+/,null," \n\r \u2028\u2029"],["str",/^(?:["\u201c\u201d](?:[^"\u201c\u201d]|["\u201c\u201d]{2})(?:["\u201c\u201d]c|$)|["\u201c\u201d](?:[^"\u201c\u201d]|["\u201c\u201d]{2})*(?:["\u201c\u201d]|$))/i,null,'"“”'],["com",/^['\u2018\u2019](?:_(?:\r\n?|[^\r]?)|[^\n\r_\u2028\u2029])*/,null,"'‘’"]],[["kwd",/^(?:addhandler|addressof|alias|and|andalso|ansi|as|assembly|auto|boolean|byref|byte|byval|call|case|catch|cbool|cbyte|cchar|cdate|cdbl|cdec|char|cint|class|clng|cobj|const|cshort|csng|cstr|ctype|date|decimal|declare|default|delegate|dim|directcast|do|double|each|else|elseif|end|endif|enum|erase|error|event|exit|finally|for|friend|function|get|gettype|gosub|goto|handles|if|implements|imports|in|inherits|integer|interface|is|let|lib|like|long|loop|me|mod|module|mustinherit|mustoverride|mybase|myclass|namespace|new|next|not|notinheritable|notoverridable|object|on|option|optional|or|orelse|overloads|overridable|overrides|paramarray|preserve|private|property|protected|public|raiseevent|readonly|redim|removehandler|resume|return|select|set|shadows|shared|short|single|static|step|stop|string|structure|sub|synclock|then|throw|to|try|typeof|unicode|until|variant|wend|when|while|with|withevents|writeonly|xor|endif|gosub|let|variant|wend)\b/i,null],["com",/^rem\b.*/i],["lit",/^(?:true\b|false\b|nothing\b|\d+(?:e[+-]?\d+[dfr]?|[dfilrs])?|(?:&h[\da-f]+|&o[0-7]+)[ils]?|\d*\.\d+(?:e[+-]?\d+)?[dfr]?|#\s+(?:\d+[/-]\d+[/-]\d+(?:\s+\d+:\d+(?::\d+)?(\s*(?:am|pm))?)?|\d+:\d+(?::\d+)?(\s*(?:am|pm))?)\s+#)/i],["pln",/^(?:(?:[a-z]|_\w)\w*(?:\[[!#%&@]+])?|\[(?:[a-z]|_\w)\w*])/i],["pun",/^[^\w\t\n\r "'[\]\xa0\u2018\u2019\u201c\u201d\u2028\u2029]+/],["pun",/^(?:\[|])/]]),["vb","vbs"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "]],[["str",/^(?:[box]?"(?:[^"]|"")*"|'.')/i],["com",/^--[^\n\r]*/],["kwd",/^(?:abs|access|after|alias|all|and|architecture|array|assert|attribute|begin|block|body|buffer|bus|case|component|configuration|constant|disconnect|downto|else|elsif|end|entity|exit|file|for|function|generate|generic|group|guarded|if|impure|in|inertial|inout|is|label|library|linkage|literal|loop|map|mod|nand|new|next|nor|not|null|of|on|open|or|others|out|package|port|postponed|procedure|process|pure|range|record|register|reject|rem|report|return|rol|ror|select|severity|shared|signal|sla|sll|sra|srl|subtype|then|to|transport|type|unaffected|units|until|use|variable|wait|when|while|with|xnor|xor)(?=[^\w-]|$)/i,null],["typ",/^(?:bit|bit_vector|character|boolean|integer|real|time|string|severity_level|positive|natural|signed|unsigned|line|text|std_u?logic(?:_vector)?)(?=[^\w-]|$)/i,null],["typ",/^'(?:active|ascending|base|delayed|driving|driving_value|event|high|image|instance_name|last_active|last_event|last_value|left|leftof|length|low|path_name|pos|pred|quiet|range|reverse_range|right|rightof|simple_name|stable|succ|transaction|val|value)(?=[^\w-]|$)/i,null],["lit",/^\d+(?:_\d+)*(?:#[\w.\\]+#(?:[+-]?\d+(?:_\d+)*)?|(?:\.\d+(?:_\d+)*)?(?:e[+-]?\d+(?:_\d+)*)?)/i],["pln",/^(?:[a-z]\w*|\\[^\\]*\\)/i],["pun",/^[^\w\t\n\r "'\xa0][^\w\t\n\r "'\xa0-]*/]]),["vhdl","vhd"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\d\t a-gi-z\xa0]+/,null," abcdefgijklmnopqrstuvwxyz0123456789"],["pun",/^[*=[\]^~]+/,null,"=*~^[]"]],[["lang-wiki.meta",/(?:^^|\r\n?|\n)(#[a-z]+)\b/],["lit",/^[A-Z][a-z][\da-z]+[A-Z][a-z][^\W_]+\b/],["lang-",/^{{{([\S\s]+?)}}}/],["lang-",/^`([^\n\r`]+)`/],["str",/^https?:\/\/[^\s#/?]*(?:\/[^\s#?]*)?(?:\?[^\s#]*)?(?:#\S*)?/i],["pln",/^(?:\r\n|[\S\s])[^\n\r#*=A-[^`h{~]*/]]),["wiki"]),PR.registerLangHandler(PR.createSimpleLexer([["kwd",/^#[a-z]+/i,null,"#"]],[]),["wiki.meta"]);var a=null,a=null;PR.registerLangHandler(PR.createSimpleLexer([["pun",/^[:>?|]+/,a,":|>?"],["dec",/^%(?:YAML|TAG)[^\n\r#]+/,a,"%"],["typ",/^&\S+/,a,"&"],["typ",/^!\S*/,a,"!"],["str",/^"(?:[^"\\]|\\.)*(?:"|$)/,a,'"'],["str",/^'(?:[^']|'')*(?:'|$)/,a,"'"],["com",/^#[^\n\r]*/,a,"#"],["pln",/^\s+/,a," \r\n"]],[["dec",/^(?:---|\.\.\.)(?:[\n\r]|$)/],["pun",/^-/],["kwd",/^\w+:[\n\r ]/],["pln",/^\w+/]]),["yaml","yml"]),function(e){e.fn.zclip=function(t){if("object"==typeof t&&!t.length){var n=e.extend({path:"ZeroClipboard.swf",copy:null,beforeCopy:null,afterCopy:null,clickAfter:!0,setHandCursor:!0,setCSSEffects:!0},t);return this.each(function(){var t=e(this);if(t.is(":visible")&&("string"==typeof n.copy||e.isFunction(n.copy))){ZeroClipboard.setMoviePath(n.path);var r=new ZeroClipboard.Client;e.isFunction(n.copy)&&t.bind("zClip_copy",n.copy),e.isFunction(n.beforeCopy)&&t.bind("zClip_beforeCopy",n.beforeCopy),e.isFunction(n.afterCopy)&&t.bind("zClip_afterCopy",n.afterCopy),r.setHandCursor(n.setHandCursor),r.setCSSEffects(n.setCSSEffects),r.addEventListener("mouseOver",function(e){t.trigger("mouseenter")}),r.addEventListener("mouseOut",function(e){t.trigger("mouseleave")}),r.addEventListener("mouseDown",function(i){t.trigger("mousedown"),r.setText(e.isFunction(n.copy)?t.triggerHandler("zClip_copy"):n.copy),e.isFunction(n.beforeCopy)&&t.trigger("zClip_beforeCopy")}),r.addEventListener("complete",function(r,i){e.isFunction(n.afterCopy)?t.trigger("zClip_afterCopy"):(i.length>500&&(i=i.substr(0,500)+"...\n\n("+(i.length-500)+" characters not shown)"),t.removeClass("hover"),alert("Copied text to clipboard:\n\n "+i)),n.clickAfter&&t.trigger("click")}),r.glue(t[0],t.parent()[0]),e(window).bind("load resize",function(){r.reposition()})}})}return"string"==typeof t?this.each(function(){var n=e(this);t=t.toLowerCase();var r=n.data("zclipId"),i=e("#"+r+".zclip");"remove"==t?(i.remove(),n.removeClass("active hover")):"hide"==t?(i.hide(),n.removeClass("active hover")):"show"==t&&i.show()}):void 0}}(jQuery);var ZeroClipboard={version:"1.0.7",clients:{},moviePath:"ZeroClipboard.swf",nextId:1,$:function(e){return"string"==typeof e&&(e=document.getElementById(e)),e.addClass||(e.hide=function(){},e.show=function(){this.style.display=""},e.addClass=function(e){this.removeClass(e),this.className+=" "+e},e.removeClass=function(e){for(var t=this.className.split(/\s+/),n=-1,r=0;r<t.length;r++)t[r]==e&&(n=r,r=t.length);return n>-1&&(t.splice(n,1),this.className=t.join(" ")),this},e.hasClass=function(e){return!!this.className.match(new RegExp("\\s*"+e+"\\s*"))}),e},setMoviePath:function(e){this.moviePath=e},dispatch:function(e,t,n){var r=this.clients[e];r&&r.receiveEvent(t,n)},register:function(e,t){this.clients[e]=t},getDOMObjectPosition:function(e,t){var n={left:0,top:0,width:e.width?e.width:e.offsetWidth,height:e.height?e.height:e.offsetHeight};return e&&e!=t&&(n.left+=e.offsetLeft,n.top+=e.offsetTop),n},Client:function(e){this.handlers={},this.id=ZeroClipboard.nextId++,this.movieId="ZeroClipboardMovie_"+this.id,ZeroClipboard.register(this.id,this),e&&this.glue(e)}};ZeroClipboard.Client.prototype={id:0,ready:!1,movie:null,clipText:"",handCursorEnabled:!0,cssEffects:!0,handlers:null,glue:function(e,t,n){this.domElement=ZeroClipboard.$(e);var r=99;this.domElement.style.zIndex&&(r=parseInt(this.domElement.style.zIndex,10)+1),"string"==typeof t?t=ZeroClipboard.$(t):"undefined"==typeof t&&(t=document.getElementsByTagName("body")[0]);var i=ZeroClipboard.getDOMObjectPosition(this.domElement,t);this.div=document.createElement("div"),this.div.className="zclip",this.div.id="zclip-"+this.movieId,$(this.domElement).data("zclipId","zclip-"+this.movieId);var o=this.div.style;if(o.position="absolute",o.left=""+i.left+"px",o.top=""+i.top+"px",o.width=""+i.width+"px",o.height=""+i.height+"px",o.zIndex=r,"object"==typeof n)for(addedStyle in n)o[addedStyle]=n[addedStyle];t.appendChild(this.div),this.div.innerHTML=this.getHTML(i.width,i.height)},getHTML:function(e,t){var n="",r="id="+this.id+"&width="+e+"&height="+t;if(navigator.userAgent.match(/MSIE/)){var i=location.href.match(/^https/i)?"https://":"http://";n+='<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="'+i+'download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" width="'+e+'" height="'+t+'" id="'+this.movieId+'" align="middle"><param name="allowScriptAccess" value="always" /><param name="allowFullScreen" value="false" /><param name="movie" value="'+ZeroClipboard.moviePath+'" /><param name="loop" value="false" /><param name="menu" value="false" /><param name="quality" value="best" /><param name="bgcolor" value="#ffffff" /><param name="flashvars" value="'+r+'"/><param name="wmode" value="transparent"/></object>'}else n+='<embed id="'+this.movieId+'" src="'+ZeroClipboard.moviePath+'" loop="false" menu="false" quality="best" bgcolor="#ffffff" width="'+e+'" height="'+t+'" name="'+this.movieId+'" align="middle" allowScriptAccess="always" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" flashvars="'+r+'" wmode="transparent" />';return n},hide:function(){this.div&&(this.div.style.left="-2000px")},show:function(){this.reposition()},destroy:function(){if(this.domElement&&this.div){this.hide(),this.div.innerHTML="";var e=document.getElementsByTagName("body")[0];try{e.removeChild(this.div)}catch(t){}this.domElement=null,this.div=null}},reposition:function(e){if(e&&(this.domElement=ZeroClipboard.$(e),this.domElement||this.hide()),this.domElement&&this.div){var t=ZeroClipboard.getDOMObjectPosition(this.domElement),n=this.div.style;n.left=""+t.left+"px",n.top=""+t.top+"px"}},setText:function(e){this.clipText=e,this.ready&&this.movie.setText(e)},addEventListener:function(e,t){e=e.toString().toLowerCase().replace(/^on/,""),this.handlers[e]||(this.handlers[e]=[]),this.handlers[e].push(t)},setHandCursor:function(e){this.handCursorEnabled=e,this.ready&&this.movie.setHandCursor(e)},setCSSEffects:function(e){this.cssEffects=!!e},receiveEvent:function(e,t){switch(e=e.toString().toLowerCase().replace(/^on/,"")){case"load":if(this.movie=document.getElementById(this.movieId),!this.movie){var n=this;return void setTimeout(function(){n.receiveEvent("load",null)},1)}if(!this.ready&&navigator.userAgent.match(/Firefox/)&&navigator.userAgent.match(/Windows/)){var n=this;return setTimeout(function(){n.receiveEvent("load",null)},100),void(this.ready=!0)}this.ready=!0;try{this.movie.setText(this.clipText)}catch(r){}try{this.movie.setHandCursor(this.handCursorEnabled)}catch(r){}break;case"mouseover":this.domElement&&this.cssEffects&&(this.domElement.addClass("hover"),this.recoverActive&&this.domElement.addClass("active"));break;case"mouseout":this.domElement&&this.cssEffects&&(this.recoverActive=!1,this.domElement.hasClass("active")&&(this.domElement.removeClass("active"),this.recoverActive=!0),this.domElement.removeClass("hover"));break;case"mousedown":this.domElement&&this.cssEffects&&this.domElement.addClass("active");break;case"mouseup":this.domElement&&this.cssEffects&&(this.domElement.removeClass("active"),this.recoverActive=!1)}if(this.handlers[e])for(var i=0,o=this.handlers[e].length;o>i;i++){var a=this.handlers[e][i];"function"==typeof a?a(this,t):"object"==typeof a&&2==a.length?a[0][a[1]](this,t):"string"==typeof a&&window[a](this,t)}}},$.fn.extend({tabs:function(){Tabs(this)}}),$.fn.extend({markdown_preview:function(e){Preview(this,e)}}),$(document).ready(function(){function e(e){e.find(".label-color-drop .drop-down").html(n).on("click","a",function(){var e=$(this).parents(".form"),t=e.find(".label-color-drop label"),n=e.find("input[name=color]"),r=$(this).data("color-hex");t.css("background-color",r),n.val(r)})}var t=["#e11d21","#EB6420","#FBCA04","#009800","#006B75","#207DE5","#0052cc","#53E917","#F6C6C7","#FAD8C7","#FEF2C0","#BFE5BF","#BFDADC","#C7DEF8","#BFD4F2","#D4C5F9"],n="";t.forEach(function(e){n+='<a class="color" style="background-color:'+e+'" data-color-hex="'+e+'"></a>'});var r=$("#label-add-color"),i=$("#label-add-form .label-color-drop label");i.css("background-color",t[0]),r.val(t[0]);var o=$("#label-add-form");e(o),$("#label-new-btn").on("click",function(){o.hasClass("hidden")&&o.removeClass("hidden")}),$("#label-cancel-btn").on("click",function(){o.addClass("hidden")});var a=$("#label-edit-form-tpl");$("#label-list").on("click","a.edit",function(){var t=$(this).parents(".item"),n=a.clone();e(n);var r=n.find(".label-color-drop label"),i=n.find("input[name=color]"),o=t.find(".label").data("color-hex");r.css("background-color",o),i.val(o),n.find("input[name=name]").val(t.find(".label").text()),n.find("input[name=id]").val(t.attr("id").replace("label-","")),t.after(n.show()),$("#label-edit-cancel-btn").on("click",function(){n.remove()})});var s=$("#label-delete-form-tpl");$("#label-list").on("click","a.delete",function(){var e=$(this).parents(".item"),t=s.clone();t.find("input[name=id]").val(e.attr("id").replace("label-","")),e.after(t.show()),$("#label-del-cancel-btn").on("click",function(){t.remove()})})}),function($){function e(e,t){return"function"==typeof e?e.call(t):e}function t(e){for(;e=e.parentNode;)if(e==document)return!0;return!1}function n(e,t){this.$element=$(e),this.options=t,this.enabled=!0,this.fixTitle()}n.prototype={show:function(){var t=this.getTitle();if(t&&this.enabled){var n=this.tip();n.find(".tipsy-inner")[this.options.html?"html":"text"](t),n[0].className="tipsy",n.remove().css({top:0,left:0,visibility:"hidden",display:"block"}).prependTo(document.body);var r=$.extend({},this.$element.offset(),{width:this.$element[0].offsetWidth,height:this.$element[0].offsetHeight}),i=n[0].offsetWidth,o=n[0].offsetHeight,a=e(this.options.gravity,this.$element[0]),s;switch(a.charAt(0)){case"n":s={top:r.top+r.height+this.options.offset,left:r.left+r.width/2-i/2};break;case"s":s={top:r.top-o-this.options.offset,left:r.left+r.width/2-i/2};break;case"e":s={top:r.top+r.height/2-o/2,left:r.left-i-this.options.offset};break;case"w":s={top:r.top+r.height/2-o/2,left:r.left+r.width+this.options.offset}}2==a.length&&(s.left="w"==a.charAt(1)?r.left+r.width/2-15:r.left+r.width/2-i+15),n.css(s).addClass("tipsy-"+a),n.find(".tipsy-arrow")[0].className="tipsy-arrow tipsy-arrow-"+a.charAt(0),this.options.className&&n.addClass(e(this.options.className,this.$element[0])),this.options.fade?n.stop().css({opacity:0,display:"block",visibility:"visible"}).animate({opacity:this.options.opacity}):n.css({visibility:"visible",opacity:this.options.opacity})}},hide:function(){this.options.fade?this.tip().stop().fadeOut(function(){$(this).remove()}):this.tip().remove()},fixTitle:function(){var e=this.$element;(e.attr("title")||"string"!=typeof e.attr("original-title"))&&e.attr("original-title",e.attr("title")||"").removeAttr("title")},getTitle:function(){var e,t=this.$element,n=this.options;this.fixTitle();var e,n=this.options;return"string"==typeof n.title?e=t.attr("title"==n.title?"original-title":n.title):"function"==typeof n.title&&(e=n.title.call(t[0])),e=(""+e).replace(/(^\s*|\s*$)/,""),e||n.fallback},tip:function(){return this.$tip||(this.$tip=$('<div class="tipsy"></div>').html('<div class="tipsy-arrow"></div><div class="tipsy-inner"></div>'),this.$tip.data("tipsy-pointee",this.$element[0])),this.$tip},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled}},$.fn.tipsy=function(e){function t(t){var r=$.data(t,"tipsy");return r||(r=new n(t,$.fn.tipsy.elementOptions(t,e)),$.data(t,"tipsy",r)),r}function r(){var n=t(this);n.hoverState="in",0==e.delayIn?n.show():(n.fixTitle(),setTimeout(function(){"in"==n.hoverState&&n.show()},e.delayIn))}function i(){var n=t(this);n.hoverState="out",0==e.delayOut?n.hide():setTimeout(function(){"out"==n.hoverState&&n.hide()},e.delayOut)}if(e===!0)return this.data("tipsy");if("string"==typeof e){var o=this.data("tipsy");return o&&o[e](),this}if(e=$.extend({},$.fn.tipsy.defaults,e),e.live||this.each(function(){t(this)}),"manual"!=e.trigger){var a=e.live?"live":"bind",s="hover"==e.trigger?"mouseenter":"focus",l="hover"==e.trigger?"mouseleave":"blur";this[a](s,r)[a](l,i)}return this},$.fn.tipsy.defaults={className:null,delayIn:0,delayOut:0,fade:!1,fallback:"",gravity:"n",html:!1,live:!1,offset:0,opacity:.8,title:"title",trigger:"hover"},$.fn.tipsy.revalidate=function(){$(".tipsy").each(function(){var e=$.data(this,"tipsy-pointee");e&&t(e)||$(this).remove()})},$.fn.tipsy.elementOptions=function(e,t){return $.metadata?$.extend({},t,$(e).metadata()):t},$.fn.tipsy.autoNS=function(){return $(this).offset().top>$(document).scrollTop()+$(window).height()/2?"s":"n"},$.fn.tipsy.autoWE=function(){return $(this).offset().left>$(document).scrollLeft()+$(window).width()/2?"e":"w"},$.fn.tipsy.autoBounds=function(e,t){return function(){var n={ns:t[0],ew:t.length>1?t[1]:!1},r=$(document).scrollTop()+e,i=$(document).scrollLeft()+e,o=$(this);return o.offset().top<r&&(n.ns="n"),o.offset().left<i&&(n.ew="w"),$(window).width()+$(document).scrollLeft()-o.offset().left<e&&(n.ew="e"),$(window).height()+$(document).scrollTop()-o.offset().top<e&&(n.ns="s"),n.ns+(n.ew?n.ew:"")}}}(jQuery);var Gogs={};!function($){var ajax=$.ajax;$.extend({ajax:function(url,options){"object"==typeof url&&(options=url,url=void 0),options=options||{},url=options.url;var csrftoken=$("meta[name=_csrf]").attr("content"),headers=options.headers||{},domain=document.domain.replace(/\./gi,"\\.");(!/^(http:|https:).*/.test(url)||eval("/^(http:|https:)\\/\\/(.+\\.)*"+domain+".*/").test(url))&&(headers=$.extend(headers,{"X-Csrf-Token":csrftoken})),options.headers=headers;var callback=options.success;return options.success=function(e){e.once&&$("[name=_once]").val(e.once),callback&&callback.apply(this,arguments)},ajax(url,options)},changeHash:function(e){history.pushState?history.pushState(null,null,e):location.hash=e},deSelect:function(){window.getSelection?window.getSelection().removeAllRanges():document.selection.empty()}}),$.fn.extend({toggleHide:function(){$(this).addClass("hidden")},toggleShow:function(){$(this).removeClass("hidden")},toggleAjax:function(e,t){var n=$(this).data("ajax"),r=$(this).data("ajax-method")||"get",i=$(this).data("ajax-name"),o={};i.endsWith("preview")&&(o.mode="gfm",o.context=$(this).data("ajax-context")),$("[data-ajax-rel="+i+"]").each(function(){var e=$(this).data("ajax-field"),t=$(this).data("ajax-val");return"val"==t?(o[e]=$(this).val(),!0):"txt"==t?(o[e]=$(this).text(),!0):"html"==t?(o[e]=$(this).html(),!0):"data"==t?(o[e]=$(this).data("ajax-data"),!0):!0}),console.log("toggleAjax:",r,n,o),$.ajax({url:n,method:r.toUpperCase(),data:o,error:t,success:function(t){e&&e(t)}})}})}(jQuery),function($){Gogs.renderMarkdown=function(){var e=$(".markdown"),t=e.find("pre > code").parent();t.addClass("prettyprint"),prettyPrint();var n={};e.find("h1, h2, h3, h4, h5, h6").each(function(){var e=$(this),t=encodeURIComponent(e.text().toLowerCase().replace(/[^\w\- ]/g,"").replace(/[ ]/g,"-")),r=t;n[t]>0&&(r=t+"-"+n[t]),void 0==n[t]?n[t]=1:n[t]+=1,e=e.wrap('<div id="'+r+'" class="anchor-wrap" ></div>'),e.append('<a class="anchor" href="#'+r+'"><span class="octicon octicon-link"></span></a>')})},Gogs.renderCodeView=function(){function e(e,t,n){if(e.removeClass("active"),n){var r=parseInt(t.attr("rel").substr(1)),o=parseInt(n.attr("rel").substr(1)),a;if(r!=o){r>o&&(a=r,r=o,o=a);var s=[];for(i=r;o>=i;i++)s.push(".L"+i);return e.filter(s.join(",")).addClass("active"),void $.changeHash("#L"+r+"-L"+o)}}t.addClass("active"),$.changeHash("#"+t.attr("rel"))}$(document).on("click",".lines-num span",function(t){var n=$(this),r=n.parent().siblings(".lines-code").find("ol.linenums > li");e(r,r.filter("[rel="+n.attr("rel")+"]"),t.shiftKey?r.filter(".active").eq(0):null),$.deSelect()}),$(".code-view .lines-code > pre").each(function(){var e=$(this),t=e.parent(),n=t.siblings(".lines-num");if(n.length>0)for(var r=e.find("ol.linenums > li").length,i=1;r>=i;i++)n.append('<span id="L'+i+'" rel="L'+i+'">'+i+"</span>")}),$(window).on("hashchange",function(t){var n=window.location.hash.match(/^#(L\d+)\-(L\d+)$/),r=$(".code-view ol.linenums > li"),i;return n?(i=r.filter("."+n[1]),e(r,i,r.filter("."+n[2])),void $("html, body").scrollTop(i.offset().top-200)):(n=window.location.hash.match(/^#(L\d+)$/),void(n&&(i=r.filter("."+n[1]),e(r,i),$("html, body").scrollTop(i.offset().top-200))))}).trigger("hashchange")},Gogs.searchUsers=function(e,t){var n=function(e){return e&&e.length>0};$.ajax({url:Gogs.AppSubUrl+"/api/v1/users/search?q="+e,dataType:"json",success:function(e){if(e.ok&&e.data.length){var r="";$.each(e.data,function(e,t){r+='<li><a><img src="'+t.avatar_url+'"><span class="username">'+t.username+"</span>",n(t.full_name)&&(r+=" ("+t.full_name+")"),r+="</a></li>"}),t.html(r),t.toggleShow()}else t.toggleHide()}})},Gogs.searchRepos=function(e,t,n){$.ajax({url:Gogs.AppSubUrl+"/api/v1/repos/search?q="+e+"&"+n,dataType:"json",success:function(e){if(e.ok&&e.data.length){var n="";$.each(e.data,function(e,t){n+='<li><a><span class="octicon octicon-repo"></span> '+t.full_name+"</a></li>"}),t.html(n),t.toggleShow()}else t.toggleHide()}})},Gogs.bindCopy=function(e){$(e).hasClass("js-copy-bind")||$(e).zclip({path:Gogs.AppSubUrl+"/js/ZeroClipboard.swf",copy:function(){var e=$(this).data("copy-val"),t=$($(this).data("copy-from")),n="";return"txt"==e&&(n=t.text()),"val"==e&&(n=t.val()),"html"==e&&(n=t.html()),n},afterCopy:function(){var e=$(this);e.tipsy("hide").attr("original-title",e.data("after-title")),setTimeout(function(){e.tipsy("show")},200),setTimeout(function(){e.tipsy("hide").attr("original-title",e.data("original-title"))},2e3)}}).addClass("js-copy-bind")}}(jQuery),$(document).ready(function(){Gogs.AppSubUrl=$("head").data("suburl")||"",initCore(),$("#user-profile-setting").length&&initUserSetting(),($("#repo-create-form").length||$("#repo-migrate-form").length)&&initRepoCreate(),$("#repo-header").length&&(initTimeSwitch(),initRepo()),$("#release").length&&initRepoRelease(),$("#repo-setting").length&&initRepoSetting(),$("#org-setting").length&&initOrgSetting(),$("#invite-box").length&&initInvite(),$("#team-create-form").length&&initOrgTeamCreate(),$("#team-members-list").length&&initTeamMembersList(),$("#team-repositories-list").length&&initTeamRepositoriesList(),$("#admin-setting").length&&initAdmin(),$("#install-form").length&&initInstall(),$("#user-profile-page").length&&initProfile(),$("#diff-page").length&&(initTimeSwitch(),initDiff()),$("#dashboard-sidebar-menu").tabs(),$("#pull-issue-preview").markdown_preview(".issue-add-comment"),homepage();var e=$("#footer-lang li").length;$("#footer-lang .drop-down").css({top:-31*e+"px",height:31*e-3+"px"})}),String.prototype.endsWith=function(e){return-1!==this.indexOf(e,this.length-e.length)};
\ No newline at end of file +function Tabs(e){function t(e){console.log("hide",e),e.removeClass("js-tab-nav-show"),$(e.data("tab-target")).removeClass("js-tab-show").hide()}function n(e){console.log("show",e),e.addClass("js-tab-nav-show"),$(e.data("tab-target")).addClass("js-tab-show").show()}var i=$(e);if(i.length){var r=i.find(".js-tab-nav-show");r.length&&$(r.data("tab-target")).addClass("js-tab-show"),i.on("click",".js-tab-nav",function(e){e.preventDefault();var o=$(this);o.hasClass("js-tab-nav-show")||(r=i.find(".js-tab-nav-show").eq(0),t(r),n(o))}),console.log("init tabs @",e)}}function Preview(e,t){function n(e){return e.find(".js-preview-input").eq(0)}function i(e){return e.hasClass("js-preview-container")?e:e.find(".js-preview-container").eq(0)}var r=$(e),o=$(t),a=n(o);if(!a.length)return void console.log("[preview]: no preview input");var s=i(o);return s.length?(r.on("click",function(){$.post("/api/v1/markdown",{text:a.val()},function(e){s.html(e)})}),void console.log("[preview]: init preview @",e,"&",t)):void console.log("[preview]: no preview container")}function initCore(){Gogs.renderMarkdown(),0==$(".code-diff").length?Gogs.renderCodeView():Gogs.renderDiffView(),$(".js-tab-nav").click(function(e){$(this).hasClass("js-tab-nav-show")||($(this).parent().find(".js-tab-nav-show").each(function(){$(this).removeClass("js-tab-nav-show"),$($(this).data("tab-target")).hide()}),$(this).addClass("js-tab-nav-show"),$($(this).data("tab-target")).show()),e.preventDefault()}),$(document).on("click",".popup-modal-dismiss",function(e){e.preventDefault(),$.magnificPopup.close()}),$(".collapse").hide(),$(".tipsy-tooltip").tipsy({fade:!0})}function initUserSetting(){var t=$("#username"),n=$("#user-profile-form");$("#change-username-btn").magnificPopup({modal:!0,callbacks:{open:function(){t.data("uname")==t.val()&&($.magnificPopup.close(),n.submit())}}}).click(function(){return t.data("uname")!=t.val()?(e.preventDefault(),!0):void 0}),$("#change-username-submit").click(function(){$.magnificPopup.close(),n.submit()}),$(".show-form-btn").click(function(){$($(this).data("target-form")).removeClass("hide")}),$("#delete-account-btn").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-account-submit").click(function(){$.magnificPopup.close(),$("#delete-account-form").submit()})}function initRepoCreate(){$("#repo-create-owner-list").on("click","li",function(){if(!$(this).hasClass("checked")){var e=$(this).data("uid");$("#repo-owner-id").val(e),$("#repo-owner-avatar").attr("src",$(this).find("img").attr("src")),$("#repo-owner-name").text($(this).text().trim()),$(this).parent().find(".checked").removeClass("checked"),$(this).addClass("checked"),console.log("set repo owner to uid :",e,$(this).text().trim())}}),$("#auth-button").click(function(e){$("#repo-migrate-auth").slideToggle("fast"),e.preventDefault()}),console.log("initRepoCreate")}function initRepo(){$("#repo-clone-ssh").click(function(){$(this).removeClass("btn-gray").addClass("btn-blue"),$("#repo-clone-https").removeClass("btn-blue").addClass("btn-gray"),$("#repo-clone-url").val($(this).data("link")),$(".clone-url").text($(this).data("link"))}),$("#repo-clone-https").click(function(){$(this).removeClass("btn-gray").addClass("btn-blue"),$("#repo-clone-ssh").removeClass("btn-blue").addClass("btn-gray"),$("#repo-clone-url").val($(this).data("link")),$(".clone-url").text($(this).data("link"))});var e=$("#repo-clone-copy");e.hover(function(){Gogs.bindCopy($(this))}),e.tipsy({fade:!0}),$(".markdown-preview").click(function(){var e=$(this);e.toggleAjax(function(t){$(e.data("preview")).html(t)},function(){$(e.data("preview")).html("no content")})})}function initHookTypeChange(){$("select#hook-type").on("change",function(){hookTypes=["Gogs","Slack"];var e=$(this).val();hookTypes.forEach(function(t){e===t?$("div#"+t.toLowerCase()).toggleShow():$("div#"+t.toLowerCase()).toggleHide()})})}function initRepoRelease(){$("#release-new-target-branch-list li").click(function(){$(this).hasClass("checked")||($("#repo-branch-current").text($(this).text()),$("#tag-target").val($(this).text()),$(this).parent().find(".checked").removeClass("checked"),$(this).addClass("checked"))})}function initRepoSetting(){var t=$("#repo_name"),n=$("#repo-setting-form");$("#change-reponame-btn").magnificPopup({modal:!0,callbacks:{open:function(){t.data("repo-name")==t.val()&&($.magnificPopup.close(),n.submit())}}}).click(function(){return t.data("repo-name")!=t.val()?(e.preventDefault(),!0):void 0}),$("#change-reponame-submit").click(function(){$.magnificPopup.close(),n.submit()}),initHookTypeChange(),$("#transfer-repo-btn").magnificPopup({modal:!0}),$("#transfer-repo-submit").click(function(){$.magnificPopup.close(),$("#transfer-repo-form").submit()}),$("#delete-repo-btn").magnificPopup({modal:!0}),$("#delete-repo-submit").click(function(){$.magnificPopup.close(),$("#delete-repo-form").submit()}),$("#repo-collab-list hr:last-child").remove();var i=$("#repo-collaborator").next().next().find("ul");$("#repo-collaborator").on("keyup",function(){var e=$(this);return e.val()?void Gogs.searchUsers(e.val(),i):void i.toggleHide()}).on("focus",function(){$(this).val()?i.toggleShow():i.toggleHide()}).next().next().find("ul").on("click","li",function(){$("#repo-collaborator").val($(this).find(".username").text()),i.toggleHide()})}function initOrgSetting(){var t=$("#orgname"),n=$("#org-setting-form");$("#change-orgname-btn").magnificPopup({modal:!0,callbacks:{open:function(){t.data("orgname")==t.val()&&($.magnificPopup.close(),n.submit())}}}).click(function(){return t.data("orgname")!=t.val()?(e.preventDefault(),!0):void 0}),$("#change-orgname-submit").click(function(){$.magnificPopup.close(),n.submit()}),$("#delete-org-btn").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-org-submit").click(function(){$.magnificPopup.close(),$("#delete-org-form").submit()}),initHookTypeChange()}function initInvite(){var e=$("#org-member-invite-list");$("#org-member-invite").on("keyup",function(){var t=$(this);return t.val()?void Gogs.searchUsers(t.val(),e):void e.toggleHide()}).on("focus",function(){$(this).val()?e.toggleShow():e.toggleHide()}).next().next().find("ul").on("click","li",function(){$("#org-member-invite").val($(this).find(".username").text()),e.toggleHide()})}function initOrgTeamCreate(){$("#org-team-delete").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-team-submit").click(function(){$.magnificPopup.close();var e=$("#team-create-form");e.attr("action",e.data("delete-url"))})}function initTeamMembersList(){var e=$("#org-team-members-list");$("#org-team-members-add").on("keyup",function(){var t=$(this);return t.val()?void Gogs.searchUsers(t.val(),e):void e.toggleHide()}).on("focus",function(){$(this).val()?e.toggleShow():e.toggleHide()}).next().next().find("ul").on("click","li",function(){$("#org-team-members-add").val($(this).find(".username").text()),e.toggleHide()})}function initTeamRepositoriesList(){var e=$("#org-team-repositories-list");$("#org-team-repositories-add").on("keyup",function(){var t=$(this);return t.val()?void Gogs.searchRepos(t.val(),e,"uid="+t.data("uid")):void e.toggleHide()}).on("focus",function(){$(this).val()?e.toggleShow():e.toggleHide()}).next().next().find("ul").on("click","li",function(){$("#org-team-repositories-add").val($(this).text()),e.toggleHide()})}function initAdmin(){$("#login-type").on("change",function(){var e=$(this).val();e.indexOf("0-")+1?($(".auth-name").toggleHide(),$(".pwd").find("input").attr("required","required").end().toggleShow()):($(".pwd").find("input").removeAttr("required").end().toggleHide(),$(".auth-name").toggleShow())}),$("#delete-account-btn").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-account-submit").click(function(){$.magnificPopup.close();var e=$("#user-profile-form");e.attr("action",e.data("delete-url"))}),$("#auth-type").on("change",function(){var e=$(this).val();2==e&&($(".ldap").toggleShow(),$(".smtp").toggleHide()),3==e&&($(".smtp").toggleShow(),$(".ldap").toggleHide())}),$("#delete-auth-btn").magnificPopup({modal:!0}).click(function(e){return e.preventDefault(),!0}),$("#delete-auth-submit").click(function(){$.magnificPopup.close();var e=$("#auth-setting-form");e.attr("action",e.data("delete-url"))})}function initInstall(){!function(){var e="127.0.0.1:3306",t="127.0.0.1:5432";$("#install-database").on("change",function(){var n=$(this).val();"SQLite3"!=n?($(".server-sql").show(),$(".sqlite-setting").addClass("hide"),"PostgreSQL"==n?($(".pgsql-setting").removeClass("hide"),$("#database-host").val()==e&&$("#database-host").val(t)):"MySQL"==n?($(".pgsql-setting").addClass("hide"),$("#database-host").val()==t&&$("#database-host").val(e)):$(".pgsql-setting").addClass("hide")):($(".server-sql").hide(),$(".pgsql-setting").hide(),$(".sqlite-setting").removeClass("hide"))})}()}function initProfile(){$("#profile-avatar").tipsy({fade:!0})}function initTimeSwitch(){$(".time-since[title]").on("click",function(){var e=$(this),t=e.attr("title"),n=e.text();e.text(t),e.attr("title",n)})}function initDiff(){$(".diff-detail-box>a").click(function(){$($(this).data("target")).slideToggle(100)});var e=$(".diff-counter");e.length<1||e.each(function(e,t){var n=$(t),i=n.find("span[data-line].add").data("line"),r=n.find("span[data-line].del").data("line"),o=parseFloat(i)/(parseFloat(i)+parseFloat(r))*100;n.find(".bar .add").css("width",o+"%")})}function homepage(){$("#promo-form").submit(function(e){return""===$("#username").val()?(e.preventDefault(),window.location.href=Gogs.AppSubUrl+"/user/login",!0):void 0}),$("#register-button").click(function(e){return""===$("#username").val()?(e.preventDefault(),window.location.href=Gogs.AppSubUrl+"/user/sign_up",!0):void $("#promo-form").attr("action",Gogs.AppSubUrl+"/user/sign_up")})}!function(e,t){"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(e,t){function n(e){var t=e.length,n=ot.type(e);return"function"===n||ot.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e}function i(e,t,n){if(ot.isFunction(t))return ot.grep(e,function(e,i){return!!t.call(e,i,e)!==n});if(t.nodeType)return ot.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(pt.test(t))return ot.filter(t,e,n);t=ot.filter(t,e)}return ot.grep(e,function(e){return ot.inArray(e,t)>=0!==n})}function r(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}function o(e){var t=wt[e]={};return ot.each(e.match(xt)||[],function(e,n){t[n]=!0}),t}function a(){mt.addEventListener?(mt.removeEventListener("DOMContentLoaded",s,!1),e.removeEventListener("load",s,!1)):(mt.detachEvent("onreadystatechange",s),e.detachEvent("onload",s))}function s(){(mt.addEventListener||"load"===event.type||"complete"===mt.readyState)&&(a(),ot.ready())}function l(e,t,n){if(void 0===n&&1===e.nodeType){var i="data-"+t.replace(Tt,"-$1").toLowerCase();if(n=e.getAttribute(i),"string"==typeof n){try{n="true"===n?!0:"false"===n?!1:"null"===n?null:+n+""===n?+n:St.test(n)?ot.parseJSON(n):n}catch(r){}ot.data(e,t,n)}else n=void 0}return n}function c(e){var t;for(t in e)if(("data"!==t||!ot.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}function u(e,t,n,i){if(ot.acceptData(e)){var r,o,a=ot.expando,s=e.nodeType,l=s?ot.cache:e,c=s?e[a]:e[a]&&a;if(c&&l[c]&&(i||l[c].data)||void 0!==n||"string"!=typeof t)return c||(c=s?e[a]=V.pop()||ot.guid++:a),l[c]||(l[c]=s?{}:{toJSON:ot.noop}),("object"==typeof t||"function"==typeof t)&&(i?l[c]=ot.extend(l[c],t):l[c].data=ot.extend(l[c].data,t)),o=l[c],i||(o.data||(o.data={}),o=o.data),void 0!==n&&(o[ot.camelCase(t)]=n),"string"==typeof t?(r=o[t],null==r&&(r=o[ot.camelCase(t)])):r=o,r}}function d(e,t,n){if(ot.acceptData(e)){var i,r,o=e.nodeType,a=o?ot.cache:e,s=o?e[ot.expando]:ot.expando;if(a[s]){if(t&&(i=n?a[s]:a[s].data)){ot.isArray(t)?t=t.concat(ot.map(t,ot.camelCase)):t in i?t=[t]:(t=ot.camelCase(t),t=t in i?[t]:t.split(" ")),r=t.length;for(;r--;)delete i[t[r]];if(n?!c(i):!ot.isEmptyObject(i))return}(n||(delete a[s].data,c(a[s])))&&(o?ot.cleanData([e],!0):it.deleteExpando||a!=a.window?delete a[s]:a[s]=null)}}}function f(){return!0}function p(){return!1}function h(){try{return mt.activeElement}catch(e){}}function m(e){var t=Ht.split("|"),n=e.createDocumentFragment();if(n.createElement)for(;t.length;)n.createElement(t.pop());return n}function g(e,t){var n,i,r=0,o=typeof e.getElementsByTagName!==kt?e.getElementsByTagName(t||"*"):typeof e.querySelectorAll!==kt?e.querySelectorAll(t||"*"):void 0;if(!o)for(o=[],n=e.childNodes||e;null!=(i=n[r]);r++)!t||ot.nodeName(i,t)?o.push(i):ot.merge(o,g(i,t));return void 0===t||t&&ot.nodeName(e,t)?ot.merge([e],o):o}function v(e){Dt.test(e.type)&&(e.defaultChecked=e.checked)}function y(e,t){return ot.nodeName(e,"table")&&ot.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function b(e){return e.type=(null!==ot.find.attr(e,"type"))+"/"+e.type,e}function x(e){var t=Zt.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function w(e,t){for(var n,i=0;null!=(n=e[i]);i++)ot._data(n,"globalEval",!t||ot._data(t[i],"globalEval"))}function C(e,t){if(1===t.nodeType&&ot.hasData(e)){var n,i,r,o=ot._data(e),a=ot._data(t,o),s=o.events;if(s){delete a.handle,a.events={};for(n in s)for(i=0,r=s[n].length;r>i;i++)ot.event.add(t,n,s[n][i])}a.data&&(a.data=ot.extend({},a.data))}}function k(e,t){var n,i,r;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!it.noCloneEvent&&t[ot.expando]){r=ot._data(t);for(i in r.events)ot.removeEvent(t,i,r.handle);t.removeAttribute(ot.expando)}"script"===n&&t.text!==e.text?(b(t).text=e.text,x(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),it.html5Clone&&e.innerHTML&&!ot.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&Dt.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}}function S(t,n){var i,r=ot(n.createElement(t)).appendTo(n.body),o=e.getDefaultComputedStyle&&(i=e.getDefaultComputedStyle(r[0]))?i.display:ot.css(r[0],"display");return r.detach(),o}function T(e){var t=mt,n=Jt[e];return n||(n=S(e,t),"none"!==n&&n||(Kt=(Kt||ot("<iframe frameborder='0' width='0' height='0'/>")).appendTo(t.documentElement),t=(Kt[0].contentWindow||Kt[0].contentDocument).document,t.write(),t.close(),n=S(e,t),Kt.detach()),Jt[e]=n),n}function E(e,t){return{get:function(){var n=e();return null!=n?n?void delete this.get:(this.get=t).apply(this,arguments):void 0}}}function N(e,t){if(t in e)return t;for(var n=t.charAt(0).toUpperCase()+t.slice(1),i=t,r=pn.length;r--;)if(t=pn[r]+n,t in e)return t;return i}function L(e,t){for(var n,i,r,o=[],a=0,s=e.length;s>a;a++)i=e[a],i.style&&(o[a]=ot._data(i,"olddisplay"),n=i.style.display,t?(o[a]||"none"!==n||(i.style.display=""),""===i.style.display&&Lt(i)&&(o[a]=ot._data(i,"olddisplay",T(i.nodeName)))):(r=Lt(i),(n&&"none"!==n||!r)&&ot._data(i,"olddisplay",r?n:ot.css(i,"display"))));for(a=0;s>a;a++)i=e[a],i.style&&(t&&"none"!==i.style.display&&""!==i.style.display||(i.style.display=t?o[a]||"":"none"));return e}function A(e,t,n){var i=cn.exec(t);return i?Math.max(0,i[1]-(n||0))+(i[2]||"px"):t}function D(e,t,n,i,r){for(var o=n===(i?"border":"content")?4:"width"===t?1:0,a=0;4>o;o+=2)"margin"===n&&(a+=ot.css(e,n+Nt[o],!0,r)),i?("content"===n&&(a-=ot.css(e,"padding"+Nt[o],!0,r)),"margin"!==n&&(a-=ot.css(e,"border"+Nt[o]+"Width",!0,r))):(a+=ot.css(e,"padding"+Nt[o],!0,r),"padding"!==n&&(a+=ot.css(e,"border"+Nt[o]+"Width",!0,r)));return a}function j(e,t,n){var i=!0,r="width"===t?e.offsetWidth:e.offsetHeight,o=nn(e),a=it.boxSizing&&"border-box"===ot.css(e,"boxSizing",!1,o);if(0>=r||null==r){if(r=rn(e,t,o),(0>r||null==r)&&(r=e.style[t]),tn.test(r))return r;i=a&&(it.boxSizingReliable()||r===e.style[t]),r=parseFloat(r)||0}return r+D(e,t,n||(a?"border":"content"),i,o)+"px"}function R(e,t,n,i,r){return new R.prototype.init(e,t,n,i,r)}function P(){return setTimeout(function(){hn=void 0}),hn=ot.now()}function _(e,t){var n,i={height:e},r=0;for(t=t?1:0;4>r;r+=2-t)n=Nt[r],i["margin"+n]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function H(e,t,n){for(var i,r=(xn[t]||[]).concat(xn["*"]),o=0,a=r.length;a>o;o++)if(i=r[o].call(n,t,e))return i}function O(e,t,n){var i,r,o,a,s,l,c,u,d=this,f={},p=e.style,h=e.nodeType&&Lt(e),m=ot._data(e,"fxshow");n.queue||(s=ot._queueHooks(e,"fx"),null==s.unqueued&&(s.unqueued=0,l=s.empty.fire,s.empty.fire=function(){s.unqueued||l()}),s.unqueued++,d.always(function(){d.always(function(){s.unqueued--,ot.queue(e,"fx").length||s.empty.fire()})})),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],c=ot.css(e,"display"),u="none"===c?ot._data(e,"olddisplay")||T(e.nodeName):c,"inline"===u&&"none"===ot.css(e,"float")&&(it.inlineBlockNeedsLayout&&"inline"!==T(e.nodeName)?p.zoom=1:p.display="inline-block")),n.overflow&&(p.overflow="hidden",it.shrinkWrapBlocks()||d.always(function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]}));for(i in t)if(r=t[i],gn.exec(r)){if(delete t[i],o=o||"toggle"===r,r===(h?"hide":"show")){if("show"!==r||!m||void 0===m[i])continue;h=!0}f[i]=m&&m[i]||ot.style(e,i)}else c=void 0;if(ot.isEmptyObject(f))"inline"===("none"===c?T(e.nodeName):c)&&(p.display=c);else{m?"hidden"in m&&(h=m.hidden):m=ot._data(e,"fxshow",{}),o&&(m.hidden=!h),h?ot(e).show():d.done(function(){ot(e).hide()}),d.done(function(){var t;ot._removeData(e,"fxshow");for(t in f)ot.style(e,t,f[t])});for(i in f)a=H(h?m[i]:0,i,d),i in m||(m[i]=a.start,h&&(a.end=a.start,a.start="width"===i||"height"===i?1:0))}}function q(e,t){var n,i,r,o,a;for(n in e)if(i=ot.camelCase(n),r=t[i],o=e[n],ot.isArray(o)&&(r=o[1],o=e[n]=o[0]),n!==i&&(e[i]=o,delete e[n]),a=ot.cssHooks[i],a&&"expand"in a){o=a.expand(o),delete e[i];for(n in o)n in e||(e[n]=o[n],t[n]=r)}else t[i]=r}function M(e,t,n){var i,r,o=0,a=bn.length,s=ot.Deferred().always(function(){delete l.elem}),l=function(){if(r)return!1;for(var t=hn||P(),n=Math.max(0,c.startTime+c.duration-t),i=n/c.duration||0,o=1-i,a=0,l=c.tweens.length;l>a;a++)c.tweens[a].run(o);return s.notifyWith(e,[c,o,n]),1>o&&l?n:(s.resolveWith(e,[c]),!1)},c=s.promise({elem:e,props:ot.extend({},t),opts:ot.extend(!0,{specialEasing:{}},n),originalProperties:t,originalOptions:n,startTime:hn||P(),duration:n.duration,tweens:[],createTween:function(t,n){var i=ot.Tween(e,c.opts,t,n,c.opts.specialEasing[t]||c.opts.easing);return c.tweens.push(i),i},stop:function(t){var n=0,i=t?c.tweens.length:0;if(r)return this;for(r=!0;i>n;n++)c.tweens[n].run(1);return t?s.resolveWith(e,[c,t]):s.rejectWith(e,[c,t]),this}}),u=c.props;for(q(u,c.opts.specialEasing);a>o;o++)if(i=bn[o].call(c,e,u,c.opts))return i;return ot.map(u,H,c),ot.isFunction(c.opts.start)&&c.opts.start.call(e,c),ot.fx.timer(ot.extend(l,{elem:e,anim:c,queue:c.opts.queue})),c.progress(c.opts.progress).done(c.opts.done,c.opts.complete).fail(c.opts.fail).always(c.opts.always)}function z(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var i,r=0,o=t.toLowerCase().match(xt)||[];if(ot.isFunction(n))for(;i=o[r++];)"+"===i.charAt(0)?(i=i.slice(1)||"*",(e[i]=e[i]||[]).unshift(n)):(e[i]=e[i]||[]).push(n)}}function F(e,t,n,i){function r(s){var l;return o[s]=!0,ot.each(e[s]||[],function(e,s){var c=s(t,n,i);return"string"!=typeof c||a||o[c]?a?!(l=c):void 0:(t.dataTypes.unshift(c),r(c),!1)}),l}var o={},a=e===Wn;return r(t.dataTypes[0])||!o["*"]&&r("*")}function I(e,t){var n,i,r=ot.ajaxSettings.flatOptions||{};for(i in t)void 0!==t[i]&&((r[i]?e:n||(n={}))[i]=t[i]);return n&&ot.extend(!0,e,n),e}function B(e,t,n){for(var i,r,o,a,s=e.contents,l=e.dataTypes;"*"===l[0];)l.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(a in s)if(s[a]&&s[a].test(r)){l.unshift(a);break}if(l[0]in n)o=l[0];else{for(a in n){if(!l[0]||e.converters[a+" "+l[0]]){o=a;break}i||(i=a)}o=o||i}return o?(o!==l[0]&&l.unshift(o),n[o]):void 0}function W(e,t,n,i){var r,o,a,s,l,c={},u=e.dataTypes.slice();if(u[1])for(a in e.converters)c[a.toLowerCase()]=e.converters[a];for(o=u.shift();o;)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!l&&i&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),l=o,o=u.shift())if("*"===o)o=l;else if("*"!==l&&l!==o){if(a=c[l+" "+o]||c["* "+o],!a)for(r in c)if(s=r.split(" "),s[1]===o&&(a=c[l+" "+s[0]]||c["* "+s[0]])){a===!0?a=c[r]:c[r]!==!0&&(o=s[0],u.unshift(s[1]));break}if(a!==!0)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(d){return{state:"parsererror",error:a?d:"No conversion from "+l+" to "+o}}}return{state:"success",data:t}}function U(e,t,n,i){var r;if(ot.isArray(t))ot.each(t,function(t,r){n||Gn.test(e)?i(e,r):U(e+"["+("object"==typeof r?t:"")+"]",r,n,i)});else if(n||"object"!==ot.type(t))i(e,t);else for(r in t)U(e+"["+r+"]",t[r],n,i)}function X(){try{return new e.XMLHttpRequest}catch(t){}}function Z(){try{return new e.ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}function G(e){return ot.isWindow(e)?e:9===e.nodeType?e.defaultView||e.parentWindow:!1}var V=[],Q=V.slice,Y=V.concat,K=V.push,J=V.indexOf,et={},tt=et.toString,nt=et.hasOwnProperty,it={},rt="1.11.1",ot=function(e,t){return new ot.fn.init(e,t)},at=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,st=/^-ms-/,lt=/-([\da-z])/gi,ct=function(e,t){return t.toUpperCase()};ot.fn=ot.prototype={jquery:rt,constructor:ot,selector:"",length:0,toArray:function(){return Q.call(this)},get:function(e){return null!=e?0>e?this[e+this.length]:this[e]:Q.call(this)},pushStack:function(e){var t=ot.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e,t){return ot.each(this,e,t)},map:function(e){return this.pushStack(ot.map(this,function(t,n){return e.call(t,n,t)}))},slice:function(){return this.pushStack(Q.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(0>e?t:0);return this.pushStack(n>=0&&t>n?[this[n]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:K,sort:V.sort,splice:V.splice},ot.extend=ot.fn.extend=function(){var e,t,n,i,r,o,a=arguments[0]||{},s=1,l=arguments.length,c=!1;for("boolean"==typeof a&&(c=a,a=arguments[s]||{},s++),"object"==typeof a||ot.isFunction(a)||(a={}),s===l&&(a=this,s--);l>s;s++)if(null!=(r=arguments[s]))for(i in r)e=a[i],n=r[i],a!==n&&(c&&n&&(ot.isPlainObject(n)||(t=ot.isArray(n)))?(t?(t=!1,o=e&&ot.isArray(e)?e:[]):o=e&&ot.isPlainObject(e)?e:{},a[i]=ot.extend(c,o,n)):void 0!==n&&(a[i]=n));return a},ot.extend({expando:"jQuery"+(rt+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isFunction:function(e){return"function"===ot.type(e)},isArray:Array.isArray||function(e){return"array"===ot.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){return!ot.isArray(e)&&e-parseFloat(e)>=0},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},isPlainObject:function(e){var t;if(!e||"object"!==ot.type(e)||e.nodeType||ot.isWindow(e))return!1;try{if(e.constructor&&!nt.call(e,"constructor")&&!nt.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(n){return!1}if(it.ownLast)for(t in e)return nt.call(e,t);for(t in e);return void 0===t||nt.call(e,t)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?et[tt.call(e)]||"object":typeof e},globalEval:function(t){t&&ot.trim(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(st,"ms-").replace(lt,ct)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t,i){var r,o=0,a=e.length,s=n(e);if(i){if(s)for(;a>o&&(r=t.apply(e[o],i),r!==!1);o++);else for(o in e)if(r=t.apply(e[o],i),r===!1)break}else if(s)for(;a>o&&(r=t.call(e[o],o,e[o]),r!==!1);o++);else for(o in e)if(r=t.call(e[o],o,e[o]),r===!1)break;return e},trim:function(e){return null==e?"":(e+"").replace(at,"")},makeArray:function(e,t){var i=t||[];return null!=e&&(n(Object(e))?ot.merge(i,"string"==typeof e?[e]:e):K.call(i,e)),i},inArray:function(e,t,n){var i;if(t){if(J)return J.call(t,e,n);for(i=t.length,n=n?0>n?Math.max(0,i+n):n:0;i>n;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,t){for(var n=+t.length,i=0,r=e.length;n>i;)e[r++]=t[i++];if(n!==n)for(;void 0!==t[i];)e[r++]=t[i++];return e.length=r,e},grep:function(e,t,n){for(var i,r=[],o=0,a=e.length,s=!n;a>o;o++)i=!t(e[o],o),i!==s&&r.push(e[o]);return r},map:function(e,t,i){var r,o=0,a=e.length,s=n(e),l=[];if(s)for(;a>o;o++)r=t(e[o],o,i),null!=r&&l.push(r);else for(o in e)r=t(e[o],o,i),null!=r&&l.push(r);return Y.apply([],l)},guid:1,proxy:function(e,t){var n,i,r;return"string"==typeof t&&(r=e[t],t=e,e=r),ot.isFunction(e)?(n=Q.call(arguments,2),i=function(){return e.apply(t||this,n.concat(Q.call(arguments)))},i.guid=e.guid=e.guid||ot.guid++,i):void 0},now:function(){return+new Date},support:it}),ot.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(e,t){et["[object "+t+"]"]=t.toLowerCase()});var ut=function(e){function t(e,t,n,i){var r,o,a,s,l,c,d,p,h,m;if((t?t.ownerDocument||t:F)!==R&&j(t),t=t||R,n=n||[],!e||"string"!=typeof e)return n;if(1!==(s=t.nodeType)&&9!==s)return[];if(_&&!i){if(r=yt.exec(e))if(a=r[1]){if(9===s){if(o=t.getElementById(a),!o||!o.parentNode)return n;if(o.id===a)return n.push(o),n}else if(t.ownerDocument&&(o=t.ownerDocument.getElementById(a))&&M(t,o)&&o.id===a)return n.push(o),n}else{if(r[2])return et.apply(n,t.getElementsByTagName(e)),n;if((a=r[3])&&w.getElementsByClassName&&t.getElementsByClassName)return et.apply(n,t.getElementsByClassName(a)),n}if(w.qsa&&(!H||!H.test(e))){if(p=d=z,h=t,m=9===s&&e,1===s&&"object"!==t.nodeName.toLowerCase()){for(c=T(e),(d=t.getAttribute("id"))?p=d.replace(xt,"\\$&"):t.setAttribute("id",p),p="[id='"+p+"'] ",l=c.length;l--;)c[l]=p+f(c[l]);h=bt.test(e)&&u(t.parentNode)||t,m=c.join(",")}if(m)try{return et.apply(n,h.querySelectorAll(m)),n}catch(g){}finally{d||t.removeAttribute("id")}}}return N(e.replace(ct,"$1"),t,n,i)}function n(){function e(n,i){return t.push(n+" ")>C.cacheLength&&delete e[t.shift()],e[n+" "]=i}var t=[];return e}function i(e){return e[z]=!0,e}function r(e){var t=R.createElement("div");try{return!!e(t)}catch(n){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function o(e,t){for(var n=e.split("|"),i=e.length;i--;)C.attrHandle[n[i]]=t}function a(e,t){var n=t&&e,i=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||V)-(~e.sourceIndex||V);if(i)return i;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function s(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function l(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function c(e){return i(function(t){return t=+t,i(function(n,i){for(var r,o=e([],n.length,t),a=o.length;a--;)n[r=o[a]]&&(n[r]=!(i[r]=n[r]))})})}function u(e){return e&&typeof e.getElementsByTagName!==G&&e}function d(){}function f(e){for(var t=0,n=e.length,i="";n>t;t++)i+=e[t].value;return i}function p(e,t,n){var i=t.dir,r=n&&"parentNode"===i,o=B++;return t.first?function(t,n,o){for(;t=t[i];)if(1===t.nodeType||r)return e(t,n,o)}:function(t,n,a){var s,l,c=[I,o];if(a){for(;t=t[i];)if((1===t.nodeType||r)&&e(t,n,a))return!0}else for(;t=t[i];)if(1===t.nodeType||r){if(l=t[z]||(t[z]={}),(s=l[i])&&s[0]===I&&s[1]===o)return c[2]=s[2];if(l[i]=c,c[2]=e(t,n,a))return!0}}}function h(e){return e.length>1?function(t,n,i){for(var r=e.length;r--;)if(!e[r](t,n,i))return!1;return!0}:e[0]}function m(e,n,i){for(var r=0,o=n.length;o>r;r++)t(e,n[r],i);return i}function g(e,t,n,i,r){for(var o,a=[],s=0,l=e.length,c=null!=t;l>s;s++)(o=e[s])&&(!n||n(o,i,r))&&(a.push(o),c&&t.push(s));return a}function v(e,t,n,r,o,a){return r&&!r[z]&&(r=v(r)),o&&!o[z]&&(o=v(o,a)),i(function(i,a,s,l){var c,u,d,f=[],p=[],h=a.length,v=i||m(t||"*",s.nodeType?[s]:s,[]),y=!e||!i&&t?v:g(v,f,e,s,l),b=n?o||(i?e:h||r)?[]:a:y;if(n&&n(y,b,s,l),r)for(c=g(b,p),r(c,[],s,l),u=c.length;u--;)(d=c[u])&&(b[p[u]]=!(y[p[u]]=d));if(i){if(o||e){if(o){for(c=[],u=b.length;u--;)(d=b[u])&&c.push(y[u]=d);o(null,b=[],c,l)}for(u=b.length;u--;)(d=b[u])&&(c=o?nt.call(i,d):f[u])>-1&&(i[c]=!(a[c]=d))}}else b=g(b===a?b.splice(h,b.length):b),o?o(null,a,b,l):et.apply(a,b)})}function y(e){for(var t,n,i,r=e.length,o=C.relative[e[0].type],a=o||C.relative[" "],s=o?1:0,l=p(function(e){return e===t},a,!0),c=p(function(e){return nt.call(t,e)>-1},a,!0),u=[function(e,n,i){return!o&&(i||n!==L)||((t=n).nodeType?l(e,n,i):c(e,n,i))}];r>s;s++)if(n=C.relative[e[s].type])u=[p(h(u),n)];else{if(n=C.filter[e[s].type].apply(null,e[s].matches),n[z]){for(i=++s;r>i&&!C.relative[e[i].type];i++);return v(s>1&&h(u),s>1&&f(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace(ct,"$1"),n,i>s&&y(e.slice(s,i)),r>i&&y(e=e.slice(i)),r>i&&f(e))}u.push(n)}return h(u)}function b(e,n){var r=n.length>0,o=e.length>0,a=function(i,a,s,l,c){var u,d,f,p=0,h="0",m=i&&[],v=[],y=L,b=i||o&&C.find.TAG("*",c),x=I+=null==y?1:Math.random()||.1,w=b.length;for(c&&(L=a!==R&&a);h!==w&&null!=(u=b[h]);h++){if(o&&u){for(d=0;f=e[d++];)if(f(u,a,s)){l.push(u);break}c&&(I=x)}r&&((u=!f&&u)&&p--,i&&m.push(u))}if(p+=h,r&&h!==p){for(d=0;f=n[d++];)f(m,v,a,s);if(i){if(p>0)for(;h--;)m[h]||v[h]||(v[h]=K.call(l));v=g(v)}et.apply(l,v),c&&!i&&v.length>0&&p+n.length>1&&t.uniqueSort(l)}return c&&(I=x,L=y),m};return r?i(a):a}var x,w,C,k,S,T,E,N,L,A,D,j,R,P,_,H,O,q,M,z="sizzle"+-new Date,F=e.document,I=0,B=0,W=n(),U=n(),X=n(),Z=function(e,t){return e===t&&(D=!0),0},G="undefined",V=1<<31,Q={}.hasOwnProperty,Y=[],K=Y.pop,J=Y.push,et=Y.push,tt=Y.slice,nt=Y.indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(this[t]===e)return t;return-1},it="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",rt="[\\x20\\t\\r\\n\\f]",ot="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",at=ot.replace("w","w#"),st="\\["+rt+"*("+ot+")(?:"+rt+"*([*^$|!~]?=)"+rt+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+at+"))|)"+rt+"*\\]",lt=":("+ot+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+st+")*)|.*)\\)|)",ct=new RegExp("^"+rt+"+|((?:^|[^\\\\])(?:\\\\.)*)"+rt+"+$","g"),ut=new RegExp("^"+rt+"*,"+rt+"*"),dt=new RegExp("^"+rt+"*([>+~]|"+rt+")"+rt+"*"),ft=new RegExp("="+rt+"*([^\\]'\"]*?)"+rt+"*\\]","g"),pt=new RegExp(lt),ht=new RegExp("^"+at+"$"),mt={ID:new RegExp("^#("+ot+")"),CLASS:new RegExp("^\\.("+ot+")"),TAG:new RegExp("^("+ot.replace("w","w*")+")"),ATTR:new RegExp("^"+st),PSEUDO:new RegExp("^"+lt),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+rt+"*(even|odd|(([+-]|)(\\d*)n|)"+rt+"*(?:([+-]|)"+rt+"*(\\d+)|))"+rt+"*\\)|)","i"),bool:new RegExp("^(?:"+it+")$","i"),needsContext:new RegExp("^"+rt+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+rt+"*((?:-\\d)?\\d*)"+rt+"*\\)|)(?=[^-]|$)","i")},gt=/^(?:input|select|textarea|button)$/i,vt=/^h\d$/i,$=/^[^{]+\{\s*\[native \w/,yt=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,bt=/[+~]/,xt=/'|\\/g,wt=new RegExp("\\\\([\\da-f]{1,6}"+rt+"?|("+rt+")|.)","ig"),Ct=function(e,t,n){var i="0x"+t-65536;return i!==i||n?t:0>i?String.fromCharCode(i+65536):String.fromCharCode(i>>10|55296,1023&i|56320)};try{et.apply(Y=tt.call(F.childNodes),F.childNodes),Y[F.childNodes.length].nodeType}catch(kt){et={apply:Y.length?function(e,t){J.apply(e,tt.call(t))}:function(e,t){for(var n=e.length,i=0;e[n++]=t[i++];);e.length=n-1}}}w=t.support={},S=t.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?"HTML"!==t.nodeName:!1},j=t.setDocument=function(e){var t,n=e?e.ownerDocument||e:F,i=n.defaultView;return n!==R&&9===n.nodeType&&n.documentElement?(R=n,P=n.documentElement,_=!S(n),i&&i!==i.top&&(i.addEventListener?i.addEventListener("unload",function(){j() +},!1):i.attachEvent&&i.attachEvent("onunload",function(){j()})),w.attributes=r(function(e){return e.className="i",!e.getAttribute("className")}),w.getElementsByTagName=r(function(e){return e.appendChild(n.createComment("")),!e.getElementsByTagName("*").length}),w.getElementsByClassName=$.test(n.getElementsByClassName)&&r(function(e){return e.innerHTML="<div class='a'></div><div class='a i'></div>",e.firstChild.className="i",2===e.getElementsByClassName("i").length}),w.getById=r(function(e){return P.appendChild(e).id=z,!n.getElementsByName||!n.getElementsByName(z).length}),w.getById?(C.find.ID=function(e,t){if(typeof t.getElementById!==G&&_){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},C.filter.ID=function(e){var t=e.replace(wt,Ct);return function(e){return e.getAttribute("id")===t}}):(delete C.find.ID,C.filter.ID=function(e){var t=e.replace(wt,Ct);return function(e){var n=typeof e.getAttributeNode!==G&&e.getAttributeNode("id");return n&&n.value===t}}),C.find.TAG=w.getElementsByTagName?function(e,t){return typeof t.getElementsByTagName!==G?t.getElementsByTagName(e):void 0}:function(e,t){var n,i=[],r=0,o=t.getElementsByTagName(e);if("*"===e){for(;n=o[r++];)1===n.nodeType&&i.push(n);return i}return o},C.find.CLASS=w.getElementsByClassName&&function(e,t){return typeof t.getElementsByClassName!==G&&_?t.getElementsByClassName(e):void 0},O=[],H=[],(w.qsa=$.test(n.querySelectorAll))&&(r(function(e){e.innerHTML="<select msallowclip=''><option selected=''></option></select>",e.querySelectorAll("[msallowclip^='']").length&&H.push("[*^$]="+rt+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||H.push("\\["+rt+"*(?:value|"+it+")"),e.querySelectorAll(":checked").length||H.push(":checked")}),r(function(e){var t=n.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&H.push("name"+rt+"*[*^$|!~]?="),e.querySelectorAll(":enabled").length||H.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),H.push(",.*:")})),(w.matchesSelector=$.test(q=P.matches||P.webkitMatchesSelector||P.mozMatchesSelector||P.oMatchesSelector||P.msMatchesSelector))&&r(function(e){w.disconnectedMatch=q.call(e,"div"),q.call(e,"[s!='']:x"),O.push("!=",lt)}),H=H.length&&new RegExp(H.join("|")),O=O.length&&new RegExp(O.join("|")),t=$.test(P.compareDocumentPosition),M=t||$.test(P.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,i=t&&t.parentNode;return e===i||!(!i||1!==i.nodeType||!(n.contains?n.contains(i):e.compareDocumentPosition&&16&e.compareDocumentPosition(i)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},Z=t?function(e,t){if(e===t)return D=!0,0;var i=!e.compareDocumentPosition-!t.compareDocumentPosition;return i?i:(i=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1,1&i||!w.sortDetached&&t.compareDocumentPosition(e)===i?e===n||e.ownerDocument===F&&M(F,e)?-1:t===n||t.ownerDocument===F&&M(F,t)?1:A?nt.call(A,e)-nt.call(A,t):0:4&i?-1:1)}:function(e,t){if(e===t)return D=!0,0;var i,r=0,o=e.parentNode,s=t.parentNode,l=[e],c=[t];if(!o||!s)return e===n?-1:t===n?1:o?-1:s?1:A?nt.call(A,e)-nt.call(A,t):0;if(o===s)return a(e,t);for(i=e;i=i.parentNode;)l.unshift(i);for(i=t;i=i.parentNode;)c.unshift(i);for(;l[r]===c[r];)r++;return r?a(l[r],c[r]):l[r]===F?-1:c[r]===F?1:0},n):R},t.matches=function(e,n){return t(e,null,null,n)},t.matchesSelector=function(e,n){if((e.ownerDocument||e)!==R&&j(e),n=n.replace(ft,"='$1']"),!(!w.matchesSelector||!_||O&&O.test(n)||H&&H.test(n)))try{var i=q.call(e,n);if(i||w.disconnectedMatch||e.document&&11!==e.document.nodeType)return i}catch(r){}return t(n,R,null,[e]).length>0},t.contains=function(e,t){return(e.ownerDocument||e)!==R&&j(e),M(e,t)},t.attr=function(e,t){(e.ownerDocument||e)!==R&&j(e);var n=C.attrHandle[t.toLowerCase()],i=n&&Q.call(C.attrHandle,t.toLowerCase())?n(e,t,!_):void 0;return void 0!==i?i:w.attributes||!_?e.getAttribute(t):(i=e.getAttributeNode(t))&&i.specified?i.value:null},t.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},t.uniqueSort=function(e){var t,n=[],i=0,r=0;if(D=!w.detectDuplicates,A=!w.sortStable&&e.slice(0),e.sort(Z),D){for(;t=e[r++];)t===e[r]&&(i=n.push(r));for(;i--;)e.splice(n[i],1)}return A=null,e},k=t.getText=function(e){var t,n="",i=0,r=e.nodeType;if(r){if(1===r||9===r||11===r){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=k(e)}else if(3===r||4===r)return e.nodeValue}else for(;t=e[i++];)n+=k(t);return n},C=t.selectors={cacheLength:50,createPseudo:i,match:mt,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(wt,Ct),e[3]=(e[3]||e[4]||e[5]||"").replace(wt,Ct),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||t.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&t.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return mt.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&pt.test(n)&&(t=T(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(wt,Ct).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=W[e+" "];return t||(t=new RegExp("(^|"+rt+")"+e+"("+rt+"|$)"))&&W(e,function(e){return t.test("string"==typeof e.className&&e.className||typeof e.getAttribute!==G&&e.getAttribute("class")||"")})},ATTR:function(e,n,i){return function(r){var o=t.attr(r,e);return null==o?"!="===n:n?(o+="","="===n?o===i:"!="===n?o!==i:"^="===n?i&&0===o.indexOf(i):"*="===n?i&&o.indexOf(i)>-1:"$="===n?i&&o.slice(-i.length)===i:"~="===n?(" "+o+" ").indexOf(i)>-1:"|="===n?o===i||o.slice(0,i.length+1)===i+"-":!1):!0}},CHILD:function(e,t,n,i,r){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===i&&0===r?function(e){return!!e.parentNode}:function(t,n,l){var c,u,d,f,p,h,m=o!==a?"nextSibling":"previousSibling",g=t.parentNode,v=s&&t.nodeName.toLowerCase(),y=!l&&!s;if(g){if(o){for(;m;){for(d=t;d=d[m];)if(s?d.nodeName.toLowerCase()===v:1===d.nodeType)return!1;h=m="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?g.firstChild:g.lastChild],a&&y){for(u=g[z]||(g[z]={}),c=u[e]||[],p=c[0]===I&&c[1],f=c[0]===I&&c[2],d=p&&g.childNodes[p];d=++p&&d&&d[m]||(f=p=0)||h.pop();)if(1===d.nodeType&&++f&&d===t){u[e]=[I,p,f];break}}else if(y&&(c=(t[z]||(t[z]={}))[e])&&c[0]===I)f=c[1];else for(;(d=++p&&d&&d[m]||(f=p=0)||h.pop())&&((s?d.nodeName.toLowerCase()!==v:1!==d.nodeType)||!++f||(y&&((d[z]||(d[z]={}))[e]=[I,f]),d!==t)););return f-=r,f===i||f%i===0&&f/i>=0}}},PSEUDO:function(e,n){var r,o=C.pseudos[e]||C.setFilters[e.toLowerCase()]||t.error("unsupported pseudo: "+e);return o[z]?o(n):o.length>1?(r=[e,e,"",n],C.setFilters.hasOwnProperty(e.toLowerCase())?i(function(e,t){for(var i,r=o(e,n),a=r.length;a--;)i=nt.call(e,r[a]),e[i]=!(t[i]=r[a])}):function(e){return o(e,0,r)}):o}},pseudos:{not:i(function(e){var t=[],n=[],r=E(e.replace(ct,"$1"));return r[z]?i(function(e,t,n,i){for(var o,a=r(e,null,i,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),!n.pop()}}),has:i(function(e){return function(n){return t(e,n).length>0}}),contains:i(function(e){return function(t){return(t.textContent||t.innerText||k(t)).indexOf(e)>-1}}),lang:i(function(e){return ht.test(e||"")||t.error("unsupported lang: "+e),e=e.replace(wt,Ct).toLowerCase(),function(t){var n;do if(n=_?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===P},focus:function(e){return e===R.activeElement&&(!R.hasFocus||R.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!C.pseudos.empty(e)},header:function(e){return vt.test(e.nodeName)},input:function(e){return gt.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:c(function(){return[0]}),last:c(function(e,t){return[t-1]}),eq:c(function(e,t,n){return[0>n?n+t:n]}),even:c(function(e,t){for(var n=0;t>n;n+=2)e.push(n);return e}),odd:c(function(e,t){for(var n=1;t>n;n+=2)e.push(n);return e}),lt:c(function(e,t,n){for(var i=0>n?n+t:n;--i>=0;)e.push(i);return e}),gt:c(function(e,t,n){for(var i=0>n?n+t:n;++i<t;)e.push(i);return e})}},C.pseudos.nth=C.pseudos.eq;for(x in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})C.pseudos[x]=s(x);for(x in{submit:!0,reset:!0})C.pseudos[x]=l(x);return d.prototype=C.filters=C.pseudos,C.setFilters=new d,T=t.tokenize=function(e,n){var i,r,o,a,s,l,c,u=U[e+" "];if(u)return n?0:u.slice(0);for(s=e,l=[],c=C.preFilter;s;){(!i||(r=ut.exec(s)))&&(r&&(s=s.slice(r[0].length)||s),l.push(o=[])),i=!1,(r=dt.exec(s))&&(i=r.shift(),o.push({value:i,type:r[0].replace(ct," ")}),s=s.slice(i.length));for(a in C.filter)!(r=mt[a].exec(s))||c[a]&&!(r=c[a](r))||(i=r.shift(),o.push({value:i,type:a,matches:r}),s=s.slice(i.length));if(!i)break}return n?s.length:s?t.error(e):U(e,l).slice(0)},E=t.compile=function(e,t){var n,i=[],r=[],o=X[e+" "];if(!o){for(t||(t=T(e)),n=t.length;n--;)o=y(t[n]),o[z]?i.push(o):r.push(o);o=X(e,b(r,i)),o.selector=e}return o},N=t.select=function(e,t,n,i){var r,o,a,s,l,c="function"==typeof e&&e,d=!i&&T(e=c.selector||e);if(n=n||[],1===d.length){if(o=d[0]=d[0].slice(0),o.length>2&&"ID"===(a=o[0]).type&&w.getById&&9===t.nodeType&&_&&C.relative[o[1].type]){if(t=(C.find.ID(a.matches[0].replace(wt,Ct),t)||[])[0],!t)return n;c&&(t=t.parentNode),e=e.slice(o.shift().value.length)}for(r=mt.needsContext.test(e)?0:o.length;r--&&(a=o[r],!C.relative[s=a.type]);)if((l=C.find[s])&&(i=l(a.matches[0].replace(wt,Ct),bt.test(o[0].type)&&u(t.parentNode)||t))){if(o.splice(r,1),e=i.length&&f(o),!e)return et.apply(n,i),n;break}}return(c||E(e,d))(i,t,!_,n,bt.test(e)&&u(t.parentNode)||t),n},w.sortStable=z.split("").sort(Z).join("")===z,w.detectDuplicates=!!D,j(),w.sortDetached=r(function(e){return 1&e.compareDocumentPosition(R.createElement("div"))}),r(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||o("type|href|height|width",function(e,t,n){return n?void 0:e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),w.attributes&&r(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||o("value",function(e,t,n){return n||"input"!==e.nodeName.toLowerCase()?void 0:e.defaultValue}),r(function(e){return null==e.getAttribute("disabled")})||o(it,function(e,t,n){var i;return n?void 0:e[t]===!0?t.toLowerCase():(i=e.getAttributeNode(t))&&i.specified?i.value:null}),t}(e);ot.find=ut,ot.expr=ut.selectors,ot.expr[":"]=ot.expr.pseudos,ot.unique=ut.uniqueSort,ot.text=ut.getText,ot.isXMLDoc=ut.isXML,ot.contains=ut.contains;var dt=ot.expr.match.needsContext,ft=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,pt=/^.[^:#\[\.,]*$/;ot.filter=function(e,t,n){var i=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===i.nodeType?ot.find.matchesSelector(i,e)?[i]:[]:ot.find.matches(e,ot.grep(t,function(e){return 1===e.nodeType}))},ot.fn.extend({find:function(e){var t,n=[],i=this,r=i.length;if("string"!=typeof e)return this.pushStack(ot(e).filter(function(){for(t=0;r>t;t++)if(ot.contains(i[t],this))return!0}));for(t=0;r>t;t++)ot.find(e,i[t],n);return n=this.pushStack(r>1?ot.unique(n):n),n.selector=this.selector?this.selector+" "+e:e,n},filter:function(e){return this.pushStack(i(this,e||[],!1))},not:function(e){return this.pushStack(i(this,e||[],!0))},is:function(e){return!!i(this,"string"==typeof e&&dt.test(e)?ot(e):e||[],!1).length}});var ht,mt=e.document,gt=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,vt=ot.fn.init=function(e,t){var n,i;if(!e)return this;if("string"==typeof e){if(n="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:gt.exec(e),!n||!n[1]&&t)return!t||t.jquery?(t||ht).find(e):this.constructor(t).find(e);if(n[1]){if(t=t instanceof ot?t[0]:t,ot.merge(this,ot.parseHTML(n[1],t&&t.nodeType?t.ownerDocument||t:mt,!0)),ft.test(n[1])&&ot.isPlainObject(t))for(n in t)ot.isFunction(this[n])?this[n](t[n]):this.attr(n,t[n]);return this}if(i=mt.getElementById(n[2]),i&&i.parentNode){if(i.id!==n[2])return ht.find(e);this.length=1,this[0]=i}return this.context=mt,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):ot.isFunction(e)?"undefined"!=typeof ht.ready?ht.ready(e):e(ot):(void 0!==e.selector&&(this.selector=e.selector,this.context=e.context),ot.makeArray(e,this))};vt.prototype=ot.fn,ht=ot(mt);var yt=/^(?:parents|prev(?:Until|All))/,bt={children:!0,contents:!0,next:!0,prev:!0};ot.extend({dir:function(e,t,n){for(var i=[],r=e[t];r&&9!==r.nodeType&&(void 0===n||1!==r.nodeType||!ot(r).is(n));)1===r.nodeType&&i.push(r),r=r[t];return i},sibling:function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}}),ot.fn.extend({has:function(e){var t,n=ot(e,this),i=n.length;return this.filter(function(){for(t=0;i>t;t++)if(ot.contains(this,n[t]))return!0})},closest:function(e,t){for(var n,i=0,r=this.length,o=[],a=dt.test(e)||"string"!=typeof e?ot(e,t||this.context):0;r>i;i++)for(n=this[i];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&ot.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?ot.unique(o):o)},index:function(e){return e?"string"==typeof e?ot.inArray(this[0],ot(e)):ot.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(ot.unique(ot.merge(this.get(),ot(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),ot.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return ot.dir(e,"parentNode")},parentsUntil:function(e,t,n){return ot.dir(e,"parentNode",n)},next:function(e){return r(e,"nextSibling")},prev:function(e){return r(e,"previousSibling")},nextAll:function(e){return ot.dir(e,"nextSibling")},prevAll:function(e){return ot.dir(e,"previousSibling")},nextUntil:function(e,t,n){return ot.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return ot.dir(e,"previousSibling",n)},siblings:function(e){return ot.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return ot.sibling(e.firstChild)},contents:function(e){return ot.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:ot.merge([],e.childNodes)}},function(e,t){ot.fn[e]=function(n,i){var r=ot.map(this,t,n);return"Until"!==e.slice(-5)&&(i=n),i&&"string"==typeof i&&(r=ot.filter(i,r)),this.length>1&&(bt[e]||(r=ot.unique(r)),yt.test(e)&&(r=r.reverse())),this.pushStack(r)}});var xt=/\S+/g,wt={};ot.Callbacks=function(e){e="string"==typeof e?wt[e]||o(e):ot.extend({},e);var t,n,i,r,a,s,l=[],c=!e.once&&[],u=function(o){for(n=e.memory&&o,i=!0,a=s||0,s=0,r=l.length,t=!0;l&&r>a;a++)if(l[a].apply(o[0],o[1])===!1&&e.stopOnFalse){n=!1;break}t=!1,l&&(c?c.length&&u(c.shift()):n?l=[]:d.disable())},d={add:function(){if(l){var i=l.length;!function o(t){ot.each(t,function(t,n){var i=ot.type(n);"function"===i?e.unique&&d.has(n)||l.push(n):n&&n.length&&"string"!==i&&o(n)})}(arguments),t?r=l.length:n&&(s=i,u(n))}return this},remove:function(){return l&&ot.each(arguments,function(e,n){for(var i;(i=ot.inArray(n,l,i))>-1;)l.splice(i,1),t&&(r>=i&&r--,a>=i&&a--)}),this},has:function(e){return e?ot.inArray(e,l)>-1:!(!l||!l.length)},empty:function(){return l=[],r=0,this},disable:function(){return l=c=n=void 0,this},disabled:function(){return!l},lock:function(){return c=void 0,n||d.disable(),this},locked:function(){return!c},fireWith:function(e,n){return!l||i&&!c||(n=n||[],n=[e,n.slice?n.slice():n],t?c.push(n):u(n)),this},fire:function(){return d.fireWith(this,arguments),this},fired:function(){return!!i}};return d},ot.extend({Deferred:function(e){var t=[["resolve","done",ot.Callbacks("once memory"),"resolved"],["reject","fail",ot.Callbacks("once memory"),"rejected"],["notify","progress",ot.Callbacks("memory")]],n="pending",i={state:function(){return n},always:function(){return r.done(arguments).fail(arguments),this},then:function(){var e=arguments;return ot.Deferred(function(n){ot.each(t,function(t,o){var a=ot.isFunction(e[t])&&e[t];r[o[1]](function(){var e=a&&a.apply(this,arguments);e&&ot.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[o[0]+"With"](this===i?n.promise():this,a?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?ot.extend(e,i):i}},r={};return i.pipe=i.then,ot.each(t,function(e,o){var a=o[2],s=o[3];i[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),r[o[0]]=function(){return r[o[0]+"With"](this===r?i:this,arguments),this},r[o[0]+"With"]=a.fireWith}),i.promise(r),e&&e.call(r,r),r},when:function(e){var t=0,n=Q.call(arguments),i=n.length,r=1!==i||e&&ot.isFunction(e.promise)?i:0,o=1===r?e:ot.Deferred(),a=function(e,t,n){return function(i){t[e]=this,n[e]=arguments.length>1?Q.call(arguments):i,n===s?o.notifyWith(t,n):--r||o.resolveWith(t,n)}},s,l,c;if(i>1)for(s=new Array(i),l=new Array(i),c=new Array(i);i>t;t++)n[t]&&ot.isFunction(n[t].promise)?n[t].promise().done(a(t,c,n)).fail(o.reject).progress(a(t,l,s)):--r;return r||o.resolveWith(c,n),o.promise()}});var Ct;ot.fn.ready=function(e){return ot.ready.promise().done(e),this},ot.extend({isReady:!1,readyWait:1,holdReady:function(e){e?ot.readyWait++:ot.ready(!0)},ready:function(e){if(e===!0?!--ot.readyWait:!ot.isReady){if(!mt.body)return setTimeout(ot.ready);ot.isReady=!0,e!==!0&&--ot.readyWait>0||(Ct.resolveWith(mt,[ot]),ot.fn.triggerHandler&&(ot(mt).triggerHandler("ready"),ot(mt).off("ready")))}}}),ot.ready.promise=function(t){if(!Ct)if(Ct=ot.Deferred(),"complete"===mt.readyState)setTimeout(ot.ready);else if(mt.addEventListener)mt.addEventListener("DOMContentLoaded",s,!1),e.addEventListener("load",s,!1);else{mt.attachEvent("onreadystatechange",s),e.attachEvent("onload",s);var n=!1;try{n=null==e.frameElement&&mt.documentElement}catch(i){}n&&n.doScroll&&!function r(){if(!ot.isReady){try{n.doScroll("left")}catch(e){return setTimeout(r,50)}a(),ot.ready()}}()}return Ct.promise(t)};var kt="undefined",$t;for($t in ot(it))break;it.ownLast="0"!==$t,it.inlineBlockNeedsLayout=!1,ot(function(){var e,t,n,i;n=mt.getElementsByTagName("body")[0],n&&n.style&&(t=mt.createElement("div"),i=mt.createElement("div"),i.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(i).appendChild(t),typeof t.style.zoom!==kt&&(t.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",it.inlineBlockNeedsLayout=e=3===t.offsetWidth,e&&(n.style.zoom=1)),n.removeChild(i))}),function(){var e=mt.createElement("div");if(null==it.deleteExpando){it.deleteExpando=!0;try{delete e.test}catch(t){it.deleteExpando=!1}}e=null}(),ot.acceptData=function(e){var t=ot.noData[(e.nodeName+" ").toLowerCase()],n=+e.nodeType||1;return 1!==n&&9!==n?!1:!t||t!==!0&&e.getAttribute("classid")===t};var St=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Tt=/([A-Z])/g;ot.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return e=e.nodeType?ot.cache[e[ot.expando]]:e[ot.expando],!!e&&!c(e)},data:function(e,t,n){return u(e,t,n)},removeData:function(e,t){return d(e,t)},_data:function(e,t,n){return u(e,t,n,!0)},_removeData:function(e,t){return d(e,t,!0)}}),ot.fn.extend({data:function(e,t){var n,i,r,o=this[0],a=o&&o.attributes;if(void 0===e){if(this.length&&(r=ot.data(o),1===o.nodeType&&!ot._data(o,"parsedAttrs"))){for(n=a.length;n--;)a[n]&&(i=a[n].name,0===i.indexOf("data-")&&(i=ot.camelCase(i.slice(5)),l(o,i,r[i])));ot._data(o,"parsedAttrs",!0)}return r}return"object"==typeof e?this.each(function(){ot.data(this,e)}):arguments.length>1?this.each(function(){ot.data(this,e,t)}):o?l(o,e,ot.data(o,e)):void 0},removeData:function(e){return this.each(function(){ot.removeData(this,e)})}}),ot.extend({queue:function(e,t,n){var i;return e?(t=(t||"fx")+"queue",i=ot._data(e,t),n&&(!i||ot.isArray(n)?i=ot._data(e,t,ot.makeArray(n)):i.push(n)),i||[]):void 0},dequeue:function(e,t){t=t||"fx";var n=ot.queue(e,t),i=n.length,r=n.shift(),o=ot._queueHooks(e,t),a=function(){ot.dequeue(e,t)};"inprogress"===r&&(r=n.shift(),i--),r&&("fx"===t&&n.unshift("inprogress"),delete o.stop,r.call(e,a,o)),!i&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return ot._data(e,n)||ot._data(e,n,{empty:ot.Callbacks("once memory").add(function(){ot._removeData(e,t+"queue"),ot._removeData(e,n)})})}}),ot.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?ot.queue(this[0],e):void 0===t?this:this.each(function(){var n=ot.queue(this,e,t);ot._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&ot.dequeue(this,e)})},dequeue:function(e){return this.each(function(){ot.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,i=1,r=ot.Deferred(),o=this,a=this.length,s=function(){--i||r.resolveWith(o,[o])};for("string"!=typeof e&&(t=e,e=void 0),e=e||"fx";a--;)n=ot._data(o[a],e+"queueHooks"),n&&n.empty&&(i++,n.empty.add(s));return s(),r.promise(t)}});var Et=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,Nt=["Top","Right","Bottom","Left"],Lt=function(e,t){return e=t||e,"none"===ot.css(e,"display")||!ot.contains(e.ownerDocument,e)},At=ot.access=function(e,t,n,i,r,o,a){var s=0,l=e.length,c=null==n;if("object"===ot.type(n)){r=!0;for(s in n)ot.access(e,t,s,n[s],!0,o,a)}else if(void 0!==i&&(r=!0,ot.isFunction(i)||(a=!0),c&&(a?(t.call(e,i),t=null):(c=t,t=function(e,t,n){return c.call(ot(e),n)})),t))for(;l>s;s++)t(e[s],n,a?i:i.call(e[s],s,t(e[s],n)));return r?e:c?t.call(e):l?t(e[0],n):o},Dt=/^(?:checkbox|radio)$/i;!function(){var e=mt.createElement("input"),t=mt.createElement("div"),n=mt.createDocumentFragment();if(t.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",it.leadingWhitespace=3===t.firstChild.nodeType,it.tbody=!t.getElementsByTagName("tbody").length,it.htmlSerialize=!!t.getElementsByTagName("link").length,it.html5Clone="<:nav></:nav>"!==mt.createElement("nav").cloneNode(!0).outerHTML,e.type="checkbox",e.checked=!0,n.appendChild(e),it.appendChecked=e.checked,t.innerHTML="<textarea>x</textarea>",it.noCloneChecked=!!t.cloneNode(!0).lastChild.defaultValue,n.appendChild(t),t.innerHTML="<input type='radio' checked='checked' name='t'/>",it.checkClone=t.cloneNode(!0).cloneNode(!0).lastChild.checked,it.noCloneEvent=!0,t.attachEvent&&(t.attachEvent("onclick",function(){it.noCloneEvent=!1}),t.cloneNode(!0).click()),null==it.deleteExpando){it.deleteExpando=!0;try{delete t.test}catch(i){it.deleteExpando=!1}}}(),function(){var t,n,i=mt.createElement("div");for(t in{submit:!0,change:!0,focusin:!0})n="on"+t,(it[t+"Bubbles"]=n in e)||(i.setAttribute(n,"t"),it[t+"Bubbles"]=i.attributes[n].expando===!1);i=null}();var jt=/^(?:input|select|textarea)$/i,Rt=/^key/,Pt=/^(?:mouse|pointer|contextmenu)|click/,$=/^(?:focusinfocus|focusoutblur)$/,_t=/^([^.]*)(?:\.(.+)|)$/;ot.event={global:{},add:function(e,t,n,i,r){var o,a,s,l,c,u,d,f,p,h,m,g=ot._data(e);if(g){for(n.handler&&(l=n,n=l.handler,r=l.selector),n.guid||(n.guid=ot.guid++),(a=g.events)||(a=g.events={}),(u=g.handle)||(u=g.handle=function(e){return typeof ot===kt||e&&ot.event.triggered===e.type?void 0:ot.event.dispatch.apply(u.elem,arguments)},u.elem=e),t=(t||"").match(xt)||[""],s=t.length;s--;)o=_t.exec(t[s])||[],p=m=o[1],h=(o[2]||"").split(".").sort(),p&&(c=ot.event.special[p]||{},p=(r?c.delegateType:c.bindType)||p,c=ot.event.special[p]||{},d=ot.extend({type:p,origType:m,data:i,handler:n,guid:n.guid,selector:r,needsContext:r&&ot.expr.match.needsContext.test(r),namespace:h.join(".")},l),(f=a[p])||(f=a[p]=[],f.delegateCount=0,c.setup&&c.setup.call(e,i,h,u)!==!1||(e.addEventListener?e.addEventListener(p,u,!1):e.attachEvent&&e.attachEvent("on"+p,u))),c.add&&(c.add.call(e,d),d.handler.guid||(d.handler.guid=n.guid)),r?f.splice(f.delegateCount++,0,d):f.push(d),ot.event.global[p]=!0);e=null}},remove:function(e,t,n,i,r){var o,a,s,l,c,u,d,f,p,h,m,g=ot.hasData(e)&&ot._data(e);if(g&&(u=g.events)){for(t=(t||"").match(xt)||[""],c=t.length;c--;)if(s=_t.exec(t[c])||[],p=m=s[1],h=(s[2]||"").split(".").sort(),p){for(d=ot.event.special[p]||{},p=(i?d.delegateType:d.bindType)||p,f=u[p]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),l=o=f.length;o--;)a=f[o],!r&&m!==a.origType||n&&n.guid!==a.guid||s&&!s.test(a.namespace)||i&&i!==a.selector&&("**"!==i||!a.selector)||(f.splice(o,1),a.selector&&f.delegateCount--,d.remove&&d.remove.call(e,a));l&&!f.length&&(d.teardown&&d.teardown.call(e,h,g.handle)!==!1||ot.removeEvent(e,p,g.handle),delete u[p])}else for(p in u)ot.event.remove(e,p+t[c],n,i,!0);ot.isEmptyObject(u)&&(delete g.handle,ot._removeData(e,"events"))}},trigger:function(t,n,i,r){var o,a,s,l,c,u,d,f=[i||mt],p=nt.call(t,"type")?t.type:t,h=nt.call(t,"namespace")?t.namespace.split("."):[];if(s=u=i=i||mt,3!==i.nodeType&&8!==i.nodeType&&!$.test(p+ot.event.triggered)&&(p.indexOf(".")>=0&&(h=p.split("."),p=h.shift(),h.sort()),a=p.indexOf(":")<0&&"on"+p,t=t[ot.expando]?t:new ot.Event(p,"object"==typeof t&&t),t.isTrigger=r?2:3,t.namespace=h.join("."),t.namespace_re=t.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=i),n=null==n?[t]:ot.makeArray(n,[t]),c=ot.event.special[p]||{},r||!c.trigger||c.trigger.apply(i,n)!==!1)){if(!r&&!c.noBubble&&!ot.isWindow(i)){for(l=c.delegateType||p,$.test(l+p)||(s=s.parentNode);s;s=s.parentNode)f.push(s),u=s;u===(i.ownerDocument||mt)&&f.push(u.defaultView||u.parentWindow||e)}for(d=0;(s=f[d++])&&!t.isPropagationStopped();)t.type=d>1?l:c.bindType||p,o=(ot._data(s,"events")||{})[t.type]&&ot._data(s,"handle"),o&&o.apply(s,n),o=a&&s[a],o&&o.apply&&ot.acceptData(s)&&(t.result=o.apply(s,n),t.result===!1&&t.preventDefault());if(t.type=p,!r&&!t.isDefaultPrevented()&&(!c._default||c._default.apply(f.pop(),n)===!1)&&ot.acceptData(i)&&a&&i[p]&&!ot.isWindow(i)){u=i[a],u&&(i[a]=null),ot.event.triggered=p;try{i[p]()}catch(m){}ot.event.triggered=void 0,u&&(i[a]=u)}return t.result}},dispatch:function(e){e=ot.event.fix(e);var t,n,i,r,o,a=[],s=Q.call(arguments),l=(ot._data(this,"events")||{})[e.type]||[],c=ot.event.special[e.type]||{};if(s[0]=e,e.delegateTarget=this,!c.preDispatch||c.preDispatch.call(this,e)!==!1){for(a=ot.event.handlers.call(this,e,l),t=0;(r=a[t++])&&!e.isPropagationStopped();)for(e.currentTarget=r.elem,o=0;(i=r.handlers[o++])&&!e.isImmediatePropagationStopped();)(!e.namespace_re||e.namespace_re.test(i.namespace))&&(e.handleObj=i,e.data=i.data,n=((ot.event.special[i.origType]||{}).handle||i.handler).apply(r.elem,s),void 0!==n&&(e.result=n)===!1&&(e.preventDefault(),e.stopPropagation()));return c.postDispatch&&c.postDispatch.call(this,e),e.result}},handlers:function(e,t){var n,i,r,o,a=[],s=t.delegateCount,l=e.target;if(s&&l.nodeType&&(!e.button||"click"!==e.type))for(;l!=this;l=l.parentNode||this)if(1===l.nodeType&&(l.disabled!==!0||"click"!==e.type)){for(r=[],o=0;s>o;o++)i=t[o],n=i.selector+" ",void 0===r[n]&&(r[n]=i.needsContext?ot(n,this).index(l)>=0:ot.find(n,this,null,[l]).length),r[n]&&r.push(i);r.length&&a.push({elem:l,handlers:r})}return s<t.length&&a.push({elem:this,handlers:t.slice(s)}),a},fix:function(e){if(e[ot.expando])return e;var t,n,i,r=e.type,o=e,a=this.fixHooks[r];for(a||(this.fixHooks[r]=a=Pt.test(r)?this.mouseHooks:Rt.test(r)?this.keyHooks:{}),i=a.props?this.props.concat(a.props):this.props,e=new ot.Event(o),t=i.length;t--;)n=i[t],e[n]=o[n];return e.target||(e.target=o.srcElement||mt),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,a.filter?a.filter(e,o):e},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,t){var n,i,r,o=t.button,a=t.fromElement;return null==e.pageX&&null!=t.clientX&&(i=e.target.ownerDocument||mt,r=i.documentElement,n=i.body,e.pageX=t.clientX+(r&&r.scrollLeft||n&&n.scrollLeft||0)-(r&&r.clientLeft||n&&n.clientLeft||0),e.pageY=t.clientY+(r&&r.scrollTop||n&&n.scrollTop||0)-(r&&r.clientTop||n&&n.clientTop||0)),!e.relatedTarget&&a&&(e.relatedTarget=a===e.target?t.toElement:a),e.which||void 0===o||(e.which=1&o?1:2&o?3:4&o?2:0),e}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==h()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){return this===h()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return ot.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):void 0},_default:function(e){return ot.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n,i){var r=ot.extend(new ot.Event,n,{type:e,isSimulated:!0,originalEvent:{}});i?ot.event.trigger(r,null,t):ot.event.dispatch.call(t,r),r.isDefaultPrevented()&&n.preventDefault()}},ot.removeEvent=mt.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var i="on"+t;e.detachEvent&&(typeof e[i]===kt&&(e[i]=null),e.detachEvent(i,n))},ot.Event=function(e,t){return this instanceof ot.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&e.returnValue===!1?f:p):this.type=e,t&&ot.extend(this,t),this.timeStamp=e&&e.timeStamp||ot.now(),void(this[ot.expando]=!0)):new ot.Event(e,t)},ot.Event.prototype={isDefaultPrevented:p,isPropagationStopped:p,isImmediatePropagationStopped:p,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=f,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=f,e&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=f,e&&e.stopImmediatePropagation&&e.stopImmediatePropagation(),this.stopPropagation()}},ot.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,t){ot.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,i=this,r=e.relatedTarget,o=e.handleObj;return(!r||r!==i&&!ot.contains(i,r))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),it.submitBubbles||(ot.event.special.submit={setup:function(){return ot.nodeName(this,"form")?!1:void ot.event.add(this,"click._submit keypress._submit",function(e){var t=e.target,n=ot.nodeName(t,"input")||ot.nodeName(t,"button")?t.form:void 0;n&&!ot._data(n,"submitBubbles")&&(ot.event.add(n,"submit._submit",function(e){e._submit_bubble=!0}),ot._data(n,"submitBubbles",!0))})},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&ot.event.simulate("submit",this.parentNode,e,!0)) +},teardown:function(){return ot.nodeName(this,"form")?!1:void ot.event.remove(this,"._submit")}}),it.changeBubbles||(ot.event.special.change={setup:function(){return jt.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(ot.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._just_changed=!0)}),ot.event.add(this,"click._change",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),ot.event.simulate("change",this,e,!0)})),!1):void ot.event.add(this,"beforeactivate._change",function(e){var t=e.target;jt.test(t.nodeName)&&!ot._data(t,"changeBubbles")&&(ot.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||ot.event.simulate("change",this.parentNode,e,!0)}),ot._data(t,"changeBubbles",!0))})},handle:function(e){var t=e.target;return this!==t||e.isSimulated||e.isTrigger||"radio"!==t.type&&"checkbox"!==t.type?e.handleObj.handler.apply(this,arguments):void 0},teardown:function(){return ot.event.remove(this,"._change"),!jt.test(this.nodeName)}}),it.focusinBubbles||ot.each({focus:"focusin",blur:"focusout"},function(e,t){var n=function(e){ot.event.simulate(t,e.target,ot.event.fix(e),!0)};ot.event.special[t]={setup:function(){var i=this.ownerDocument||this,r=ot._data(i,t);r||i.addEventListener(e,n,!0),ot._data(i,t,(r||0)+1)},teardown:function(){var i=this.ownerDocument||this,r=ot._data(i,t)-1;r?ot._data(i,t,r):(i.removeEventListener(e,n,!0),ot._removeData(i,t))}}}),ot.fn.extend({on:function(e,t,n,i,r){var o,a;if("object"==typeof e){"string"!=typeof t&&(n=n||t,t=void 0);for(o in e)this.on(o,t,n,e[o],r);return this}if(null==n&&null==i?(i=t,n=t=void 0):null==i&&("string"==typeof t?(i=n,n=void 0):(i=n,n=t,t=void 0)),i===!1)i=p;else if(!i)return this;return 1===r&&(a=i,i=function(e){return ot().off(e),a.apply(this,arguments)},i.guid=a.guid||(a.guid=ot.guid++)),this.each(function(){ot.event.add(this,e,i,n,t)})},one:function(e,t,n,i){return this.on(e,t,n,i,1)},off:function(e,t,n){var i,r;if(e&&e.preventDefault&&e.handleObj)return i=e.handleObj,ot(e.delegateTarget).off(i.namespace?i.origType+"."+i.namespace:i.origType,i.selector,i.handler),this;if("object"==typeof e){for(r in e)this.off(r,t,e[r]);return this}return(t===!1||"function"==typeof t)&&(n=t,t=void 0),n===!1&&(n=p),this.each(function(){ot.event.remove(this,e,n,t)})},trigger:function(e,t){return this.each(function(){ot.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];return n?ot.event.trigger(e,t,n,!0):void 0}});var Ht="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",Ot=/ jQuery\d+="(?:null|\d+)"/g,qt=new RegExp("<(?:"+Ht+")[\\s/>]","i"),Mt=/^\s+/,zt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,Ft=/<([\w:]+)/,It=/<tbody/i,Bt=/<|&#?\w+;/,Wt=/<(?:script|style|link)/i,Ut=/checked\s*(?:[^=]|=\s*.checked.)/i,Xt=/^$|\/(?:java|ecma)script/i,Zt=/^true\/(.*)/,Gt=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,Vt={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:it.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]},Qt=m(mt),Yt=Qt.appendChild(mt.createElement("div"));Vt.optgroup=Vt.option,Vt.tbody=Vt.tfoot=Vt.colgroup=Vt.caption=Vt.thead,Vt.th=Vt.td,ot.extend({clone:function(e,t,n){var i,r,o,a,s,l=ot.contains(e.ownerDocument,e);if(it.html5Clone||ot.isXMLDoc(e)||!qt.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(Yt.innerHTML=e.outerHTML,Yt.removeChild(o=Yt.firstChild)),!(it.noCloneEvent&&it.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||ot.isXMLDoc(e)))for(i=g(o),s=g(e),a=0;null!=(r=s[a]);++a)i[a]&&k(r,i[a]);if(t)if(n)for(s=s||g(e),i=i||g(o),a=0;null!=(r=s[a]);a++)C(r,i[a]);else C(e,o);return i=g(o,"script"),i.length>0&&w(i,!l&&g(e,"script")),i=s=r=null,o},buildFragment:function(e,t,n,i){for(var r,o,a,s,l,c,u,d=e.length,f=m(t),p=[],h=0;d>h;h++)if(o=e[h],o||0===o)if("object"===ot.type(o))ot.merge(p,o.nodeType?[o]:o);else if(Bt.test(o)){for(s=s||f.appendChild(t.createElement("div")),l=(Ft.exec(o)||["",""])[1].toLowerCase(),u=Vt[l]||Vt._default,s.innerHTML=u[1]+o.replace(zt,"<$1></$2>")+u[2],r=u[0];r--;)s=s.lastChild;if(!it.leadingWhitespace&&Mt.test(o)&&p.push(t.createTextNode(Mt.exec(o)[0])),!it.tbody)for(o="table"!==l||It.test(o)?"<table>"!==u[1]||It.test(o)?0:s:s.firstChild,r=o&&o.childNodes.length;r--;)ot.nodeName(c=o.childNodes[r],"tbody")&&!c.childNodes.length&&o.removeChild(c);for(ot.merge(p,s.childNodes),s.textContent="";s.firstChild;)s.removeChild(s.firstChild);s=f.lastChild}else p.push(t.createTextNode(o));for(s&&f.removeChild(s),it.appendChecked||ot.grep(g(p,"input"),v),h=0;o=p[h++];)if((!i||-1===ot.inArray(o,i))&&(a=ot.contains(o.ownerDocument,o),s=g(f.appendChild(o),"script"),a&&w(s),n))for(r=0;o=s[r++];)Xt.test(o.type||"")&&n.push(o);return s=null,f},cleanData:function(e,t){for(var n,i,r,o,a=0,s=ot.expando,l=ot.cache,c=it.deleteExpando,u=ot.event.special;null!=(n=e[a]);a++)if((t||ot.acceptData(n))&&(r=n[s],o=r&&l[r])){if(o.events)for(i in o.events)u[i]?ot.event.remove(n,i):ot.removeEvent(n,i,o.handle);l[r]&&(delete l[r],c?delete n[s]:typeof n.removeAttribute!==kt?n.removeAttribute(s):n[s]=null,V.push(r))}}}),ot.fn.extend({text:function(e){return At(this,function(e){return void 0===e?ot.text(this):this.empty().append((this[0]&&this[0].ownerDocument||mt).createTextNode(e))},null,e,arguments.length)},append:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=y(this,e);t.appendChild(e)}})},prepend:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=y(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){for(var n,i=e?ot.filter(e,this):this,r=0;null!=(n=i[r]);r++)t||1!==n.nodeType||ot.cleanData(g(n)),n.parentNode&&(t&&ot.contains(n.ownerDocument,n)&&w(g(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){for(var e,t=0;null!=(e=this[t]);t++){for(1===e.nodeType&&ot.cleanData(g(e,!1));e.firstChild;)e.removeChild(e.firstChild);e.options&&ot.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return ot.clone(this,e,t)})},html:function(e){return At(this,function(e){var t=this[0]||{},n=0,i=this.length;if(void 0===e)return 1===t.nodeType?t.innerHTML.replace(Ot,""):void 0;if(!("string"!=typeof e||Wt.test(e)||!it.htmlSerialize&&qt.test(e)||!it.leadingWhitespace&&Mt.test(e)||Vt[(Ft.exec(e)||["",""])[1].toLowerCase()])){e=e.replace(zt,"<$1></$2>");try{for(;i>n;n++)t=this[n]||{},1===t.nodeType&&(ot.cleanData(g(t,!1)),t.innerHTML=e);t=0}catch(r){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=arguments[0];return this.domManip(arguments,function(t){e=this.parentNode,ot.cleanData(g(this)),e&&e.replaceChild(t,this)}),e&&(e.length||e.nodeType)?this:this.remove()},detach:function(e){return this.remove(e,!0)},domManip:function(e,t){e=Y.apply([],e);var n,i,r,o,a,s,l=0,c=this.length,u=this,d=c-1,f=e[0],p=ot.isFunction(f);if(p||c>1&&"string"==typeof f&&!it.checkClone&&Ut.test(f))return this.each(function(n){var i=u.eq(n);p&&(e[0]=f.call(this,n,i.html())),i.domManip(e,t)});if(c&&(s=ot.buildFragment(e,this[0].ownerDocument,!1,this),n=s.firstChild,1===s.childNodes.length&&(s=n),n)){for(o=ot.map(g(s,"script"),b),r=o.length;c>l;l++)i=s,l!==d&&(i=ot.clone(i,!0,!0),r&&ot.merge(o,g(i,"script"))),t.call(this[l],i,l);if(r)for(a=o[o.length-1].ownerDocument,ot.map(o,x),l=0;r>l;l++)i=o[l],Xt.test(i.type||"")&&!ot._data(i,"globalEval")&&ot.contains(a,i)&&(i.src?ot._evalUrl&&ot._evalUrl(i.src):ot.globalEval((i.text||i.textContent||i.innerHTML||"").replace(Gt,"")));s=n=null}return this}}),ot.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){ot.fn[e]=function(e){for(var n,i=0,r=[],o=ot(e),a=o.length-1;a>=i;i++)n=i===a?this:this.clone(!0),ot(o[i])[t](n),K.apply(r,n.get());return this.pushStack(r)}});var Kt,Jt={};!function(){var e;it.shrinkWrapBlocks=function(){if(null!=e)return e;e=!1;var t,n,i;return n=mt.getElementsByTagName("body")[0],n&&n.style?(t=mt.createElement("div"),i=mt.createElement("div"),i.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(i).appendChild(t),typeof t.style.zoom!==kt&&(t.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",t.appendChild(mt.createElement("div")).style.width="5px",e=3!==t.offsetWidth),n.removeChild(i),e):void 0}}();var en=/^margin/,tn=new RegExp("^("+Et+")(?!px)[a-z%]+$","i"),nn,rn,on=/^(top|right|bottom|left)$/;e.getComputedStyle?(nn=function(e){return e.ownerDocument.defaultView.getComputedStyle(e,null)},rn=function(e,t,n){var i,r,o,a,s=e.style;return n=n||nn(e),a=n?n.getPropertyValue(t)||n[t]:void 0,n&&(""!==a||ot.contains(e.ownerDocument,e)||(a=ot.style(e,t)),tn.test(a)&&en.test(t)&&(i=s.width,r=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=i,s.minWidth=r,s.maxWidth=o)),void 0===a?a:a+""}):mt.documentElement.currentStyle&&(nn=function(e){return e.currentStyle},rn=function(e,t,n){var i,r,o,a,s=e.style;return n=n||nn(e),a=n?n[t]:void 0,null==a&&s&&s[t]&&(a=s[t]),tn.test(a)&&!on.test(t)&&(i=s.left,r=e.runtimeStyle,o=r&&r.left,o&&(r.left=e.currentStyle.left),s.left="fontSize"===t?"1em":a,a=s.pixelLeft+"px",s.left=i,o&&(r.left=o)),void 0===a?a:a+""||"auto"}),!function(){function t(){var t,n,i,r;n=mt.getElementsByTagName("body")[0],n&&n.style&&(t=mt.createElement("div"),i=mt.createElement("div"),i.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(i).appendChild(t),t.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",o=a=!1,l=!0,e.getComputedStyle&&(o="1%"!==(e.getComputedStyle(t,null)||{}).top,a="4px"===(e.getComputedStyle(t,null)||{width:"4px"}).width,r=t.appendChild(mt.createElement("div")),r.style.cssText=t.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",r.style.marginRight=r.style.width="0",t.style.width="1px",l=!parseFloat((e.getComputedStyle(r,null)||{}).marginRight)),t.innerHTML="<table><tr><td></td><td>t</td></tr></table>",r=t.getElementsByTagName("td"),r[0].style.cssText="margin:0;border:0;padding:0;display:none",s=0===r[0].offsetHeight,s&&(r[0].style.display="",r[1].style.display="none",s=0===r[0].offsetHeight),n.removeChild(i))}var n,i,r,o,a,s,l;n=mt.createElement("div"),n.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",r=n.getElementsByTagName("a")[0],(i=r&&r.style)&&(i.cssText="float:left;opacity:.5",it.opacity="0.5"===i.opacity,it.cssFloat=!!i.cssFloat,n.style.backgroundClip="content-box",n.cloneNode(!0).style.backgroundClip="",it.clearCloneStyle="content-box"===n.style.backgroundClip,it.boxSizing=""===i.boxSizing||""===i.MozBoxSizing||""===i.WebkitBoxSizing,ot.extend(it,{reliableHiddenOffsets:function(){return null==s&&t(),s},boxSizingReliable:function(){return null==a&&t(),a},pixelPosition:function(){return null==o&&t(),o},reliableMarginRight:function(){return null==l&&t(),l}}))}(),ot.swap=function(e,t,n,i){var r,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];r=n.apply(e,i||[]);for(o in t)e.style[o]=a[o];return r};var an=/alpha\([^)]*\)/i,sn=/opacity\s*=\s*([^)]*)/,ln=/^(none|table(?!-c[ea]).+)/,cn=new RegExp("^("+Et+")(.*)$","i"),un=new RegExp("^([+-])=("+Et+")","i"),dn={position:"absolute",visibility:"hidden",display:"block"},fn={letterSpacing:"0",fontWeight:"400"},pn=["Webkit","O","Moz","ms"];ot.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=rn(e,"opacity");return""===n?"1":n}}}},cssNumber:{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":it.cssFloat?"cssFloat":"styleFloat"},style:function(e,t,n,i){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var r,o,a,s=ot.camelCase(t),l=e.style;if(t=ot.cssProps[s]||(ot.cssProps[s]=N(l,s)),a=ot.cssHooks[t]||ot.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(r=a.get(e,!1,i))?r:l[t];if(o=typeof n,"string"===o&&(r=un.exec(n))&&(n=(r[1]+1)*r[2]+parseFloat(ot.css(e,t)),o="number"),null!=n&&n===n&&("number"!==o||ot.cssNumber[s]||(n+="px"),it.clearCloneStyle||""!==n||0!==t.indexOf("background")||(l[t]="inherit"),!(a&&"set"in a&&void 0===(n=a.set(e,n,i)))))try{l[t]=n}catch(c){}}},css:function(e,t,n,i){var r,o,a,s=ot.camelCase(t);return t=ot.cssProps[s]||(ot.cssProps[s]=N(e.style,s)),a=ot.cssHooks[t]||ot.cssHooks[s],a&&"get"in a&&(o=a.get(e,!0,n)),void 0===o&&(o=rn(e,t,i)),"normal"===o&&t in fn&&(o=fn[t]),""===n||n?(r=parseFloat(o),n===!0||ot.isNumeric(r)?r||0:o):o}}),ot.each(["height","width"],function(e,t){ot.cssHooks[t]={get:function(e,n,i){return n?ln.test(ot.css(e,"display"))&&0===e.offsetWidth?ot.swap(e,dn,function(){return j(e,t,i)}):j(e,t,i):void 0},set:function(e,n,i){var r=i&&nn(e);return A(e,n,i?D(e,t,i,it.boxSizing&&"border-box"===ot.css(e,"boxSizing",!1,r),r):0)}}}),it.opacity||(ot.cssHooks.opacity={get:function(e,t){return sn.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,i=e.currentStyle,r=ot.isNumeric(t)?"alpha(opacity="+100*t+")":"",o=i&&i.filter||n.filter||"";n.zoom=1,(t>=1||""===t)&&""===ot.trim(o.replace(an,""))&&n.removeAttribute&&(n.removeAttribute("filter"),""===t||i&&!i.filter)||(n.filter=an.test(o)?o.replace(an,r):o+" "+r)}}),ot.cssHooks.marginRight=E(it.reliableMarginRight,function(e,t){return t?ot.swap(e,{display:"inline-block"},rn,[e,"marginRight"]):void 0}),ot.each({margin:"",padding:"",border:"Width"},function(e,t){ot.cssHooks[e+t]={expand:function(n){for(var i=0,r={},o="string"==typeof n?n.split(" "):[n];4>i;i++)r[e+Nt[i]+t]=o[i]||o[i-2]||o[0];return r}},en.test(e)||(ot.cssHooks[e+t].set=A)}),ot.fn.extend({css:function(e,t){return At(this,function(e,t,n){var i,r,o={},a=0;if(ot.isArray(t)){for(i=nn(e),r=t.length;r>a;a++)o[t[a]]=ot.css(e,t[a],!1,i);return o}return void 0!==n?ot.style(e,t,n):ot.css(e,t)},e,t,arguments.length>1)},show:function(){return L(this,!0)},hide:function(){return L(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){Lt(this)?ot(this).show():ot(this).hide()})}}),ot.Tween=R,R.prototype={constructor:R,init:function(e,t,n,i,r,o){this.elem=e,this.prop=n,this.easing=r||"swing",this.options=t,this.start=this.now=this.cur(),this.end=i,this.unit=o||(ot.cssNumber[n]?"":"px")},cur:function(){var e=R.propHooks[this.prop];return e&&e.get?e.get(this):R.propHooks._default.get(this)},run:function(e){var t,n=R.propHooks[this.prop];return this.pos=t=this.options.duration?ot.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):R.propHooks._default.set(this),this}},R.prototype.init.prototype=R.prototype,R.propHooks={_default:{get:function(e){var t;return null==e.elem[e.prop]||e.elem.style&&null!=e.elem.style[e.prop]?(t=ot.css(e.elem,e.prop,""),t&&"auto"!==t?t:0):e.elem[e.prop]},set:function(e){ot.fx.step[e.prop]?ot.fx.step[e.prop](e):e.elem.style&&(null!=e.elem.style[ot.cssProps[e.prop]]||ot.cssHooks[e.prop])?ot.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},R.propHooks.scrollTop=R.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},ot.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},ot.fx=R.prototype.init,ot.fx.step={};var hn,mn,gn=/^(?:toggle|show|hide)$/,vn=new RegExp("^(?:([+-])=|)("+Et+")([a-z%]*)$","i"),yn=/queueHooks$/,bn=[O],xn={"*":[function(e,t){var n=this.createTween(e,t),i=n.cur(),r=vn.exec(t),o=r&&r[3]||(ot.cssNumber[e]?"":"px"),a=(ot.cssNumber[e]||"px"!==o&&+i)&&vn.exec(ot.css(n.elem,e)),s=1,l=20;if(a&&a[3]!==o){o=o||a[3],r=r||[],a=+i||1;do s=s||".5",a/=s,ot.style(n.elem,e,a+o);while(s!==(s=n.cur()/i)&&1!==s&&--l)}return r&&(a=n.start=+a||+i||0,n.unit=o,n.end=r[1]?a+(r[1]+1)*r[2]:+r[2]),n}]};ot.Animation=ot.extend(M,{tweener:function(e,t){ot.isFunction(e)?(t=e,e=["*"]):e=e.split(" ");for(var n,i=0,r=e.length;r>i;i++)n=e[i],xn[n]=xn[n]||[],xn[n].unshift(t)},prefilter:function(e,t){t?bn.unshift(e):bn.push(e)}}),ot.speed=function(e,t,n){var i=e&&"object"==typeof e?ot.extend({},e):{complete:n||!n&&t||ot.isFunction(e)&&e,duration:e,easing:n&&t||t&&!ot.isFunction(t)&&t};return i.duration=ot.fx.off?0:"number"==typeof i.duration?i.duration:i.duration in ot.fx.speeds?ot.fx.speeds[i.duration]:ot.fx.speeds._default,(null==i.queue||i.queue===!0)&&(i.queue="fx"),i.old=i.complete,i.complete=function(){ot.isFunction(i.old)&&i.old.call(this),i.queue&&ot.dequeue(this,i.queue)},i},ot.fn.extend({fadeTo:function(e,t,n,i){return this.filter(Lt).css("opacity",0).show().end().animate({opacity:t},e,n,i)},animate:function(e,t,n,i){var r=ot.isEmptyObject(e),o=ot.speed(t,n,i),a=function(){var t=M(this,ot.extend({},e),o);(r||ot._data(this,"finish"))&&t.stop(!0)};return a.finish=a,r||o.queue===!1?this.each(a):this.queue(o.queue,a)},stop:function(e,t,n){var i=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=void 0),t&&e!==!1&&this.queue(e||"fx",[]),this.each(function(){var t=!0,r=null!=e&&e+"queueHooks",o=ot.timers,a=ot._data(this);if(r)a[r]&&a[r].stop&&i(a[r]);else for(r in a)a[r]&&a[r].stop&&yn.test(r)&&i(a[r]);for(r=o.length;r--;)o[r].elem!==this||null!=e&&o[r].queue!==e||(o[r].anim.stop(n),t=!1,o.splice(r,1));(t||!n)&&ot.dequeue(this,e)})},finish:function(e){return e!==!1&&(e=e||"fx"),this.each(function(){var t,n=ot._data(this),i=n[e+"queue"],r=n[e+"queueHooks"],o=ot.timers,a=i?i.length:0;for(n.finish=!0,ot.queue(this,e,[]),r&&r.stop&&r.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;a>t;t++)i[t]&&i[t].finish&&i[t].finish.call(this);delete n.finish})}}),ot.each(["toggle","show","hide"],function(e,t){var n=ot.fn[t];ot.fn[t]=function(e,i,r){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(_(t,!0),e,i,r)}}),ot.each({slideDown:_("show"),slideUp:_("hide"),slideToggle:_("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){ot.fn[e]=function(e,n,i){return this.animate(t,e,n,i)}}),ot.timers=[],ot.fx.tick=function(){var e,t=ot.timers,n=0;for(hn=ot.now();n<t.length;n++)e=t[n],e()||t[n]!==e||t.splice(n--,1);t.length||ot.fx.stop(),hn=void 0},ot.fx.timer=function(e){ot.timers.push(e),e()?ot.fx.start():ot.timers.pop()},ot.fx.interval=13,ot.fx.start=function(){mn||(mn=setInterval(ot.fx.tick,ot.fx.interval))},ot.fx.stop=function(){clearInterval(mn),mn=null},ot.fx.speeds={slow:600,fast:200,_default:400},ot.fn.delay=function(e,t){return e=ot.fx?ot.fx.speeds[e]||e:e,t=t||"fx",this.queue(t,function(t,n){var i=setTimeout(t,e);n.stop=function(){clearTimeout(i)}})},function(){var e,t,n,i,r;t=mt.createElement("div"),t.setAttribute("className","t"),t.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",i=t.getElementsByTagName("a")[0],n=mt.createElement("select"),r=n.appendChild(mt.createElement("option")),e=t.getElementsByTagName("input")[0],i.style.cssText="top:1px",it.getSetAttribute="t"!==t.className,it.style=/top/.test(i.getAttribute("style")),it.hrefNormalized="/a"===i.getAttribute("href"),it.checkOn=!!e.value,it.optSelected=r.selected,it.enctype=!!mt.createElement("form").enctype,n.disabled=!0,it.optDisabled=!r.disabled,e=mt.createElement("input"),e.setAttribute("value",""),it.input=""===e.getAttribute("value"),e.value="t",e.setAttribute("type","radio"),it.radioValue="t"===e.value}();var wn=/\r/g;ot.fn.extend({val:function(e){var t,n,i,r=this[0];return arguments.length?(i=ot.isFunction(e),this.each(function(n){var r;1===this.nodeType&&(r=i?e.call(this,n,ot(this).val()):e,null==r?r="":"number"==typeof r?r+="":ot.isArray(r)&&(r=ot.map(r,function(e){return null==e?"":e+""})),t=ot.valHooks[this.type]||ot.valHooks[this.nodeName.toLowerCase()],t&&"set"in t&&void 0!==t.set(this,r,"value")||(this.value=r))})):r?(t=ot.valHooks[r.type]||ot.valHooks[r.nodeName.toLowerCase()],t&&"get"in t&&void 0!==(n=t.get(r,"value"))?n:(n=r.value,"string"==typeof n?n.replace(wn,""):null==n?"":n)):void 0}}),ot.extend({valHooks:{option:{get:function(e){var t=ot.find.attr(e,"value");return null!=t?t:ot.trim(ot.text(e))}},select:{get:function(e){for(var t,n,i=e.options,r=e.selectedIndex,o="select-one"===e.type||0>r,a=o?null:[],s=o?r+1:i.length,l=0>r?s:o?r:0;s>l;l++)if(n=i[l],!(!n.selected&&l!==r||(it.optDisabled?n.disabled:null!==n.getAttribute("disabled"))||n.parentNode.disabled&&ot.nodeName(n.parentNode,"optgroup"))){if(t=ot(n).val(),o)return t;a.push(t)}return a},set:function(e,t){for(var n,i,r=e.options,o=ot.makeArray(t),a=r.length;a--;)if(i=r[a],ot.inArray(ot.valHooks.option.get(i),o)>=0)try{i.selected=n=!0}catch(s){i.scrollHeight}else i.selected=!1;return n||(e.selectedIndex=-1),r}}}}),ot.each(["radio","checkbox"],function(){ot.valHooks[this]={set:function(e,t){return ot.isArray(t)?e.checked=ot.inArray(ot(e).val(),t)>=0:void 0}},it.checkOn||(ot.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var Cn,kn,$n=ot.expr.attrHandle,Sn=/^(?:checked|selected)$/i,Tn=it.getSetAttribute,En=it.input;ot.fn.extend({attr:function(e,t){return At(this,ot.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){ot.removeAttr(this,e)})}}),ot.extend({attr:function(e,t,n){var i,r,o=e.nodeType;return e&&3!==o&&8!==o&&2!==o?typeof e.getAttribute===kt?ot.prop(e,t,n):(1===o&&ot.isXMLDoc(e)||(t=t.toLowerCase(),i=ot.attrHooks[t]||(ot.expr.match.bool.test(t)?kn:Cn)),void 0===n?i&&"get"in i&&null!==(r=i.get(e,t))?r:(r=ot.find.attr(e,t),null==r?void 0:r):null!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):void ot.removeAttr(e,t)):void 0},removeAttr:function(e,t){var n,i,r=0,o=t&&t.match(xt);if(o&&1===e.nodeType)for(;n=o[r++];)i=ot.propFix[n]||n,ot.expr.match.bool.test(n)?En&&Tn||!Sn.test(n)?e[i]=!1:e[ot.camelCase("default-"+n)]=e[i]=!1:ot.attr(e,n,""),e.removeAttribute(Tn?n:i)},attrHooks:{type:{set:function(e,t){if(!it.radioValue&&"radio"===t&&ot.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}}}),kn={set:function(e,t,n){return t===!1?ot.removeAttr(e,n):En&&Tn||!Sn.test(n)?e.setAttribute(!Tn&&ot.propFix[n]||n,n):e[ot.camelCase("default-"+n)]=e[n]=!0,n}},ot.each(ot.expr.match.bool.source.match(/\w+/g),function(e,t){var n=$n[t]||ot.find.attr;$n[t]=En&&Tn||!Sn.test(t)?function(e,t,i){var r,o;return i||(o=$n[t],$n[t]=r,r=null!=n(e,t,i)?t.toLowerCase():null,$n[t]=o),r}:function(e,t,n){return n?void 0:e[ot.camelCase("default-"+t)]?t.toLowerCase():null}}),En&&Tn||(ot.attrHooks.value={set:function(e,t,n){return ot.nodeName(e,"input")?void(e.defaultValue=t):Cn&&Cn.set(e,t,n)}}),Tn||(Cn={set:function(e,t,n){var i=e.getAttributeNode(n);return i||e.setAttributeNode(i=e.ownerDocument.createAttribute(n)),i.value=t+="","value"===n||t===e.getAttribute(n)?t:void 0}},$n.id=$n.name=$n.coords=function(e,t,n){var i;return n?void 0:(i=e.getAttributeNode(t))&&""!==i.value?i.value:null},ot.valHooks.button={get:function(e,t){var n=e.getAttributeNode(t);return n&&n.specified?n.value:void 0},set:Cn.set},ot.attrHooks.contenteditable={set:function(e,t,n){Cn.set(e,""===t?!1:t,n)}},ot.each(["width","height"],function(e,t){ot.attrHooks[t]={set:function(e,n){return""===n?(e.setAttribute(t,"auto"),n):void 0}}})),it.style||(ot.attrHooks.style={get:function(e){return e.style.cssText||void 0},set:function(e,t){return e.style.cssText=t+""}});var Nn=/^(?:input|select|textarea|button|object)$/i,Ln=/^(?:a|area)$/i;ot.fn.extend({prop:function(e,t){return At(this,ot.prop,e,t,arguments.length>1)},removeProp:function(e){return e=ot.propFix[e]||e,this.each(function(){try{this[e]=void 0,delete this[e]}catch(t){}})}}),ot.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(e,t,n){var i,r,o,a=e.nodeType;return e&&3!==a&&8!==a&&2!==a?(o=1!==a||!ot.isXMLDoc(e),o&&(t=ot.propFix[t]||t,r=ot.propHooks[t]),void 0!==n?r&&"set"in r&&void 0!==(i=r.set(e,n,t))?i:e[t]=n:r&&"get"in r&&null!==(i=r.get(e,t))?i:e[t]):void 0},propHooks:{tabIndex:{get:function(e){var t=ot.find.attr(e,"tabindex");return t?parseInt(t,10):Nn.test(e.nodeName)||Ln.test(e.nodeName)&&e.href?0:-1}}}}),it.hrefNormalized||ot.each(["href","src"],function(e,t){ot.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}}),it.optSelected||(ot.propHooks.selected={get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}}),ot.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){ot.propFix[this.toLowerCase()]=this}),it.enctype||(ot.propFix.enctype="encoding");var An=/[\t\r\n\f]/g;ot.fn.extend({addClass:function(e){var t,n,i,r,o,a,s=0,l=this.length,c="string"==typeof e&&e;if(ot.isFunction(e))return this.each(function(t){ot(this).addClass(e.call(this,t,this.className))});if(c)for(t=(e||"").match(xt)||[];l>s;s++)if(n=this[s],i=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(An," "):" ")){for(o=0;r=t[o++];)i.indexOf(" "+r+" ")<0&&(i+=r+" ");a=ot.trim(i),n.className!==a&&(n.className=a)}return this},removeClass:function(e){var t,n,i,r,o,a,s=0,l=this.length,c=0===arguments.length||"string"==typeof e&&e;if(ot.isFunction(e))return this.each(function(t){ot(this).removeClass(e.call(this,t,this.className))});if(c)for(t=(e||"").match(xt)||[];l>s;s++)if(n=this[s],i=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(An," "):"")){for(o=0;r=t[o++];)for(;i.indexOf(" "+r+" ")>=0;)i=i.replace(" "+r+" "," ");a=e?ot.trim(i):"",n.className!==a&&(n.className=a)}return this},toggleClass:function(e,t){var n=typeof e;return"boolean"==typeof t&&"string"===n?t?this.addClass(e):this.removeClass(e):this.each(ot.isFunction(e)?function(n){ot(this).toggleClass(e.call(this,n,this.className,t),t)}:function(){if("string"===n)for(var t,i=0,r=ot(this),o=e.match(xt)||[];t=o[i++];)r.hasClass(t)?r.removeClass(t):r.addClass(t);else(n===kt||"boolean"===n)&&(this.className&&ot._data(this,"__className__",this.className),this.className=this.className||e===!1?"":ot._data(this,"__className__")||"")})},hasClass:function(e){for(var t=" "+e+" ",n=0,i=this.length;i>n;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(An," ").indexOf(t)>=0)return!0;return!1}}),ot.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(e,t){ot.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),ot.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,i){return this.on(t,e,n,i)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}});var Dn=ot.now(),jn=/\?/,Rn=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;ot.parseJSON=function(t){if(e.JSON&&e.JSON.parse)return e.JSON.parse(t+"");var n,i=null,r=ot.trim(t+"");return r&&!ot.trim(r.replace(Rn,function(e,t,r,o){return n&&t&&(i=0),0===i?e:(n=r||t,i+=!o-!r,"")}))?Function("return "+r)():ot.error("Invalid JSON: "+t)},ot.parseXML=function(t){var n,i;if(!t||"string"!=typeof t)return null;try{e.DOMParser?(i=new DOMParser,n=i.parseFromString(t,"text/xml")):(n=new ActiveXObject("Microsoft.XMLDOM"),n.async="false",n.loadXML(t))}catch(r){n=void 0}return n&&n.documentElement&&!n.getElementsByTagName("parsererror").length||ot.error("Invalid XML: "+t),n};var Pn,_n,Hn=/#.*$/,On=/([?&])_=[^&]*/,qn=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Mn=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,zn=/^(?:GET|HEAD)$/,Fn=/^\/\//,In=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,Bn={},Wn={},Un="*/".concat("*");try{_n=location.href}catch(Xn){_n=mt.createElement("a"),_n.href="",_n=_n.href}Pn=In.exec(_n.toLowerCase())||[],ot.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:_n,type:"GET",isLocal:Mn.test(Pn[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Un,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":ot.parseJSON,"text xml":ot.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?I(I(e,ot.ajaxSettings),t):I(ot.ajaxSettings,e)},ajaxPrefilter:z(Bn),ajaxTransport:z(Wn),ajax:function(e,t){function n(e,t,n,i){var r,u,v,y,x,C=t;2!==b&&(b=2,s&&clearTimeout(s),c=void 0,a=i||"",w.readyState=e>0?4:0,r=e>=200&&300>e||304===e,n&&(y=B(d,w,n)),y=W(d,y,w,r),r?(d.ifModified&&(x=w.getResponseHeader("Last-Modified"),x&&(ot.lastModified[o]=x),x=w.getResponseHeader("etag"),x&&(ot.etag[o]=x)),204===e||"HEAD"===d.type?C="nocontent":304===e?C="notmodified":(C=y.state,u=y.data,v=y.error,r=!v)):(v=C,(e||!C)&&(C="error",0>e&&(e=0))),w.status=e,w.statusText=(t||C)+"",r?h.resolveWith(f,[u,C,w]):h.rejectWith(f,[w,C,v]),w.statusCode(g),g=void 0,l&&p.trigger(r?"ajaxSuccess":"ajaxError",[w,d,r?u:v]),m.fireWith(f,[w,C]),l&&(p.trigger("ajaxComplete",[w,d]),--ot.active||ot.event.trigger("ajaxStop")))}"object"==typeof e&&(t=e,e=void 0),t=t||{};var i,r,o,a,s,l,c,u,d=ot.ajaxSetup({},t),f=d.context||d,p=d.context&&(f.nodeType||f.jquery)?ot(f):ot.event,h=ot.Deferred(),m=ot.Callbacks("once memory"),g=d.statusCode||{},v={},y={},b=0,x="canceled",w={readyState:0,getResponseHeader:function(e){var t;if(2===b){if(!u)for(u={};t=qn.exec(a);)u[t[1].toLowerCase()]=t[2];t=u[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===b?a:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return b||(e=y[n]=y[n]||e,v[e]=t),this},overrideMimeType:function(e){return b||(d.mimeType=e),this},statusCode:function(e){var t;if(e)if(2>b)for(t in e)g[t]=[g[t],e[t]];else w.always(e[w.status]);return this},abort:function(e){var t=e||x;return c&&c.abort(t),n(0,t),this}};if(h.promise(w).complete=m.add,w.success=w.done,w.error=w.fail,d.url=((e||d.url||_n)+"").replace(Hn,"").replace(Fn,Pn[1]+"//"),d.type=t.method||t.type||d.method||d.type,d.dataTypes=ot.trim(d.dataType||"*").toLowerCase().match(xt)||[""],null==d.crossDomain&&(i=In.exec(d.url.toLowerCase()),d.crossDomain=!(!i||i[1]===Pn[1]&&i[2]===Pn[2]&&(i[3]||("http:"===i[1]?"80":"443"))===(Pn[3]||("http:"===Pn[1]?"80":"443")))),d.data&&d.processData&&"string"!=typeof d.data&&(d.data=ot.param(d.data,d.traditional)),F(Bn,d,t,w),2===b)return w;l=d.global,l&&0===ot.active++&&ot.event.trigger("ajaxStart"),d.type=d.type.toUpperCase(),d.hasContent=!zn.test(d.type),o=d.url,d.hasContent||(d.data&&(o=d.url+=(jn.test(o)?"&":"?")+d.data,delete d.data),d.cache===!1&&(d.url=On.test(o)?o.replace(On,"$1_="+Dn++):o+(jn.test(o)?"&":"?")+"_="+Dn++)),d.ifModified&&(ot.lastModified[o]&&w.setRequestHeader("If-Modified-Since",ot.lastModified[o]),ot.etag[o]&&w.setRequestHeader("If-None-Match",ot.etag[o])),(d.data&&d.hasContent&&d.contentType!==!1||t.contentType)&&w.setRequestHeader("Content-Type",d.contentType),w.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+("*"!==d.dataTypes[0]?", "+Un+"; q=0.01":""):d.accepts["*"]); +for(r in d.headers)w.setRequestHeader(r,d.headers[r]);if(d.beforeSend&&(d.beforeSend.call(f,w,d)===!1||2===b))return w.abort();x="abort";for(r in{success:1,error:1,complete:1})w[r](d[r]);if(c=F(Wn,d,t,w)){w.readyState=1,l&&p.trigger("ajaxSend",[w,d]),d.async&&d.timeout>0&&(s=setTimeout(function(){w.abort("timeout")},d.timeout));try{b=1,c.send(v,n)}catch(C){if(!(2>b))throw C;n(-1,C)}}else n(-1,"No Transport");return w},getJSON:function(e,t,n){return ot.get(e,t,n,"json")},getScript:function(e,t){return ot.get(e,void 0,t,"script")}}),ot.each(["get","post"],function(e,t){ot[t]=function(e,n,i,r){return ot.isFunction(n)&&(r=r||i,i=n,n=void 0),ot.ajax({url:e,type:t,dataType:r,data:n,success:i})}}),ot.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){ot.fn[t]=function(e){return this.on(t,e)}}),ot._evalUrl=function(e){return ot.ajax({url:e,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},ot.fn.extend({wrapAll:function(e){if(ot.isFunction(e))return this.each(function(t){ot(this).wrapAll(e.call(this,t))});if(this[0]){var t=ot(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstChild&&1===e.firstChild.nodeType;)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return this.each(ot.isFunction(e)?function(t){ot(this).wrapInner(e.call(this,t))}:function(){var t=ot(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=ot.isFunction(e);return this.each(function(n){ot(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){ot.nodeName(this,"body")||ot(this).replaceWith(this.childNodes)}).end()}}),ot.expr.filters.hidden=function(e){return e.offsetWidth<=0&&e.offsetHeight<=0||!it.reliableHiddenOffsets()&&"none"===(e.style&&e.style.display||ot.css(e,"display"))},ot.expr.filters.visible=function(e){return!ot.expr.filters.hidden(e)};var Zn=/%20/g,Gn=/\[\]$/,Vn=/\r?\n/g,Qn=/^(?:submit|button|image|reset|file)$/i,Yn=/^(?:input|select|textarea|keygen)/i;ot.param=function(e,t){var n,i=[],r=function(e,t){t=ot.isFunction(t)?t():null==t?"":t,i[i.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(void 0===t&&(t=ot.ajaxSettings&&ot.ajaxSettings.traditional),ot.isArray(e)||e.jquery&&!ot.isPlainObject(e))ot.each(e,function(){r(this.name,this.value)});else for(n in e)U(n,e[n],t,r);return i.join("&").replace(Zn,"+")},ot.fn.extend({serialize:function(){return ot.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=ot.prop(this,"elements");return e?ot.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!ot(this).is(":disabled")&&Yn.test(this.nodeName)&&!Qn.test(e)&&(this.checked||!Dt.test(e))}).map(function(e,t){var n=ot(this).val();return null==n?null:ot.isArray(n)?ot.map(n,function(e){return{name:t.name,value:e.replace(Vn,"\r\n")}}):{name:t.name,value:n.replace(Vn,"\r\n")}}).get()}}),ot.ajaxSettings.xhr=void 0!==e.ActiveXObject?function(){return!this.isLocal&&/^(get|post|head|put|delete|options)$/i.test(this.type)&&X()||Z()}:X;var Kn=0,Jn={},ei=ot.ajaxSettings.xhr();e.ActiveXObject&&ot(e).on("unload",function(){for(var e in Jn)Jn[e](void 0,!0)}),it.cors=!!ei&&"withCredentials"in ei,ei=it.ajax=!!ei,ei&&ot.ajaxTransport(function(e){if(!e.crossDomain||it.cors){var t;return{send:function(n,i){var r,o=e.xhr(),a=++Kn;if(o.open(e.type,e.url,e.async,e.username,e.password),e.xhrFields)for(r in e.xhrFields)o[r]=e.xhrFields[r];e.mimeType&&o.overrideMimeType&&o.overrideMimeType(e.mimeType),e.crossDomain||n["X-Requested-With"]||(n["X-Requested-With"]="XMLHttpRequest");for(r in n)void 0!==n[r]&&o.setRequestHeader(r,n[r]+"");o.send(e.hasContent&&e.data||null),t=function(n,r){var s,l,c;if(t&&(r||4===o.readyState))if(delete Jn[a],t=void 0,o.onreadystatechange=ot.noop,r)4!==o.readyState&&o.abort();else{c={},s=o.status,"string"==typeof o.responseText&&(c.text=o.responseText);try{l=o.statusText}catch(u){l=""}s||!e.isLocal||e.crossDomain?1223===s&&(s=204):s=c.text?200:404}c&&i(s,l,c,o.getAllResponseHeaders())},e.async?4===o.readyState?setTimeout(t):o.onreadystatechange=Jn[a]=t:t()},abort:function(){t&&t(void 0,!0)}}}}),ot.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(e){return ot.globalEval(e),e}}}),ot.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),ot.ajaxTransport("script",function(e){if(e.crossDomain){var t,n=mt.head||ot("head")[0]||mt.documentElement;return{send:function(i,r){t=mt.createElement("script"),t.async=!0,e.scriptCharset&&(t.charset=e.scriptCharset),t.src=e.url,t.onload=t.onreadystatechange=function(e,n){(n||!t.readyState||/loaded|complete/.test(t.readyState))&&(t.onload=t.onreadystatechange=null,t.parentNode&&t.parentNode.removeChild(t),t=null,n||r(200,"success"))},n.insertBefore(t,n.firstChild)},abort:function(){t&&t.onload(void 0,!0)}}}});var ti=[],ni=/(=)\?(?=&|$)|\?\?/;ot.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=ti.pop()||ot.expando+"_"+Dn++;return this[e]=!0,e}}),ot.ajaxPrefilter("json jsonp",function(t,n,i){var r,o,a,s=t.jsonp!==!1&&(ni.test(t.url)?"url":"string"==typeof t.data&&!(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&ni.test(t.data)&&"data");return s||"jsonp"===t.dataTypes[0]?(r=t.jsonpCallback=ot.isFunction(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(ni,"$1"+r):t.jsonp!==!1&&(t.url+=(jn.test(t.url)?"&":"?")+t.jsonp+"="+r),t.converters["script json"]=function(){return a||ot.error(r+" was not called"),a[0]},t.dataTypes[0]="json",o=e[r],e[r]=function(){a=arguments},i.always(function(){e[r]=o,t[r]&&(t.jsonpCallback=n.jsonpCallback,ti.push(r)),a&&ot.isFunction(o)&&o(a[0]),a=o=void 0}),"script"):void 0}),ot.parseHTML=function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||mt;var i=ft.exec(e),r=!n&&[];return i?[t.createElement(i[1])]:(i=ot.buildFragment([e],t,r),r&&r.length&&ot(r).remove(),ot.merge([],i.childNodes))};var ii=ot.fn.load;ot.fn.load=function(e,t,n){if("string"!=typeof e&&ii)return ii.apply(this,arguments);var i,r,o,a=this,s=e.indexOf(" ");return s>=0&&(i=ot.trim(e.slice(s,e.length)),e=e.slice(0,s)),ot.isFunction(t)?(n=t,t=void 0):t&&"object"==typeof t&&(o="POST"),a.length>0&&ot.ajax({url:e,type:o,dataType:"html",data:t}).done(function(e){r=arguments,a.html(i?ot("<div>").append(ot.parseHTML(e)).find(i):e)}).complete(n&&function(e,t){a.each(n,r||[e.responseText,t,e])}),this},ot.expr.filters.animated=function(e){return ot.grep(ot.timers,function(t){return e===t.elem}).length};var ri=e.document.documentElement;ot.offset={setOffset:function(e,t,n){var i,r,o,a,s,l,c,u=ot.css(e,"position"),d=ot(e),f={};"static"===u&&(e.style.position="relative"),s=d.offset(),o=ot.css(e,"top"),l=ot.css(e,"left"),c=("absolute"===u||"fixed"===u)&&ot.inArray("auto",[o,l])>-1,c?(i=d.position(),a=i.top,r=i.left):(a=parseFloat(o)||0,r=parseFloat(l)||0),ot.isFunction(t)&&(t=t.call(e,n,s)),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+r),"using"in t?t.using.call(e,f):d.css(f)}},ot.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){ot.offset.setOffset(this,e,t)});var t,n,i={top:0,left:0},r=this[0],o=r&&r.ownerDocument;return o?(t=o.documentElement,ot.contains(t,r)?(typeof r.getBoundingClientRect!==kt&&(i=r.getBoundingClientRect()),n=G(o),{top:i.top+(n.pageYOffset||t.scrollTop)-(t.clientTop||0),left:i.left+(n.pageXOffset||t.scrollLeft)-(t.clientLeft||0)}):i):void 0},position:function(){if(this[0]){var e,t,n={top:0,left:0},i=this[0];return"fixed"===ot.css(i,"position")?t=i.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),ot.nodeName(e[0],"html")||(n=e.offset()),n.top+=ot.css(e[0],"borderTopWidth",!0),n.left+=ot.css(e[0],"borderLeftWidth",!0)),{top:t.top-n.top-ot.css(i,"marginTop",!0),left:t.left-n.left-ot.css(i,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent||ri;e&&!ot.nodeName(e,"html")&&"static"===ot.css(e,"position");)e=e.offsetParent;return e||ri})}}),ot.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,t){var n=/Y/.test(t);ot.fn[e]=function(i){return At(this,function(e,i,r){var o=G(e);return void 0===r?o?t in o?o[t]:o.document.documentElement[i]:e[i]:void(o?o.scrollTo(n?ot(o).scrollLeft():r,n?r:ot(o).scrollTop()):e[i]=r)},e,i,arguments.length,null)}}),ot.each(["top","left"],function(e,t){ot.cssHooks[t]=E(it.pixelPosition,function(e,n){return n?(n=rn(e,t),tn.test(n)?ot(e).position()[t]+"px":n):void 0})}),ot.each({Height:"height",Width:"width"},function(e,t){ot.each({padding:"inner"+e,content:t,"":"outer"+e},function(n,i){ot.fn[i]=function(i,r){var o=arguments.length&&(n||"boolean"!=typeof i),a=n||(i===!0||r===!0?"margin":"border");return At(this,function(t,n,i){var r;return ot.isWindow(t)?t.document.documentElement["client"+e]:9===t.nodeType?(r=t.documentElement,Math.max(t.body["scroll"+e],r["scroll"+e],t.body["offset"+e],r["offset"+e],r["client"+e])):void 0===i?ot.css(t,n,a):ot.style(t,n,i,a)},t,o?i:void 0,o,null)}})}),ot.fn.size=function(){return this.length},ot.fn.andSelf=ot.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return ot});var oi=e.jQuery,ai=e.$;return ot.noConflict=function(t){return e.$===ot&&(e.$=ai),t&&e.jQuery===ot&&(e.jQuery=oi),ot},typeof t===kt&&(e.jQuery=e.$=ot),ot}),!function(){var e=null;window.PR_SHOULD_USE_CONTINUATION=!0,function(){function t(e){function t(e){var t=e.charCodeAt(0);if(92!==t)return t;var n=e.charAt(1);return(t=d[n])?t:n>="0"&&"7">=n?parseInt(e.substring(1),8):"u"===n||"x"===n?parseInt(e.substring(2),16):e.charCodeAt(1)}function n(e){return 32>e?(16>e?"\\x0":"\\x")+e.toString(16):(e=String.fromCharCode(e),"\\"===e||"-"===e||"]"===e||"^"===e?"\\"+e:e)}function i(e){var i=e.substring(1,e.length-1).match(/\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\[0-3][0-7]{0,2}|\\[0-7]{1,2}|\\[\S\s]|[^\\]/g),e=[],r="^"===i[0],o=["["];r&&o.push("^");for(var r=r?1:0,a=i.length;a>r;++r){var s=i[r];if(/\\[bdsw]/i.test(s))o.push(s);else{var s=t(s),l;a>r+2&&"-"===i[r+1]?(l=t(i[r+2]),r+=2):l=s,e.push([s,l]),65>l||s>122||(65>l||s>90||e.push([32|Math.max(65,s),32|Math.min(l,90)]),97>l||s>122||e.push([-33&Math.max(97,s),-33&Math.min(l,122)]))}}for(e.sort(function(e,t){return e[0]-t[0]||t[1]-e[1]}),i=[],a=[],r=0;r<e.length;++r)s=e[r],s[0]<=a[1]+1?a[1]=Math.max(a[1],s[1]):i.push(a=s);for(r=0;r<i.length;++r)s=i[r],o.push(n(s[0])),s[1]>s[0]&&(s[1]+1>s[0]&&o.push("-"),o.push(n(s[1])));return o.push("]"),o.join("")}function r(e){for(var t=e.source.match(/\[(?:[^\\\]]|\\[\S\s])*]|\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\\d+|\\[^\dux]|\(\?[!:=]|[()^]|[^()[\\^]+/g),r=t.length,s=[],l=0,c=0;r>l;++l){var u=t[l];"("===u?++c:"\\"===u.charAt(0)&&(u=+u.substring(1))&&(c>=u?s[u]=-1:t[l]=n(u))}for(l=1;l<s.length;++l)-1===s[l]&&(s[l]=++o);for(c=l=0;r>l;++l)u=t[l],"("===u?(++c,s[c]||(t[l]="(?:")):"\\"===u.charAt(0)&&(u=+u.substring(1))&&c>=u&&(t[l]="\\"+s[u]);for(l=0;r>l;++l)"^"===t[l]&&"^"!==t[l+1]&&(t[l]="");if(e.ignoreCase&&a)for(l=0;r>l;++l)u=t[l],e=u.charAt(0),u.length>=2&&"["===e?t[l]=i(u):"\\"!==e&&(t[l]=u.replace(/[A-Za-z]/g,function(e){return e=e.charCodeAt(0),"["+String.fromCharCode(-33&e,32|e)+"]"}));return t.join("")}for(var o=0,a=!1,s=!1,l=0,c=e.length;c>l;++l){var u=e[l];if(u.ignoreCase)s=!0;else if(/[a-z]/i.test(u.source.replace(/\\u[\da-f]{4}|\\x[\da-f]{2}|\\[^UXux]/gi,""))){a=!0,s=!1;break}}for(var d={b:8,t:9,n:10,v:11,f:12,r:13},f=[],l=0,c=e.length;c>l;++l){if(u=e[l],u.global||u.multiline)throw Error(""+u);f.push("(?:"+r(u)+")")}return RegExp(f.join("|"),s?"gi":"g")}function n(e,t){function n(e){var l=e.nodeType;if(1==l){if(!i.test(e.className)){for(l=e.firstChild;l;l=l.nextSibling)n(l);l=e.nodeName.toLowerCase(),("br"===l||"li"===l)&&(r[s]="\n",a[s<<1]=o++,a[s++<<1|1]=e)}}else(3==l||4==l)&&(l=e.nodeValue,l.length&&(l=t?l.replace(/\r\n?/g,"\n"):l.replace(/[\t\n\r ]+/g," "),r[s]=l,a[s<<1]=o,o+=l.length,a[s++<<1|1]=e))}var i=/(?:^|\s)nocode(?:\s|$)/,r=[],o=0,a=[],s=0;return n(e),{a:r.join("").replace(/\n$/,""),d:a}}function i(e,t,n,i){t&&(e={a:t,e:e},n(e),i.push.apply(i,e.g))}function r(e){for(var t=void 0,n=e.firstChild;n;n=n.nextSibling)var i=n.nodeType,t=1===i?t?e:n:3===i&&w.test(n.nodeValue)?e:t;return t===e?void 0:t}function o(n,r){function o(e){for(var t=e.e,n=[t,"pln"],u=0,d=e.a.match(s)||[],f={},p=0,h=d.length;h>p;++p){var m=d[p],g=f[m],v=void 0,y;if("string"==typeof g)y=!1;else{var b=a[m.charAt(0)];if(b)v=m.match(b[1]),g=b[0];else{for(y=0;l>y;++y)if(b=r[y],v=m.match(b[1])){g=b[0];break}v||(g="pln")}!(y=g.length>=5&&"lang-"===g.substring(0,5))||v&&"string"==typeof v[1]||(y=!1,g="src"),y||(f[m]=g)}if(b=u,u+=m.length,y){y=v[1];var x=m.indexOf(y),w=x+y.length;v[2]&&(w=m.length-v[2].length,x=w-y.length),g=g.substring(5),i(t+b,m.substring(0,x),o,n),i(t+b+x,y,c(g,y),n),i(t+b+w,m.substring(w),o,n)}else n.push(t+b,g)}e.g=n}var a={},s;!function(){for(var i=n.concat(r),o=[],l={},c=0,u=i.length;u>c;++c){var d=i[c],f=d[3];if(f)for(var p=f.length;--p>=0;)a[f.charAt(p)]=d;d=d[1],f=""+d,l.hasOwnProperty(f)||(o.push(d),l[f]=e)}o.push(/[\S\s]/),s=t(o)}();var l=r.length;return o}function a(t){var n=[],i=[];n.push(t.tripleQuotedStrings?["str",/^(?:'''(?:[^'\\]|\\[\S\s]|''?(?=[^']))*(?:'''|$)|"""(?:[^"\\]|\\[\S\s]|""?(?=[^"]))*(?:"""|$)|'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$))/,e,"'\""]:t.multiLineStrings?["str",/^(?:'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$)|`(?:[^\\`]|\\[\S\s])*(?:`|$))/,e,"'\"`"]:["str",/^(?:'(?:[^\n\r'\\]|\\.)*(?:'|$)|"(?:[^\n\r"\\]|\\.)*(?:"|$))/,e,"\"'"]),t.verbatimStrings&&i.push(["str",/^@"(?:[^"]|"")*(?:"|$)/,e]);var r=t.hashComments;if(r&&(t.cStyleComments?(n.push(r>1?["com",/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,e,"#"]:["com",/^#(?:(?:define|e(?:l|nd)if|else|error|ifn?def|include|line|pragma|undef|warning)\b|[^\n\r]*)/,e,"#"]),i.push(["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h(?:h|pp|\+\+)?|[a-z]\w*)>/,e])):n.push(["com",/^#[^\n\r]*/,e,"#"])),t.cStyleComments&&(i.push(["com",/^\/\/[^\n\r]*/,e]),i.push(["com",/^\/\*[\S\s]*?(?:\*\/|$)/,e])),r=t.regexLiterals){var a=(r=r>1?"":"\n\r")?".":"[\\S\\s]";i.push(["lang-regex",RegExp("^(?:^^\\.?|[+-]|[!=]=?=?|\\#|%=?|&&?=?|\\(|\\*=?|[+\\-]=|->|\\/=?|::?|<<?=?|>>?>?=?|,|;|\\?|@|\\[|~|{|\\^\\^?=?|\\|\\|?=?|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*("+("/(?=[^/*"+r+"])(?:[^/\\x5B\\x5C"+r+"]|\\x5C"+a+"|\\x5B(?:[^\\x5C\\x5D"+r+"]|\\x5C"+a+")*(?:\\x5D|$))+/")+")")])}return(r=t.types)&&i.push(["typ",r]),r=(""+t.keywords).replace(/^ | $/g,""),r.length&&i.push(["kwd",RegExp("^(?:"+r.replace(/[\s,]+/g,"|")+")\\b"),e]),n.push(["pln",/^\s+/,e," \r\n "]),r="^.[^\\s\\w.$@'\"`/\\\\]*",t.regexLiterals&&(r+="(?!s*/)"),i.push(["lit",/^@[$_a-z][\w$@]*/i,e],["typ",/^(?:[@_]?[A-Z]+[a-z][\w$@]*|\w+_t\b)/,e],["pln",/^[$_a-z][\w$@]*/i,e],["lit",/^(?:0x[\da-f]+|(?:\d(?:_\d+)*\d*(?:\.\d*)?|\.\d\+)(?:e[+-]?\d+)?)[a-z]*/i,e,"0123456789"],["pln",/^\\[\S\s]?/,e],["pun",RegExp(r),e]),o(n,i)}function s(e,t,n){function i(e){var t=e.nodeType;if(1!=t||o.test(e.className)){if((3==t||4==t)&&n){var l=e.nodeValue,c=l.match(a);c&&(t=l.substring(0,c.index),e.nodeValue=t,(l=l.substring(c.index+c[0].length))&&e.parentNode.insertBefore(s.createTextNode(l),e.nextSibling),r(e),t||e.parentNode.removeChild(e))}}else if("br"===e.nodeName)r(e),e.parentNode&&e.parentNode.removeChild(e);else for(e=e.firstChild;e;e=e.nextSibling)i(e)}function r(e){function t(e,n){var i=n?e.cloneNode(!1):e,r=e.parentNode;if(r){var r=t(r,1),o=e.nextSibling;r.appendChild(i);for(var a=o;a;a=o)o=a.nextSibling,r.appendChild(a)}return i}for(;!e.nextSibling;)if(e=e.parentNode,!e)return;for(var e=t(e.nextSibling,0),n;(n=e.parentNode)&&1===n.nodeType;)e=n;c.push(e)}for(var o=/(?:^|\s)nocode(?:\s|$)/,a=/\r\n?|\n/,s=e.ownerDocument,l=s.createElement("li");e.firstChild;)l.appendChild(e.firstChild);for(var c=[l],u=0;u<c.length;++u)i(c[u]);t===(0|t)&&c[0].setAttribute("value",t);var d=s.createElement("ol");d.className="linenums";for(var t=Math.max(0,t-1|0)||0,u=0,f=c.length;f>u;++u)l=c[u],l.setAttribute("rel","L"+(u+t+1)),l.className="L"+(u+t+1),l.firstChild||l.appendChild(s.createTextNode(" ")),d.appendChild(l);e.appendChild(d)}function l(e,t){for(var n=t.length;--n>=0;){var i=t[n];k.hasOwnProperty(i)?d.console&&console.warn("cannot override language handler %s",i):k[i]=e}}function c(e,t){return e&&k.hasOwnProperty(e)||(e=/^\s*</.test(t)?"default-markup":"default-code"),k[e]}function u(e){var t=e.h;try{var i=n(e.c,e.i),r=i.a;e.a=r,e.d=i.d,e.e=0,c(t,r)(e);var o=/\bMSIE\s(\d+)/.exec(navigator.userAgent),o=o&&+o[1]<=8,t=/\n/g,a=e.a,s=a.length,i=0,l=e.d,u=l.length,r=0,f=e.g,p=f.length,h=0;f[p]=s;var m,g;for(g=m=0;p>g;)f[g]!==f[g+2]?(f[m++]=f[g++],f[m++]=f[g++]):g+=2;for(p=m,g=m=0;p>g;){for(var v=f[g],y=f[g+1],b=g+2;p>=b+2&&f[b+1]===y;)b+=2;f[m++]=v,f[m++]=y,g=b}f.length=m;var x=e.c,w;x&&(w=x.style.display,x.style.display="none");try{for(;u>r;){var C=l[r+2]||s,k=f[h+2]||s,b=Math.min(C,k),S=l[r+1],T;if(1!==S.nodeType&&(T=a.substring(i,b))){o&&(T=T.replace(t,"\r")),S.nodeValue=T;var E=S.ownerDocument,N=E.createElement("span");N.className=f[h+1];var L=S.parentNode;L.replaceChild(N,S),N.appendChild(S),C>i&&(l[r+1]=S=E.createTextNode(a.substring(b,C)),L.insertBefore(S,N.nextSibling))}i=b,i>=C&&(r+=2),i>=k&&(h+=2)}}finally{x&&(x.style.display=w)}}catch(A){d.console&&console.log(A&&A.stack||A)}}var d=window,f=["break,continue,do,else,for,if,return,while"],p=[[f,"auto,case,char,const,default,double,enum,extern,float,goto,inline,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"],"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"],h=[p,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,delegate,dynamic_cast,explicit,export,friend,generic,late_check,mutable,namespace,nullptr,property,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"],m=[p,"abstract,assert,boolean,byte,extends,final,finally,implements,import,instanceof,interface,null,native,package,strictfp,super,synchronized,throws,transient"],g=[m,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,internal,into,is,let,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var,virtual,where"],p=[p,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"],v=[f,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"],y=[f,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"],b=[f,"as,assert,const,copy,drop,enum,extern,fail,false,fn,impl,let,log,loop,match,mod,move,mut,priv,pub,pure,ref,self,static,struct,true,trait,type,unsafe,use"],f=[f,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"],x=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)\b/,w=/\S/,C=a({keywords:[h,g,p,"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",v,y,f],hashComments:!0,cStyleComments:!0,multiLineStrings:!0,regexLiterals:!0}),k={};l(C,["default-code"]),l(o([],[["pln",/^[^<?]+/],["dec",/^<!\w[^>]*(?:>|$)/],["com",/^<\!--[\S\s]*?(?:--\>|$)/],["lang-",/^<\?([\S\s]+?)(?:\?>|$)/],["lang-",/^<%([\S\s]+?)(?:%>|$)/],["pun",/^(?:<[%?]|[%?]>)/],["lang-",/^<xmp\b[^>]*>([\S\s]+?)<\/xmp\b[^>]*>/i],["lang-js",/^<script\b[^>]*>([\S\s]*?)(<\/script\b[^>]*>)/i],["lang-css",/^<style\b[^>]*>([\S\s]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]),l(o([["pln",/^\s+/,e," \r\n"],["atv",/^(?:"[^"]*"?|'[^']*'?)/,e,"\"'"]],[["tag",/^^<\/?[a-z](?:[\w-.:]*\w)?|\/?>$/i],["atn",/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^\s"'>]*(?:[^\s"'/>]|\/(?=\s)))/],["pun",/^[/<->]+/],["lang-js",/^on\w+\s*=\s*"([^"]+)"/i],["lang-js",/^on\w+\s*=\s*'([^']+)'/i],["lang-js",/^on\w+\s*=\s*([^\s"'>]+)/i],["lang-css",/^style\s*=\s*"([^"]+)"/i],["lang-css",/^style\s*=\s*'([^']+)'/i],["lang-css",/^style\s*=\s*([^\s"'>]+)/i]]),["in.tag"]),l(o([],[["atv",/^[\S\s]+/]]),["uq.val"]),l(a({keywords:h,hashComments:!0,cStyleComments:!0,types:x}),["c","cc","cpp","cxx","cyc","m"]),l(a({keywords:"null,true,false"}),["json"]),l(a({keywords:g,hashComments:!0,cStyleComments:!0,verbatimStrings:!0,types:x}),["cs"]),l(a({keywords:m,cStyleComments:!0}),["java"]),l(a({keywords:f,hashComments:!0,multiLineStrings:!0}),["bash","bsh","csh","sh"]),l(a({keywords:v,hashComments:!0,multiLineStrings:!0,tripleQuotedStrings:!0}),["cv","py","python"]),l(a({keywords:"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",hashComments:!0,multiLineStrings:!0,regexLiterals:2}),["perl","pl","pm"]),l(a({keywords:y,hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["rb","ruby"]),l(a({keywords:p,cStyleComments:!0,regexLiterals:!0}),["javascript","js"]),l(a({keywords:"all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,throw,true,try,unless,until,when,while,yes",hashComments:3,cStyleComments:!0,multilineStrings:!0,tripleQuotedStrings:!0,regexLiterals:!0}),["coffee"]),l(a({keywords:b,cStyleComments:!0,multilineStrings:!0}),["rc","rs","rust"]),l(o([],[["str",/^[\S\s]+/]]),["regex"]);var S=d.PR={createSimpleLexer:o,registerLangHandler:l,sourceDecorator:a,PR_ATTRIB_NAME:"atn",PR_ATTRIB_VALUE:"atv",PR_COMMENT:"com",PR_DECLARATION:"dec",PR_KEYWORD:"kwd",PR_LITERAL:"lit",PR_NOCODE:"nocode",PR_PLAIN:"pln",PR_PUNCTUATION:"pun",PR_SOURCE:"src",PR_STRING:"str",PR_TAG:"tag",PR_TYPE:"typ",prettyPrintOne:d.prettyPrintOne=function(e,t,n){var i=document.createElement("div");return i.innerHTML="<pre>"+e+"</pre>",i=i.firstChild,n&&s(i,n,!0),u({h:t,j:n,c:i,i:1}),i.innerHTML},prettyPrint:d.prettyPrint=function(t,n){function i(){for(var n=d.PR_SHOULD_USE_CONTINUATION?h.now()+250:1/0;m<l.length&&h.now()<n;m++){for(var o=l[m],c=k,f=o;f=f.previousSibling;){var p=f.nodeType,S=(7===p||8===p)&&f.nodeValue;if(S?!/^\??prettify\b/.test(S):3!==p||/\S/.test(f.nodeValue))break;if(S){c={},S.replace(/\b(\w+)=([\w%+\-.:]+)/g,function(e,t,n){c[t]=n});break}}if(f=o.className,(c!==k||y.test(f))&&!b.test(f)){for(p=!1,S=o.parentNode;S;S=S.parentNode)if(C.test(S.tagName)&&S.className&&y.test(S.className)){p=!0;break}if(!p){if(o.className+=" prettyprinted",p=c.lang,!p){var p=f.match(v),T;!p&&(T=r(o))&&w.test(T.tagName)&&(p=T.className.match(v)),p&&(p=p[1])}if(x.test(o.tagName))S=1;else var S=o.currentStyle,E=a.defaultView,S=(S=S?S.whiteSpace:E&&E.getComputedStyle?E.getComputedStyle(o,e).getPropertyValue("white-space"):0)&&"pre"===S.substring(0,3);E=c.linenums,(E="true"===E||+E)||(E=(E=f.match(/\blinenums\b(?::(\d+))?/))?E[1]&&E[1].length?+E[1]:!0:!1),E&&s(o,E,S),g={h:p,c:o,j:E,i:S},u(g)}}}m<l.length?setTimeout(i,250):"function"==typeof t&&t()}for(var o=n||document.body,a=o.ownerDocument||document,o=[o.getElementsByTagName("pre"),o.getElementsByTagName("code"),o.getElementsByTagName("xmp")],l=[],c=0;c<o.length;++c)for(var f=0,p=o[c].length;p>f;++f)l.push(o[c][f]);var o=e,h=Date;h.now||(h={now:function(){return+new Date}});var m=0,g,v=/\blang(?:uage)?-([\w.]+)(?!\S)/,y=/\bprettyprint\b/,b=/\bprettyprinted\b/,x=/pre|xmp/i,w=/^code$/i,C=/^(?:pre|code|xmp)$/i,k={};i()}};"function"==typeof define&&define.amd&&define("google-code-prettify",[],function(){return S})}()}(),PR.registerLangHandler(PR.createSimpleLexer([["com",/^#[^\n\r]*/,null,"#"],["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,null,'"']],[["kwd",/^(?:ADS|AD|AUG|BZF|BZMF|CAE|CAF|CA|CCS|COM|CS|DAS|DCA|DCOM|DCS|DDOUBL|DIM|DOUBLE|DTCB|DTCF|DV|DXCH|EDRUPT|EXTEND|INCR|INDEX|NDX|INHINT|LXCH|MASK|MSK|MP|MSU|NOOP|OVSK|QXCH|RAND|READ|RELINT|RESUME|RETURN|ROR|RXOR|SQUARE|SU|TCR|TCAA|OVSK|TCF|TC|TS|WAND|WOR|WRITE|XCH|XLQ|XXALQ|ZL|ZQ|ADD|ADZ|SUB|SUZ|MPY|MPR|MPZ|DVP|COM|ABS|CLA|CLZ|LDQ|STO|STQ|ALS|LLS|LRS|TRA|TSQ|TMI|TOV|AXT|TIX|DLY|INP|OUT)\s/,null],["typ",/^(?:-?GENADR|=MINUS|2BCADR|VN|BOF|MM|-?2CADR|-?[1-6]DNADR|ADRES|BBCON|[ES]?BANK=?|BLOCK|BNKSUM|E?CADR|COUNT\*?|2?DEC\*?|-?DNCHAN|-?DNPTR|EQUALS|ERASE|MEMORY|2?OCT|REMADR|SETLOC|SUBRO|ORG|BSS|BES|SYN|EQU|DEFINE|END)\s/,null],["lit",/^'(?:-*(?:\w|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?)?/],["pln",/^-*(?:[!-z]|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?/],["pun",/^[^\w\t\n\r "'-);\\\xa0]+/]]),["apollo","agc","aea"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["str",/^"(?:[^\n\r"\\]|\\.)*(?:"|$)/,a,'"'],["pln",/^\s+/,a," \r\n "]],[["com",/^REM[^\n\r]*/,a],["kwd",/^\b(?:AND|CLOSE|CLR|CMD|CONT|DATA|DEF ?FN|DIM|END|FOR|GET|GOSUB|GOTO|IF|INPUT|LET|LIST|LOAD|NEW|NEXT|NOT|ON|OPEN|OR|POKE|PRINT|READ|RESTORE|RETURN|RUN|SAVE|STEP|STOP|SYS|THEN|TO|VERIFY|WAIT)\b/,a],["pln",/^[a-z][^\W_]?(?:\$|%)?/i,a],["lit",/^(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?/i,a,"0123456789"],["pun",/^.[^\s\w"$%.]*/,a]]),["basic","cbm"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["opn",/^[([{]+/,a,"([{"],["clo",/^[)\]}]+/,a,")]}"],["com",/^;[^\n\r]*/,a,";"],["pln",/^[\t\n\r \xa0]+/,a," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,a,'"']],[["kwd",/^(?:def|if|do|let|quote|var|fn|loop|recur|throw|try|monitor-enter|monitor-exit|defmacro|defn|defn-|macroexpand|macroexpand-1|for|doseq|dosync|dotimes|and|or|when|not|assert|doto|proxy|defstruct|first|rest|cons|defprotocol|deftype|defrecord|reify|defmulti|defmethod|meta|with-meta|ns|in-ns|create-ns|import|intern|refer|alias|namespace|resolve|ref|deref|refset|new|set!|memfn|to-array|into-array|aset|gen-class|reduce|map|filter|find|nil?|empty?|hash-map|hash-set|vec|vector|seq|flatten|reverse|assoc|dissoc|list|list?|disj|get|union|difference|intersection|extend|extend-type|extend-protocol|prn)\b/,a],["typ",/^:[\dA-Za-z-]+/]]),["clj"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\f\r ]+/,null," \r\n\f"]],[["str",/^"(?:[^\n\f\r"\\]|\\(?:\r\n?|\n|\f)|\\[\S\s])*"/,null],["str",/^'(?:[^\n\f\r'\\]|\\(?:\r\n?|\n|\f)|\\[\S\s])*'/,null],["lang-css-str",/^url\(([^"')]+)\)/i],["kwd",/^(?:url|rgb|!important|@import|@page|@media|@charset|inherit)(?=[^\w-]|$)/i,null],["lang-css-kw",/^(-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*)\s*:/i],["com",/^\/\*[^*]*\*+(?:[^*/][^*]*\*+)*\//],["com",/^(?:<\!--|--\>)/],["lit",/^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],["lit",/^#[\da-f]{3,6}\b/i],["pln",/^-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*/i],["pun",/^[^\s\w"']+/]]),["css"]),PR.registerLangHandler(PR.createSimpleLexer([],[["kwd",/^-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*/i]]),["css-kw"]),PR.registerLangHandler(PR.createSimpleLexer([],[["str",/^[^"')]+/]]),["css-str"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "]],[["com",/^#!.*/],["kwd",/^\b(?:import|library|part of|part|as|show|hide)\b/i],["com",/^\/\/.*/],["com",/^\/\*[^*]*\*+(?:[^*/][^*]*\*+)*\//],["kwd",/^\b(?:class|interface)\b/i],["kwd",/^\b(?:assert|break|case|catch|continue|default|do|else|finally|for|if|in|is|new|return|super|switch|this|throw|try|while)\b/i],["kwd",/^\b(?:abstract|const|extends|factory|final|get|implements|native|operator|set|static|typedef|var)\b/i],["typ",/^\b(?:bool|double|dynamic|int|num|object|string|void)\b/i],["kwd",/^\b(?:false|null|true)\b/i],["str",/^r?'''[\S\s]*?[^\\]'''/],["str",/^r?"""[\S\s]*?[^\\]"""/],["str",/^r?'('|[^\n\f\r]*?[^\\]')/],["str",/^r?"("|[^\n\f\r]*?[^\\]")/],["pln",/^[$_a-z]\w*/i],["pun",/^[!%&*+/:<-?^|~-]/],["lit",/^\b0x[\da-f]+/i],["lit",/^\b\d+(?:\.\d*)?(?:e[+-]?\d+)?/i],["lit",/^\b\.\d+(?:e[+-]?\d+)?/i],["pun",/^[(),.;[\]{}]/]]),["dart"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t-\r ]+/,null," \n\f\r "],["str",/^"(?:[^\n\f\r"\\]|\\[\S\s])*(?:"|$)/,null,'"'],["lit",/^[a-z]\w*/],["lit",/^'(?:[^\n\f\r'\\]|\\[^&])+'?/,null,"'"],["lit",/^\?[^\t\n ({]+/,null,"?"],["lit",/^(?:0o[0-7]+|0x[\da-f]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)/i,null,"0123456789"]],[["com",/^%[^\n]*/],["kwd",/^(?:module|attributes|do|let|in|letrec|apply|call|primop|case|of|end|when|fun|try|catch|receive|after|char|integer|float,atom,string,var)\b/],["kwd",/^-[_a-z]+/],["typ",/^[A-Z_]\w*/],["pun",/^[,.;]/]]),["erlang","erl"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t-\r ]+/,null," \n\f\r "],["str",/^"(?:[^\n\f\r"\\]|\\[\S\s])*(?:"|$)/,null,'"'],["str",/^'(?:[^\n\f\r'\\]|\\[^&])'?/,null,"'"],["lit",/^(?:0o[0-7]+|0x[\da-f]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)/i,null,"0123456789"]],[["com",/^(?:--+[^\n\f\r]*|{-(?:[^-]|-+[^}-])*-})/],["kwd",/^(?:case|class|data|default|deriving|do|else|if|import|in|infix|infixl|infixr|instance|let|module|newtype|of|then|type|where|_)(?=[^\d'A-Za-z]|$)/,null],["pln",/^(?:[A-Z][\w']*\.)*[A-Za-z][\w']*/],["pun",/^[^\d\t-\r "'A-Za-z]+/]]),["hs"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["opn",/^\(+/,a,"("],["clo",/^\)+/,a,")"],["com",/^;[^\n\r]*/,a,";"],["pln",/^[\t\n\r \xa0]+/,a," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,a,'"']],[["kwd",/^(?:block|c[ad]+r|catch|con[ds]|def(?:ine|un)|do|eq|eql|equal|equalp|eval-when|flet|format|go|if|labels|lambda|let|load-time-value|locally|macrolet|multiple-value-call|nil|progn|progv|quote|require|return-from|setq|symbol-macrolet|t|tagbody|the|throw|unwind)\b/,a],["lit",/^[+-]?(?:[#0]x[\da-f]+|\d+\/\d+|(?:\.\d+|\d+(?:\.\d*)?)(?:[de][+-]?\d+)?)/i],["lit",/^'(?:-*(?:\w|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?)?/],["pln",/^-*(?:[_a-z]|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?/i],["pun",/^[^\w\t\n\r "'-);\\\xa0]+/]]),["cl","el","lisp","lsp","scm","ss","rkt"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^!?"(?:[^"\\]|\\[\S\s])*(?:"|$)/,null,'"'],["com",/^;[^\n\r]*/,null,";"]],[["pln",/^[!%@](?:[$\-.A-Z_a-z][\w$\-.]*|\d+)/],["kwd",/^[^\W\d]\w*/,null],["lit",/^\d+\.\d+/],["lit",/^(?:\d+|0[Xx][\dA-Fa-f]+)/],["pun",/^[(-*,:<->[\]{}]|\.\.\.$/]]),["llvm","ll"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^(?:"(?:[^"\\]|\\[\S\s])*(?:"|$)|'(?:[^'\\]|\\[\S\s])*(?:'|$))/,null,"\"'"]],[["com",/^--(?:\[(=*)\[[\S\s]*?(?:]\1]|$)|[^\n\r]*)/],["str",/^\[(=*)\[[\S\s]*?(?:]\1]|$)/],["kwd",/^(?:and|break|do|else|elseif|end|false|for|function|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,null],["lit",/^[+-]?(?:0x[\da-f]+|(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?)/i],["pln",/^[_a-z]\w*/i],["pun",/^[^\w\t\n\r \xa0][^\w\t\n\r "'+=\xa0-]*/]]),["lua"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["com",/^#(?:if[\t\n\r \xa0]+(?:[$_a-z][\w']*|``[^\t\n\r`]*(?:``|$))|else|endif|light)/i,null,"#"],["str",/^(?:"(?:[^"\\]|\\[\S\s])*(?:"|$)|'(?:[^'\\]|\\[\S\s])(?:'|$))/,null,"\"'"]],[["com",/^(?:\/\/[^\n\r]*|\(\*[\S\s]*?\*\))/],["kwd",/^(?:abstract|and|as|assert|begin|class|default|delegate|do|done|downcast|downto|elif|else|end|exception|extern|false|finally|for|fun|function|if|in|inherit|inline|interface|internal|lazy|let|match|member|module|mutable|namespace|new|null|of|open|or|override|private|public|rec|return|static|struct|then|to|true|try|type|upcast|use|val|void|when|while|with|yield|asr|land|lor|lsl|lsr|lxor|mod|sig|atomic|break|checked|component|const|constraint|constructor|continue|eager|event|external|fixed|functor|global|include|method|mixin|object|parallel|process|protected|pure|sealed|trait|virtual|volatile)\b/],["lit",/^[+-]?(?:0x[\da-f]+|(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?)/i],["pln",/^(?:[_a-z][\w']*[!#?]?|``[^\t\n\r`]*(?:``|$))/i],["pun",/^[^\w\t\n\r "'\xa0]+/]]),["fs","ml"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^"(?:[^"]|\\.)*"/,null,'"']],[["com",/^;[^\n\r]*/,null,";"],["dec",/^\$(?:d|device|ec|ecode|es|estack|et|etrap|h|horolog|i|io|j|job|k|key|p|principal|q|quit|st|stack|s|storage|sy|system|t|test|tl|tlevel|tr|trestart|x|y|z[a-z]*|a|ascii|c|char|d|data|e|extract|f|find|fn|fnumber|g|get|j|justify|l|length|na|name|o|order|p|piece|ql|qlength|qs|qsubscript|q|query|r|random|re|reverse|s|select|st|stack|t|text|tr|translate|nan)\b/i,null],["kwd",/^(?:[^$]b|break|c|close|d|do|e|else|f|for|g|goto|h|halt|h|hang|i|if|j|job|k|kill|l|lock|m|merge|n|new|o|open|q|quit|r|read|s|set|tc|tcommit|tre|trestart|tro|trollback|ts|tstart|u|use|v|view|w|write|x|xecute)\b/i,null],["lit",/^[+-]?(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?/i],["pln",/^[a-z][^\W_]*/i],["pun",/^[^\w\t\n\r"$%;^\xa0]|_/]]),["mumps"]); +var a=null;PR.registerLangHandler(PR.createSimpleLexer([["str",/^(?:'(?:[^\n\r'\\]|\\.)*'|"(?:[^\n\r"\\]|\\.)*(?:"|$))/,a,'"'],["com",/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\n\r]*)/,a,"#"],["pln",/^\s+/,a," \r\n "]],[["str",/^@"(?:[^"]|"")*(?:"|$)/,a],["str",/^<#[^#>]*(?:#>|$)/,a],["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,a],["com",/^\/\/[^\n\r]*/,a],["com",/^\/\*[\S\s]*?(?:\*\/|$)/,a],["kwd",/^(?:abstract|and|as|base|catch|class|def|delegate|enum|event|extern|false|finally|fun|implements|interface|internal|is|macro|match|matches|module|mutable|namespace|new|null|out|override|params|partial|private|protected|public|ref|sealed|static|struct|syntax|this|throw|true|try|type|typeof|using|variant|virtual|volatile|when|where|with|assert|assert2|async|break|checked|continue|do|else|ensures|for|foreach|if|late|lock|new|nolate|otherwise|regexp|repeat|requires|return|surroundwith|unchecked|unless|using|while|yield)\b/,a],["typ",/^(?:array|bool|byte|char|decimal|double|float|int|list|long|object|sbyte|short|string|ulong|uint|ufloat|ulong|ushort|void)\b/,a],["lit",/^@[$_a-z][\w$@]*/i,a],["typ",/^@[A-Z]+[a-z][\w$@]*/,a],["pln",/^'?[$_a-z][\w$@]*/i,a],["lit",/^(?:0x[\da-f]+|(?:\d(?:_\d+)*\d*(?:\.\d*)?|\.\d\+)(?:e[+-]?\d+)?)[a-z]*/i,a,"0123456789"],["pun",/^.[^\s\w"-$'./@`]*/,a]]),["n","nemerle"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["str",/^'(?:[^\n\r'\\]|\\.)*(?:'|$)/,a,"'"],["pln",/^\s+/,a," \r\n "]],[["com",/^\(\*[\S\s]*?(?:\*\)|$)|^{[\S\s]*?(?:}|$)/,a],["kwd",/^(?:absolute|and|array|asm|assembler|begin|case|const|constructor|destructor|div|do|downto|else|end|external|for|forward|function|goto|if|implementation|in|inline|interface|interrupt|label|mod|not|object|of|or|packed|procedure|program|record|repeat|set|shl|shr|then|to|type|unit|until|uses|var|virtual|while|with|xor)\b/i,a],["lit",/^(?:true|false|self|nil)/i,a],["pln",/^[a-z][^\W_]*/i,a],["lit",/^(?:\$[\da-f]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?)/i,a,"0123456789"],["pun",/^.[^\s\w$'./@]*/,a]]),["pascal"]),PR.registerLangHandler(PR.sourceDecorator({keywords:"bytes,default,double,enum,extend,extensions,false,group,import,max,message,option,optional,package,repeated,required,returns,rpc,service,syntax,to,true",types:/^(bool|(double|s?fixed|[su]?int)(32|64)|float|string)\b/,cStyleComments:!0}),["proto"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,null,'"'],["str",/^'(?:[^'\\]|\\[\S\s])*(?:'|$)/,null,"'"]],[["com",/^#.*/],["kwd",/^(?:if|else|for|while|repeat|in|next|break|return|switch|function)(?![\w.])/],["lit",/^0[Xx][\dA-Fa-f]+([Pp]\d+)?[Li]?/],["lit",/^[+-]?(\d+(\.\d+)?|\.\d+)([Ee][+-]?\d+)?[Li]?/],["lit",/^(?:NULL|NA(?:_(?:integer|real|complex|character)_)?|Inf|TRUE|FALSE|NaN|\.\.(?:\.|\d+))(?![\w.])/],["pun",/^(?:<<?-|->>?|-|==|<=|>=|<|>|&&?|!=|\|\|?|[!*+/^]|%.*?%|[$=@~]|:{1,3}|[(),;?[\]{}])/],["pln",/^(?:[A-Za-z]+[\w.]*|\.[^\W\d][\w.]*)(?![\w.])/],["str",/^`.+`/]]),["r","s","R","S","Splus"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["com",/^%[^\n\r]*/,null,"%"]],[["lit",/^\\(?:cr|l?dots|R|tab)\b/],["kwd",/^\\[@-Za-z]+/],["kwd",/^#(?:ifn?def|endif)/],["pln",/^\\[{}]/],["pun",/^[()[\]{}]+/]]),["Rd","rd"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^"(?:""(?:""?(?!")|[^"\\]|\\.)*"{0,3}|(?:[^\n\r"\\]|\\.)*"?)/,null,'"'],["lit",/^`(?:[^\n\r\\`]|\\.)*`?/,null,"`"],["pun",/^[!#%&(--:-@[-^{-~]+/,null,"!#%&()*+,-:;<=>?@[\\]^{|}~"]],[["str",/^'(?:[^\n\r'\\]|\\(?:'|[^\n\r']+))'/],["lit",/^'[$A-Z_a-z][\w$]*(?![\w$'])/],["kwd",/^(?:abstract|case|catch|class|def|do|else|extends|final|finally|for|forSome|if|implicit|import|lazy|match|new|object|override|package|private|protected|requires|return|sealed|super|throw|trait|try|type|val|var|while|with|yield)\b/],["lit",/^(?:true|false|null|this)\b/],["lit",/^(?:0(?:[0-7]+|x[\da-f]+)l?|(?:0|[1-9]\d*)(?:(?:\.\d+)?(?:e[+-]?\d+)?f?|l?)|\\.\d+(?:e[+-]?\d+)?f?)/i],["typ",/^[$_]*[A-Z][\d$A-Z_]*[a-z][\w$]*/],["pln",/^[$A-Z_a-z][\w$]*/],["com",/^\/(?:\/.*|\*(?:\/|\**[^*/])*(?:\*+\/?)?)/],["pun",/^(?:\.+|\/)/]]),["scala"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["str",/^(?:"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*')/,null,"\"'"]],[["com",/^(?:--[^\n\r]*|\/\*[\S\s]*?(?:\*\/|$))/],["kwd",/^(?:add|all|alter|and|any|apply|as|asc|authorization|backup|begin|between|break|browse|bulk|by|cascade|case|check|checkpoint|close|clustered|coalesce|collate|column|commit|compute|connect|constraint|contains|containstable|continue|convert|create|cross|current|current_date|current_time|current_timestamp|current_user|cursor|database|dbcc|deallocate|declare|default|delete|deny|desc|disk|distinct|distributed|double|drop|dummy|dump|else|end|errlvl|escape|except|exec|execute|exists|exit|fetch|file|fillfactor|following|for|foreign|freetext|freetexttable|from|full|function|goto|grant|group|having|holdlock|identity|identitycol|identity_insert|if|in|index|inner|insert|intersect|into|is|join|key|kill|left|like|lineno|load|match|matched|merge|natural|national|nocheck|nonclustered|nocycle|not|null|nullif|of|off|offsets|on|open|opendatasource|openquery|openrowset|openxml|option|or|order|outer|over|partition|percent|pivot|plan|preceding|precision|primary|print|proc|procedure|public|raiserror|read|readtext|reconfigure|references|replication|restore|restrict|return|revoke|right|rollback|rowcount|rowguidcol|rows?|rule|save|schema|select|session_user|set|setuser|shutdown|some|start|statistics|system_user|table|textsize|then|to|top|tran|transaction|trigger|truncate|tsequal|unbounded|union|unique|unpivot|update|updatetext|use|user|using|values|varying|view|waitfor|when|where|while|with|within|writetext|xml)(?=[^\w-]|$)/i,null],["lit",/^[+-]?(?:0x[\da-f]+|(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?)/i],["pln",/^[_a-z][\w-]*/i],["pun",/^[^\w\t\n\r "'\xa0][^\w\t\n\r "'+\xa0-]*/]]),["sql"]);var a=null;PR.registerLangHandler(PR.createSimpleLexer([["opn",/^{+/,a,"{"],["clo",/^}+/,a,"}"],["com",/^#[^\n\r]*/,a,"#"],["pln",/^[\t\n\r \xa0]+/,a," \n\r "],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,a,'"']],[["kwd",/^(?:after|append|apply|array|break|case|catch|continue|error|eval|exec|exit|expr|for|foreach|if|incr|info|proc|return|set|switch|trace|uplevel|upvar|while)\b/,a],["lit",/^[+-]?(?:[#0]x[\da-f]+|\d+\/\d+|(?:\.\d+|\d+(?:\.\d*)?)(?:[de][+-]?\d+)?)/i],["lit",/^'(?:-*(?:\w|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?)?/],["pln",/^-*(?:[_a-z]|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?/i],["pun",/^[^\w\t\n\r "'-);\\\xa0]+/]]),["tcl"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "],["com",/^%[^\n\r]*/,null,"%"]],[["kwd",/^\\[@-Za-z]+/],["kwd",/^\\./],["typ",/^[$&]/],["lit",/[+-]?(?:\.\d+|\d+(?:\.\d*)?)(cm|em|ex|in|pc|pt|bp|mm)/i],["pun",/^[()=[\]{}]+/]]),["latex","tex"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0\u2028\u2029]+/,null," \n\r \u2028\u2029"],["str",/^(?:["\u201c\u201d](?:[^"\u201c\u201d]|["\u201c\u201d]{2})(?:["\u201c\u201d]c|$)|["\u201c\u201d](?:[^"\u201c\u201d]|["\u201c\u201d]{2})*(?:["\u201c\u201d]|$))/i,null,'"“”'],["com",/^['\u2018\u2019](?:_(?:\r\n?|[^\r]?)|[^\n\r_\u2028\u2029])*/,null,"'‘’"]],[["kwd",/^(?:addhandler|addressof|alias|and|andalso|ansi|as|assembly|auto|boolean|byref|byte|byval|call|case|catch|cbool|cbyte|cchar|cdate|cdbl|cdec|char|cint|class|clng|cobj|const|cshort|csng|cstr|ctype|date|decimal|declare|default|delegate|dim|directcast|do|double|each|else|elseif|end|endif|enum|erase|error|event|exit|finally|for|friend|function|get|gettype|gosub|goto|handles|if|implements|imports|in|inherits|integer|interface|is|let|lib|like|long|loop|me|mod|module|mustinherit|mustoverride|mybase|myclass|namespace|new|next|not|notinheritable|notoverridable|object|on|option|optional|or|orelse|overloads|overridable|overrides|paramarray|preserve|private|property|protected|public|raiseevent|readonly|redim|removehandler|resume|return|select|set|shadows|shared|short|single|static|step|stop|string|structure|sub|synclock|then|throw|to|try|typeof|unicode|until|variant|wend|when|while|with|withevents|writeonly|xor|endif|gosub|let|variant|wend)\b/i,null],["com",/^rem\b.*/i],["lit",/^(?:true\b|false\b|nothing\b|\d+(?:e[+-]?\d+[dfr]?|[dfilrs])?|(?:&h[\da-f]+|&o[0-7]+)[ils]?|\d*\.\d+(?:e[+-]?\d+)?[dfr]?|#\s+(?:\d+[/-]\d+[/-]\d+(?:\s+\d+:\d+(?::\d+)?(\s*(?:am|pm))?)?|\d+:\d+(?::\d+)?(\s*(?:am|pm))?)\s+#)/i],["pln",/^(?:(?:[a-z]|_\w)\w*(?:\[[!#%&@]+])?|\[(?:[a-z]|_\w)\w*])/i],["pun",/^[^\w\t\n\r "'[\]\xa0\u2018\u2019\u201c\u201d\u2028\u2029]+/],["pun",/^(?:\[|])/]]),["vb","vbs"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null," \n\r "]],[["str",/^(?:[box]?"(?:[^"]|"")*"|'.')/i],["com",/^--[^\n\r]*/],["kwd",/^(?:abs|access|after|alias|all|and|architecture|array|assert|attribute|begin|block|body|buffer|bus|case|component|configuration|constant|disconnect|downto|else|elsif|end|entity|exit|file|for|function|generate|generic|group|guarded|if|impure|in|inertial|inout|is|label|library|linkage|literal|loop|map|mod|nand|new|next|nor|not|null|of|on|open|or|others|out|package|port|postponed|procedure|process|pure|range|record|register|reject|rem|report|return|rol|ror|select|severity|shared|signal|sla|sll|sra|srl|subtype|then|to|transport|type|unaffected|units|until|use|variable|wait|when|while|with|xnor|xor)(?=[^\w-]|$)/i,null],["typ",/^(?:bit|bit_vector|character|boolean|integer|real|time|string|severity_level|positive|natural|signed|unsigned|line|text|std_u?logic(?:_vector)?)(?=[^\w-]|$)/i,null],["typ",/^'(?:active|ascending|base|delayed|driving|driving_value|event|high|image|instance_name|last_active|last_event|last_value|left|leftof|length|low|path_name|pos|pred|quiet|range|reverse_range|right|rightof|simple_name|stable|succ|transaction|val|value)(?=[^\w-]|$)/i,null],["lit",/^\d+(?:_\d+)*(?:#[\w.\\]+#(?:[+-]?\d+(?:_\d+)*)?|(?:\.\d+(?:_\d+)*)?(?:e[+-]?\d+(?:_\d+)*)?)/i],["pln",/^(?:[a-z]\w*|\\[^\\]*\\)/i],["pun",/^[^\w\t\n\r "'\xa0][^\w\t\n\r "'\xa0-]*/]]),["vhdl","vhd"]),PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\d\t a-gi-z\xa0]+/,null," abcdefgijklmnopqrstuvwxyz0123456789"],["pun",/^[*=[\]^~]+/,null,"=*~^[]"]],[["lang-wiki.meta",/(?:^^|\r\n?|\n)(#[a-z]+)\b/],["lit",/^[A-Z][a-z][\da-z]+[A-Z][a-z][^\W_]+\b/],["lang-",/^{{{([\S\s]+?)}}}/],["lang-",/^`([^\n\r`]+)`/],["str",/^https?:\/\/[^\s#/?]*(?:\/[^\s#?]*)?(?:\?[^\s#]*)?(?:#\S*)?/i],["pln",/^(?:\r\n|[\S\s])[^\n\r#*=A-[^`h{~]*/]]),["wiki"]),PR.registerLangHandler(PR.createSimpleLexer([["kwd",/^#[a-z]+/i,null,"#"]],[]),["wiki.meta"]);var a=null,a=null;PR.registerLangHandler(PR.createSimpleLexer([["pun",/^[:>?|]+/,a,":|>?"],["dec",/^%(?:YAML|TAG)[^\n\r#]+/,a,"%"],["typ",/^&\S+/,a,"&"],["typ",/^!\S*/,a,"!"],["str",/^"(?:[^"\\]|\\.)*(?:"|$)/,a,'"'],["str",/^'(?:[^']|'')*(?:'|$)/,a,"'"],["com",/^#[^\n\r]*/,a,"#"],["pln",/^\s+/,a," \r\n"]],[["dec",/^(?:---|\.\.\.)(?:[\n\r]|$)/],["pun",/^-/],["kwd",/^\w+:[\n\r ]/],["pln",/^\w+/]]),["yaml","yml"]),function(e){e.fn.zclip=function(t){if("object"==typeof t&&!t.length){var n=e.extend({path:"ZeroClipboard.swf",copy:null,beforeCopy:null,afterCopy:null,clickAfter:!0,setHandCursor:!0,setCSSEffects:!0},t);return this.each(function(){var t=e(this);if(t.is(":visible")&&("string"==typeof n.copy||e.isFunction(n.copy))){ZeroClipboard.setMoviePath(n.path);var i=new ZeroClipboard.Client;e.isFunction(n.copy)&&t.bind("zClip_copy",n.copy),e.isFunction(n.beforeCopy)&&t.bind("zClip_beforeCopy",n.beforeCopy),e.isFunction(n.afterCopy)&&t.bind("zClip_afterCopy",n.afterCopy),i.setHandCursor(n.setHandCursor),i.setCSSEffects(n.setCSSEffects),i.addEventListener("mouseOver",function(e){t.trigger("mouseenter")}),i.addEventListener("mouseOut",function(e){t.trigger("mouseleave")}),i.addEventListener("mouseDown",function(r){t.trigger("mousedown"),i.setText(e.isFunction(n.copy)?t.triggerHandler("zClip_copy"):n.copy),e.isFunction(n.beforeCopy)&&t.trigger("zClip_beforeCopy")}),i.addEventListener("complete",function(i,r){e.isFunction(n.afterCopy)?t.trigger("zClip_afterCopy"):(r.length>500&&(r=r.substr(0,500)+"...\n\n("+(r.length-500)+" characters not shown)"),t.removeClass("hover"),alert("Copied text to clipboard:\n\n "+r)),n.clickAfter&&t.trigger("click")}),i.glue(t[0],t.parent()[0]),e(window).bind("load resize",function(){i.reposition()})}})}return"string"==typeof t?this.each(function(){var n=e(this);t=t.toLowerCase();var i=n.data("zclipId"),r=e("#"+i+".zclip");"remove"==t?(r.remove(),n.removeClass("active hover")):"hide"==t?(r.hide(),n.removeClass("active hover")):"show"==t&&r.show()}):void 0}}(jQuery);var ZeroClipboard={version:"1.0.7",clients:{},moviePath:"ZeroClipboard.swf",nextId:1,$:function(e){return"string"==typeof e&&(e=document.getElementById(e)),e.addClass||(e.hide=function(){},e.show=function(){this.style.display=""},e.addClass=function(e){this.removeClass(e),this.className+=" "+e},e.removeClass=function(e){for(var t=this.className.split(/\s+/),n=-1,i=0;i<t.length;i++)t[i]==e&&(n=i,i=t.length);return n>-1&&(t.splice(n,1),this.className=t.join(" ")),this},e.hasClass=function(e){return!!this.className.match(new RegExp("\\s*"+e+"\\s*"))}),e},setMoviePath:function(e){this.moviePath=e},dispatch:function(e,t,n){var i=this.clients[e];i&&i.receiveEvent(t,n)},register:function(e,t){this.clients[e]=t},getDOMObjectPosition:function(e,t){var n={left:0,top:0,width:e.width?e.width:e.offsetWidth,height:e.height?e.height:e.offsetHeight};return e&&e!=t&&(n.left+=e.offsetLeft,n.top+=e.offsetTop),n},Client:function(e){this.handlers={},this.id=ZeroClipboard.nextId++,this.movieId="ZeroClipboardMovie_"+this.id,ZeroClipboard.register(this.id,this),e&&this.glue(e)}};ZeroClipboard.Client.prototype={id:0,ready:!1,movie:null,clipText:"",handCursorEnabled:!0,cssEffects:!0,handlers:null,glue:function(e,t,n){this.domElement=ZeroClipboard.$(e);var i=99;this.domElement.style.zIndex&&(i=parseInt(this.domElement.style.zIndex,10)+1),"string"==typeof t?t=ZeroClipboard.$(t):"undefined"==typeof t&&(t=document.getElementsByTagName("body")[0]);var r=ZeroClipboard.getDOMObjectPosition(this.domElement,t);this.div=document.createElement("div"),this.div.className="zclip",this.div.id="zclip-"+this.movieId,$(this.domElement).data("zclipId","zclip-"+this.movieId);var o=this.div.style;if(o.position="absolute",o.left=""+r.left+"px",o.top=""+r.top+"px",o.width=""+r.width+"px",o.height=""+r.height+"px",o.zIndex=i,"object"==typeof n)for(addedStyle in n)o[addedStyle]=n[addedStyle];t.appendChild(this.div),this.div.innerHTML=this.getHTML(r.width,r.height)},getHTML:function(e,t){var n="",i="id="+this.id+"&width="+e+"&height="+t;if(navigator.userAgent.match(/MSIE/)){var r=location.href.match(/^https/i)?"https://":"http://";n+='<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="'+r+'download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" width="'+e+'" height="'+t+'" id="'+this.movieId+'" align="middle"><param name="allowScriptAccess" value="always" /><param name="allowFullScreen" value="false" /><param name="movie" value="'+ZeroClipboard.moviePath+'" /><param name="loop" value="false" /><param name="menu" value="false" /><param name="quality" value="best" /><param name="bgcolor" value="#ffffff" /><param name="flashvars" value="'+i+'"/><param name="wmode" value="transparent"/></object>'}else n+='<embed id="'+this.movieId+'" src="'+ZeroClipboard.moviePath+'" loop="false" menu="false" quality="best" bgcolor="#ffffff" width="'+e+'" height="'+t+'" name="'+this.movieId+'" align="middle" allowScriptAccess="always" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" flashvars="'+i+'" wmode="transparent" />';return n},hide:function(){this.div&&(this.div.style.left="-2000px")},show:function(){this.reposition()},destroy:function(){if(this.domElement&&this.div){this.hide(),this.div.innerHTML="";var e=document.getElementsByTagName("body")[0];try{e.removeChild(this.div)}catch(t){}this.domElement=null,this.div=null}},reposition:function(e){if(e&&(this.domElement=ZeroClipboard.$(e),this.domElement||this.hide()),this.domElement&&this.div){var t=ZeroClipboard.getDOMObjectPosition(this.domElement),n=this.div.style;n.left=""+t.left+"px",n.top=""+t.top+"px"}},setText:function(e){this.clipText=e,this.ready&&this.movie.setText(e)},addEventListener:function(e,t){e=e.toString().toLowerCase().replace(/^on/,""),this.handlers[e]||(this.handlers[e]=[]),this.handlers[e].push(t)},setHandCursor:function(e){this.handCursorEnabled=e,this.ready&&this.movie.setHandCursor(e)},setCSSEffects:function(e){this.cssEffects=!!e},receiveEvent:function(e,t){switch(e=e.toString().toLowerCase().replace(/^on/,"")){case"load":if(this.movie=document.getElementById(this.movieId),!this.movie){var n=this;return void setTimeout(function(){n.receiveEvent("load",null)},1)}if(!this.ready&&navigator.userAgent.match(/Firefox/)&&navigator.userAgent.match(/Windows/)){var n=this;return setTimeout(function(){n.receiveEvent("load",null)},100),void(this.ready=!0)}this.ready=!0;try{this.movie.setText(this.clipText)}catch(i){}try{this.movie.setHandCursor(this.handCursorEnabled)}catch(i){}break;case"mouseover":this.domElement&&this.cssEffects&&(this.domElement.addClass("hover"),this.recoverActive&&this.domElement.addClass("active"));break;case"mouseout":this.domElement&&this.cssEffects&&(this.recoverActive=!1,this.domElement.hasClass("active")&&(this.domElement.removeClass("active"),this.recoverActive=!0),this.domElement.removeClass("hover"));break;case"mousedown":this.domElement&&this.cssEffects&&this.domElement.addClass("active");break;case"mouseup":this.domElement&&this.cssEffects&&(this.domElement.removeClass("active"),this.recoverActive=!1)}if(this.handlers[e])for(var r=0,o=this.handlers[e].length;o>r;r++){var a=this.handlers[e][r];"function"==typeof a?a(this,t):"object"==typeof a&&2==a.length?a[0][a[1]](this,t):"string"==typeof a&&window[a](this,t)}}},$.fn.extend({tabs:function(){Tabs(this)}}),$.fn.extend({markdown_preview:function(e){Preview(this,e)}}),$(document).ready(function(){function e(e){e.find(".label-color-drop .drop-down").html(n).on("click","a",function(){var e=$(this).parents(".form"),t=e.find(".label-color-drop label"),n=e.find("input[name=color]"),i=$(this).data("color-hex");t.css("background-color",i),n.val(i)})}var t=["#e11d21","#EB6420","#FBCA04","#009800","#006B75","#207DE5","#0052cc","#53E917","#F6C6C7","#FAD8C7","#FEF2C0","#BFE5BF","#BFDADC","#C7DEF8","#BFD4F2","#D4C5F9"],n="";t.forEach(function(e){n+='<a class="color" style="background-color:'+e+'" data-color-hex="'+e+'"></a>'});var i=$("#label-add-color"),r=$("#label-add-form .label-color-drop label");r.css("background-color",t[0]),i.val(t[0]);var o=$("#label-add-form");e(o),$("#label-new-btn").on("click",function(){o.hasClass("hidden")&&o.removeClass("hidden")}),$("#label-cancel-btn").on("click",function(){o.addClass("hidden")});var a=$("#label-edit-form-tpl");$("#label-list").on("click","a.edit",function(){var t=$(this).parents(".item"),n=a.clone();e(n);var i=n.find(".label-color-drop label"),r=n.find("input[name=color]"),o=t.find(".label").data("color-hex");i.css("background-color",o),r.val(o),n.find("input[name=name]").val(t.find(".label").text()),n.find("input[name=id]").val(t.attr("id").replace("label-","")),t.after(n.show()),$("#label-edit-cancel-btn").on("click",function(){n.remove()})});var s=$("#label-delete-form-tpl");$("#label-list").on("click","a.delete",function(){var e=$(this).parents(".item"),t=s.clone();t.find("input[name=id]").val(e.attr("id").replace("label-","")),e.after(t.show()),$("#label-del-cancel-btn").on("click",function(){t.remove()})})}),function($){function e(e,t){return"function"==typeof e?e.call(t):e}function t(e){for(;e=e.parentNode;)if(e==document)return!0;return!1}function n(e,t){this.$element=$(e),this.options=t,this.enabled=!0,this.fixTitle()}n.prototype={show:function(){var t=this.getTitle();if(t&&this.enabled){var n=this.tip();n.find(".tipsy-inner")[this.options.html?"html":"text"](t),n[0].className="tipsy",n.remove().css({top:0,left:0,visibility:"hidden",display:"block"}).prependTo(document.body);var i=$.extend({},this.$element.offset(),{width:this.$element[0].offsetWidth,height:this.$element[0].offsetHeight}),r=n[0].offsetWidth,o=n[0].offsetHeight,a=e(this.options.gravity,this.$element[0]),s;switch(a.charAt(0)){case"n":s={top:i.top+i.height+this.options.offset,left:i.left+i.width/2-r/2};break;case"s":s={top:i.top-o-this.options.offset,left:i.left+i.width/2-r/2};break;case"e":s={top:i.top+i.height/2-o/2,left:i.left-r-this.options.offset};break;case"w":s={top:i.top+i.height/2-o/2,left:i.left+i.width+this.options.offset}}2==a.length&&(s.left="w"==a.charAt(1)?i.left+i.width/2-15:i.left+i.width/2-r+15),n.css(s).addClass("tipsy-"+a),n.find(".tipsy-arrow")[0].className="tipsy-arrow tipsy-arrow-"+a.charAt(0),this.options.className&&n.addClass(e(this.options.className,this.$element[0])),this.options.fade?n.stop().css({opacity:0,display:"block",visibility:"visible"}).animate({opacity:this.options.opacity}):n.css({visibility:"visible",opacity:this.options.opacity})}},hide:function(){this.options.fade?this.tip().stop().fadeOut(function(){$(this).remove()}):this.tip().remove()},fixTitle:function(){var e=this.$element;(e.attr("title")||"string"!=typeof e.attr("original-title"))&&e.attr("original-title",e.attr("title")||"").removeAttr("title")},getTitle:function(){var e,t=this.$element,n=this.options;this.fixTitle();var e,n=this.options;return"string"==typeof n.title?e=t.attr("title"==n.title?"original-title":n.title):"function"==typeof n.title&&(e=n.title.call(t[0])),e=(""+e).replace(/(^\s*|\s*$)/,""),e||n.fallback},tip:function(){return this.$tip||(this.$tip=$('<div class="tipsy"></div>').html('<div class="tipsy-arrow"></div><div class="tipsy-inner"></div>'),this.$tip.data("tipsy-pointee",this.$element[0])),this.$tip},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled}},$.fn.tipsy=function(e){function t(t){var i=$.data(t,"tipsy");return i||(i=new n(t,$.fn.tipsy.elementOptions(t,e)),$.data(t,"tipsy",i)),i}function i(){var n=t(this);n.hoverState="in",0==e.delayIn?n.show():(n.fixTitle(),setTimeout(function(){"in"==n.hoverState&&n.show()},e.delayIn))}function r(){var n=t(this);n.hoverState="out",0==e.delayOut?n.hide():setTimeout(function(){"out"==n.hoverState&&n.hide()},e.delayOut)}if(e===!0)return this.data("tipsy");if("string"==typeof e){var o=this.data("tipsy");return o&&o[e](),this}if(e=$.extend({},$.fn.tipsy.defaults,e),e.live||this.each(function(){t(this)}),"manual"!=e.trigger){var a=e.live?"live":"bind",s="hover"==e.trigger?"mouseenter":"focus",l="hover"==e.trigger?"mouseleave":"blur";this[a](s,i)[a](l,r)}return this},$.fn.tipsy.defaults={className:null,delayIn:0,delayOut:0,fade:!1,fallback:"",gravity:"n",html:!1,live:!1,offset:0,opacity:.8,title:"title",trigger:"hover"},$.fn.tipsy.revalidate=function(){$(".tipsy").each(function(){var e=$.data(this,"tipsy-pointee");e&&t(e)||$(this).remove()})},$.fn.tipsy.elementOptions=function(e,t){return $.metadata?$.extend({},t,$(e).metadata()):t},$.fn.tipsy.autoNS=function(){return $(this).offset().top>$(document).scrollTop()+$(window).height()/2?"s":"n"},$.fn.tipsy.autoWE=function(){return $(this).offset().left>$(document).scrollLeft()+$(window).width()/2?"e":"w"},$.fn.tipsy.autoBounds=function(e,t){return function(){var n={ns:t[0],ew:t.length>1?t[1]:!1},i=$(document).scrollTop()+e,r=$(document).scrollLeft()+e,o=$(this);return o.offset().top<i&&(n.ns="n"),o.offset().left<r&&(n.ew="w"),$(window).width()+$(document).scrollLeft()-o.offset().left<e&&(n.ew="e"),$(window).height()+$(document).scrollTop()-o.offset().top<e&&(n.ns="s"),n.ns+(n.ew?n.ew:"")}}}(jQuery);var Gogs={};!function($){var ajax=$.ajax;$.extend({ajax:function(url,options){"object"==typeof url&&(options=url,url=void 0),options=options||{},url=options.url;var csrftoken=$("meta[name=_csrf]").attr("content"),headers=options.headers||{},domain=document.domain.replace(/\./gi,"\\.");(!/^(http:|https:).*/.test(url)||eval("/^(http:|https:)\\/\\/(.+\\.)*"+domain+".*/").test(url))&&(headers=$.extend(headers,{"X-Csrf-Token":csrftoken})),options.headers=headers;var callback=options.success;return options.success=function(e){e.once&&$("[name=_once]").val(e.once),callback&&callback.apply(this,arguments)},ajax(url,options)},changeHash:function(e){history.pushState?history.pushState(null,null,e):location.hash=e},deSelect:function(){window.getSelection?window.getSelection().removeAllRanges():document.selection.empty()}}),$.fn.extend({toggleHide:function(){$(this).addClass("hidden")},toggleShow:function(){$(this).removeClass("hidden")},toggleAjax:function(e,t){var n=$(this).data("ajax"),i=$(this).data("ajax-method")||"get",r=$(this).data("ajax-name"),o={};r.endsWith("preview")&&(o.mode="gfm",o.context=$(this).data("ajax-context")),$("[data-ajax-rel="+r+"]").each(function(){var e=$(this).data("ajax-field"),t=$(this).data("ajax-val");return"val"==t?(o[e]=$(this).val(),!0):"txt"==t?(o[e]=$(this).text(),!0):"html"==t?(o[e]=$(this).html(),!0):"data"==t?(o[e]=$(this).data("ajax-data"),!0):!0}),console.log("toggleAjax:",i,n,o),$.ajax({url:n,method:i.toUpperCase(),data:o,error:t,success:function(t){e&&e(t)}})}})}(jQuery),function($){Gogs.renderMarkdown=function(){var e=$(".markdown"),t=e.find("pre > code").parent();t.addClass("prettyprint"),prettyPrint();var n={};e.find("h1, h2, h3, h4, h5, h6").each(function(){var e=$(this),t=encodeURIComponent(e.text().toLowerCase().replace(/[^\w\- ]/g,"").replace(/[ ]/g,"-")),i=t;n[t]>0&&(i=t+"-"+n[t]),void 0==n[t]?n[t]=1:n[t]+=1,e=e.wrap('<div id="'+i+'" class="anchor-wrap" ></div>'),e.append('<a class="anchor" href="#'+i+'"><span class="octicon octicon-link"></span></a>')})},Gogs.renderCodeView=function(){function e(e,t,n){if(e.removeClass("active"),n){var r=parseInt(t.attr("rel").substr(1)),o=parseInt(n.attr("rel").substr(1)),a;if(r!=o){r>o&&(a=r,r=o,o=a);var s=[];for(i=r;i<=o;i++)s.push(".L"+i);return e.filter(s.join(",")).addClass("active"),void $.changeHash("#L"+r+"-L"+o)}}t.addClass("active"),$.changeHash("#"+t.attr("rel"))}$(document).on("click",".lines-num span",function(t){var n=$(this),i=n.parent().siblings(".lines-code").find("ol.linenums > li");e(i,i.filter("[rel="+n.attr("rel")+"]"),t.shiftKey?i.filter(".active").eq(0):null),$.deSelect()}),$(".code-view .lines-code > pre").each(function(){var e=$(this),t=e.parent(),n=t.siblings(".lines-num");if(n.length>0)for(var i=e.find("ol.linenums > li").length,r=1;i>=r;r++)n.append('<span id="L'+r+'" rel="L'+r+'">'+r+"</span>")}),$(window).on("hashchange",function(t){var n=window.location.hash.match(/^#(L\d+)\-(L\d+)$/),i=$(".code-view ol.linenums > li"),r;return n?(r=i.filter("."+n[1]),e(i,r,i.filter("."+n[2])),void $("html, body").scrollTop(r.offset().top-200)):(n=window.location.hash.match(/^#(L\d+)$/),void(n&&(r=i.filter("."+n[1]),e(i,r),$("html, body").scrollTop(r.offset().top-200))))}).trigger("hashchange")},Gogs.renderDiffView=function(){function e(e,t,n){if(e.removeClass("active"),e.parents("tr").find("td").removeClass("selected-line"),n){var r=parseInt(t.attr("rel").substr(1)),o=parseInt(n.attr("rel").substr(1)),a;if(r!=o){r>o&&(a=r,r=o,o=a);var s=[];for(i=r;i<=o;i++)s.push("[rel=L"+i+"]");return e.filter(s.join(",")).addClass("active"),e.filter(s.join(",")).parents("tr").find("td").addClass("selected-line"),void $.changeHash("#L"+r+"-L"+o)}}t.addClass("active"),t.parents("tr").find("td").addClass("selected-line"),$.changeHash("#"+t.attr("rel"))}$(document).on("click",".code-diff .lines-num span",function(t){var n=$(this),i=n.parent().siblings(".lines-code").parents().find("td.lines-num > span");e(i,i.filter("[rel="+n.attr("rel")+"]"),t.shiftKey&&i.filter(".active").length?i.filter(".active").eq(0):null),$.deSelect()}),$(".code-diff .lines-code > pre").each(function(){var e=$(this),t=e.parent(),n=t.siblings(".lines-num");if(n.length>0)for(var i=e.find("ol.linenums > li").length,r=1;i>=r;r++)n.append('<span id="L'+r+'" rel="L'+r+'">'+r+"</span>")}),$(window).on("hashchange",function(t){var n=window.location.hash.match(/^#(L\d+)\-(L\d+)$/),i=$(".code-diff td.lines-num > span"),r;return n?(r=i.filter("[rel="+n[1]+"]"),e(i,r,i.filter("[rel="+n[2]+"]")),void $("html, body").scrollTop(r.offset().top-200)):(n=window.location.hash.match(/^#(L\d+)$/),void(n&&(r=i.filter("[rel="+n[1]+"]"),e(i,r),$("html, body").scrollTop(r.offset().top-200))))}).trigger("hashchange")},Gogs.searchUsers=function(e,t){var n=function(e){return e&&e.length>0};$.ajax({url:Gogs.AppSubUrl+"/api/v1/users/search?q="+e,dataType:"json",success:function(e){if(e.ok&&e.data.length){var i="";$.each(e.data,function(e,t){i+='<li><a><img src="'+t.avatar_url+'"><span class="username">'+t.username+"</span>",n(t.full_name)&&(i+=" ("+t.full_name+")"),i+="</a></li>"}),t.html(i),t.toggleShow()}else t.toggleHide()}})},Gogs.searchRepos=function(e,t,n){$.ajax({url:Gogs.AppSubUrl+"/api/v1/repos/search?q="+e+"&"+n,dataType:"json",success:function(e){if(e.ok&&e.data.length){var n="";$.each(e.data,function(e,t){n+='<li><a><span class="octicon octicon-repo"></span> '+t.full_name+"</a></li>"}),t.html(n),t.toggleShow()}else t.toggleHide()}})},Gogs.bindCopy=function(e){$(e).hasClass("js-copy-bind")||$(e).zclip({path:Gogs.AppSubUrl+"/js/ZeroClipboard.swf",copy:function(){var e=$(this).data("copy-val"),t=$($(this).data("copy-from")),n="";return"txt"==e&&(n=t.text()),"val"==e&&(n=t.val()),"html"==e&&(n=t.html()),n},afterCopy:function(){var e=$(this);e.tipsy("hide").attr("original-title",e.data("after-title")),setTimeout(function(){e.tipsy("show")},200),setTimeout(function(){e.tipsy("hide").attr("original-title",e.data("original-title"))},2e3)}}).addClass("js-copy-bind")}}(jQuery),$(document).ready(function(){Gogs.AppSubUrl=$("head").data("suburl")||"",initCore(),$("#user-profile-setting").length&&initUserSetting(),($("#repo-create-form").length||$("#repo-migrate-form").length)&&initRepoCreate(),$("#repo-header").length&&(initTimeSwitch(),initRepo()),$("#release").length&&initRepoRelease(),$("#repo-setting").length&&initRepoSetting(),$("#org-setting").length&&initOrgSetting(),$("#invite-box").length&&initInvite(),$("#team-create-form").length&&initOrgTeamCreate(),$("#team-members-list").length&&initTeamMembersList(),$("#team-repositories-list").length&&initTeamRepositoriesList(),$("#admin-setting").length&&initAdmin(),$("#install-form").length&&initInstall(),$("#user-profile-page").length&&initProfile(),$("#diff-page").length&&(initTimeSwitch(),initDiff()),$("#dashboard-sidebar-menu").tabs(),$("#pull-issue-preview").markdown_preview(".issue-add-comment"),homepage();var e=$("#footer-lang li").length;$("#footer-lang .drop-down").css({top:-31*e+"px",height:31*e-3+"px"})}),String.prototype.endsWith=function(e){return-1!==this.indexOf(e,this.length-e.length)};
\ No newline at end of file diff --git a/public/ng/less/gogs/repository.less b/public/ng/less/gogs/repository.less index 291784298c..e48f5c8713 100644 --- a/public/ng/less/gogs/repository.less +++ b/public/ng/less/gogs/repository.less @@ -665,6 +665,9 @@ background-color: #d1ffd6 !important; border-color: #b4e2b4 !important; } + td.selected-line, td.selected-line pre { + background-color: #ffffdd !important; + } } &:hover { td, pre { diff --git a/public/ng/less/gogs/settings.less b/public/ng/less/gogs/settings.less index de923daba8..9816454458 100644 --- a/public/ng/less/gogs/settings.less +++ b/public/ng/less/gogs/settings.less @@ -35,6 +35,7 @@ #org-setting-form, #repo-setting-form, #user-profile-form, +#add-email-form, .repo-setting-form { background-color: #FFF; padding: 30px 0; @@ -69,6 +70,7 @@ #repo-hooks-history-panel, #user-social-panel, #user-applications-panel, +#user-email-panel, #user-ssh-panel { margin-bottom: 20px; .setting-list { diff --git a/routers/admin/admin.go b/routers/admin/admin.go index 563a9cdc41..ea50d5c4cb 100644 --- a/routers/admin/admin.go +++ b/routers/admin/admin.go @@ -118,6 +118,7 @@ const ( CLEAN_INACTIVATE_USER CLEAN_REPO_ARCHIVES GIT_GC_REPOS + SYNC_SSH_AUTHORIZED_KEY ) func Dashboard(ctx *middleware.Context) { @@ -144,6 +145,9 @@ func Dashboard(ctx *middleware.Context) { case GIT_GC_REPOS: success = ctx.Tr("admin.dashboard.git_gc_repos_success") err = models.GitGcRepos() + case SYNC_SSH_AUTHORIZED_KEY: + success = ctx.Tr("admin.dashboard.resync_all_sshkeys_success") + err = models.RewriteAllPublicKeys() } if err != nil { diff --git a/routers/install.go b/routers/install.go index a2491c4fc7..9c3f134d45 100644 --- a/routers/install.go +++ b/routers/install.go @@ -14,6 +14,7 @@ import ( "github.com/Unknwon/com" "github.com/Unknwon/macaron" "github.com/go-xorm/xorm" + "gopkg.in/ini.v1" "github.com/gogits/gogs/models" "github.com/gogits/gogs/modules/auth" @@ -73,12 +74,7 @@ func GlobalInit() { checkRunMode() } -func renderDbOption(ctx *middleware.Context) { - ctx.Data["DbOptions"] = []string{"MySQL", "PostgreSQL", "SQLite3"} -} - -// @router /install [get] -func Install(ctx *middleware.Context, form auth.InstallForm) { +func InstallInit(ctx *middleware.Context) { if setting.InstallLock { ctx.Handle(404, "Install", errors.New("Installation is prohibited")) return @@ -87,46 +83,35 @@ func Install(ctx *middleware.Context, form auth.InstallForm) { ctx.Data["Title"] = ctx.Tr("install.install") ctx.Data["PageIsInstall"] = true - // FIXME: when i'm ckeching length here? should they all be 0 no matter when? - // Get and assign values to install form. - if len(form.DbHost) == 0 { - form.DbHost = models.DbCfg.Host - } - if len(form.DbUser) == 0 { - form.DbUser = models.DbCfg.User - } - if len(form.DbPasswd) == 0 { - form.DbPasswd = models.DbCfg.Pwd - } - if len(form.DatabaseName) == 0 { - form.DatabaseName = models.DbCfg.Name - } - if len(form.DatabasePath) == 0 { - form.DatabasePath = models.DbCfg.Path - } + ctx.Data["DbOptions"] = []string{"MySQL", "PostgreSQL", "SQLite3"} +} - if len(form.RepoRootPath) == 0 { - form.RepoRootPath = setting.RepoRootPath - } - if len(form.RunUser) == 0 { - // Note: it's not normall to use SSH in windows so current user can be first option(not git). - if setting.IsWindows && setting.RunUser == "git" { - form.RunUser = os.Getenv("USER") - if len(form.RunUser) == 0 { - form.RunUser = os.Getenv("USERNAME") - } - } else { - form.RunUser = setting.RunUser +func Install(ctx *middleware.Context) { + form := auth.InstallForm{} + + form.DbHost = models.DbCfg.Host + form.DbUser = models.DbCfg.User + form.DbPasswd = models.DbCfg.Passwd + form.DbName = models.DbCfg.Name + form.DbPath = models.DbCfg.Path + + form.RepoRootPath = setting.RepoRootPath + + // Note(unknwon): it's hard for Windows users change a running user, + // so just use current one if config says default. + if setting.IsWindows && setting.RunUser == "git" { + form.RunUser = os.Getenv("USER") + if len(form.RunUser) == 0 { + form.RunUser = os.Getenv("USERNAME") } - } - if len(form.Domain) == 0 { - form.Domain = setting.Domain - } - if len(form.AppUrl) == 0 { - form.AppUrl = setting.AppUrl + } else { + form.RunUser = setting.RunUser } - renderDbOption(ctx) + form.Domain = setting.Domain + form.HTTPPort = setting.HttpPort + form.AppUrl = setting.AppUrl + curDbOp := "" if models.EnableSQLite3 { curDbOp = "SQLite3" // Default when enabled. @@ -138,16 +123,7 @@ func Install(ctx *middleware.Context, form auth.InstallForm) { } func InstallPost(ctx *middleware.Context, form auth.InstallForm) { - if setting.InstallLock { - ctx.Handle(404, "InstallPost", errors.New("Installation is prohibited")) - return - } - - ctx.Data["Title"] = ctx.Tr("install.install") - ctx.Data["PageIsInstall"] = true - - renderDbOption(ctx) - ctx.Data["CurDbOption"] = form.Database + ctx.Data["CurDbOption"] = form.DbType if ctx.HasError() { ctx.HTML(200, INSTALL) @@ -162,18 +138,17 @@ func InstallPost(ctx *middleware.Context, form auth.InstallForm) { // Pass basic check, now test configuration. // Test database setting. dbTypes := map[string]string{"MySQL": "mysql", "PostgreSQL": "postgres", "SQLite3": "sqlite3"} - models.DbCfg.Type = dbTypes[form.Database] + models.DbCfg.Type = dbTypes[form.DbType] models.DbCfg.Host = form.DbHost models.DbCfg.User = form.DbUser - models.DbCfg.Pwd = form.DbPasswd - models.DbCfg.Name = form.DatabaseName - models.DbCfg.SslMode = form.SslMode - models.DbCfg.Path = form.DatabasePath + models.DbCfg.Passwd = form.DbPasswd + models.DbCfg.Name = form.DbName + models.DbCfg.SSLMode = form.SSLMode + models.DbCfg.Path = form.DbPath // Set test engine. var x *xorm.Engine if err := models.NewTestEngine(x); err != nil { - // FIXME: should use core.QueryDriver (github.com/go-xorm/core) if strings.Contains(err.Error(), `Unknown database type: sqlite3`) { ctx.RenderWithErr(ctx.Tr("install.sqlite3_not_available", "http://gogs.io/docs/installation/install_from_binary.html"), INSTALL, &form) } else { @@ -194,7 +169,6 @@ func InstallPost(ctx *middleware.Context, form auth.InstallForm) { if len(curUser) == 0 { curUser = os.Getenv("USERNAME") } - // Does not check run user when the install lock is off. if form.RunUser != curUser { ctx.Data["Err_RunUser"] = true ctx.RenderWithErr(ctx.Tr("install.run_user_not_match", form.RunUser, curUser), INSTALL, &form) @@ -202,47 +176,53 @@ func InstallPost(ctx *middleware.Context, form auth.InstallForm) { } // Check admin password. - if form.AdminPasswd != form.ConfirmPasswd { + if form.AdminPasswd != form.AdminConfirmPasswd { ctx.Data["Err_AdminPasswd"] = true ctx.RenderWithErr(ctx.Tr("form.password_not_match"), INSTALL, form) return } + if form.AppUrl[len(form.AppUrl)-1] != '/' { + form.AppUrl += "/" + } + // Save settings. - setting.Cfg.Section("database").Key("DB_TYPE").SetValue(models.DbCfg.Type) - setting.Cfg.Section("database").Key("HOST").SetValue(models.DbCfg.Host) - setting.Cfg.Section("database").Key("NAME").SetValue(models.DbCfg.Name) - setting.Cfg.Section("database").Key("USER").SetValue(models.DbCfg.User) - setting.Cfg.Section("database").Key("PASSWD").SetValue(models.DbCfg.Pwd) - setting.Cfg.Section("database").Key("SSL_MODE").SetValue(models.DbCfg.SslMode) - setting.Cfg.Section("database").Key("PATH").SetValue(models.DbCfg.Path) - - setting.Cfg.Section("repository").Key("ROOT").SetValue(form.RepoRootPath) - setting.Cfg.Section("").Key("RUN_USER").SetValue(form.RunUser) - setting.Cfg.Section("server").Key("DOMAIN").SetValue(form.Domain) - setting.Cfg.Section("server").Key("ROOT_URL").SetValue(form.AppUrl) - - if len(strings.TrimSpace(form.SmtpHost)) > 0 { - setting.Cfg.Section("mailer").Key("ENABLED").SetValue("true") - setting.Cfg.Section("mailer").Key("HOST").SetValue(form.SmtpHost) - setting.Cfg.Section("mailer").Key("USER").SetValue(form.SmtpEmail) - setting.Cfg.Section("mailer").Key("PASSWD").SetValue(form.SmtpPasswd) - - setting.Cfg.Section("service").Key("REGISTER_EMAIL_CONFIRM").SetValue(com.ToStr(form.RegisterConfirm == "on")) - setting.Cfg.Section("service").Key("ENABLE_NOTIFY_MAIL").SetValue(com.ToStr(form.MailNotify == "on")) + cfg := ini.Empty() + cfg.Section("database").Key("DB_TYPE").SetValue(models.DbCfg.Type) + cfg.Section("database").Key("HOST").SetValue(models.DbCfg.Host) + cfg.Section("database").Key("NAME").SetValue(models.DbCfg.Name) + cfg.Section("database").Key("USER").SetValue(models.DbCfg.User) + cfg.Section("database").Key("PASSWD").SetValue(models.DbCfg.Passwd) + cfg.Section("database").Key("SSL_MODE").SetValue(models.DbCfg.SSLMode) + cfg.Section("database").Key("PATH").SetValue(models.DbCfg.Path) + + cfg.Section("repository").Key("ROOT").SetValue(form.RepoRootPath) + cfg.Section("").Key("RUN_USER").SetValue(form.RunUser) + cfg.Section("server").Key("DOMAIN").SetValue(form.Domain) + cfg.Section("server").Key("HTTP_PORT").SetValue(form.HTTPPort) + cfg.Section("server").Key("ROOT_URL").SetValue(form.AppUrl) + + if len(strings.TrimSpace(form.SMTPHost)) > 0 { + cfg.Section("mailer").Key("ENABLED").SetValue("true") + cfg.Section("mailer").Key("HOST").SetValue(form.SMTPHost) + cfg.Section("mailer").Key("USER").SetValue(form.SMTPEmail) + cfg.Section("mailer").Key("PASSWD").SetValue(form.SMTPPasswd) + + cfg.Section("service").Key("REGISTER_EMAIL_CONFIRM").SetValue(com.ToStr(form.RegisterConfirm == "on")) + cfg.Section("service").Key("ENABLE_NOTIFY_MAIL").SetValue(com.ToStr(form.MailNotify == "on")) } - setting.Cfg.Section("").Key("RUN_MODE").SetValue("prod") + cfg.Section("").Key("RUN_MODE").SetValue("prod") - setting.Cfg.Section("session").Key("PROVIDER").SetValue("file") + cfg.Section("session").Key("PROVIDER").SetValue("file") - setting.Cfg.Section("log").Key("MODE").SetValue("file") + cfg.Section("log").Key("MODE").SetValue("file") - setting.Cfg.Section("security").Key("INSTALL_LOCK").SetValue("true") - setting.Cfg.Section("security").Key("SECRET_KEY").SetValue(base.GetRandomString(15)) + cfg.Section("security").Key("INSTALL_LOCK").SetValue("true") + cfg.Section("security").Key("SECRET_KEY").SetValue(base.GetRandomString(15)) os.MkdirAll("custom/conf", os.ModePerm) - if err := setting.Cfg.SaveTo(path.Join(setting.CustomPath, "conf/app.ini")); err != nil { + if err := cfg.SaveTo(path.Join(setting.CustomPath, "conf/app.ini")); err != nil { ctx.RenderWithErr(ctx.Tr("install.save_config_failed", err), INSTALL, &form) return } @@ -264,5 +244,5 @@ func InstallPost(ctx *middleware.Context, form auth.InstallForm) { log.Info("First-time run install finished!") ctx.Flash.Success(ctx.Tr("install.install_success")) - ctx.Redirect(setting.AppSubUrl + "/user/login") + ctx.Redirect(form.AppUrl + "user/login") } diff --git a/routers/repo/commit.go b/routers/repo/commit.go index 4571b24f2a..e92ec8c88c 100644 --- a/routers/repo/commit.go +++ b/routers/repo/commit.go @@ -37,7 +37,7 @@ func RenderIssueLinks(oldCommits *list.List, repoLink string) *list.List { newCommits := list.New() for e := oldCommits.Front(); e != nil; e = e.Next() { c := e.Value.(*git.Commit) - c.CommitMessage = string(base.RenderIssueIndexPattern([]byte(c.CommitMessage), repoLink)) + c.CommitMessage = c.CommitMessage newCommits.PushBack(c) } return newCommits @@ -206,7 +206,7 @@ func Diff(ctx *middleware.Context) { commitId := ctx.Repo.CommitId commit := ctx.Repo.Commit - commit.CommitMessage = string(base.RenderIssueIndexPattern([]byte(commit.CommitMessage), ctx.Repo.RepoLink)) + commit.CommitMessage = commit.CommitMessage diff, err := models.GetDiffCommit(models.RepoPath(userName, repoName), commitId, setting.Git.MaxGitDiffLines) if err != nil { diff --git a/routers/repo/download.go b/routers/repo/download.go index 6367c40e28..c5e18e005b 100644 --- a/routers/repo/download.go +++ b/routers/repo/download.go @@ -25,16 +25,16 @@ func ServeBlob(ctx *middleware.Context, blob *git.Blob) error { buf = buf[:n] } - contentType, isTextFile := base.IsTextFile(buf) + _, isTextFile := base.IsTextFile(buf) _, isImageFile := base.IsImageFile(buf) - ctx.Resp.Header().Set("Content-Type", contentType) + ctx.Resp.Header().Set("Content-Type", "text/plain") if !isTextFile && !isImageFile { ctx.Resp.Header().Set("Content-Disposition", "attachment; filename="+path.Base(ctx.Repo.TreeName)) ctx.Resp.Header().Set("Content-Transfer-Encoding", "binary") } ctx.Resp.Write(buf) - io.Copy(ctx.Resp, dataRc) - return nil + _, err = io.Copy(ctx.Resp, dataRc) + return err } func SingleDownload(ctx *middleware.Context) { diff --git a/routers/repo/view.go b/routers/repo/view.go index 606a0da637..cb689df6a0 100644 --- a/routers/repo/view.go +++ b/routers/repo/view.go @@ -156,9 +156,9 @@ func Home(ctx *middleware.Context) { for _, f := range files { switch c := f[1].(type) { case *git.Commit: - c.CommitMessage = string(base.RenderIssueIndexPattern([]byte(c.CommitMessage), ctx.Repo.RepoLink)) + c.CommitMessage = c.CommitMessage case *git.SubModuleFile: - c.CommitMessage = string(base.RenderIssueIndexPattern([]byte(c.CommitMessage), ctx.Repo.RepoLink)) + c.CommitMessage = c.CommitMessage } } ctx.Data["Files"] = files diff --git a/scripts/init/freebsd/gogs b/scripts/init/freebsd/gogs new file mode 100644 index 0000000000..df13ee0d9c --- /dev/null +++ b/scripts/init/freebsd/gogs @@ -0,0 +1,46 @@ +#!/bin/sh +# +# $FreeBSD$ +# +# PROVIDE: gogs +# REQUIRE: NETWORKING SYSLOG +# KEYWORD: shutdown +# +# Add the following lines to /etc/rc.conf to enable gogs: +# +#gogs_enable="YES" + +. /etc/rc.subr + +name="gogs" +rcvar="gogs_enable" + +load_rc_config $name + +: ${gogs_user:="git"} +: ${gogs_enable:="NO"} +: ${gogs_directory:="/home/git"} + +command="${gogs_directory}/scripts/start.sh" + +pidfile="${gogs_directory}/${name}.pid" + +start_cmd="${name}_start" +stop_cmd="${name}_stop" + +gogs_start() { + cd ${gogs_directory} + export USER=${gogs_user} + export HOME=${gogs_directory} + /usr/sbin/daemon -f -u ${gogs_user} -p ${pidfile} $command +} + +gogs_stop() { + if [ ! -f $pidfile ]; then + echo "GOGS PID File not found. Maybe GOGS is not running?" + else + kill $(cat $pidfile) + fi +} + +run_rc_command "$1" diff --git a/scripts/start.bat b/scripts/start.bat deleted file mode 100644 index dfe84c0f85..0000000000 --- a/scripts/start.bat +++ /dev/null @@ -1,2 +0,0 @@ -@echo off -..\\gogs.exe web diff --git a/scripts/start.sh b/scripts/start.sh index 997b5fc272..9c05dc97ee 100755 --- a/scripts/start.sh +++ b/scripts/start.sh @@ -3,7 +3,7 @@ # Use of this source code is governed by a MIT-style # license that can be found in the LICENSE file. # -# start gogs web +# MUST EXECUTE THIS AT ROOT DIRECTORY: ./scripts/start.sh # IFS=' ' diff --git a/templates/.VERSION b/templates/.VERSION index 36f8bef5b7..40246b9eca 100644 --- a/templates/.VERSION +++ b/templates/.VERSION @@ -1 +1 @@ -0.5.12.0120 Beta
\ No newline at end of file +0.5.12.0204 Beta
\ No newline at end of file diff --git a/templates/admin/config.tmpl b/templates/admin/config.tmpl index 9dd25081ac..1f8a85ecb2 100644 --- a/templates/admin/config.tmpl +++ b/templates/admin/config.tmpl @@ -61,7 +61,7 @@ <dt>{{.i18n.Tr "admin.config.db_user"}}</dt> <dd>{{.DbCfg.User}}</dd> <dt>{{.i18n.Tr "admin.config.db_ssl_mode"}}</dt> - <dd>{{.DbCfg.SslMode}} {{.i18n.Tr "admin.config.db_ssl_mode_helper"}}</dd> + <dd>{{.DbCfg.SSLMode}} {{.i18n.Tr "admin.config.db_ssl_mode_helper"}}</dd> <dt>{{.i18n.Tr "admin.config.db_path"}}</dt> <dd>{{.DbCfg.Path}} {{.i18n.Tr "admin.config.db_path_helper"}}</dd> </dl> diff --git a/templates/admin/dashboard.tmpl b/templates/admin/dashboard.tmpl index 8d17c360b0..b570517536 100644 --- a/templates/admin/dashboard.tmpl +++ b/templates/admin/dashboard.tmpl @@ -48,6 +48,11 @@ <td>{{.i18n.Tr "admin.dashboard.git_gc_repos"}}</td> <td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=4">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> </tr> + <tr> + <td>{{.i18n.Tr "admin.dashboard.resync_all_sshkeys"}}</td> + <td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=5">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> + </tr> + </tbody> </table> </div> diff --git a/templates/home.tmpl b/templates/home.tmpl index 02f2a3badd..8603f26f41 100644 --- a/templates/home.tmpl +++ b/templates/home.tmpl @@ -28,7 +28,7 @@ <div class="grid-1-2 left"> <i class="octicon octicon-flame"></i> <b>Einfach zu installieren</b> - <p>Starte einfach <a target="_blank" href="http://gogs.io/docs/installation/install_from_binary.html">die Anwendung</a> für deine Plattform. Gogs gibt es auch für <a target="_blank" href="https://github.com/gogits/gogs/tree/master/dockerfiles">Docker</a>, <a target="_blank" href="https://github.com/geerlingguy/ansible-vagrant-examples/tree/master/gogs">Vagrant</a> oder als <a target="_blank" href="http://gogs.io/docs/installation/install_from_packages.html">Installationspaket</a>.</p> + <p>Starte einfach <a target="_blank" href="http://gogs.io/docs/installation/install_from_binary.html">die Anwendung</a> für deine Plattform. Gogs gibt es auch für <a target="_blank" href="https://github.com/gogits/gogs/tree/master/docker">Docker</a>, <a target="_blank" href="https://github.com/geerlingguy/ansible-vagrant-examples/tree/master/gogs">Vagrant</a> oder als <a target="_blank" href="http://gogs.io/docs/installation/install_from_packages.html">Installationspaket</a>.</p> </div> <div class="grid-1-2 left"> <i class="octicon octicon-device-desktop"></i> @@ -49,7 +49,7 @@ <div class="grid-1-2 left"> <i class="octicon octicon-flame"></i> <b>易安装</b> - <p>您除了可以根据操作系统平台通过 <a target="_blank" href="http://gogs.io/docs/installation/install_from_binary.html">二进制运行</a>,还可以通过 <a target="_blank" href="https://github.com/gogits/gogs/tree/master/dockerfiles">Docker</a> 或 <a target="_blank" href="https://github.com/geerlingguy/ansible-vagrant-examples/tree/master/gogs">Vagrant</a>,以及 <a target="_blank" href="http://gogs.io/docs/installation/install_from_packages.html">包管理</a> 安装。</p> + <p>您除了可以根据操作系统平台通过 <a target="_blank" href="http://gogs.io/docs/installation/install_from_binary.html">二进制运行</a>,还可以通过 <a target="_blank" href="https://github.com/gogits/gogs/tree/master/docker">Docker</a> 或 <a target="_blank" href="https://github.com/geerlingguy/ansible-vagrant-examples/tree/master/gogs">Vagrant</a>,以及 <a target="_blank" href="http://gogs.io/docs/installation/install_from_packages.html">包管理</a> 安装。</p> </div> <div class="grid-1-2 left"> <i class="octicon octicon-device-desktop"></i> @@ -70,7 +70,7 @@ <div class="grid-1-2 left"> <i class="octicon octicon-flame"></i> <b>Easy to install</b> - <p>Simply <a target="_blank" href="http://gogs.io/docs/installation/install_from_binary.html">run the binary</a> for your platform. Or ship Gogs with <a target="_blank" href="https://github.com/gogits/gogs/tree/master/dockerfiles">Docker</a> or <a target="_blank" href="https://github.com/geerlingguy/ansible-vagrant-examples/tree/master/gogs">Vagrant</a>, or get it <a target="_blank" href="http://gogs.io/docs/installation/install_from_packages.html">packaged</a>.</p> + <p>Simply <a target="_blank" href="http://gogs.io/docs/installation/install_from_binary.html">run the binary</a> for your platform. Or ship Gogs with <a target="_blank" href="https://github.com/gogits/gogs/tree/master/docker">Docker</a> or <a target="_blank" href="https://github.com/geerlingguy/ansible-vagrant-examples/tree/master/gogs">Vagrant</a>, or get it <a target="_blank" href="http://gogs.io/docs/installation/install_from_packages.html">packaged</a>.</p> </div> <div class="grid-1-2 left"> <i class="octicon octicon-device-desktop"></i> diff --git a/templates/install.tmpl b/templates/install.tmpl index f1c28031d9..3a7eb7877f 100644 --- a/templates/install.tmpl +++ b/templates/install.tmpl @@ -13,7 +13,7 @@ <div class="text-center panel-desc">{{.i18n.Tr "install.requite_db_desc"}}</div> <div class="field"> <label class="req">{{.i18n.Tr "install.db_type"}}</label> - <select name="database" id="install-database" class="form-control"> + <select name="db_type" id="install-database" class="form-control"> {{range .DbOptions}} <option value="{{.}}"{{if eq $.CurDbOption .}}selected{{end}}>{{.}}</option> {{end}} @@ -22,20 +22,20 @@ <div class="server-sql {{if eq .CurDbOption "SQLite3"}}hide{{end}}"> <div class="field"> - <label class="req" for="host">{{.i18n.Tr "install.host"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_DbHost}}ipt-error{{end}}" id="host" name="host" value="{{.host}}" /> + <label class="req" for="db_host">{{.i18n.Tr "install.host"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_DbHost}}ipt-error{{end}}" id="db_host" name="db_host" value="{{.db_host}}" /> </div> <div class="field"> - <label class="req" for="user">{{.i18n.Tr "install.user"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_DbUser}}ipt-error{{end}}" id="user" name="user" value="{{.user}}" /> + <label class="req" for="db_user">{{.i18n.Tr "install.user"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_DbUser}}ipt-error{{end}}" id="db_user" name="db_user" value="{{.db_user}}" /> </div> <div class="field"> - <label class="req" for="passwd">{{.i18n.Tr "install.password"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_DbPasswd}}ipt-error{{end}}" id="passwd" name="passwd" type="password" value="{{.passwd}}" /> + <label class="req" for="db_passwd">{{.i18n.Tr "install.password"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_DbPasswd}}ipt-error{{end}}" id="db_passwd" name="db_passwd" type="password" value="{{.db_passwd}}" /> </div> <div class="field"> - <label class="req" for="database_name">{{.i18n.Tr "install.db_name"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_DatabaseName}}ipt-error{{end}}" id="database_name" name="database_name" value="{{.database_name}}" /> + <label class="req" for="db_name">{{.i18n.Tr "install.db_name"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_DbName}}ipt-error{{end}}" id="db_name" name="db_name" value="{{.db_name}}" /> <label></label> <span class="help">{{.i18n.Tr "install.db_helper"}}</span> </div> @@ -51,8 +51,8 @@ </div> <div class="field sqlite-setting {{if not (eq .CurDbOption "SQLite3")}}hide{{end}}"> - <label class="req" for="database_path">{{.i18n.Tr "install.path"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_DatabasePath}}ipt-error{{end}}" id="database_path" name="database_path" value="{{.database_path}}" /> + <label class="req" for="db_path">{{.i18n.Tr "install.path"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_DbPath}}ipt-error{{end}}" id="db_path" name="db_path" value="{{.db_path}}" /> <label></label> <span class="help">{{.i18n.Tr "install.sqlite_helper"}}</span> </div> @@ -61,8 +61,8 @@ <div class="text-center panel-desc">{{.i18n.Tr "install.general_title"}}</div> <div class="field"> - <label class="req" for="repo_path">{{.i18n.Tr "install.repo_path"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_RepoRootPath}}ipt-error{{end}}" id="repo_path" name="repo_path" value="{{.repo_path}}" required /> + <label class="req" for="repo_root_path">{{.i18n.Tr "install.repo_path"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_RepoRootPath}}ipt-error{{end}}" id="repo_root_path" name="repo_root_path" value="{{.repo_root_path}}" required /> <label></label> <span class="help">{{.i18n.Tr "install.repo_path_helper"}}</span> </div> @@ -79,6 +79,12 @@ <span class="help">{{.i18n.Tr "install.domain_helper"}}</span> </div> <div class="field"> + <label class="req" for="http_port">{{.i18n.Tr "install.http_port"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_HttpPort}}ipt-error{{end}}" id="http_port" name="http_port" value="{{.http_port}}" required /> + <label></label> + <span class="help">{{.i18n.Tr "install.http_port_helper"}}</span> + </div> + <div class="field"> <label class="req" for="app_url">{{.i18n.Tr "install.app_url"}}</label> <input class="ipt ipt-large ipt-radius {{if .Err_AppUrl}}ipt-error{{end}}" id="app_url" name="app_url" value="{{.app_url}}" required /> <label></label> @@ -93,12 +99,12 @@ <input class="ipt ipt-large ipt-radius {{if .Err_SmtpHost}}ipt-error{{end}}" id="smtp_host" name="smtp_host" value="{{.smtp_host}}" /> </div> <div class="field"> - <label for="mailer_user">{{.i18n.Tr "install.mailer_user"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_SmtpEmail}}ipt-error{{end}}" id="mailer_user" name="mailer_user" value="{{.mailer_user}}" /> + <label for="smtp_user">{{.i18n.Tr "install.mailer_user"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_SMTPEmail}}ipt-error{{end}}" id="smtp_user" name="smtp_user" value="{{.smtp_user}}" /> </div> <div class="field"> - <label for="mailer_pwd">{{.i18n.Tr "install.mailer_password"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_SmtpPasswd}}ipt-error{{end}}" id="mailer_pwd" name="mailer_pwd" type="password" value="{{.mailer_pwd}}" /> + <label for="smtp_pwd">{{.i18n.Tr "install.mailer_password"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_SMTPPasswd}}ipt-error{{end}}" id="smtp_pwd" name="smtp_pwd" type="password" value="{{.smtp_pwd}}" /> </div> <hr> @@ -122,12 +128,12 @@ <input class="ipt ipt-large ipt-radius {{if .Err_AdminName}}ipt-error{{end}}" id="admin_name" name="admin_name" value="{{.admin_name}}" required /> </div> <div class="field"> - <label class="req" for="admin_pwd">{{.i18n.Tr "install.admin_password"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_AdminPasswd}}ipt-error{{end}}" id="admin_pwd" name="admin_pwd" type="password" value="{{.admin_pwd}}" required /> + <label class="req" for="admin_passwd">{{.i18n.Tr "install.admin_password"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_AdminPasswd}}ipt-error{{end}}" id="admin_passwd" name="admin_passwd" type="password" value="{{.admin_passwd}}" required /> </div> <div class="field"> - <label class="req" for="confirm_passwd">{{.i18n.Tr "install.confirm_password"}}</label> - <input class="ipt ipt-large ipt-radius {{if .Err_AdminPasswd}}ipt-error{{end}}" id="confirm_passwd" name="confirm_passwd" type="password" required /> + <label class="req" for="admin_confirm_passwd">{{.i18n.Tr "install.confirm_password"}}</label> + <input class="ipt ipt-large ipt-radius {{if .Err_AdminPasswd}}ipt-error{{end}}" id="admin_confirm_passwd" name="admin_confirm_passwd" type="password" required /> </div> <div class="field"> <label class="req" for="admin_email">{{.i18n.Tr "install.admin_email"}}</label> diff --git a/templates/repo/commits_table.tmpl b/templates/repo/commits_table.tmpl index bd3777b46e..4c8141ab17 100644 --- a/templates/repo/commits_table.tmpl +++ b/templates/repo/commits_table.tmpl @@ -32,7 +32,7 @@ {{end}} </td> <td class="sha"><a rel="nofollow" class="label label-green" href="{{AppSubUrl}}/{{$username}}/{{$reponame}}/commit/{{.Id}} ">{{SubStr .Id.String 0 10}} </a></td> - <td class="message"><span class="text-truncate">{{Str2html .Summary}}</span></td> + <td class="message"><span class="text-truncate">{{RenderCommitMessage .Summary $.RepoLink}}</span></td> <td class="date">{{TimeSince .Author.When $.Lang}}</td> </tr> {{end}} diff --git a/templates/repo/diff.tmpl b/templates/repo/diff.tmpl index 225175e8d1..3d4a8b1fa7 100644 --- a/templates/repo/diff.tmpl +++ b/templates/repo/diff.tmpl @@ -17,7 +17,7 @@ <div class="panel panel-info panel-radius diff-head-box"> <div class="panel-header"> <a class="pull-right btn btn-blue btn-header btn-medium btn-radius" rel="nofollow" href="{{.SourcePath}}">{{.i18n.Tr "repo.diff.browse_source"}}</a> - <h4 class="commit-message">{{Str2html .Commit.Message}}</h4> + <h4 class="commit-message">{{RenderCommitMessage .Commit.Message $.RepoLink}}</h4> </div> <div class="panel-body"> <span class="pull-right"> @@ -74,11 +74,11 @@ </ol> </div> - {{range .Diff.Files}} + {{range $i, $file := .Diff.Files}} <div class="panel panel-radius diff-file-box diff-box file-content" id="diff-{{.Index}}"> <div class="panel-header"> <div class="diff-counter count pull-left"> - {{if not .IsBin}} + {{if not $file.IsBin}} <span class="add" data-line="{{.Addition}}">+ {{.Addition}}</span> <span class="bar"> <span class="pull-left add"></span> @@ -90,9 +90,9 @@ {{end}} </div> <a class="btn btn-gray btn-header btn-radius text-black pull-right" rel="nofollow" href="{{$.SourcePath}}/{{.Name}}">{{$.i18n.Tr "repo.diff.view_file"}}</a> - <span class="file">{{.Name}}</span> + <span class="file">{{$file.Name}}</span> </div> - {{$isImage := (call $.IsImageFile .Name)}} + {{$isImage := (call $.IsImageFile $file.Name)}} <div class="panel-body file-body file-code code-view code-diff"> {{if $isImage}} <div class="text-center"> @@ -101,18 +101,18 @@ {{else}} <table> <tbody> - {{range .Sections}} - {{range .Lines}} - <tr class="{{DiffLineTypeToStr .Type}}-code nl-1 ol-1"> + {{range $j, $section := $file.Sections}} + {{range $k, $line := $section.Lines}} + <tr class="{{DiffLineTypeToStr .Type}}-code nl-{{$i}} ol-{{$i}}"> <td class="lines-num lines-num-old"> - <span rel="L1">{{if .LeftIdx}}{{.LeftIdx}}{{end}}</span> + <span rel="diff-{{Add $i 1}}L{{$j}}{{$k}}">{{if $line.LeftIdx}}{{$line.LeftIdx}}{{end}}</span> </td> <td class="lines-num lines-num-new"> - <span rel="L1">{{if .RightIdx}}{{.RightIdx}}{{end}}</span> + <span rel="diff-{{Add $i 1}}L{{$j}}{{$k}}">{{if $line.RightIdx}}{{$line.RightIdx}}{{end}}</span> </td> <td class="lines-code"> - <pre>{{.Content}}</pre> + <pre>{{$line.Content}}</pre> </td> </tr> {{end}} diff --git a/templates/repo/view_list.tmpl b/templates/repo/view_list.tmpl index fed91effa7..06536b4728 100644 --- a/templates/repo/view_list.tmpl +++ b/templates/repo/view_list.tmpl @@ -14,7 +14,7 @@ </span> <span class="last-commit"><a href="{{.RepoLink}}/commit/{{.LastCommit.Id}}" rel="nofollow"> <strong>{{ShortSha .LastCommit.Id.String}}</strong></a> - <span class="text-truncate">{{Str2html .LastCommit.Summary}}</span> + <span class="text-truncate">{{RenderCommitMessage .LastCommit.Summary .RepoLink}}</span> </span> <span class="age right">{{TimeSince .LastCommit.Author.When $.Lang}}</span> </th> @@ -53,7 +53,7 @@ <a rel="nofollow" class="label label-green" href="{{AppSubUrl}}/{{$.Username}}/{{$.Reponame}}/commit/{{$commit.Id}} ">{{SubStr $commit.Id.String 0 10}} </a> </td> <td class="message"> - <span class="text-truncate">{{Str2html $commit.Summary}}</span> + <span class="text-truncate">{{RenderCommitMessage $commit.Summary $.RepoLink}}</span> </td> <td class="age">{{TimeSince $commit.Committer.When $.Lang}}</td> </tr> diff --git a/templates/user/settings/email.tmpl b/templates/user/settings/email.tmpl index fc8bcbbcf9..c99e6a0415 100644 --- a/templates/user/settings/email.tmpl +++ b/templates/user/settings/email.tmpl @@ -36,19 +36,21 @@ {{end}} </li> {{end}} - <form action="{{AppSubUrl}}/user/settings/email" method="post"> - {{.CsrfTokenHtml}} - <p class="panel-header"><strong>{{.i18n.Tr "settings.add_new_email"}}</strong></p> - <p class="field"> + </ul> + <div class="panel-header"> + <strong>{{.i18n.Tr "settings.add_new_email"}}</strong> + </div> + <form class="form form-align panel-body" id="add-email-form" action="{{AppSubUrl}}/user/settings/email" method="post"> + {{.CsrfTokenHtml}} + <p class="field"> <label class="req" for="email">{{.i18n.Tr "email"}}</label> - <input class="ipt ipt-radius" id="email" name="email" type="text" required /> + <input class="ipt ipt-large ipt-radius" id="email" name="email" type="text" required /> </p> <p class="field"> <label></label> - <button class="btn btn-green btn-radius" id="email-add-btn">{{.i18n.Tr "settings.add_email"}}</button> + <button class="btn btn-green btn-large btn-radius" id="email-add-btn">{{.i18n.Tr "settings.add_email"}}</button> </p> - </form> - </ul> + </form> </div> </div> </div> diff --git a/templates/user/settings/nav.tmpl b/templates/user/settings/nav.tmpl index 780f1218a1..d8003c8ba7 100644 --- a/templates/user/settings/nav.tmpl +++ b/templates/user/settings/nav.tmpl @@ -4,7 +4,7 @@ <ul class="menu menu-vertical switching-list grid-1-5 left"> <li {{if .PageIsSettingsProfile}}class="current"{{end}}><a href="{{AppSubUrl}}/user/settings">{{.i18n.Tr "settings.profile"}}</a></li> <li {{if .PageIsSettingsPassword}}class="current"{{end}}><a href="{{AppSubUrl}}/user/settings/password">{{.i18n.Tr "settings.password"}}</a></li> - <li {{if .PageIsSettingsEmail}}class="current"{{end}}><a href="{{AppSubUrl}}/user/settings/email">{{.i18n.Tr "settings.emails"}}</a></li> + <li {{if .PageIsSettingsEmails}}class="current"{{end}}><a href="{{AppSubUrl}}/user/settings/email">{{.i18n.Tr "settings.emails"}}</a></li> <li {{if .PageIsSettingsSSHKeys}}class="current"{{end}}><a href="{{AppSubUrl}}/user/settings/ssh">{{.i18n.Tr "settings.ssh_keys"}}</a></li> <li {{if .PageIsSettingsSocial}}class="current"{{end}}><a href="{{AppSubUrl}}/user/settings/social">{{.i18n.Tr "settings.social"}}</a></li> <li {{if .PageIsSettingsApplications}}class="current"{{end}}><a href="{{AppSubUrl}}/user/settings/applications">{{.i18n.Tr "settings.applications"}}</a></li> |