Version Description
- Release 2017-01-21
- Settings panel switched to saving via form submit instead of an Ajax request to avoid conflicts with security plugins
- Settings panel cleanup
Download this release
Release Info
Developer | mrsztuczkens |
Plugin | jQuery Pin It Button for Images |
Version | 2.2.0 |
Comparing to | |
See all releases |
Code changes from version 2.1.3 to 2.2.0
- css/admin-ad.css +0 -25
- css/admin.css +1 -1
- css/client.css +1 -1
- images/settings_link.png +0 -0
- images/settings_link_pro.png +0 -0
- images/settings_tabs.png +0 -0
- includes/admin/JPIBFI_Welcome_Screen.php +140 -0
- includes/admin/includes/JPIBFI_Pro_Nag.php +81 -0
- includes/admin/includes/jpibfi_admin_notice.php +29 -0
- includes/admin/includes/{jpibfi-ajax-result-builder.php → jpibfi_ajax_result_builder.php} +0 -0
- includes/admin/includes/jpibfi_nag.php +30 -0
- includes/admin/includes/{jpibfi-nag.php → jpibfi_review_nag.php} +12 -33
- includes/admin/jpibfi-admin.php +48 -60
- includes/admin/settings/jpibfi-import-export-settings.php +17 -18
- includes/admin/settings/jpibfi-selection-settings.php +2 -1
- includes/admin/settings/jpibfi-settings-base.php +28 -76
- includes/admin/settings/{jpibfi-validator.php → jpibfi_validator.php} +47 -34
- includes/includes/jpibfi-option-converter.php +7 -0
- includes/jpibfi.php +0 -6
- includes/public/class-jpibfi-client.php +145 -116
- jquery-pin-it-button-for-images.php +13 -2
- js/jpibfi-ad.admin.js +0 -10
- js/jpibfi.admin.js +9 -9
- js/jpibfi.client.js +1 -1
- languages/jquery-pin-it-button-for-images.pot +210 -73
- readme.txt +9 -1
css/admin-ad.css
DELETED
@@ -1,25 +0,0 @@
|
|
1 |
-
div.jpibfi-pro-notice {
|
2 |
-
overflow: hidden;
|
3 |
-
}
|
4 |
-
|
5 |
-
div.jpibfi-pro-notice p {
|
6 |
-
display:block;
|
7 |
-
float:left;
|
8 |
-
font-size: 1em;
|
9 |
-
font-weight: 600;
|
10 |
-
color: #23282d;
|
11 |
-
margin: 5px 0;
|
12 |
-
}
|
13 |
-
|
14 |
-
div.jpibfi-pro-notice a {
|
15 |
-
color: orange;
|
16 |
-
}
|
17 |
-
|
18 |
-
div.jpibfi-pro-notice span {
|
19 |
-
display:block;
|
20 |
-
float: right;
|
21 |
-
font-size: 1em;
|
22 |
-
padding: 2px 10px;
|
23 |
-
margin: 0.6em 0;
|
24 |
-
cursor: pointer;
|
25 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
css/admin.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
@charset "UTF-8";a.pinit-button.old_default,a.pinit-button.old_default span{height:41px!important;width:65px!important}a.pinit-button.custom,a.pinit-button.old_default{text-indent:-9999em!important}a.pinit-button.custom span,a.pinit-button.old_default span{display:block;background-color:transparent!important;background-repeat:no-repeat!important;background-position:0 0!important}a.pinit-button.old_default span{background-image:url(images/pinit-button.png)!important;background-size:65px 41px!important}a.pinit-button.default{display:block;overflow:hidden;text-decoration:none;color:#fff;background-color:#bd081c}a.pinit-button.default:hover{background-color:#a50718}a.pinit-button.default.jpibfi-size-small{height:43.2px}a.pinit-button.default.jpibfi-size-small.jpibfi-button-round,a.pinit-button.default.jpibfi-size-small.jpibfi-button-rounded-square,a.pinit-button.default.jpibfi-size-small.jpibfi-button-square{width:43.2px}a.pinit-button.default.jpibfi-size-small.jpibfi-button-rectangle,a.pinit-button.default.jpibfi-size-small.jpibfi-button-rounded-rectangle{width:64.8px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-circle{font-size:28.8px}a.pinit-button.default.jpibfi-size-
|
1 |
+
@charset "UTF-8";a.pinit-button.old_default,a.pinit-button.old_default span{height:41px!important;width:65px!important}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-circle,a.pinit-button.default.jpibfi-size-small .jpibfi-icon-plain{font-size:28.8px}a.pinit-button.custom,a.pinit-button.old_default{text-indent:-9999em!important}a.pinit-button.custom span,a.pinit-button.old_default span{display:block;background-color:transparent!important;background-repeat:no-repeat!important;background-position:0 0!important}a.pinit-button.old_default span{background-image:url(images/pinit-button.png)!important;background-size:65px 41px!important}a.pinit-button.default{display:block;overflow:hidden;text-decoration:none;color:#fff;background-color:#bd081c}a.pinit-button.default:hover{background-color:#a50718}a.pinit-button.default.jpibfi-size-small{height:43.2px}a.pinit-button.default.jpibfi-size-small.jpibfi-button-round,a.pinit-button.default.jpibfi-size-small.jpibfi-button-rounded-square,a.pinit-button.default.jpibfi-size-small.jpibfi-button-square{width:43.2px}a.pinit-button.default.jpibfi-size-small.jpibfi-button-rectangle,a.pinit-button.default.jpibfi-size-small.jpibfi-button-rounded-rectangle{width:64.8px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-circle:before{margin-top:-14.4px;margin-left:-12.38px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-pushpin,a.pinit-button.default.jpibfi-size-small .jpibfi-icon-thumb-tack{font-size:17.28px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-plain:before{margin-top:-13.5px;margin-left:-10.06px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-thumb-tack:before{margin-top:-7.97px;margin-left:-5.54px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-pushpin:before{margin-top:-8.64px;margin-left:-8.64px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-pinterest2{font-size:28.8px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-circle,a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-plain{font-size:36px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-pinterest2:before{margin-top:-14.4px;margin-left:-14.4px}a.pinit-button.default.jpibfi-size-normal{height:54px}a.pinit-button.default.jpibfi-size-normal.jpibfi-button-round,a.pinit-button.default.jpibfi-size-normal.jpibfi-button-rounded-square,a.pinit-button.default.jpibfi-size-normal.jpibfi-button-square{width:54px}a.pinit-button.default.jpibfi-size-large.jpibfi-button-round,a.pinit-button.default.jpibfi-size-large.jpibfi-button-rounded-square,a.pinit-button.default.jpibfi-size-large.jpibfi-button-square,a.pinit-button.default.jpibfi-size-normal.jpibfi-button-rectangle,a.pinit-button.default.jpibfi-size-normal.jpibfi-button-rounded-rectangle{width:81px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-circle:before{margin-top:-18px;margin-left:-15.47px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-pushpin,a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-thumb-tack{font-size:21.6px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-plain:before{margin-top:-16.88px;margin-left:-12.58px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-thumb-tack:before{margin-top:-9.96px;margin-left:-6.92px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-pushpin:before{margin-top:-10.8px;margin-left:-10.8px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-pinterest2{font-size:36px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-circle,a.pinit-button.default.jpibfi-size-large .jpibfi-icon-plain{font-size:54px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-pinterest2:before{margin-top:-18px;margin-left:-18px}a.pinit-button.default.jpibfi-size-large{height:81px}a.pinit-button.default.jpibfi-size-large.jpibfi-button-rectangle,a.pinit-button.default.jpibfi-size-large.jpibfi-button-rounded-rectangle{width:121.5px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-circle:before{margin-top:-27px;margin-left:-23.2px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-pushpin,a.pinit-button.default.jpibfi-size-large .jpibfi-icon-thumb-tack{font-size:32.4px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-plain:before{margin-top:-25.31px;margin-left:-18.86px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-thumb-tack:before{margin-top:-14.93px;margin-left:-10.38px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-pushpin:before{margin-top:-16.2px;margin-left:-16.2px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-pinterest2{font-size:54px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-pinterest2:before{margin-top:-27px;margin-left:-27px}a.pinit-button.default.jpibfi-button-rounded-rectangle,a.pinit-button.default.jpibfi-button-rounded-square{border-radius:10px}a.pinit-button.default.jpibfi-button-round{border-radius:50%}a.pinit-button.default [class*=" jpibfi-icon-"],a.pinit-button.default [class^=jpibfi-icon-]{color:#fff;display:block}a.pinit-button.default [class*=" jpibfi-icon-"]:hover,a.pinit-button.default [class^=jpibfi-icon-]:hover{color:#fff}a.pinit-button.default [class*=" jpibfi-icon-"]:before,a.pinit-button.default [class^=jpibfi-icon-]:before{display:block;position:absolute;top:50%;left:50%}@font-face{font-family:jpibfi-font;src:url(fonts/jpibfi-font.eot?ifsn2k);src:url(fonts/jpibfi-font.eot?ifsn2k#iefix) format("embedded-opentype"),url(fonts/jpibfi-font.ttf?ifsn2k) format("truetype"),url(fonts/jpibfi-font.woff?ifsn2k) format("woff"),url(fonts/jpibfi-font.svg?ifsn2k#jpibfi-font) format("svg");font-weight:400;font-style:normal}[class*=" jpibfi-icon-"],[class^=jpibfi-icon-]{font-family:jpibfi-font!important;speak:none;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.jpibfi-icon-circle:before{content:""}.jpibfi-icon-plain:before{content:""}.jpibfi-icon-thumb-tack:before{content:""}.jpibfi-icon-pushpin:before{content:""}.jpibfi-icon-pinterest2:before{content:""}.frizzly-sortable li{cursor:move}input[type=checkbox]~label{padding-left:5px}input#custom_image_url{width:100%}div.checkbox-indented{margin-left:20px}table.jpibfi-inner-table td,table.jpibfi-inner-table th{max-width:350px}table.jpibfi-inner-table th{padding:5px;width:auto}table.jpibfi-inner-table td{vertical-align:top;padding:0 15px 0 10px}a.pinit-button{display:block;position:relative}
|
css/client.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
@charset "UTF-8";a.pinit-button.old_default,a.pinit-button.old_default span{height:41px!important;width:65px!important}a.pinit-button.custom,a.pinit-button.old_default{text-indent:-9999em!important}a.pinit-button.custom span,a.pinit-button.old_default span{display:block;background-color:transparent!important;background-repeat:no-repeat!important;background-position:0 0!important}a.pinit-button.old_default span{background-image:url(images/pinit-button.png)!important;background-size:65px 41px!important}a.pinit-button.default{display:block;overflow:hidden;text-decoration:none;color:#fff;background-color:#bd081c}a.pinit-button.default:hover{background-color:#a50718}a.pinit-button.default.jpibfi-size-small{height:43.2px}a.pinit-button.default.jpibfi-size-small.jpibfi-button-round,a.pinit-button.default.jpibfi-size-small.jpibfi-button-rounded-square,a.pinit-button.default.jpibfi-size-small.jpibfi-button-square{width:43.2px}a.pinit-button.default.jpibfi-size-small.jpibfi-button-rectangle,a.pinit-button.default.jpibfi-size-small.jpibfi-button-rounded-rectangle{width:64.8px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-circle{font-size:28.8px}a.pinit-button.default.jpibfi-size-
|
1 |
+
@charset "UTF-8";a.pinit-button.old_default,a.pinit-button.old_default span{height:41px!important;width:65px!important}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-circle,a.pinit-button.default.jpibfi-size-small .jpibfi-icon-plain{font-size:28.8px}a.pinit-button.custom,a.pinit-button.old_default{text-indent:-9999em!important}a.pinit-button.custom span,a.pinit-button.old_default span{display:block;background-color:transparent!important;background-repeat:no-repeat!important;background-position:0 0!important}a.pinit-button.old_default span{background-image:url(images/pinit-button.png)!important;background-size:65px 41px!important}a.pinit-button.default{display:block;overflow:hidden;text-decoration:none;color:#fff;background-color:#bd081c}a.pinit-button.default:hover{background-color:#a50718}a.pinit-button.default.jpibfi-size-small{height:43.2px}a.pinit-button.default.jpibfi-size-small.jpibfi-button-round,a.pinit-button.default.jpibfi-size-small.jpibfi-button-rounded-square,a.pinit-button.default.jpibfi-size-small.jpibfi-button-square{width:43.2px}a.pinit-button.default.jpibfi-size-small.jpibfi-button-rectangle,a.pinit-button.default.jpibfi-size-small.jpibfi-button-rounded-rectangle{width:64.8px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-circle:before{margin-top:-14.4px;margin-left:-12.38px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-pushpin,a.pinit-button.default.jpibfi-size-small .jpibfi-icon-thumb-tack{font-size:17.28px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-plain:before{margin-top:-13.5px;margin-left:-10.06px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-thumb-tack:before{margin-top:-7.97px;margin-left:-5.54px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-pushpin:before{margin-top:-8.64px;margin-left:-8.64px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-pinterest2{font-size:28.8px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-circle,a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-plain{font-size:36px}a.pinit-button.default.jpibfi-size-small .jpibfi-icon-pinterest2:before{margin-top:-14.4px;margin-left:-14.4px}a.pinit-button.default.jpibfi-size-normal{height:54px}a.pinit-button.default.jpibfi-size-normal.jpibfi-button-round,a.pinit-button.default.jpibfi-size-normal.jpibfi-button-rounded-square,a.pinit-button.default.jpibfi-size-normal.jpibfi-button-square{width:54px}a.pinit-button.default.jpibfi-size-large.jpibfi-button-round,a.pinit-button.default.jpibfi-size-large.jpibfi-button-rounded-square,a.pinit-button.default.jpibfi-size-large.jpibfi-button-square,a.pinit-button.default.jpibfi-size-normal.jpibfi-button-rectangle,a.pinit-button.default.jpibfi-size-normal.jpibfi-button-rounded-rectangle{width:81px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-circle:before{margin-top:-18px;margin-left:-15.47px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-pushpin,a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-thumb-tack{font-size:21.6px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-plain:before{margin-top:-16.88px;margin-left:-12.58px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-thumb-tack:before{margin-top:-9.96px;margin-left:-6.92px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-pushpin:before{margin-top:-10.8px;margin-left:-10.8px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-pinterest2{font-size:36px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-circle,a.pinit-button.default.jpibfi-size-large .jpibfi-icon-plain{font-size:54px}a.pinit-button.default.jpibfi-size-normal .jpibfi-icon-pinterest2:before{margin-top:-18px;margin-left:-18px}a.pinit-button.default.jpibfi-size-large{height:81px}a.pinit-button.default.jpibfi-size-large.jpibfi-button-rectangle,a.pinit-button.default.jpibfi-size-large.jpibfi-button-rounded-rectangle{width:121.5px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-circle:before{margin-top:-27px;margin-left:-23.2px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-pushpin,a.pinit-button.default.jpibfi-size-large .jpibfi-icon-thumb-tack{font-size:32.4px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-plain:before{margin-top:-25.31px;margin-left:-18.86px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-thumb-tack:before{margin-top:-14.93px;margin-left:-10.38px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-pushpin:before{margin-top:-16.2px;margin-left:-16.2px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-pinterest2{font-size:54px}a.pinit-button.default.jpibfi-size-large .jpibfi-icon-pinterest2:before{margin-top:-27px;margin-left:-27px}a.pinit-button.default.jpibfi-button-rounded-rectangle,a.pinit-button.default.jpibfi-button-rounded-square{border-radius:10px}a.pinit-button.default.jpibfi-button-round{border-radius:50%}a.pinit-button.default [class*=" jpibfi-icon-"],a.pinit-button.default [class^=jpibfi-icon-]{color:#fff;display:block}a.pinit-button.default [class*=" jpibfi-icon-"]:hover,a.pinit-button.default [class^=jpibfi-icon-]:hover{color:#fff}a.pinit-button.default [class*=" jpibfi-icon-"]:before,a.pinit-button.default [class^=jpibfi-icon-]:before{display:block;position:absolute;top:50%;left:50%}@font-face{font-family:jpibfi-font;src:url(fonts/jpibfi-font.eot?ifsn2k);src:url(fonts/jpibfi-font.eot?ifsn2k#iefix) format("embedded-opentype"),url(fonts/jpibfi-font.ttf?ifsn2k) format("truetype"),url(fonts/jpibfi-font.woff?ifsn2k) format("woff"),url(fonts/jpibfi-font.svg?ifsn2k#jpibfi-font) format("svg");font-weight:400;font-style:normal}[class*=" jpibfi-icon-"],[class^=jpibfi-icon-]{font-family:jpibfi-font!important;speak:none;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.jpibfi-icon-circle:before{content:""}.jpibfi-icon-plain:before{content:""}.jpibfi-icon-thumb-tack:before{content:""}.jpibfi-icon-pushpin:before{content:""}.jpibfi-icon-pinterest2:before{content:""}a.pinit-button{position:absolute;display:none}
|
images/settings_link.png
ADDED
Binary file
|
images/settings_link_pro.png
ADDED
Binary file
|
images/settings_tabs.png
ADDED
Binary file
|
includes/admin/JPIBFI_Welcome_Screen.php
ADDED
@@ -0,0 +1,140 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
3 |
+
exit;
|
4 |
+
}
|
5 |
+
|
6 |
+
class JPIBFI_Welcome_Screen {
|
7 |
+
private $minimum_capability = 'manage_options';
|
8 |
+
private $transient_name = '_jpibfi_activation_redirect';
|
9 |
+
private $plugin_name;
|
10 |
+
private $file;
|
11 |
+
private $version;
|
12 |
+
|
13 |
+
function __construct( $file, $version ) {
|
14 |
+
$this->file = $file;
|
15 |
+
$this->version = $version;
|
16 |
+
|
17 |
+
$this->plugin_name = 'jQuery Pin It Button for Images Lite';
|
18 |
+
add_action( 'admin_menu', array( $this, 'admin_menus' ) );
|
19 |
+
add_action( 'admin_init', array( $this, 'redirect' ), 11 );
|
20 |
+
}
|
21 |
+
|
22 |
+
public function admin_menus() {
|
23 |
+
// About Page
|
24 |
+
add_dashboard_page(
|
25 |
+
__( 'Welcome to jQuery Pin It Button for Images', 'jquery-pin-it-button-for-images' ),
|
26 |
+
__( 'Welcome to jQuery Pin It Button for Images', 'jquery-pin-it-button-for-images' ),
|
27 |
+
$this->minimum_capability,
|
28 |
+
'jpibfi-welcome',
|
29 |
+
array( $this, 'welcome_message' )
|
30 |
+
);
|
31 |
+
|
32 |
+
// Now remove them from the menus so plugins that allow customizing the admin menu don't show them
|
33 |
+
remove_submenu_page( 'index.php', 'jpibfi-welcome' );
|
34 |
+
}
|
35 |
+
|
36 |
+
public function welcome_message() {
|
37 |
+
?>
|
38 |
+
<div class="wrap about-wrap">
|
39 |
+
<h1><?php printf( __( 'Welcome to %s %s', 'jquery-pin-it-button-for-images' ), $this->plugin_name, $this->version ); ?></h1>
|
40 |
+
|
41 |
+
<p class="about-text"><?php printf( __( 'Thank you for updating to the latest version! %s helps your readers share your images using Pinterest.', 'jquery-pin-it-button-for-images' ), $this->plugin_name, $this->version ); ?></p>
|
42 |
+
|
43 |
+
<hr/>
|
44 |
+
|
45 |
+
<div class="feature-section one-col">
|
46 |
+
<h2><?php _e( 'Settings', 'jquery-pin-it-button-for-images' ); ?></h2>
|
47 |
+
<p class="lead-description"><?php _e( 'The most important part of the plugin is the settings panel.', 'jquery-pin-it-button-for-images' ); ?></p>
|
48 |
+
</div>
|
49 |
+
|
50 |
+
<div class="feature-section two-col">
|
51 |
+
<div class="col">
|
52 |
+
<h3><?php _e( 'Finding the settings panel', 'jquery-pin-it-button-for-images' ); ?></h3>
|
53 |
+
<p><?php printf( __( 'You can find the plugin\'s settings panel in the <b>Settings</b> submenu under the name <b>%s</b>. There you can find all the settings the plugin allows you to adjust. All settings are divided into several tabs so you can find what you\'re looking for easily.', 'jquery-pin-it-button-for-images' ), $this->plugin_name ); ?></p>
|
54 |
+
</div>
|
55 |
+
<div class="col">
|
56 |
+
<?php
|
57 |
+
$file_name = 'settings_link.png';
|
58 |
+
?>
|
59 |
+
<img src="<?php echo plugin_dir_url( $this->file ) . '/images/' . $file_name ?>"
|
60 |
+
title="<?php _e( 'Settings link', 'jquery-pin-it-button-for-images' ); ?>"/>
|
61 |
+
</div>
|
62 |
+
</div>
|
63 |
+
<div class="feature-section one-col">
|
64 |
+
<h3><?php _e( 'Everything at hand', 'jquery-pin-it-button-for-images' ); ?></h3>
|
65 |
+
<p style="margin-left: 0; margin-right: 0;"><?php _e( 'You can find all the links mentioned below in the settings panel.', 'jquery-pin-it-button-for-images' ); ?></p>
|
66 |
+
<p style="text-align: center;"><img
|
67 |
+
src="<?php echo plugin_dir_url( $this->file ) . '/images/settings_tabs.png' ?>"
|
68 |
+
title="<?php _e( 'Settings tabs', 'jquery-pin-it-button-for-images' ); ?>"/>
|
69 |
+
</p>
|
70 |
+
</div>
|
71 |
+
<div class="feature-section two-col">
|
72 |
+
<div class="col">
|
73 |
+
<h3><?php _e( 'Selection settings', 'jquery-pin-it-button-for-images' ); ?></h3>
|
74 |
+
<p><?php _e( 'In this tab you choose which images should feature the "Pin it" button. You can choose images with specific classes or set up a minimum image resolution to prevent the button from showing up on small images. You can also choose on which pages the "Pin it" button should show up.', 'jquery-pin-it-button-for-images' ); ?></p>
|
75 |
+
<?php printf( __( '<a href="%s" class="button button-primary">Go to Selection settings</a>', 'jquery-pin-it-button-for-images' ), admin_url( 'options-general.php?page=jpibfi_settings&tab=select' ) ); ?>
|
76 |
+
</div>
|
77 |
+
<div class="col">
|
78 |
+
<h3><?php _e( 'Visual settings', 'jquery-pin-it-button-for-images' ); ?></h3>
|
79 |
+
<p><?php _e( 'This tab helps you configure how the "Pin it" button looks like and where it appears. If you want to use your own "Pin it" icon or make the button show up in the upper right corner of the image, this is the tab you are looking for.', 'jquery-pin-it-button-for-images' ); ?></p>
|
80 |
+
<?php printf( __( '<a href="%s" class="button button-primary">Go to Visual settings</a>', 'jquery-pin-it-button-for-images' ), admin_url( 'options-general.php?page=jpibfi_settings&tab=visual' ) ); ?>
|
81 |
+
</div>
|
82 |
+
</div>
|
83 |
+
<div class="feature-section two-col">
|
84 |
+
<div class="col">
|
85 |
+
<h3><?php _e( 'Advanced settings', 'jquery-pin-it-button-for-images' ); ?></h3>
|
86 |
+
<p><?php _e( 'In most cases you won\'t have to visit this tab ever. It features a few advanced settings used in most cases to resolve conflicts with other plugins.', 'jquery-pin-it-button-for-images' ); ?></p>
|
87 |
+
<?php printf( __( '<a href="%s" class="button button-primary">Go to Advanced settings</a>', 'jquery-pin-it-button-for-images' ), admin_url( 'options-general.php?page=jpibfi_settings&tab=advanced' ) ); ?>
|
88 |
+
</div>
|
89 |
+
<div class="col">
|
90 |
+
<h3><?php _e( 'Import/Export', 'jquery-pin-it-button-for-images' ); ?></h3>
|
91 |
+
<p><?php _e( 'If you would like to quickly copy the plugin\'s settings to another instance of WordPress, that\'s the place for you. You can download a file with your current settings and import it to another instance easily.', 'jquery-pin-it-button-for-images' ); ?></p>
|
92 |
+
<?php printf( __( '<a href="%s" class="button button-primary">Go to Import/Export</a>', 'jquery-pin-it-button-for-images' ), admin_url( 'options-general.php?page=jpibfi_settings&tab=import' ) ); ?>
|
93 |
+
</div>
|
94 |
+
</div>
|
95 |
+
|
96 |
+
<hr/>
|
97 |
+
|
98 |
+
<div class="feature-section one-col">
|
99 |
+
<h2><?php _e( 'Finding help', 'jquery-pin-it-button-for-images' ); ?></h2>
|
100 |
+
<p class="lead-description"><?php _e( 'If you\'re stuck and can\'t get the plugin to work the way you want it to, get help!', 'jquery-pin-it-button-for-images' ); ?></p>
|
101 |
+
</div>
|
102 |
+
|
103 |
+
<div class="feature-section two-col">
|
104 |
+
<div class="col">
|
105 |
+
<h3><?php _e( 'Documentation', 'jquery-pin-it-button-for-images' ); ?></h3>
|
106 |
+
<p><?php printf( __( 'If you are having difficulties with some aspects of the plugin, the first place to look for help is <a href="%s" target="_blank">the documentation</a> of the plugin. Chances are you will find what you are looking for there.', 'jquery-pin-it-button-for-images' ), 'https://highfiveplugins.com/jpibfi/jquery-pin-it-button-for-images-documentation/' ); ?></p>
|
107 |
+
</div>
|
108 |
+
<div class="col">
|
109 |
+
<h3><?php _e( 'Support', 'jquery-pin-it-button-for-images' ); ?></h3>
|
110 |
+
<p><?php
|
111 |
+
printf( __( 'Users of the free version of the plugin can find support <a href="%s" target="_blank">in the support forum</a>. When posting to the support forum, make sure you include the URL of your website.', 'jquery-pin-it-button-for-images' ), 'https://wordpress.org/support/plugin/jquery-pin-it-button-for-images' );
|
112 |
+
?></p>
|
113 |
+
</div>
|
114 |
+
</div>
|
115 |
+
<hr />
|
116 |
+
<div class="feature-section one-col">
|
117 |
+
<h2><?php _e( 'Next steps', 'jquery-pin-it-button-for-images' ); ?></h2>
|
118 |
+
<?php
|
119 |
+
$next_steps_text = sprintf( __( 'In most cases, the plugin is ready to go without any configuration. If there is anything you would like to change, go to the <a href="%s">Settings panel</a>.', 'jquery-pin-it-button-for-images' ), admin_url( 'options-general.php?page=jpibfi_settings' ) );
|
120 |
+
?>
|
121 |
+
<p class="lead-description"><?php echo $next_steps_text; ?></p>
|
122 |
+
</div>
|
123 |
+
</div>
|
124 |
+
<?php
|
125 |
+
}
|
126 |
+
|
127 |
+
public function redirect() {
|
128 |
+
if ( ! get_transient( $this->transient_name ) ) {
|
129 |
+
return;
|
130 |
+
}
|
131 |
+
delete_transient( $this->transient_name );
|
132 |
+
|
133 |
+
// Bail if activating from network, or bulk
|
134 |
+
if ( is_network_admin() || isset( $_GET['activate-multi'] ) ) {
|
135 |
+
return;
|
136 |
+
}
|
137 |
+
wp_safe_redirect( admin_url( 'index.php?page=jpibfi-welcome' ) );
|
138 |
+
exit;
|
139 |
+
}
|
140 |
+
}
|
includes/admin/includes/JPIBFI_Pro_Nag.php
ADDED
@@ -0,0 +1,81 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
require_once 'jpibfi_nag.php';
|
4 |
+
class JPIBFI_Pro_Nag extends JPIBFI_Nag {
|
5 |
+
|
6 |
+
private $cancel_notice_value;
|
7 |
+
private $stages;
|
8 |
+
private $plugin_name;
|
9 |
+
private $pro_link;
|
10 |
+
private $notice_key;
|
11 |
+
private $notice_text;
|
12 |
+
|
13 |
+
function __construct( $plugin_prefix, $plugin_name, $pro_link ) {
|
14 |
+
parent::__construct( $plugin_prefix );
|
15 |
+
$this->pro_link = $pro_link;
|
16 |
+
$this->plugin_name = $plugin_name;
|
17 |
+
$this->notice_key = $plugin_prefix . '_pro_notice';
|
18 |
+
$this->stages = array( 30, 60, 90, 135, 180, 225, 270, 315, 360, 405, 450, 495, 540, 585, 630, 675, 720 );
|
19 |
+
$this->cancel_notice_value = 'END';
|
20 |
+
|
21 |
+
$this->notice_text = sprintf(
|
22 |
+
__( "You've been using <b>%s</b> for quite some time now. How about checking out the Pro version? <a class='button button-primary' href='%s' target='_blank'>Yes, take me there →</a> <a class='button button-secondary' href='%s'>Thanks, but no thanks.</a>", 'jquery-pin-in-button-for-images' ),
|
23 |
+
$plugin_name,
|
24 |
+
$pro_link,
|
25 |
+
'%s'
|
26 |
+
);
|
27 |
+
|
28 |
+
$this->setup();
|
29 |
+
}
|
30 |
+
|
31 |
+
public function setup() {
|
32 |
+
if ( current_user_can( 'install_plugins' ) ) {
|
33 |
+
$this->catch_hide_notice();
|
34 |
+
add_action( 'admin_notices', array( $this, 'display_admin_notice' ) );
|
35 |
+
}
|
36 |
+
}
|
37 |
+
|
38 |
+
private function catch_hide_notice() {
|
39 |
+
if ( ! isset( $_GET[ $this->notice_key ] ) ) {
|
40 |
+
return;
|
41 |
+
}
|
42 |
+
global $current_user;
|
43 |
+
$datetime_install = $this->get_install_date();
|
44 |
+
$users_stage = $this->cancel_notice_value;
|
45 |
+
for($i = count( $this->stages )-1; $i >= 0 ; $i-- ){
|
46 |
+
$datetime_past = new DateTime( sprintf('-%s days', $this->stages[ $i ] ) );
|
47 |
+
if ( $datetime_past >= $datetime_install && ($i + 1 < count( $this->stages )) ) {
|
48 |
+
$users_stage = $this->stages[ $i + 1 ];
|
49 |
+
break;
|
50 |
+
}
|
51 |
+
}
|
52 |
+
update_user_meta( $current_user->ID, $this->notice_key, $users_stage );
|
53 |
+
wp_redirect( remove_query_arg( $this->notice_key ) );
|
54 |
+
exit;
|
55 |
+
}
|
56 |
+
|
57 |
+
/**
|
58 |
+
* Display the admin notice
|
59 |
+
*/
|
60 |
+
public function display_admin_notice() {
|
61 |
+
$current_user = wp_get_current_user();
|
62 |
+
$users_stage = get_user_meta( $current_user->ID, $this->notice_key, true );
|
63 |
+
|
64 |
+
if ( $this->cancel_notice_value === $users_stage ) {
|
65 |
+
return;
|
66 |
+
}
|
67 |
+
$users_stage = '' == $users_stage ? $this->stages[0] : $users_stage;
|
68 |
+
$datetime_install = $this->get_install_date();
|
69 |
+
$datetime_past = new DateTime( sprintf('-%s days', $users_stage ) );
|
70 |
+
|
71 |
+
if ( $datetime_past < $datetime_install ) {
|
72 |
+
return;
|
73 |
+
}
|
74 |
+
?>
|
75 |
+
<div class="notice notice-info is-dismissible">
|
76 |
+
<p><?php printf( $this->notice_text, add_query_arg( $this->notice_key, '1' ) ); ?></p>
|
77 |
+
</div>
|
78 |
+
<?php
|
79 |
+
}
|
80 |
+
|
81 |
+
}
|
includes/admin/includes/jpibfi_admin_notice.php
ADDED
@@ -0,0 +1,29 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
class JPIBFI_Admin_Notice {
|
4 |
+
private $type;
|
5 |
+
private $is_dismissible;
|
6 |
+
private $message;
|
7 |
+
|
8 |
+
|
9 |
+
/**
|
10 |
+
* JPIBFI_Admin_Notice constructor.
|
11 |
+
*
|
12 |
+
* @param $type string
|
13 |
+
* @param $is_dismissible boolean
|
14 |
+
* @param $message string
|
15 |
+
*/
|
16 |
+
public function __construct($type, $is_dismissible, $message) {
|
17 |
+
$this->type = $type;
|
18 |
+
$this->is_dismissible = $is_dismissible;
|
19 |
+
$this->message = $message;
|
20 |
+
}
|
21 |
+
|
22 |
+
function get_html() {
|
23 |
+
$class = sprintf( 'notice%1$s%2$s',
|
24 |
+
$this->is_dismissible ? ' is-dismissible' : '',
|
25 |
+
' notice-' . $this->type
|
26 |
+
);
|
27 |
+
return sprintf('<div class="%s"><p>%s</p></div>', $class, $this->message);
|
28 |
+
}
|
29 |
+
}
|
includes/admin/includes/{jpibfi-ajax-result-builder.php → jpibfi_ajax_result_builder.php}
RENAMED
File without changes
|
includes/admin/includes/jpibfi_nag.php
ADDED
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
abstract class JPIBFI_Nag {
|
4 |
+
|
5 |
+
protected $plugin_prefix;
|
6 |
+
private $install_date_key;
|
7 |
+
|
8 |
+
function __construct( $plugin_prefix ) {
|
9 |
+
$this->plugin_prefix = $plugin_prefix;
|
10 |
+
$this->install_date_key = $plugin_prefix . '_install_date';
|
11 |
+
}
|
12 |
+
|
13 |
+
protected function get_install_date() {
|
14 |
+
$date_string = get_site_option( $this->install_date_key, '' );
|
15 |
+
if ( $date_string == '' ) {
|
16 |
+
$date_string = $this->insert_install_date();
|
17 |
+
}
|
18 |
+
|
19 |
+
return new DateTime( $date_string );
|
20 |
+
}
|
21 |
+
|
22 |
+
protected function insert_install_date() {
|
23 |
+
$datetime_now = new DateTime();
|
24 |
+
$date_string = $datetime_now->format( 'Y-m-d' );
|
25 |
+
add_site_option( $this->install_date_key, $date_string );
|
26 |
+
|
27 |
+
return $date_string;
|
28 |
+
}
|
29 |
+
|
30 |
+
}
|
includes/admin/includes/{jpibfi-nag.php → jpibfi_review_nag.php}
RENAMED
@@ -1,24 +1,24 @@
|
|
1 |
<?php
|
2 |
|
|
|
3 |
/**
|
4 |
* Class JPIBFI_Nag
|
5 |
*
|
6 |
* Heavily influenced by What The File Plugin
|
7 |
* https://wordpress.org/plugins/what-the-file/
|
8 |
*/
|
9 |
-
class JPIBFI_Nag {
|
10 |
|
11 |
private $notice_key;
|
12 |
private $notice_text;
|
13 |
private $notice_period;
|
14 |
-
private $install_date_key;
|
15 |
|
16 |
function __construct($plugin_prefix, $plugin_name, $review_link, $period = '-10 days') {
|
|
|
17 |
$this->notice_key = $plugin_prefix . '_review_notice';
|
18 |
-
$this->install_date_key = $plugin_prefix . '_install_date';
|
19 |
|
20 |
$this->notice_text = sprintf(
|
21 |
-
__( "You've been using <b>%s</b> for some time now, could you please give it a review at wordpress.org? <
|
22 |
$plugin_name,
|
23 |
$review_link,
|
24 |
'%s'
|
@@ -31,7 +31,7 @@ class JPIBFI_Nag {
|
|
31 |
public function setup() {
|
32 |
if ( current_user_can( 'install_plugins' ) ) {
|
33 |
$this->catch_hide_notice();
|
34 |
-
$this
|
35 |
}
|
36 |
}
|
37 |
|
@@ -45,7 +45,10 @@ class JPIBFI_Nag {
|
|
45 |
exit;
|
46 |
}
|
47 |
|
48 |
-
|
|
|
|
|
|
|
49 |
$current_user = wp_get_current_user();
|
50 |
$hide_notice = get_user_meta( $current_user->ID, $this->notice_key, true );
|
51 |
|
@@ -53,38 +56,14 @@ class JPIBFI_Nag {
|
|
53 |
return;
|
54 |
}
|
55 |
|
56 |
-
// Get installation date
|
57 |
$datetime_install = $this->get_install_date();
|
58 |
$datetime_past = new DateTime( $this->notice_period );
|
59 |
|
60 |
-
if ( $datetime_past
|
61 |
-
|
62 |
-
}
|
63 |
-
}
|
64 |
-
|
65 |
-
private function get_install_date() {
|
66 |
-
$date_string = get_site_option( $this->install_date_key, '' );
|
67 |
-
if ( $date_string == '' ) {
|
68 |
-
$date_string = $this->insert_install_date();
|
69 |
}
|
70 |
-
|
71 |
-
return new DateTime( $date_string );
|
72 |
-
}
|
73 |
-
|
74 |
-
public function insert_install_date() {
|
75 |
-
$datetime_now = new DateTime();
|
76 |
-
$date_string = $datetime_now->format( 'Y-m-d' );
|
77 |
-
add_site_option( $this->install_date_key, $date_string );
|
78 |
-
|
79 |
-
return $date_string;
|
80 |
-
}
|
81 |
-
|
82 |
-
/**
|
83 |
-
* Display the admin notice
|
84 |
-
*/
|
85 |
-
public function display_admin_notice() {
|
86 |
?>
|
87 |
-
<div class="
|
88 |
<p><?php printf( $this->notice_text, add_query_arg( $this->notice_key, '1' ) ); ?></p>
|
89 |
</div>
|
90 |
<?php
|
1 |
<?php
|
2 |
|
3 |
+
require_once 'jpibfi_nag.php';
|
4 |
/**
|
5 |
* Class JPIBFI_Nag
|
6 |
*
|
7 |
* Heavily influenced by What The File Plugin
|
8 |
* https://wordpress.org/plugins/what-the-file/
|
9 |
*/
|
10 |
+
class JPIBFI_Review_Nag extends JPIBFI_Nag {
|
11 |
|
12 |
private $notice_key;
|
13 |
private $notice_text;
|
14 |
private $notice_period;
|
|
|
15 |
|
16 |
function __construct($plugin_prefix, $plugin_name, $review_link, $period = '-10 days') {
|
17 |
+
parent::__construct( $plugin_prefix );
|
18 |
$this->notice_key = $plugin_prefix . '_review_notice';
|
|
|
19 |
|
20 |
$this->notice_text = sprintf(
|
21 |
+
__( "You've been using <b>%s</b> for some time now, could you please give it a review at wordpress.org? <a class='button button-primary' href='%s' target='_blank'>Yes, take me there →</a> <a class='button button-secondary' href='%s'>I've already done this!</a>" ),
|
22 |
$plugin_name,
|
23 |
$review_link,
|
24 |
'%s'
|
31 |
public function setup() {
|
32 |
if ( current_user_can( 'install_plugins' ) ) {
|
33 |
$this->catch_hide_notice();
|
34 |
+
add_action( 'admin_notices', array( $this, 'display_admin_notice' ) );
|
35 |
}
|
36 |
}
|
37 |
|
45 |
exit;
|
46 |
}
|
47 |
|
48 |
+
/**
|
49 |
+
* Display the admin notice
|
50 |
+
*/
|
51 |
+
public function display_admin_notice() {
|
52 |
$current_user = wp_get_current_user();
|
53 |
$hide_notice = get_user_meta( $current_user->ID, $this->notice_key, true );
|
54 |
|
56 |
return;
|
57 |
}
|
58 |
|
|
|
59 |
$datetime_install = $this->get_install_date();
|
60 |
$datetime_past = new DateTime( $this->notice_period );
|
61 |
|
62 |
+
if ( $datetime_past < $datetime_install ) {
|
63 |
+
return;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
64 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
65 |
?>
|
66 |
+
<div class="notice notice-info is-dismissible">
|
67 |
<p><?php printf( $this->notice_text, add_query_arg( $this->notice_key, '1' ) ); ?></p>
|
68 |
</div>
|
69 |
<?php
|
includes/admin/jpibfi-admin.php
CHANGED
@@ -4,6 +4,8 @@ class JPIBFI_Admin {
|
|
4 |
|
5 |
private $file;
|
6 |
private $version;
|
|
|
|
|
7 |
|
8 |
private $admin_screen_hook = '';
|
9 |
|
@@ -16,21 +18,22 @@ class JPIBFI_Admin {
|
|
16 |
$this->file = $file;
|
17 |
$this->version = $version;
|
18 |
|
19 |
-
$this->tab_modules
|
|
|
|
|
20 |
|
21 |
$this->load_dependencies();
|
22 |
-
$this->
|
23 |
|
|
|
24 |
add_action( 'admin_menu', array( $this, 'print_admin_page_action' ) );
|
25 |
add_action( 'admin_enqueue_scripts', array( $this, 'add_admin_scripts' ) );
|
26 |
|
27 |
$jpibfi_plugin = plugin_basename( $this->file );
|
28 |
add_filter( "plugin_action_links_$jpibfi_plugin", array( $this, 'add_settings_link' ) );
|
29 |
add_action( 'admin_notices', array( $this, 'show_ad' ), 11 );
|
30 |
-
|
31 |
-
add_action( 'admin_notices', array( $this, 'show_pro_ad' ) );
|
32 |
add_filter( 'plugin_row_meta', array( $this, 'plugin_meta_links' ), 10, 2 );
|
33 |
-
add_action( 'wp_ajax_jpibfi_remove_pro_ad', array( $this, 'remove_pro_ad' ) );
|
34 |
}
|
35 |
|
36 |
function add_settings_link( $links ) {
|
@@ -49,24 +52,28 @@ class JPIBFI_Admin {
|
|
49 |
|
50 |
private function load_dependencies() {
|
51 |
$deps = array(
|
52 |
-
'
|
|
|
|
|
53 |
'settings/jpibfi-settings-base.php',
|
54 |
-
'settings/
|
55 |
'settings/jpibfi-import-export-settings.php',
|
56 |
'settings/jpibfi-selection-settings.php',
|
57 |
'settings/jpibfi-visual-settings.php',
|
58 |
-
|
59 |
);
|
60 |
foreach ( $deps as $dep ) {
|
61 |
require_once $dep;
|
62 |
}
|
63 |
}
|
64 |
|
65 |
-
private function
|
66 |
$this->add_tab_module( new JPIBFI_Selection_Settings() );
|
67 |
$this->add_tab_module( new JPIBFI_Visual_Settings() );
|
68 |
$this->add_tab_module( new JPIBFI_Advanced_Settings() );
|
69 |
$this->add_tab_module( new JPIBFI_Import_Export_Settings() );
|
|
|
|
|
70 |
}
|
71 |
|
72 |
public function print_admin_page_action() {
|
@@ -86,25 +93,26 @@ class JPIBFI_Admin {
|
|
86 |
if ( $this->admin_screen_hook === $hook ) {
|
87 |
$this->add_settings_scripts();
|
88 |
}
|
89 |
-
|
90 |
-
if ( 'plugins.php' === $hook ) {
|
91 |
-
$this->add_remove_ad_scripts();
|
92 |
-
}
|
93 |
}
|
94 |
|
95 |
private function add_settings_scripts() {
|
96 |
$plugin_dir_url = plugin_dir_url( $this->file );
|
97 |
|
98 |
wp_enqueue_style( 'jquery-pin-it-button-admin-style', $plugin_dir_url . 'css/admin.css', array(), $this->version, 'all' );
|
99 |
-
wp_enqueue_style( 'jpibfi-ad', $plugin_dir_url . 'css/admin-ad.css', array(), $this->version, 'all' );
|
100 |
|
101 |
$slug = isset( $_GET['tab'] ) ? $_GET['tab'] : 'select';
|
102 |
$tab_mod = $this->get_tab( $slug );
|
103 |
$settings = array(
|
104 |
-
'ajax' => $tab_mod->get_settings_ajax(),
|
105 |
'tabs' => $this->get_tabs(),
|
106 |
'currentTab' => $slug,
|
107 |
'page' => 'jpibfi_settings',
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
108 |
'links' => array(
|
109 |
array(
|
110 |
'url' => 'https://highfiveplugins.com/jpibfi/jquery-pin-it-button-for-images-documentation/',
|
@@ -113,12 +121,12 @@ class JPIBFI_Admin {
|
|
113 |
array(
|
114 |
'url' => 'https://wordpress.org/support/plugin/jquery-pin-it-button-for-images',
|
115 |
'label' => __( 'Support', 'jquery-pin-it-button-for-images' )
|
116 |
-
)
|
117 |
),
|
118 |
'settings' => $tab_mod->get_settings_configuration(),
|
119 |
'i18n' => array(
|
120 |
-
'editor'
|
121 |
-
'status'
|
122 |
),
|
123 |
);
|
124 |
$settings['version'] = 'lite';
|
@@ -153,55 +161,40 @@ class JPIBFI_Admin {
|
|
153 |
<?php
|
154 |
}
|
155 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
156 |
public function show_ad() {
|
157 |
global $hook_suffix;
|
158 |
if ( $hook_suffix === $this->admin_screen_hook ) {
|
159 |
?>
|
160 |
-
<div class="
|
161 |
<p>
|
162 |
-
<?php
|
163 |
-
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
),
|
168 |
-
array( 'a' => array( 'href' => array(), 'target' => array() ) )
|
169 |
-
); ?>
|
170 |
</p>
|
171 |
</div>
|
172 |
<?php
|
173 |
}
|
174 |
}
|
175 |
|
176 |
-
|
177 |
-
|
178 |
-
|
179 |
-
wp_enqueue_script( 'jpibfi-ad', $plugin_dir_url . 'js/jpibfi-ad.admin.js', array( 'jquery' ), $this->version, false );
|
180 |
-
}
|
181 |
-
|
182 |
-
function show_nag() {
|
183 |
-
require_once 'includes/jpibfi-nag.php';
|
184 |
-
new JPIBFI_Nag('jpibfi', 'jQuery Pin It Button For Images', 'http://wordpress.org/support/view/plugin-reviews/jquery-pin-it-button-for-images', '-10 days');
|
185 |
-
}
|
186 |
|
187 |
-
|
188 |
-
|
189 |
-
$hooks = array();
|
190 |
-
$hooks[] = $this->admin_screen_hook;
|
191 |
-
if ( get_option( 'jpibfi_pro_ad' ) ) {
|
192 |
-
$hooks[] = 'plugins.php';
|
193 |
-
}
|
194 |
-
|
195 |
-
if ( in_array( $hook_suffix, $hooks ) ) {
|
196 |
-
$show_close = 'plugins.php' == $hook_suffix;
|
197 |
-
?>
|
198 |
-
<div class="updated jpibfi-pro-notice">
|
199 |
-
<p><?php echo sprintf( __( 'jQuery Pin It Button for Images Pro is available. Click <a target="_blank" href="%s">here</a> to learn more.', 'jquery-pin-it-button-for-images' ), 'https://highfiveplugins.com/downloads/jquery-pin-it-button-for-images-pro/' ); ?></p>
|
200 |
-
<?php if ( $show_close ): ?><span id="jpibfi_remove_ad"
|
201 |
-
class="dashicons dashicons-no"></span><?php endif; ?>
|
202 |
-
</div>
|
203 |
-
<?php
|
204 |
-
}
|
205 |
}
|
206 |
|
207 |
function plugin_meta_links( $links, $file ) {
|
@@ -212,9 +205,4 @@ class JPIBFI_Admin {
|
|
212 |
|
213 |
return $links;
|
214 |
}
|
215 |
-
|
216 |
-
function remove_pro_ad() {
|
217 |
-
delete_option( 'jpibfi_pro_ad' );
|
218 |
-
wp_die();
|
219 |
-
}
|
220 |
}
|
4 |
|
5 |
private $file;
|
6 |
private $version;
|
7 |
+
private $save_settings_action;
|
8 |
+
private $save_settings_tab;
|
9 |
|
10 |
private $admin_screen_hook = '';
|
11 |
|
18 |
$this->file = $file;
|
19 |
$this->version = $version;
|
20 |
|
21 |
+
$this->tab_modules = array();
|
22 |
+
$this->save_settings_action = 'jpibfi_save_settings';
|
23 |
+
$this->save_settings_tab = 'jpibfi_save_settings_tab';
|
24 |
|
25 |
$this->load_dependencies();
|
26 |
+
$this->setup();
|
27 |
|
28 |
+
add_action( 'admin_init', array( $this, 'save_settings' ) );
|
29 |
add_action( 'admin_menu', array( $this, 'print_admin_page_action' ) );
|
30 |
add_action( 'admin_enqueue_scripts', array( $this, 'add_admin_scripts' ) );
|
31 |
|
32 |
$jpibfi_plugin = plugin_basename( $this->file );
|
33 |
add_filter( "plugin_action_links_$jpibfi_plugin", array( $this, 'add_settings_link' ) );
|
34 |
add_action( 'admin_notices', array( $this, 'show_ad' ), 11 );
|
35 |
+
add_action( 'admin_init', array( $this, 'show_nags' ) );
|
|
|
36 |
add_filter( 'plugin_row_meta', array( $this, 'plugin_meta_links' ), 10, 2 );
|
|
|
37 |
}
|
38 |
|
39 |
function add_settings_link( $links ) {
|
52 |
|
53 |
private function load_dependencies() {
|
54 |
$deps = array(
|
55 |
+
'JPIBFI_Welcome_Screen.php',
|
56 |
+
'includes/jpibfi_ajax_result_builder.php',
|
57 |
+
'includes/jpibfi_admin_notice.php',
|
58 |
'settings/jpibfi-settings-base.php',
|
59 |
+
'settings/jpibfi_validator.php',
|
60 |
'settings/jpibfi-import-export-settings.php',
|
61 |
'settings/jpibfi-selection-settings.php',
|
62 |
'settings/jpibfi-visual-settings.php',
|
63 |
+
'settings/jpibfi-advanced-settings.php',
|
64 |
);
|
65 |
foreach ( $deps as $dep ) {
|
66 |
require_once $dep;
|
67 |
}
|
68 |
}
|
69 |
|
70 |
+
private function setup() {
|
71 |
$this->add_tab_module( new JPIBFI_Selection_Settings() );
|
72 |
$this->add_tab_module( new JPIBFI_Visual_Settings() );
|
73 |
$this->add_tab_module( new JPIBFI_Advanced_Settings() );
|
74 |
$this->add_tab_module( new JPIBFI_Import_Export_Settings() );
|
75 |
+
|
76 |
+
new JPIBFI_Welcome_Screen( $this->file, $this->version );
|
77 |
}
|
78 |
|
79 |
public function print_admin_page_action() {
|
93 |
if ( $this->admin_screen_hook === $hook ) {
|
94 |
$this->add_settings_scripts();
|
95 |
}
|
|
|
|
|
|
|
|
|
96 |
}
|
97 |
|
98 |
private function add_settings_scripts() {
|
99 |
$plugin_dir_url = plugin_dir_url( $this->file );
|
100 |
|
101 |
wp_enqueue_style( 'jquery-pin-it-button-admin-style', $plugin_dir_url . 'css/admin.css', array(), $this->version, 'all' );
|
|
|
102 |
|
103 |
$slug = isset( $_GET['tab'] ) ? $_GET['tab'] : 'select';
|
104 |
$tab_mod = $this->get_tab( $slug );
|
105 |
$settings = array(
|
|
|
106 |
'tabs' => $this->get_tabs(),
|
107 |
'currentTab' => $slug,
|
108 |
'page' => 'jpibfi_settings',
|
109 |
+
'save' => array(
|
110 |
+
'post_url' => add_query_arg( array( 'tab' => $slug ) ),
|
111 |
+
'action' => $this->save_settings_action,
|
112 |
+
'nonce' => wp_create_nonce( $this->save_settings_action ),
|
113 |
+
'tab' => $this->save_settings_tab,
|
114 |
+
'submit' => __( 'Save Changes', 'jquery-pin-it-button-for-images' )
|
115 |
+
),
|
116 |
'links' => array(
|
117 |
array(
|
118 |
'url' => 'https://highfiveplugins.com/jpibfi/jquery-pin-it-button-for-images-documentation/',
|
121 |
array(
|
122 |
'url' => 'https://wordpress.org/support/plugin/jquery-pin-it-button-for-images',
|
123 |
'label' => __( 'Support', 'jquery-pin-it-button-for-images' )
|
124 |
+
),
|
125 |
),
|
126 |
'settings' => $tab_mod->get_settings_configuration(),
|
127 |
'i18n' => array(
|
128 |
+
'editor' => $tab_mod->get_settings_i18n(),
|
129 |
+
'status' => array( 'pending' => __( 'Saving changes ...', 'jquery-pin-it-button-for-images' ) ),
|
130 |
),
|
131 |
);
|
132 |
$settings['version'] = 'lite';
|
161 |
<?php
|
162 |
}
|
163 |
|
164 |
+
function save_settings() {
|
165 |
+
$return_condition = ! isset( $_POST[ $this->save_settings_action ] ) ||
|
166 |
+
! wp_verify_nonce( $_POST[ $this->save_settings_action ], $this->save_settings_action );
|
167 |
+
if ( $return_condition ) {
|
168 |
+
return;
|
169 |
+
}
|
170 |
+
$tab = $_POST[ $this->save_settings_tab ];
|
171 |
+
$module = $this->get_tab( $tab );
|
172 |
+
$module->save_settings( $_POST );
|
173 |
+
}
|
174 |
+
|
175 |
public function show_ad() {
|
176 |
global $hook_suffix;
|
177 |
if ( $hook_suffix === $this->admin_screen_hook ) {
|
178 |
?>
|
179 |
+
<div class="notice notice-success">
|
180 |
<p>
|
181 |
+
<?php printf(
|
182 |
+
__( 'jQuery Pin It Button for Images Pro is available. <a class="button button-primary" href="%1$s" target="_blank">Check it out →</a>', 'jquery-pin-it-button-for-images' ),
|
183 |
+
'https://highfiveplugins.com/downloads/jquery-pin-it-button-for-images-pro/'
|
184 |
+
);
|
185 |
+
?>
|
|
|
|
|
|
|
186 |
</p>
|
187 |
</div>
|
188 |
<?php
|
189 |
}
|
190 |
}
|
191 |
|
192 |
+
function show_nags() {
|
193 |
+
require_once 'includes/jpibfi_review_nag.php';
|
194 |
+
new JPIBFI_Review_Nag( 'jpibfi', 'jQuery Pin It Button For Images', 'http://wordpress.org/support/view/plugin-reviews/jquery-pin-it-button-for-images', '-10 days' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
195 |
|
196 |
+
require_once 'includes/JPIBFI_Pro_Nag.php';
|
197 |
+
new JPIBFI_Pro_Nag( 'jpibfi', 'jQuery Pin It Button For Images', 'https://highfiveplugins.com/downloads/jquery-pin-it-button-for-images-pro/' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
198 |
}
|
199 |
|
200 |
function plugin_meta_links( $links, $file ) {
|
205 |
|
206 |
return $links;
|
207 |
}
|
|
|
|
|
|
|
|
|
|
|
208 |
}
|
includes/admin/settings/jpibfi-import-export-settings.php
CHANGED
@@ -12,35 +12,30 @@ class JPIBFI_Import_Export_Settings extends JPIBFI_Settings_Tab {
|
|
12 |
}
|
13 |
|
14 |
function import() {
|
15 |
-
$result = new JPIBFI_Ajax_Result_Builder();
|
16 |
$file = wp_import_handle_upload();
|
17 |
|
18 |
if ( isset( $file['error'] ) ) {
|
19 |
-
|
20 |
-
|
21 |
-
->build();
|
22 |
}
|
23 |
|
24 |
if ( ! isset( $file['file'], $file['id'] ) ) {
|
25 |
-
|
26 |
-
|
27 |
-
->build();
|
28 |
}
|
29 |
|
30 |
if ( ! file_exists( $file['file'] ) ) {
|
31 |
wp_import_cleanup( $file['id'] );
|
32 |
|
33 |
-
|
34 |
-
|
35 |
-
->build();
|
36 |
}
|
37 |
|
38 |
if ( ! is_file( $file['file'] ) ) {
|
39 |
wp_import_cleanup( $file['id'] );
|
40 |
|
41 |
-
|
42 |
-
|
43 |
-
->build();
|
44 |
}
|
45 |
|
46 |
$file_contents = file_get_contents( $file['file'] );
|
@@ -55,9 +50,7 @@ class JPIBFI_Import_Export_Settings extends JPIBFI_Settings_Tab {
|
|
55 |
$converter = new JPIBFI_Option_Converter();
|
56 |
$converter->save_and_convert_if_needed( $options_to_import );
|
57 |
|
58 |
-
|
59 |
-
->set_message( __( 'Import Successful', 'jquery_pin_it_button_for_images' ) )
|
60 |
-
->build();
|
61 |
}
|
62 |
|
63 |
function get_settings_i18n() {
|
@@ -77,7 +70,7 @@ class JPIBFI_Import_Export_Settings extends JPIBFI_Settings_Tab {
|
|
77 |
function get_module_settings() {
|
78 |
return array(
|
79 |
'slug' => 'import',
|
80 |
-
'name' => __( 'Import/Export
|
81 |
);
|
82 |
}
|
83 |
|
@@ -116,7 +109,8 @@ class JPIBFI_Import_Export_Settings extends JPIBFI_Settings_Tab {
|
|
116 |
$option_names = array(
|
117 |
'jpibfi_selection_options',
|
118 |
'jpibfi_visual_options',
|
119 |
-
'
|
|
|
120 |
);
|
121 |
|
122 |
$export_options = array();
|
@@ -132,4 +126,9 @@ class JPIBFI_Import_Export_Settings extends JPIBFI_Settings_Tab {
|
|
132 |
echo json_encode( array( 'options' => $export_options ), $JSON_PRETTY_PRINT );
|
133 |
exit;
|
134 |
}
|
|
|
|
|
|
|
|
|
|
|
135 |
}
|
12 |
}
|
13 |
|
14 |
function import() {
|
|
|
15 |
$file = wp_import_handle_upload();
|
16 |
|
17 |
if ( isset( $file['error'] ) ) {
|
18 |
+
$this->notices[] = new JPIBFI_Admin_Notice( 'error', true, esc_html( $file['error'] ) );
|
19 |
+
return;
|
|
|
20 |
}
|
21 |
|
22 |
if ( ! isset( $file['file'], $file['id'] ) ) {
|
23 |
+
$this->notices[] = new JPIBFI_Admin_Notice( 'error', true, __( 'The file did not upload properly. Please try again.', 'jquery-pin-it-button-for-images' ) );
|
24 |
+
return;
|
|
|
25 |
}
|
26 |
|
27 |
if ( ! file_exists( $file['file'] ) ) {
|
28 |
wp_import_cleanup( $file['id'] );
|
29 |
|
30 |
+
$this->notices[] = new JPIBFI_Admin_Notice( 'error', true, sprintf( __( 'The export file could not be found at <code>%s</code>. It is likely that this was caused by a permissions problem.', 'jquery-pin-it-button-for-images' ), esc_html( $file['file'] ) ) );
|
31 |
+
return;
|
|
|
32 |
}
|
33 |
|
34 |
if ( ! is_file( $file['file'] ) ) {
|
35 |
wp_import_cleanup( $file['id'] );
|
36 |
|
37 |
+
$this->notices[] = new JPIBFI_Admin_Notice( 'error', true, __( 'The path is not a file, please try again.', 'jquery-pin-it-button-for-images' ) );
|
38 |
+
return;
|
|
|
39 |
}
|
40 |
|
41 |
$file_contents = file_get_contents( $file['file'] );
|
50 |
$converter = new JPIBFI_Option_Converter();
|
51 |
$converter->save_and_convert_if_needed( $options_to_import );
|
52 |
|
53 |
+
$this->notices[] = new JPIBFI_Admin_Notice( 'success', true, __( 'Import Successful', 'jquery_pin_it_button_for_images' ) );
|
|
|
|
|
54 |
}
|
55 |
|
56 |
function get_settings_i18n() {
|
70 |
function get_module_settings() {
|
71 |
return array(
|
72 |
'slug' => 'import',
|
73 |
+
'name' => __( 'Import/Export', 'jquery-pin-it-button-for-images' ),
|
74 |
);
|
75 |
}
|
76 |
|
109 |
$option_names = array(
|
110 |
'jpibfi_selection_options',
|
111 |
'jpibfi_visual_options',
|
112 |
+
'jpibfi_advanced_options',
|
113 |
+
'jpibfi_options_version',
|
114 |
);
|
115 |
|
116 |
$export_options = array();
|
126 |
echo json_encode( array( 'options' => $export_options ), $JSON_PRETTY_PRINT );
|
127 |
exit;
|
128 |
}
|
129 |
+
|
130 |
+
public function save_settings( $settings ) {
|
131 |
+
print_r( $settings, true);
|
132 |
+
$this->import();
|
133 |
+
}
|
134 |
}
|
includes/admin/settings/jpibfi-selection-settings.php
CHANGED
@@ -65,7 +65,8 @@ class JPIBFI_Selection_Settings extends JPIBFI_Settings_Base {
|
|
65 |
'<a href="http://api.jquery.com/category/selectors/" target="_blank">',
|
66 |
'</a>'
|
67 |
),
|
68 |
-
'type' => 'string'
|
|
|
69 |
);
|
70 |
|
71 |
$res['disabled_classes'] = array(
|
65 |
'<a href="http://api.jquery.com/category/selectors/" target="_blank">',
|
66 |
'</a>'
|
67 |
),
|
68 |
+
'type' => 'string',
|
69 |
+
'required' => true
|
70 |
);
|
71 |
|
72 |
$res['disabled_classes'] = array(
|
includes/admin/settings/jpibfi-settings-base.php
CHANGED
@@ -9,41 +9,16 @@ abstract class JPIBFI_Settings_Tab {
|
|
9 |
*/
|
10 |
private $slug;
|
11 |
|
|
|
|
|
|
|
|
|
|
|
12 |
function __construct( $slug ) {
|
13 |
$this->slug = $slug;
|
14 |
-
|
15 |
-
}
|
16 |
-
|
17 |
-
function ajax_custom() {
|
18 |
-
check_ajax_referer( $this->get_ajax_custom_action_name(), 'nonce' );
|
19 |
-
if ( ! current_user_can( 'manage_options' ) ) {
|
20 |
-
wp_die();
|
21 |
-
}
|
22 |
-
|
23 |
-
$action = $_REQUEST['name'];
|
24 |
-
if ( ! is_callable( array( $this, $action ) ) ) {
|
25 |
-
$builder = new JPIBFI_Ajax_Result_Builder();
|
26 |
-
wp_send_json(
|
27 |
-
$builder
|
28 |
-
->set_error( __( 'Error', 'jquery-pin-it-button-for-images' ) )
|
29 |
-
->build()
|
30 |
-
);
|
31 |
-
} else {
|
32 |
-
$result = call_user_func( array( $this, $action ) );
|
33 |
-
wp_send_json( $result );
|
34 |
-
}
|
35 |
-
}
|
36 |
-
|
37 |
-
private function get_ajax_custom_action_name() {
|
38 |
-
return 'jpibfi_settings_custom_' . $this->get_slug();
|
39 |
-
}
|
40 |
|
41 |
-
|
42 |
-
return array(
|
43 |
-
'url' => admin_url( 'admin-ajax.php' ),
|
44 |
-
'customAction' => $this->get_ajax_custom_action_name(),
|
45 |
-
'customActionNonce' => wp_create_nonce( $this->get_ajax_custom_action_name() )
|
46 |
-
);
|
47 |
}
|
48 |
|
49 |
function get_settings_configuration() {
|
@@ -63,6 +38,17 @@ abstract class JPIBFI_Settings_Tab {
|
|
63 |
function get_slug() {
|
64 |
return $this->slug;
|
65 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
66 |
}
|
67 |
|
68 |
abstract class JPIBFI_Settings_Base extends JPIBFI_Settings_Tab {
|
@@ -75,56 +61,22 @@ abstract class JPIBFI_Settings_Base extends JPIBFI_Settings_Tab {
|
|
75 |
function __construct( $slug, $options ) {
|
76 |
parent::__construct( $slug );
|
77 |
$this->options = $options;
|
78 |
-
|
79 |
-
add_action( 'wp_ajax_' . $this->get_ajax_save_action_name(), array( $this, 'ajax_save_settings' ) );
|
80 |
-
}
|
81 |
-
|
82 |
-
function ajax_save_settings() {
|
83 |
-
check_ajax_referer( $this->get_ajax_save_action_name(), 'nonce' );
|
84 |
-
if ( ! current_user_can( 'manage_options' ) ) {
|
85 |
-
wp_die();
|
86 |
-
}
|
87 |
-
|
88 |
-
$settings = json_decode( stripslashes( $_REQUEST['settings'] ), true );
|
89 |
-
$update_result = $this->save_settings( $settings );
|
90 |
-
wp_send_json( $update_result );
|
91 |
-
}
|
92 |
-
|
93 |
-
private function get_ajax_save_action_name() {
|
94 |
-
return 'jpibfi_settings_save_' . $this->get_slug();
|
95 |
-
}
|
96 |
-
|
97 |
-
function get_settings_ajax() {
|
98 |
-
$result = parent::get_settings_ajax();
|
99 |
-
$result['saveSettingsAction'] = $this->get_ajax_save_action_name();
|
100 |
-
$result['saveSettingsNonce'] = wp_create_nonce( $this->get_ajax_save_action_name() );
|
101 |
-
|
102 |
-
return $result;
|
103 |
}
|
104 |
|
105 |
function save_settings( $settings ) {
|
106 |
-
$settings = $this->options->sanitize( $settings );
|
107 |
-
|
108 |
$validator = new JPIBFI_Validator( $settings, $this->options->get_default_options(), $this->get_settings_configuration() );
|
109 |
$errors = $validator->get_errors();
|
110 |
-
|
111 |
-
$result = new JPIBFI_Ajax_Result_Builder();
|
112 |
-
|
113 |
if ( count( $errors ) > 0 ) {
|
114 |
-
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
|
|
|
|
|
|
|
|
120 |
}
|
121 |
-
|
122 |
-
$sanitized = $validator->get_result();
|
123 |
-
$this->options->update( $sanitized );
|
124 |
-
|
125 |
-
return $result
|
126 |
-
->set_model( $sanitized )
|
127 |
-
->set_message( __( 'Settings saved.', 'jquery-pin-it-button-for-images' ) )
|
128 |
-
->build();
|
129 |
}
|
130 |
}
|
9 |
*/
|
10 |
private $slug;
|
11 |
|
12 |
+
/**
|
13 |
+
* @var JPIBFI_Admin_Notice[]
|
14 |
+
*/
|
15 |
+
protected $notices;
|
16 |
+
|
17 |
function __construct( $slug ) {
|
18 |
$this->slug = $slug;
|
19 |
+
$this->notices = array();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
20 |
|
21 |
+
add_action( 'admin_notices', array( $this, 'show_notices' ) );
|
|
|
|
|
|
|
|
|
|
|
22 |
}
|
23 |
|
24 |
function get_settings_configuration() {
|
38 |
function get_slug() {
|
39 |
return $this->slug;
|
40 |
}
|
41 |
+
|
42 |
+
function save_settings( $settings ) {
|
43 |
+
|
44 |
+
}
|
45 |
+
|
46 |
+
function show_notices( ) {
|
47 |
+
foreach ( $this->notices as $notice ) {
|
48 |
+
echo $notice->get_html();
|
49 |
+
}
|
50 |
+
}
|
51 |
+
|
52 |
}
|
53 |
|
54 |
abstract class JPIBFI_Settings_Base extends JPIBFI_Settings_Tab {
|
61 |
function __construct( $slug, $options ) {
|
62 |
parent::__construct( $slug );
|
63 |
$this->options = $options;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
64 |
}
|
65 |
|
66 |
function save_settings( $settings ) {
|
|
|
|
|
67 |
$validator = new JPIBFI_Validator( $settings, $this->options->get_default_options(), $this->get_settings_configuration() );
|
68 |
$errors = $validator->get_errors();
|
|
|
|
|
|
|
69 |
if ( count( $errors ) > 0 ) {
|
70 |
+
$error_messages = array_merge(
|
71 |
+
array( '<strong>' .__( 'Settings not saved.', 'frizzly' ) . '</strong>' ),
|
72 |
+
$errors
|
73 |
+
);
|
74 |
+
$this->notices[] = new JPIBFI_Admin_Notice( 'error', true, join( '<br/>', $error_messages ) );
|
75 |
+
} else {
|
76 |
+
$sanitized = $validator->get_result();
|
77 |
+
$sanitized = $this->options->sanitize( $sanitized );
|
78 |
+
$this->options->update( $sanitized );
|
79 |
+
$this->notices[] = new JPIBFI_Admin_Notice( 'success', true, '<strong>' . __( 'Settings saved.', 'jquery-pin-in-button-for-images' ) . '</strong>' );
|
80 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
81 |
}
|
82 |
}
|
includes/admin/settings/{jpibfi-validator.php → jpibfi_validator.php}
RENAMED
@@ -7,6 +7,9 @@ class JPIBFI_Validator {
|
|
7 |
private $settings;
|
8 |
|
9 |
private $result;
|
|
|
|
|
|
|
10 |
private $errors;
|
11 |
|
12 |
function __construct( $current, $default, $settings ) {
|
@@ -22,15 +25,15 @@ class JPIBFI_Validator {
|
|
22 |
$this->result = array();
|
23 |
|
24 |
foreach ( $this->default as $key => $def_value ) {
|
25 |
-
if ( ! isset( $this->current[ $key ] ) ) {
|
26 |
-
$this->result[ $key ] = $def_value;
|
27 |
-
continue;
|
28 |
-
}
|
29 |
if ( ! isset( $this->settings[ $key ] ) ) {
|
30 |
continue;
|
31 |
}
|
32 |
-
$
|
33 |
-
|
|
|
|
|
|
|
|
|
34 |
$validation_result = $this->validate_field( $value, $this->settings[ $key ] );
|
35 |
if ( true !== $validation_result ) {
|
36 |
$this->errors[ $key ] = $validation_result;
|
@@ -47,8 +50,22 @@ class JPIBFI_Validator {
|
|
47 |
return $this->result;
|
48 |
}
|
49 |
|
50 |
-
|
51 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
52 |
}
|
53 |
|
54 |
private function validate_field( $value, $setting ) {
|
@@ -60,15 +77,13 @@ class JPIBFI_Validator {
|
|
60 |
if ( is_callable( array( $this, $func_name ) ) ) {
|
61 |
return call_user_func( array( $this, $func_name ), $value, $setting );
|
62 |
}
|
|
|
63 |
return true;
|
64 |
}
|
65 |
|
66 |
private function validate_float( $value, $setting ) {
|
67 |
if ( ! is_float( $value ) ) {
|
68 |
-
return
|
69 |
-
__( '%1$s value is not a number.', 'jquery-pin-it-button-for-images' ),
|
70 |
-
$this->get_error_label( $setting )
|
71 |
-
);
|
72 |
}
|
73 |
|
74 |
return $this->validate_mix_max( $value, $setting );
|
@@ -76,10 +91,7 @@ class JPIBFI_Validator {
|
|
76 |
|
77 |
private function validate_int( $value, $setting ) {
|
78 |
if ( ! is_int( $value ) ) {
|
79 |
-
return
|
80 |
-
__( '%1$s value is not a number.', 'jquery-pin-it-button-for-images' ),
|
81 |
-
$this->get_error_label( $setting )
|
82 |
-
);
|
83 |
}
|
84 |
|
85 |
return $this->validate_mix_max( $value, $setting );
|
@@ -87,32 +99,27 @@ class JPIBFI_Validator {
|
|
87 |
|
88 |
private function validate_mix_max( $value, $setting ) {
|
89 |
if ( isset( $setting['min'] ) && $value < $setting['min'] ) {
|
90 |
-
return
|
91 |
-
__( '%1$s value is less than the minimum value of %2$s.', 'jquery-pin-it-button-for-images' ),
|
92 |
-
$this->get_error_label( $setting ),
|
93 |
-
$setting['min']
|
94 |
-
);
|
95 |
}
|
96 |
if ( isset( $setting['max'] ) && $value > $setting['max'] ) {
|
97 |
-
return
|
98 |
-
__( '%1$s value is greater than the minimum value of %2$s.', 'jquery-pin-it-button-for-images' ),
|
99 |
-
$this->get_error_label( $setting ),
|
100 |
-
$setting['max']
|
101 |
-
);
|
102 |
}
|
103 |
|
104 |
return true;
|
105 |
}
|
106 |
|
107 |
private function validate_multiselect( $value, $setting ) {
|
108 |
-
$err = __( '%1$s value is invalid.', 'jquery-pin-
|
109 |
if ( ! is_array( $value ) ) {
|
110 |
-
return
|
|
|
|
|
|
|
111 |
}
|
112 |
$options_keys = array_keys( $setting['options'] );
|
113 |
foreach ( $value as $name ) {
|
114 |
if ( ! in_array( $name, $options_keys ) ) {
|
115 |
-
return
|
116 |
}
|
117 |
}
|
118 |
|
@@ -122,15 +129,19 @@ class JPIBFI_Validator {
|
|
122 |
private function validate_select( $value, $setting ) {
|
123 |
$options_keys = array_keys( $setting['options'] );
|
124 |
if ( ! in_array( $value, $options_keys ) ) {
|
125 |
-
|
126 |
-
__( '%1$s value is invalid.', 'jquery-pin-it-button-for-images' ),
|
127 |
-
$this->get_error_label( $setting )
|
128 |
-
);
|
129 |
}
|
130 |
|
131 |
return true;
|
132 |
}
|
133 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
134 |
private function try_sanitize_field( $value, $setting ) {
|
135 |
if ( ! isset( $setting['type'] ) ) {
|
136 |
return $value;
|
@@ -141,7 +152,9 @@ class JPIBFI_Validator {
|
|
141 |
case 'float':
|
142 |
return is_numeric( $value ) ? floatval( $value ) : $value;
|
143 |
case 'boolean':
|
144 |
-
return
|
|
|
|
|
145 |
default:
|
146 |
return $value;
|
147 |
}
|
7 |
private $settings;
|
8 |
|
9 |
private $result;
|
10 |
+
/**
|
11 |
+
* @var string[]
|
12 |
+
*/
|
13 |
private $errors;
|
14 |
|
15 |
function __construct( $current, $default, $settings ) {
|
25 |
$this->result = array();
|
26 |
|
27 |
foreach ( $this->default as $key => $def_value ) {
|
|
|
|
|
|
|
|
|
28 |
if ( ! isset( $this->settings[ $key ] ) ) {
|
29 |
continue;
|
30 |
}
|
31 |
+
$setting = $this->settings[ $key ];
|
32 |
+
|
33 |
+
$value = ! isset( $this->current[ $key ] )
|
34 |
+
? ( 'boolean' === $setting['type'] ? '' : $def_value )
|
35 |
+
: $this->current[ $key ];
|
36 |
+
$value = $this->try_sanitize_field( $value, $setting );
|
37 |
$validation_result = $this->validate_field( $value, $this->settings[ $key ] );
|
38 |
if ( true !== $validation_result ) {
|
39 |
$this->errors[ $key ] = $validation_result;
|
50 |
return $this->result;
|
51 |
}
|
52 |
|
53 |
+
/**
|
54 |
+
* @param $error_type string
|
55 |
+
* @param $error_default_format string
|
56 |
+
* @param $setting array
|
57 |
+
*
|
58 |
+
* @return string
|
59 |
+
*/
|
60 |
+
private function get_error_text( $error_type, $error_default_format, $setting ) {
|
61 |
+
if ( isset( $setting['error_messages'] ) && isset( $setting['error_messages'][ $error_type ] ) ) {
|
62 |
+
return $setting['error_messages'][ $error_type ];
|
63 |
+
}
|
64 |
+
$error_label = isset( $setting['error_label'] )
|
65 |
+
? $setting['error_label']
|
66 |
+
: ( isset( $setting['label'] ) ? $setting['label'] : '' );
|
67 |
+
|
68 |
+
return sprintf( $error_default_format, $error_label );
|
69 |
}
|
70 |
|
71 |
private function validate_field( $value, $setting ) {
|
77 |
if ( is_callable( array( $this, $func_name ) ) ) {
|
78 |
return call_user_func( array( $this, $func_name ), $value, $setting );
|
79 |
}
|
80 |
+
|
81 |
return true;
|
82 |
}
|
83 |
|
84 |
private function validate_float( $value, $setting ) {
|
85 |
if ( ! is_float( $value ) ) {
|
86 |
+
return $this->get_error_text( 'type', __( '%1$s value is not a number.', 'jquery-pin-in-button-for-images' ), $setting );
|
|
|
|
|
|
|
87 |
}
|
88 |
|
89 |
return $this->validate_mix_max( $value, $setting );
|
91 |
|
92 |
private function validate_int( $value, $setting ) {
|
93 |
if ( ! is_int( $value ) ) {
|
94 |
+
return $this->get_error_text( 'type', __( '%1$s value is not a number.', 'jquery-pin-in-button-for-images' ), $setting );
|
|
|
|
|
|
|
95 |
}
|
96 |
|
97 |
return $this->validate_mix_max( $value, $setting );
|
99 |
|
100 |
private function validate_mix_max( $value, $setting ) {
|
101 |
if ( isset( $setting['min'] ) && $value < $setting['min'] ) {
|
102 |
+
return $this->get_error_text( 'min', __( '%1$s value is less than the minimum value of %2$s.', 'jquery-pin-in-button-for-images' ), $setting );
|
|
|
|
|
|
|
|
|
103 |
}
|
104 |
if ( isset( $setting['max'] ) && $value > $setting['max'] ) {
|
105 |
+
return $this->get_error_text( 'max', __( '%1$s value is greater than the minimum value of %2$s.', 'jquery-pin-in-button-for-images' ), $setting );
|
|
|
|
|
|
|
|
|
106 |
}
|
107 |
|
108 |
return true;
|
109 |
}
|
110 |
|
111 |
private function validate_multiselect( $value, $setting ) {
|
112 |
+
$err = __( '%1$s value is invalid.', 'jquery-pin-in-button-for-images' );
|
113 |
if ( ! is_array( $value ) ) {
|
114 |
+
return $this->get_error_text( 'type', $err, $setting );
|
115 |
+
}
|
116 |
+
if ( isset( $setting['min'] ) && count( $value ) < $setting['min'] ) {
|
117 |
+
return $this->get_error_text( 'min', __('%1$s does not have enough selected records.', 'jquery-pin-in-button-for-images'), $setting);
|
118 |
}
|
119 |
$options_keys = array_keys( $setting['options'] );
|
120 |
foreach ( $value as $name ) {
|
121 |
if ( ! in_array( $name, $options_keys ) ) {
|
122 |
+
return $this->get_error_text( 'type', $err, $setting );
|
123 |
}
|
124 |
}
|
125 |
|
129 |
private function validate_select( $value, $setting ) {
|
130 |
$options_keys = array_keys( $setting['options'] );
|
131 |
if ( ! in_array( $value, $options_keys ) ) {
|
132 |
+
$this->get_error_text( 'type', __( '%1$s value is invalid.', 'jquery-pin-in-button-for-images' ), $setting );
|
|
|
|
|
|
|
133 |
}
|
134 |
|
135 |
return true;
|
136 |
}
|
137 |
|
138 |
+
private function validate_string( $value, $setting ) {
|
139 |
+
if ( isset( $setting['required' ] ) && '' == $value ) {
|
140 |
+
return $this->get_error_text( 'required', __( '%1$s cannot be empty.', 'jquery-pin-in-button-for-images' ) , $setting );
|
141 |
+
}
|
142 |
+
return true;
|
143 |
+
}
|
144 |
+
|
145 |
private function try_sanitize_field( $value, $setting ) {
|
146 |
if ( ! isset( $setting['type'] ) ) {
|
147 |
return $value;
|
152 |
case 'float':
|
153 |
return is_numeric( $value ) ? floatval( $value ) : $value;
|
154 |
case 'boolean':
|
155 |
+
return 'on' === $value;
|
156 |
+
case 'multiselect':
|
157 |
+
return '' === $value ? array() : explode( ',', $value );
|
158 |
default:
|
159 |
return $value;
|
160 |
}
|
includes/includes/jpibfi-option-converter.php
CHANGED
@@ -4,11 +4,13 @@ class JPIBFI_Option_Converter {
|
|
4 |
|
5 |
private $selection_options;
|
6 |
private $visual_options;
|
|
|
7 |
|
8 |
private $converted_option_name;
|
9 |
private $converted_option_value;
|
10 |
|
11 |
public function __construct() {
|
|
|
12 |
$this->selection_options = new JPIBFI_Selection_Options();
|
13 |
$this->visual_options = new JPIBFI_Visual_Options();
|
14 |
|
@@ -52,6 +54,11 @@ class JPIBFI_Option_Converter {
|
|
52 |
$this->visual_options->update( $visual_options );
|
53 |
}
|
54 |
|
|
|
|
|
|
|
|
|
|
|
55 |
$this->finish();
|
56 |
}
|
57 |
|
4 |
|
5 |
private $selection_options;
|
6 |
private $visual_options;
|
7 |
+
private $advanced_options;
|
8 |
|
9 |
private $converted_option_name;
|
10 |
private $converted_option_value;
|
11 |
|
12 |
public function __construct() {
|
13 |
+
$this->advanced_options = new JPIBFI_Advanced_Options();
|
14 |
$this->selection_options = new JPIBFI_Selection_Options();
|
15 |
$this->visual_options = new JPIBFI_Visual_Options();
|
16 |
|
54 |
$this->visual_options->update( $visual_options );
|
55 |
}
|
56 |
|
57 |
+
$advanced_options = $imported_options[ 'jpibfi_advanced_options' ];
|
58 |
+
if ( $advanced_options ) {
|
59 |
+
$this->advanced_options->update( $advanced_options );
|
60 |
+
}
|
61 |
+
|
62 |
$this->finish();
|
63 |
}
|
64 |
|
includes/jpibfi.php
CHANGED
@@ -14,7 +14,6 @@ class JPIBFI {
|
|
14 |
$this->load_textdomain();
|
15 |
|
16 |
register_activation_hook( $file, array( $this, 'update_plugin' ) );
|
17 |
-
register_activation_hook( $file, array( $this, 'setup_nag' ) );
|
18 |
add_action( 'plugins_loaded', array( $this, 'update_plugin' ) );
|
19 |
}
|
20 |
|
@@ -44,13 +43,8 @@ class JPIBFI {
|
|
44 |
return;
|
45 |
|
46 |
update_option( $version_option, $this->version );
|
47 |
-
update_option( 'jpibfi_pro_ad', 1 );
|
48 |
|
49 |
$converter = new JPIBFI_Option_Converter();
|
50 |
$converter->convert_if_needed();
|
51 |
}
|
52 |
-
|
53 |
-
public function setup_nag(){
|
54 |
-
|
55 |
-
}
|
56 |
}
|
14 |
$this->load_textdomain();
|
15 |
|
16 |
register_activation_hook( $file, array( $this, 'update_plugin' ) );
|
|
|
17 |
add_action( 'plugins_loaded', array( $this, 'update_plugin' ) );
|
18 |
}
|
19 |
|
43 |
return;
|
44 |
|
45 |
update_option( $version_option, $this->version );
|
|
|
46 |
|
47 |
$converter = new JPIBFI_Option_Converter();
|
48 |
$converter->convert_if_needed();
|
49 |
}
|
|
|
|
|
|
|
|
|
50 |
}
|
includes/public/class-jpibfi-client.php
CHANGED
@@ -11,12 +11,12 @@ class JPIBFI_Client {
|
|
11 |
private $version;
|
12 |
private $plugin_dir_url;
|
13 |
|
14 |
-
public function __construct($file, $version) {
|
15 |
-
$this->version
|
16 |
-
$this->plugin_dir_url
|
17 |
$this->selection_options = new JPIBFI_Selection_Options();
|
18 |
-
$this->visual_options
|
19 |
-
$this->advanced_options
|
20 |
|
21 |
add_action( 'wp_enqueue_scripts', array( $this, 'add_plugin_scripts' ) );
|
22 |
add_action( 'wp_head', array( $this, 'print_header_style' ) );
|
@@ -24,78 +24,84 @@ class JPIBFI_Client {
|
|
24 |
}
|
25 |
|
26 |
private function add_conditional_filters() {
|
27 |
-
|
28 |
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
|
35 |
foreach ( $filters as $filter ) {
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
|
|
|
|
|
|
41 |
|
42 |
public function add_plugin_scripts() {
|
43 |
-
if (
|
44 |
return;
|
|
|
45 |
|
46 |
-
|
47 |
|
48 |
wp_enqueue_script( 'jpibfi-script', $this->plugin_dir_url . 'js/jpibfi.client.js', $deps, $this->version, false );
|
49 |
|
50 |
-
$selection_options
|
51 |
$selection_options['image_selector'] = apply_filters( 'jpibfi_image_selector', $selection_options['image_selector'] );
|
52 |
|
53 |
-
$parameters_array = array
|
54 |
'hover' => array_merge(
|
55 |
-
array
|
56 |
$selection_options,
|
57 |
$this->visual_options->get_options_for_view()
|
58 |
),
|
59 |
);
|
60 |
wp_localize_script( 'jpibfi-script', 'jpibfi_options', $parameters_array );
|
61 |
|
62 |
-
wp_enqueue_style( 'jpibfi-style', $this->plugin_dir_url . 'css/client.css', array
|
63 |
}
|
64 |
|
65 |
public function print_header_style() {
|
66 |
-
if (
|
67 |
return;
|
|
|
68 |
|
69 |
$visual_options_js = $this->visual_options->get_options_for_view();
|
70 |
|
71 |
$custom_button_span_css = '';
|
72 |
-
$custom_button_css
|
73 |
if ( $visual_options_js['pin_image'] === 'custom' ) {
|
74 |
-
$custom_button_css .=
|
75 |
-
$custom_button_css .=
|
76 |
-
|
77 |
-
$custom_button_span_css .=
|
78 |
-
$custom_button_span_css .=
|
79 |
-
$custom_button_span_css .=
|
80 |
}
|
81 |
-
|
82 |
?>
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
a.pinit-button.custom span {
|
88 |
-
<?php echo $custom_button_span_css; ?>
|
89 |
-
}
|
90 |
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
|
|
|
|
|
|
|
|
99 |
}
|
100 |
|
101 |
/*
|
@@ -103,98 +109,107 @@ class JPIBFI_Client {
|
|
103 |
* This piece of code uses a lot of code from the Photo Protect http://wordpress.org/plugins/photo-protect/ plugin
|
104 |
*/
|
105 |
function the_content( $content ) {
|
106 |
-
if (
|
107 |
return $content;
|
|
|
108 |
global $post;
|
109 |
-
|
110 |
$visual_options = $this->visual_options->get();
|
111 |
|
112 |
-
$get_description = in_array('img_description', $visual_options['description_option']);
|
113 |
-
$get_caption
|
114 |
|
115 |
-
$imgPattern
|
116 |
$attrPattern = '/ ([-\w]+)[ ]*=[ ]*([\"\'])(.*?)\2/i';
|
117 |
|
118 |
-
preg_match_all($imgPattern, $content, $images, PREG_SET_ORDER);
|
119 |
|
120 |
-
foreach ($images as $img) {
|
121 |
|
122 |
-
preg_match_all($attrPattern, $img[0], $attributes, PREG_SET_ORDER);
|
123 |
|
124 |
$new_img = '<img';
|
125 |
-
$src
|
126 |
-
$id
|
127 |
|
128 |
-
foreach ($attributes as $att) {
|
129 |
-
$full
|
130 |
-
$name
|
131 |
$value = $att[3];
|
132 |
|
133 |
$new_img .= $full;
|
134 |
|
135 |
-
if ('class' == $name )
|
136 |
$id = $this->get_post_id_from_image_classes( $value );
|
|
|
137 |
|
138 |
-
if ( 'src' == $name )
|
139 |
$src = $value;
|
|
|
140 |
}
|
141 |
-
|
142 |
-
if ($get_description || $get_caption){
|
143 |
-
$att = $this->get_attachment($id, $src);
|
144 |
-
if ($att != null) {
|
145 |
-
if ($get_description)
|
146 |
-
$new_img .= sprintf(' data-jpibfi-description="%s"', esc_attr( $att->post_content ));
|
147 |
-
|
148 |
-
|
149 |
-
|
|
|
|
|
150 |
}
|
151 |
}
|
152 |
-
|
153 |
-
$new_img .= sprintf(' data-jpibfi-post-excerpt="%s"', esc_attr( wp_kses( $post->post_excerpt, array() ) ));
|
154 |
-
$new_img .= sprintf(' data-jpibfi-post-url="%s"', esc_attr(get_permalink()));
|
155 |
-
$new_img .= sprintf(' data-jpibfi-post-title="%s"', esc_attr(get_the_title()));
|
156 |
$new_img .= ' >';
|
157 |
-
$content = str_replace($img[0], $new_img, $content);
|
158 |
}
|
159 |
$jscript = '';
|
160 |
-
if (defined( 'DOING_AJAX' ) && DOING_AJAX ) {
|
161 |
ob_start();
|
162 |
?>
|
163 |
-
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
<?php
|
172 |
$jscript = ob_get_clean();
|
173 |
}
|
|
|
174 |
return '<input class="jpibfi" type="hidden">' . $content . $jscript;
|
175 |
}
|
176 |
|
177 |
//function gets the id of the image by searching for class with wp-image- prefix, otherwise returns empty string
|
178 |
function get_post_id_from_image_classes( $class_attribute ) {
|
179 |
-
$classes = preg_split( '/\s+/', $class_attribute, -1, PREG_SPLIT_NO_EMPTY );
|
180 |
-
$prefix
|
181 |
|
182 |
-
foreach($classes as $class) {
|
183 |
-
if ( $prefix === substr( $class, 0, strlen( $prefix ) ))
|
184 |
-
return str_replace( $prefix, '',
|
|
|
185 |
}
|
|
|
186 |
return '';
|
187 |
}
|
188 |
|
189 |
-
|
190 |
-
|
191 |
|
192 |
if ( null === $result ) {
|
193 |
-
$id
|
194 |
-
$result = $id !== 0 ? get_post($id) : null;
|
195 |
}
|
|
|
196 |
return $result;
|
197 |
-
|
198 |
|
199 |
/**
|
200 |
* Function copied from https://wpscholar.com/blog/get-attachment-id-from-wp-image-url/
|
@@ -204,9 +219,9 @@ class JPIBFI_Client {
|
|
204 |
*/
|
205 |
function get_attachment_id_by_url( $url ) {
|
206 |
$attachment_id = 0;
|
207 |
-
$dir
|
208 |
if ( false !== strpos( $url, $dir['baseurl'] . '/' ) ) {
|
209 |
-
$file
|
210 |
$query_args = array(
|
211 |
'post_type' => 'attachment',
|
212 |
'post_status' => 'inherit',
|
@@ -219,10 +234,10 @@ class JPIBFI_Client {
|
|
219 |
),
|
220 |
)
|
221 |
);
|
222 |
-
$query
|
223 |
if ( $query->have_posts() ) {
|
224 |
foreach ( $query->posts as $post_id ) {
|
225 |
-
$meta
|
226 |
$original_file = basename( $meta['file'] );
|
227 |
$cropped_image_files = wp_list_pluck( $meta['sizes'], 'file' );
|
228 |
if ( $original_file === $file || in_array( $file, $cropped_image_files ) ) {
|
@@ -232,51 +247,65 @@ class JPIBFI_Client {
|
|
232 |
}
|
233 |
}
|
234 |
}
|
|
|
235 |
return $attachment_id;
|
236 |
}
|
237 |
|
238 |
function add_jpibfi() {
|
239 |
-
if ( is_feed() )
|
240 |
return false;
|
241 |
-
|
|
|
242 |
$jpibfi_selection_options = $this->selection_options->get();
|
243 |
-
$show_on
|
244 |
-
$show_array
|
245 |
|
246 |
foreach ( $show_array as $show_tag ) {
|
247 |
-
if ($this->is_tag( $show_tag )) {
|
248 |
$add_jpibfi = true;
|
249 |
break;
|
250 |
}
|
251 |
}
|
252 |
-
if (
|
253 |
return false;
|
|
|
254 |
|
255 |
-
$disable_on
|
256 |
$disable_array = explode( ',', $disable_on );
|
257 |
|
258 |
foreach ( $disable_array as $disable_tag ) {
|
259 |
-
if ($this->is_tag( $disable_tag ))
|
260 |
return false;
|
|
|
261 |
}
|
|
|
262 |
return true;
|
263 |
}
|
264 |
|
265 |
function is_tag( $tag ) {
|
266 |
$tag = trim( $tag );
|
267 |
-
if ( is_numeric($tag) ) {
|
268 |
$int = intval( $tag );
|
|
|
269 |
return get_the_ID() === $int;
|
270 |
}
|
271 |
-
switch( strtolower( $tag ) ) {
|
272 |
-
case '[front]':
|
273 |
-
|
274 |
-
case '[
|
275 |
-
|
276 |
-
case '[
|
277 |
-
|
278 |
-
|
279 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
280 |
default:
|
281 |
return false;
|
282 |
}
|
11 |
private $version;
|
12 |
private $plugin_dir_url;
|
13 |
|
14 |
+
public function __construct( $file, $version ) {
|
15 |
+
$this->version = $version;
|
16 |
+
$this->plugin_dir_url = plugin_dir_url( $file );
|
17 |
$this->selection_options = new JPIBFI_Selection_Options();
|
18 |
+
$this->visual_options = new JPIBFI_Visual_Options();
|
19 |
+
$this->advanced_options = new JPIBFI_Advanced_Options();
|
20 |
|
21 |
add_action( 'wp_enqueue_scripts', array( $this, 'add_plugin_scripts' ) );
|
22 |
add_action( 'wp_head', array( $this, 'print_header_style' ) );
|
24 |
}
|
25 |
|
26 |
private function add_conditional_filters() {
|
27 |
+
$advanced_value = $this->advanced_options->get();
|
28 |
|
29 |
+
$filters = array(
|
30 |
+
'post_thumbnail_html',
|
31 |
+
'the_excerpt',
|
32 |
+
'the_content'
|
33 |
+
);
|
34 |
|
35 |
foreach ( $filters as $filter ) {
|
36 |
+
if ( $advanced_value[ 'filter_' . $filter . '_on' ] ) {
|
37 |
+
add_filter( $filter, array(
|
38 |
+
$this,
|
39 |
+
'the_content'
|
40 |
+
), $advanced_value[ 'filter_' . $filter . '_priority' ] );
|
41 |
+
}
|
42 |
+
}
|
43 |
+
}
|
44 |
|
45 |
public function add_plugin_scripts() {
|
46 |
+
if ( ! $this->add_jpibfi() ) {
|
47 |
return;
|
48 |
+
}
|
49 |
|
50 |
+
$deps = array( 'jquery' );
|
51 |
|
52 |
wp_enqueue_script( 'jpibfi-script', $this->plugin_dir_url . 'js/jpibfi.client.js', $deps, $this->version, false );
|
53 |
|
54 |
+
$selection_options = $this->selection_options->get();
|
55 |
$selection_options['image_selector'] = apply_filters( 'jpibfi_image_selector', $selection_options['image_selector'] );
|
56 |
|
57 |
+
$parameters_array = array(
|
58 |
'hover' => array_merge(
|
59 |
+
array( 'siteTitle' => esc_attr( get_bloginfo( 'name', 'display' ) ) ),
|
60 |
$selection_options,
|
61 |
$this->visual_options->get_options_for_view()
|
62 |
),
|
63 |
);
|
64 |
wp_localize_script( 'jpibfi-script', 'jpibfi_options', $parameters_array );
|
65 |
|
66 |
+
wp_enqueue_style( 'jpibfi-style', $this->plugin_dir_url . 'css/client.css', array(), $this->version );
|
67 |
}
|
68 |
|
69 |
public function print_header_style() {
|
70 |
+
if ( ! $this->add_jpibfi() ) {
|
71 |
return;
|
72 |
+
}
|
73 |
|
74 |
$visual_options_js = $this->visual_options->get_options_for_view();
|
75 |
|
76 |
$custom_button_span_css = '';
|
77 |
+
$custom_button_css = '';
|
78 |
if ( $visual_options_js['pin_image'] === 'custom' ) {
|
79 |
+
$custom_button_css .= sprintf( 'width: %dpx !important;', $visual_options_js['pinImageWidth'] );
|
80 |
+
$custom_button_css .= sprintf( 'height: %dpx !important;', $visual_options_js['pinImageHeight'] );
|
81 |
+
|
82 |
+
$custom_button_span_css .= $custom_button_css;
|
83 |
+
$custom_button_span_css .= sprintf( 'background-image: url("%s");', $visual_options_js['custom_image_url'] );
|
84 |
+
$custom_button_span_css .= sprintf( 'background-size: %dpx %dpx;', $visual_options_js['pinImageWidth'], $visual_options_js['pinImageHeight'] );
|
85 |
}
|
86 |
+
ob_start();
|
87 |
?>
|
88 |
+
<style type="text/css">
|
89 |
+
a.pinit-button.custom {
|
90 |
+
<?php echo $custom_button_css; ?>
|
91 |
+
}
|
|
|
|
|
|
|
92 |
|
93 |
+
a.pinit-button.custom span {
|
94 |
+
<?php echo $custom_button_span_css; ?>
|
95 |
+
}
|
96 |
+
|
97 |
+
img.pinit-hover {
|
98 |
+
opacity: <?php echo (1 - $visual_options_js['transparency_value']); ?> !important;
|
99 |
+
filter: alpha(opacity=<?php echo (1 - $visual_options_js['transparency_value']) * 100; ?>) !important;
|
100 |
+
}
|
101 |
+
</style>
|
102 |
+
|
103 |
+
<?php
|
104 |
+
echo ob_get_clean();
|
105 |
}
|
106 |
|
107 |
/*
|
109 |
* This piece of code uses a lot of code from the Photo Protect http://wordpress.org/plugins/photo-protect/ plugin
|
110 |
*/
|
111 |
function the_content( $content ) {
|
112 |
+
if ( ! $this->add_jpibfi() ) {
|
113 |
return $content;
|
114 |
+
}
|
115 |
global $post;
|
116 |
+
|
117 |
$visual_options = $this->visual_options->get();
|
118 |
|
119 |
+
$get_description = in_array( 'img_description', $visual_options['description_option'] );
|
120 |
+
$get_caption = in_array( 'img_caption', $visual_options['description_option'] );
|
121 |
|
122 |
+
$imgPattern = '/<img[^>]*>/i';
|
123 |
$attrPattern = '/ ([-\w]+)[ ]*=[ ]*([\"\'])(.*?)\2/i';
|
124 |
|
125 |
+
preg_match_all( $imgPattern, $content, $images, PREG_SET_ORDER );
|
126 |
|
127 |
+
foreach ( $images as $img ) {
|
128 |
|
129 |
+
preg_match_all( $attrPattern, $img[0], $attributes, PREG_SET_ORDER );
|
130 |
|
131 |
$new_img = '<img';
|
132 |
+
$src = '';
|
133 |
+
$id = '';
|
134 |
|
135 |
+
foreach ( $attributes as $att ) {
|
136 |
+
$full = $att[0];
|
137 |
+
$name = $att[1];
|
138 |
$value = $att[3];
|
139 |
|
140 |
$new_img .= $full;
|
141 |
|
142 |
+
if ( 'class' == $name ) {
|
143 |
$id = $this->get_post_id_from_image_classes( $value );
|
144 |
+
}
|
145 |
|
146 |
+
if ( 'src' == $name ) {
|
147 |
$src = $value;
|
148 |
+
}
|
149 |
}
|
150 |
+
|
151 |
+
if ( $get_description || $get_caption ) {
|
152 |
+
$att = $this->get_attachment( $id, $src );
|
153 |
+
if ( $att != null ) {
|
154 |
+
if ( $get_description ) {
|
155 |
+
$new_img .= sprintf( ' data-jpibfi-description="%s"', esc_attr( $att->post_content ) );
|
156 |
+
}
|
157 |
+
|
158 |
+
if ( $get_caption ) {
|
159 |
+
$new_img .= sprintf( ' data-jpibfi-caption="%s"', esc_attr( $att->post_excerpt ) );
|
160 |
+
}
|
161 |
}
|
162 |
}
|
163 |
+
|
164 |
+
$new_img .= sprintf( ' data-jpibfi-post-excerpt="%s"', esc_attr( wp_kses( $post->post_excerpt, array() ) ) );
|
165 |
+
$new_img .= sprintf( ' data-jpibfi-post-url="%s"', esc_attr( get_permalink() ) );
|
166 |
+
$new_img .= sprintf( ' data-jpibfi-post-title="%s"', esc_attr( get_the_title() ) );
|
167 |
$new_img .= ' >';
|
168 |
+
$content = str_replace( $img[0], $new_img, $content );
|
169 |
}
|
170 |
$jscript = '';
|
171 |
+
if ( defined( 'DOING_AJAX' ) && DOING_AJAX ) {
|
172 |
ob_start();
|
173 |
?>
|
174 |
+
<script type="text/javascript">
|
175 |
+
(function () {
|
176 |
+
if (!jQuery) return;
|
177 |
+
jQuery(document).ready(function () {
|
178 |
+
jQuery('.jpibfi').closest('div').addClass('jpibfi_container');
|
179 |
+
});
|
180 |
+
})();
|
181 |
+
</script>
|
182 |
<?php
|
183 |
$jscript = ob_get_clean();
|
184 |
}
|
185 |
+
|
186 |
return '<input class="jpibfi" type="hidden">' . $content . $jscript;
|
187 |
}
|
188 |
|
189 |
//function gets the id of the image by searching for class with wp-image- prefix, otherwise returns empty string
|
190 |
function get_post_id_from_image_classes( $class_attribute ) {
|
191 |
+
$classes = preg_split( '/\s+/', $class_attribute, - 1, PREG_SPLIT_NO_EMPTY );
|
192 |
+
$prefix = 'wp-image-';
|
193 |
|
194 |
+
foreach ( $classes as $class ) {
|
195 |
+
if ( $prefix === substr( $class, 0, strlen( $prefix ) ) ) {
|
196 |
+
return str_replace( $prefix, '', $class );
|
197 |
+
}
|
198 |
}
|
199 |
+
|
200 |
return '';
|
201 |
}
|
202 |
|
203 |
+
function get_attachment( $id, $src ) {
|
204 |
+
$result = is_numeric( $id ) ? get_post( $id ) : null;
|
205 |
|
206 |
if ( null === $result ) {
|
207 |
+
$id = $this->get_attachment_id_by_url( $src );
|
208 |
+
$result = $id !== 0 ? get_post( $id ) : null;
|
209 |
}
|
210 |
+
|
211 |
return $result;
|
212 |
+
}
|
213 |
|
214 |
/**
|
215 |
* Function copied from https://wpscholar.com/blog/get-attachment-id-from-wp-image-url/
|
219 |
*/
|
220 |
function get_attachment_id_by_url( $url ) {
|
221 |
$attachment_id = 0;
|
222 |
+
$dir = wp_upload_dir();
|
223 |
if ( false !== strpos( $url, $dir['baseurl'] . '/' ) ) {
|
224 |
+
$file = basename( $url );
|
225 |
$query_args = array(
|
226 |
'post_type' => 'attachment',
|
227 |
'post_status' => 'inherit',
|
234 |
),
|
235 |
)
|
236 |
);
|
237 |
+
$query = new WP_Query( $query_args );
|
238 |
if ( $query->have_posts() ) {
|
239 |
foreach ( $query->posts as $post_id ) {
|
240 |
+
$meta = wp_get_attachment_metadata( $post_id );
|
241 |
$original_file = basename( $meta['file'] );
|
242 |
$cropped_image_files = wp_list_pluck( $meta['sizes'], 'file' );
|
243 |
if ( $original_file === $file || in_array( $file, $cropped_image_files ) ) {
|
247 |
}
|
248 |
}
|
249 |
}
|
250 |
+
|
251 |
return $attachment_id;
|
252 |
}
|
253 |
|
254 |
function add_jpibfi() {
|
255 |
+
if ( is_feed() ) {
|
256 |
return false;
|
257 |
+
}
|
258 |
+
$add_jpibfi = false;
|
259 |
$jpibfi_selection_options = $this->selection_options->get();
|
260 |
+
$show_on = $jpibfi_selection_options['show_on'];
|
261 |
+
$show_array = explode( ',', $show_on );
|
262 |
|
263 |
foreach ( $show_array as $show_tag ) {
|
264 |
+
if ( $this->is_tag( $show_tag ) ) {
|
265 |
$add_jpibfi = true;
|
266 |
break;
|
267 |
}
|
268 |
}
|
269 |
+
if ( ! $add_jpibfi ) {
|
270 |
return false;
|
271 |
+
}
|
272 |
|
273 |
+
$disable_on = $jpibfi_selection_options['disable_on'];
|
274 |
$disable_array = explode( ',', $disable_on );
|
275 |
|
276 |
foreach ( $disable_array as $disable_tag ) {
|
277 |
+
if ( $this->is_tag( $disable_tag ) ) {
|
278 |
return false;
|
279 |
+
}
|
280 |
}
|
281 |
+
|
282 |
return true;
|
283 |
}
|
284 |
|
285 |
function is_tag( $tag ) {
|
286 |
$tag = trim( $tag );
|
287 |
+
if ( is_numeric( $tag ) ) {
|
288 |
$int = intval( $tag );
|
289 |
+
|
290 |
return get_the_ID() === $int;
|
291 |
}
|
292 |
+
switch ( strtolower( $tag ) ) {
|
293 |
+
case '[front]':
|
294 |
+
return is_front_page();
|
295 |
+
case '[single]':
|
296 |
+
return is_single();
|
297 |
+
case '[page]':
|
298 |
+
return is_page();
|
299 |
+
case '[archive]':
|
300 |
+
return is_archive();
|
301 |
+
case '[search]':
|
302 |
+
return is_search();
|
303 |
+
case '[category]':
|
304 |
+
return is_category();
|
305 |
+
case '[tag]':
|
306 |
+
return is_tag();
|
307 |
+
case '[home]':
|
308 |
+
return is_home();
|
309 |
default:
|
310 |
return false;
|
311 |
}
|
jquery-pin-it-button-for-images.php
CHANGED
@@ -6,7 +6,7 @@ Description: Highlights images on hover and adds a "Pin It" button over them for
|
|
6 |
Text Domain: jquery-pin-it-button-for-images
|
7 |
Domain Path: /languages
|
8 |
Author: Marcin Skrzypiec
|
9 |
-
Version:2.
|
10 |
Author URI: https://highfiveplugins.com/
|
11 |
*/
|
12 |
|
@@ -18,7 +18,7 @@ if ( !class_exists( 'jQuery_Pin_It_Button_For_Images' ) ) {
|
|
18 |
final class jQuery_Pin_It_Button_For_Images {
|
19 |
|
20 |
function __construct() {
|
21 |
-
$version = '2.
|
22 |
require_once plugin_dir_path(__FILE__) . 'includes/jpibfi.php';
|
23 |
new JPIBFI(__FILE__, $version);
|
24 |
}
|
@@ -26,6 +26,17 @@ if ( !class_exists( 'jQuery_Pin_It_Button_For_Images' ) ) {
|
|
26 |
|
27 |
$JPIBFI = new jQuery_Pin_It_Button_For_Images();
|
28 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
29 |
} else {
|
30 |
function jpibfi_duplicate_error() {
|
31 |
?>
|
6 |
Text Domain: jquery-pin-it-button-for-images
|
7 |
Domain Path: /languages
|
8 |
Author: Marcin Skrzypiec
|
9 |
+
Version:2.2.0
|
10 |
Author URI: https://highfiveplugins.com/
|
11 |
*/
|
12 |
|
18 |
final class jQuery_Pin_It_Button_For_Images {
|
19 |
|
20 |
function __construct() {
|
21 |
+
$version = '2.2.0';
|
22 |
require_once plugin_dir_path(__FILE__) . 'includes/jpibfi.php';
|
23 |
new JPIBFI(__FILE__, $version);
|
24 |
}
|
26 |
|
27 |
$JPIBFI = new jQuery_Pin_It_Button_For_Images();
|
28 |
|
29 |
+
function jpibfi_activation_hook() {
|
30 |
+
// Bail if activating from network, or bulk
|
31 |
+
if ( is_network_admin() || isset( $_GET['activate-multi'] ) ) {
|
32 |
+
return;
|
33 |
+
}
|
34 |
+
|
35 |
+
// Add the transient to redirect
|
36 |
+
set_transient( '_jpibfi_activation_redirect', true, 30 );
|
37 |
+
}
|
38 |
+
register_activation_hook( __FILE__, 'jpibfi_activation_hook' );
|
39 |
+
|
40 |
} else {
|
41 |
function jpibfi_duplicate_error() {
|
42 |
?>
|
js/jpibfi-ad.admin.js
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
/* eslint-disable */
|
2 |
-
(function ($) {
|
3 |
-
|
4 |
-
$(document).ready(function ($) {
|
5 |
-
$('#jpibfi_remove_ad').click(function () {
|
6 |
-
$('.jpibfi-pro-notice').remove();
|
7 |
-
jQuery.post(ajaxurl, { 'action': 'jpibfi_remove_pro_ad' }, function (response) {});
|
8 |
-
});
|
9 |
-
});
|
10 |
-
})(jQuery);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
js/jpibfi.admin.js
CHANGED
@@ -1,9 +1,9 @@
|
|
1 |
-
!function e(t,n,r){function i(a,s){if(!n[a]){if(!t[a]){var u="function"==typeof require&&require;if(!s&&u)return u(a,!0);if(o)return o(a,!0);var l=new Error("Cannot find module '"+a+"'");throw l.code="MODULE_NOT_FOUND",l}var c=n[a]={exports:{}};t[a][0].call(c.exports,function(e){var n=t[a][1][e];return i(n?n:e)},c,c.exports,e,t,n,r)}return n[a].exports}for(var o="function"==typeof require&&require,a=0;a<r.length;a++)i(r[a]);return i}({1:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./app.controller"),o=r(i),a={bindings:{settingsName:"@"},controller:o["default"],template:'<navbar id="settings-navbar"\n tabs="$ctrl.config.tabs"\n page="$ctrl.config.page"\n links="$ctrl.config.links"\n current-tab="$ctrl.config.currentTab">\n </navbar>\n <status i18n="$ctrl.config.i18n.status"></status>\n <select-editor\n ng-if="$ctrl.config.currentTab == \'select\'"\n settings="$ctrl.config.settings"\n i18n="$ctrl.config.i18n.editor">\n </select-editor>\n <visual-editor\n ng-if="$ctrl.config.currentTab == \'visual\'"\n settings="$ctrl.config.settings"\n i18n="$ctrl.config.i18n.editor">\n </visual-editor>\n <advanced-editor\n ng-if="$ctrl.config.currentTab == \'advanced\'"\n settings="$ctrl.config.settings"\n i18n="$ctrl.config.i18n.editor">\n </advanced-editor>\n <import-editor\n ng-if="$ctrl.config.currentTab == \'import\'"\n settings="$ctrl.config.settings"\n i18n="$ctrl.config.i18n.editor">\n </import-editor>\n '};n["default"]=a},{"./app.controller":2}],2:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t,n){r(this,e),this.httpService=t,this.linkService=n,this.config={},this.settingsValue={}}return i(e,[{key:"$onInit",value:function(){this.config=window[this.settingsName],this.httpService.init(this.config.ajax),this.linkService.init(this.config.page)}}]),e}();o.$inject=["httpService","linkService"],n["default"]=o},{}],3:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("angular-sanitize"),s=r(a),u=e("ng-file-upload"),l=r(u),c=e("angular-drag-and-drop-lists"),f=(r(c),e("./app.component")),d=r(f),p=e("./components/components"),h=r(p),g=e("./common/components"),v=r(g),m=e("./services"),$=r(m),b=o["default"].module("app",[s["default"],l["default"],h["default"],v["default"],$["default"]]).component("app",d["default"]).name;n["default"]=b},{"./app.component":1,"./common/components":8,"./components/components":18,"./services":39,angular:46,"angular-drag-and-drop-lists":42,"angular-sanitize":44,"ng-file-upload":48}],4:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./../base.controller"),o=r(i),a={bindings:{settings:"<",i18n:"<"},controller:o["default"],template:'\n <h2>{{ $ctrl.i18n.title }}</h2>\n <table class="form-table">\n <tbody>\n <tr>\n <th>{{ ::$ctrl.i18n.filters_label }}</th>\n <td>\n <p>\n <filter name="$ctrl.settings.filter_the_content_on" priority="$ctrl.settings.filter_the_content_priority"\n update="$ctrl.update($event)" template="$ctrl.i18n.filter_template">\n </filter>\n </p>\n <p>\n <filter name="$ctrl.settings.filter_the_excerpt_on" priority="$ctrl.settings.filter_the_excerpt_priority"\n update="$ctrl.update($event)" template="$ctrl.i18n.filter_template">\n </filter>\n </p>\n <p>\n <filter name="$ctrl.settings.filter_post_thumbnail_html_on" priority="$ctrl.settings.filter_post_thumbnail_html_priority"\n update="$ctrl.update($event)" template="$ctrl.i18n.filter_template">\n </filter>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.filters_description"></p>\n </td>\n </tr>\n </tbody>\n </table>\n <button class="button button-primary" ng-click="$ctrl.save()">\n {{ ::$ctrl.i18n.submit }}\n </button>\n '};n["default"]=a},{"./../base.controller":7}],5:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t){r(this,e),this.$compile=t,this.restrict="E",this.scope={name:"=",priority:"=",template:"=",update:"&"}}return i(e,[{key:"link",value:function(e,t,n){var r=e.template,i=r.replace("%name%",'<editor-checkbox args="name" on-update="update({ $event })" add-br="false"></editor-checkbox>').replace("%priority%",'<editor-number args="priority" on-update="update({ $event })"></editor-number>');t.html(i),this.$compile(t.contents())(e)}}]),e}();n["default"]=o},{}],6:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./filter.directive"),s=r(a),u=e("./advanced.component"),l=r(u),c=e("./../../components/components"),f=r(c),d=o["default"].module("app.common.advanced",[f["default"]]).directive("filter",["$compile",function(e){return new s["default"](e)}]).component("advancedEditor",l["default"]).name;n["default"]=d},{"./../../components/components":18,"./advanced.component":4,"./filter.directive":5,angular:46}],7:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(t){r(this,e),this.httpService=t}return o(e,[{key:"$onChanges",value:function(e){var t=this;e.settings&&(this.settings=i({},this.settings),this.values=Object.keys(this.settings).reduce(function(e,n){return e[n]=t.settings[n].value,e},{}))}},{key:"update",value:function(e){var t=e.key,n=e.value;this.values[t]=n}},{key:"updateValue",value:function(e,t){this.settings[e]=i({},this.settings[e],{value:t}),this.values[e]=t}},{key:"save",value:function(){var e=this;this.httpService.saveSettings(this.values).then(function(t){var n=t.status,r=t.model;"OK"===n.status&&(e.values=r,Object.keys(e.values).forEach(function(t){e.settings[t]=i({},e.settings[t],{value:e.values[t]})}))})}}]),e}();a.$inject=["httpService"],n["default"]=a},{}],8:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./select"),s=r(a),u=e("./visual"),l=r(u),c=e("./import"),f=r(c),d=e("./advanced"),p=r(d),h=o["default"].module("app.common",[s["default"],l["default"],f["default"],p["default"]]).name;n["default"]=h},{"./advanced":6,"./import":11,"./select":12,"./visual":15,angular:46}],9:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./import.controller"),o=r(i),a={bindings:{i18n:"<"},controller:o["default"],template:'\n <h2>{{ ::$ctrl.i18n.title }}</h2>\n <table class="form-table">\n <tbody>\n <tr>\n <th><label>{{ ::$ctrl.i18n.export_title }}</label></th>\n <td>\n <a href="{{ ::$ctrl.i18n.export_url }}" class="button button-default">\n {{ ::$ctrl.i18n.export_button_text }}\n </a>\n </td>\n </tr>\n <tr>\n <th><label>{{ ::$ctrl.i18n.import_title }}</label></th>\n <td>\n <button class="button button-primary" type="file"\n ngf-accept="\'.json\'"\n ngf-select="$ctrl.uploadFiles($file, $invalidFiles)" ngf-max-size="1MB">\n {{ ::$ctrl.i18n.import_button_text }}\n </button>\n <div ng-if="$ctrl.upload_status === \'OK\' || $ctrl.upload_status === \'ERROR\'" class="notice"\n ng-class="{ \'error\': $ctrl.upload_status === \'ERROR\', \'updated\': $ctrl.upload_status === \'OK\' }">\n <p><strong ng-bind-html="$ctrl.upload_message"></strong></p>\n </div>\n </td>\n </tr>\n </tbody>\n </table>\n '};n["default"]=a},{"./import.controller":10}],10:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t,n,i){r(this,e),this.$timeout=t,this.httpService=i,this.Upload=n,this.upload_status="",this.upload_message=""}return i(e,[{key:"uploadFiles",value:function(e,t){this.f=e,this.errFile=t&&t[0],e&&this.httpService.uploadFile(this.i18n.import_action_name,e)}}]),e}();o.$inject=["$timeout","Upload","httpService"],n["default"]=o},{}],11:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./import.component"),s=r(a),u=o["default"].module("app.common.import",[]).component("importEditor",s["default"]).name;n["default"]=u},{"./import.component":9,angular:46}],12:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./resolution.directive"),s=r(a),u=e("./select.component"),l=r(u),c=e("./../../components/components"),f=r(c),d=o["default"].module("app.common.select",[f["default"]]).directive("resolution",["$compile",function(e){return new s["default"](e)}]).component("selectEditor",l["default"]).name;n["default"]=d},{"./../../components/components":18,"./resolution.directive":13,"./select.component":14,angular:46}],13:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t){r(this,e),this.$compile=t,this.restrict="E",this.scope={height:"=",width:"=",template:"=",update:"&"}}return i(e,[{key:"link",value:function(e,t,n){var r=e.template,i=r.replace("%height%",'<editor-number args="height" on-update="update({ $event })"></editor-number>').replace("%width%",'<editor-number args="width" on-update="update({ $event })"></editor-number>');t.html(i),this.$compile(t.contents())(e)}}]),e}();n["default"]=o},{}],14:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./../base.controller"),o=r(i),a={bindings:{settings:"<",i18n:"<"},controller:o["default"],template:'\n <h2>{{ $ctrl.i18n.title }}</h2>\n <table class="form-table">\n <tbody>\n <tr>\n <th><label for="image_selector">{{ ::$ctrl.settings.image_selector.label }}</label></th>\n <td>\n <editor-text args="$ctrl.settings.image_selector" on-update="$ctrl.update($event)"></editor-text>\n <p class="description" ng-bind-html="$ctrl.settings.image_selector.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label for="disabled_classes">{{ ::$ctrl.settings.disabled_classes.label }}</label></th>\n <td>\n <editor-text args="$ctrl.settings.disabled_classes" on-update="$ctrl.update($event)"></editor-text>\n <p class="description" ng-bind-html="$ctrl.settings.disabled_classes.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label for="enabled_classes">{{ ::$ctrl.settings.enabled_classes.label }}</label></th>\n <td>\n <editor-text args="$ctrl.settings.enabled_classes" on-update="$ctrl.update($event)"></editor-text>\n <p class="description" ng-bind-html="$ctrl.settings.enabled_classes.desc"></p>\n </td>\n </tr>\n <tr>\n <th>{{ ::$ctrl.i18n.image_resolution_label }}</th>\n <td>\n <p>\n <resolution height="$ctrl.settings.min_image_height_small" width="$ctrl.settings.min_image_width_small"\n update="$ctrl.update($event)" template="$ctrl.i18n.min_resolution_template_small">\n </resolution>\n </p>\n <p>\n <resolution height="$ctrl.settings.min_image_height" width="$ctrl.settings.min_image_width"\n update="$ctrl.update($event)" template="$ctrl.i18n.min_resolution_template">\n </resolution>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.image_resolution_desc"></p>\n <p class="description" ng-bind-html="$ctrl.i18n.image_resolution_desc_2"></p>\n </td>\n </tr>\n <tr>\n <th>{{ ::$ctrl.i18n.show_on_field_label }}</th>\n <td>\n <p>\n <label for="show_on">{{ ::$ctrl.settings.show_on.label }}:</label><br/>\n <editor-textarea args="$ctrl.settings.show_on" on-update="$ctrl.update($event)"></editor-text>\n </p>\n <p>\n <label for="disable_on">{{ ::$ctrl.settings.disable_on.label }}:</label><br/>\n <editor-textarea args="$ctrl.settings.disable_on" on-update="$ctrl.update($event)"></editor-text>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.show_on_field_desc"></p>\n </td>\n </tr>\n </tbody>\n </table>\n <button class="button button-primary" ng-click="$ctrl.save()">\n {{ ::$ctrl.i18n.submit }}\n </button>\n '};n["default"]=a},{"./../base.controller":7}],15:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./visual.component"),s=r(a),u=e("./../../components/components"),l=r(u),c=o["default"].module("app.common.visual",[l["default"]]).component("visualEditor",s["default"]).name;n["default"]=c},{"./../../components/components":18,"./visual.component":16,angular:46}],16:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./visual.controller"),o=r(i),a={bindings:{settings:"<",i18n:"<"},controller:o["default"],template:'\n <h2>{{ $ctrl.i18n.title }}</h2>\n <table class="form-table">\n <tbody>\n <tr>\n <th><label for="show_button">{{ ::$ctrl.settings.show_button.label }}</label></th>\n <td>\n <editor-select args="$ctrl.settings.show_button" on-update="$ctrl.update($event)"></editor-select>\n <p class="description" ng-bind-html="$ctrl.settings.show_button.desc"></p>\n <p ng-if="$ctrl.values.show_button != \'hover\'">\n <b ng-bind-html="$ctrl.i18n.pro_feature_error"></b>\n </p>\n </td>\n </tr>\n <tr>\n <th><label>{{ ::$ctrl.settings.description_option.label }}</label></th>\n <td>\n <editor-sortable-select args="$ctrl.settings.description_option" on-update="$ctrl.update($event)"></editor-sortable-select>\n <p class="description" ng-bind-html="$ctrl.settings.description_option.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label for="pinLinkedImages">{{ ::$ctrl.settings.pinLinkedImages.label }}</label></th>\n <td>\n <editor-checkbox args="$ctrl.settings.pinLinkedImages" on-update="$ctrl.update($event)"></editor-checkbox>\n <p class="description" ng-bind-html="$ctrl.settings.pinLinkedImages.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label for="transparency_value">{{ ::$ctrl.settings.transparency_value.label }}</label></th>\n <td>\n <editor-number args="$ctrl.settings.transparency_value" on-update="$ctrl.update($event)"></editor-number>\n <p class="description" ng-bind-html="$ctrl.settings.transparency_value.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label>{{ ::$ctrl.settings.pin_image.label }}</label></th>\n <td>\n <table class="jpibfi-inner-table">\n <tr>\n <th>{{ ::$ctrl.i18n.mode }}</th>\n <th ng-if="$ctrl.values.pin_image != \'old_default\'">{{ ::$ctrl.i18n.settings }}</th>\n <th>{{ ::$ctrl.i18n.preview }}</th>\n </tr>\n <tr>\n <td>\n <p><label><input type="radio" ng_model="$ctrl.values.pin_image" value="old_default">{{ ::$ctrl.settings.pin_image.options[\'old_default\'] }}</label></p>\n <p><label><input type="radio" ng_model="$ctrl.values.pin_image" value="default">{{ ::$ctrl.settings.pin_image.options[\'default\'] }}</label></p>\n <p><label><input type="radio" ng_model="$ctrl.values.pin_image" value="custom">{{ ::$ctrl.settings.pin_image.options[\'custom\'] }}</label></p>\n </td>\n <td ng-if="$ctrl.values.pin_image != \'old_default\'">\n <div ng-show="$ctrl.values.pin_image == \'default\'">\n <p>\n <label for="pin_image_icon">{{ ::$ctrl.settings.pin_image_icon.label }}</label>\n <editor-select args="$ctrl.settings.pin_image_icon" on-update="$ctrl.update($event)"></editor-select>\n <p ng-if="$ctrl.values.pin_image_icon != \'circle\'">\n <b ng-bind-html="$ctrl.i18n.pro_feature_error"></b>\n </p>\n </p>\n <p>\n <label for="pin_image_size">{{ ::$ctrl.settings.pin_image_size.label }}</label>\n <editor-select args="$ctrl.settings.pin_image_size" on-update="$ctrl.update($event)"></editor-select>\n </p>\n <p>\n <label for="pin_image_button">{{ ::$ctrl.settings.pin_image_button.label }}</label>\n <editor-select args="$ctrl.settings.pin_image_button" on-update="$ctrl.update($event)"></editor-select>\n </p>\n </div>\n <div ng-if="$ctrl.values.pin_image == \'custom\'">\n <p><button class="button button-default" ng-click="$ctrl.upload()">{{ ::$ctrl.i18n.custom_button_upload }}</button></p>\n <p>\n <label for="custom_image_url">{{ ::$ctrl.settings.custom_image_url.label }}</label>\n <editor-text args="$ctrl.settings.custom_image_url" on-update="$ctrl.update($event)"></editor-text>\n </p>\n <p>\n <div style="display: inline-block; width: 49%;">\n <label for="custom_image_height">{{ ::$ctrl.settings.custom_image_height.label }}</label>\n <editor-number args="$ctrl.settings.custom_image_height" on-update="$ctrl.update($event)"></editor-number>\n </div>\n <div style="display: inline-block; width: 49%;">\n <label for="custom_image_width">{{ ::$ctrl.settings.custom_image_width.label }}</label>\n <editor-number args="$ctrl.settings.custom_image_width" on-update="$ctrl.update($event)"></editor-number>\n </div>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.custom_button_desc"></p>\n </div>\n </td>\n <td>\n <div ng-if="$ctrl.values.pin_image == \'old_default\'">\n <a class="pinit-button old_default"><span></span></a>\n </div>\n <div ng-show="$ctrl.values.pin_image == \'default\'">\n <a class="pinit-button default" ng-class="[\'jpibfi-size-\' + $ctrl.values.pin_image_size, \'jpibfi-button-\' + $ctrl.values.pin_image_button]">\n <span ng-class="[\'jpibfi-icon-\' + $ctrl.values.pin_image_icon]"></span>\n </a>\n </div>\n <div ng-show="$ctrl.values.pin_image == \'custom\'">\n <div ng-if="$ctrl.values.custom_image_url">\n <div style="width: {{ $ctrl.values.custom_image_width }}px;\n height: {{ $ctrl.values.custom_image_height }}px;\n background-image: url(\'{{ $ctrl.values.custom_image_url }}\');">\n </div>\n </div>\n <div ng-if="!$ctrl.values.custom_image_url">\n {{ ::$ctrl.i18n.custom_button_no_image_to_preview }}\n </div>\n </div>\n </td>\n </tr>\n </table>\n </tr>\n <tr>\n <th><label for="button_position">{{ ::$ctrl.settings.button_position.label }}</label></th>\n <td>\n <editor-select args="$ctrl.settings.button_position" on-update="$ctrl.update($event)"></editor-select>\n <p class="description" ng-bind-html="$ctrl.settings.button_position.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label>{{ ::$ctrl.i18n.margins_label }}</label></th>\n <td>\n <p>\n <label for="button_margin_top">{{ ::$ctrl.settings.button_margin_top.label }}</label>\n <editor-number ng-disabled="!$ctrl.marginAvailability.top" args="$ctrl.settings.button_margin_top" on-update="$ctrl.update($event)">\n </editor-number>\n </p>\n <p>\n <label for="button_margin_bottom">{{ ::$ctrl.settings.button_margin_bottom.label }}</label>\n <editor-number ng-disabled="!$ctrl.marginAvailability.bottom" args="$ctrl.settings.button_margin_bottom" on-update="$ctrl.update($event)">\n </editor-number>\n </p>\n <p>\n <label for="button_margin_left">{{ ::$ctrl.settings.button_margin_left.label }}</label>\n <editor-number ng-disabled="!$ctrl.marginAvailability.left" args="$ctrl.settings.button_margin_left" on-update="$ctrl.update($event)">\n </editor-number>\n </p>\n <p>\n <label for="button_margin_right">{{ ::$ctrl.settings.button_margin_right.label }}</label>\n <editor-number ng-disabled="!$ctrl.marginAvailability.right" args="$ctrl.settings.button_margin_right" on-update="$ctrl.update($event)">\n </editor-number>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.margins_desc"></p>\n </td>\n </tr>\n </tbody>\n </table>\n <button class="button button-primary" ng-click="$ctrl.save()">\n {{ ::$ctrl.i18n.submit }}\n </button>\n <p ng-bind-html="$ctrl.i18n.attribution"></p>\n '};n["default"]=a},{"./visual.controller":17}],17:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=function d(e,t,n){null===e&&(e=Function.prototype);var r=Object.getOwnPropertyDescriptor(e,t);if(void 0===r){var i=Object.getPrototypeOf(e);return null===i?void 0:d(i,t,n)}if("value"in r)return r.value;var o=r.get;if(void 0!==o)return o.call(n)},l=e("./../base.controller"),c=r(l),f=function(e){function t(e,n){i(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,n));return r.$scope=e,r.fileFrame=null,r}return a(t,e),s(t,[{key:"$onChanges",value:function(e){u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"$onChanges",this).call(this,e),this.updateMarginAvailability()}},{key:"update",value:function(e){var t=e.key,n=e.value;this.values[t]=n,"button_position"===t&&this.updateMarginAvailability()}},{key:"updateMarginAvailability",value:function(){var e=this.values.button_position;this.marginAvailability={top:"top-left"===e||"top-right"===e,bottom:"bottom-left"===e||"bottom-right"===e,left:"top-left"===e||"bottom-left"===e,right:"top-right"===e||"bottom-right"===e}}},{key:"upload",value:function(){var e=this;return this.fileFrame?void this.fileFrame.open():(this.fileFrame=wp.media.frames.file_frame=wp.media({title:this.i18n.custom_button_frame_title,button:{text:this.i18n.custom_button_frame_button_text},multiple:!1}).on("select",function(){var t=e.fileFrame.state().get("selection").first().toJSON();e.updateValue("custom_image_url",t.url),e.updateValue("custom_image_width",t.width),e.updateValue("custom_image_height",t.height),e.$scope.$digest()}),void this.fileFrame.open())}}]),t}(c["default"]);f.$inject=["$scope","httpService"],n["default"]=f},{"./../base.controller":7}],18:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./navbar"),s=r(a),u=e("./editors"),l=r(u),c=e("./status"),f=r(c),d=o["default"].module("app.components",[s["default"],l["default"],f["default"]]).name;n["default"]=d},{"./editors":32,"./navbar":33,"./status":35,angular:46}],19:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.checkbox.controller"),o=r(i),a={bindings:{args:"<",onUpdate:"&",addBr:"<?"},controller:o["default"],template:'<input type="checkbox" ng-change="$ctrl.change()" id="{{ $ctrl.key }}" ng-model="$ctrl.value">\n <label for=" {{ $ctrl.key }}">{{ ::$ctrl.args.text }}</label><br ng-if="$ctrl.addBr" />'};n["default"]=a},{"./editor.checkbox.controller":20}],20:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=e("./editor.controller"),l=r(u),c=function(e){function t(){return i(this,t),o(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return a(t,e),s(t,[{key:"$onInit",value:function(){void 0===this.addBr&&(this.addBr=!0)}}]),t}(l["default"]);n["default"]=c},{"./editor.controller":23}],21:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.checkboxes.controller"),o=r(i),a={bindings:{args:"<",onUpdate:"&"},controller:o["default"],template:'<p ng-repeat="(key, label) in $ctrl.args.options">\n <input type="checkbox" id="{{:: $ctrl.key + \'_\' + key }}" ng-change="$ctrl.change()" ng-model="$ctrl.values[key]" />\n <label for="{{ $ctrl.key + \'_\' + key }}">{{ ::label }}</label>\n </p>'
|
2 |
-
};n["default"]=a},{"./editor.checkboxes.controller":22}],22:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e),this.key=this.args.key;var t=this.args.value||[];this.values=Object.keys(this.args.options).reduce(function(e,n){return e[n]=t.indexOf(n)!==-1,e},{})}return o(e,[{key:"$onChanges",value:function(e){e.args&&(this.args=i({},this.args))}},{key:"change",value:function(e){var t=this;return this.onUpdate({$event:{key:this.key,value:Object.keys(this.args.options).reduce(function(e,n){return t.values[n]?e.concat([n]):e},[])}}),e}}]),e}();a.$inject=[],n["default"]=a},{}],23:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e)}return o(e,[{key:"$onChanges",value:function(e){e.args&&(this.args=i({},this.args),this.key=this.args.key,this.value=this.args.value)}},{key:"change",value:function(){this.onUpdate({$event:{key:this.key,value:this.value}})}}]),e}();a.$inject=[],n["default"]=a},{}],24:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.controller"),o=r(i),a={bindings:{args:"<",ngDisabled:"<",onUpdate:"&"},controller:o["default"],template:'\n <input id="{{ $ctrl.key }}" ng-disabled="$ctrl.ngDisabled" number-attributes="$ctrl.args" class="small-text" type="number" ng-model="$ctrl.value" ng-change="$ctrl.change()" /> \n <span>{{ ::$ctrl.args.unit }}</span>'};n["default"]=a},{"./editor.controller":23}],25:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t){r(this,e),this.$parse=t,this.restrict="A"}return i(e,[{key:"link",value:function(e,t,n){var r=this.$parse(n.numberAttributes)(e),i=["step","min","max"];i.forEach(function(e){void 0!==r[e]&&t.attr(e,r[e])})}}]),e}();n["default"]=o},{}],26:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.select.controller"),o=r(i),a={bindings:{args:"<",onUpdate:"&"},controller:o["default"],template:'\n <select ng-model="$ctrl.value" ng-change="$ctrl.change()">\n <option ng-repeat="(value, name) in $ctrl.args.options" value="{{ value }}">{{ name }}</option>\n </select>'};n["default"]=a},{"./editor.select.controller":27}],27:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=function d(e,t,n){null===e&&(e=Function.prototype);var r=Object.getOwnPropertyDescriptor(e,t);if(void 0===r){var i=Object.getPrototypeOf(e);return null===i?void 0:d(i,t,n)}if("value"in r)return r.value;var o=r.get;if(void 0!==o)return o.call(n)},l=e("./editor.controller"),c=r(l),f=function(e){function t(){return i(this,t),o(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return a(t,e),s(t,[{key:"$onChanges",value:function(e){u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"$onChanges",this).call(this,e),e.args&&(void 0!==this.args.value&&null!==this.args.value||(this.value=Object.keys(this.args.options)[0],this.change()),this.args.truthy&&(this.value=this.value?"1":"0"))}},{key:"change",value:function(){this.onUpdate({$event:{key:this.key,value:this.args.truthy?"1"===this.value:this.value}})}}]),t}(c["default"]);f.$inject=[],n["default"]=f},{"./editor.controller":23}],28:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.sortableSelect.controller"),o=r(i),a={bindings:{args:"<",onUpdate:"&"},controller:o["default"],template:'\n <ul class="frizzly-sortable" dnd-list="$ctrl.options">\n <li ng-repeat="item in $ctrl.options"\n dnd-draggable="item"\n dnd-moved="$ctrl.options.splice($index, 1); $ctrl.change()"\n dnd-effect-allowed="move">\n <input type="checkbox" id="{{ item.key }}" ng-model="item.selected" ng-change="$ctrl.change()" />\n <label for="{{ item.key }}">{{ item.label }}\n </li>\n </ul>\n '};n["default"]=a},{"./editor.sortableSelect.controller":29}],29:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e)}return o(e,[{key:"$onChanges",value:function(e){var t=this;if(e.args){this.args=i({},this.args),this.key=this.args.key,this.value=this.args.value||[];var n=this.value.slice().concat(Object.keys(this.args.options).filter(function(e){return t.value.indexOf(e)===-1}));this.options=n.map(function(e){return{key:e,label:t.args.options[e],selected:t.value.indexOf(e)!==-1}})}}},{key:"change",value:function(){var e=this.options.reduce(function(e,t){return t.selected?e.concat([t.key]):e},[]);this.onUpdate({$event:{key:this.key,value:e}})}}]),e}();a.$inject=[],n["default"]=a},{}],30:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.controller"),o=r(i),a={bindings:{args:"<",ngDisabled:"<",onUpdate:"&"},controller:o["default"],template:'<input ng-disabled="$ctrl.ngDisabled" type="text" id="{{ $ctrl.key }}" ng-model="$ctrl.value" ng-change="$ctrl.change()" class="regular-text" />'};n["default"]=a},{"./editor.controller":23}],31:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.controller"),o=r(i),a={bindings:{args:"<",onUpdate:"&"},controller:o["default"],template:'<textarea rows="3" cols="50" id="{{ $ctrl.key }}" class="large-text code" ng-model="$ctrl.value" ng-change="$ctrl.change()"></textarea>'};n["default"]=a},{"./editor.controller":23}],32:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./editor.text.component"),s=r(a),u=e("./editor.textarea.component"),l=r(u),c=e("./editor.number.component"),f=r(c),d=e("./editor.number.directive"),p=r(d),h=e("./editor.checkbox.component"),g=r(h),v=e("./editor.checkboxes.component"),m=r(v),$=e("./editor.select.component"),b=r($),y=e("./editor.sortableSelect.component"),w=r(y),x=o["default"].module("editors",["dndLists"]).component("editorText",s["default"]).component("editorTextarea",l["default"]).component("editorNumber",f["default"]).component("editorCheckbox",g["default"]).component("editorCheckboxes",m["default"]).component("editorSelect",b["default"]).component("editorSortableSelect",w["default"]).directive("numberAttributes",["$parse",function(e){return new p["default"](e)}]).name;n["default"]=x},{"./editor.checkbox.component":19,"./editor.checkboxes.component":21,"./editor.number.component":24,"./editor.number.directive":25,"./editor.select.component":26,"./editor.sortableSelect.component":28,"./editor.text.component":30,"./editor.textarea.component":31,angular:46}],33:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./navbar.component"),s=r(a),u=o["default"].module("navbar",[]).component("navbar",s["default"]).name;n["default"]=u},{"./navbar.component":34,angular:46}],34:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={bindings:{currentTab:"<",tabs:"<",page:"<",links:"<"},controller:function(){},template:'\n <h2 class="nav-tab-wrapper">\n <a ng-repeat="tab in $ctrl.tabs" \n href="?page={{ $ctrl.page }}&tab={{ tab.slug }}" class="nav-tab {{ $ctrl.currentTab == tab.slug ? \'nav-tab-active\' : \'\' }}">\n {{ tab.name }}\n </a>\n <a ng-repeat="link in $ctrl.links" href="{{ link.url }}" target="_blank" class="nav-tab">\n {{ link.label }}\n </a>\n </h2>\n '};n["default"]=r},{}],35:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./status.component"),s=r(a),u=o["default"].module("status",[]).component("status",s["default"]).name;n["default"]=u},{"./status.component":36,angular:46}],36:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./status.controller"),o=r(i),a={bindings:{i18n:"<"},controller:o["default"],template:"\n <div class=\"notice notice-success\" ng-if=\"$ctrl.status.status != ''\" ng-class=\"{ \n 'notice-success': $ctrl.status.status === 'OK',\n 'notice-info' : $ctrl.status.status === 'PENDING',\n 'notice-error': $ctrl.status.status === 'ERROR'\n }\">\n <p ng-repeat=\"(key, text) in $ctrl.status.messages\"><strong>{{ text }}</strong></p>\n </div>\n "};n["default"]=a},{"./status.controller":37}],37:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t,n){var i=this;r(this,e),this.$anchorScroll=t,this.status={status:""},n.onRequest(function(){return i.onRequestHandler()}),n.onResponse(function(e){var t=e.status;return i.onResponseHandler(t)})}return i(e,[{key:"onResponseHandler",value:function(e){this.status=e}},{key:"onRequestHandler",value:function(){this.$anchorScroll(),this.status.status="PENDING",this.status.messages={pending:this.i18n.pending}}}]),e}();o.$inject=["$anchorScroll","httpService"],n["default"]=o},{}],38:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=e("angular"),s=r(a),u=function(){function e(t,n,r){i(this,e),this.$http=t,this.$timeout=n,this.Upload=r,this.responseObservers=[],this.requestObservers=[]}return o(e,[{key:"init",value:function(e){this.url=e.url,this.saveSettingsParams={action:e.saveSettingsAction,nonce:e.saveSettingsNonce},this.customActionParams={action:e.customAction,nonce:e.customActionNonce}}},{key:"onRequest",value:function(e){this.requestObservers.push(e)}},{key:"onResponse",value:function(e){this.responseObservers.push(e)}},{key:"saveSettings",value:function(e){var t=s["default"].extend({},this.saveSettingsParams,{settings:e});return this.processRequest(t)}},{key:"customAction",value:function(e,t){var n=s["default"].extend({},this.customActionParams,{name:e,settings:t});return this.processRequest(n)}},{key:"uploadFile",value:function(e,t){var n=this,r=s["default"].extend({},this.customActionParams,{name:e,"import":t}),i=this.Upload.upload({url:this.url,data:r});this.requestObservers.forEach(function(e){e()}),i.then(function(e){var t=e.data;n.$timeout(function(){n.responseObservers.forEach(function(e){e(t)})})},function(e){e.status>0&&(n.errorMsg=e.status+": "+e.data)})}},{key:"processRequest",value:function(e){var t=this,n={method:"POST",url:this.url,params:e};return this.requestObservers.forEach(function(e){e()}),this.$http(n).then(function(e){var n=e.data;return t.responseObservers.forEach(function(e){e(n)}),n})}}]),e}();u.$inject=["$http","$timeout","Upload"],n["default"]=u},{angular:46}],39:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./http.service"),s=r(a),u=e("./link.service"),l=r(u),c=o["default"].module("services",[]).service("httpService",s["default"]).service("linkService",l["default"]).name;n["default"]=c},{"./http.service":38,"./link.service":40,angular:46}],40:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(u){i=!0,o=u}finally{try{!r&&s["return"]&&s["return"]()}finally{if(i)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e),this.baseLink=""}return o(e,[{key:"init",value:function(e){this.baseLink="?page="+e}},{key:"generateQuery",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce(function(e,t){var n=i(t,2),r=n[0],o=n[1];return e+"&"+r+"="+o},this.baseLink)}}]),e}();a.$inject=[],n["default"]=a},{}],41:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}var i=e("./app/app");r(i);!function(e){e(document).ready(function(){})}(jQuery)},{"./app/app":3}],42:[function(e,t,n){angular.module("dndLists",[]).directive("dndDraggable",["$parse","$timeout","dndDropEffectWorkaround","dndDragTypeWorkaround",function(e,t,n,r){return function(i,o,a){o.attr("draggable","true"),a.dndDisableIf&&i.$watch(a.dndDisableIf,function(e){o.attr("draggable",!e)}),o.on("dragstart",function(s){return s=s.originalEvent||s,"false"==o.attr("draggable")||(s.dataTransfer.setData("Text",angular.toJson(i.$eval(a.dndDraggable))),s.dataTransfer.effectAllowed=a.dndEffectAllowed||"move",o.addClass("dndDragging"),t(function(){o.addClass("dndDraggingSource")},0),n.dropEffect="none",r.isDragging=!0,r.dragType=a.dndType?i.$eval(a.dndType):void 0,s._dndHandle&&s.dataTransfer.setDragImage&&s.dataTransfer.setDragImage(o[0],0,0),e(a.dndDragstart)(i,{event:s}),void s.stopPropagation())}),o.on("dragend",function(s){s=s.originalEvent||s;var u=n.dropEffect;i.$apply(function(){switch(u){case"move":e(a.dndMoved)(i,{event:s});break;case"copy":e(a.dndCopied)(i,{event:s});break;case"none":e(a.dndCanceled)(i,{event:s})}e(a.dndDragend)(i,{event:s,dropEffect:u})}),o.removeClass("dndDragging"),t(function(){o.removeClass("dndDraggingSource")},0),r.isDragging=!1,s.stopPropagation()}),o.on("click",function(t){a.dndSelected&&(t=t.originalEvent||t,i.$apply(function(){e(a.dndSelected)(i,{event:t})}),t.stopPropagation())}),o.on("selectstart",function(){this.dragDrop&&this.dragDrop()})}}]).directive("dndList",["$parse","$timeout","dndDropEffectWorkaround","dndDragTypeWorkaround",function(e,t,n,r){return function(i,o,a){function s(e,t,n){var r=m?e.offsetX||e.layerX:e.offsetY||e.layerY,i=m?t.offsetWidth:t.offsetHeight,o=m?t.offsetLeft:t.offsetTop;return o=n?o:0,r<o+i/2}function u(){var e;return angular.forEach(o.children(),function(t){var n=angular.element(t);n.hasClass("dndPlaceholder")&&(e=n)}),e||angular.element("<li class='dndPlaceholder'></li>")}function l(){return Array.prototype.indexOf.call(v.children,g)}function c(e){if(!r.isDragging&&!$)return!1;if(!p(e.dataTransfer.types))return!1;if(a.dndAllowedTypes&&r.isDragging){var t=i.$eval(a.dndAllowedTypes);if(angular.isArray(t)&&t.indexOf(r.dragType)===-1)return!1}return!a.dndDisableIf||!i.$eval(a.dndDisableIf)}function f(){return h.remove(),o.removeClass("dndDragover"),!0}function d(t,n,o,a){return e(t)(i,{event:n,index:o,item:a||void 0,external:!r.isDragging,type:r.isDragging?r.dragType:void 0})}function p(e){if(!e)return!0;for(var t=0;t<e.length;t++)if("Text"===e[t]||"text/plain"===e[t])return!0;return!1}var h=u(),g=h[0],v=o[0];h.remove();var m=a.dndHorizontalList&&i.$eval(a.dndHorizontalList),$=a.dndExternalSources&&i.$eval(a.dndExternalSources);o.on("dragenter",function(e){return e=e.originalEvent||e,!c(e)||void e.preventDefault()}),o.on("dragover",function(e){if(e=e.originalEvent||e,!c(e))return!0;if(g.parentNode!=v&&o.append(h),e.target!==v){for(var t=e.target;t.parentNode!==v&&t.parentNode;)t=t.parentNode;t.parentNode===v&&t!==g&&(s(e,t)?v.insertBefore(g,t):v.insertBefore(g,t.nextSibling))}else if(s(e,g,!0))for(;g.previousElementSibling&&(s(e,g.previousElementSibling,!0)||0===g.previousElementSibling.offsetHeight);)v.insertBefore(g,g.previousElementSibling);else for(;g.nextElementSibling&&!s(e,g.nextElementSibling,!0);)v.insertBefore(g,g.nextElementSibling.nextElementSibling);return a.dndDragover&&!d(a.dndDragover,e,l())?f():(o.addClass("dndDragover"),e.preventDefault(),e.stopPropagation(),!1)}),o.on("drop",function(e){if(e=e.originalEvent||e,!c(e))return!0;e.preventDefault();var t,r=e.dataTransfer.getData("Text")||e.dataTransfer.getData("text/plain");try{t=JSON.parse(r)}catch(o){return f()}var s=l();return a.dndDrop&&(t=d(a.dndDrop,e,s,t),!t)?f():(t!==!0&&i.$apply(function(){i.$eval(a.dndList).splice(s,0,t)}),d(a.dndInserted,e,s,t),"none"===e.dataTransfer.dropEffect?"copy"===e.dataTransfer.effectAllowed||"move"===e.dataTransfer.effectAllowed?n.dropEffect=e.dataTransfer.effectAllowed:n.dropEffect=e.ctrlKey?"copy":"move":n.dropEffect=e.dataTransfer.dropEffect,f(),e.stopPropagation(),!1)}),o.on("dragleave",function(e){e=e.originalEvent||e,o.removeClass("dndDragover"),t(function(){o.hasClass("dndDragover")||h.remove()},100)})}}]).directive("dndNodrag",function(){return function(e,t,n){t.attr("draggable","true"),t.on("dragstart",function(e){e=e.originalEvent||e,e._dndHandle||(e.dataTransfer.types&&e.dataTransfer.types.length||e.preventDefault(),e.stopPropagation())}),t.on("dragend",function(e){e=e.originalEvent||e,e._dndHandle||e.stopPropagation()})}}).directive("dndHandle",function(){return function(e,t,n){t.attr("draggable","true"),t.on("dragstart dragend",function(e){e=e.originalEvent||e,e._dndHandle=!0})}}).factory("dndDragTypeWorkaround",function(){return{}}).factory("dndDropEffectWorkaround",function(){return{}})},{}],43:[function(e,t,n){!function(e,t){"use strict";function n(){function n(e,t){var n,r={},i=e.split(",");for(n=0;n<i.length;n++)r[t?u(i[n]):i[n]]=!0;return r}function r(t,n){null===t||void 0===t?t="":"string"!=typeof t&&(t=""+t),$.innerHTML=t;var r=5;do{if(0===r)throw d("uinput","Failed to sanitize html because the input is unstable");r--,e.document.documentMode&&v($),t=$.innerHTML,$.innerHTML=t}while(t!==$.innerHTML);for(var i=$.firstChild;i;){switch(i.nodeType){case 1:n.start(i.nodeName.toLowerCase(),p(i.attributes));break;case 3:n.chars(i.textContent)}var o;if(!(o=i.firstChild)&&(1==i.nodeType&&n.end(i.nodeName.toLowerCase()),o=i.nextSibling,!o))for(;null==o&&(i=i.parentNode,i!==$);)o=i.nextSibling,1==i.nodeType&&n.end(i.nodeName.toLowerCase());i=o}for(;i=$.firstChild;)$.removeChild(i)}function p(e){for(var t={},n=0,r=e.length;n<r;n++){var i=e[n];t[i.name]=i.value}return t}function h(e){return e.replace(/&/g,"&").replace(b,function(e){var t=e.charCodeAt(0),n=e.charCodeAt(1);return"&#"+(1024*(t-55296)+(n-56320)+65536)+";"}).replace(y,function(e){return"&#"+e.charCodeAt(0)+";"}).replace(/</g,"<").replace(/>/g,">")}function g(e,t){var n=!1,r=i(e,e.push);return{start:function(e,i){e=u(e),!n&&A[e]&&(n=e),n||O[e]!==!0||(r("<"),r(e),a(i,function(n,i){var o=u(i),a="img"===e&&"src"===o||"background"===o;T[o]!==!0||M[o]===!0&&!t(n,a)||(r(" "),r(i),r('="'),r(h(n)),r('"'))}),r(">"))},end:function(e){e=u(e),n||O[e]!==!0||w[e]===!0||(r("</"),r(e),r(">")),e==n&&(n=!1)},chars:function(e){n||r(h(e))}}}function v(t){if(t.nodeType===e.Node.ELEMENT_NODE)for(var n=t.attributes,r=0,i=n.length;r<i;r++){var o=n[r],a=o.name.toLowerCase();"xmlns:ns1"!==a&&0!==a.lastIndexOf("ns1:",0)||(t.removeAttributeNode(o),r--,i--)}var s=t.firstChild;s&&v(s),s=t.nextSibling,s&&v(s)}var m=!1;this.$get=["$$sanitizeUri",function(e){return m&&o(O,C),function(t){var n=[];return c(t,f(n,function(t,n){return!/^unsafe:/.test(e(t,n))})),n.join("")}}],this.enableSvg=function(e){return s(e)?(m=e,this):m},i=t.bind,o=t.extend,a=t.forEach,s=t.isDefined,u=t.lowercase,l=t.noop,c=r,f=g;var $,b=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,y=/([^\#-~ |!])/g,w=n("area,br,col,hr,img,wbr"),x=n("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),_=n("rp,rt"),k=o({},_,x),S=o({},x,n("address,article,aside,blockquote,caption,center,del,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,map,menu,nav,ol,pre,section,table,ul")),E=o({},_,n("a,abbr,acronym,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,q,ruby,rp,rt,s,samp,small,span,strike,strong,sub,sup,time,tt,u,var")),C=n("circle,defs,desc,ellipse,font-face,font-face-name,font-face-src,g,glyph,hkern,image,linearGradient,line,marker,metadata,missing-glyph,mpath,path,polygon,polyline,radialGradient,rect,stop,svg,switch,text,title,tspan"),A=n("script,style"),O=o({},w,S,E,k),M=n("background,cite,href,longdesc,src,xlink:href"),j=n("abbr,align,alt,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,coords,dir,face,headers,height,hreflang,hspace,ismap,lang,language,nohref,nowrap,rel,rev,rows,rowspan,rules,scope,scrolling,shape,size,span,start,summary,tabindex,target,title,type,valign,value,vspace,width"),P=n("accent-height,accumulate,additive,alphabetic,arabic-form,ascent,baseProfile,bbox,begin,by,calcMode,cap-height,class,color,color-rendering,content,cx,cy,d,dx,dy,descent,display,dur,end,fill,fill-rule,font-family,font-size,font-stretch,font-style,font-variant,font-weight,from,fx,fy,g1,g2,glyph-name,gradientUnits,hanging,height,horiz-adv-x,horiz-origin-x,ideographic,k,keyPoints,keySplines,keyTimes,lang,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mathematical,max,min,offset,opacity,orient,origin,overline-position,overline-thickness,panose-1,path,pathLength,points,preserveAspectRatio,r,refX,refY,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,rotate,rx,ry,slope,stemh,stemv,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,systemLanguage,target,text-anchor,to,transform,type,u1,u2,underline-position,underline-thickness,unicode,unicode-range,units-per-em,values,version,viewBox,visibility,width,widths,x,x-height,x1,x2,xlink:actuate,xlink:arcrole,xlink:role,xlink:show,xlink:title,xlink:type,xml:base,xml:lang,xml:space,xmlns,xmlns:xlink,y,y1,y2,zoomAndPan",!0),T=o({},M,P,j);!function(e){var t;if(!e.document||!e.document.implementation)throw d("noinert","Can't create an inert html document");t=e.document.implementation.createHTMLDocument("inert");var n=t.documentElement||t.getDocumentElement(),r=n.getElementsByTagName("body");if(1===r.length)$=r[0];else{var i=t.createElement("html");$=t.createElement("body"),i.appendChild($),t.appendChild(i)}}(e)}function r(e){var t=[],n=f(t,l);return n.chars(e),t.join("")}var i,o,a,s,u,l,c,f,d=t.$$minErr("$sanitize");t.module("ngSanitize",[]).provider("$sanitize",n),t.module("ngSanitize").filter("linky",["$sanitize",function(e){var n=/((ftp|https?):\/\/|(www\.)|(mailto:)?[A-Za-z0-9._%+-]+@)\S*[^\s.;,(){}<>"\u201d\u2019]/i,i=/^mailto:/i,o=t.$$minErr("linky"),a=t.isDefined,s=t.isFunction,u=t.isObject,l=t.isString;return function(t,c,f){function d(e){e&&b.push(r(e))}function p(e,t){var n,r=m(e);b.push("<a ");for(n in r)b.push(n+'="'+r[n]+'" ');!a(c)||"target"in r||b.push('target="',c,'" '),b.push('href="',e.replace(/"/g,"""),'">'),d(t),b.push("</a>")}if(null==t||""===t)return t;if(!l(t))throw o("notstring","Expected string but received: {0}",t);for(var h,g,v,m=s(f)?f:u(f)?function(){return f}:function(){return{}},$=t,b=[];h=$.match(n);)g=h[0],h[2]||h[4]||(g=(h[3]?"http://":"mailto:")+g),v=h.index,d($.substr(0,v)),p(g,h[0].replace(i,"")),$=$.substring(v+h[0].length);return d($),e(b.join(""))}}])}(window,window.angular)},{}],44:[function(e,t,n){e("./angular-sanitize"),t.exports="ngSanitize"},{"./angular-sanitize":43}],45:[function(e,t,n){!function(e){"use strict";function t(e,t){return t=t||Error,function(){var n,r,i=2,o=arguments,a=o[0],s="["+(e?e+":":"")+a+"] ",u=o[1];for(s+=u.replace(/\{\d+\}/g,function(e){var t=+e.slice(1,-1),n=t+i;return n<o.length?$e(o[n]):e}),s+="\nhttp://errors.angularjs.org/1.5.8/"+(e?e+"/":"")+a,r=i,n="?";r<o.length;r++,n="&")s+=n+"p"+(r-i)+"="+encodeURIComponent($e(o[r]));return new t(s)}}function n(e){if(null==e||E(e))return!1;if(Kr(e)||w(e)||Rr&&e instanceof Rr)return!0;var t="length"in Object(e)&&e.length;return x(t)&&(t>=0&&(t-1 in e||e instanceof Array)||"function"==typeof e.item)}function r(e,t,i){var o,a;if(e)if(k(e))for(o in e)"prototype"==o||"length"==o||"name"==o||e.hasOwnProperty&&!e.hasOwnProperty(o)||t.call(i,e[o],o,e);else if(Kr(e)||n(e)){var s="object"!=typeof e;for(o=0,a=e.length;o<a;o++)(s||o in e)&&t.call(i,e[o],o,e)}else if(e.forEach&&e.forEach!==r)e.forEach(t,i,e);else if(y(e))for(o in e)t.call(i,e[o],o,e);else if("function"==typeof e.hasOwnProperty)for(o in e)e.hasOwnProperty(o)&&t.call(i,e[o],o,e);else for(o in e)Pr.call(e,o)&&t.call(i,e[o],o,e);return e}function i(e,t,n){for(var r=Object.keys(e).sort(),i=0;i<r.length;i++)t.call(n,e[r[i]],r[i]);return r}function o(e){return function(t,n){e(n,t)}}function a(){return++Xr}function s(e,t){t?e.$$hashKey=t:delete e.$$hashKey}function u(e,t,n){for(var r=e.$$hashKey,i=0,o=t.length;i<o;++i){var a=t[i];if(b(a)||k(a))for(var l=Object.keys(a),c=0,f=l.length;c<f;c++){var d=l[c],p=a[d];n&&b(p)?_(p)?e[d]=new Date(p.valueOf()):S(p)?e[d]=new RegExp(p):p.nodeName?e[d]=p.cloneNode(!0):F(p)?e[d]=p.clone():(b(e[d])||(e[d]=Kr(p)?[]:{}),u(e[d],[p],!0)):e[d]=p}}return s(e,r),e}function l(e){return u(e,zr.call(arguments,1),!1)}function c(e){return u(e,zr.call(arguments,1),!0)}function f(e){return parseInt(e,10)}function d(e,t){return l(Object.create(e),t)}function p(){}function h(e){return e}function g(e){return function(){return e}}function v(e){return k(e.toString)&&e.toString!==Hr}function m(e){return"undefined"==typeof e}function $(e){return"undefined"!=typeof e}function b(e){return null!==e&&"object"==typeof e}function y(e){return null!==e&&"object"==typeof e&&!Br(e)}function w(e){return"string"==typeof e}function x(e){return"number"==typeof e}function _(e){return"[object Date]"===Hr.call(e)}function k(e){return"function"==typeof e}function S(e){return"[object RegExp]"===Hr.call(e)}function E(e){return e&&e.window===e}function C(e){return e&&e.$evalAsync&&e.$watch}function A(e){return"[object File]"===Hr.call(e)}function O(e){return"[object FormData]"===Hr.call(e)}function M(e){return"[object Blob]"===Hr.call(e)}function j(e){return"boolean"==typeof e}function P(e){return e&&k(e.then)}function T(e){return e&&x(e.length)&&Yr.test(Hr.call(e))}function D(e){return"[object ArrayBuffer]"===Hr.call(e)}function F(e){return!(!e||!(e.nodeName||e.prop&&e.attr&&e.find))}function N(e){var t,n={},r=e.split(",");for(t=0;t<r.length;t++)n[r[t]]=!0;return n}function I(e){return Tr(e.nodeName||e[0]&&e[0].nodeName)}function R(e,t){var n=e.indexOf(t);return n>=0&&e.splice(n,1),n}function U(e,t){function n(e,t){var n,r=t.$$hashKey;if(Kr(e))for(var o=0,a=e.length;o<a;o++)t.push(i(e[o]));else if(y(e))for(n in e)t[n]=i(e[n]);else if(e&&"function"==typeof e.hasOwnProperty)for(n in e)e.hasOwnProperty(n)&&(t[n]=i(e[n]));else for(n in e)Pr.call(e,n)&&(t[n]=i(e[n]));return s(t,r),t}function i(e){if(!b(e))return e;var t=a.indexOf(e);if(t!==-1)return u[t];if(E(e)||C(e))throw Wr("cpws","Can't copy! Making copies of Window or Scope instances is not supported.");var r=!1,i=o(e);return void 0===i&&(i=Kr(e)?[]:Object.create(Br(e)),r=!0),a.push(e),u.push(i),r?n(e,i):i}function o(e){switch(Hr.call(e)){case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Float32Array]":case"[object Float64Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return new e.constructor(i(e.buffer),e.byteOffset,e.length);case"[object ArrayBuffer]":if(!e.slice){var t=new ArrayBuffer(e.byteLength);return new Uint8Array(t).set(new Uint8Array(e)),t}return e.slice(0);case"[object Boolean]":case"[object Number]":case"[object String]":case"[object Date]":return new e.constructor(e.valueOf());case"[object RegExp]":var n=new RegExp(e.source,e.toString().match(/[^\/]*$/)[0]);return n.lastIndex=e.lastIndex,n;case"[object Blob]":return new e.constructor([e],{type:e.type})}if(k(e.cloneNode))return e.cloneNode(!0)}var a=[],u=[];if(t){if(T(t)||D(t))throw Wr("cpta","Can't copy! TypedArray destination cannot be mutated.");if(e===t)throw Wr("cpi","Can't copy! Source and destination are identical.");return Kr(t)?t.length=0:r(t,function(e,n){"$$hashKey"!==n&&delete t[n]}),a.push(e),u.push(t),n(e,t)}return i(e)}function V(e,t){if(e===t)return!0;if(null===e||null===t)return!1;if(e!==e&&t!==t)return!0;var n,r,i,o=typeof e,a=typeof t;if(o==a&&"object"==o){if(!Kr(e)){
|
3 |
-
if(_(e))return!!_(t)&&V(e.getTime(),t.getTime());if(S(e))return!!S(t)&&e.toString()==t.toString();if(C(e)||C(t)||E(e)||E(t)||Kr(t)||_(t)||S(t))return!1;i=he();for(r in e)if("$"!==r.charAt(0)&&!k(e[r])){if(!V(e[r],t[r]))return!1;i[r]=!0}for(r in t)if(!(r in i)&&"$"!==r.charAt(0)&&$(t[r])&&!k(t[r]))return!1;return!0}if(!Kr(t))return!1;if((n=e.length)==t.length){for(r=0;r<n;r++)if(!V(e[r],t[r]))return!1;return!0}}return!1}function z(e,t,n){return e.concat(zr.call(t,n))}function L(e,t){return zr.call(e,t||0)}function q(e,t){var n=arguments.length>2?L(arguments,2):[];return!k(t)||t instanceof RegExp?t:n.length?function(){return arguments.length?t.apply(e,z(n,arguments,0)):t.apply(e,n)}:function(){return arguments.length?t.apply(e,arguments):t.call(e)}}function H(t,n){var r=n;return"string"==typeof t&&"$"===t.charAt(0)&&"$"===t.charAt(1)?r=void 0:E(n)?r="$WINDOW":n&&e.document===n?r="$DOCUMENT":C(n)&&(r="$SCOPE"),r}function B(e,t){if(!m(e))return x(t)||(t=t?2:null),JSON.stringify(e,H,t)}function W(e){return w(e)?JSON.parse(e):e}function G(e,t){e=e.replace(ti,"");var n=Date.parse("Jan 01, 1970 00:00:00 "+e)/6e4;return isNaN(n)?t:n}function X(e,t){return e=new Date(e.getTime()),e.setMinutes(e.getMinutes()+t),e}function K(e,t,n){n=n?-1:1;var r=e.getTimezoneOffset(),i=G(t,r);return X(e,n*(i-r))}function Y(e){e=Rr(e).clone();try{e.empty()}catch(t){}var n=Rr("<div>").append(e).html();try{return e[0].nodeType===si?Tr(n):n.match(/^(<[^>]+>)/)[1].replace(/^<([\w\-]+)/,function(e,t){return"<"+Tr(t)})}catch(t){return Tr(n)}}function Z(e){try{return decodeURIComponent(e)}catch(t){}}function J(e){var t={};return r((e||"").split("&"),function(e){var n,r,i;e&&(r=e=e.replace(/\+/g,"%20"),n=e.indexOf("="),n!==-1&&(r=e.substring(0,n),i=e.substring(n+1)),r=Z(r),$(r)&&(i=!$(i)||Z(i),Pr.call(t,r)?Kr(t[r])?t[r].push(i):t[r]=[t[r],i]:t[r]=i))}),t}function Q(e){var t=[];return r(e,function(e,n){Kr(e)?r(e,function(e){t.push(te(n,!0)+(e===!0?"":"="+te(e,!0)))}):t.push(te(n,!0)+(e===!0?"":"="+te(e,!0)))}),t.length?t.join("&"):""}function ee(e){return te(e,!0).replace(/%26/gi,"&").replace(/%3D/gi,"=").replace(/%2B/gi,"+")}function te(e,t){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%3B/gi,";").replace(/%20/g,t?"%20":"+")}function ne(e,t){var n,r,i=ni.length;for(r=0;r<i;++r)if(n=ni[r]+t,w(n=e.getAttribute(n)))return n;return null}function re(e,t){var n,i,o={};r(ni,function(t){var r=t+"app";!n&&e.hasAttribute&&e.hasAttribute(r)&&(n=e,i=e.getAttribute(r))}),r(ni,function(t){var r,o=t+"app";!n&&(r=e.querySelector("["+o.replace(":","\\:")+"]"))&&(n=r,i=r.getAttribute(o))}),n&&(o.strictDi=null!==ne(n,"strict-di"),t(n,i?[i]:[],o))}function ie(t,n,i){b(i)||(i={});var o={strictDi:!1};i=l(o,i);var a=function(){if(t=Rr(t),t.injector()){var r=t[0]===e.document?"document":Y(t);throw Wr("btstrpd","App already bootstrapped with this element '{0}'",r.replace(/</,"<").replace(/>/,">"))}n=n||[],n.unshift(["$provide",function(e){e.value("$rootElement",t)}]),i.debugInfoEnabled&&n.push(["$compileProvider",function(e){e.debugInfoEnabled(!0)}]),n.unshift("ng");var o=rt(n,i.strictDi);return o.invoke(["$rootScope","$rootElement","$compile","$injector",function(e,t,n,r){e.$apply(function(){t.data("$injector",r),n(t)(e)})}]),o},s=/^NG_ENABLE_DEBUG_INFO!/,u=/^NG_DEFER_BOOTSTRAP!/;return e&&s.test(e.name)&&(i.debugInfoEnabled=!0,e.name=e.name.replace(s,"")),e&&!u.test(e.name)?a():(e.name=e.name.replace(u,""),Gr.resumeBootstrap=function(e){return r(e,function(e){n.push(e)}),a()},void(k(Gr.resumeDeferredBootstrap)&&Gr.resumeDeferredBootstrap()))}function oe(){e.name="NG_ENABLE_DEBUG_INFO!"+e.name,e.location.reload()}function ae(e){var t=Gr.element(e).injector();if(!t)throw Wr("test","no injector found for element argument to getTestability");return t.get("$$testability")}function se(e,t){return t=t||"_",e.replace(ri,function(e,n){return(n?t:"")+e.toLowerCase()})}function ue(){var t;if(!ii){var n=ei();Ur=m(n)?e.jQuery:n?e[n]:void 0,Ur&&Ur.fn.on?(Rr=Ur,l(Ur.fn,{scope:Ei.scope,isolateScope:Ei.isolateScope,controller:Ei.controller,injector:Ei.injector,inheritedData:Ei.inheritedData}),t=Ur.cleanData,Ur.cleanData=function(e){for(var n,r,i=0;null!=(r=e[i]);i++)n=Ur._data(r,"events"),n&&n.$destroy&&Ur(r).triggerHandler("$destroy");t(e)}):Rr=Oe,Gr.element=Rr,ii=!0}}function le(e,t,n){if(!e)throw Wr("areq","Argument '{0}' is {1}",t||"?",n||"required");return e}function ce(e,t,n){return n&&Kr(e)&&(e=e[e.length-1]),le(k(e),t,"not a function, got "+(e&&"object"==typeof e?e.constructor.name||"Object":typeof e)),e}function fe(e,t){if("hasOwnProperty"===e)throw Wr("badname","hasOwnProperty is not a valid {0} name",t)}function de(e,t,n){if(!t)return e;for(var r,i=t.split("."),o=e,a=i.length,s=0;s<a;s++)r=i[s],e&&(e=(o=e)[r]);return!n&&k(e)?q(o,e):e}function pe(e){for(var t,n=e[0],r=e[e.length-1],i=1;n!==r&&(n=n.nextSibling);i++)(t||e[i]!==n)&&(t||(t=Rr(zr.call(e,0,i))),t.push(n));return t||e}function he(){return Object.create(null)}function ge(e){function n(e,t,n){return e[t]||(e[t]=n())}var r=t("$injector"),i=t("ng"),o=n(e,"angular",Object);return o.$$minErr=o.$$minErr||t,n(o,"module",function(){var e={};return function(t,o,a){var s=function(e,t){if("hasOwnProperty"===e)throw i("badname","hasOwnProperty is not a valid {0} name",t)};return s(t,"module"),o&&e.hasOwnProperty(t)&&(e[t]=null),n(e,t,function(){function e(e,t,n,r){return r||(r=i),function(){return r[n||"push"]([e,t,arguments]),c}}function n(e,n){return function(r,o){return o&&k(o)&&(o.$$moduleName=t),i.push([e,n,arguments]),c}}if(!o)throw r("nomod","Module '{0}' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.",t);var i=[],s=[],u=[],l=e("$injector","invoke","push",s),c={_invokeQueue:i,_configBlocks:s,_runBlocks:u,requires:o,name:t,provider:n("$provide","provider"),factory:n("$provide","factory"),service:n("$provide","service"),value:e("$provide","value"),constant:e("$provide","constant","unshift"),decorator:n("$provide","decorator"),animation:n("$animateProvider","register"),filter:n("$filterProvider","register"),controller:n("$controllerProvider","register"),directive:n("$compileProvider","directive"),component:n("$compileProvider","component"),config:l,run:function(e){return u.push(e),this}};return a&&l(a),c})}})}function ve(e,t){if(Kr(e)){t=t||[];for(var n=0,r=e.length;n<r;n++)t[n]=e[n]}else if(b(e)){t=t||{};for(var i in e)"$"===i.charAt(0)&&"$"===i.charAt(1)||(t[i]=e[i])}return t||e}function me(e){var t=[];return JSON.stringify(e,function(e,n){if(n=H(e,n),b(n)){if(t.indexOf(n)>=0)return"...";t.push(n)}return n})}function $e(e){return"function"==typeof e?e.toString().replace(/ \{[\s\S]*$/,""):m(e)?"undefined":"string"!=typeof e?me(e):e}function be(n){l(n,{bootstrap:ie,copy:U,extend:l,merge:c,equals:V,element:Rr,forEach:r,injector:rt,noop:p,bind:q,toJson:B,fromJson:W,identity:h,isUndefined:m,isDefined:$,isString:w,isFunction:k,isObject:b,isNumber:x,isElement:F,isArray:Kr,version:fi,isDate:_,lowercase:Tr,uppercase:Dr,callbacks:{$$counter:0},getTestability:ae,$$minErr:t,$$csp:Qr,reloadWithDebugInfo:oe}),(Vr=ge(e))("ng",["ngLocale"],["$provide",function(e){e.provider({$$sanitizeUri:Sn}),e.provider("$compile",ht).directive({a:Fo,input:ea,textarea:ea,form:Vo,script:Ka,select:Ja,style:es,option:Qa,ngBind:ra,ngBindHtml:oa,ngBindTemplate:ia,ngClass:sa,ngClassEven:la,ngClassOdd:ua,ngCloak:ca,ngController:fa,ngForm:zo,ngHide:La,ngIf:ha,ngInclude:ga,ngInit:ma,ngNonBindable:Ta,ngPluralize:Ia,ngRepeat:Ra,ngShow:za,ngStyle:qa,ngSwitch:Ha,ngSwitchWhen:Ba,ngSwitchDefault:Wa,ngOptions:Na,ngTransclude:Xa,ngModel:Ma,ngList:$a,ngChange:aa,pattern:ns,ngPattern:ns,required:ts,ngRequired:ts,minlength:is,ngMinlength:is,maxlength:rs,ngMaxlength:rs,ngValue:na,ngModelOptions:Pa}).directive({ngInclude:va}).directive(No).directive(da),e.provider({$anchorScroll:it,$animate:Li,$animateCss:Bi,$$animateJs:Vi,$$animateQueue:zi,$$AnimateRunner:Hi,$$animateAsyncRun:qi,$browser:ct,$cacheFactory:ft,$controller:yt,$document:wt,$exceptionHandler:xt,$filter:Un,$$forceReflow:Zi,$interpolate:Nt,$interval:It,$http:Pt,$httpParamSerializer:kt,$httpParamSerializerJQLike:St,$httpBackend:Dt,$xhrFactory:Tt,$jsonpCallbacks:ao,$location:Jt,$log:Qt,$parse:bn,$rootScope:kn,$q:yn,$$q:wn,$sce:On,$sceDelegate:An,$sniffer:Mn,$templateCache:dt,$templateRequest:jn,$$testability:Pn,$timeout:Tn,$window:Nn,$$rAF:_n,$$jqLite:Ye,$$HashMap:Mi,$$cookieReader:Rn})}])}function ye(){return++pi}function we(e){return e.replace(vi,function(e,t,n,r){return r?n.toUpperCase():n}).replace(mi,"Moz$1")}function xe(e){return!wi.test(e)}function _e(e){var t=e.nodeType;return t===oi||!t||t===li}function ke(e){for(var t in di[e.ng339])return!0;return!1}function Se(e){for(var t=0,n=e.length;t<n;t++)Te(e[t])}function Ee(e,t){var n,i,o,a,s=t.createDocumentFragment(),u=[];if(xe(e))u.push(t.createTextNode(e));else{for(n=s.appendChild(t.createElement("div")),i=(xi.exec(e)||["",""])[1].toLowerCase(),o=ki[i]||ki._default,n.innerHTML=o[1]+e.replace(_i,"<$1></$2>")+o[2],a=o[0];a--;)n=n.lastChild;u=z(u,n.childNodes),n=s.firstChild,n.textContent=""}return s.textContent="",s.innerHTML="",r(u,function(e){s.appendChild(e)}),s}function Ce(t,n){n=n||e.document;var r;return(r=yi.exec(t))?[n.createElement(r[1])]:(r=Ee(t,n))?r.childNodes:[]}function Ae(e,t){var n=e.parentNode;n&&n.replaceChild(t,e),t.appendChild(e)}function Oe(e){if(e instanceof Oe)return e;var t;if(w(e)&&(e=Zr(e),t=!0),!(this instanceof Oe)){if(t&&"<"!=e.charAt(0))throw bi("nosel","Looking up elements via selectors is not supported by jqLite! See: http://docs.angularjs.org/api/angular.element");return new Oe(e)}t?Ue(this,Ce(e)):Ue(this,e)}function Me(e){return e.cloneNode(!0)}function je(e,t){if(t||Te(e),e.querySelectorAll)for(var n=e.querySelectorAll("*"),r=0,i=n.length;r<i;r++)Te(n[r])}function Pe(e,t,n,i){if($(i))throw bi("offargs","jqLite#off() does not support the `selector` argument");var o=De(e),a=o&&o.events,s=o&&o.handle;if(s)if(t){var u=function(t){var r=a[t];$(n)&&R(r||[],n),$(n)&&r&&r.length>0||(gi(e,t,s),delete a[t])};r(t.split(" "),function(e){u(e),$i[e]&&u($i[e])})}else for(t in a)"$destroy"!==t&&gi(e,t,s),delete a[t]}function Te(e,t){var n=e.ng339,r=n&&di[n];if(r){if(t)return void delete r.data[t];r.handle&&(r.events.$destroy&&r.handle({},"$destroy"),Pe(e)),delete di[n],e.ng339=void 0}}function De(e,t){var n=e.ng339,r=n&&di[n];return t&&!r&&(e.ng339=n=ye(),r=di[n]={events:{},data:{},handle:void 0}),r}function Fe(e,t,n){if(_e(e)){var r=$(n),i=!r&&t&&!b(t),o=!t,a=De(e,!i),s=a&&a.data;if(r)s[t]=n;else{if(o)return s;if(i)return s&&s[t];l(s,t)}}}function Ne(e,t){return!!e.getAttribute&&(" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ").indexOf(" "+t+" ")>-1}function Ie(e,t){t&&e.setAttribute&&r(t.split(" "),function(t){e.setAttribute("class",Zr((" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ").replace(" "+Zr(t)+" "," ")))})}function Re(e,t){if(t&&e.setAttribute){var n=(" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ");r(t.split(" "),function(e){e=Zr(e),n.indexOf(" "+e+" ")===-1&&(n+=e+" ")}),e.setAttribute("class",Zr(n))}}function Ue(e,t){if(t)if(t.nodeType)e[e.length++]=t;else{var n=t.length;if("number"==typeof n&&t.window!==t){if(n)for(var r=0;r<n;r++)e[e.length++]=t[r]}else e[e.length++]=t}}function Ve(e,t){return ze(e,"$"+(t||"ngController")+"Controller")}function ze(e,t,n){e.nodeType==li&&(e=e.documentElement);for(var r=Kr(t)?t:[t];e;){for(var i=0,o=r.length;i<o;i++)if($(n=Rr.data(e,r[i])))return n;e=e.parentNode||e.nodeType===ci&&e.host}}function Le(e){for(je(e,!0);e.firstChild;)e.removeChild(e.firstChild)}function qe(e,t){t||je(e);var n=e.parentNode;n&&n.removeChild(e)}function He(t,n){n=n||e,"complete"===n.document.readyState?n.setTimeout(t):Rr(n).on("load",t)}function Be(e,t){var n=Ci[t.toLowerCase()];return n&&Ai[I(e)]&&n}function We(e){return Oi[e]}function Ge(e,t){var n=function(n,r){n.isDefaultPrevented=function(){return n.defaultPrevented};var i=t[r||n.type],o=i?i.length:0;if(o){if(m(n.immediatePropagationStopped)){var a=n.stopImmediatePropagation;n.stopImmediatePropagation=function(){n.immediatePropagationStopped=!0,n.stopPropagation&&n.stopPropagation(),a&&a.call(n)}}n.isImmediatePropagationStopped=function(){return n.immediatePropagationStopped===!0};var s=i.specialHandlerWrapper||Xe;o>1&&(i=ve(i));for(var u=0;u<o;u++)n.isImmediatePropagationStopped()||s(e,n,i[u])}};return n.elem=e,n}function Xe(e,t,n){n.call(e,t)}function Ke(e,t,n){var r=t.relatedTarget;r&&(r===e||Si.call(e,r))||n.call(e,t)}function Ye(){this.$get=function(){return l(Oe,{hasClass:function(e,t){return e.attr&&(e=e[0]),Ne(e,t)},addClass:function(e,t){return e.attr&&(e=e[0]),Re(e,t)},removeClass:function(e,t){return e.attr&&(e=e[0]),Ie(e,t)}})}}function Ze(e,t){var n=e&&e.$$hashKey;if(n)return"function"==typeof n&&(n=e.$$hashKey()),n;var r=typeof e;return n="function"==r||"object"==r&&null!==e?e.$$hashKey=r+":"+(t||a)():r+":"+e}function Je(e,t){if(t){var n=0;this.nextUid=function(){return++n}}r(e,this.put,this)}function Qe(e){return Function.prototype.toString.call(e)+" "}function et(e){var t=Qe(e).replace(Fi,""),n=t.match(ji)||t.match(Pi);return n}function tt(e){var t=et(e);return t?"function("+(t[1]||"").replace(/[\s\r\n]+/," ")+")":"fn"}function nt(e,t,n){var i,o,a;if("function"==typeof e){if(!(i=e.$inject)){if(i=[],e.length){if(t)throw w(n)&&n||(n=e.name||tt(e)),Ni("strictdi","{0} is not using explicit annotation and cannot be invoked in strict mode",n);o=et(e),r(o[1].split(Ti),function(e){e.replace(Di,function(e,t,n){i.push(n)})})}e.$inject=i}}else Kr(e)?(a=e.length-1,ce(e[a],"fn"),i=e.slice(0,a)):ce(e,"fn",!0);return i}function rt(e,t){function n(e){return function(t,n){return b(t)?void r(t,o(e)):e(t,n)}}function i(e,t){if(fe(e,"service"),(k(t)||Kr(t))&&(t=_.instantiate(t)),!t.$get)throw Ni("pget","Provider '{0}' must define $get factory method.",e);return x[e+v]=t}function a(e,t){return function(){var n=C.invoke(t,this);if(m(n))throw Ni("undef","Provider '{0}' must return a value from $get factory method.",e);return n}}function s(e,t,n){return i(e,{$get:n!==!1?a(e,t):t})}function u(e,t){return s(e,["$injector",function(e){return e.instantiate(t)}])}function l(e,t){return s(e,g(t),!1)}function c(e,t){fe(e,"constant"),x[e]=t,S[e]=t}function f(e,t){var n=_.get(e+v),r=n.$get;n.$get=function(){var e=C.invoke(r,n);return C.invoke(t,null,{$delegate:e})}}function d(e){le(m(e)||Kr(e),"modulesToLoad","not an array");var t,n=[];return r(e,function(e){function r(e){var t,n;for(t=0,n=e.length;t<n;t++){var r=e[t],i=_.get(r[0]);i[r[1]].apply(i,r[2])}}if(!y.get(e)){y.put(e,!0);try{w(e)?(t=Vr(e),n=n.concat(d(t.requires)).concat(t._runBlocks),r(t._invokeQueue),r(t._configBlocks)):k(e)?n.push(_.invoke(e)):Kr(e)?n.push(_.invoke(e)):ce(e,"module")}catch(i){throw Kr(e)&&(e=e[e.length-1]),i.message&&i.stack&&i.stack.indexOf(i.message)==-1&&(i=i.message+"\n"+i.stack),Ni("modulerr","Failed to instantiate module {0} due to:\n{1}",e,i.stack||i.message||i)}}}),n}function p(e,n){function r(t,r){if(e.hasOwnProperty(t)){if(e[t]===h)throw Ni("cdep","Circular dependency found: {0}",t+" <- "+$.join(" <- "));return e[t]}try{return $.unshift(t),e[t]=h,e[t]=n(t,r)}catch(i){throw e[t]===h&&delete e[t],i}finally{$.shift()}}function i(e,n,i){for(var o=[],a=rt.$$annotate(e,t,i),s=0,u=a.length;s<u;s++){var l=a[s];if("string"!=typeof l)throw Ni("itkn","Incorrect injection token! Expected service name as string, got {0}",l);o.push(n&&n.hasOwnProperty(l)?n[l]:r(l,i))}return o}function o(e){return!(Ir<=11)&&("function"==typeof e&&/^(?:class\b|constructor\()/.test(Qe(e)))}function a(e,t,n,r){"string"==typeof n&&(r=n,n=null);var a=i(e,n,r);return Kr(e)&&(e=e[e.length-1]),o(e)?(a.unshift(null),new(Function.prototype.bind.apply(e,a))):e.apply(t,a)}function s(e,t,n){var r=Kr(e)?e[e.length-1]:e,o=i(e,t,n);return o.unshift(null),new(Function.prototype.bind.apply(r,o))}return{invoke:a,instantiate:s,get:r,annotate:rt.$$annotate,has:function(t){return x.hasOwnProperty(t+v)||e.hasOwnProperty(t)}}}t=t===!0;var h={},v="Provider",$=[],y=new Je([],(!0)),x={$provide:{provider:n(i),factory:n(s),service:n(u),value:n(l),constant:n(c),decorator:f}},_=x.$injector=p(x,function(e,t){throw Gr.isString(t)&&$.push(t),Ni("unpr","Unknown provider: {0}",$.join(" <- "))}),S={},E=p(S,function(e,t){var n=_.get(e+v,t);return C.invoke(n.$get,n,void 0,e)}),C=E;x["$injector"+v]={$get:g(E)};var A=d(e);return C=E.get("$injector"),C.strictDi=t,r(A,function(e){e&&C.invoke(e)}),C}function it(){var e=!0;this.disableAutoScrolling=function(){e=!1},this.$get=["$window","$location","$rootScope",function(t,n,r){function i(e){var t=null;return Array.prototype.some.call(e,function(e){if("a"===I(e))return t=e,!0}),t}function o(){var e=s.yOffset;if(k(e))e=e();else if(F(e)){var n=e[0],r=t.getComputedStyle(n);e="fixed"!==r.position?0:n.getBoundingClientRect().bottom}else x(e)||(e=0);return e}function a(e){if(e){e.scrollIntoView();var n=o();if(n){var r=e.getBoundingClientRect().top;t.scrollBy(0,r-n)}}else t.scrollTo(0,0)}function s(e){e=w(e)?e:n.hash();var t;e?(t=u.getElementById(e))?a(t):(t=i(u.getElementsByName(e)))?a(t):"top"===e&&a(null):a(null)}var u=t.document;return e&&r.$watch(function(){return n.hash()},function(e,t){e===t&&""===e||He(function(){r.$evalAsync(s)})}),s}]}function ot(e,t){return e||t?e?t?(Kr(e)&&(e=e.join(" ")),Kr(t)&&(t=t.join(" ")),e+" "+t):e:t:""}function at(e){for(var t=0;t<e.length;t++){var n=e[t];if(n.nodeType===Ri)return n}}function st(e){w(e)&&(e=e.split(" "));var t=he();return r(e,function(e){e.length&&(t[e]=!0)}),t}function ut(e){return b(e)?e:{}}function lt(e,t,n,i){function o(e){try{e.apply(null,L(arguments,1))}finally{if($--,0===$)for(;b.length;)try{b.pop()()}catch(t){n.error(t)}}}function a(e){var t=e.indexOf("#");return t===-1?"":e.substr(t)}function s(){k=null,u(),l()}function u(){y=S(),y=m(y)?null:y,V(y,A)&&(y=A),A=y}function l(){x===c.url()&&w===y||(x=c.url(),w=y,r(E,function(e){e(c.url(),y)}))}var c=this,f=e.location,d=e.history,h=e.setTimeout,g=e.clearTimeout,v={};c.isMock=!1;var $=0,b=[];c.$$completeOutstandingRequest=o,c.$$incOutstandingRequestCount=function(){$++},c.notifyWhenNoOutstandingRequests=function(e){0===$?e():b.push(e)};var y,w,x=f.href,_=t.find("base"),k=null,S=i.history?function(){try{return d.state}catch(e){}}:p;u(),w=y,c.url=function(t,n,r){if(m(r)&&(r=null),f!==e.location&&(f=e.location),d!==e.history&&(d=e.history),t){var o=w===r;if(x===t&&(!i.history||o))return c;var s=x&&qt(x)===qt(t);return x=t,w=r,!i.history||s&&o?(s||(k=t),n?f.replace(t):s?f.hash=a(t):f.href=t,f.href!==t&&(k=t)):(d[n?"replaceState":"pushState"](r,"",t),u(),w=y),k&&(k=t),c}return k||f.href.replace(/%27/g,"'")},c.state=function(){return y};var E=[],C=!1,A=null;c.onUrlChange=function(t){return C||(i.history&&Rr(e).on("popstate",s),Rr(e).on("hashchange",s),C=!0),E.push(t),t},c.$$applicationDestroyed=function(){Rr(e).off("hashchange popstate",s)},c.$$checkUrlChange=l,c.baseHref=function(){var e=_.attr("href");return e?e.replace(/^(https?\:)?\/\/[^\/]*/,""):""},c.defer=function(e,t){var n;return $++,n=h(function(){delete v[n],o(e)},t||0),v[n]=!0,n},c.defer.cancel=function(e){return!!v[e]&&(delete v[e],g(e),o(p),!0)}}function ct(){this.$get=["$window","$log","$sniffer","$document",function(e,t,n,r){return new lt(e,r,t,n)}]}function ft(){this.$get=function(){function e(e,r){function i(e){e!=d&&(p?p==e&&(p=e.n):p=e,o(e.n,e.p),o(e,d),d=e,d.n=null)}function o(e,t){e!=t&&(e&&(e.p=t),t&&(t.n=e))}if(e in n)throw t("$cacheFactory")("iid","CacheId '{0}' is already taken!",e);var a=0,s=l({},r,{id:e}),u=he(),c=r&&r.capacity||Number.MAX_VALUE,f=he(),d=null,p=null;return n[e]={put:function(e,t){if(!m(t)){if(c<Number.MAX_VALUE){var n=f[e]||(f[e]={key:e});i(n)}return e in u||a++,u[e]=t,a>c&&this.remove(p.key),t}},get:function(e){if(c<Number.MAX_VALUE){var t=f[e];if(!t)return;i(t)}return u[e]},remove:function(e){if(c<Number.MAX_VALUE){var t=f[e];if(!t)return;t==d&&(d=t.p),t==p&&(p=t.n),o(t.n,t.p),delete f[e]}e in u&&(delete u[e],a--)},removeAll:function(){u=he(),a=0,f=he(),d=p=null},destroy:function(){u=null,s=null,f=null,delete n[e]},info:function(){return l({},s,{size:a})}}}var n={};return e.info=function(){var e={};return r(n,function(t,n){e[n]=t.info()}),e},e.get=function(e){return n[e]},e}}function dt(){this.$get=["$cacheFactory",function(e){return e("templates")}]}function pt(){}function ht(t,n){function i(e,t,n){var i=/^\s*([@&<]|=(\*?))(\??)\s*(\w*)\s*$/,o=he();return r(e,function(e,r){if(e in E)return void(o[r]=E[e]);var a=e.match(i);if(!a)throw Wi("iscp","Invalid {3} for directive '{0}'. Definition: {... {1}: '{2}' ...}",t,r,e,n?"controller bindings definition":"isolate scope definition");o[r]={mode:a[1][0],collection:"*"===a[2],optional:"?"===a[3],attrName:a[4]||r},a[4]&&(E[e]=o[r])}),o}function a(e,t){var n={isolateScope:null,bindToController:null};if(b(e.scope)&&(e.bindToController===!0?(n.bindToController=i(e.scope,t,!0),n.isolateScope={}):n.isolateScope=i(e.scope,t,!1)),b(e.bindToController)&&(n.bindToController=i(e.bindToController,t,!0)),b(n.bindToController)){var r=e.controller,o=e.controllerAs;if(!r)throw Wi("noctrl","Cannot bind to controller without directive '{0}'s controller.",t);if(!bt(r,o))throw Wi("noident","Cannot bind to controller without identifier for directive '{0}'.",t)}return n}function s(e){var t=e.charAt(0);if(!t||t!==Tr(t))throw Wi("baddir","Directive/Component name '{0}' is invalid. The first character must be a lowercase letter",e);if(e!==e.trim())throw Wi("baddir","Directive/Component name '{0}' is invalid. The name should not contain leading or trailing whitespaces",e)}function u(e){var t=e.require||e.controller&&e.name;return!Kr(t)&&b(t)&&r(t,function(e,n){var r=e.match(_),i=e.substring(r[0].length);i||(t[n]=r[0]+n)}),t}var c={},f="Directive",v=/^\s*directive\:\s*([\w\-]+)\s+(.*)$/,y=/(([\w\-]+)(?:\:([^;]+))?;?)/,x=N("ngSrc,ngSrcset,src,srcset"),_=/^(?:(\^\^?)?(\?)?(\^\^?)?)?/,S=/^(on[a-z]+|formaction)$/,E=he();this.directive=function M(e,n){return fe(e,"directive"),w(e)?(s(e),le(n,"directiveFactory"),c.hasOwnProperty(e)||(c[e]=[],t.factory(e+f,["$injector","$exceptionHandler",function(t,n){var i=[];return r(c[e],function(r,o){try{var a=t.invoke(r);k(a)?a={compile:g(a)}:!a.compile&&a.link&&(a.compile=g(a.link)),a.priority=a.priority||0,a.index=o,a.name=a.name||e,a.require=u(a),a.restrict=a.restrict||"EA",a.$$moduleName=r.$$moduleName,i.push(a)}catch(s){n(s)}}),i}])),c[e].push(n)):r(e,o(M)),this},this.component=function(e,t){function n(e){function n(t){return k(t)||Kr(t)?function(n,r){return e.invoke(t,this,{$element:n,$attrs:r})}:t}var o=t.template||t.templateUrl?t.template:"",a={controller:i,controllerAs:bt(t.controller)||t.controllerAs||"$ctrl",template:n(o),templateUrl:n(t.templateUrl),transclude:t.transclude,scope:{},bindToController:t.bindings||{},restrict:"E",require:t.require};return r(t,function(e,t){"$"===t.charAt(0)&&(a[t]=e)}),a}var i=t.controller||function(){};return r(t,function(e,t){"$"===t.charAt(0)&&(n[t]=e,k(i)&&(i[t]=e))}),n.$inject=["$injector"],this.directive(e,n)},this.aHrefSanitizationWhitelist=function(e){return $(e)?(n.aHrefSanitizationWhitelist(e),this):n.aHrefSanitizationWhitelist()},this.imgSrcSanitizationWhitelist=function(e){return $(e)?(n.imgSrcSanitizationWhitelist(e),this):n.imgSrcSanitizationWhitelist()};var A=!0;this.debugInfoEnabled=function(e){return $(e)?(A=e,this):A};var O=10;this.onChangesTtl=function(e){return arguments.length?(O=e,this):O},this.$get=["$injector","$interpolate","$exceptionHandler","$templateRequest","$parse","$controller","$rootScope","$sce","$animate","$$sanitizeUri",function(t,n,i,o,s,u,g,E,M,P){function T(){try{if(!--_e)throw be=void 0,Wi("infchng","{0} $onChanges() iterations reached. Aborting!\n",O);g.$apply(function(){for(var e=[],t=0,n=be.length;t<n;++t)try{be[t]()}catch(r){e.push(r)}if(be=void 0,e.length)throw e})}finally{_e++}}function D(e,t){if(t){var n,r,i,o=Object.keys(t);for(n=0,r=o.length;n<r;n++)i=o[n],this[i]=t[i]}else this.$attr={};this.$$element=e}function F(e,t,n){we.innerHTML="<span "+t+">";var r=we.firstChild.attributes,i=r[0];r.removeNamedItem(i.name),i.value=n,e.attributes.setNamedItem(i)}function N(e,t){try{e.addClass(t)}catch(n){}}function U(t,n,r,i,o){t instanceof Rr||(t=Rr(t));for(var a=/\S+/,s=0,u=t.length;s<u;s++){var l=t[s];l.nodeType===si&&l.nodeValue.match(a)&&Ae(l,t[s]=e.document.createElement("span"))}var c=H(t,n,t,r,i,o);U.$$addScopeClass(t);var f=null;return function(e,n,r){le(e,"scope"),o&&o.needsNewScope&&(e=e.$parent.$new()),r=r||{};var i=r.parentBoundTranscludeFn,a=r.transcludeControllers,s=r.futureParentElement;i&&i.$$boundTransclude&&(i=i.$$boundTransclude),f||(f=z(s));var u;if(u="html"!==f?Rr(fe(f,Rr("<div>").append(t).html())):n?Ei.clone.call(t):t,a)for(var l in a)u.data("$"+l+"Controller",a[l].instance);return U.$$addScopeInfo(u,e),n&&n(u,e),c&&c(e,u,u,i),u}}function z(e){var t=e&&e[0];return t&&"foreignobject"!==I(t)&&Hr.call(t).match(/SVG/)?"svg":"html"}function H(e,t,n,r,i,o){function a(e,n,r,i){var o,a,s,u,l,c,f,d,g;if(p){var v=n.length;for(g=new Array(v),l=0;l<h.length;l+=3)f=h[l],g[f]=n[f]}else g=n;for(l=0,c=h.length;l<c;)s=g[h[l++]],o=h[l++],a=h[l++],o?(o.scope?(u=e.$new(),U.$$addScopeInfo(Rr(s),u)):u=e,d=o.transcludeOnThisElement?B(e,o.transclude,i):!o.templateOnThisElement&&i?i:!i&&t?B(e,t):null,o(a,u,s,r,d)):a&&a(e,s.childNodes,void 0,i)}for(var s,u,l,c,f,d,p,h=[],g=0;g<e.length;g++)s=new D,u=W(e[g],[],s,0===g?r:void 0,i),l=u.length?J(u,e[g],s,t,n,null,[],[],o):null,l&&l.scope&&U.$$addScopeClass(s.$$element),f=l&&l.terminal||!(c=e[g].childNodes)||!c.length?null:H(c,l?(l.transcludeOnThisElement||!l.templateOnThisElement)&&l.transclude:t),(l||f)&&(h.push(g,l,f),d=!0,p=p||l),o=null;return d?a:null}function B(e,t,n){function r(r,i,o,a,s){return r||(r=e.$new(!1,s),r.$$transcluded=!0),t(r,i,{parentBoundTranscludeFn:n,transcludeControllers:o,futureParentElement:a})}var i=r.$$slots=he();for(var o in t.$$slots)t.$$slots[o]?i[o]=B(e,t.$$slots[o],n):i[o]=null;return r}function W(e,t,n,r,i){var o,a,s=e.nodeType,u=n.$attr;switch(s){case oi:ne(t,vt(I(e)),"E",r,i);for(var l,c,f,d,p,h,g=e.attributes,v=0,m=g&&g.length;v<m;v++){var $=!1,x=!1;l=g[v],c=l.name,p=Zr(l.value),d=vt(c),(h=Ce.test(d))&&(c=c.replace(Xi,"").substr(8).replace(/_(.)/g,function(e,t){return t.toUpperCase()}));var _=d.match(Oe);_&&re(_[1])&&($=c,x=c.substr(0,c.length-5)+"end",c=c.substr(0,c.length-6)),f=vt(c.toLowerCase()),u[f]=c,!h&&n.hasOwnProperty(f)||(n[f]=p,Be(e,f)&&(n[f]=!0)),pe(e,t,p,f,h),ne(t,f,"A",r,i,$,x)}if(a=e.className,b(a)&&(a=a.animVal),w(a)&&""!==a)for(;o=y.exec(a);)f=vt(o[2]),ne(t,f,"C",r,i)&&(n[f]=Zr(o[3])),a=a.substr(o.index+o[0].length);break;case si:if(11===Ir)for(;e.parentNode&&e.nextSibling&&e.nextSibling.nodeType===si;)e.nodeValue=e.nodeValue+e.nextSibling.nodeValue,e.parentNode.removeChild(e.nextSibling);ce(t,e.nodeValue);break;case ui:G(e,t,n,r,i)}return t.sort(ae),t}function G(e,t,n,r,i){try{var o=v.exec(e.nodeValue);if(o){var a=vt(o[1]);ne(t,a,"M",r,i)&&(n[a]=Zr(o[2]))}}catch(s){}}function X(e,t,n){var r=[],i=0;if(t&&e.hasAttribute&&e.hasAttribute(t)){do{if(!e)throw Wi("uterdir","Unterminated attribute, found '{0}' but no matching '{1}' found.",t,n);e.nodeType==oi&&(e.hasAttribute(t)&&i++,e.hasAttribute(n)&&i--),r.push(e),e=e.nextSibling}while(i>0)}else r.push(e);return Rr(r)}function K(e,t,n){return function(r,i,o,a,s){return i=X(i[0],t,n),e(r,i,o,a,s)}}function Z(e,t,n,r,i,o){var a;return e?U(t,n,r,i,o):function(){return a||(a=U(t,n,r,i,o),t=n=o=null),a.apply(this,arguments)}}function J(e,t,n,o,a,s,u,c,f){function d(e,t,n,r){e&&(n&&(e=K(e,n,r)),e.require=h.require,e.directiveName=g,(S===h||h.$$isolateScope)&&(e=ve(e,{isolateScope:!0})),u.push(e)),t&&(n&&(t=K(t,n,r)),t.require=h.require,t.directiveName=g,(S===h||h.$$isolateScope)&&(t=ve(t,{isolateScope:!0})),c.push(t))}function p(e,o,a,s,f){function d(e,t,n,r){var i;if(C(e)||(r=n,n=t,t=e,e=void 0),j&&(i=y),n||(n=j?A.parent():A),!r)return f(e,t,i,n,R);var o=f.$$slots[r];if(o)return o(e,t,i,n,R);if(m(o))throw Wi("noslot",'No parent directive that requires a transclusion with slot name "{0}". Element: {1}',r,Y(A))}var p,h,g,v,$,y,w,A,O,M;t===a?(O=n,A=n.$$element):(A=Rr(a),O=new D(A,n)),$=o,S?v=o.$new(!0):x&&($=o.$parent),f&&(w=d,w.$$boundTransclude=f,w.isSlotFilled=function(e){return!!f.$$slots[e]}),_&&(y=ee(A,O,w,_,v,o,S)),S&&(U.$$addScopeInfo(A,v,!0,!(E&&(E===S||E===S.$$originalDirective))),U.$$addScopeClass(A,!0),v.$$isolateBindings=S.$$isolateBindings,M=$e(o,O,v,v.$$isolateBindings,S),M.removeWatches&&v.$on("$destroy",M.removeWatches));for(var P in y){var T=_[P],F=y[P],N=T.$$bindings.bindToController;F.identifier&&N?F.bindingInfo=$e($,O,F.instance,N,T):F.bindingInfo={};var I=F();I!==F.instance&&(F.instance=I,A.data("$"+T.name+"Controller",I),F.bindingInfo.removeWatches&&F.bindingInfo.removeWatches(),F.bindingInfo=$e($,O,F.instance,N,T))}for(r(_,function(e,t){var n=e.require;e.bindToController&&!Kr(n)&&b(n)&&l(y[t].instance,Q(t,n,A,y))}),r(y,function(e){var t=e.instance;if(k(t.$onChanges))try{t.$onChanges(e.bindingInfo.initialChanges)}catch(n){i(n)}if(k(t.$onInit))try{t.$onInit()}catch(n){i(n)}k(t.$doCheck)&&($.$watch(function(){t.$doCheck()}),t.$doCheck()),k(t.$onDestroy)&&$.$on("$destroy",function(){t.$onDestroy()})}),p=0,h=u.length;p<h;p++)g=u[p],me(g,g.isolateScope?v:o,A,O,g.require&&Q(g.directiveName,g.require,A,y),w);var R=o;for(S&&(S.template||null===S.templateUrl)&&(R=v),e&&e(R,a.childNodes,void 0,f),p=c.length-1;p>=0;p--)g=c[p],me(g,g.isolateScope?v:o,A,O,g.require&&Q(g.directiveName,g.require,A,y),w);r(y,function(e){var t=e.instance;k(t.$postLink)&&t.$postLink()})}f=f||{};for(var h,g,v,$,y,w=-Number.MAX_VALUE,x=f.newScopeDirective,_=f.controllerDirectives,S=f.newIsolateScopeDirective,E=f.templateDirective,A=f.nonTlbTranscludeDirective,O=!1,M=!1,j=f.hasElementTranscludeDirective,P=n.$$element=Rr(t),T=s,F=o,N=!1,R=!1,V=0,z=e.length;V<z;V++){h=e[V];var H=h.$$start,B=h.$$end;if(H&&(P=X(t,H,B)),v=void 0,w>h.priority)break;if((y=h.scope)&&(h.templateUrl||(b(y)?(ue("new/isolated scope",S||x,h,P),S=h):ue("new/isolated scope",S,h,P)),x=x||h),g=h.name,!N&&(h.replace&&(h.templateUrl||h.template)||h.transclude&&!h.$$tlb)){for(var G,J=V+1;G=e[J++];)if(G.transclude&&!G.$$tlb||G.replace&&(G.templateUrl||G.template)){R=!0;break}N=!0}if(!h.templateUrl&&h.controller&&(y=h.controller,_=_||he(),ue("'"+g+"' controller",_[g],h,P),_[g]=h),y=h.transclude)if(O=!0,h.$$tlb||(ue("transclusion",A,h,P),A=h),"element"==y)j=!0,w=h.priority,v=P,P=n.$$element=Rr(U.$$createComment(g,n[g])),t=P[0],ge(a,L(v),t),v[0].$$parentNode=v[0].parentNode,F=Z(R,v,o,w,T&&T.name,{nonTlbTranscludeDirective:A});else{var ne=he();if(v=Rr(Me(t)).contents(),b(y)){v=[];var re=he(),ae=he();r(y,function(e,t){var n="?"===e.charAt(0);e=n?e.substring(1):e,re[e]=t,ne[t]=null,ae[t]=n}),r(P.contents(),function(e){var t=re[vt(I(e))];t?(ae[t]=!0,ne[t]=ne[t]||[],ne[t].push(e)):v.push(e)}),r(ae,function(e,t){if(!e)throw Wi("reqslot","Required transclusion slot `{0}` was not filled.",t)});for(var se in ne)ne[se]&&(ne[se]=Z(R,ne[se],o))}P.empty(),F=Z(R,v,o,void 0,void 0,{needsNewScope:h.$$isolateScope||h.$$newScope}),F.$$slots=ne}if(h.template)if(M=!0,ue("template",E,h,P),E=h,y=k(h.template)?h.template(P,n):h.template,y=Ee(y),h.replace){if(T=h,v=xe(y)?[]:$t(fe(h.templateNamespace,Zr(y))),t=v[0],1!=v.length||t.nodeType!==oi)throw Wi("tplrt","Template for directive '{0}' must have exactly one root element. {1}",g,"");ge(a,P,t);var le={$attr:{}},ce=W(t,[],le),de=e.splice(V+1,e.length-(V+1));(S||x)&&te(ce,S,x),e=e.concat(ce).concat(de),ie(n,le),z=e.length}else P.html(y);if(h.templateUrl)M=!0,ue("template",E,h,P),E=h,h.replace&&(T=h),p=oe(e.splice(V,e.length-V),P,n,a,O&&F,u,c,{controllerDirectives:_,newScopeDirective:x!==h&&x,newIsolateScopeDirective:S,templateDirective:E,nonTlbTranscludeDirective:A}),z=e.length;else if(h.compile)try{$=h.compile(P,n,F);var pe=h.$$originalDirective||h;
|
4 |
-
k($)?d(null,q(pe,$),H,B):$&&d(q(pe,$.pre),q(pe,$.post),H,B)}catch(be){i(be,Y(P))}h.terminal&&(p.terminal=!0,w=Math.max(w,h.priority))}return p.scope=x&&x.scope===!0,p.transcludeOnThisElement=O,p.templateOnThisElement=M,p.transclude=F,f.hasElementTranscludeDirective=j,p}function Q(e,t,n,i){var o;if(w(t)){var a=t.match(_),s=t.substring(a[0].length),u=a[1]||a[3],l="?"===a[2];if("^^"===u?n=n.parent():(o=i&&i[s],o=o&&o.instance),!o){var c="$"+s+"Controller";o=u?n.inheritedData(c):n.data(c)}if(!o&&!l)throw Wi("ctreq","Controller '{0}', required by directive '{1}', can't be found!",s,e)}else if(Kr(t)){o=[];for(var f=0,d=t.length;f<d;f++)o[f]=Q(e,t[f],n,i)}else b(t)&&(o={},r(t,function(t,r){o[r]=Q(e,t,n,i)}));return o||null}function ee(e,t,n,r,i,o,a){var s=he();for(var l in r){var c=r[l],f={$scope:c===a||c.$$isolateScope?i:o,$element:e,$attrs:t,$transclude:n},d=c.controller;"@"==d&&(d=t[c.name]);var p=u(d,f,!0,c.controllerAs);s[c.name]=p,e.data("$"+c.name+"Controller",p.instance)}return s}function te(e,t,n){for(var r=0,i=e.length;r<i;r++)e[r]=d(e[r],{$$isolateScope:t,$$newScope:n})}function ne(e,n,r,o,s,u,l){if(n===s)return null;var p=null;if(c.hasOwnProperty(n))for(var h,g=t.get(n+f),v=0,$=g.length;v<$;v++)try{if(h=g[v],(m(o)||o>h.priority)&&h.restrict.indexOf(r)!=-1){if(u&&(h=d(h,{$$start:u,$$end:l})),!h.$$bindings){var y=h.$$bindings=a(h,h.name);b(y.isolateScope)&&(h.$$isolateBindings=y.isolateScope)}e.push(h),p=h}}catch(w){i(w)}return p}function re(e){if(c.hasOwnProperty(e))for(var n,r=t.get(e+f),i=0,o=r.length;i<o;i++)if(n=r[i],n.multiElement)return!0;return!1}function ie(e,t){var n=t.$attr,i=e.$attr;e.$$element;r(e,function(r,i){"$"!=i.charAt(0)&&(t[i]&&t[i]!==r&&(r+=("style"===i?";":" ")+t[i]),e.$set(i,r,!0,n[i]))}),r(t,function(t,r){e.hasOwnProperty(r)||"$"===r.charAt(0)||(e[r]=t,"class"!==r&&"style"!==r&&(i[r]=n[r]))})}function oe(e,t,n,i,a,s,u,l){var c,f,p=[],h=t[0],g=e.shift(),v=d(g,{templateUrl:null,transclude:null,replace:null,$$originalDirective:g}),m=k(g.templateUrl)?g.templateUrl(t,n):g.templateUrl,$=g.templateNamespace;return t.empty(),o(m).then(function(o){var d,y,w,x;if(o=Ee(o),g.replace){if(w=xe(o)?[]:$t(fe($,Zr(o))),d=w[0],1!=w.length||d.nodeType!==oi)throw Wi("tplrt","Template for directive '{0}' must have exactly one root element. {1}",g.name,m);y={$attr:{}},ge(i,t,d);var _=W(d,[],y);b(g.scope)&&te(_,!0),e=_.concat(e),ie(n,y)}else d=h,t.html(o);for(e.unshift(v),c=J(e,d,n,a,t,g,s,u,l),r(i,function(e,n){e==d&&(i[n]=t[0])}),f=H(t[0].childNodes,a);p.length;){var k=p.shift(),S=p.shift(),E=p.shift(),C=p.shift(),A=t[0];if(!k.$$destroyed){if(S!==h){var O=S.className;l.hasElementTranscludeDirective&&g.replace||(A=Me(d)),ge(E,Rr(S),A),N(Rr(A),O)}x=c.transcludeOnThisElement?B(k,c.transclude,C):C,c(f,k,A,i,x)}}p=null}),function(e,t,n,r,i){var o=i;t.$$destroyed||(p?p.push(t,n,r,o):(c.transcludeOnThisElement&&(o=B(t,c.transclude,i)),c(f,t,n,r,o)))}}function ae(e,t){var n=t.priority-e.priority;return 0!==n?n:e.name!==t.name?e.name<t.name?-1:1:e.index-t.index}function ue(e,t,n,r){function i(e){return e?" (module: "+e+")":""}if(t)throw Wi("multidir","Multiple directives [{0}{1}, {2}{3}] asking for {4} on: {5}",t.name,i(t.$$moduleName),n.name,i(n.$$moduleName),e,Y(r))}function ce(e,t){var r=n(t,!0);r&&e.push({priority:0,compile:function(e){var t=e.parent(),n=!!t.length;return n&&U.$$addBindingClass(t),function(e,t){var i=t.parent();n||U.$$addBindingClass(i),U.$$addBindingInfo(i,r.expressions),e.$watch(r,function(e){t[0].nodeValue=e})}}})}function fe(t,n){switch(t=Tr(t||"html")){case"svg":case"math":var r=e.document.createElement("div");return r.innerHTML="<"+t+">"+n+"</"+t+">",r.childNodes[0].childNodes;default:return n}}function de(e,t){if("srcdoc"==t)return E.HTML;var n=I(e);return"xlinkHref"==t||"form"==n&&"action"==t||"img"!=n&&("src"==t||"ngSrc"==t)?E.RESOURCE_URL:void 0}function pe(e,t,r,i,o){var a=de(e,i);o=x[i]||o;var s=n(r,!0,a,o);if(s){if("multiple"===i&&"select"===I(e))throw Wi("selmulti","Binding to the 'multiple' attribute is not supported. Element: {0}",Y(e));t.push({priority:100,compile:function(){return{pre:function(e,t,u){var l=u.$$observers||(u.$$observers=he());if(S.test(i))throw Wi("nodomevents","Interpolations for HTML DOM event attributes are disallowed. Please use the ng- versions (such as ng-click instead of onclick) instead.");var c=u[i];c!==r&&(s=c&&n(c,!0,a,o),r=c),s&&(u[i]=s(e),(l[i]||(l[i]=[])).$$inter=!0,(u.$$observers&&u.$$observers[i].$$scope||e).$watch(s,function(e,t){"class"===i&&e!=t?u.$updateClass(e,t):u.$set(i,e)}))}}}})}}function ge(t,n,r){var i,o,a=n[0],s=n.length,u=a.parentNode;if(t)for(i=0,o=t.length;i<o;i++)if(t[i]==a){t[i++]=r;for(var l=i,c=l+s-1,f=t.length;l<f;l++,c++)c<f?t[l]=t[c]:delete t[l];t.length-=s-1,t.context===a&&(t.context=r);break}u&&u.replaceChild(r,a);var d=e.document.createDocumentFragment();for(i=0;i<s;i++)d.appendChild(n[i]);for(Rr.hasData(a)&&(Rr.data(r,Rr.data(a)),Rr(a).off("$destroy")),Rr.cleanData(d.querySelectorAll("*")),i=1;i<s;i++)delete n[i];n[0]=r,n.length=1}function ve(e,t){return l(function(){return e.apply(null,arguments)},e,t)}function me(e,t,n,r,o,a){try{e(t,n,r,o,a)}catch(s){i(s,Y(n))}}function $e(e,t,i,o,a){function u(t,n,r){k(i.$onChanges)&&n!==r&&(be||(e.$$postDigest(T),be=[]),c||(c={},be.push(l)),c[t]&&(r=c[t].previousValue),c[t]=new gt(r,n))}function l(){i.$onChanges(c),c=void 0}var c,f=[],d={};return r(o,function(r,o){var l,c,h,g,v,m=r.attrName,$=r.optional,b=r.mode;switch(b){case"@":$||Pr.call(t,m)||(i[o]=t[m]=void 0),t.$observe(m,function(e){if(w(e)||j(e)){var t=i[o];u(o,e,t),i[o]=e}}),t.$$observers[m].$$scope=e,l=t[m],w(l)?i[o]=n(l)(e):j(l)&&(i[o]=l),d[o]=new gt(Gi,i[o]);break;case"=":if(!Pr.call(t,m)){if($)break;t[m]=void 0}if($&&!t[m])break;c=s(t[m]),g=c.literal?V:function(e,t){return e===t||e!==e&&t!==t},h=c.assign||function(){throw l=i[o]=c(e),Wi("nonassign","Expression '{0}' in attribute '{1}' used with directive '{2}' is non-assignable!",t[m],m,a.name)},l=i[o]=c(e);var y=function(t){return g(t,i[o])||(g(t,l)?h(e,t=i[o]):i[o]=t),l=t};y.$stateful=!0,v=r.collection?e.$watchCollection(t[m],y):e.$watch(s(t[m],y),null,c.literal),f.push(v);break;case"<":if(!Pr.call(t,m)){if($)break;t[m]=void 0}if($&&!t[m])break;c=s(t[m]);var x=i[o]=c(e);d[o]=new gt(Gi,i[o]),v=e.$watch(c,function(e,t){if(t===e){if(t===x)return;t=x}u(o,e,t),i[o]=e},c.literal),f.push(v);break;case"&":if(c=t.hasOwnProperty(m)?s(t[m]):p,c===p&&$)break;i[o]=function(t){return c(e,t)}}}),{initialChanges:d,removeWatches:f.length&&function(){for(var e=0,t=f.length;e<t;++e)f[e]()}}}var be,ye=/^\w/,we=e.document.createElement("div"),_e=O;D.prototype={$normalize:vt,$addClass:function(e){e&&e.length>0&&M.addClass(this.$$element,e)},$removeClass:function(e){e&&e.length>0&&M.removeClass(this.$$element,e)},$updateClass:function(e,t){var n=mt(e,t);n&&n.length&&M.addClass(this.$$element,n);var r=mt(t,e);r&&r.length&&M.removeClass(this.$$element,r)},$set:function(e,t,n,o){var a,s=this.$$element[0],u=Be(s,e),l=We(e),c=e;if(u?(this.$$element.prop(e,t),o=u):l&&(this[l]=t,c=l),this[e]=t,o?this.$attr[e]=o:(o=this.$attr[e],o||(this.$attr[e]=o=se(e,"-"))),a=I(this.$$element),"a"===a&&("href"===e||"xlinkHref"===e)||"img"===a&&"src"===e)this[e]=t=P(t,"src"===e);else if("img"===a&&"srcset"===e&&$(t)){for(var f="",d=Zr(t),p=/(\s+\d+x\s*,|\s+\d+w\s*,|\s+,|,\s+)/,h=/\s/.test(d)?p:/(,)/,g=d.split(h),v=Math.floor(g.length/2),b=0;b<v;b++){var y=2*b;f+=P(Zr(g[y]),!0),f+=" "+Zr(g[y+1])}var w=Zr(g[2*b]).split(/\s/);f+=P(Zr(w[0]),!0),2===w.length&&(f+=" "+Zr(w[1])),this[e]=t=f}n!==!1&&(null===t||m(t)?this.$$element.removeAttr(o):ye.test(o)?this.$$element.attr(o,t):F(this.$$element[0],o,t));var x=this.$$observers;x&&r(x[c],function(e){try{e(t)}catch(n){i(n)}})},$observe:function(e,t){var n=this,r=n.$$observers||(n.$$observers=he()),i=r[e]||(r[e]=[]);return i.push(t),g.$evalAsync(function(){i.$$inter||!n.hasOwnProperty(e)||m(n[e])||t(n[e])}),function(){R(i,t)}}};var ke=n.startSymbol(),Se=n.endSymbol(),Ee="{{"==ke&&"}}"==Se?h:function(e){return e.replace(/\{\{/g,ke).replace(/}}/g,Se)},Ce=/^ngAttr[A-Z]/,Oe=/^(.+)Start$/;return U.$$addBindingInfo=A?function(e,t){var n=e.data("$binding")||[];Kr(t)?n=n.concat(t):n.push(t),e.data("$binding",n)}:p,U.$$addBindingClass=A?function(e){N(e,"ng-binding")}:p,U.$$addScopeInfo=A?function(e,t,n,r){var i=n?r?"$isolateScopeNoTemplate":"$isolateScope":"$scope";e.data(i,t)}:p,U.$$addScopeClass=A?function(e,t){N(e,t?"ng-isolate-scope":"ng-scope")}:p,U.$$createComment=function(t,n){var r="";return A&&(r=" "+(t||"")+": ",n&&(r+=n+" ")),e.document.createComment(r)},U}]}function gt(e,t){this.previousValue=e,this.currentValue=t}function vt(e){return we(e.replace(Xi,""))}function mt(e,t){var n="",r=e.split(/\s+/),i=t.split(/\s+/);e:for(var o=0;o<r.length;o++){for(var a=r[o],s=0;s<i.length;s++)if(a==i[s])continue e;n+=(n.length>0?" ":"")+a}return n}function $t(e){e=Rr(e);var t=e.length;if(t<=1)return e;for(;t--;){var n=e[t];n.nodeType===ui&&Lr.call(e,t,1)}return e}function bt(e,t){if(t&&w(t))return t;if(w(e)){var n=Yi.exec(e);if(n)return n[3]}}function yt(){var e={},n=!1;this.has=function(t){return e.hasOwnProperty(t)},this.register=function(t,n){fe(t,"controller"),b(t)?l(e,t):e[t]=n},this.allowGlobals=function(){n=!0},this.$get=["$injector","$window",function(r,i){function o(e,n,r,i){if(!e||!b(e.$scope))throw t("$controller")("noscp","Cannot export controller '{0}' as '{1}'! No $scope object provided via `locals`.",i,n);e.$scope[n]=r}return function(t,a,s,u){var c,f,d,p;if(s=s===!0,u&&w(u)&&(p=u),w(t)){if(f=t.match(Yi),!f)throw Ki("ctrlfmt","Badly formed controller string '{0}'. Must match `__name__ as __id__` or `__name__`.",t);d=f[1],p=p||f[3],t=e.hasOwnProperty(d)?e[d]:de(a.$scope,d,!0)||(n?de(i,d,!0):void 0),ce(t,d,!0)}if(s){var h=(Kr(t)?t[t.length-1]:t).prototype;c=Object.create(h||null),p&&o(a,p,c,d||t.name);var g;return g=l(function(){var e=r.invoke(t,c,a,d);return e!==c&&(b(e)||k(e))&&(c=e,p&&o(a,p,c,d||t.name)),c},{instance:c,identifier:p})}return c=r.instantiate(t,a,d),p&&o(a,p,c,d||t.name),c}}]}function wt(){this.$get=["$window",function(e){return Rr(e.document)}]}function xt(){this.$get=["$log",function(e){return function(t,n){e.error.apply(e,arguments)}}]}function _t(e){return b(e)?_(e)?e.toISOString():B(e):e}function kt(){this.$get=function(){return function(e){if(!e)return"";var t=[];return i(e,function(e,n){null===e||m(e)||(Kr(e)?r(e,function(e){t.push(te(n)+"="+te(_t(e)))}):t.push(te(n)+"="+te(_t(e))))}),t.join("&")}}}function St(){this.$get=function(){return function(e){function t(e,o,a){null===e||m(e)||(Kr(e)?r(e,function(e,n){t(e,o+"["+(b(e)?n:"")+"]")}):b(e)&&!_(e)?i(e,function(e,n){t(e,o+(a?"":"[")+n+(a?"":"]"))}):n.push(te(o)+"="+te(_t(e))))}if(!e)return"";var n=[];return t(e,"",!0),n.join("&")}}}function Et(e,t){if(w(e)){var n=e.replace(no,"").trim();if(n){var r=t("Content-Type");(r&&0===r.indexOf(Ji)||Ct(n))&&(e=W(n))}}return e}function Ct(e){var t=e.match(eo);return t&&to[t[0]].test(e)}function At(e){function t(e,t){e&&(i[e]=i[e]?i[e]+", "+t:t)}var n,i=he();return w(e)?r(e.split("\n"),function(e){n=e.indexOf(":"),t(Tr(Zr(e.substr(0,n))),Zr(e.substr(n+1)))}):b(e)&&r(e,function(e,n){t(Tr(n),Zr(e))}),i}function Ot(e){var t;return function(n){if(t||(t=At(e)),n){var r=t[Tr(n)];return void 0===r&&(r=null),r}return t}}function Mt(e,t,n,i){return k(i)?i(e,t,n):(r(i,function(r){e=r(e,t,n)}),e)}function jt(e){return 200<=e&&e<300}function Pt(){var e=this.defaults={transformResponse:[Et],transformRequest:[function(e){return!b(e)||A(e)||M(e)||O(e)?e:B(e)}],headers:{common:{Accept:"application/json, text/plain, */*"},post:ve(Qi),put:ve(Qi),patch:ve(Qi)},xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",paramSerializer:"$httpParamSerializer"},n=!1;this.useApplyAsync=function(e){return $(e)?(n=!!e,this):n};var i=!0;this.useLegacyPromiseExtensions=function(e){return $(e)?(i=!!e,this):i};var o=this.interceptors=[];this.$get=["$httpBackend","$$cookieReader","$cacheFactory","$rootScope","$q","$injector",function(a,s,u,c,f,d){function p(n){function o(e,t){for(var n=0,r=t.length;n<r;){var i=t[n++],o=t[n++];e=e.then(i,o)}return t.length=0,e}function a(e,t){var n,i={};return r(e,function(e,r){k(e)?(n=e(t),null!=n&&(i[r]=n)):i[r]=e}),i}function s(t){var n,r,i,o=e.headers,s=l({},t.headers);o=l({},o.common,o[Tr(t.method)]);e:for(n in o){r=Tr(n);for(i in s)if(Tr(i)===r)continue e;s[n]=o[n]}return a(s,ve(t))}function u(t){var n=t.headers,i=Mt(t.data,Ot(n),void 0,t.transformRequest);return m(i)&&r(n,function(e,t){"content-type"===Tr(t)&&delete n[t]}),m(t.withCredentials)&&!m(e.withCredentials)&&(t.withCredentials=e.withCredentials),v(t,i).then(c,c)}function c(e){var t=l({},e);return t.data=Mt(e.data,e.headers,e.status,p.transformResponse),jt(e.status)?t:f.reject(t)}if(!b(n))throw t("$http")("badreq","Http request configuration must be an object. Received: {0}",n);if(!w(n.url))throw t("$http")("badreq","Http request configuration url must be a string. Received: {0}",n.url);var p=l({method:"get",transformRequest:e.transformRequest,transformResponse:e.transformResponse,paramSerializer:e.paramSerializer},n);p.headers=s(n),p.method=Dr(p.method),p.paramSerializer=w(p.paramSerializer)?d.get(p.paramSerializer):p.paramSerializer;var h=[],g=[],$=f.when(p);return r(_,function(e){(e.request||e.requestError)&&h.unshift(e.request,e.requestError),(e.response||e.responseError)&&g.push(e.response,e.responseError)}),$=o($,h),$=$.then(u),$=o($,g),i?($.success=function(e){return ce(e,"fn"),$.then(function(t){e(t.data,t.status,t.headers,p)}),$},$.error=function(e){return ce(e,"fn"),$.then(null,function(t){e(t.data,t.status,t.headers,p)}),$}):($.success=io("success"),$.error=io("error")),$}function h(e){r(arguments,function(e){p[e]=function(t,n){return p(l({},n||{},{method:e,url:t}))}})}function g(e){r(arguments,function(e){p[e]=function(t,n,r){return p(l({},r||{},{method:e,url:t,data:n}))}})}function v(t,i){function o(e){if(e){var t={};return r(e,function(e,r){t[r]=function(t){function r(){e(t)}n?c.$applyAsync(r):c.$$phase?r():c.$apply(r)}}),t}}function u(e,t,r,i){function o(){l(t,e,r,i)}g&&(jt(e)?g.put(S,[e,t,At(r),i]):g.remove(S)),n?c.$applyAsync(o):(o(),c.$$phase||c.$apply())}function l(e,n,r,i){n=n>=-1?n:0,(jt(n)?w.resolve:w.reject)({data:e,status:n,headers:Ot(r),config:t,statusText:i})}function d(e){l(e.data,e.status,ve(e.headers()),e.statusText)}function h(){var e=p.pendingRequests.indexOf(t);e!==-1&&p.pendingRequests.splice(e,1)}var g,v,w=f.defer(),_=w.promise,k=t.headers,S=y(t.url,t.paramSerializer(t.params));if(p.pendingRequests.push(t),_.then(h,h),!t.cache&&!e.cache||t.cache===!1||"GET"!==t.method&&"JSONP"!==t.method||(g=b(t.cache)?t.cache:b(e.cache)?e.cache:x),g&&(v=g.get(S),$(v)?P(v)?v.then(d,d):Kr(v)?l(v[1],v[0],ve(v[2]),v[3]):l(v,200,{},"OK"):g.put(S,_)),m(v)){var E=Fn(t.url)?s()[t.xsrfCookieName||e.xsrfCookieName]:void 0;E&&(k[t.xsrfHeaderName||e.xsrfHeaderName]=E),a(t.method,S,i,u,k,t.timeout,t.withCredentials,t.responseType,o(t.eventHandlers),o(t.uploadEventHandlers))}return _}function y(e,t){return t.length>0&&(e+=(e.indexOf("?")==-1?"?":"&")+t),e}var x=u("$http");e.paramSerializer=w(e.paramSerializer)?d.get(e.paramSerializer):e.paramSerializer;var _=[];return r(o,function(e){_.unshift(w(e)?d.get(e):d.invoke(e))}),p.pendingRequests=[],h("get","delete","head","jsonp"),g("post","put","patch"),p.defaults=e,p}]}function Tt(){this.$get=function(){return function(){return new e.XMLHttpRequest}}}function Dt(){this.$get=["$browser","$jsonpCallbacks","$document","$xhrFactory",function(e,t,n,r){return Ft(e,r,e.defer,t,n[0])}]}function Ft(e,t,n,i,o){function a(e,t,n){e=e.replace("JSON_CALLBACK",t);var r=o.createElement("script"),a=null;return r.type="text/javascript",r.src=e,r.async=!0,a=function(e){gi(r,"load",a),gi(r,"error",a),o.body.removeChild(r),r=null;var s=-1,u="unknown";e&&("load"!==e.type||i.wasCalled(t)||(e={type:"error"}),u=e.type,s="error"===e.type?404:200),n&&n(s,u)},hi(r,"load",a),hi(r,"error",a),o.body.appendChild(r),a}return function(o,s,u,l,c,f,d,h,g,v){function b(){x&&x(),_&&_.abort()}function y(t,r,i,o,a){$(E)&&n.cancel(E),x=_=null,t(r,i,o,a),e.$$completeOutstandingRequest(p)}if(e.$$incOutstandingRequestCount(),s=s||e.url(),"jsonp"===Tr(o))var w=i.createCallback(s),x=a(s,w,function(e,t){var n=200===e&&i.getResponse(w);y(l,e,n,"",t),i.removeCallback(w)});else{var _=t(o,s);_.open(o,s,!0),r(c,function(e,t){$(e)&&_.setRequestHeader(t,e)}),_.onload=function(){var e=_.statusText||"",t="response"in _?_.response:_.responseText,n=1223===_.status?204:_.status;0===n&&(n=t?200:"file"==Dn(s).protocol?404:0),y(l,n,t,_.getAllResponseHeaders(),e)};var k=function(){y(l,-1,null,null,"")};if(_.onerror=k,_.onabort=k,r(g,function(e,t){_.addEventListener(t,e)}),r(v,function(e,t){_.upload.addEventListener(t,e)}),d&&(_.withCredentials=!0),h)try{_.responseType=h}catch(S){if("json"!==h)throw S}_.send(m(u)?null:u)}if(f>0)var E=n(b,f);else P(f)&&f.then(b)}}function Nt(){var e="{{",t="}}";this.startSymbol=function(t){return t?(e=t,this):e},this.endSymbol=function(e){return e?(t=e,this):t},this.$get=["$parse","$exceptionHandler","$sce",function(n,r,i){function o(e){return"\\\\\\"+e}function a(n){return n.replace(p,e).replace(h,t)}function s(e){if(null==e)return"";switch(typeof e){case"string":break;case"number":e=""+e;break;default:e=B(e)}return e}function u(e,t,n,r){var i;return i=e.$watch(function(e){return i(),r(e)},t,n)}function c(o,c,p,h){function v(e){try{return e=P(e),h&&!$(e)?e:s(e)}catch(t){r(oo.interr(o,t))}}if(!o.length||o.indexOf(e)===-1){var b;if(!c){var y=a(o);b=g(y),b.exp=o,b.expressions=[],b.$$watchDelegate=u}return b}h=!!h;for(var w,x,_,S=0,E=[],C=[],A=o.length,O=[],M=[];S<A;){if((w=o.indexOf(e,S))==-1||(x=o.indexOf(t,w+f))==-1){S!==A&&O.push(a(o.substring(S)));break}S!==w&&O.push(a(o.substring(S,w))),_=o.substring(w+f,x),E.push(_),C.push(n(_,v)),S=x+d,M.push(O.length),O.push("")}if(p&&O.length>1&&oo.throwNoconcat(o),!c||E.length){var j=function(e){for(var t=0,n=E.length;t<n;t++){if(h&&m(e[t]))return;O[M[t]]=e[t]}return O.join("")},P=function(e){return p?i.getTrusted(p,e):i.valueOf(e)};return l(function(e){var t=0,n=E.length,i=new Array(n);try{for(;t<n;t++)i[t]=C[t](e);return j(i)}catch(a){r(oo.interr(o,a))}},{exp:o,expressions:E,$$watchDelegate:function(e,t){var n;return e.$watchGroup(C,function(r,i){var o=j(r);k(t)&&t.call(this,o,r!==i?n:o,e),n=o})}})}}var f=e.length,d=t.length,p=new RegExp(e.replace(/./g,o),"g"),h=new RegExp(t.replace(/./g,o),"g");return c.startSymbol=function(){return e},c.endSymbol=function(){return t},c}]}function It(){this.$get=["$rootScope","$window","$q","$$q","$browser",function(e,t,n,r,i){function o(o,s,u,l){function c(){f?o.apply(null,d):o(g)}var f=arguments.length>4,d=f?L(arguments,4):[],p=t.setInterval,h=t.clearInterval,g=0,v=$(l)&&!l,m=(v?r:n).defer(),b=m.promise;return u=$(u)?u:0,b.$$intervalId=p(function(){v?i.defer(c):e.$evalAsync(c),m.notify(g++),u>0&&g>=u&&(m.resolve(g),h(b.$$intervalId),delete a[b.$$intervalId]),v||e.$apply()},s),a[b.$$intervalId]=m,b}var a={};return o.cancel=function(e){return!!(e&&e.$$intervalId in a)&&(a[e.$$intervalId].reject("canceled"),t.clearInterval(e.$$intervalId),delete a[e.$$intervalId],!0)},o}]}function Rt(e){for(var t=e.split("/"),n=t.length;n--;)t[n]=ee(t[n]);return t.join("/")}function Ut(e,t){var n=Dn(e);t.$$protocol=n.protocol,t.$$host=n.hostname,t.$$port=f(n.port)||uo[n.protocol]||null}function Vt(e,t){var n="/"!==e.charAt(0);n&&(e="/"+e);var r=Dn(e);t.$$path=decodeURIComponent(n&&"/"===r.pathname.charAt(0)?r.pathname.substring(1):r.pathname),t.$$search=J(r.search),t.$$hash=decodeURIComponent(r.hash),t.$$path&&"/"!=t.$$path.charAt(0)&&(t.$$path="/"+t.$$path)}function zt(e,t){return 0===e.lastIndexOf(t,0)}function Lt(e,t){if(zt(t,e))return t.substr(e.length)}function qt(e){var t=e.indexOf("#");return t==-1?e:e.substr(0,t)}function Ht(e){return e.replace(/(#.+)|#$/,"$1")}function Bt(e){return e.substr(0,qt(e).lastIndexOf("/")+1)}function Wt(e){return e.substring(0,e.indexOf("/",e.indexOf("//")+2))}function Gt(e,t,n){this.$$html5=!0,n=n||"",Ut(e,this),this.$$parse=function(e){var n=Lt(t,e);if(!w(n))throw lo("ipthprfx",'Invalid url "{0}", missing path prefix "{1}".',e,t);Vt(n,this),this.$$path||(this.$$path="/"),this.$$compose()},this.$$compose=function(){var e=Q(this.$$search),n=this.$$hash?"#"+ee(this.$$hash):"";this.$$url=Rt(this.$$path)+(e?"?"+e:"")+n,this.$$absUrl=t+this.$$url.substr(1)},this.$$parseLinkUrl=function(r,i){if(i&&"#"===i[0])return this.hash(i.slice(1)),!0;var o,a,s;return $(o=Lt(e,r))?(a=o,s=$(o=Lt(n,o))?t+(Lt("/",o)||o):e+a):$(o=Lt(t,r))?s=t+o:t==r+"/"&&(s=t),s&&this.$$parse(s),!!s}}function Xt(e,t,n){Ut(e,this),this.$$parse=function(r){function i(e,t,n){var r,i=/^\/[A-Z]:(\/.*)/;return zt(t,n)&&(t=t.replace(n,"")),i.exec(t)?e:(r=i.exec(e),r?r[1]:e)}var o,a=Lt(e,r)||Lt(t,r);m(a)||"#"!==a.charAt(0)?this.$$html5?o=a:(o="",m(a)&&(e=r,this.replace())):(o=Lt(n,a),m(o)&&(o=a)),Vt(o,this),this.$$path=i(this.$$path,o,e),this.$$compose()},this.$$compose=function(){var t=Q(this.$$search),r=this.$$hash?"#"+ee(this.$$hash):"";this.$$url=Rt(this.$$path)+(t?"?"+t:"")+r,this.$$absUrl=e+(this.$$url?n+this.$$url:"")},this.$$parseLinkUrl=function(t,n){return qt(e)==qt(t)&&(this.$$parse(t),!0)}}function Kt(e,t,n){this.$$html5=!0,Xt.apply(this,arguments),this.$$parseLinkUrl=function(r,i){if(i&&"#"===i[0])return this.hash(i.slice(1)),!0;var o,a;return e==qt(r)?o=r:(a=Lt(t,r))?o=e+n+a:t===r+"/"&&(o=t),o&&this.$$parse(o),!!o},this.$$compose=function(){var t=Q(this.$$search),r=this.$$hash?"#"+ee(this.$$hash):"";this.$$url=Rt(this.$$path)+(t?"?"+t:"")+r,this.$$absUrl=e+n+this.$$url}}function Yt(e){return function(){return this[e]}}function Zt(e,t){return function(n){return m(n)?this[e]:(this[e]=t(n),this.$$compose(),this)}}function Jt(){var e="",t={enabled:!1,requireBase:!0,rewriteLinks:!0};this.hashPrefix=function(t){return $(t)?(e=t,this):e},this.html5Mode=function(e){return j(e)?(t.enabled=e,this):b(e)?(j(e.enabled)&&(t.enabled=e.enabled),j(e.requireBase)&&(t.requireBase=e.requireBase),j(e.rewriteLinks)&&(t.rewriteLinks=e.rewriteLinks),this):t},this.$get=["$rootScope","$browser","$sniffer","$rootElement","$window",function(n,r,i,o,a){function s(e,t,n){var i=l.url(),o=l.$$state;try{r.url(e,t,n),l.$$state=r.state()}catch(a){throw l.url(i),l.$$state=o,a}}function u(e,t){n.$broadcast("$locationChangeSuccess",l.absUrl(),e,l.$$state,t)}var l,c,f,d=r.baseHref(),p=r.url();if(t.enabled){if(!d&&t.requireBase)throw lo("nobase","$location in HTML5 mode requires a <base> tag to be present!");f=Wt(p)+(d||"/"),c=i.history?Gt:Kt}else f=qt(p),c=Xt;var h=Bt(f);l=new c(f,h,"#"+e),l.$$parseLinkUrl(p,p),l.$$state=r.state();var g=/^\s*(javascript|mailto):/i;o.on("click",function(e){if(t.rewriteLinks&&!e.ctrlKey&&!e.metaKey&&!e.shiftKey&&2!=e.which&&2!=e.button){for(var i=Rr(e.target);"a"!==I(i[0]);)if(i[0]===o[0]||!(i=i.parent())[0])return;var s=i.prop("href"),u=i.attr("href")||i.attr("xlink:href");b(s)&&"[object SVGAnimatedString]"===s.toString()&&(s=Dn(s.animVal).href),g.test(s)||!s||i.attr("target")||e.isDefaultPrevented()||l.$$parseLinkUrl(s,u)&&(e.preventDefault(),l.absUrl()!=r.url()&&(n.$apply(),a.angular["ff-684208-preventDefault"]=!0))}}),Ht(l.absUrl())!=Ht(p)&&r.url(l.absUrl(),!0);var v=!0;return r.onUrlChange(function(e,t){return m(Lt(h,e))?void(a.location.href=e):(n.$evalAsync(function(){var r,i=l.absUrl(),o=l.$$state;e=Ht(e),l.$$parse(e),l.$$state=t,r=n.$broadcast("$locationChangeStart",e,i,t,o).defaultPrevented,l.absUrl()===e&&(r?(l.$$parse(i),l.$$state=o,s(i,!1,o)):(v=!1,u(i,o)))}),void(n.$$phase||n.$digest()))}),n.$watch(function(){var e=Ht(r.url()),t=Ht(l.absUrl()),o=r.state(),a=l.$$replace,c=e!==t||l.$$html5&&i.history&&o!==l.$$state;(v||c)&&(v=!1,n.$evalAsync(function(){var t=l.absUrl(),r=n.$broadcast("$locationChangeStart",t,e,l.$$state,o).defaultPrevented;l.absUrl()===t&&(r?(l.$$parse(e),l.$$state=o):(c&&s(t,a,o===l.$$state?null:l.$$state),u(e,o)))})),l.$$replace=!1}),l}]}function Qt(){var e=!0,t=this;this.debugEnabled=function(t){return $(t)?(e=t,this):e},this.$get=["$window",function(n){function i(e){return e instanceof Error&&(e.stack?e=e.message&&e.stack.indexOf(e.message)===-1?"Error: "+e.message+"\n"+e.stack:e.stack:e.sourceURL&&(e=e.message+"\n"+e.sourceURL+":"+e.line)),e}function o(e){var t=n.console||{},o=t[e]||t.log||p,a=!1;try{a=!!o.apply}catch(s){}return a?function(){var e=[];return r(arguments,function(t){e.push(i(t))}),o.apply(t,e)}:function(e,t){o(e,null==t?"":t)}}return{log:o("log"),info:o("info"),warn:o("warn"),error:o("error"),debug:function(){var n=o("debug");return function(){e&&n.apply(t,arguments)}}()}}]}function en(e,t){if("__defineGetter__"===e||"__defineSetter__"===e||"__lookupGetter__"===e||"__lookupSetter__"===e||"__proto__"===e)throw fo("isecfld","Attempting to access a disallowed field in Angular expressions! Expression: {0}",t);return e}function tn(e){return e+""}function nn(e,t){if(e){if(e.constructor===e)throw fo("isecfn","Referencing Function in Angular expressions is disallowed! Expression: {0}",t);if(e.window===e)throw fo("isecwindow","Referencing the Window in Angular expressions is disallowed! Expression: {0}",t);if(e.children&&(e.nodeName||e.prop&&e.attr&&e.find))throw fo("isecdom","Referencing DOM nodes in Angular expressions is disallowed! Expression: {0}",t);if(e===Object)throw fo("isecobj","Referencing Object in Angular expressions is disallowed! Expression: {0}",t)}return e}function rn(e,t){if(e){if(e.constructor===e)throw fo("isecfn","Referencing Function in Angular expressions is disallowed! Expression: {0}",t);if(e===po||e===ho||e===go)throw fo("isecff","Referencing call, apply or bind in Angular expressions is disallowed! Expression: {0}",t)}}function on(e,t){if(e&&(e===(0).constructor||e===(!1).constructor||e==="".constructor||e==={}.constructor||e===[].constructor||e===Function.constructor))throw fo("isecaf","Assigning to a constructor is disallowed! Expression: {0}",t)}function an(e,t){return"undefined"!=typeof e?e:t}function sn(e,t){return"undefined"==typeof e?t:"undefined"==typeof t?e:e+t}function un(e,t){var n=e(t);return!n.$stateful}function ln(e,t){var n,i;switch(e.type){case bo.Program:n=!0,r(e.body,function(e){ln(e.expression,t),n=n&&e.expression.constant}),e.constant=n;break;case bo.Literal:e.constant=!0,e.toWatch=[];break;case bo.UnaryExpression:ln(e.argument,t),e.constant=e.argument.constant,e.toWatch=e.argument.toWatch;break;case bo.BinaryExpression:ln(e.left,t),ln(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=e.left.toWatch.concat(e.right.toWatch);break;case bo.LogicalExpression:ln(e.left,t),ln(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=e.constant?[]:[e];break;case bo.ConditionalExpression:ln(e.test,t),ln(e.alternate,t),ln(e.consequent,t),e.constant=e.test.constant&&e.alternate.constant&&e.consequent.constant,e.toWatch=e.constant?[]:[e];break;case bo.Identifier:e.constant=!1,e.toWatch=[e];break;case bo.MemberExpression:ln(e.object,t),e.computed&&ln(e.property,t),e.constant=e.object.constant&&(!e.computed||e.property.constant),e.toWatch=[e];break;case bo.CallExpression:n=!!e.filter&&un(t,e.callee.name),i=[],r(e.arguments,function(e){ln(e,t),n=n&&e.constant,e.constant||i.push.apply(i,e.toWatch)}),e.constant=n,e.toWatch=e.filter&&un(t,e.callee.name)?i:[e];break;case bo.AssignmentExpression:ln(e.left,t),ln(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=[e];break;case bo.ArrayExpression:n=!0,i=[],r(e.elements,function(e){ln(e,t),n=n&&e.constant,e.constant||i.push.apply(i,e.toWatch)}),e.constant=n,e.toWatch=i;break;case bo.ObjectExpression:n=!0,i=[],r(e.properties,function(e){ln(e.value,t),n=n&&e.value.constant&&!e.computed,e.value.constant||i.push.apply(i,e.value.toWatch)}),e.constant=n,e.toWatch=i;break;case bo.ThisExpression:e.constant=!1,e.toWatch=[];break;case bo.LocalsExpression:e.constant=!1,e.toWatch=[]}}function cn(e){if(1==e.length){var t=e[0].expression,n=t.toWatch;return 1!==n.length?n:n[0]!==t?n:void 0}}function fn(e){return e.type===bo.Identifier||e.type===bo.MemberExpression}function dn(e){if(1===e.body.length&&fn(e.body[0].expression))return{type:bo.AssignmentExpression,left:e.body[0].expression,right:{type:bo.NGValueParameter},operator:"="}}function pn(e){return 0===e.body.length||1===e.body.length&&(e.body[0].expression.type===bo.Literal||e.body[0].expression.type===bo.ArrayExpression||e.body[0].expression.type===bo.ObjectExpression)}function hn(e){return e.constant}function gn(e,t){this.astBuilder=e,this.$filter=t}function vn(e,t){this.astBuilder=e,this.$filter=t}function mn(e){return"constructor"==e}function $n(e){return k(e.valueOf)?e.valueOf():wo.call(e)}function bn(){var e,t,n=he(),i=he(),o={"true":!0,"false":!1,"null":null,undefined:void 0};this.addLiteral=function(e,t){o[e]=t},this.setIdentifierFns=function(n,r){return e=n,t=r,this},this.$get=["$filter",function(a){function s(e,t,r){var o,s,l;switch(r=r||y,typeof e){case"string":e=e.trim(),l=e;var v=r?i:n;if(o=v[l],!o){":"===e.charAt(0)&&":"===e.charAt(1)&&(s=!0,e=e.substring(2));var $=r?b:m,w=new $o($),x=new yo(w,a,$);o=x.parse(e),o.constant?o.$$watchDelegate=h:s?o.$$watchDelegate=o.literal?d:f:o.inputs&&(o.$$watchDelegate=c),r&&(o=u(o)),v[l]=o}return g(o,t);case"function":return g(e,t);default:return g(p,t)}}function u(e){function t(t,n,r,i){var o=y;y=!0;try{return e(t,n,r,i)}finally{y=o}}if(!e)return e;t.$$watchDelegate=e.$$watchDelegate,t.assign=u(e.assign),t.constant=e.constant,t.literal=e.literal;for(var n=0;e.inputs&&n<e.inputs.length;++n)e.inputs[n]=u(e.inputs[n]);return t.inputs=e.inputs,t}function l(e,t){return null==e||null==t?e===t:("object"!=typeof e||(e=$n(e),"object"!=typeof e))&&(e===t||e!==e&&t!==t)}function c(e,t,n,r,i){var o,a=r.inputs;if(1===a.length){var s=l;return a=a[0],e.$watch(function(e){var t=a(e);return l(t,s)||(o=r(e,void 0,void 0,[t]),s=t&&$n(t)),o},t,n,i)}for(var u=[],c=[],f=0,d=a.length;f<d;f++)u[f]=l,c[f]=null;return e.$watch(function(e){for(var t=!1,n=0,i=a.length;n<i;n++){var s=a[n](e);(t||(t=!l(s,u[n])))&&(c[n]=s,u[n]=s&&$n(s))}return t&&(o=r(e,void 0,void 0,c)),o},t,n,i)}function f(e,t,n,r){var i,o;return i=e.$watch(function(e){return r(e)},function(e,n,r){o=e,k(t)&&t.apply(this,arguments),$(e)&&r.$$postDigest(function(){$(o)&&i()})},n)}function d(e,t,n,i){function o(e){var t=!0;return r(e,function(e){$(e)||(t=!1)}),t}var a,s;return a=e.$watch(function(e){return i(e)},function(e,n,r){s=e,k(t)&&t.call(this,e,n,r),o(e)&&r.$$postDigest(function(){o(s)&&a()})},n)}function h(e,t,n,r){var i;return i=e.$watch(function(e){return i(),r(e)},t,n)}function g(e,t){if(!t)return e;var n=e.$$watchDelegate,r=!1,i=n!==d&&n!==f,o=i?function(n,i,o,a){var s=r&&a?a[0]:e(n,i,o,a);return t(s,n,i)}:function(n,r,i,o){var a=e(n,r,i,o),s=t(a,n,r);return $(a)?s:a};return e.$$watchDelegate&&e.$$watchDelegate!==c?o.$$watchDelegate=e.$$watchDelegate:t.$stateful||(o.$$watchDelegate=c,r=!e.inputs,o.inputs=e.inputs?e.inputs:[e]),o}var v=Qr().noUnsafeEval,m={csp:v,expensiveChecks:!1,literals:U(o),isIdentifierStart:k(e)&&e,isIdentifierContinue:k(t)&&t},b={csp:v,expensiveChecks:!0,literals:U(o),isIdentifierStart:k(e)&&e,isIdentifierContinue:k(t)&&t},y=!1;return s.$$runningExpensiveChecks=function(){return y},s}]}function yn(){this.$get=["$rootScope","$exceptionHandler",function(e,t){return xn(function(t){e.$evalAsync(t)},t)}]}function wn(){this.$get=["$browser","$exceptionHandler",function(e,t){return xn(function(t){e.defer(t)},t)}]}function xn(e,n){function i(){this.$$state={status:0}}function o(e,t){return function(n){t.call(e,n)}}function a(e){var t,r,i;i=e.pending,e.processScheduled=!1,e.pending=void 0;for(var o=0,a=i.length;o<a;++o){r=i[o][0],t=i[o][e.status];try{k(t)?r.resolve(t(e.value)):1===e.status?r.resolve(e.value):r.reject(e.value)}catch(s){r.reject(s),n(s)}}}function s(t){!t.processScheduled&&t.pending&&(t.processScheduled=!0,e(function(){a(t)}))}function u(){this.promise=new i}function c(e){var t=new u,n=0,i=Kr(e)?[]:{};return r(e,function(e,r){n++,$(e).then(function(e){i.hasOwnProperty(r)||(i[r]=e,
|
5 |
-
--n||t.resolve(i))},function(e){i.hasOwnProperty(r)||t.reject(e)})}),0===n&&t.resolve(i),t.promise}function f(e){var t=p();return r(e,function(e){$(e).then(t.resolve,t.reject)}),t.promise}var d=t("$q",TypeError),p=function(){var e=new u;return e.resolve=o(e,e.resolve),e.reject=o(e,e.reject),e.notify=o(e,e.notify),e};l(i.prototype,{then:function(e,t,n){if(m(e)&&m(t)&&m(n))return this;var r=new u;return this.$$state.pending=this.$$state.pending||[],this.$$state.pending.push([r,e,t,n]),this.$$state.status>0&&s(this.$$state),r.promise},"catch":function(e){return this.then(null,e)},"finally":function(e,t){return this.then(function(t){return v(t,!0,e)},function(t){return v(t,!1,e)},t)}}),l(u.prototype,{resolve:function(e){this.promise.$$state.status||(e===this.promise?this.$$reject(d("qcycle","Expected promise to be resolved with value other than itself '{0}'",e)):this.$$resolve(e))},$$resolve:function(e){function t(e){u||(u=!0,a.$$resolve(e))}function r(e){u||(u=!0,a.$$reject(e))}var i,a=this,u=!1;try{(b(e)||k(e))&&(i=e&&e.then),k(i)?(this.promise.$$state.status=-1,i.call(e,t,r,o(this,this.notify))):(this.promise.$$state.value=e,this.promise.$$state.status=1,s(this.promise.$$state))}catch(l){r(l),n(l)}},reject:function(e){this.promise.$$state.status||this.$$reject(e)},$$reject:function(e){this.promise.$$state.value=e,this.promise.$$state.status=2,s(this.promise.$$state)},notify:function(t){var r=this.promise.$$state.pending;this.promise.$$state.status<=0&&r&&r.length&&e(function(){for(var e,i,o=0,a=r.length;o<a;o++){i=r[o][0],e=r[o][3];try{i.notify(k(e)?e(t):t)}catch(s){n(s)}}})}});var h=function(e){var t=new u;return t.reject(e),t.promise},g=function(e,t){var n=new u;return t?n.resolve(e):n.reject(e),n.promise},v=function(e,t,n){var r=null;try{k(n)&&(r=n())}catch(i){return g(i,!1)}return P(r)?r.then(function(){return g(e,t)},function(e){return g(e,!1)}):g(e,t)},$=function(e,t,n,r){var i=new u;return i.resolve(e),i.promise.then(t,n,r)},y=$,w=function(e){function t(e){r.resolve(e)}function n(e){r.reject(e)}if(!k(e))throw d("norslvr","Expected resolverFn, got '{0}'",e);var r=new u;return e(t,n),r.promise};return w.prototype=i.prototype,w.defer=p,w.reject=h,w.when=$,w.resolve=y,w.all=c,w.race=f,w}function _n(){this.$get=["$window","$timeout",function(e,t){var n=e.requestAnimationFrame||e.webkitRequestAnimationFrame,r=e.cancelAnimationFrame||e.webkitCancelAnimationFrame||e.webkitCancelRequestAnimationFrame,i=!!n,o=i?function(e){var t=n(e);return function(){r(t)}}:function(e){var n=t(e,16.66,!1);return function(){t.cancel(n)}};return o.supported=i,o}]}function kn(){function e(e){function t(){this.$$watchers=this.$$nextSibling=this.$$childHead=this.$$childTail=null,this.$$listeners={},this.$$listenerCount={},this.$$watchersCount=0,this.$id=a(),this.$$ChildScope=null}return t.prototype=e,t}var i=10,o=t("$rootScope"),s=null,u=null;this.digestTtl=function(e){return arguments.length&&(i=e),i},this.$get=["$exceptionHandler","$parse","$browser",function(t,l,c){function f(e){e.currentScope.$$destroyed=!0}function d(e){9===Ir&&(e.$$childHead&&d(e.$$childHead),e.$$nextSibling&&d(e.$$nextSibling)),e.$parent=e.$$nextSibling=e.$$prevSibling=e.$$childHead=e.$$childTail=e.$root=e.$$watchers=null}function h(){this.$id=a(),this.$$phase=this.$parent=this.$$watchers=this.$$nextSibling=this.$$prevSibling=this.$$childHead=this.$$childTail=null,this.$root=this,this.$$destroyed=!1,this.$$listeners={},this.$$listenerCount={},this.$$watchersCount=0,this.$$isolateBindings=null}function g(e){if(S.$$phase)throw o("inprog","{0} already in progress",S.$$phase);S.$$phase=e}function v(){S.$$phase=null}function $(e,t){do e.$$watchersCount+=t;while(e=e.$parent)}function y(e,t,n){do e.$$listenerCount[n]-=t,0===e.$$listenerCount[n]&&delete e.$$listenerCount[n];while(e=e.$parent)}function w(){}function x(){for(;A.length;)try{A.shift()()}catch(e){t(e)}u=null}function _(){null===u&&(u=c.defer(function(){S.$apply(x)}))}h.prototype={constructor:h,$new:function(t,n){var r;return n=n||this,t?(r=new h,r.$root=this.$root):(this.$$ChildScope||(this.$$ChildScope=e(this)),r=new this.$$ChildScope),r.$parent=n,r.$$prevSibling=n.$$childTail,n.$$childHead?(n.$$childTail.$$nextSibling=r,n.$$childTail=r):n.$$childHead=n.$$childTail=r,(t||n!=this)&&r.$on("$destroy",f),r},$watch:function(e,t,n,r){var i=l(e);if(i.$$watchDelegate)return i.$$watchDelegate(this,t,n,i,e);var o=this,a=o.$$watchers,u={fn:t,last:w,get:i,exp:r||e,eq:!!n};return s=null,k(t)||(u.fn=p),a||(a=o.$$watchers=[]),a.unshift(u),$(this,1),function(){R(a,u)>=0&&$(o,-1),s=null}},$watchGroup:function(e,t){function n(){u=!1,l?(l=!1,t(o,o,s)):t(o,i,s)}var i=new Array(e.length),o=new Array(e.length),a=[],s=this,u=!1,l=!0;if(!e.length){var c=!0;return s.$evalAsync(function(){c&&t(o,o,s)}),function(){c=!1}}return 1===e.length?this.$watch(e[0],function(e,n,r){o[0]=e,i[0]=n,t(o,e===n?o:i,r)}):(r(e,function(e,t){var r=s.$watch(e,function(e,r){o[t]=e,i[t]=r,u||(u=!0,s.$evalAsync(n))});a.push(r)}),function(){for(;a.length;)a.shift()()})},$watchCollection:function(e,t){function r(e){o=e;var t,r,i,s,u;if(!m(o)){if(b(o))if(n(o)){a!==p&&(a=p,v=a.length=0,f++),t=o.length,v!==t&&(f++,a.length=v=t);for(var l=0;l<t;l++)u=a[l],s=o[l],i=u!==u&&s!==s,i||u===s||(f++,a[l]=s)}else{a!==h&&(a=h={},v=0,f++),t=0;for(r in o)Pr.call(o,r)&&(t++,s=o[r],u=a[r],r in a?(i=u!==u&&s!==s,i||u===s||(f++,a[r]=s)):(v++,a[r]=s,f++));if(v>t){f++;for(r in a)Pr.call(o,r)||(v--,delete a[r])}}else a!==o&&(a=o,f++);return f}}function i(){if(g?(g=!1,t(o,o,u)):t(o,s,u),c)if(b(o))if(n(o)){s=new Array(o.length);for(var e=0;e<o.length;e++)s[e]=o[e]}else{s={};for(var r in o)Pr.call(o,r)&&(s[r]=o[r])}else s=o}r.$stateful=!0;var o,a,s,u=this,c=t.length>1,f=0,d=l(e,r),p=[],h={},g=!0,v=0;return this.$watch(d,i)},$digest:function(){var e,n,r,a,l,f,d,p,h,m,$,b,y=i,_=this,A=[];g("$digest"),c.$$checkUrlChange(),this===S&&null!==u&&(c.defer.cancel(u),x()),s=null;do{p=!1,m=_;for(var M=0;M<E.length;M++){try{b=E[M],b.scope.$eval(b.expression,b.locals)}catch(j){t(j)}s=null}E.length=0;e:do{if(f=m.$$watchers)for(d=f.length;d--;)try{if(e=f[d])if(l=e.get,(n=l(m))===(r=e.last)||(e.eq?V(n,r):"number"==typeof n&&"number"==typeof r&&isNaN(n)&&isNaN(r))){if(e===s){p=!1;break e}}else p=!0,s=e,e.last=e.eq?U(n,null):n,a=e.fn,a(n,r===w?n:r,m),y<5&&($=4-y,A[$]||(A[$]=[]),A[$].push({msg:k(e.exp)?"fn: "+(e.exp.name||e.exp.toString()):e.exp,newVal:n,oldVal:r}))}catch(j){t(j)}if(!(h=m.$$watchersCount&&m.$$childHead||m!==_&&m.$$nextSibling))for(;m!==_&&!(h=m.$$nextSibling);)m=m.$parent}while(m=h);if((p||E.length)&&!y--)throw v(),o("infdig","{0} $digest() iterations reached. Aborting!\nWatchers fired in the last 5 iterations: {1}",i,A)}while(p||E.length);for(v();O<C.length;)try{C[O++]()}catch(j){t(j)}C.length=O=0},$destroy:function(){if(!this.$$destroyed){var e=this.$parent;this.$broadcast("$destroy"),this.$$destroyed=!0,this===S&&c.$$applicationDestroyed(),$(this,-this.$$watchersCount);for(var t in this.$$listenerCount)y(this,this.$$listenerCount[t],t);e&&e.$$childHead==this&&(e.$$childHead=this.$$nextSibling),e&&e.$$childTail==this&&(e.$$childTail=this.$$prevSibling),this.$$prevSibling&&(this.$$prevSibling.$$nextSibling=this.$$nextSibling),this.$$nextSibling&&(this.$$nextSibling.$$prevSibling=this.$$prevSibling),this.$destroy=this.$digest=this.$apply=this.$evalAsync=this.$applyAsync=p,this.$on=this.$watch=this.$watchGroup=function(){return p},this.$$listeners={},this.$$nextSibling=null,d(this)}},$eval:function(e,t){return l(e)(this,t)},$evalAsync:function(e,t){S.$$phase||E.length||c.defer(function(){E.length&&S.$digest()}),E.push({scope:this,expression:l(e),locals:t})},$$postDigest:function(e){C.push(e)},$apply:function(e){try{g("$apply");try{return this.$eval(e)}finally{v()}}catch(n){t(n)}finally{try{S.$digest()}catch(n){throw t(n),n}}},$applyAsync:function(e){function t(){n.$eval(e)}var n=this;e&&A.push(t),e=l(e),_()},$on:function(e,t){var n=this.$$listeners[e];n||(this.$$listeners[e]=n=[]),n.push(t);var r=this;do r.$$listenerCount[e]||(r.$$listenerCount[e]=0),r.$$listenerCount[e]++;while(r=r.$parent);var i=this;return function(){var r=n.indexOf(t);r!==-1&&(n[r]=null,y(i,1,e))}},$emit:function(e,n){var r,i,o,a=[],s=this,u=!1,l={name:e,targetScope:s,stopPropagation:function(){u=!0},preventDefault:function(){l.defaultPrevented=!0},defaultPrevented:!1},c=z([l],arguments,1);do{for(r=s.$$listeners[e]||a,l.currentScope=s,i=0,o=r.length;i<o;i++)if(r[i])try{r[i].apply(null,c)}catch(f){t(f)}else r.splice(i,1),i--,o--;if(u)return l.currentScope=null,l;s=s.$parent}while(s);return l.currentScope=null,l},$broadcast:function(e,n){var r=this,i=r,o=r,a={name:e,targetScope:r,preventDefault:function(){a.defaultPrevented=!0},defaultPrevented:!1};if(!r.$$listenerCount[e])return a;for(var s,u,l,c=z([a],arguments,1);i=o;){for(a.currentScope=i,s=i.$$listeners[e]||[],u=0,l=s.length;u<l;u++)if(s[u])try{s[u].apply(null,c)}catch(f){t(f)}else s.splice(u,1),u--,l--;if(!(o=i.$$listenerCount[e]&&i.$$childHead||i!==r&&i.$$nextSibling))for(;i!==r&&!(o=i.$$nextSibling);)i=i.$parent}return a.currentScope=null,a}};var S=new h,E=S.$$asyncQueue=[],C=S.$$postDigestQueue=[],A=S.$$applyAsyncQueue=[],O=0;return S}]}function Sn(){var e=/^\s*(https?|ftp|mailto|tel|file):/,t=/^\s*((https?|ftp|file|blob):|data:image\/)/;this.aHrefSanitizationWhitelist=function(t){return $(t)?(e=t,this):e},this.imgSrcSanitizationWhitelist=function(e){return $(e)?(t=e,this):t},this.$get=function(){return function(n,r){var i,o=r?t:e;return i=Dn(n).href,""===i||i.match(o)?n:"unsafe:"+i}}}function En(e){if("self"===e)return e;if(w(e)){if(e.indexOf("***")>-1)throw xo("iwcard","Illegal sequence *** in string matcher. String: {0}",e);return e=Jr(e).replace("\\*\\*",".*").replace("\\*","[^:/.?&;]*"),new RegExp("^"+e+"$")}if(S(e))return new RegExp("^"+e.source+"$");throw xo("imatcher",'Matchers may only be "self", string patterns or RegExp objects')}function Cn(e){var t=[];return $(e)&&r(e,function(e){t.push(En(e))}),t}function An(){this.SCE_CONTEXTS=_o;var e=["self"],t=[];this.resourceUrlWhitelist=function(t){return arguments.length&&(e=Cn(t)),e},this.resourceUrlBlacklist=function(e){return arguments.length&&(t=Cn(e)),t},this.$get=["$injector",function(n){function r(e,t){return"self"===e?Fn(t):!!e.exec(t.href)}function i(n){var i,o,a=Dn(n.toString()),s=!1;for(i=0,o=e.length;i<o;i++)if(r(e[i],a)){s=!0;break}if(s)for(i=0,o=t.length;i<o;i++)if(r(t[i],a)){s=!1;break}return s}function o(e){var t=function(e){this.$$unwrapTrustedValue=function(){return e}};return e&&(t.prototype=new e),t.prototype.valueOf=function(){return this.$$unwrapTrustedValue()},t.prototype.toString=function(){return this.$$unwrapTrustedValue().toString()},t}function a(e,t){var n=f.hasOwnProperty(e)?f[e]:null;if(!n)throw xo("icontext","Attempted to trust a value in invalid context. Context: {0}; Value: {1}",e,t);if(null===t||m(t)||""===t)return t;if("string"!=typeof t)throw xo("itype","Attempted to trust a non-string value in a content requiring a string: Context: {0}",e);return new n(t)}function s(e){return e instanceof c?e.$$unwrapTrustedValue():e}function u(e,t){if(null===t||m(t)||""===t)return t;var n=f.hasOwnProperty(e)?f[e]:null;if(n&&t instanceof n)return t.$$unwrapTrustedValue();if(e===_o.RESOURCE_URL){if(i(t))return t;throw xo("insecurl","Blocked loading resource from url not allowed by $sceDelegate policy. URL: {0}",t.toString())}if(e===_o.HTML)return l(t);throw xo("unsafe","Attempting to use an unsafe value in a safe context.")}var l=function(e){throw xo("unsafe","Attempting to use an unsafe value in a safe context.")};n.has("$sanitize")&&(l=n.get("$sanitize"));var c=o(),f={};return f[_o.HTML]=o(c),f[_o.CSS]=o(c),f[_o.URL]=o(c),f[_o.JS]=o(c),f[_o.RESOURCE_URL]=o(f[_o.URL]),{trustAs:a,getTrusted:u,valueOf:s}}]}function On(){var e=!0;this.enabled=function(t){return arguments.length&&(e=!!t),e},this.$get=["$parse","$sceDelegate",function(t,n){if(e&&Ir<8)throw xo("iequirks","Strict Contextual Escaping does not support Internet Explorer version < 11 in quirks mode. You can fix this by adding the text <!doctype html> to the top of your HTML document. See http://docs.angularjs.org/api/ng.$sce for more information.");var i=ve(_o);i.isEnabled=function(){return e},i.trustAs=n.trustAs,i.getTrusted=n.getTrusted,i.valueOf=n.valueOf,e||(i.trustAs=i.getTrusted=function(e,t){return t},i.valueOf=h),i.parseAs=function(e,n){var r=t(n);return r.literal&&r.constant?r:t(n,function(t){return i.getTrusted(e,t)})};var o=i.parseAs,a=i.getTrusted,s=i.trustAs;return r(_o,function(e,t){var n=Tr(t);i[we("parse_as_"+n)]=function(t){return o(e,t)},i[we("get_trusted_"+n)]=function(t){return a(e,t)},i[we("trust_as_"+n)]=function(t){return s(e,t)}}),i}]}function Mn(){this.$get=["$window","$document",function(e,t){var n,r,i={},o=e.chrome&&e.chrome.app&&e.chrome.app.runtime,a=!o&&e.history&&e.history.pushState,s=f((/android (\d+)/.exec(Tr((e.navigator||{}).userAgent))||[])[1]),u=/Boxee/i.test((e.navigator||{}).userAgent),l=t[0]||{},c=/^(Moz|webkit|ms)(?=[A-Z])/,d=l.body&&l.body.style,p=!1,h=!1;if(d){for(var g in d)if(r=c.exec(g)){n=r[0],n=n[0].toUpperCase()+n.substr(1);break}n||(n="WebkitOpacity"in d&&"webkit"),p=!!("transition"in d||n+"Transition"in d),h=!!("animation"in d||n+"Animation"in d),!s||p&&h||(p=w(d.webkitTransition),h=w(d.webkitAnimation))}return{history:!(!a||s<4||u),hasEvent:function(e){if("input"===e&&Ir<=11)return!1;if(m(i[e])){var t=l.createElement("div");i[e]="on"+e in t}return i[e]},csp:Qr(),vendorPrefix:n,transitions:p,animations:h,android:s}}]}function jn(){var e;this.httpOptions=function(t){return t?(e=t,this):e},this.$get=["$templateCache","$http","$q","$sce",function(t,n,r,i){function o(a,s){function u(e){if(!s)throw ko("tpload","Failed to load template: {0} (HTTP status: {1} {2})",a,e.status,e.statusText);return r.reject(e)}o.totalPendingRequests++,w(a)&&!m(t.get(a))||(a=i.getTrustedResourceUrl(a));var c=n.defaults&&n.defaults.transformResponse;return Kr(c)?c=c.filter(function(e){return e!==Et}):c===Et&&(c=null),n.get(a,l({cache:t,transformResponse:c},e))["finally"](function(){o.totalPendingRequests--}).then(function(e){return t.put(a,e.data),e.data},u)}return o.totalPendingRequests=0,o}]}function Pn(){this.$get=["$rootScope","$browser","$location",function(e,t,n){var i={};return i.findBindings=function(e,t,n){var i=e.getElementsByClassName("ng-binding"),o=[];return r(i,function(e){var i=Gr.element(e).data("$binding");i&&r(i,function(r){if(n){var i=new RegExp("(^|\\s)"+Jr(t)+"(\\s|\\||$)");i.test(r)&&o.push(e)}else r.indexOf(t)!=-1&&o.push(e)})}),o},i.findModels=function(e,t,n){for(var r=["ng-","data-ng-","ng\\:"],i=0;i<r.length;++i){var o=n?"=":"*=",a="["+r[i]+"model"+o+'"'+t+'"]',s=e.querySelectorAll(a);if(s.length)return s}},i.getLocation=function(){return n.url()},i.setLocation=function(t){t!==n.url()&&(n.url(t),e.$digest())},i.whenStable=function(e){t.notifyWhenNoOutstandingRequests(e)},i}]}function Tn(){this.$get=["$rootScope","$browser","$q","$$q","$exceptionHandler",function(e,t,n,r,i){function o(o,s,u){k(o)||(u=s,s=o,o=p);var l,c=L(arguments,3),f=$(u)&&!u,d=(f?r:n).defer(),h=d.promise;return l=t.defer(function(){try{d.resolve(o.apply(null,c))}catch(t){d.reject(t),i(t)}finally{delete a[h.$$timeoutId]}f||e.$apply()},s),h.$$timeoutId=l,a[l]=d,h}var a={};return o.cancel=function(e){return!!(e&&e.$$timeoutId in a)&&(a[e.$$timeoutId].reject("canceled"),delete a[e.$$timeoutId],t.defer.cancel(e.$$timeoutId))},o}]}function Dn(e){var t=e;return Ir&&(So.setAttribute("href",t),t=So.href),So.setAttribute("href",t),{href:So.href,protocol:So.protocol?So.protocol.replace(/:$/,""):"",host:So.host,search:So.search?So.search.replace(/^\?/,""):"",hash:So.hash?So.hash.replace(/^#/,""):"",hostname:So.hostname,port:So.port,pathname:"/"===So.pathname.charAt(0)?So.pathname:"/"+So.pathname}}function Fn(e){var t=w(e)?Dn(e):e;return t.protocol===Eo.protocol&&t.host===Eo.host}function Nn(){this.$get=g(e)}function In(e){function t(e){try{return decodeURIComponent(e)}catch(t){return e}}var n=e[0]||{},r={},i="";return function(){var e,o,a,s,u,l=n.cookie||"";if(l!==i)for(i=l,e=i.split("; "),r={},a=0;a<e.length;a++)o=e[a],s=o.indexOf("="),s>0&&(u=t(o.substring(0,s)),m(r[u])&&(r[u]=t(o.substring(s+1))));return r}}function Rn(){this.$get=In}function Un(e){function t(i,o){if(b(i)){var a={};return r(i,function(e,n){a[n]=t(n,e)}),a}return e.factory(i+n,o)}var n="Filter";this.register=t,this.$get=["$injector",function(e){return function(t){return e.get(t+n)}}],t("currency",Hn),t("date",or),t("filter",Vn),t("json",ar),t("limitTo",sr),t("lowercase",To),t("number",Bn),t("orderBy",lr),t("uppercase",Do)}function Vn(){return function(e,r,i,o){if(!n(e)){if(null==e)return e;throw t("filter")("notarray","Expected array but received: {0}",e)}o=o||"$";var a,s,u=qn(r);switch(u){case"function":a=r;break;case"boolean":case"null":case"number":case"string":s=!0;case"object":a=zn(r,i,o,s);break;default:return e}return Array.prototype.filter.call(e,a)}}function zn(e,t,n,r){var i,o=b(e)&&n in e;return t===!0?t=V:k(t)||(t=function(e,t){return!m(e)&&(null===e||null===t?e===t:!(b(t)||b(e)&&!v(e))&&(e=Tr(""+e),t=Tr(""+t),e.indexOf(t)!==-1))}),i=function(i){return o&&!b(i)?Ln(i,e[n],t,n,!1):Ln(i,e,t,n,r)}}function Ln(e,t,n,r,i,o){var a=qn(e),s=qn(t);if("string"===s&&"!"===t.charAt(0))return!Ln(e,t.substring(1),n,r,i);if(Kr(e))return e.some(function(e){return Ln(e,t,n,r,i)});switch(a){case"object":var u;if(i){for(u in e)if("$"!==u.charAt(0)&&Ln(e[u],t,n,r,!0))return!0;return!o&&Ln(e,t,n,r,!1)}if("object"===s){for(u in t){var l=t[u];if(!k(l)&&!m(l)){var c=u===r,f=c?e:e[u];if(!Ln(f,l,n,r,c,c))return!1}}return!0}return n(e,t);case"function":return!1;default:return n(e,t)}}function qn(e){return null===e?"null":typeof e}function Hn(e){var t=e.NUMBER_FORMATS;return function(e,n,r){return m(n)&&(n=t.CURRENCY_SYM),m(r)&&(r=t.PATTERNS[1].maxFrac),null==e?e:Xn(e,t.PATTERNS[1],t.GROUP_SEP,t.DECIMAL_SEP,r).replace(/\u00A4/g,n)}}function Bn(e){var t=e.NUMBER_FORMATS;return function(e,n){return null==e?e:Xn(e,t.PATTERNS[0],t.GROUP_SEP,t.DECIMAL_SEP,n)}}function Wn(e){var t,n,r,i,o,a=0;for((n=e.indexOf(Ao))>-1&&(e=e.replace(Ao,"")),(r=e.search(/e/i))>0?(n<0&&(n=r),n+=+e.slice(r+1),e=e.substring(0,r)):n<0&&(n=e.length),r=0;e.charAt(r)==Oo;r++);if(r==(o=e.length))t=[0],n=1;else{for(o--;e.charAt(o)==Oo;)o--;for(n-=r,t=[],i=0;r<=o;r++,i++)t[i]=+e.charAt(r)}return n>Co&&(t=t.splice(0,Co-1),a=n-1,n=1),{d:t,e:a,i:n}}function Gn(e,t,n,r){var i=e.d,o=i.length-e.i;t=m(t)?Math.min(Math.max(n,o),r):+t;var a=t+e.i,s=i[a];if(a>0){i.splice(Math.max(e.i,a));for(var u=a;u<i.length;u++)i[u]=0}else{o=Math.max(0,o),e.i=1,i.length=Math.max(1,a=t+1),i[0]=0;for(var l=1;l<a;l++)i[l]=0}if(s>=5)if(a-1<0){for(var c=0;c>a;c--)i.unshift(0),e.i++;i.unshift(1),e.i++}else i[a-1]++;for(;o<Math.max(0,t);o++)i.push(0);var f=i.reduceRight(function(e,t,n,r){return t+=e,r[n]=t%10,Math.floor(t/10)},0);f&&(i.unshift(f),e.i++)}function Xn(e,t,n,r,i){if(!w(e)&&!x(e)||isNaN(e))return"";var o,a=!isFinite(e),s=!1,u=Math.abs(e)+"",l="";if(a)l="∞";else{o=Wn(u),Gn(o,i,t.minFrac,t.maxFrac);var c=o.d,f=o.i,d=o.e,p=[];for(s=c.reduce(function(e,t){return e&&!t},!0);f<0;)c.unshift(0),f++;f>0?p=c.splice(f,c.length):(p=c,c=[0]);var h=[];for(c.length>=t.lgSize&&h.unshift(c.splice(-t.lgSize,c.length).join(""));c.length>t.gSize;)h.unshift(c.splice(-t.gSize,c.length).join(""));c.length&&h.unshift(c.join("")),l=h.join(n),p.length&&(l+=r+p.join("")),d&&(l+="e+"+d)}return e<0&&!s?t.negPre+l+t.negSuf:t.posPre+l+t.posSuf}function Kn(e,t,n,r){var i="";for((e<0||r&&e<=0)&&(r?e=-e+1:(e=-e,i="-")),e=""+e;e.length<t;)e=Oo+e;return n&&(e=e.substr(e.length-t)),i+e}function Yn(e,t,n,r,i){return n=n||0,function(o){var a=o["get"+e]();return(n>0||a>-n)&&(a+=n),0===a&&n==-12&&(a=12),Kn(a,t,r,i)}}function Zn(e,t,n){return function(r,i){var o=r["get"+e](),a=(n?"STANDALONE":"")+(t?"SHORT":""),s=Dr(a+e);return i[s][o]}}function Jn(e,t,n){var r=-1*n,i=r>=0?"+":"";return i+=Kn(Math[r>0?"floor":"ceil"](r/60),2)+Kn(Math.abs(r%60),2)}function Qn(e){var t=new Date(e,0,1).getDay();return new Date(e,0,(t<=4?5:12)-t)}function er(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate()+(4-e.getDay()))}function tr(e){return function(t){var n=Qn(t.getFullYear()),r=er(t),i=+r-+n,o=1+Math.round(i/6048e5);return Kn(o,e)}}function nr(e,t){return e.getHours()<12?t.AMPMS[0]:t.AMPMS[1]}function rr(e,t){return e.getFullYear()<=0?t.ERAS[0]:t.ERAS[1]}function ir(e,t){return e.getFullYear()<=0?t.ERANAMES[0]:t.ERANAMES[1]}function or(e){function t(e){var t;if(t=e.match(n)){var r=new Date(0),i=0,o=0,a=t[8]?r.setUTCFullYear:r.setFullYear,s=t[8]?r.setUTCHours:r.setHours;t[9]&&(i=f(t[9]+t[10]),o=f(t[9]+t[11])),a.call(r,f(t[1]),f(t[2])-1,f(t[3]));var u=f(t[4]||0)-i,l=f(t[5]||0)-o,c=f(t[6]||0),d=Math.round(1e3*parseFloat("0."+(t[7]||0)));return s.call(r,u,l,c,d),r}return e}var n=/^(\d{4})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/;return function(n,i,o){var a,s,u="",l=[];if(i=i||"mediumDate",i=e.DATETIME_FORMATS[i]||i,w(n)&&(n=Po.test(n)?f(n):t(n)),x(n)&&(n=new Date(n)),!_(n)||!isFinite(n.getTime()))return n;for(;i;)s=jo.exec(i),s?(l=z(l,s,1),i=l.pop()):(l.push(i),i=null);var c=n.getTimezoneOffset();return o&&(c=G(o,c),n=K(n,o,!0)),r(l,function(t){a=Mo[t],u+=a?a(n,e.DATETIME_FORMATS,c):"''"===t?"'":t.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),u}}function ar(){return function(e,t){return m(t)&&(t=2),B(e,t)}}function sr(){return function(e,t,r){return t=Math.abs(Number(t))===1/0?Number(t):f(t),isNaN(t)?e:(x(e)&&(e=e.toString()),n(e)?(r=!r||isNaN(r)?0:f(r),r=r<0?Math.max(0,e.length+r):r,t>=0?ur(e,r,r+t):0===r?ur(e,t,e.length):ur(e,Math.max(0,r+t),r)):e)}}function ur(e,t,n){return w(e)?e.slice(t,n):zr.call(e,t,n)}function lr(e){function r(t){return t.map(function(t){var n=1,r=h;if(k(t))r=t;else if(w(t)&&("+"!=t.charAt(0)&&"-"!=t.charAt(0)||(n="-"==t.charAt(0)?-1:1,t=t.substring(1)),""!==t&&(r=e(t),r.constant))){var i=r();r=function(e){return e[i]}}return{get:r,descending:n}})}function i(e){switch(typeof e){case"number":case"boolean":case"string":return!0;default:return!1}}function o(e){return k(e.valueOf)&&(e=e.valueOf(),i(e))?e:v(e)&&(e=e.toString(),i(e))?e:e}function a(e,t){var n=typeof e;return null===e?(n="string",e="null"):"object"===n&&(e=o(e)),{value:e,type:n,index:t}}function s(e,t){var n=0,r=e.type,i=t.type;if(r===i){var o=e.value,a=t.value;"string"===r?(o=o.toLowerCase(),a=a.toLowerCase()):"object"===r&&(b(o)&&(o=e.index),b(a)&&(a=t.index)),o!==a&&(n=o<a?-1:1)}else n=r<i?-1:1;return n}return function(e,i,o,u){function l(e,t){return{value:e,tieBreaker:{value:t,type:"number",index:t},predicateValues:f.map(function(n){return a(n.get(e),t)})}}function c(e,t){for(var n=0,r=f.length;n<r;n++){var i=p(e.predicateValues[n],t.predicateValues[n]);if(i)return i*f[n].descending*d}return p(e.tieBreaker,t.tieBreaker)*d}if(null==e)return e;if(!n(e))throw t("orderBy")("notarray","Expected array but received: {0}",e);Kr(i)||(i=[i]),0===i.length&&(i=["+"]);var f=r(i),d=o?-1:1,p=k(u)?u:s,h=Array.prototype.map.call(e,l);return h.sort(c),e=h.map(function(e){return e.value})}}function cr(e){return k(e)&&(e={link:e}),e.restrict=e.restrict||"AC",g(e)}function fr(e,t){e.$name=t}function dr(e,t,n,i,o){var a=this,s=[];a.$error={},a.$$success={},a.$pending=void 0,a.$name=o(t.name||t.ngForm||"")(n),a.$dirty=!1,a.$pristine=!0,a.$valid=!0,a.$invalid=!1,a.$submitted=!1,a.$$parentForm=Io,a.$rollbackViewValue=function(){r(s,function(e){e.$rollbackViewValue()})},a.$commitViewValue=function(){r(s,function(e){e.$commitViewValue()})},a.$addControl=function(e){fe(e.$name,"input"),s.push(e),e.$name&&(a[e.$name]=e),e.$$parentForm=a},a.$$renameControl=function(e,t){var n=e.$name;a[n]===e&&delete a[n],a[t]=e,e.$name=t},a.$removeControl=function(e){e.$name&&a[e.$name]===e&&delete a[e.$name],r(a.$pending,function(t,n){a.$setValidity(n,null,e)}),r(a.$error,function(t,n){a.$setValidity(n,null,e)}),r(a.$$success,function(t,n){a.$setValidity(n,null,e)}),R(s,e),e.$$parentForm=Io},Cr({ctrl:this,$element:e,set:function(e,t,n){var r=e[t];if(r){var i=r.indexOf(n);i===-1&&r.push(n)}else e[t]=[n]},unset:function(e,t,n){var r=e[t];r&&(R(r,n),0===r.length&&delete e[t])},$animate:i}),a.$setDirty=function(){i.removeClass(e,wa),i.addClass(e,xa),a.$dirty=!0,a.$pristine=!1,a.$$parentForm.$setDirty()},a.$setPristine=function(){i.setClass(e,wa,xa+" "+Ro),a.$dirty=!1,a.$pristine=!0,a.$submitted=!1,r(s,function(e){e.$setPristine()})},a.$setUntouched=function(){r(s,function(e){e.$setUntouched()})},a.$setSubmitted=function(){i.addClass(e,Ro),a.$submitted=!0,a.$$parentForm.$setSubmitted()}}function pr(e){e.$formatters.push(function(t){return e.$isEmpty(t)?t:t.toString()})}function hr(e,t,n,r,i,o){gr(e,t,n,r,i,o),pr(r)}function gr(e,t,n,r,i,o){var a=Tr(t[0].type);if(!i.android){var s=!1;t.on("compositionstart",function(){s=!0}),t.on("compositionend",function(){s=!1,l()})}var u,l=function(e){if(u&&(o.defer.cancel(u),u=null),!s){var i=t.val(),l=e&&e.type;"password"===a||n.ngTrim&&"false"===n.ngTrim||(i=Zr(i)),(r.$viewValue!==i||""===i&&r.$$hasNativeValidators)&&r.$setViewValue(i,l)}};if(i.hasEvent("input"))t.on("input",l);else{var c=function(e,t,n){u||(u=o.defer(function(){u=null,t&&t.value===n||l(e)}))};t.on("keydown",function(e){var t=e.keyCode;91===t||15<t&&t<19||37<=t&&t<=40||c(e,this,this.value)}),i.hasEvent("paste")&&t.on("paste cut",c)}t.on("change",l),Jo[a]&&r.$$hasNativeValidators&&a===n.type&&t.on(Zo,function(e){if(!u){var t=this[jr],n=t.badInput,r=t.typeMismatch;u=o.defer(function(){u=null,t.badInput===n&&t.typeMismatch===r||l(e)})}}),r.$render=function(){var e=r.$isEmpty(r.$viewValue)?"":r.$viewValue;t.val()!==e&&t.val(e)}}function vr(e,t){if(_(e))return e;if(w(e)){Xo.lastIndex=0;var n=Xo.exec(e);if(n){var r=+n[1],i=+n[2],o=0,a=0,s=0,u=0,l=Qn(r),c=7*(i-1);return t&&(o=t.getHours(),a=t.getMinutes(),s=t.getSeconds(),u=t.getMilliseconds()),new Date(r,0,l.getDate()+c,o,a,s,u)}}return NaN}function mr(e,t){return function(n,i){var o,a;if(_(n))return n;if(w(n)){if('"'==n.charAt(0)&&'"'==n.charAt(n.length-1)&&(n=n.substring(1,n.length-1)),Lo.test(n))return new Date(n);if(e.lastIndex=0,o=e.exec(n))return o.shift(),a=i?{yyyy:i.getFullYear(),MM:i.getMonth()+1,dd:i.getDate(),HH:i.getHours(),mm:i.getMinutes(),ss:i.getSeconds(),sss:i.getMilliseconds()/1e3}:{yyyy:1970,MM:1,dd:1,HH:0,mm:0,ss:0,sss:0},r(o,function(e,n){n<t.length&&(a[t[n]]=+e)}),new Date(a.yyyy,a.MM-1,a.dd,a.HH,a.mm,a.ss||0,1e3*a.sss||0)}return NaN}}function $r(e,t,n,r){return function(i,o,a,s,u,l,c){function f(e){return e&&!(e.getTime&&e.getTime()!==e.getTime())}function d(e){return $(e)&&!_(e)?n(e)||void 0:e}br(i,o,a,s),gr(i,o,a,s,u,l);var p,h=s&&s.$options&&s.$options.timezone;if(s.$$parserName=e,s.$parsers.push(function(e){if(s.$isEmpty(e))return null;if(t.test(e)){var r=n(e,p);return h&&(r=K(r,h)),r}}),s.$formatters.push(function(e){if(e&&!_(e))throw Aa("datefmt","Expected `{0}` to be a date",e);return f(e)?(p=e,p&&h&&(p=K(p,h,!0)),c("date")(e,r,h)):(p=null,"")}),$(a.min)||a.ngMin){var g;s.$validators.min=function(e){return!f(e)||m(g)||n(e)>=g},a.$observe("min",function(e){g=d(e),s.$validate()})}if($(a.max)||a.ngMax){var v;s.$validators.max=function(e){return!f(e)||m(v)||n(e)<=v},a.$observe("max",function(e){v=d(e),s.$validate()})}}}function br(e,t,n,r){var i=t[0],o=r.$$hasNativeValidators=b(i.validity);o&&r.$parsers.push(function(e){var n=t.prop(jr)||{};return n.badInput||n.typeMismatch?void 0:e})}function yr(e,t,n,r,i,o){if(br(e,t,n,r),gr(e,t,n,r,i,o),r.$$parserName="number",r.$parsers.push(function(e){return r.$isEmpty(e)?null:Bo.test(e)?parseFloat(e):void 0}),r.$formatters.push(function(e){if(!r.$isEmpty(e)){if(!x(e))throw Aa("numfmt","Expected `{0}` to be a number",e);e=e.toString()}return e}),$(n.min)||n.ngMin){var a;r.$validators.min=function(e){return r.$isEmpty(e)||m(a)||e>=a},n.$observe("min",function(e){$(e)&&!x(e)&&(e=parseFloat(e)),a=x(e)&&!isNaN(e)?e:void 0,r.$validate()})}if($(n.max)||n.ngMax){var s;r.$validators.max=function(e){return r.$isEmpty(e)||m(s)||e<=s},n.$observe("max",function(e){$(e)&&!x(e)&&(e=parseFloat(e)),s=x(e)&&!isNaN(e)?e:void 0,r.$validate()})}}function wr(e,t,n,r,i,o){gr(e,t,n,r,i,o),pr(r),r.$$parserName="url",r.$validators.url=function(e,t){var n=e||t;return r.$isEmpty(n)||qo.test(n)}}function xr(e,t,n,r,i,o){gr(e,t,n,r,i,o),pr(r),r.$$parserName="email",r.$validators.email=function(e,t){var n=e||t;return r.$isEmpty(n)||Ho.test(n)}}function _r(e,t,n,r){m(n.name)&&t.attr("name",a());var i=function(e){t[0].checked&&r.$setViewValue(n.value,e&&e.type)};t.on("click",i),r.$render=function(){var e=n.value;t[0].checked=e==r.$viewValue},n.$observe("value",r.$render)}function kr(e,t,n,r,i){var o;if($(r)){if(o=e(r),!o.constant)throw Aa("constexpr","Expected constant expression for `{0}`, but saw `{1}`.",n,r);return o(t)}return i}function Sr(e,t,n,r,i,o,a,s){var u=kr(s,e,"ngTrueValue",n.ngTrueValue,!0),l=kr(s,e,"ngFalseValue",n.ngFalseValue,!1),c=function(e){r.$setViewValue(t[0].checked,e&&e.type)};t.on("click",c),r.$render=function(){t[0].checked=r.$viewValue},r.$isEmpty=function(e){return e===!1},r.$formatters.push(function(e){return V(e,u)}),r.$parsers.push(function(e){return e?u:l})}function Er(e,t){return e="ngClass"+e,["$animate",function(n){function i(e,t){var n=[];e:for(var r=0;r<e.length;r++){for(var i=e[r],o=0;o<t.length;o++)if(i==t[o])continue e;n.push(i)}return n}function o(e){var t=[];return Kr(e)?(r(e,function(e){t=t.concat(o(e))}),t):w(e)?e.split(" "):b(e)?(r(e,function(e,n){e&&(t=t.concat(n.split(" ")))}),t):e}return{restrict:"AC",link:function(a,s,u){function l(e){var t=f(e,1);u.$addClass(t)}function c(e){var t=f(e,-1);u.$removeClass(t)}function f(e,t){var n=s.data("$classCounts")||he(),i=[];return r(e,function(e){(t>0||n[e])&&(n[e]=(n[e]||0)+t,n[e]===+(t>0)&&i.push(e))}),s.data("$classCounts",n),i.join(" ")}function d(e,t){var r=i(t,e),o=i(e,t);r=f(r,1),o=f(o,-1),r&&r.length&&n.addClass(s,r),o&&o.length&&n.removeClass(s,o)}function p(e){if(t===!0||(1&a.$index)===t){var n=o(e||[]);if(h){if(!V(e,h)){var r=o(h);d(r,n)}}else l(n)}h=Kr(e)?e.map(function(e){return ve(e)}):ve(e)}var h;a.$watch(u[e],p,!0),u.$observe("class",function(t){p(a.$eval(u[e]))}),"ngClass"!==e&&a.$watch("$index",function(n,r){var i=1&n;if(i!==(1&r)){var s=o(a.$eval(u[e]));i===t?l(s):c(s)}})}}}]}function Cr(e){function t(e,t,s){m(t)?n("$pending",e,s):r("$pending",e,s),j(t)?t?(c(a.$error,e,s),l(a.$$success,e,s)):(l(a.$error,e,s),c(a.$$success,e,s)):(c(a.$error,e,s),c(a.$$success,e,s)),a.$pending?(i(Sa,!0),a.$valid=a.$invalid=void 0,o("",null)):(i(Sa,!1),a.$valid=Ar(a.$error),a.$invalid=!a.$valid,o("",a.$valid));var u;u=a.$pending&&a.$pending[e]?void 0:!a.$error[e]&&(!!a.$$success[e]||null),o(e,u),a.$$parentForm.$setValidity(e,u,a)}function n(e,t,n){a[e]||(a[e]={}),l(a[e],t,n)}function r(e,t,n){a[e]&&c(a[e],t,n),Ar(a[e])&&(a[e]=void 0)}function i(e,t){t&&!u[e]?(f.addClass(s,e),u[e]=!0):!t&&u[e]&&(f.removeClass(s,e),u[e]=!1)}function o(e,t){e=e?"-"+se(e,"-"):"",i(ba+e,t===!0),i(ya+e,t===!1)}var a=e.ctrl,s=e.$element,u={},l=e.set,c=e.unset,f=e.$animate;u[ya]=!(u[ba]=s.hasClass(ba)),a.$setValidity=t}function Ar(e){if(e)for(var t in e)if(e.hasOwnProperty(t))return!1;return!0}function Or(e){e[0].hasAttribute("selected")&&(e[0].selected=!0)}var Mr=/^\/(.+)\/([a-z]*)$/,jr="validity",Pr=Object.prototype.hasOwnProperty,Tr=function(e){return w(e)?e.toLowerCase():e},Dr=function(e){return w(e)?e.toUpperCase():e},Fr=function(e){return w(e)?e.replace(/[A-Z]/g,function(e){return String.fromCharCode(32|e.charCodeAt(0))}):e},Nr=function(e){return w(e)?e.replace(/[a-z]/g,function(e){return String.fromCharCode(e.charCodeAt(0)&-33)}):e};"i"!=="I".toLowerCase()&&(Tr=Fr,Dr=Nr);var Ir,Rr,Ur,Vr,zr=[].slice,Lr=[].splice,qr=[].push,Hr=Object.prototype.toString,Br=Object.getPrototypeOf,Wr=t("ng"),Gr=e.angular||(e.angular={}),Xr=0;Ir=e.document.documentMode,p.$inject=[],h.$inject=[];var Kr=Array.isArray,Yr=/^\[object (?:Uint8|Uint8Clamped|Uint16|Uint32|Int8|Int16|Int32|Float32|Float64)Array\]$/,Zr=function(e){return w(e)?e.trim():e;
|
6 |
-
},Jr=function(e){return e.replace(/([-()\[\]{}+?*.$\^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08")},Qr=function(){function t(){try{return new Function(""),!1}catch(e){return!0}}if(!$(Qr.rules)){var n=e.document.querySelector("[ng-csp]")||e.document.querySelector("[data-ng-csp]");if(n){var r=n.getAttribute("ng-csp")||n.getAttribute("data-ng-csp");Qr.rules={noUnsafeEval:!r||r.indexOf("no-unsafe-eval")!==-1,noInlineStyle:!r||r.indexOf("no-inline-style")!==-1}}else Qr.rules={noUnsafeEval:t(),noInlineStyle:!1}}return Qr.rules},ei=function(){if($(ei.name_))return ei.name_;var t,n,r,i,o=ni.length;for(n=0;n<o;++n)if(r=ni[n],t=e.document.querySelector("["+r.replace(":","\\:")+"jq]")){i=t.getAttribute(r+"jq");break}return ei.name_=i},ti=/:/g,ni=["ng-","data-ng-","ng:","x-ng-"],ri=/[A-Z]/g,ii=!1,oi=1,ai=2,si=3,ui=8,li=9,ci=11,fi={full:"1.5.8",major:1,minor:5,dot:8,codeName:"arbitrary-fallbacks"};Oe.expando="ng339";var di=Oe.cache={},pi=1,hi=function(e,t,n){e.addEventListener(t,n,!1)},gi=function(e,t,n){e.removeEventListener(t,n,!1)};Oe._data=function(e){return this.cache[e[this.expando]]||{}};var vi=/([\:\-\_]+(.))/g,mi=/^moz([A-Z])/,$i={mouseleave:"mouseout",mouseenter:"mouseover"},bi=t("jqLite"),yi=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,wi=/<|&#?\w+;/,xi=/<([\w:-]+)/,_i=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,ki={option:[1,'<select multiple="multiple">',"</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ki.optgroup=ki.option,ki.tbody=ki.tfoot=ki.colgroup=ki.caption=ki.thead,ki.th=ki.td;var Si=e.Node.prototype.contains||function(e){return!!(16&this.compareDocumentPosition(e))},Ei=Oe.prototype={ready:function(t){function n(){r||(r=!0,t())}var r=!1;"complete"===e.document.readyState?e.setTimeout(n):(this.on("DOMContentLoaded",n),Oe(e).on("load",n))},toString:function(){var e=[];return r(this,function(t){e.push(""+t)}),"["+e.join(", ")+"]"},eq:function(e){return Rr(e>=0?this[e]:this[this.length+e])},length:0,push:qr,sort:[].sort,splice:[].splice},Ci={};r("multiple,selected,checked,disabled,readOnly,required,open".split(","),function(e){Ci[Tr(e)]=e});var Ai={};r("input,select,option,textarea,button,form,details".split(","),function(e){Ai[e]=!0});var Oi={ngMinlength:"minlength",ngMaxlength:"maxlength",ngMin:"min",ngMax:"max",ngPattern:"pattern"};r({data:Fe,removeData:Te,hasData:ke,cleanData:Se},function(e,t){Oe[t]=e}),r({data:Fe,inheritedData:ze,scope:function(e){return Rr.data(e,"$scope")||ze(e.parentNode||e,["$isolateScope","$scope"])},isolateScope:function(e){return Rr.data(e,"$isolateScope")||Rr.data(e,"$isolateScopeNoTemplate")},controller:Ve,injector:function(e){return ze(e,"$injector")},removeAttr:function(e,t){e.removeAttribute(t)},hasClass:Ne,css:function(e,t,n){return t=we(t),$(n)?void(e.style[t]=n):e.style[t]},attr:function(e,t,n){var r=e.nodeType;if(r!==si&&r!==ai&&r!==ui){var i=Tr(t);if(Ci[i]){if(!$(n))return e[t]||(e.attributes.getNamedItem(t)||p).specified?i:void 0;n?(e[t]=!0,e.setAttribute(t,i)):(e[t]=!1,e.removeAttribute(i))}else if($(n))e.setAttribute(t,n);else if(e.getAttribute){var o=e.getAttribute(t,2);return null===o?void 0:o}}},prop:function(e,t,n){return $(n)?void(e[t]=n):e[t]},text:function(){function e(e,t){if(m(t)){var n=e.nodeType;return n===oi||n===si?e.textContent:""}e.textContent=t}return e.$dv="",e}(),val:function(e,t){if(m(t)){if(e.multiple&&"select"===I(e)){var n=[];return r(e.options,function(e){e.selected&&n.push(e.value||e.text)}),0===n.length?null:n}return e.value}e.value=t},html:function(e,t){return m(t)?e.innerHTML:(je(e,!0),void(e.innerHTML=t))},empty:Le},function(e,t){Oe.prototype[t]=function(t,n){var r,i,o=this.length;if(e!==Le&&m(2==e.length&&e!==Ne&&e!==Ve?t:n)){if(b(t)){for(r=0;r<o;r++)if(e===Fe)e(this[r],t);else for(i in t)e(this[r],i,t[i]);return this}for(var a=e.$dv,s=m(a)?Math.min(o,1):o,u=0;u<s;u++){var l=e(this[u],t,n);a=a?a+l:l}return a}for(r=0;r<o;r++)e(this[r],t,n);return this}}),r({removeData:Te,on:function(e,t,n,r){if($(r))throw bi("onargs","jqLite#on() does not support the `selector` or `eventData` parameters");if(_e(e)){var i=De(e,!0),o=i.events,a=i.handle;a||(a=i.handle=Ge(e,o));for(var s=t.indexOf(" ")>=0?t.split(" "):[t],u=s.length,l=function(t,r,i){var s=o[t];s||(s=o[t]=[],s.specialHandlerWrapper=r,"$destroy"===t||i||hi(e,t,a)),s.push(n)};u--;)t=s[u],$i[t]?(l($i[t],Ke),l(t,void 0,!0)):l(t)}},off:Pe,one:function(e,t,n){e=Rr(e),e.on(t,function r(){e.off(t,n),e.off(t,r)}),e.on(t,n)},replaceWith:function(e,t){var n,i=e.parentNode;je(e),r(new Oe(t),function(t){n?i.insertBefore(t,n.nextSibling):i.replaceChild(t,e),n=t})},children:function(e){var t=[];return r(e.childNodes,function(e){e.nodeType===oi&&t.push(e)}),t},contents:function(e){return e.contentDocument||e.childNodes||[]},append:function(e,t){var n=e.nodeType;if(n===oi||n===ci){t=new Oe(t);for(var r=0,i=t.length;r<i;r++){var o=t[r];e.appendChild(o)}}},prepend:function(e,t){if(e.nodeType===oi){var n=e.firstChild;r(new Oe(t),function(t){e.insertBefore(t,n)})}},wrap:function(e,t){Ae(e,Rr(t).eq(0).clone()[0])},remove:qe,detach:function(e){qe(e,!0)},after:function(e,t){var n=e,r=e.parentNode;t=new Oe(t);for(var i=0,o=t.length;i<o;i++){var a=t[i];r.insertBefore(a,n.nextSibling),n=a}},addClass:Re,removeClass:Ie,toggleClass:function(e,t,n){t&&r(t.split(" "),function(t){var r=n;m(r)&&(r=!Ne(e,t)),(r?Re:Ie)(e,t)})},parent:function(e){var t=e.parentNode;return t&&t.nodeType!==ci?t:null},next:function(e){return e.nextElementSibling},find:function(e,t){return e.getElementsByTagName?e.getElementsByTagName(t):[]},clone:Me,triggerHandler:function(e,t,n){var i,o,a,s=t.type||t,u=De(e),c=u&&u.events,f=c&&c[s];f&&(i={preventDefault:function(){this.defaultPrevented=!0},isDefaultPrevented:function(){return this.defaultPrevented===!0},stopImmediatePropagation:function(){this.immediatePropagationStopped=!0},isImmediatePropagationStopped:function(){return this.immediatePropagationStopped===!0},stopPropagation:p,type:s,target:e},t.type&&(i=l(i,t)),o=ve(f),a=n?[i].concat(n):[i],r(o,function(t){i.isImmediatePropagationStopped()||t.apply(e,a)}))}},function(e,t){Oe.prototype[t]=function(t,n,r){for(var i,o=0,a=this.length;o<a;o++)m(i)?(i=e(this[o],t,n,r),$(i)&&(i=Rr(i))):Ue(i,e(this[o],t,n,r));return $(i)?i:this},Oe.prototype.bind=Oe.prototype.on,Oe.prototype.unbind=Oe.prototype.off}),Je.prototype={put:function(e,t){this[Ze(e,this.nextUid)]=t},get:function(e){return this[Ze(e,this.nextUid)]},remove:function(e){var t=this[e=Ze(e,this.nextUid)];return delete this[e],t}};var Mi=[function(){this.$get=[function(){return Je}]}],ji=/^([^\(]+?)=>/,Pi=/^[^\(]*\(\s*([^\)]*)\)/m,Ti=/,/,Di=/^\s*(_?)(\S+?)\1\s*$/,Fi=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/gm,Ni=t("$injector");rt.$$annotate=nt;var Ii=t("$animate"),Ri=1,Ui="ng-animate",Vi=function(){this.$get=p},zi=function(){var e=new Je,t=[];this.$get=["$$AnimateRunner","$rootScope",function(n,i){function o(e,t,n){var i=!1;return t&&(t=w(t)?t.split(" "):Kr(t)?t:[],r(t,function(t){t&&(i=!0,e[t]=n)})),i}function a(){r(t,function(t){var n=e.get(t);if(n){var i=st(t.attr("class")),o="",a="";r(n,function(e,t){var n=!!i[t];e!==n&&(e?o+=(o.length?" ":"")+t:a+=(a.length?" ":"")+t)}),r(t,function(e){o&&Re(e,o),a&&Ie(e,a)}),e.remove(t)}}),t.length=0}function s(n,r,s){var u=e.get(n)||{},l=o(u,r,!0),c=o(u,s,!1);(l||c)&&(e.put(n,u),t.push(n),1===t.length&&i.$$postDigest(a))}return{enabled:p,on:p,off:p,pin:p,push:function(e,t,r,i){i&&i(),r=r||{},r.from&&e.css(r.from),r.to&&e.css(r.to),(r.addClass||r.removeClass)&&s(e,r.addClass,r.removeClass);var o=new n;return o.complete(),o}}}]},Li=["$provide",function(e){var t=this;this.$$registeredAnimations=Object.create(null),this.register=function(n,r){if(n&&"."!==n.charAt(0))throw Ii("notcsel","Expecting class selector starting with '.' got '{0}'.",n);var i=n+"-animation";t.$$registeredAnimations[n.substr(1)]=i,e.factory(i,r)},this.classNameFilter=function(e){if(1===arguments.length&&(this.$$classNameFilter=e instanceof RegExp?e:null,this.$$classNameFilter)){var t=new RegExp("(\\s+|\\/)"+Ui+"(\\s+|\\/)");if(t.test(this.$$classNameFilter.toString()))throw Ii("nongcls",'$animateProvider.classNameFilter(regex) prohibits accepting a regex value which matches/contains the "{0}" CSS class.',Ui)}return this.$$classNameFilter},this.$get=["$$animateQueue",function(e){function t(e,t,n){if(n){var r=at(n);!r||r.parentNode||r.previousElementSibling||(n=null)}n?n.after(e):t.prepend(e)}return{on:e.on,off:e.off,pin:e.pin,enabled:e.enabled,cancel:function(e){e.end&&e.end()},enter:function(n,r,i,o){return r=r&&Rr(r),i=i&&Rr(i),r=r||i.parent(),t(n,r,i),e.push(n,"enter",ut(o))},move:function(n,r,i,o){return r=r&&Rr(r),i=i&&Rr(i),r=r||i.parent(),t(n,r,i),e.push(n,"move",ut(o))},leave:function(t,n){return e.push(t,"leave",ut(n),function(){t.remove()})},addClass:function(t,n,r){return r=ut(r),r.addClass=ot(r.addclass,n),e.push(t,"addClass",r)},removeClass:function(t,n,r){return r=ut(r),r.removeClass=ot(r.removeClass,n),e.push(t,"removeClass",r)},setClass:function(t,n,r,i){return i=ut(i),i.addClass=ot(i.addClass,n),i.removeClass=ot(i.removeClass,r),e.push(t,"setClass",i)},animate:function(t,n,r,i,o){return o=ut(o),o.from=o.from?l(o.from,n):n,o.to=o.to?l(o.to,r):r,i=i||"ng-inline-animate",o.tempClasses=ot(o.tempClasses,i),e.push(t,"animate",o)}}}]}],qi=function(){this.$get=["$$rAF",function(e){function t(t){n.push(t),n.length>1||e(function(){for(var e=0;e<n.length;e++)n[e]();n=[]})}var n=[];return function(){var e=!1;return t(function(){e=!0}),function(n){e?n():t(n)}}}]},Hi=function(){this.$get=["$q","$sniffer","$$animateAsyncRun","$document","$timeout",function(e,t,n,i,o){function a(e){this.setHost(e);var t=n(),r=function(e){o(e,0,!1)};this._doneCallbacks=[],this._tick=function(e){var n=i[0];n&&n.hidden?r(e):t(e)},this._state=0}var s=0,u=1,l=2;return a.chain=function(e,t){function n(){return r===e.length?void t(!0):void e[r](function(e){return e===!1?void t(!1):(r++,void n())})}var r=0;n()},a.all=function(e,t){function n(n){o=o&&n,++i===e.length&&t(o)}var i=0,o=!0;r(e,function(e){e.done(n)})},a.prototype={setHost:function(e){this.host=e||{}},done:function(e){this._state===l?e():this._doneCallbacks.push(e)},progress:p,getPromise:function(){if(!this.promise){var t=this;this.promise=e(function(e,n){t.done(function(t){t===!1?n():e()})})}return this.promise},then:function(e,t){return this.getPromise().then(e,t)},"catch":function(e){return this.getPromise()["catch"](e)},"finally":function(e){return this.getPromise()["finally"](e)},pause:function(){this.host.pause&&this.host.pause()},resume:function(){this.host.resume&&this.host.resume()},end:function(){this.host.end&&this.host.end(),this._resolve(!0)},cancel:function(){this.host.cancel&&this.host.cancel(),this._resolve(!1)},complete:function(e){var t=this;t._state===s&&(t._state=u,t._tick(function(){t._resolve(e)}))},_resolve:function(e){this._state!==l&&(r(this._doneCallbacks,function(t){t(e)}),this._doneCallbacks.length=0,this._state=l)}},a}]},Bi=function(){this.$get=["$$rAF","$q","$$AnimateRunner",function(e,t,n){return function(t,r){function i(){return e(function(){o(),s||u.complete(),s=!0}),u}function o(){a.addClass&&(t.addClass(a.addClass),a.addClass=null),a.removeClass&&(t.removeClass(a.removeClass),a.removeClass=null),a.to&&(t.css(a.to),a.to=null)}var a=r||{};a.$$prepared||(a=U(a)),a.cleanupStyles&&(a.from=a.to=null),a.from&&(t.css(a.from),a.from=null);var s,u=new n;return{start:i,end:i}}}]},Wi=t("$compile"),Gi=new pt;ht.$inject=["$provide","$$sanitizeUriProvider"],gt.prototype.isFirstChange=function(){return this.previousValue===Gi};var Xi=/^((?:x|data)[\:\-_])/i,Ki=t("$controller"),Yi=/^(\S+)(\s+as\s+([\w$]+))?$/,Zi=function(){this.$get=["$document",function(e){return function(t){return t?!t.nodeType&&t instanceof Rr&&(t=t[0]):t=e[0].body,t.offsetWidth+1}}]},Ji="application/json",Qi={"Content-Type":Ji+";charset=utf-8"},eo=/^\[|^\{(?!\{)/,to={"[":/]$/,"{":/}$/},no=/^\)\]\}',?\n/,ro=t("$http"),io=function(e){return function(){throw ro("legacy","The method `{0}` on the promise returned from `$http` has been disabled.",e)}},oo=Gr.$interpolateMinErr=t("$interpolate");oo.throwNoconcat=function(e){throw oo("noconcat","Error while interpolating: {0}\nStrict Contextual Escaping disallows interpolations that concatenate multiple expressions when a trusted value is required. See http://docs.angularjs.org/api/ng.$sce",e)},oo.interr=function(e,t){return oo("interr","Can't interpolate: {0}\n{1}",e,t.toString())};var ao=function(){this.$get=["$window",function(e){function t(e){var t=function(e){t.data=e,t.called=!0};return t.id=e,t}var n=e.angular.callbacks,r={};return{createCallback:function(e){var i="_"+(n.$$counter++).toString(36),o="angular.callbacks."+i,a=t(i);return r[o]=n[i]=a,o},wasCalled:function(e){return r[e].called},getResponse:function(e){return r[e].data},removeCallback:function(e){var t=r[e];delete n[t.id],delete r[e]}}}]},so=/^([^\?#]*)(\?([^#]*))?(#(.*))?$/,uo={http:80,https:443,ftp:21},lo=t("$location"),co={$$absUrl:"",$$html5:!1,$$replace:!1,absUrl:Yt("$$absUrl"),url:function(e){if(m(e))return this.$$url;var t=so.exec(e);return(t[1]||""===e)&&this.path(decodeURIComponent(t[1])),(t[2]||t[1]||""===e)&&this.search(t[3]||""),this.hash(t[5]||""),this},protocol:Yt("$$protocol"),host:Yt("$$host"),port:Yt("$$port"),path:Zt("$$path",function(e){return e=null!==e?e.toString():"","/"==e.charAt(0)?e:"/"+e}),search:function(e,t){switch(arguments.length){case 0:return this.$$search;case 1:if(w(e)||x(e))e=e.toString(),this.$$search=J(e);else{if(!b(e))throw lo("isrcharg","The first argument of the `$location#search()` call must be a string or an object.");e=U(e,{}),r(e,function(t,n){null==t&&delete e[n]}),this.$$search=e}break;default:m(t)||null===t?delete this.$$search[e]:this.$$search[e]=t}return this.$$compose(),this},hash:Zt("$$hash",function(e){return null!==e?e.toString():""}),replace:function(){return this.$$replace=!0,this}};r([Kt,Xt,Gt],function(e){e.prototype=Object.create(co),e.prototype.state=function(t){if(!arguments.length)return this.$$state;if(e!==Gt||!this.$$html5)throw lo("nostate","History API state support is available only in HTML5 mode and only in browsers supporting HTML5 History API");return this.$$state=m(t)?null:t,this}});var fo=t("$parse"),po=Function.prototype.call,ho=Function.prototype.apply,go=Function.prototype.bind,vo=he();r("+ - * / % === !== == != < > <= >= && || ! = |".split(" "),function(e){vo[e]=!0});var mo={n:"\n",f:"\f",r:"\r",t:"\t",v:"\x0B","'":"'",'"':'"'},$o=function(e){this.options=e};$o.prototype={constructor:$o,lex:function(e){for(this.text=e,this.index=0,this.tokens=[];this.index<this.text.length;){var t=this.text.charAt(this.index);if('"'===t||"'"===t)this.readString(t);else if(this.isNumber(t)||"."===t&&this.isNumber(this.peek()))this.readNumber();else if(this.isIdentifierStart(this.peekMultichar()))this.readIdent();else if(this.is(t,"(){}[].,;:?"))this.tokens.push({index:this.index,text:t}),this.index++;else if(this.isWhitespace(t))this.index++;else{var n=t+this.peek(),r=n+this.peek(2),i=vo[t],o=vo[n],a=vo[r];if(i||o||a){var s=a?r:o?n:t;this.tokens.push({index:this.index,text:s,operator:!0}),this.index+=s.length}else this.throwError("Unexpected next character ",this.index,this.index+1)}}return this.tokens},is:function(e,t){return t.indexOf(e)!==-1},peek:function(e){var t=e||1;return this.index+t<this.text.length&&this.text.charAt(this.index+t)},isNumber:function(e){return"0"<=e&&e<="9"&&"string"==typeof e},isWhitespace:function(e){return" "===e||"\r"===e||"\t"===e||"\n"===e||"\x0B"===e||" "===e},isIdentifierStart:function(e){return this.options.isIdentifierStart?this.options.isIdentifierStart(e,this.codePointAt(e)):this.isValidIdentifierStart(e)},isValidIdentifierStart:function(e){return"a"<=e&&e<="z"||"A"<=e&&e<="Z"||"_"===e||"$"===e},isIdentifierContinue:function(e){return this.options.isIdentifierContinue?this.options.isIdentifierContinue(e,this.codePointAt(e)):this.isValidIdentifierContinue(e)},isValidIdentifierContinue:function(e,t){return this.isValidIdentifierStart(e,t)||this.isNumber(e)},codePointAt:function(e){return 1===e.length?e.charCodeAt(0):(e.charCodeAt(0)<<10)+e.charCodeAt(1)-56613888},peekMultichar:function(){var e=this.text.charAt(this.index),t=this.peek();if(!t)return e;var n=e.charCodeAt(0),r=t.charCodeAt(0);return n>=55296&&n<=56319&&r>=56320&&r<=57343?e+t:e},isExpOperator:function(e){return"-"===e||"+"===e||this.isNumber(e)},throwError:function(e,t,n){n=n||this.index;var r=$(t)?"s "+t+"-"+this.index+" ["+this.text.substring(t,n)+"]":" "+n;throw fo("lexerr","Lexer Error: {0} at column{1} in expression [{2}].",e,r,this.text)},readNumber:function(){for(var e="",t=this.index;this.index<this.text.length;){var n=Tr(this.text.charAt(this.index));if("."==n||this.isNumber(n))e+=n;else{var r=this.peek();if("e"==n&&this.isExpOperator(r))e+=n;else if(this.isExpOperator(n)&&r&&this.isNumber(r)&&"e"==e.charAt(e.length-1))e+=n;else{if(!this.isExpOperator(n)||r&&this.isNumber(r)||"e"!=e.charAt(e.length-1))break;this.throwError("Invalid exponent")}}this.index++}this.tokens.push({index:t,text:e,constant:!0,value:Number(e)})},readIdent:function(){var e=this.index;for(this.index+=this.peekMultichar().length;this.index<this.text.length;){var t=this.peekMultichar();if(!this.isIdentifierContinue(t))break;this.index+=t.length}this.tokens.push({index:e,text:this.text.slice(e,this.index),identifier:!0})},readString:function(e){var t=this.index;this.index++;for(var n="",r=e,i=!1;this.index<this.text.length;){var o=this.text.charAt(this.index);if(r+=o,i){if("u"===o){var a=this.text.substring(this.index+1,this.index+5);a.match(/[\da-f]{4}/i)||this.throwError("Invalid unicode escape [\\u"+a+"]"),this.index+=4,n+=String.fromCharCode(parseInt(a,16))}else{var s=mo[o];n+=s||o}i=!1}else if("\\"===o)i=!0;else{if(o===e)return this.index++,void this.tokens.push({index:t,text:r,constant:!0,value:n});n+=o}this.index++}this.throwError("Unterminated quote",t)}};var bo=function(e,t){this.lexer=e,this.options=t};bo.Program="Program",bo.ExpressionStatement="ExpressionStatement",bo.AssignmentExpression="AssignmentExpression",bo.ConditionalExpression="ConditionalExpression",bo.LogicalExpression="LogicalExpression",bo.BinaryExpression="BinaryExpression",bo.UnaryExpression="UnaryExpression",bo.CallExpression="CallExpression",bo.MemberExpression="MemberExpression",bo.Identifier="Identifier",bo.Literal="Literal",bo.ArrayExpression="ArrayExpression",bo.Property="Property",bo.ObjectExpression="ObjectExpression",bo.ThisExpression="ThisExpression",bo.LocalsExpression="LocalsExpression",bo.NGValueParameter="NGValueParameter",bo.prototype={ast:function(e){this.text=e,this.tokens=this.lexer.lex(e);var t=this.program();return 0!==this.tokens.length&&this.throwError("is an unexpected token",this.tokens[0]),t},program:function(){for(var e=[];;)if(this.tokens.length>0&&!this.peek("}",")",";","]")&&e.push(this.expressionStatement()),!this.expect(";"))return{type:bo.Program,body:e}},expressionStatement:function(){return{type:bo.ExpressionStatement,expression:this.filterChain()}},filterChain:function(){for(var e,t=this.expression();e=this.expect("|");)t=this.filter(t);return t},expression:function(){return this.assignment()},assignment:function(){var e=this.ternary();return this.expect("=")&&(e={type:bo.AssignmentExpression,left:e,right:this.assignment(),operator:"="}),e},ternary:function(){var e,t,n=this.logicalOR();return this.expect("?")&&(e=this.expression(),this.consume(":"))?(t=this.expression(),{type:bo.ConditionalExpression,test:n,alternate:e,consequent:t}):n},logicalOR:function(){for(var e=this.logicalAND();this.expect("||");)e={type:bo.LogicalExpression,operator:"||",left:e,right:this.logicalAND()};return e},logicalAND:function(){for(var e=this.equality();this.expect("&&");)e={type:bo.LogicalExpression,operator:"&&",left:e,right:this.equality()};return e},equality:function(){for(var e,t=this.relational();e=this.expect("==","!=","===","!==");)t={type:bo.BinaryExpression,operator:e.text,left:t,right:this.relational()};return t},relational:function(){for(var e,t=this.additive();e=this.expect("<",">","<=",">=");)t={type:bo.BinaryExpression,operator:e.text,left:t,right:this.additive()};return t},additive:function(){for(var e,t=this.multiplicative();e=this.expect("+","-");)t={type:bo.BinaryExpression,operator:e.text,left:t,right:this.multiplicative()};return t},multiplicative:function(){for(var e,t=this.unary();e=this.expect("*","/","%");)t={type:bo.BinaryExpression,operator:e.text,left:t,right:this.unary()};return t},unary:function(){var e;return(e=this.expect("+","-","!"))?{type:bo.UnaryExpression,operator:e.text,prefix:!0,argument:this.unary()}:this.primary()},primary:function(){var e;this.expect("(")?(e=this.filterChain(),this.consume(")")):this.expect("[")?e=this.arrayDeclaration():this.expect("{")?e=this.object():this.selfReferential.hasOwnProperty(this.peek().text)?e=U(this.selfReferential[this.consume().text]):this.options.literals.hasOwnProperty(this.peek().text)?e={type:bo.Literal,value:this.options.literals[this.consume().text]}:this.peek().identifier?e=this.identifier():this.peek().constant?e=this.constant():this.throwError("not a primary expression",this.peek());for(var t;t=this.expect("(","[",".");)"("===t.text?(e={type:bo.CallExpression,callee:e,arguments:this.parseArguments()},this.consume(")")):"["===t.text?(e={type:bo.MemberExpression,object:e,property:this.expression(),computed:!0},this.consume("]")):"."===t.text?e={type:bo.MemberExpression,object:e,property:this.identifier(),computed:!1}:this.throwError("IMPOSSIBLE");return e},filter:function(e){for(var t=[e],n={type:bo.CallExpression,callee:this.identifier(),arguments:t,filter:!0};this.expect(":");)t.push(this.expression());return n},parseArguments:function(){var e=[];if(")"!==this.peekToken().text)do e.push(this.filterChain());while(this.expect(","));return e},identifier:function(){var e=this.consume();return e.identifier||this.throwError("is not a valid identifier",e),{type:bo.Identifier,name:e.text}},constant:function(){return{type:bo.Literal,value:this.consume().value}},arrayDeclaration:function(){var e=[];if("]"!==this.peekToken().text)do{if(this.peek("]"))break;e.push(this.expression())}while(this.expect(","));return this.consume("]"),{type:bo.ArrayExpression,elements:e}},object:function(){var e,t=[];if("}"!==this.peekToken().text)do{if(this.peek("}"))break;e={type:bo.Property,kind:"init"},this.peek().constant?(e.key=this.constant(),e.computed=!1,this.consume(":"),e.value=this.expression()):this.peek().identifier?(e.key=this.identifier(),e.computed=!1,this.peek(":")?(this.consume(":"),e.value=this.expression()):e.value=e.key):this.peek("[")?(this.consume("["),e.key=this.expression(),this.consume("]"),e.computed=!0,this.consume(":"),e.value=this.expression()):this.throwError("invalid key",this.peek()),t.push(e)}while(this.expect(","));return this.consume("}"),{type:bo.ObjectExpression,properties:t}},throwError:function(e,t){throw fo("syntax","Syntax Error: Token '{0}' {1} at column {2} of the expression [{3}] starting at [{4}].",t.text,e,t.index+1,this.text,this.text.substring(t.index))},consume:function(e){if(0===this.tokens.length)throw fo("ueoe","Unexpected end of expression: {0}",this.text);var t=this.expect(e);return t||this.throwError("is unexpected, expecting ["+e+"]",this.peek()),t},peekToken:function(){if(0===this.tokens.length)throw fo("ueoe","Unexpected end of expression: {0}",this.text);return this.tokens[0]},peek:function(e,t,n,r){return this.peekAhead(0,e,t,n,r)},peekAhead:function(e,t,n,r,i){if(this.tokens.length>e){var o=this.tokens[e],a=o.text;if(a===t||a===n||a===r||a===i||!t&&!n&&!r&&!i)return o}return!1},expect:function(e,t,n,r){var i=this.peek(e,t,n,r);return!!i&&(this.tokens.shift(),i)},selfReferential:{"this":{type:bo.ThisExpression},$locals:{type:bo.LocalsExpression}}},gn.prototype={compile:function(e,t){var n=this,i=this.astBuilder.ast(e);this.state={nextId:0,filters:{},expensiveChecks:t,fn:{vars:[],body:[],own:{}},assign:{vars:[],body:[],own:{}},inputs:[]},ln(i,n.$filter);var o,a="";if(this.stage="assign",o=dn(i)){this.state.computing="assign";var s=this.nextId();this.recurse(o,s),this.return_(s),a="fn.assign="+this.generateFunction("assign","s,v,l")}var u=cn(i.body);n.stage="inputs",r(u,function(e,t){var r="fn"+t;n.state[r]={vars:[],body:[],own:{}},n.state.computing=r;var i=n.nextId();n.recurse(e,i),n.return_(i),n.state.inputs.push(r),e.watchId=t}),this.state.computing="fn",this.stage="main",this.recurse(i);var l='"'+this.USE+" "+this.STRICT+'";\n'+this.filterPrefix()+"var fn="+this.generateFunction("fn","s,l,a,i")+a+this.watchFns()+"return fn;",c=new Function("$filter","ensureSafeMemberName","ensureSafeObject","ensureSafeFunction","getStringValue","ensureSafeAssignContext","ifDefined","plus","text",l)(this.$filter,en,nn,rn,tn,on,an,sn,e);return this.state=this.stage=void 0,c.literal=pn(i),c.constant=hn(i),c},USE:"use",STRICT:"strict",watchFns:function(){var e=[],t=this.state.inputs,n=this;return r(t,function(t){e.push("var "+t+"="+n.generateFunction(t,"s"))}),t.length&&e.push("fn.inputs=["+t.join(",")+"];"),e.join("")},generateFunction:function(e,t){return"function("+t+"){"+this.varsPrefix(e)+this.body(e)+"};"},filterPrefix:function(){var e=[],t=this;return r(this.state.filters,function(n,r){e.push(n+"=$filter("+t.escape(r)+")")}),e.length?"var "+e.join(",")+";":""},varsPrefix:function(e){return this.state[e].vars.length?"var "+this.state[e].vars.join(",")+";":""},body:function(e){return this.state[e].body.join("")},recurse:function(e,t,n,i,o,a){var s,u,l,c,f,d=this;if(i=i||p,!a&&$(e.watchId))return t=t||this.nextId(),void this.if_("i",this.lazyAssign(t,this.computedMember("i",e.watchId)),this.lazyRecurse(e,t,n,i,o,!0));switch(e.type){case bo.Program:r(e.body,function(t,n){d.recurse(t.expression,void 0,void 0,function(e){u=e}),n!==e.body.length-1?d.current().body.push(u,";"):d.return_(u)});break;case bo.Literal:c=this.escape(e.value),this.assign(t,c),i(c);break;case bo.UnaryExpression:this.recurse(e.argument,void 0,void 0,function(e){u=e}),c=e.operator+"("+this.ifDefined(u,0)+")",this.assign(t,c),i(c);break;case bo.BinaryExpression:this.recurse(e.left,void 0,void 0,function(e){s=e}),this.recurse(e.right,void 0,void 0,function(e){u=e}),c="+"===e.operator?this.plus(s,u):"-"===e.operator?this.ifDefined(s,0)+e.operator+this.ifDefined(u,0):"("+s+")"+e.operator+"("+u+")",this.assign(t,c),i(c);break;case bo.LogicalExpression:t=t||this.nextId(),d.recurse(e.left,t),d.if_("&&"===e.operator?t:d.not(t),d.lazyRecurse(e.right,t)),i(t);break;case bo.ConditionalExpression:t=t||this.nextId(),d.recurse(e.test,t),d.if_(t,d.lazyRecurse(e.alternate,t),d.lazyRecurse(e.consequent,t)),i(t);break;case bo.Identifier:t=t||this.nextId(),n&&(n.context="inputs"===d.stage?"s":this.assign(this.nextId(),this.getHasOwnProperty("l",e.name)+"?l:s"),n.computed=!1,n.name=e.name),en(e.name),d.if_("inputs"===d.stage||d.not(d.getHasOwnProperty("l",e.name)),function(){d.if_("inputs"===d.stage||"s",function(){o&&1!==o&&d.if_(d.not(d.nonComputedMember("s",e.name)),d.lazyAssign(d.nonComputedMember("s",e.name),"{}")),d.assign(t,d.nonComputedMember("s",e.name))})},t&&d.lazyAssign(t,d.nonComputedMember("l",e.name))),(d.state.expensiveChecks||mn(e.name))&&d.addEnsureSafeObject(t),i(t);break;case bo.MemberExpression:s=n&&(n.context=this.nextId())||this.nextId(),t=t||this.nextId(),d.recurse(e.object,s,void 0,function(){d.if_(d.notNull(s),function(){o&&1!==o&&d.addEnsureSafeAssignContext(s),e.computed?(u=d.nextId(),d.recurse(e.property,u),d.getStringValue(u),d.addEnsureSafeMemberName(u),o&&1!==o&&d.if_(d.not(d.computedMember(s,u)),d.lazyAssign(d.computedMember(s,u),"{}")),c=d.ensureSafeObject(d.computedMember(s,u)),d.assign(t,c),n&&(n.computed=!0,n.name=u)):(en(e.property.name),o&&1!==o&&d.if_(d.not(d.nonComputedMember(s,e.property.name)),d.lazyAssign(d.nonComputedMember(s,e.property.name),"{}")),c=d.nonComputedMember(s,e.property.name),(d.state.expensiveChecks||mn(e.property.name))&&(c=d.ensureSafeObject(c)),d.assign(t,c),n&&(n.computed=!1,n.name=e.property.name))},function(){d.assign(t,"undefined")}),i(t)},!!o);break;case bo.CallExpression:t=t||this.nextId(),e.filter?(u=d.filter(e.callee.name),l=[],r(e.arguments,function(e){var t=d.nextId();d.recurse(e,t),l.push(t)}),c=u+"("+l.join(",")+")",d.assign(t,c),i(t)):(u=d.nextId(),s={},l=[],d.recurse(e.callee,u,s,function(){d.if_(d.notNull(u),function(){d.addEnsureSafeFunction(u),r(e.arguments,function(e){d.recurse(e,d.nextId(),void 0,function(e){l.push(d.ensureSafeObject(e))})}),s.name?(d.state.expensiveChecks||d.addEnsureSafeObject(s.context),c=d.member(s.context,s.name,s.computed)+"("+l.join(",")+")"):c=u+"("+l.join(",")+")",c=d.ensureSafeObject(c),d.assign(t,c)},function(){d.assign(t,"undefined")}),i(t)}));break;case bo.AssignmentExpression:if(u=this.nextId(),s={},!fn(e.left))throw fo("lval","Trying to assign a value to a non l-value");this.recurse(e.left,void 0,s,function(){d.if_(d.notNull(s.context),function(){d.recurse(e.right,u),d.addEnsureSafeObject(d.member(s.context,s.name,s.computed)),d.addEnsureSafeAssignContext(s.context),c=d.member(s.context,s.name,s.computed)+e.operator+u,d.assign(t,c),i(t||c)})},1);break;case bo.ArrayExpression:l=[],r(e.elements,function(e){d.recurse(e,d.nextId(),void 0,function(e){l.push(e)})}),c="["+l.join(",")+"]",this.assign(t,c),i(c);break;case bo.ObjectExpression:l=[],f=!1,r(e.properties,function(e){e.computed&&(f=!0)}),f?(t=t||this.nextId(),this.assign(t,"{}"),r(e.properties,function(e){e.computed?(s=d.nextId(),d.recurse(e.key,s)):s=e.key.type===bo.Identifier?e.key.name:""+e.key.value,u=d.nextId(),d.recurse(e.value,u),d.assign(d.member(t,s,e.computed),u)})):(r(e.properties,function(t){d.recurse(t.value,e.constant?void 0:d.nextId(),void 0,function(e){l.push(d.escape(t.key.type===bo.Identifier?t.key.name:""+t.key.value)+":"+e)})}),c="{"+l.join(",")+"}",this.assign(t,c)),i(t||c);break;case bo.ThisExpression:this.assign(t,"s"),i("s");break;case bo.LocalsExpression:this.assign(t,"l"),i("l");break;case bo.NGValueParameter:this.assign(t,"v"),i("v")}},getHasOwnProperty:function(e,t){var n=e+"."+t,r=this.current().own;return r.hasOwnProperty(n)||(r[n]=this.nextId(!1,e+"&&("+this.escape(t)+" in "+e+")")),r[n]},assign:function(e,t){if(e)return this.current().body.push(e,"=",t,";"),e},filter:function(e){return this.state.filters.hasOwnProperty(e)||(this.state.filters[e]=this.nextId(!0)),this.state.filters[e]},ifDefined:function(e,t){return"ifDefined("+e+","+this.escape(t)+")"},plus:function(e,t){return"plus("+e+","+t+")"},return_:function(e){this.current().body.push("return ",e,";")},if_:function(e,t,n){if(e===!0)t();else{var r=this.current().body;r.push("if(",e,"){"),t(),r.push("}"),n&&(r.push("else{"),n(),r.push("}"))}},not:function(e){return"!("+e+")"},notNull:function(e){return e+"!=null"},nonComputedMember:function(e,t){var n=/[$_a-zA-Z][$_a-zA-Z0-9]*/,r=/[^$_a-zA-Z0-9]/g;return n.test(t)?e+"."+t:e+'["'+t.replace(r,this.stringEscapeFn)+'"]'},computedMember:function(e,t){return e+"["+t+"]"},member:function(e,t,n){return n?this.computedMember(e,t):this.nonComputedMember(e,t)},addEnsureSafeObject:function(e){this.current().body.push(this.ensureSafeObject(e),";")},addEnsureSafeMemberName:function(e){this.current().body.push(this.ensureSafeMemberName(e),";")},addEnsureSafeFunction:function(e){this.current().body.push(this.ensureSafeFunction(e),";")},addEnsureSafeAssignContext:function(e){this.current().body.push(this.ensureSafeAssignContext(e),";")},ensureSafeObject:function(e){return"ensureSafeObject("+e+",text)"},ensureSafeMemberName:function(e){return"ensureSafeMemberName("+e+",text)"},ensureSafeFunction:function(e){return"ensureSafeFunction("+e+",text)"},getStringValue:function(e){this.assign(e,"getStringValue("+e+")")},ensureSafeAssignContext:function(e){return"ensureSafeAssignContext("+e+",text)"},lazyRecurse:function(e,t,n,r,i,o){
|
7 |
-
var a=this;return function(){a.recurse(e,t,n,r,i,o)}},lazyAssign:function(e,t){var n=this;return function(){n.assign(e,t)}},stringEscapeRegex:/[^ a-zA-Z0-9]/g,stringEscapeFn:function(e){return"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)},escape:function(e){if(w(e))return"'"+e.replace(this.stringEscapeRegex,this.stringEscapeFn)+"'";if(x(e))return e.toString();if(e===!0)return"true";if(e===!1)return"false";if(null===e)return"null";if("undefined"==typeof e)return"undefined";throw fo("esc","IMPOSSIBLE")},nextId:function(e,t){var n="v"+this.state.nextId++;return e||this.current().vars.push(n+(t?"="+t:"")),n},current:function(){return this.state[this.state.computing]}},vn.prototype={compile:function(e,t){var n=this,i=this.astBuilder.ast(e);this.expression=e,this.expensiveChecks=t,ln(i,n.$filter);var o,a;(o=dn(i))&&(a=this.recurse(o));var s,u=cn(i.body);u&&(s=[],r(u,function(e,t){var r=n.recurse(e);e.input=r,s.push(r),e.watchId=t}));var l=[];r(i.body,function(e){l.push(n.recurse(e.expression))});var c=0===i.body.length?p:1===i.body.length?l[0]:function(e,t){var n;return r(l,function(r){n=r(e,t)}),n};return a&&(c.assign=function(e,t,n){return a(e,n,t)}),s&&(c.inputs=s),c.literal=pn(i),c.constant=hn(i),c},recurse:function(e,t,n){var i,o,a,s=this;if(e.input)return this.inputs(e.input,e.watchId);switch(e.type){case bo.Literal:return this.value(e.value,t);case bo.UnaryExpression:return o=this.recurse(e.argument),this["unary"+e.operator](o,t);case bo.BinaryExpression:return i=this.recurse(e.left),o=this.recurse(e.right),this["binary"+e.operator](i,o,t);case bo.LogicalExpression:return i=this.recurse(e.left),o=this.recurse(e.right),this["binary"+e.operator](i,o,t);case bo.ConditionalExpression:return this["ternary?:"](this.recurse(e.test),this.recurse(e.alternate),this.recurse(e.consequent),t);case bo.Identifier:return en(e.name,s.expression),s.identifier(e.name,s.expensiveChecks||mn(e.name),t,n,s.expression);case bo.MemberExpression:return i=this.recurse(e.object,!1,!!n),e.computed||(en(e.property.name,s.expression),o=e.property.name),e.computed&&(o=this.recurse(e.property)),e.computed?this.computedMember(i,o,t,n,s.expression):this.nonComputedMember(i,o,s.expensiveChecks,t,n,s.expression);case bo.CallExpression:return a=[],r(e.arguments,function(e){a.push(s.recurse(e))}),e.filter&&(o=this.$filter(e.callee.name)),e.filter||(o=this.recurse(e.callee,!0)),e.filter?function(e,n,r,i){for(var s=[],u=0;u<a.length;++u)s.push(a[u](e,n,r,i));var l=o.apply(void 0,s,i);return t?{context:void 0,name:void 0,value:l}:l}:function(e,n,r,i){var u,l=o(e,n,r,i);if(null!=l.value){nn(l.context,s.expression),rn(l.value,s.expression);for(var c=[],f=0;f<a.length;++f)c.push(nn(a[f](e,n,r,i),s.expression));u=nn(l.value.apply(l.context,c),s.expression)}return t?{value:u}:u};case bo.AssignmentExpression:return i=this.recurse(e.left,!0,1),o=this.recurse(e.right),function(e,n,r,a){var u=i(e,n,r,a),l=o(e,n,r,a);return nn(u.value,s.expression),on(u.context),u.context[u.name]=l,t?{value:l}:l};case bo.ArrayExpression:return a=[],r(e.elements,function(e){a.push(s.recurse(e))}),function(e,n,r,i){for(var o=[],s=0;s<a.length;++s)o.push(a[s](e,n,r,i));return t?{value:o}:o};case bo.ObjectExpression:return a=[],r(e.properties,function(e){e.computed?a.push({key:s.recurse(e.key),computed:!0,value:s.recurse(e.value)}):a.push({key:e.key.type===bo.Identifier?e.key.name:""+e.key.value,computed:!1,value:s.recurse(e.value)})}),function(e,n,r,i){for(var o={},s=0;s<a.length;++s)a[s].computed?o[a[s].key(e,n,r,i)]=a[s].value(e,n,r,i):o[a[s].key]=a[s].value(e,n,r,i);return t?{value:o}:o};case bo.ThisExpression:return function(e){return t?{value:e}:e};case bo.LocalsExpression:return function(e,n){return t?{value:n}:n};case bo.NGValueParameter:return function(e,n,r){return t?{value:r}:r}}},"unary+":function(e,t){return function(n,r,i,o){var a=e(n,r,i,o);return a=$(a)?+a:0,t?{value:a}:a}},"unary-":function(e,t){return function(n,r,i,o){var a=e(n,r,i,o);return a=$(a)?-a:0,t?{value:a}:a}},"unary!":function(e,t){return function(n,r,i,o){var a=!e(n,r,i,o);return t?{value:a}:a}},"binary+":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a),u=t(r,i,o,a),l=sn(s,u);return n?{value:l}:l}},"binary-":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a),u=t(r,i,o,a),l=($(s)?s:0)-($(u)?u:0);return n?{value:l}:l}},"binary*":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)*t(r,i,o,a);return n?{value:s}:s}},"binary/":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)/t(r,i,o,a);return n?{value:s}:s}},"binary%":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)%t(r,i,o,a);return n?{value:s}:s}},"binary===":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)===t(r,i,o,a);return n?{value:s}:s}},"binary!==":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)!==t(r,i,o,a);return n?{value:s}:s}},"binary==":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)==t(r,i,o,a);return n?{value:s}:s}},"binary!=":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)!=t(r,i,o,a);return n?{value:s}:s}},"binary<":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)<t(r,i,o,a);return n?{value:s}:s}},"binary>":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)>t(r,i,o,a);return n?{value:s}:s}},"binary<=":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)<=t(r,i,o,a);return n?{value:s}:s}},"binary>=":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)>=t(r,i,o,a);return n?{value:s}:s}},"binary&&":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)&&t(r,i,o,a);return n?{value:s}:s}},"binary||":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)||t(r,i,o,a);return n?{value:s}:s}},"ternary?:":function(e,t,n,r){return function(i,o,a,s){var u=e(i,o,a,s)?t(i,o,a,s):n(i,o,a,s);return r?{value:u}:u}},value:function(e,t){return function(){return t?{context:void 0,name:void 0,value:e}:e}},identifier:function(e,t,n,r,i){return function(o,a,s,u){var l=a&&e in a?a:o;r&&1!==r&&l&&!l[e]&&(l[e]={});var c=l?l[e]:void 0;return t&&nn(c,i),n?{context:l,name:e,value:c}:c}},computedMember:function(e,t,n,r,i){return function(o,a,s,u){var l,c,f=e(o,a,s,u);return null!=f&&(l=t(o,a,s,u),l=tn(l),en(l,i),r&&1!==r&&(on(f),f&&!f[l]&&(f[l]={})),c=f[l],nn(c,i)),n?{context:f,name:l,value:c}:c}},nonComputedMember:function(e,t,n,r,i,o){return function(a,s,u,l){var c=e(a,s,u,l);i&&1!==i&&(on(c),c&&!c[t]&&(c[t]={}));var f=null!=c?c[t]:void 0;return(n||mn(t))&&nn(f,o),r?{context:c,name:t,value:f}:f}},inputs:function(e,t){return function(n,r,i,o){return o?o[t]:e(n,r,i)}}};var yo=function(e,t,n){this.lexer=e,this.$filter=t,this.options=n,this.ast=new bo(e,n),this.astCompiler=n.csp?new vn(this.ast,t):new gn(this.ast,t)};yo.prototype={constructor:yo,parse:function(e){return this.astCompiler.compile(e,this.options.expensiveChecks)}};var wo=Object.prototype.valueOf,xo=t("$sce"),_o={HTML:"html",CSS:"css",URL:"url",RESOURCE_URL:"resourceUrl",JS:"js"},ko=t("$compile"),So=e.document.createElement("a"),Eo=Dn(e.location.href);In.$inject=["$document"],Un.$inject=["$provide"];var Co=22,Ao=".",Oo="0";Hn.$inject=["$locale"],Bn.$inject=["$locale"];var Mo={yyyy:Yn("FullYear",4,0,!1,!0),yy:Yn("FullYear",2,0,!0,!0),y:Yn("FullYear",1,0,!1,!0),MMMM:Zn("Month"),MMM:Zn("Month",!0),MM:Yn("Month",2,1),M:Yn("Month",1,1),LLLL:Zn("Month",!1,!0),dd:Yn("Date",2),d:Yn("Date",1),HH:Yn("Hours",2),H:Yn("Hours",1),hh:Yn("Hours",2,-12),h:Yn("Hours",1,-12),mm:Yn("Minutes",2),m:Yn("Minutes",1),ss:Yn("Seconds",2),s:Yn("Seconds",1),sss:Yn("Milliseconds",3),EEEE:Zn("Day"),EEE:Zn("Day",!0),a:nr,Z:Jn,ww:tr(2),w:tr(1),G:rr,GG:rr,GGG:rr,GGGG:ir},jo=/((?:[^yMLdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|L+|d+|H+|h+|m+|s+|a|Z|G+|w+))(.*)/,Po=/^\-?\d+$/;or.$inject=["$locale"];var To=g(Tr),Do=g(Dr);lr.$inject=["$parse"];var Fo=g({restrict:"E",compile:function(e,t){if(!t.href&&!t.xlinkHref)return function(e,t){if("a"===t[0].nodeName.toLowerCase()){var n="[object SVGAnimatedString]"===Hr.call(t.prop("href"))?"xlink:href":"href";t.on("click",function(e){t.attr(n)||e.preventDefault()})}}}}),No={};r(Ci,function(e,t){function n(e,n,i){e.$watch(i[r],function(e){i.$set(t,!!e)})}if("multiple"!=e){var r=vt("ng-"+t),i=n;"checked"===e&&(i=function(e,t,i){i.ngModel!==i[r]&&n(e,t,i)}),No[r]=function(){return{restrict:"A",priority:100,link:i}}}}),r(Oi,function(e,t){No[t]=function(){return{priority:100,link:function(e,n,r){if("ngPattern"===t&&"/"==r.ngPattern.charAt(0)){var i=r.ngPattern.match(Mr);if(i)return void r.$set("ngPattern",new RegExp(i[1],i[2]))}e.$watch(r[t],function(e){r.$set(t,e)})}}}}),r(["src","srcset","href"],function(e){var t=vt("ng-"+e);No[t]=function(){return{priority:99,link:function(n,r,i){var o=e,a=e;"href"===e&&"[object SVGAnimatedString]"===Hr.call(r.prop("href"))&&(a="xlinkHref",i.$attr[a]="xlink:href",o=null),i.$observe(t,function(t){return t?(i.$set(a,t),void(Ir&&o&&r.prop(o,i[a]))):void("href"===e&&i.$set(a,null))})}}}});var Io={$addControl:p,$$renameControl:fr,$removeControl:p,$setValidity:p,$setDirty:p,$setPristine:p,$setSubmitted:p},Ro="ng-submitted";dr.$inject=["$element","$attrs","$scope","$animate","$interpolate"];var Uo=function(e){return["$timeout","$parse",function(t,n){function r(e){return""===e?n('this[""]').assign:n(e).assign||p}var i={name:"form",restrict:e?"EAC":"E",require:["form","^^?form"],controller:dr,compile:function(n,i){n.addClass(wa).addClass(ba);var o=i.name?"name":!(!e||!i.ngForm)&&"ngForm";return{pre:function(e,n,i,a){var s=a[0];if(!("action"in i)){var u=function(t){e.$apply(function(){s.$commitViewValue(),s.$setSubmitted()}),t.preventDefault()};hi(n[0],"submit",u),n.on("$destroy",function(){t(function(){gi(n[0],"submit",u)},0,!1)})}var c=a[1]||s.$$parentForm;c.$addControl(s);var f=o?r(s.$name):p;o&&(f(e,s),i.$observe(o,function(t){s.$name!==t&&(f(e,void 0),s.$$parentForm.$$renameControl(s,t),(f=r(s.$name))(e,s))})),n.on("$destroy",function(){s.$$parentForm.$removeControl(s),f(e,void 0),l(s,Io)})}}}};return i}]},Vo=Uo(),zo=Uo(!0),Lo=/^\d{4,}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+(?:[+-][0-2]\d:[0-5]\d|Z)$/,qo=/^[a-z][a-z\d.+-]*:\/*(?:[^:@]+(?::[^@]+)?@)?(?:[^\s:\/?#]+|\[[a-f\d:]+\])(?::\d+)?(?:\/[^?#]*)?(?:\?[^#]*)?(?:#.*)?$/i,Ho=/^(?=.{1,254}$)(?=.{1,64}@)[-!#$%&'*+\/0-9=?A-Z^_`a-z{|}~]+(\.[-!#$%&'*+\/0-9=?A-Z^_`a-z{|}~]+)*@[A-Za-z0-9]([A-Za-z0-9-]{0,61}[A-Za-z0-9])?(\.[A-Za-z0-9]([A-Za-z0-9-]{0,61}[A-Za-z0-9])?)*$/,Bo=/^\s*(\-|\+)?(\d+|(\d*(\.\d*)))([eE][+-]?\d+)?\s*$/,Wo=/^(\d{4,})-(\d{2})-(\d{2})$/,Go=/^(\d{4,})-(\d\d)-(\d\d)T(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,Xo=/^(\d{4,})-W(\d\d)$/,Ko=/^(\d{4,})-(\d\d)$/,Yo=/^(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,Zo="keydown wheel mousedown",Jo=he();r("date,datetime-local,month,time,week".split(","),function(e){Jo[e]=!0});var Qo={text:hr,date:$r("date",Wo,mr(Wo,["yyyy","MM","dd"]),"yyyy-MM-dd"),"datetime-local":$r("datetimelocal",Go,mr(Go,["yyyy","MM","dd","HH","mm","ss","sss"]),"yyyy-MM-ddTHH:mm:ss.sss"),time:$r("time",Yo,mr(Yo,["HH","mm","ss","sss"]),"HH:mm:ss.sss"),week:$r("week",Xo,vr,"yyyy-Www"),month:$r("month",Ko,mr(Ko,["yyyy","MM"]),"yyyy-MM"),number:yr,url:wr,email:xr,radio:_r,checkbox:Sr,hidden:p,button:p,submit:p,reset:p,file:p},ea=["$browser","$sniffer","$filter","$parse",function(e,t,n,r){return{restrict:"E",require:["?ngModel"],link:{pre:function(i,o,a,s){s[0]&&(Qo[Tr(a.type)]||Qo.text)(i,o,a,s[0],t,e,n,r)}}}}],ta=/^(true|false|\d+)$/,na=function(){return{restrict:"A",priority:100,compile:function(e,t){return ta.test(t.ngValue)?function(e,t,n){n.$set("value",e.$eval(n.ngValue))}:function(e,t,n){e.$watch(n.ngValue,function(e){n.$set("value",e)})}}}},ra=["$compile",function(e){return{restrict:"AC",compile:function(t){return e.$$addBindingClass(t),function(t,n,r){e.$$addBindingInfo(n,r.ngBind),n=n[0],t.$watch(r.ngBind,function(e){n.textContent=m(e)?"":e})}}}}],ia=["$interpolate","$compile",function(e,t){return{compile:function(n){return t.$$addBindingClass(n),function(n,r,i){var o=e(r.attr(i.$attr.ngBindTemplate));t.$$addBindingInfo(r,o.expressions),r=r[0],i.$observe("ngBindTemplate",function(e){r.textContent=m(e)?"":e})}}}}],oa=["$sce","$parse","$compile",function(e,t,n){return{restrict:"A",compile:function(r,i){var o=t(i.ngBindHtml),a=t(i.ngBindHtml,function(t){return e.valueOf(t)});return n.$$addBindingClass(r),function(t,r,i){n.$$addBindingInfo(r,i.ngBindHtml),t.$watch(a,function(){var n=o(t);r.html(e.getTrustedHtml(n)||"")})}}}}],aa=g({restrict:"A",require:"ngModel",link:function(e,t,n,r){r.$viewChangeListeners.push(function(){e.$eval(n.ngChange)})}}),sa=Er("",!0),ua=Er("Odd",0),la=Er("Even",1),ca=cr({compile:function(e,t){t.$set("ngCloak",void 0),e.removeClass("ng-cloak")}}),fa=[function(){return{restrict:"A",scope:!0,controller:"@",priority:500}}],da={},pa={blur:!0,focus:!0};r("click dblclick mousedown mouseup mouseover mouseout mousemove mouseenter mouseleave keydown keyup keypress submit focus blur copy cut paste".split(" "),function(e){var t=vt("ng-"+e);da[t]=["$parse","$rootScope",function(n,r){return{restrict:"A",compile:function(i,o){var a=n(o[t],null,!0);return function(t,n){n.on(e,function(n){var i=function(){a(t,{$event:n})};pa[e]&&r.$$phase?t.$evalAsync(i):t.$apply(i)})}}}}]});var ha=["$animate","$compile",function(e,t){return{multiElement:!0,transclude:"element",priority:600,terminal:!0,restrict:"A",$$tlb:!0,link:function(n,r,i,o,a){var s,u,l;n.$watch(i.ngIf,function(n){n?u||a(function(n,o){u=o,n[n.length++]=t.$$createComment("end ngIf",i.ngIf),s={clone:n},e.enter(n,r.parent(),r)}):(l&&(l.remove(),l=null),u&&(u.$destroy(),u=null),s&&(l=pe(s.clone),e.leave(l).then(function(){l=null}),s=null))})}}}],ga=["$templateRequest","$anchorScroll","$animate",function(e,t,n){return{restrict:"ECA",priority:400,terminal:!0,transclude:"element",controller:Gr.noop,compile:function(r,i){var o=i.ngInclude||i.src,a=i.onload||"",s=i.autoscroll;return function(r,i,u,l,c){var f,d,p,h=0,g=function(){d&&(d.remove(),d=null),f&&(f.$destroy(),f=null),p&&(n.leave(p).then(function(){d=null}),d=p,p=null)};r.$watch(o,function(o){var u=function(){!$(s)||s&&!r.$eval(s)||t()},d=++h;o?(e(o,!0).then(function(e){if(!r.$$destroyed&&d===h){var t=r.$new();l.template=e;var s=c(t,function(e){g(),n.enter(e,null,i).then(u)});f=t,p=s,f.$emit("$includeContentLoaded",o),r.$eval(a)}},function(){r.$$destroyed||d===h&&(g(),r.$emit("$includeContentError",o))}),r.$emit("$includeContentRequested",o)):(g(),l.template=null)})}}}}],va=["$compile",function(t){return{restrict:"ECA",priority:-400,require:"ngInclude",link:function(n,r,i,o){return Hr.call(r[0]).match(/SVG/)?(r.empty(),void t(Ee(o.template,e.document).childNodes)(n,function(e){r.append(e)},{futureParentElement:r})):(r.html(o.template),void t(r.contents())(n))}}}],ma=cr({priority:450,compile:function(){return{pre:function(e,t,n){e.$eval(n.ngInit)}}}}),$a=function(){return{restrict:"A",priority:100,require:"ngModel",link:function(e,t,n,i){var o=t.attr(n.$attr.ngList)||", ",a="false"!==n.ngTrim,s=a?Zr(o):o,u=function(e){if(!m(e)){var t=[];return e&&r(e.split(s),function(e){e&&t.push(a?Zr(e):e)}),t}};i.$parsers.push(u),i.$formatters.push(function(e){if(Kr(e))return e.join(o)}),i.$isEmpty=function(e){return!e||!e.length}}}},ba="ng-valid",ya="ng-invalid",wa="ng-pristine",xa="ng-dirty",_a="ng-untouched",ka="ng-touched",Sa="ng-pending",Ea="ng-empty",Ca="ng-not-empty",Aa=t("ngModel"),Oa=["$scope","$exceptionHandler","$attrs","$element","$parse","$animate","$timeout","$rootScope","$q","$interpolate",function(e,t,n,i,o,a,s,u,l,c){this.$viewValue=Number.NaN,this.$modelValue=Number.NaN,this.$$rawModelValue=void 0,this.$validators={},this.$asyncValidators={},this.$parsers=[],this.$formatters=[],this.$viewChangeListeners=[],this.$untouched=!0,this.$touched=!1,this.$pristine=!0,this.$dirty=!1,this.$valid=!0,this.$invalid=!1,this.$error={},this.$$success={},this.$pending=void 0,this.$name=c(n.name||"",!1)(e),this.$$parentForm=Io;var f,d=o(n.ngModel),h=d.assign,g=d,v=h,b=null,y=this;this.$$setOptions=function(e){if(y.$options=e,e&&e.getterSetter){var t=o(n.ngModel+"()"),r=o(n.ngModel+"($$$p)");g=function(e){var n=d(e);return k(n)&&(n=t(e)),n},v=function(e,t){k(d(e))?r(e,{$$$p:t}):h(e,t)}}else if(!d.assign)throw Aa("nonassign","Expression '{0}' is non-assignable. Element: {1}",n.ngModel,Y(i))},this.$render=p,this.$isEmpty=function(e){return m(e)||""===e||null===e||e!==e},this.$$updateEmptyClasses=function(e){y.$isEmpty(e)?(a.removeClass(i,Ca),a.addClass(i,Ea)):(a.removeClass(i,Ea),a.addClass(i,Ca))};var w=0;Cr({ctrl:this,$element:i,set:function(e,t){e[t]=!0},unset:function(e,t){delete e[t]},$animate:a}),this.$setPristine=function(){y.$dirty=!1,y.$pristine=!0,a.removeClass(i,xa),a.addClass(i,wa)},this.$setDirty=function(){y.$dirty=!0,y.$pristine=!1,a.removeClass(i,wa),a.addClass(i,xa),y.$$parentForm.$setDirty()},this.$setUntouched=function(){y.$touched=!1,y.$untouched=!0,a.setClass(i,_a,ka)},this.$setTouched=function(){y.$touched=!0,y.$untouched=!1,a.setClass(i,ka,_a)},this.$rollbackViewValue=function(){s.cancel(b),y.$viewValue=y.$$lastCommittedViewValue,y.$render()},this.$validate=function(){if(!x(y.$modelValue)||!isNaN(y.$modelValue)){var e=y.$$lastCommittedViewValue,t=y.$$rawModelValue,n=y.$valid,r=y.$modelValue,i=y.$options&&y.$options.allowInvalid;y.$$runValidators(t,e,function(e){i||n===e||(y.$modelValue=e?t:void 0,y.$modelValue!==r&&y.$$writeModelToScope())})}},this.$$runValidators=function(e,t,n){function i(){var e=y.$$parserName||"parse";return m(f)?(s(e,null),!0):(f||(r(y.$validators,function(e,t){s(t,null)}),r(y.$asyncValidators,function(e,t){s(t,null)})),s(e,f),f)}function o(){var n=!0;return r(y.$validators,function(r,i){var o=r(e,t);n=n&&o,s(i,o)}),!!n||(r(y.$asyncValidators,function(e,t){s(t,null)}),!1)}function a(){var n=[],i=!0;r(y.$asyncValidators,function(r,o){var a=r(e,t);if(!P(a))throw Aa("nopromise","Expected asynchronous validator to return a promise but got '{0}' instead.",a);s(o,void 0),n.push(a.then(function(){s(o,!0)},function(){i=!1,s(o,!1)}))}),n.length?l.all(n).then(function(){u(i)},p):u(!0)}function s(e,t){c===w&&y.$setValidity(e,t)}function u(e){c===w&&n(e)}w++;var c=w;return i()&&o()?void a():void u(!1)},this.$commitViewValue=function(){var e=y.$viewValue;s.cancel(b),(y.$$lastCommittedViewValue!==e||""===e&&y.$$hasNativeValidators)&&(y.$$updateEmptyClasses(e),y.$$lastCommittedViewValue=e,y.$pristine&&this.$setDirty(),this.$$parseAndValidate())},this.$$parseAndValidate=function(){function t(){y.$modelValue!==o&&y.$$writeModelToScope()}var n=y.$$lastCommittedViewValue,r=n;if(f=!m(r)||void 0)for(var i=0;i<y.$parsers.length;i++)if(r=y.$parsers[i](r),m(r)){f=!1;break}x(y.$modelValue)&&isNaN(y.$modelValue)&&(y.$modelValue=g(e));var o=y.$modelValue,a=y.$options&&y.$options.allowInvalid;y.$$rawModelValue=r,a&&(y.$modelValue=r,t()),y.$$runValidators(r,y.$$lastCommittedViewValue,function(e){a||(y.$modelValue=e?r:void 0,t())})},this.$$writeModelToScope=function(){v(e,y.$modelValue),r(y.$viewChangeListeners,function(e){try{e()}catch(n){t(n)}})},this.$setViewValue=function(e,t){y.$viewValue=e,y.$options&&!y.$options.updateOnDefault||y.$$debounceViewValueCommit(t)},this.$$debounceViewValueCommit=function(t){var n,r=0,i=y.$options;i&&$(i.debounce)&&(n=i.debounce,x(n)?r=n:x(n[t])?r=n[t]:x(n["default"])&&(r=n["default"])),s.cancel(b),r?b=s(function(){y.$commitViewValue()},r):u.$$phase?y.$commitViewValue():e.$apply(function(){y.$commitViewValue()})},e.$watch(function(){var t=g(e);if(t!==y.$modelValue&&(y.$modelValue===y.$modelValue||t===t)){y.$modelValue=y.$$rawModelValue=t,f=void 0;for(var n=y.$formatters,r=n.length,i=t;r--;)i=n[r](i);y.$viewValue!==i&&(y.$$updateEmptyClasses(i),y.$viewValue=y.$$lastCommittedViewValue=i,y.$render(),y.$$runValidators(t,i,p))}return t})}],Ma=["$rootScope",function(e){return{restrict:"A",require:["ngModel","^?form","^?ngModelOptions"],controller:Oa,priority:1,compile:function(t){return t.addClass(wa).addClass(_a).addClass(ba),{pre:function(e,t,n,r){var i=r[0],o=r[1]||i.$$parentForm;i.$$setOptions(r[2]&&r[2].$options),o.$addControl(i),n.$observe("name",function(e){i.$name!==e&&i.$$parentForm.$$renameControl(i,e)}),e.$on("$destroy",function(){i.$$parentForm.$removeControl(i)})},post:function(t,n,r,i){var o=i[0];o.$options&&o.$options.updateOn&&n.on(o.$options.updateOn,function(e){o.$$debounceViewValueCommit(e&&e.type)}),n.on("blur",function(){o.$touched||(e.$$phase?t.$evalAsync(o.$setTouched):t.$apply(o.$setTouched))})}}}}}],ja=/(\s+|^)default(\s+|$)/,Pa=function(){return{restrict:"A",controller:["$scope","$attrs",function(e,t){var n=this;this.$options=U(e.$eval(t.ngModelOptions)),$(this.$options.updateOn)?(this.$options.updateOnDefault=!1,this.$options.updateOn=Zr(this.$options.updateOn.replace(ja,function(){return n.$options.updateOnDefault=!0," "}))):this.$options.updateOnDefault=!0}]}},Ta=cr({terminal:!0,priority:1e3}),Da=t("ngOptions"),Fa=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+group\s+by\s+([\s\S]+?))?(?:\s+disable\s+when\s+([\s\S]+?))?\s+for\s+(?:([\$\w][\$\w]*)|(?:\(\s*([\$\w][\$\w]*)\s*,\s*([\$\w][\$\w]*)\s*\)))\s+in\s+([\s\S]+?)(?:\s+track\s+by\s+([\s\S]+?))?$/,Na=["$compile","$document","$parse",function(t,i,o){function a(e,t,r){function i(e,t,n,r,i){this.selectValue=e,this.viewValue=t,this.label=n,this.group=r,this.disabled=i}function a(e){var t;if(!l&&n(e))t=e;else{t=[];for(var r in e)e.hasOwnProperty(r)&&"$"!==r.charAt(0)&&t.push(r)}return t}var s=e.match(Fa);if(!s)throw Da("iexp","Expected expression in form of '_select_ (as _label_)? for (_key_,)?_value_ in _collection_' but got '{0}'. Element: {1}",e,Y(t));var u=s[5]||s[7],l=s[6],c=/ as /.test(s[0])&&s[1],f=s[9],d=o(s[2]?s[1]:u),p=c&&o(c),h=p||d,g=f&&o(f),v=f?function(e,t){return g(r,t)}:function(e){return Ze(e)},m=function(e,t){return v(e,_(e,t))},$=o(s[2]||s[1]),b=o(s[3]||""),y=o(s[4]||""),w=o(s[8]),x={},_=l?function(e,t){return x[l]=t,x[u]=e,x}:function(e){return x[u]=e,x};return{trackBy:f,getTrackByValue:m,getWatchables:o(w,function(e){var t=[];e=e||[];for(var n=a(e),i=n.length,o=0;o<i;o++){var u=e===n?o:n[o],l=e[u],c=_(l,u),f=v(l,c);if(t.push(f),s[2]||s[1]){var d=$(r,c);t.push(d)}if(s[4]){var p=y(r,c);t.push(p)}}return t}),getOptions:function(){for(var e=[],t={},n=w(r)||[],o=a(n),s=o.length,u=0;u<s;u++){var l=n===o?u:o[u],c=n[l],d=_(c,l),p=h(r,d),g=v(p,d),x=$(r,d),k=b(r,d),S=y(r,d),E=new i(g,p,x,k,S);e.push(E),t[g]=E}return{items:e,selectValueMap:t,getOptionFromViewValue:function(e){return t[m(e)]},getViewValueFromOption:function(e){return f?Gr.copy(e.viewValue):e.viewValue}}}}}function s(e,n,o,s){function c(e,t){var n=u.cloneNode(!1);t.appendChild(n),f(e,n)}function f(e,t){e.element=t,t.disabled=e.disabled,e.label!==t.label&&(t.label=e.label,t.textContent=e.label),e.value!==t.value&&(t.value=e.selectValue)}function d(){var e=_&&h.readValue();if(_)for(var t=_.items.length-1;t>=0;t--){var r=_.items[t];qe($(r.group)?r.element.parentNode:r.element)}_=k.getOptions();var i={};if(w&&n.prepend(p),_.items.forEach(function(e){var t;$(e.group)?(t=i[e.group],t||(t=l.cloneNode(!1),S.appendChild(t),t.label=null===e.group?"null":e.group,i[e.group]=t),c(e,t)):c(e,S)}),n[0].appendChild(S),g.$render(),!g.$isEmpty(e)){var o=h.readValue(),a=k.trackBy||v;(a?V(e,o):e===o)||(g.$setViewValue(o),g.$render())}}for(var p,h=s[0],g=s[1],v=o.multiple,m=0,b=n.children(),y=b.length;m<y;m++)if(""===b[m].value){p=b.eq(m);break}var w=!!p,x=Rr(u.cloneNode(!1));x.val("?");var _,k=a(o.ngOptions,n,e),S=i[0].createDocumentFragment(),E=function(){w||n.prepend(p),n.val(""),p.prop("selected",!0),p.attr("selected",!0)},C=function(){w||p.remove()},A=function(){n.prepend(x),n.val("?"),x.prop("selected",!0),x.attr("selected",!0)},O=function(){x.remove()};v?(g.$isEmpty=function(e){return!e||0===e.length},h.writeValue=function(e){_.items.forEach(function(e){e.element.selected=!1}),e&&e.forEach(function(e){var t=_.getOptionFromViewValue(e);t&&(t.element.selected=!0)})},h.readValue=function(){var e=n.val()||[],t=[];return r(e,function(e){var n=_.selectValueMap[e];n&&!n.disabled&&t.push(_.getViewValueFromOption(n))}),t},k.trackBy&&e.$watchCollection(function(){if(Kr(g.$viewValue))return g.$viewValue.map(function(e){return k.getTrackByValue(e)})},function(){g.$render()})):(h.writeValue=function(e){var t=_.getOptionFromViewValue(e);t?(n[0].value!==t.selectValue&&(O(),C(),n[0].value=t.selectValue,t.element.selected=!0),t.element.setAttribute("selected","selected")):null===e||w?(O(),E()):(C(),A())},h.readValue=function(){var e=_.selectValueMap[n.val()];return e&&!e.disabled?(C(),O(),_.getViewValueFromOption(e)):null},k.trackBy&&e.$watch(function(){return k.getTrackByValue(g.$viewValue)},function(){g.$render()})),w?(p.remove(),t(p)(e),p.removeClass("ng-scope")):p=Rr(u.cloneNode(!1)),n.empty(),d(),e.$watchCollection(k.getWatchables,d)}var u=e.document.createElement("option"),l=e.document.createElement("optgroup");return{restrict:"A",terminal:!0,require:["select","ngModel"],link:{pre:function(e,t,n,r){r[0].registerOption=p},post:s}}}],Ia=["$locale","$interpolate","$log",function(e,t,n){var i=/{}/g,o=/^when(Minus)?(.+)$/;return{link:function(a,s,u){function l(e){s.text(e||"")}var c,f=u.count,d=u.$attr.when&&s.attr(u.$attr.when),h=u.offset||0,g=a.$eval(d)||{},v={},$=t.startSymbol(),b=t.endSymbol(),y=$+f+"-"+h+b,w=Gr.noop;r(u,function(e,t){var n=o.exec(t);if(n){var r=(n[1]?"-":"")+Tr(n[2]);g[r]=s.attr(u.$attr[t])}}),r(g,function(e,n){v[n]=t(e.replace(i,y))}),a.$watch(f,function(t){var r=parseFloat(t),i=isNaN(r);if(i||r in g||(r=e.pluralCat(r-h)),r!==c&&!(i&&x(c)&&isNaN(c))){w();var o=v[r];m(o)?(null!=t&&n.debug("ngPluralize: no rule defined for '"+r+"' in "+d),w=p,l()):w=a.$watch(o,l),c=r}})}}}],Ra=["$parse","$animate","$compile",function(e,i,o){var a="$$NG_REMOVED",s=t("ngRepeat"),u=function(e,t,n,r,i,o,a){e[n]=r,i&&(e[i]=o),e.$index=t,e.$first=0===t,e.$last=t===a-1,e.$middle=!(e.$first||e.$last),e.$odd=!(e.$even=0===(1&t))},l=function(e){return e.clone[0]},c=function(e){return e.clone[e.clone.length-1]};return{restrict:"A",multiElement:!0,transclude:"element",priority:1e3,terminal:!0,$$tlb:!0,compile:function(t,f){var d=f.ngRepeat,p=o.$$createComment("end ngRepeat",d),h=d.match(/^\s*([\s\S]+?)\s+in\s+([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+track\s+by\s+([\s\S]+?))?\s*$/);if(!h)throw s("iexp","Expected expression in form of '_item_ in _collection_[ track by _id_]' but got '{0}'.",d);var g=h[1],v=h[2],m=h[3],$=h[4];if(h=g.match(/^(?:(\s*[\$\w]+)|\(\s*([\$\w]+)\s*,\s*([\$\w]+)\s*\))$/),!h)throw s("iidexp","'_item_' in '_item_ in _collection_' should be an identifier or '(_key_, _value_)' expression, but got '{0}'.",g);var b=h[3]||h[1],y=h[2];if(m&&(!/^[$a-zA-Z_][$a-zA-Z0-9_]*$/.test(m)||/^(null|undefined|this|\$index|\$first|\$middle|\$last|\$even|\$odd|\$parent|\$root|\$id)$/.test(m)))throw s("badident","alias '{0}' is invalid --- must be a valid JS identifier which is not a reserved name.",m);var w,x,_,k,S={$id:Ze};return $?w=e($):(_=function(e,t){return Ze(t)},k=function(e){return e}),function(e,t,o,f,h){w&&(x=function(t,n,r){return y&&(S[y]=t),S[b]=n,S.$index=r,w(e,S)});var g=he();e.$watchCollection(v,function(o){var f,v,$,w,S,E,C,A,O,M,j,P,T=t[0],D=he();if(m&&(e[m]=o),n(o))O=o,A=x||_;else{A=x||k,O=[];for(var F in o)Pr.call(o,F)&&"$"!==F.charAt(0)&&O.push(F)}for(w=O.length,j=new Array(w),f=0;f<w;f++)if(S=o===O?f:O[f],E=o[S],C=A(S,E,f),g[C])M=g[C],delete g[C],D[C]=M,j[f]=M;else{if(D[C])throw r(j,function(e){e&&e.scope&&(g[e.id]=e)}),s("dupes","Duplicates in a repeater are not allowed. Use 'track by' expression to specify unique keys. Repeater: {0}, Duplicate key: {1}, Duplicate value: {2}",d,C,E);j[f]={id:C,scope:void 0,clone:void 0},D[C]=!0}for(var N in g){if(M=g[N],P=pe(M.clone),i.leave(P),P[0].parentNode)for(f=0,v=P.length;f<v;f++)P[f][a]=!0;M.scope.$destroy()}for(f=0;f<w;f++)if(S=o===O?f:O[f],E=o[S],M=j[f],M.scope){$=T;do $=$.nextSibling;while($&&$[a]);l(M)!=$&&i.move(pe(M.clone),null,T),T=c(M),u(M.scope,f,b,E,y,S,w)}else h(function(e,t){M.scope=t;var n=p.cloneNode(!1);e[e.length++]=n,i.enter(e,null,T),T=n,M.clone=e,D[M.id]=M,u(M.scope,f,b,E,y,S,w)});g=D})}}}}],Ua="ng-hide",Va="ng-hide-animate",za=["$animate",function(e){return{restrict:"A",multiElement:!0,link:function(t,n,r){t.$watch(r.ngShow,function(t){e[t?"removeClass":"addClass"](n,Ua,{tempClasses:Va})})}}}],La=["$animate",function(e){return{restrict:"A",multiElement:!0,link:function(t,n,r){t.$watch(r.ngHide,function(t){e[t?"addClass":"removeClass"](n,Ua,{tempClasses:Va})})}}}],qa=cr(function(e,t,n){e.$watch(n.ngStyle,function(e,n){n&&e!==n&&r(n,function(e,n){t.css(n,"")}),e&&t.css(e)},!0)}),Ha=["$animate","$compile",function(e,t){return{require:"ngSwitch",controller:["$scope",function(){this.cases={}}],link:function(n,i,o,a){var s=o.ngSwitch||o.on,u=[],l=[],c=[],f=[],d=function(e,t){return function(){e.splice(t,1)}};n.$watch(s,function(n){var i,o;for(i=0,o=c.length;i<o;++i)e.cancel(c[i]);for(c.length=0,i=0,o=f.length;i<o;++i){var s=pe(l[i].clone);f[i].$destroy();var p=c[i]=e.leave(s);p.then(d(c,i))}l.length=0,f.length=0,(u=a.cases["!"+n]||a.cases["?"])&&r(u,function(n){n.transclude(function(r,i){f.push(i);var o=n.element;r[r.length++]=t.$$createComment("end ngSwitchWhen");var a={clone:r};l.push(a),e.enter(r,o.parent(),o)})})})}}}],Ba=cr({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(e,t,n,r,i){r.cases["!"+n.ngSwitchWhen]=r.cases["!"+n.ngSwitchWhen]||[],r.cases["!"+n.ngSwitchWhen].push({transclude:i,element:t})}}),Wa=cr({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(e,t,n,r,i){r.cases["?"]=r.cases["?"]||[],r.cases["?"].push({transclude:i,element:t})}}),Ga=t("ngTransclude"),Xa=["$compile",function(e){return{restrict:"EAC",terminal:!0,compile:function(t){var n=e(t.contents());return t.empty(),function(e,t,r,i,o){function a(e,n){e.length?t.append(e):(s(),n.$destroy())}function s(){n(e,function(e){t.append(e)})}if(!o)throw Ga("orphan","Illegal use of ngTransclude directive in the template! No parent directive that requires a transclusion found. Element: {0}",Y(t));r.ngTransclude===r.$attr.ngTransclude&&(r.ngTransclude="");var u=r.ngTransclude||r.ngTranscludeSlot;o(a,null,u),u&&!o.isSlotFilled(u)&&s()}}}}],Ka=["$templateCache",function(e){return{restrict:"E",terminal:!0,compile:function(t,n){if("text/ng-template"==n.type){var r=n.id,i=t[0].text;e.put(r,i)}}}}],Ya={$setViewValue:p,$render:p},Za=["$element","$scope",function(t,n){var r=this,i=new Je;r.ngModelCtrl=Ya,r.unknownOption=Rr(e.document.createElement("option")),r.renderUnknownOption=function(e){var n="? "+Ze(e)+" ?";r.unknownOption.val(n),t.prepend(r.unknownOption),t.val(n)},n.$on("$destroy",function(){r.renderUnknownOption=p}),r.removeUnknownOption=function(){r.unknownOption.parent()&&r.unknownOption.remove()},r.readValue=function(){return r.removeUnknownOption(),t.val()},r.writeValue=function(e){r.hasOption(e)?(r.removeUnknownOption(),t.val(e),""===e&&r.emptyOption.prop("selected",!0)):null==e&&r.emptyOption?(r.removeUnknownOption(),t.val("")):r.renderUnknownOption(e)},r.addOption=function(e,t){if(t[0].nodeType!==ui){fe(e,'"option value"'),""===e&&(r.emptyOption=t);var n=i.get(e)||0;i.put(e,n+1),r.ngModelCtrl.$render(),Or(t)}},r.removeOption=function(e){var t=i.get(e);t&&(1===t?(i.remove(e),""===e&&(r.emptyOption=void 0)):i.put(e,t-1))},r.hasOption=function(e){return!!i.get(e)},r.registerOption=function(e,t,n,i,o){if(i){var a;n.$observe("value",function(e){$(a)&&r.removeOption(a),a=e,r.addOption(e,t)})}else o?e.$watch(o,function(e,i){n.$set("value",e),i!==e&&r.removeOption(i),r.addOption(e,t)}):r.addOption(n.value,t);t.on("$destroy",function(){r.removeOption(n.value),r.ngModelCtrl.$render()})}}],Ja=function(){function e(e,t,n,i){var o=i[1];if(o){var a=i[0];if(a.ngModelCtrl=o,t.on("change",function(){e.$apply(function(){o.$setViewValue(a.readValue())})}),n.multiple){a.readValue=function(){var e=[];return r(t.find("option"),function(t){t.selected&&e.push(t.value)}),e},a.writeValue=function(e){var n=new Je(e);r(t.find("option"),function(e){e.selected=$(n.get(e.value))})};var s,u=NaN;e.$watch(function(){u!==o.$viewValue||V(s,o.$viewValue)||(s=ve(o.$viewValue),
|
8 |
-
o.$render()),u=o.$viewValue}),o.$isEmpty=function(e){return!e||0===e.length}}}}function t(e,t,n,r){var i=r[1];if(i){var o=r[0];i.$render=function(){o.writeValue(i.$viewValue)}}}return{restrict:"E",require:["select","?ngModel"],controller:Za,priority:1,link:{pre:e,post:t}}},Qa=["$interpolate",function(e){return{restrict:"E",priority:100,compile:function(t,n){if($(n.value))var r=e(n.value,!0);else{var i=e(t.text(),!0);i||n.$set("value",t.text())}return function(e,t,n){var o="$selectController",a=t.parent(),s=a.data(o)||a.parent().data(o);s&&s.registerOption(e,t,n,r,i)}}}}],es=g({restrict:"E",terminal:!1}),ts=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,n,r){r&&(n.required=!0,r.$validators.required=function(e,t){return!n.required||!r.$isEmpty(t)},n.$observe("required",function(){r.$validate()}))}}},ns=function(){return{restrict:"A",require:"?ngModel",link:function(e,n,r,i){if(i){var o,a=r.ngPattern||r.pattern;r.$observe("pattern",function(e){if(w(e)&&e.length>0&&(e=new RegExp("^"+e+"$")),e&&!e.test)throw t("ngPattern")("noregexp","Expected {0} to be a RegExp but was {1}. Element: {2}",a,e,Y(n));o=e||void 0,i.$validate()}),i.$validators.pattern=function(e,t){return i.$isEmpty(t)||m(o)||o.test(t)}}}}},rs=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,n,r){if(r){var i=-1;n.$observe("maxlength",function(e){var t=f(e);i=isNaN(t)?-1:t,r.$validate()}),r.$validators.maxlength=function(e,t){return i<0||r.$isEmpty(t)||t.length<=i}}}}},is=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,n,r){if(r){var i=0;n.$observe("minlength",function(e){i=f(e)||0,r.$validate()}),r.$validators.minlength=function(e,t){return r.$isEmpty(t)||t.length>=i}}}}};return e.angular.bootstrap?void(e.console&&console.log("WARNING: Tried to load angular more than once.")):(ue(),be(Gr),Gr.module("ngLocale",[],["$provide",function(e){function t(e){e+="";var t=e.indexOf(".");return t==-1?0:e.length-t-1}function n(e,n){var r=n;void 0===r&&(r=Math.min(t(e),3));var i=Math.pow(10,r),o=(e*i|0)%i;return{v:r,f:o}}var r={ZERO:"zero",ONE:"one",TWO:"two",FEW:"few",MANY:"many",OTHER:"other"};e.value("$locale",{DATETIME_FORMATS:{AMPMS:["AM","PM"],DAY:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],ERANAMES:["Before Christ","Anno Domini"],ERAS:["BC","AD"],FIRSTDAYOFWEEK:6,MONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],SHORTDAY:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],SHORTMONTH:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],STANDALONEMONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],WEEKENDRANGE:[5,6],fullDate:"EEEE, MMMM d, y",longDate:"MMMM d, y",medium:"MMM d, y h:mm:ss a",mediumDate:"MMM d, y",mediumTime:"h:mm:ss a","short":"M/d/yy h:mm a",shortDate:"M/d/yy",shortTime:"h:mm a"},NUMBER_FORMATS:{CURRENCY_SYM:"$",DECIMAL_SEP:".",GROUP_SEP:",",PATTERNS:[{gSize:3,lgSize:3,maxFrac:3,minFrac:0,minInt:1,negPre:"-",negSuf:"",posPre:"",posSuf:""},{gSize:3,lgSize:3,maxFrac:2,minFrac:2,minInt:1,negPre:"-¤",negSuf:"",posPre:"¤",posSuf:""}]},id:"en-us",localeID:"en_US",pluralCat:function(e,t){var i=0|e,o=n(e,t);return 1==i&&0==o.v?r.ONE:r.OTHER}})}]),void Rr(e.document).ready(function(){re(e.document,ie)}))}(window),!window.angular.$$csp().noInlineStyle&&window.angular.element(document.head).prepend('<style type="text/css">@charset "UTF-8";[ng\\:cloak],[ng-cloak],[data-ng-cloak],[x-ng-cloak],.ng-cloak,.x-ng-cloak,.ng-hide:not(.ng-hide-animate){display:none !important;}ng\\:form{display:block;}.ng-animate-shim{visibility:hidden;}.ng-anchor{position:absolute;}</style>')},{}],46:[function(e,t,n){e("./angular"),t.exports=angular},{"./angular":45}],47:[function(e,t,n){!function(){function e(e,t){window.XMLHttpRequest.prototype[e]=t(window.XMLHttpRequest.prototype[e])}function t(e,t,n){try{Object.defineProperty(e,t,{get:n})}catch(r){}}if(window.FileAPI||(window.FileAPI={}),!window.XMLHttpRequest)throw"AJAX is not supported. XMLHttpRequest is not defined.";if(FileAPI.shouldLoad=!window.FormData||FileAPI.forceLoad,FileAPI.shouldLoad){var n=function(e){if(!e.__listeners){e.upload||(e.upload={}),e.__listeners=[];var t=e.upload.addEventListener;e.upload.addEventListener=function(n,r){e.__listeners[n]=r,t&&t.apply(this,arguments)}}};e("open",function(e){return function(t,r,i){n(this),this.__url=r;try{e.apply(this,[t,r,i])}catch(o){o.message.indexOf("Access is denied")>-1&&(this.__origError=o,e.apply(this,[t,"_fix_for_ie_crossdomain__",i]))}}}),e("getResponseHeader",function(e){return function(t){return this.__fileApiXHR&&this.__fileApiXHR.getResponseHeader?this.__fileApiXHR.getResponseHeader(t):null==e?null:e.apply(this,[t])}}),e("getAllResponseHeaders",function(e){return function(){return this.__fileApiXHR&&this.__fileApiXHR.getAllResponseHeaders?this.__fileApiXHR.getAllResponseHeaders():null==e?null:e.apply(this)}}),e("abort",function(e){return function(){return this.__fileApiXHR&&this.__fileApiXHR.abort?this.__fileApiXHR.abort():null==e?null:e.apply(this)}}),e("setRequestHeader",function(e){return function(t,r){if("__setXHR_"===t){n(this);var i=r(this);i instanceof Function&&i(this)}else this.__requestHeaders=this.__requestHeaders||{},this.__requestHeaders[t]=r,e.apply(this,arguments)}}),e("send",function(e){return function(){var n=this;if(arguments[0]&&arguments[0].__isFileAPIShim){var r=arguments[0],i={url:n.__url,jsonp:!1,cache:!0,complete:function(e,r){e&&angular.isString(e)&&e.indexOf("#2174")!==-1&&(e=null),n.__completed=!0,!e&&n.__listeners.load&&n.__listeners.load({type:"load",loaded:n.__loaded,total:n.__total,target:n,lengthComputable:!0}),!e&&n.__listeners.loadend&&n.__listeners.loadend({type:"loadend",loaded:n.__loaded,total:n.__total,target:n,lengthComputable:!0}),"abort"===e&&n.__listeners.abort&&n.__listeners.abort({type:"abort",loaded:n.__loaded,total:n.__total,target:n,lengthComputable:!0}),void 0!==r.status&&t(n,"status",function(){return 0===r.status&&e&&"abort"!==e?500:r.status}),void 0!==r.statusText&&t(n,"statusText",function(){return r.statusText}),t(n,"readyState",function(){return 4}),void 0!==r.response&&t(n,"response",function(){return r.response});var i=r.responseText||(e&&0===r.status&&"abort"!==e?e:void 0);t(n,"responseText",function(){return i}),t(n,"response",function(){return i}),e&&t(n,"err",function(){return e}),n.__fileApiXHR=r,n.onreadystatechange&&n.onreadystatechange(),n.onload&&n.onload()},progress:function(e){if(e.target=n,n.__listeners.progress&&n.__listeners.progress(e),n.__total=e.total,n.__loaded=e.loaded,e.total===e.loaded){var t=this;setTimeout(function(){n.__completed||(n.getAllResponseHeaders=function(){},t.complete(null,{status:204,statusText:"No Content"}))},FileAPI.noContentTimeout||1e4)}},headers:n.__requestHeaders};i.data={},i.files={};for(var o=0;o<r.data.length;o++){var a=r.data[o];null!=a.val&&null!=a.val.name&&null!=a.val.size&&null!=a.val.type?i.files[a.key]=a.val:i.data[a.key]=a.val}setTimeout(function(){if(!FileAPI.hasFlash)throw'Adode Flash Player need to be installed. To check ahead use "FileAPI.hasFlash"';n.__fileApiXHR=FileAPI.upload(i)},1)}else{if(this.__origError)throw this.__origError;e.apply(n,arguments)}}}),window.XMLHttpRequest.__isFileAPIShim=!0,window.FormData=FormData=function(){return{append:function(e,t,n){t.__isFileAPIBlobShim&&(t=t.data[0]),this.data.push({key:e,val:t,name:n})},data:[],__isFileAPIShim:!0}},window.Blob=Blob=function(e){return{data:e,__isFileAPIBlobShim:!0}}}}(),function(){function e(e){return"input"===e[0].tagName.toLowerCase()&&e.attr("type")&&"file"===e.attr("type").toLowerCase()}function t(){try{var e=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");if(e)return!0}catch(t){if(void 0!==navigator.mimeTypes["application/x-shockwave-flash"])return!0}return!1}function n(e){var t=0,n=0;if(window.jQuery)return jQuery(e).offset();if(e.offsetParent)do t+=e.offsetLeft-e.scrollLeft,n+=e.offsetTop-e.scrollTop,e=e.offsetParent;while(e);return{left:t,top:n}}if(FileAPI.shouldLoad){if(FileAPI.hasFlash=t(),FileAPI.forceLoad&&(FileAPI.html5=!1),!FileAPI.upload){var r,i,o,a,s,u=document.createElement("script"),l=document.getElementsByTagName("script");if(window.FileAPI.jsUrl)r=window.FileAPI.jsUrl;else if(window.FileAPI.jsPath)i=window.FileAPI.jsPath;else for(o=0;o<l.length;o++)if(s=l[o].src,a=s.search(/\/ng\-file\-upload[\-a-zA-z0-9\.]*\.js/),a>-1){i=s.substring(0,a+1);break}null==FileAPI.staticPath&&(FileAPI.staticPath=i),u.setAttribute("src",r||i+"FileAPI.min.js"),document.getElementsByTagName("head")[0].appendChild(u)}FileAPI.ngfFixIE=function(r,i,o){if(!t())throw'Adode Flash Player need to be installed. To check ahead use "FileAPI.hasFlash"';var a=function(){var t=i.parent();r.attr("disabled")?t&&t.removeClass("js-fileapi-wrapper"):(i.attr("__ngf_flash_")||(i.unbind("change"),i.unbind("click"),i.bind("change",function(e){s.apply(this,[e]),o.apply(this,[e])}),i.attr("__ngf_flash_","true")),t.addClass("js-fileapi-wrapper"),e(r)||(t.css("position","absolute").css("top",n(r[0]).top+"px").css("left",n(r[0]).left+"px").css("width",r[0].offsetWidth+"px").css("height",r[0].offsetHeight+"px").css("filter","alpha(opacity=0)").css("display",r.css("display")).css("overflow","hidden").css("z-index","900000").css("visibility","visible"),i.css("width",r[0].offsetWidth+"px").css("height",r[0].offsetHeight+"px").css("position","absolute").css("top","0px").css("left","0px")))};r.bind("mouseenter",a);var s=function(e){for(var t=FileAPI.getFiles(e),n=0;n<t.length;n++)void 0===t[n].size&&(t[n].size=0),void 0===t[n].name&&(t[n].name="file"),void 0===t[n].type&&(t[n].type="undefined");e.target||(e.target={}),e.target.files=t,e.target.files!==t&&(e.__files_=t),(e.__files_||e.target.files).item=function(t){return(e.__files_||e.target.files)[t]||null}}},FileAPI.disableFileInput=function(e,t){t?e.removeClass("js-fileapi-wrapper"):e.addClass("js-fileapi-wrapper")}}}(),window.FileReader||(window.FileReader=function(){var e=this,t=!1;this.listeners={},this.addEventListener=function(t,n){e.listeners[t]=e.listeners[t]||[],e.listeners[t].push(n)},this.removeEventListener=function(t,n){e.listeners[t]&&e.listeners[t].splice(e.listeners[t].indexOf(n),1)},this.dispatchEvent=function(t){var n=e.listeners[t.type];if(n)for(var r=0;r<n.length;r++)n[r].call(e,t)},this.onabort=this.onerror=this.onload=this.onloadstart=this.onloadend=this.onprogress=null;var n=function(t,n){var r={type:t,target:e,loaded:n.loaded,total:n.total,error:n.error};return null!=n.result&&(r.target.result=n.result),r},r=function(r){t||(t=!0,e.onloadstart&&e.onloadstart(n("loadstart",r)));var i;"load"===r.type?(e.onloadend&&e.onloadend(n("loadend",r)),i=n("load",r),e.onload&&e.onload(i),e.dispatchEvent(i)):"progress"===r.type?(i=n("progress",r),e.onprogress&&e.onprogress(i),e.dispatchEvent(i)):(i=n("error",r),e.onerror&&e.onerror(i),e.dispatchEvent(i))};this.readAsDataURL=function(e){FileAPI.readAsDataURL(e,r)},this.readAsText=function(e){FileAPI.readAsText(e,r)}}),!window.XMLHttpRequest||window.FileAPI&&FileAPI.shouldLoad||(window.XMLHttpRequest.prototype.setRequestHeader=function(e){return function(t,n){if("__setXHR_"===t){var r=n(this);r instanceof Function&&r(this)}else e.apply(this,arguments)}}(window.XMLHttpRequest.prototype.setRequestHeader));var r=angular.module("ngFileUpload",[]);r.version="12.2.12",r.service("UploadBase",["$http","$q","$timeout",function(e,t,n){function i(r){function i(e){l.notify&&l.notify(e),c.progressFunc&&n(function(){c.progressFunc(e)})}function o(e){return null!=r._start&&s?{loaded:e.loaded+r._start,total:r._file&&r._file.size||e.total,type:e.type,config:r,lengthComputable:!0,target:e.target}:e}function u(){e(r).then(function(e){if(s&&r._chunkSize&&!r._finished&&r._file){var t=r._file&&r._file.size||0;i({loaded:Math.min(r._end,t),total:t,config:r,type:"progress"}),a.upload(r,!0)}else r._finished&&delete r._finished,l.resolve(e)},function(e){l.reject(e)},function(e){l.notify(e)})}r.method=r.method||"POST",r.headers=r.headers||{};var l=r._deferred=r._deferred||t.defer(),c=l.promise;return r.disableProgress||(r.headers.__setXHR_=function(){return function(e){e&&e.upload&&e.upload.addEventListener&&(r.__XHR=e,r.xhrFn&&r.xhrFn(e),e.upload.addEventListener("progress",function(e){e.config=r,i(o(e))},!1),e.upload.addEventListener("load",function(e){e.lengthComputable&&(e.config=r,i(o(e)))},!1))}}),s?r._chunkSize&&r._end&&!r._finished?(r._start=r._end,r._end+=r._chunkSize,u()):r.resumeSizeUrl?e.get(r.resumeSizeUrl).then(function(e){r.resumeSizeResponseReader?r._start=r.resumeSizeResponseReader(e.data):r._start=parseInt((null==e.data.size?e.data:e.data.size).toString()),r._chunkSize&&(r._end=r._start+r._chunkSize),u()},function(e){throw e}):r.resumeSize?r.resumeSize().then(function(e){r._start=e,r._chunkSize&&(r._end=r._start+r._chunkSize),u()},function(e){throw e}):(r._chunkSize&&(r._start=0,r._end=r._start+r._chunkSize),u()):u(),c.success=function(e){return c.then(function(t){e(t.data,t.status,t.headers,r)}),c},c.error=function(e){return c.then(null,function(t){e(t.data,t.status,t.headers,r)}),c},c.progress=function(e){return c.progressFunc=e,c.then(null,null,function(t){e(t)}),c},c.abort=c.pause=function(){return r.__XHR&&n(function(){r.__XHR.abort()}),c},c.xhr=function(e){return r.xhrFn=function(t){return function(){t&&t.apply(c,arguments),e.apply(c,arguments)}}(r.xhrFn),c},a.promisesCount++,c["finally"]&&c["finally"]instanceof Function&&c["finally"](function(){a.promisesCount--}),c}function o(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}var a=this;a.promisesCount=0,this.isResumeSupported=function(){return window.Blob&&window.Blob.prototype.slice};var s=this.isResumeSupported();this.isUploadInProgress=function(){return a.promisesCount>0},this.rename=function(e,t){return e.ngfName=t,e},this.jsonBlob=function(e){null==e||angular.isString(e)||(e=JSON.stringify(e));var t=new window.Blob([e],{type:"application/json"});return t._ngfBlob=!0,t},this.json=function(e){return angular.toJson(e)},this.isFile=function(e){return null!=e&&(e instanceof window.Blob||e.flashId&&e.name&&e.size)},this.upload=function(e,t){function n(t,n){if(t._ngfBlob)return t;if(e._file=e._file||t,null!=e._start&&s){e._end&&e._end>=t.size&&(e._finished=!0,e._end=t.size);var r=t.slice(e._start,e._end||t.size);return r.name=t.name,r.ngfName=t.ngfName,e._chunkSize&&(n.append("_chunkSize",e._chunkSize),n.append("_currentChunkSize",e._end-e._start),n.append("_chunkNumber",Math.floor(e._start/e._chunkSize)),n.append("_totalSize",e._file.size)),r}return t}function r(t,i,o){if(void 0!==i)if(angular.isDate(i)&&(i=i.toISOString()),angular.isString(i))t.append(o,i);else if(a.isFile(i)){var s=n(i,t),u=o.split(",");u[1]&&(s.ngfName=u[1].replace(/^\s+|\s+$/g,""),o=u[0]),e._fileKey=e._fileKey||o,t.append(o,s,s.ngfName||s.name)}else if(angular.isObject(i)){if(i.$$ngfCircularDetection)throw"ngFileUpload: Circular reference in config.data. Make sure specified data for Upload.upload() has no circular reference: "+o;i.$$ngfCircularDetection=!0;try{for(var l in i)if(i.hasOwnProperty(l)&&"$$ngfCircularDetection"!==l){var c=null==e.objectKey?"[i]":e.objectKey;i.length&&parseInt(l)>-1&&(c=null==e.arrayKey?c:e.arrayKey),r(t,i[l],o+c.replace(/[ik]/g,l))}}finally{delete i.$$ngfCircularDetection}}else t.append(o,i)}function u(){e._chunkSize=a.translateScalars(e.resumeChunkSize),e._chunkSize=e._chunkSize?parseInt(e._chunkSize.toString()):null,e.headers=e.headers||{},e.headers["Content-Type"]=void 0,e.transformRequest=e.transformRequest?angular.isArray(e.transformRequest)?e.transformRequest:[e.transformRequest]:[],e.transformRequest.push(function(t){var n,i=new window.FormData;t=t||e.fields||{},e.file&&(t.file=e.file);for(n in t)if(t.hasOwnProperty(n)){var o=t[n];e.formDataAppender?e.formDataAppender(i,n,o):r(i,o,n)}return i})}return t||(e=o(e)),e._isDigested||(e._isDigested=!0,u()),i(e)},this.http=function(t){return t=o(t),t.transformRequest=t.transformRequest||function(t){return window.ArrayBuffer&&t instanceof window.ArrayBuffer||t instanceof window.Blob?t:e.defaults.transformRequest[0].apply(this,arguments)},t._chunkSize=a.translateScalars(t.resumeChunkSize),t._chunkSize=t._chunkSize?parseInt(t._chunkSize.toString()):null,i(t)},this.translateScalars=function(e){if(angular.isString(e)){if(e.search(/kb/i)===e.length-2)return parseFloat(1024*e.substring(0,e.length-2));if(e.search(/mb/i)===e.length-2)return parseFloat(1048576*e.substring(0,e.length-2));if(e.search(/gb/i)===e.length-2)return parseFloat(1073741824*e.substring(0,e.length-2));if(e.search(/b/i)===e.length-1)return parseFloat(e.substring(0,e.length-1));if(e.search(/s/i)===e.length-1)return parseFloat(e.substring(0,e.length-1));if(e.search(/m/i)===e.length-1)return parseFloat(60*e.substring(0,e.length-1));if(e.search(/h/i)===e.length-1)return parseFloat(3600*e.substring(0,e.length-1))}return e},this.urlToBlob=function(n){var r=t.defer();return e({url:n,method:"get",responseType:"arraybuffer"}).then(function(e){var t=new Uint8Array(e.data),i=e.headers("content-type")||"image/WebP",o=new window.Blob([t],{type:i}),a=n.match(/.*\/(.+?)(\?.*)?$/);a.length>1&&(o.name=a[1]),r.resolve(o)},function(e){r.reject(e)}),r.promise},this.setDefaults=function(e){this.defaults=e||{}},this.defaults={},this.version=r.version}]),r.service("Upload",["$parse","$timeout","$compile","$q","UploadExif",function(e,t,n,r,i){function o(e,t,n){var i=[u.emptyPromise()];return angular.forEach(e,function(r,o){0===r.type.indexOf("image/jpeg")&&u.attrGetter("ngfFixOrientation",t,n,{$file:r})&&i.push(u.happyPromise(u.applyExifRotation(r),r).then(function(t){e.splice(o,1,t)}))}),r.all(i)}function a(e,t,n,i){var o=u.attrGetter("ngfResize",t,n);if(!o||!u.isResizeSupported()||!e.length)return u.emptyPromise();if(o instanceof Function){var a=r.defer();return o(e).then(function(r){s(r,e,t,n,i).then(function(e){a.resolve(e)},function(e){a.reject(e)})},function(e){a.reject(e)})}return s(o,e,t,n,i)}function s(e,t,n,i,o){function a(r,a){if(0===r.type.indexOf("image")){if(e.pattern&&!u.validatePattern(r,e.pattern))return;e.resizeIf=function(e,t){return u.attrGetter("ngfResizeIf",n,i,{$width:e,$height:t,$file:r})};var l=u.resize(r,e);s.push(l),l.then(function(e){t.splice(a,1,e)},function(e){r.$error="resize",(r.$errorMessages=r.$errorMessages||{}).resize=!0,r.$errorParam=(e?(e.message?e.message:e)+": ":"")+(r&&r.name),o.$ngfValidations.push({name:"resize",valid:!1}),u.applyModelValidation(o,t)})}}for(var s=[u.emptyPromise()],l=0;l<t.length;l++)a(t[l],l);return r.all(s)}var u=i;return u.getAttrWithDefaults=function(e,t){if(null!=e[t])return e[t];var n=u.defaults[t];return null==n?n:angular.isString(n)?n:JSON.stringify(n)},u.attrGetter=function(t,n,r,i){var o=this.getAttrWithDefaults(n,t);if(!r)return o;try{return i?e(o)(r,i):e(o)(r)}catch(a){if(t.search(/min|max|pattern/i))return o;throw a}},u.shouldUpdateOn=function(e,t,n){var r=u.attrGetter("ngfModelOptions",t,n);return!r||!r.updateOn||r.updateOn.split(" ").indexOf(e)>-1},u.emptyPromise=function(){var e=r.defer(),n=arguments;return t(function(){e.resolve.apply(e,n)}),e.promise},u.rejectPromise=function(){var e=r.defer(),n=arguments;return t(function(){e.reject.apply(e,n)}),e.promise},u.happyPromise=function(e,n){var i=r.defer();return e.then(function(e){i.resolve(e)},function(e){t(function(){throw e}),i.resolve(n)}),i.promise},u.updateModel=function(n,r,i,s,l,c,f){function d(o,a,l,f,d){r.$$ngfPrevValidFiles=o,r.$$ngfPrevInvalidFiles=a;var p=o&&o.length?o[0]:null,h=a&&a.length?a[0]:null;n&&(u.applyModelValidation(n,o),n.$setViewValue(d?p:o)),s&&e(s)(i,{$files:o,$file:p,$newFiles:l,$duplicateFiles:f,$invalidFiles:a,$invalidFile:h,$event:c});var g=u.attrGetter("ngfModelInvalid",r);g&&t(function(){e(g).assign(i,d?h:a)}),t(function(){})}function p(){function e(e,t){return e.name===t.name&&(e.$ngfOrigSize||e.size)===(t.$ngfOrigSize||t.size)&&e.type===t.type}function t(t){var n;for(n=0;n<m.length;n++)if(e(t,m[n]))return!0;for(n=0;n<$.length;n++)if(e(t,$[n]))return!0;return!1}if(l){v=[],b=[];for(var n=0;n<l.length;n++)t(l[n])?b.push(l[n]):v.push(l[n])}}function h(e){return angular.isArray(e)?e:[e]}function g(){function e(){t(function(){d(x?m.concat(w):w,x?$.concat(y):y,l,b,_)},S&&S.debounce?S.debounce.change||S.debounce:0)}var o=k?v:w;a(o,r,i,n).then(function(){k?u.validate(v,x?m.length:0,n,r,i).then(function(t){w=t.validsFiles,y=t.invalidsFiles,e()}):e()},function(){for(var t=0;t<o.length;t++){var n=o[t];if("resize"===n.$error){var r=w.indexOf(n);r>-1&&(w.splice(r,1),y.push(n)),e()}}})}var v,m,$,b=[],y=[],w=[];m=r.$$ngfPrevValidFiles||[],$=r.$$ngfPrevInvalidFiles||[],n&&n.$modelValue&&(m=h(n.$modelValue));var x=u.attrGetter("ngfKeep",r,i);v=(l||[]).slice(0),"distinct"!==x&&u.attrGetter("ngfKeepDistinct",r,i)!==!0||p(r,i);var _=!x&&!u.attrGetter("ngfMultiple",r,i)&&!u.attrGetter("multiple",r);if(!x||v.length){u.attrGetter("ngfBeforeModelChange",r,i,{$files:l,$file:l&&l.length?l[0]:null,$newFiles:v,$duplicateFiles:b,$event:c});var k=u.attrGetter("ngfValidateAfterResize",r,i),S=u.attrGetter("ngfModelOptions",r,i);u.validate(v,x?m.length:0,n,r,i).then(function(e){f?d(v,[],l,b,_):(S&&S.allowInvalid||k?w=v:(w=e.validFiles,y=e.invalidFiles),u.attrGetter("ngfFixOrientation",r,i)&&u.isExifSupported()?o(w,r,i).then(function(){g()}):g())})}},u}]),r.directive("ngfSelect",["$parse","$timeout","$compile","Upload",function(e,t,n,r){function i(e){var t=e.match(/Android[^\d]*(\d+)\.(\d+)/);if(t&&t.length>2){var n=r.defaults.androidFixMinorVersion||4;return parseInt(t[1])<4||parseInt(t[1])===n&&parseInt(t[2])<n}return e.indexOf("Chrome")===-1&&/.*Windows.*Safari.*/.test(e)}function o(e,t,n,r,o,s,u,l){function c(){return"input"===t[0].tagName.toLowerCase()&&n.type&&"file"===n.type.toLowerCase()}function f(){return b("ngfChange")||b("ngfSelect")}function d(t){if(l.shouldUpdateOn("change",n,e)){var i=t.__files_||t.target&&t.target.files,o=[];if(!i)return;for(var a=0;a<i.length;a++)o.push(i[a]);l.updateModel(r,n,e,f(),o.length?o:null,t)}}function p(e,r){function i(t){e.attr("id","ngf-"+t),r.attr("id","ngf-label-"+t)}for(var o=0;o<t[0].attributes.length;o++){var a=t[0].attributes[o];"type"!==a.name&&"class"!==a.name&&"style"!==a.name&&("id"===a.name?(i(a.value),y.push(n.$observe("id",i))):e.attr(a.name,a.value||"required"!==a.name&&"multiple"!==a.name?a.value:a.name))}}function h(){if(c())return t;var e=angular.element('<input type="file">'),n=angular.element("<label>upload</label>");return n.css("visibility","hidden").css("position","absolute").css("overflow","hidden").css("width","0px").css("height","0px").css("border","none").css("margin","0px").css("padding","0px").attr("tabindex","-1"),p(e,n),a.push({el:t,ref:n}),document.body.appendChild(n.append(e)[0]),e}function g(n){if(t.attr("disabled"))return!1;if(!b("ngfSelectDisabled",e)){var r=v(n);if(null!=r)return r;m(n);try{c()||document.body.contains(_[0])||(a.push({el:t,ref:_.parent()}),document.body.appendChild(_.parent()[0]),_.bind("change",d))}catch(o){}return i(navigator.userAgent)?setTimeout(function(){_[0].click()},0):_[0].click(),!1}}function v(e){var t=e.changedTouches||e.originalEvent&&e.originalEvent.changedTouches;if(t){if("touchstart"===e.type)return x=t[0].clientX,w=t[0].clientY,!0;if("touchend"===e.type){var n=t[0].clientX,r=t[0].clientY;if(Math.abs(n-x)>20||Math.abs(r-w)>20)return e.stopPropagation(),e.preventDefault(),!1}return!0}}function m(t){l.shouldUpdateOn("click",n,e)&&_.val()&&(_.val(null),l.updateModel(r,n,e,f(),null,t,!0))}function $(e){if(_&&!_.attr("__ngf_ie10_Fix_")){if(!_[0].parentNode)return void(_=null);e.preventDefault(),e.stopPropagation(),_.unbind("click");var t=_.clone();return _.replaceWith(t),_=t,_.attr("__ngf_ie10_Fix_","true"),_.bind("change",d),_.bind("click",$),_[0].click(),!1}_.removeAttr("__ngf_ie10_Fix_")}var b=function(e,t){return l.attrGetter(e,n,t)};l.registerModelChangeValidator(r,n,e);var y=[];b("ngfMultiple")&&y.push(e.$watch(b("ngfMultiple"),function(){_.attr("multiple",b("ngfMultiple",e))})),b("ngfCapture")&&y.push(e.$watch(b("ngfCapture"),function(){_.attr("capture",b("ngfCapture",e))})),b("ngfAccept")&&y.push(e.$watch(b("ngfAccept"),function(){_.attr("accept",b("ngfAccept",e))})),y.push(n.$observe("accept",function(){_.attr("accept",b("accept"))}));var w=0,x=0,_=t;c()||(_=h()),_.bind("change",d),c()?t.bind("click",m):t.bind("click touchstart touchend",g),navigator.appVersion.indexOf("MSIE 10")!==-1&&_.bind("click",$),r&&r.$formatters.push(function(e){return null!=e&&0!==e.length||_.val()&&_.val(null),e}),e.$on("$destroy",function(){c()||_.parent().remove(),angular.forEach(y,function(e){e()})}),s(function(){for(var e=0;e<a.length;e++){var t=a[e];document.body.contains(t.el[0])||(a.splice(e,1),t.ref.remove())}}),window.FileAPI&&window.FileAPI.ngfFixIE&&window.FileAPI.ngfFixIE(t,_,d)}var a=[];return{restrict:"AEC",require:"?ngModel",link:function(i,a,s,u){o(i,a,s,u,e,t,n,r)}}}]),function(){function e(e){return"img"===e.tagName.toLowerCase()?"image":"audio"===e.tagName.toLowerCase()?"audio":"video"===e.tagName.toLowerCase()?"video":/./}function t(t,n,r,i,o,a,s,u){function l(e){var a=t.attrGetter("ngfNoObjectUrl",o,r);t.dataUrl(e,a)["finally"](function(){n(function(){var t=(a?e.$ngfDataUrl:e.$ngfBlobUrl)||e.$ngfDataUrl;u?i.css("background-image","url('"+(t||"")+"')"):i.attr("src",t),t?i.removeClass("ng-hide"):i.addClass("ng-hide")})})}n(function(){var n=r.$watch(o[a],function(n){var c=s;if("ngfThumbnail"===a&&(c||(c={width:i[0].naturalWidth||i[0].clientWidth,height:i[0].naturalHeight||i[0].clientHeight}),0===c.width&&window.getComputedStyle)){var f=getComputedStyle(i[0]);c={width:parseInt(f.width.slice(0,-2)),height:parseInt(f.height.slice(0,-2))}}return angular.isString(n)?(i.removeClass("ng-hide"),u?i.css("background-image","url('"+n+"')"):i.attr("src",n)):void(!n||!n.type||0!==n.type.search(e(i[0]))||u&&0!==n.type.indexOf("image")?i.addClass("ng-hide"):c&&t.isResizeSupported()?(c.resizeIf=function(e,i){return t.attrGetter("ngfResizeIf",o,r,{$width:e,$height:i,$file:n})},t.resize(n,c).then(function(e){l(e)},function(e){throw e})):l(n))});r.$on("$destroy",function(){n()})})}r.service("UploadDataUrl",["UploadBase","$timeout","$q",function(e,t,n){var r=e;return r.base64DataUrl=function(e){if(angular.isArray(e)){var t=n.defer(),i=0;return angular.forEach(e,function(n){r.dataUrl(n,!0)["finally"](function(){if(i++,i===e.length){var n=[];angular.forEach(e,function(e){n.push(e.$ngfDataUrl)}),t.resolve(n,e)}})}),t.promise}return r.dataUrl(e,!0)},r.dataUrl=function(e,i){if(!e)return r.emptyPromise(e,e);if(i&&null!=e.$ngfDataUrl||!i&&null!=e.$ngfBlobUrl)return r.emptyPromise(i?e.$ngfDataUrl:e.$ngfBlobUrl,e);var o=i?e.$$ngfDataUrlPromise:e.$$ngfBlobUrlPromise;if(o)return o;var a=n.defer();return t(function(){if(window.FileReader&&e&&(!window.FileAPI||navigator.userAgent.indexOf("MSIE 8")===-1||e.size<2e4)&&(!window.FileAPI||navigator.userAgent.indexOf("MSIE 9")===-1||e.size<4e6)){var n=window.URL||window.webkitURL;if(n&&n.createObjectURL&&!i){var o;try{o=n.createObjectURL(e)}catch(s){return void t(function(){e.$ngfBlobUrl="",a.reject()})}t(function(){if(e.$ngfBlobUrl=o,o){a.resolve(o,e),r.blobUrls=r.blobUrls||[],r.blobUrlsTotalSize=r.blobUrlsTotalSize||0,r.blobUrls.push({url:o,size:e.size}),r.blobUrlsTotalSize+=e.size||0;for(var t=r.defaults.blobUrlsMaxMemory||268435456,i=r.defaults.blobUrlsMaxQueueSize||200;(r.blobUrlsTotalSize>t||r.blobUrls.length>i)&&r.blobUrls.length>1;){var s=r.blobUrls.splice(0,1)[0];n.revokeObjectURL(s.url),r.blobUrlsTotalSize-=s.size}}})}else{var u=new FileReader;u.onload=function(n){t(function(){e.$ngfDataUrl=n.target.result,a.resolve(n.target.result,e),t(function(){delete e.$ngfDataUrl},1e3)})},u.onerror=function(){t(function(){e.$ngfDataUrl="",a.reject()})},u.readAsDataURL(e)}}else t(function(){e[i?"$ngfDataUrl":"$ngfBlobUrl"]="",a.reject()})}),o=i?e.$$ngfDataUrlPromise=a.promise:e.$$ngfBlobUrlPromise=a.promise,o["finally"](function(){delete e[i?"$$ngfDataUrlPromise":"$$ngfBlobUrlPromise"]}),o},r}]),r.directive("ngfSrc",["Upload","$timeout",function(e,n){return{restrict:"AE",link:function(r,i,o){t(e,n,r,i,o,"ngfSrc",e.attrGetter("ngfResize",o,r),!1)}}}]),r.directive("ngfBackground",["Upload","$timeout",function(e,n){return{restrict:"AE",link:function(r,i,o){t(e,n,r,i,o,"ngfBackground",e.attrGetter("ngfResize",o,r),!0)}}}]),r.directive("ngfThumbnail",["Upload","$timeout",function(e,n){return{restrict:"AE",link:function(r,i,o){var a=e.attrGetter("ngfSize",o,r);t(e,n,r,i,o,"ngfThumbnail",a,e.attrGetter("ngfAsBackground",o,r))}}}]),r.config(["$compileProvider",function(e){e.imgSrcSanitizationWhitelist&&e.imgSrcSanitizationWhitelist(/^\s*(https?|ftp|mailto|tel|webcal|local|file|data|blob):/),e.aHrefSanitizationWhitelist&&e.aHrefSanitizationWhitelist(/^\s*(https?|ftp|mailto|tel|webcal|local|file|data|blob):/)}]),r.filter("ngfDataUrl",["UploadDataUrl","$sce",function(e,t){return function(n,r,i){if(angular.isString(n))return t.trustAsResourceUrl(n);var o=n&&((r?n.$ngfDataUrl:n.$ngfBlobUrl)||n.$ngfDataUrl);return n&&!o?(!n.$ngfDataUrlFilterInProgress&&angular.isObject(n)&&(n.$ngfDataUrlFilterInProgress=!0,e.dataUrl(n,r)),""):(n&&delete n.$ngfDataUrlFilterInProgress,(n&&o?i?t.trustAsResourceUrl(o):o:n)||"")}}])}(),r.service("UploadValidate",["UploadDataUrl","$q","$timeout",function(e,t,n){function r(e){var t="",n=[];if(e.length>2&&"/"===e[0]&&"/"===e[e.length-1])t=e.substring(1,e.length-1);else{var i=e.split(",");if(i.length>1)for(var o=0;o<i.length;o++){var a=r(i[o]);a.regexp?(t+="("+a.regexp+")",o<i.length-1&&(t+="|")):n=n.concat(a.excludes)}else 0===e.indexOf("!")?n.push("^((?!"+r(e.substring(1)).regexp+").)*$"):(0===e.indexOf(".")&&(e="*"+e),t="^"+e.replace(new RegExp("[.\\\\+*?\\[\\^\\]$(){}=!<>|:\\-]","g"),"\\$&")+"$",t=t.replace(/\\\*/g,".*").replace(/\\\?/g,"."))}return{regexp:t,excludes:n}}function i(e,t){null==t||e.$dirty||(e.$setDirty?e.$setDirty():e.$dirty=!0)}var o=e;return o.validatePattern=function(e,t){if(!t)return!0;var n=r(t),i=!0;if(n.regexp&&n.regexp.length){var o=new RegExp(n.regexp,"i");i=null!=e.type&&o.test(e.type)||null!=e.name&&o.test(e.name)}for(var a=n.excludes.length;a--;){var s=new RegExp(n.excludes[a],"i");i=i&&(null==e.type||s.test(e.type))&&(null==e.name||s.test(e.name))}return i},o.ratioToFloat=function(e){var t=e.toString(),n=t.search(/[x:]/i);return t=n>-1?parseFloat(t.substring(0,n))/parseFloat(t.substring(n+1)):parseFloat(t)},o.registerModelChangeValidator=function(e,t,n){e&&e.$formatters.push(function(r){if(e.$dirty){var i=r;r&&!angular.isArray(r)&&(i=[r]),o.validate(i,0,e,t,n).then(function(){o.applyModelValidation(e,i)})}return r})},o.applyModelValidation=function(e,t){i(e,t),angular.forEach(e.$ngfValidations,function(t){e.$setValidity(t.name,t.valid)})},o.getValidationAttr=function(e,t,n,r,i){var a="ngf"+n[0].toUpperCase()+n.substr(1),s=o.attrGetter(a,e,t,{$file:i});if(null==s&&(s=o.attrGetter("ngfValidate",e,t,{$file:i}))){var u=(r||n).split(".");s=s[u[0]],u.length>1&&(s=s&&s[u[1]])}return s},o.validate=function(e,n,r,i,a){function s(t,n,s){if(e){for(var u=e.length,l=null;u--;){var p=e[u];if(p){var h=o.getValidationAttr(i,a,t,n,p);null!=h&&(s(p,h,u)||(c.indexOf(t)===-1?(p.$error=t,(p.$errorMessages=p.$errorMessages||{})[t]=!0,p.$errorParam=h,d.indexOf(p)===-1&&d.push(p),f||e.splice(u,1),l=!1):e.splice(u,1)))}}null!==l&&r.$ngfValidations.push({name:t,valid:l})}}function u(n,s,u,p,h){function g(t,r,i){function o(o){if(o())if(c.indexOf(n)===-1){if(r.$error=n,(r.$errorMessages=r.$errorMessages||{})[n]=!0,r.$errorParam=i,d.indexOf(r)===-1&&d.push(r),!f){var a=e.indexOf(r);a>-1&&e.splice(a,1)}t.resolve(!1)}else{var s=e.indexOf(r);s>-1&&e.splice(s,1),t.resolve(!0)}else t.resolve(!0)}null!=i?p(r,i).then(function(e){o(function(){return!h(e,i)})},function(){o(function(){return l("ngfValidateForce",{$file:r})})}):t.resolve(!0)}var v=[o.emptyPromise(!0)];e&&(e=void 0===e.length?[e]:e,angular.forEach(e,function(e){var r=t.defer();return v.push(r.promise),
|
9 |
-
!u||null!=e.type&&0===e.type.search(u)?void("dimensions"===n&&null!=o.attrGetter("ngfDimensions",i)?o.imageDimensions(e).then(function(t){g(r,e,l("ngfDimensions",{$file:e,$width:t.width,$height:t.height}))},function(){r.resolve(!1)}):"duration"===n&&null!=o.attrGetter("ngfDuration",i)?o.mediaDuration(e).then(function(t){g(r,e,l("ngfDuration",{$file:e,$duration:t}))},function(){r.resolve(!1)}):g(r,e,o.getValidationAttr(i,a,n,s,e))):void r.resolve(!0)}));var m=t.defer();return t.all(v).then(function(e){for(var t=!0,i=0;i<e.length;i++)if(!e[i]){t=!1;break}r.$ngfValidations.push({name:n,valid:t}),m.resolve(t)}),m.promise}r=r||{},r.$ngfValidations=r.$ngfValidations||[],angular.forEach(r.$ngfValidations,function(e){e.valid=!0});var l=function(e,t){return o.attrGetter(e,i,a,t)},c=(o.attrGetter("ngfIgnoreInvalid",i,a)||"").split(" "),f=o.attrGetter("ngfRunAllValidations",i,a);if(null==e||0===e.length)return o.emptyPromise({validFiles:e,invalidFiles:[]});e=void 0===e.length?[e]:e.slice(0);var d=[];s("pattern",null,o.validatePattern),s("minSize","size.min",function(e,t){return e.size+.1>=o.translateScalars(t)}),s("maxSize","size.max",function(e,t){return e.size-.1<=o.translateScalars(t)});var p=0;if(s("maxTotalSize",null,function(t,n){return p+=t.size,!(p>o.translateScalars(n))||(e.splice(0,e.length),!1)}),s("validateFn",null,function(e,t){return t===!0||null===t||""===t}),!e.length)return o.emptyPromise({validFiles:[],invalidFiles:d});var h=t.defer(),g=[];return g.push(u("maxHeight","height.max",/image/,this.imageDimensions,function(e,t){return e.height<=t})),g.push(u("minHeight","height.min",/image/,this.imageDimensions,function(e,t){return e.height>=t})),g.push(u("maxWidth","width.max",/image/,this.imageDimensions,function(e,t){return e.width<=t})),g.push(u("minWidth","width.min",/image/,this.imageDimensions,function(e,t){return e.width>=t})),g.push(u("dimensions",null,/image/,function(e,t){return o.emptyPromise(t)},function(e){return e})),g.push(u("ratio",null,/image/,this.imageDimensions,function(e,t){for(var n=t.toString().split(","),r=!1,i=0;i<n.length;i++)Math.abs(e.width/e.height-o.ratioToFloat(n[i]))<.01&&(r=!0);return r})),g.push(u("maxRatio","ratio.max",/image/,this.imageDimensions,function(e,t){return e.width/e.height-o.ratioToFloat(t)<1e-4})),g.push(u("minRatio","ratio.min",/image/,this.imageDimensions,function(e,t){return e.width/e.height-o.ratioToFloat(t)>-1e-4})),g.push(u("maxDuration","duration.max",/audio|video/,this.mediaDuration,function(e,t){return e<=o.translateScalars(t)})),g.push(u("minDuration","duration.min",/audio|video/,this.mediaDuration,function(e,t){return e>=o.translateScalars(t)})),g.push(u("duration",null,/audio|video/,function(e,t){return o.emptyPromise(t)},function(e){return e})),g.push(u("validateAsyncFn",null,null,function(e,t){return t},function(e){return e===!0||null===e||""===e})),t.all(g).then(function(){if(f)for(var t=0;t<e.length;t++){var r=e[t];r.$error&&e.splice(t--,1)}f=!1,s("maxFiles",null,function(e,t,r){return n+r<t}),h.resolve({validFiles:e,invalidFiles:d})}),h.promise},o.imageDimensions=function(e){if(e.$ngfWidth&&e.$ngfHeight){var r=t.defer();return n(function(){r.resolve({width:e.$ngfWidth,height:e.$ngfHeight})}),r.promise}if(e.$ngfDimensionPromise)return e.$ngfDimensionPromise;var i=t.defer();return n(function(){return 0!==e.type.indexOf("image")?void i.reject("not image"):void o.dataUrl(e).then(function(t){function r(){var t=s[0].naturalWidth||s[0].clientWidth,n=s[0].naturalHeight||s[0].clientHeight;s.remove(),e.$ngfWidth=t,e.$ngfHeight=n,i.resolve({width:t,height:n})}function o(){s.remove(),i.reject("load error")}function a(){n(function(){s[0].parentNode&&(s[0].clientWidth?r():u++>10?o():a())},1e3)}var s=angular.element("<img>").attr("src",t).css("visibility","hidden").css("position","fixed").css("max-width","none !important").css("max-height","none !important");s.on("load",r),s.on("error",o);var u=0;a(),angular.element(document.getElementsByTagName("body")[0]).append(s)},function(){i.reject("load error")})}),e.$ngfDimensionPromise=i.promise,e.$ngfDimensionPromise["finally"](function(){delete e.$ngfDimensionPromise}),e.$ngfDimensionPromise},o.mediaDuration=function(e){if(e.$ngfDuration){var r=t.defer();return n(function(){r.resolve(e.$ngfDuration)}),r.promise}if(e.$ngfDurationPromise)return e.$ngfDurationPromise;var i=t.defer();return n(function(){return 0!==e.type.indexOf("audio")&&0!==e.type.indexOf("video")?void i.reject("not media"):void o.dataUrl(e).then(function(t){function r(){var t=s[0].duration;e.$ngfDuration=t,s.remove(),i.resolve(t)}function o(){s.remove(),i.reject("load error")}function a(){n(function(){s[0].parentNode&&(s[0].duration?r():u>10?o():a())},1e3)}var s=angular.element(0===e.type.indexOf("audio")?"<audio>":"<video>").attr("src",t).css("visibility","none").css("position","fixed");s.on("loadedmetadata",r),s.on("error",o);var u=0;a(),angular.element(document.body).append(s)},function(){i.reject("load error")})}),e.$ngfDurationPromise=i.promise,e.$ngfDurationPromise["finally"](function(){delete e.$ngfDurationPromise}),e.$ngfDurationPromise},o}]),r.service("UploadResize",["UploadValidate","$q",function(e,t){var n=e,r=function(e,t,n,r,i){var o=i?Math.max(n/e,r/t):Math.min(n/e,r/t);return{width:e*o,height:t*o,marginX:e*o-n,marginY:t*o-r}},i=function(e,i,o,a,s,u,l,c){var f=t.defer(),d=document.createElement("canvas"),p=document.createElement("img");return p.setAttribute("style","visibility:hidden;position:fixed;z-index:-100000"),document.body.appendChild(p),p.onload=function(){var e=p.width,t=p.height;if(p.parentNode.removeChild(p),null!=c&&c(e,t)===!1)return void f.reject("resizeIf");try{if(u){var h=n.ratioToFloat(u),g=e/t;g<h?(i=e,o=i/h):(o=t,i=o*h)}i||(i=e),o||(o=t);var v=r(e,t,i,o,l);d.width=Math.min(v.width,i),d.height=Math.min(v.height,o);var m=d.getContext("2d");m.drawImage(p,Math.min(0,-v.marginX/2),Math.min(0,-v.marginY/2),v.width,v.height),f.resolve(d.toDataURL(s||"image/WebP",a||.934))}catch($){f.reject($)}},p.onerror=function(){p.parentNode.removeChild(p),f.reject()},p.src=e,f.promise};return n.dataUrltoBlob=function(e,t,n){for(var r=e.split(","),i=r[0].match(/:(.*?);/)[1],o=atob(r[1]),a=o.length,s=new Uint8Array(a);a--;)s[a]=o.charCodeAt(a);var u=new window.Blob([s],{type:i});return u.name=t,u.$ngfOrigSize=n,u},n.isResizeSupported=function(){var e=document.createElement("canvas");return window.atob&&e.getContext&&e.getContext("2d")&&window.Blob},n.isResizeSupported()&&Object.defineProperty(window.Blob.prototype,"name",{get:function(){return this.$ngfName},set:function(e){this.$ngfName=e},configurable:!0}),n.resize=function(e,r){if(0!==e.type.indexOf("image"))return n.emptyPromise(e);var o=t.defer();return n.dataUrl(e,!0).then(function(t){i(t,r.width,r.height,r.quality,r.type||e.type,r.ratio,r.centerCrop,r.resizeIf).then(function(i){if("image/jpeg"===e.type&&r.restoreExif!==!1)try{i=n.restoreExif(t,i)}catch(a){setTimeout(function(){throw a},1)}try{var s=n.dataUrltoBlob(i,e.name,e.size);o.resolve(s)}catch(a){o.reject(a)}},function(t){"resizeIf"===t&&o.resolve(e),o.reject(t)})},function(e){o.reject(e)}),o.promise},n}]),function(){function e(e,n,r,i,o,a,s,u,l,c){function f(){return n.attr("disabled")||m("ngfDropDisabled",e)}function d(t,n){u.updateModel(i,r,e,m("ngfChange")||m("ngfDrop"),t,n)}function p(t,n){if(!u.shouldUpdateOn(t,r,e)||"string"!=typeof n)return u.rejectPromise([]);var i=[];n.replace(/<(img src|img [^>]* src) *=\"([^\"]*)\"/gi,function(e,t,n){i.push(n)});var o=[],a=[];if(i.length){angular.forEach(i,function(e){o.push(u.urlToBlob(e).then(function(e){a.push(e)}))});var s=c.defer();return c.all(o).then(function(){s.resolve(a)},function(e){s.reject(e)}),s.promise}return u.emptyPromise()}function h(e,t,n,r){var i=m("ngfDragOverClass",e,{$event:n}),o="dragover";if(angular.isString(i))o=i;else if(i&&(i.delay&&(w=i.delay),i.accept||i.reject)){var a=n.dataTransfer.items;if(null!=a&&a.length)for(var s=i.pattern||m("ngfPattern",e,{$event:n}),l=a.length;l--;){if(!u.validatePattern(a[l],s)){o=i.reject;break}o=i.accept}else o=i.accept}r(o)}function g(t,n,i,o){function a(e,t){var n=c.defer();if(null!=e)if(e.isDirectory){var r=[u.emptyPromise()];if(d){var i={type:"directory"};i.name=i.path=(t||"")+e.name,p.push(i)}var o=e.createReader(),s=[],g=function(){o.readEntries(function(i){try{i.length?(s=s.concat(Array.prototype.slice.call(i||[],0)),g()):(angular.forEach(s.slice(0),function(n){p.length<=l&&h<=f&&r.push(a(n,(t?t:"")+e.name+"/"))}),c.all(r).then(function(){n.resolve()},function(e){n.reject(e)}))}catch(o){n.reject(o)}},function(e){n.reject(e)})};g()}else e.file(function(e){try{e.path=(t?t:"")+e.name,d&&(e=u.rename(e,e.path)),p.push(e),h+=e.size,n.resolve()}catch(r){n.reject(r)}},function(e){n.reject(e)});return n.promise}var l=u.getValidationAttr(r,e,"maxFiles");null==l&&(l=Number.MAX_VALUE);var f=u.getValidationAttr(r,e,"maxTotalSize");null==f&&(f=Number.MAX_VALUE);var d=m("ngfIncludeDir",e),p=[],h=0,g=[u.emptyPromise()];if(t&&t.length>0&&"file:"!==s.location.protocol)for(var v=0;v<t.length;v++){if(t[v].webkitGetAsEntry&&t[v].webkitGetAsEntry()&&t[v].webkitGetAsEntry().isDirectory){var $=t[v].webkitGetAsEntry();if($.isDirectory&&!i)continue;null!=$&&g.push(a($))}else{var b=t[v].getAsFile();null!=b&&(p.push(b),h+=b.size)}if(p.length>l||h>f||!o&&p.length>0)break}else if(null!=n)for(var y=0;y<n.length;y++){var w=n.item(y);if((w.type||w.size>0)&&(p.push(w),h+=w.size),p.length>l||h>f||!o&&p.length>0)break}var x=c.defer();return c.all(g).then(function(){if(o||d||!p.length)x.resolve(p);else{for(var e=0;p[e]&&"directory"===p[e].type;)e++;x.resolve([p[e]])}},function(e){x.reject(e)}),x.promise}var v=t(),m=function(e,t,n){return u.attrGetter(e,r,t,n)};if(m("dropAvailable")&&a(function(){e[m("dropAvailable")]?e[m("dropAvailable")].value=v:e[m("dropAvailable")]=v}),!v)return void(m("ngfHideOnDropNotAvailable",e)===!0&&n.css("display","none"));null==m("ngfSelect")&&u.registerModelChangeValidator(i,r,e);var $,b=null,y=o(m("ngfStopPropagation")),w=1;n[0].addEventListener("dragover",function(t){if(!f()&&u.shouldUpdateOn("drop",r,e)){if(t.preventDefault(),y(e)&&t.stopPropagation(),navigator.userAgent.indexOf("Chrome")>-1){var i=t.dataTransfer.effectAllowed;t.dataTransfer.dropEffect="move"===i||"linkMove"===i?"move":"copy"}a.cancel(b),$||($="C",h(e,r,t,function(r){$=r,n.addClass($),m("ngfDrag",e,{$isDragging:!0,$class:$,$event:t})}))}},!1),n[0].addEventListener("dragenter",function(t){!f()&&u.shouldUpdateOn("drop",r,e)&&(t.preventDefault(),y(e)&&t.stopPropagation())},!1),n[0].addEventListener("dragleave",function(t){!f()&&u.shouldUpdateOn("drop",r,e)&&(t.preventDefault(),y(e)&&t.stopPropagation(),b=a(function(){$&&n.removeClass($),$=null,m("ngfDrag",e,{$isDragging:!1,$event:t})},w||100))},!1),n[0].addEventListener("drop",function(t){if(!f()&&u.shouldUpdateOn("drop",r,e)){t.preventDefault(),y(e)&&t.stopPropagation(),$&&n.removeClass($),$=null;var i,o=t.dataTransfer.items;try{i=t.dataTransfer&&t.dataTransfer.getData&&t.dataTransfer.getData("text/html")}catch(a){}g(o,t.dataTransfer.files,m("ngfAllowDir",e)!==!1,m("multiple")||m("ngfMultiple",e)).then(function(e){e.length?d(e,t):p("dropUrl",i).then(function(e){d(e,t)})})}},!1),n[0].addEventListener("paste",function(t){if(navigator.userAgent.toLowerCase().indexOf("firefox")>-1&&m("ngfEnableFirefoxPaste",e)&&t.preventDefault(),!f()&&u.shouldUpdateOn("paste",r,e)){var n=[],i=t.clipboardData||t.originalEvent.clipboardData;if(i&&i.items)for(var o=0;o<i.items.length;o++)i.items[o].type.indexOf("image")!==-1&&n.push(i.items[o].getAsFile());n.length?d(n,t):p("pasteUrl",i).then(function(e){d(e,t)})}},!1),navigator.userAgent.toLowerCase().indexOf("firefox")>-1&&m("ngfEnableFirefoxPaste",e)&&(n.attr("contenteditable",!0),n.on("keypress",function(e){e.metaKey||e.ctrlKey||e.preventDefault()}))}function t(){var e=document.createElement("div");return"draggable"in e&&"ondrop"in e&&!/Edge\/12./i.test(navigator.userAgent)}r.directive("ngfDrop",["$parse","$timeout","$window","Upload","$http","$q",function(t,n,r,i,o,a){return{restrict:"AEC",require:"?ngModel",link:function(s,u,l,c){e(s,u,l,c,t,n,r,i,o,a)}}}]),r.directive("ngfNoFileDrop",function(){return function(e,n){t()&&n.css("display","none")}}),r.directive("ngfDropAvailable",["$parse","$timeout","Upload",function(e,n,r){return function(i,o,a){if(t()){var s=e(r.attrGetter("ngfDropAvailable",a));n(function(){s(i),s.assign&&s.assign(i,!0)})}}}])}(),r.service("UploadExif",["UploadResize","$q",function(e,t){function n(e,t,n,r){switch(t){case 2:return e.transform(-1,0,0,1,n,0);case 3:return e.transform(-1,0,0,-1,n,r);case 4:return e.transform(1,0,0,-1,0,r);case 5:return e.transform(0,1,1,0,0,0);case 6:return e.transform(0,1,-1,0,r,0);case 7:return e.transform(0,-1,-1,0,r,n);case 8:return e.transform(0,-1,1,0,0,n)}}function r(e){for(var t="",n=new Uint8Array(e),r=n.byteLength,i=0;i<r;i++)t+=String.fromCharCode(n[i]);return window.btoa(t)}var i=e;return i.isExifSupported=function(){return window.FileReader&&(new FileReader).readAsArrayBuffer&&i.isResizeSupported()},i.readOrientation=function(e){var n=t.defer(),r=new FileReader,i=e.slice?e.slice(0,65536):e;return r.readAsArrayBuffer(i),r.onerror=function(e){return n.reject(e)},r.onload=function(e){var t={orientation:1},r=new DataView(this.result);if(65496!==r.getUint16(0,!1))return n.resolve(t);for(var i=r.byteLength,o=2;o<i;){var a=r.getUint16(o,!1);if(o+=2,65505===a){if(1165519206!==r.getUint32(o+=2,!1))return n.resolve(t);var s=18761===r.getUint16(o+=6,!1);o+=r.getUint32(o+4,s);var u=r.getUint16(o,s);o+=2;for(var l=0;l<u;l++)if(274===r.getUint16(o+12*l,s)){var c=r.getUint16(o+12*l+8,s);return c>=2&&c<=8&&(r.setUint16(o+12*l+8,1,s),t.fixedArrayBuffer=e.target.result),t.orientation=c,n.resolve(t)}}else{if(65280!==(65280&a))break;o+=r.getUint16(o,!1)}}return n.resolve(t)},n.promise},i.applyExifRotation=function(e){if(0!==e.type.indexOf("image/jpeg"))return i.emptyPromise(e);var o=t.defer();return i.readOrientation(e).then(function(t){return t.orientation<2||t.orientation>8?o.resolve(e):void i.dataUrl(e,!0).then(function(a){var s=document.createElement("canvas"),u=document.createElement("img");u.onload=function(){try{s.width=t.orientation>4?u.height:u.width,s.height=t.orientation>4?u.width:u.height;var a=s.getContext("2d");n(a,t.orientation,u.width,u.height),a.drawImage(u,0,0);var l=s.toDataURL(e.type||"image/WebP",.934);l=i.restoreExif(r(t.fixedArrayBuffer),l);var c=i.dataUrltoBlob(l,e.name);o.resolve(c)}catch(f){return o.reject(f)}},u.onerror=function(){o.reject()},u.src=a},function(e){o.reject(e)})},function(e){o.reject(e)}),o.promise},i.restoreExif=function(e,t){var n={};return n.KEY_STR="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n.encode64=function(e){var t,n,r,i,o,a="",s="",u="",l=0;do t=e[l++],n=e[l++],s=e[l++],r=t>>2,i=(3&t)<<4|n>>4,o=(15&n)<<2|s>>6,u=63&s,isNaN(n)?o=u=64:isNaN(s)&&(u=64),a=a+this.KEY_STR.charAt(r)+this.KEY_STR.charAt(i)+this.KEY_STR.charAt(o)+this.KEY_STR.charAt(u),t=n=s="",r=i=o=u="";while(l<e.length);return a},n.restore=function(e,t){e.match("data:image/jpeg;base64,")&&(e=e.replace("data:image/jpeg;base64,",""));var n=this.decode64(e),r=this.slice2Segments(n),i=this.exifManipulation(t,r);return"data:image/jpeg;base64,"+this.encode64(i)},n.exifManipulation=function(e,t){var n=this.getExifArray(t),r=this.insertExif(e,n);return new Uint8Array(r)},n.getExifArray=function(e){for(var t,n=0;n<e.length;n++)if(t=e[n],255===t[0]&225===t[1])return t;return[]},n.insertExif=function(e,t){var n=e.replace("data:image/jpeg;base64,",""),r=this.decode64(n),i=r.indexOf(255,3),o=r.slice(0,i),a=r.slice(i),s=o;return s=s.concat(t),s=s.concat(a)},n.slice2Segments=function(e){for(var t=0,n=[];;){if(255===e[t]&218===e[t+1])break;if(255===e[t]&216===e[t+1])t+=2;else{var r=256*e[t+2]+e[t+3],i=t+r+2,o=e.slice(t,i);n.push(o),t=i}if(t>e.length)break}return n},n.decode64=function(e){var t,n,r,i,o,a="",s="",u=0,l=[],c=/[^A-Za-z0-9\+\/\=]/g;c.exec(e)&&console.log("There were invalid base64 characters in the input text.\nValid base64 characters are A-Z, a-z, 0-9, NaNExpect errors in decoding."),e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");do r=this.KEY_STR.indexOf(e.charAt(u++)),i=this.KEY_STR.indexOf(e.charAt(u++)),o=this.KEY_STR.indexOf(e.charAt(u++)),s=this.KEY_STR.indexOf(e.charAt(u++)),t=r<<2|i>>4,n=(15&i)<<4|o>>2,a=(3&o)<<6|s,l.push(t),64!==o&&l.push(n),64!==s&&l.push(a),t=n=a="",r=i=o=s="";while(u<e.length);return l},n.restore(e,t)},i}])},{}],48:[function(e,t,n){e("./dist/ng-file-upload-all"),t.exports="ngFileUpload"},{"./dist/ng-file-upload-all":47}]},{},[41]);
|
1 |
+
!function e(t,n,r){function i(a,s){if(!n[a]){if(!t[a]){var u="function"==typeof require&&require;if(!s&&u)return u(a,!0);if(o)return o(a,!0);var l=new Error("Cannot find module '"+a+"'");throw l.code="MODULE_NOT_FOUND",l}var c=n[a]={exports:{}};t[a][0].call(c.exports,function(e){var n=t[a][1][e];return i(n?n:e)},c,c.exports,e,t,n,r)}return n[a].exports}for(var o="function"==typeof require&&require,a=0;a<r.length;a++)i(r[a]);return i}({1:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./app.controller"),o=r(i),a={bindings:{settingsName:"@"},controller:o["default"],template:'<navbar id="settings-navbar"\n tabs="$ctrl.config.tabs"\n page="$ctrl.config.page"\n links="$ctrl.config.links"\n current-tab="$ctrl.config.currentTab">\n </navbar>\n <form method="POST" enctype="multipart/form-data" id="jpibfi-form" action="{{ $ctrl.config.save.post_url }}">\n <input name="{{ ::$ctrl.config.save.action }}" value="{{ ::$ctrl.config.save.nonce }}" type="hidden" />\n <input name="{{ ::$ctrl.config.save.tab }}" value="{{ ::$ctrl.config.currentTab }}" type="hidden" />\n <select-editor\n ng-if="$ctrl.config.currentTab == \'select\'"\n settings="$ctrl.config.settings"\n i18n="$ctrl.config.i18n.editor">\n </select-editor>\n <visual-editor\n ng-if="$ctrl.config.currentTab == \'visual\'"\n settings="$ctrl.config.settings"\n i18n="$ctrl.config.i18n.editor">\n </visual-editor>\n <advanced-editor\n ng-if="$ctrl.config.currentTab == \'advanced\'"\n settings="$ctrl.config.settings"\n i18n="$ctrl.config.i18n.editor">\n </advanced-editor>\n <import-editor\n ng-if="$ctrl.config.currentTab == \'import\'"\n settings="$ctrl.config.settings"\n i18n="$ctrl.config.i18n.editor">\n </import-editor>\n <input ng-if="$ctrl.config.currentTab == \'select\' || $ctrl.config.currentTab == \'visual\' || $ctrl.config.currentTab == \'advanced\'" \n type="submit" class="button button-primary" value="{{ ::$ctrl.config.save.submit }}" /> \n </form>\n '};n["default"]=a},{"./app.controller":2}],2:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t){r(this,e),this.linkService=t,this.config={},this.settingsValue={}}return i(e,[{key:"$onInit",value:function(){this.config=window[this.settingsName],this.linkService.init(this.config.page)}}]),e}();o.$inject=["linkService"],n["default"]=o},{}],3:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("angular-sanitize"),s=r(a),u=e("ng-file-upload"),l=r(u),c=e("angular-drag-and-drop-lists"),f=(r(c),e("./app.component")),d=r(f),p=e("./components/components"),h=r(p),g=e("./common/components"),$=r(g),v=e("./services"),m=r(v),y=o["default"].module("app",[s["default"],l["default"],h["default"],$["default"],m["default"]]).component("app",d["default"]).name;n["default"]=y},{"./app.component":1,"./common/components":8,"./components/components":18,"./services":35,angular:42,"angular-drag-and-drop-lists":38,"angular-sanitize":40,"ng-file-upload":44}],4:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./../base.controller"),o=r(i),a={bindings:{settings:"<",i18n:"<"},controller:o["default"],template:'\n <h2>{{ $ctrl.i18n.title }}</h2>\n <table class="form-table">\n <tbody>\n <tr>\n <th>{{ ::$ctrl.i18n.filters_label }}</th>\n <td>\n <p>\n <filter name="$ctrl.settings.filter_the_content_on" priority="$ctrl.settings.filter_the_content_priority"\n update="$ctrl.update($event)" template="$ctrl.i18n.filter_template">\n </filter>\n </p>\n <p>\n <filter name="$ctrl.settings.filter_the_excerpt_on" priority="$ctrl.settings.filter_the_excerpt_priority"\n update="$ctrl.update($event)" template="$ctrl.i18n.filter_template">\n </filter>\n </p>\n <p>\n <filter name="$ctrl.settings.filter_post_thumbnail_html_on" priority="$ctrl.settings.filter_post_thumbnail_html_priority"\n update="$ctrl.update($event)" template="$ctrl.i18n.filter_template">\n </filter>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.filters_description"></p>\n </td>\n </tr>\n </tbody>\n </table>\n '};n["default"]=a},{"./../base.controller":7}],5:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t){r(this,e),this.$compile=t,this.restrict="E",this.scope={name:"=",priority:"=",template:"=",update:"&"}}return i(e,[{key:"link",value:function(e,t,n){var r=e.template,i=r.replace("%name%",'<editor-checkbox args="name" on-update="update({ $event })" add-br="false"></editor-checkbox>').replace("%priority%",'<editor-number args="priority" on-update="update({ $event })"></editor-number>');t.html(i),this.$compile(t.contents())(e)}}]),e}();n["default"]=o},{}],6:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./filter.directive"),s=r(a),u=e("./advanced.component"),l=r(u),c=e("./../../components/components"),f=r(c),d=o["default"].module("app.common.advanced",[f["default"]]).directive("filter",["$compile",function(e){return new s["default"](e)}]).component("advancedEditor",l["default"]).name;n["default"]=d},{"./../../components/components":18,"./advanced.component":4,"./filter.directive":5,angular:42}],7:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e)}return o(e,[{key:"$onChanges",value:function(e){var t=this;e.settings&&(this.settings=i({},this.settings),this.values=Object.keys(this.settings).reduce(function(e,n){return e[n]=t.settings[n].value,e},{}))}},{key:"update",value:function(e){var t=e.key,n=e.value;this.values[t]=n}},{key:"updateValue",value:function(e,t){this.settings[e]=i({},this.settings[e],{value:t}),this.values[e]=t}}]),e}();n["default"]=a},{}],8:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./select"),s=r(a),u=e("./visual"),l=r(u),c=e("./import"),f=r(c),d=e("./advanced"),p=r(d),h=o["default"].module("app.common",[s["default"],l["default"],f["default"],p["default"]]).name;n["default"]=h},{"./advanced":6,"./import":11,"./select":12,"./visual":15,angular:42}],9:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./import.controller"),o=r(i),a={bindings:{i18n:"<"},require:{form:"^form"},controller:o["default"],template:'\n <h2>{{ ::$ctrl.i18n.title }}</h2>\n <table class="form-table">\n <tbody>\n <tr>\n <th><label>{{ ::$ctrl.i18n.export_title }}</label></th>\n <td>\n <a href="{{ ::$ctrl.i18n.export_url }}" class="button button-default">\n {{ ::$ctrl.i18n.export_button_text }}\n </a>\n </td>\n </tr>\n <tr>\n <th><label>{{ ::$ctrl.i18n.import_title }}</label></th>\n <td>\n <input type="file" name="import" ng-change="$ctrl.upload()" ng-model="$ctrl.file" ngf-accept="\'.json\'"\n ngf-select="$ctrl.upload()" ngf-max-size="1MB" />\n </td>\n </tr>\n </tbody>\n </table>\n '};n["default"]=a},{"./import.controller":10}],10:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t){r(this,e),this.Upload=t}return i(e,[{key:"upload",value:function(){document.getElementById("jpibfi-form").submit()}}]),e}();o.$inject=["Upload"],n["default"]=o},{}],11:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./import.component"),s=r(a),u=o["default"].module("app.common.import",[]).component("importEditor",s["default"]).name;n["default"]=u},{"./import.component":9,angular:42}],12:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./resolution.directive"),s=r(a),u=e("./select.component"),l=r(u),c=e("./../../components/components"),f=r(c),d=o["default"].module("app.common.select",[f["default"]]).directive("resolution",["$compile",function(e){return new s["default"](e)}]).component("selectEditor",l["default"]).name;n["default"]=d},{"./../../components/components":18,"./resolution.directive":13,"./select.component":14,angular:42}],13:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t){r(this,e),this.$compile=t,this.restrict="E",this.scope={height:"=",width:"=",template:"=",update:"&"}}return i(e,[{key:"link",value:function(e,t,n){var r=e.template,i=r.replace("%height%",'<editor-number args="height" on-update="update({ $event })"></editor-number>').replace("%width%",'<editor-number args="width" on-update="update({ $event })"></editor-number>');t.html(i),this.$compile(t.contents())(e)}}]),e}();n["default"]=o},{}],14:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./../base.controller"),o=r(i),a={bindings:{settings:"<",i18n:"<"},controller:o["default"],template:'\n <h2>{{ $ctrl.i18n.title }}</h2>\n <table class="form-table">\n <tbody>\n <tr>\n <th><label for="image_selector">{{ ::$ctrl.settings.image_selector.label }}</label></th>\n <td>\n <editor-text args="$ctrl.settings.image_selector" on-update="$ctrl.update($event)"></editor-text>\n <p class="description" ng-bind-html="$ctrl.settings.image_selector.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label for="disabled_classes">{{ ::$ctrl.settings.disabled_classes.label }}</label></th>\n <td>\n <editor-text args="$ctrl.settings.disabled_classes" on-update="$ctrl.update($event)"></editor-text>\n <p class="description" ng-bind-html="$ctrl.settings.disabled_classes.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label for="enabled_classes">{{ ::$ctrl.settings.enabled_classes.label }}</label></th>\n <td>\n <editor-text args="$ctrl.settings.enabled_classes" on-update="$ctrl.update($event)"></editor-text>\n <p class="description" ng-bind-html="$ctrl.settings.enabled_classes.desc"></p>\n </td>\n </tr>\n <tr>\n <th>{{ ::$ctrl.i18n.image_resolution_label }}</th>\n <td>\n <p>\n <resolution height="$ctrl.settings.min_image_height_small" width="$ctrl.settings.min_image_width_small"\n update="$ctrl.update($event)" template="$ctrl.i18n.min_resolution_template_small">\n </resolution>\n </p>\n <p>\n <resolution height="$ctrl.settings.min_image_height" width="$ctrl.settings.min_image_width"\n update="$ctrl.update($event)" template="$ctrl.i18n.min_resolution_template">\n </resolution>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.image_resolution_desc"></p>\n <p class="description" ng-bind-html="$ctrl.i18n.image_resolution_desc_2"></p>\n </td>\n </tr>\n <tr>\n <th>{{ ::$ctrl.i18n.show_on_field_label }}</th>\n <td>\n <p>\n <label for="show_on">{{ ::$ctrl.settings.show_on.label }}:</label><br/>\n <editor-textarea args="$ctrl.settings.show_on" on-update="$ctrl.update($event)"></editor-text>\n </p>\n <p>\n <label for="disable_on">{{ ::$ctrl.settings.disable_on.label }}:</label><br/>\n <editor-textarea args="$ctrl.settings.disable_on" on-update="$ctrl.update($event)"></editor-text>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.show_on_field_desc"></p>\n </td>\n </tr>\n </tbody>\n </table>\n '};n["default"]=a},{"./../base.controller":7}],15:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./visual.component"),s=r(a),u=e("./../../components/components"),l=r(u),c=o["default"].module("app.common.visual",[l["default"]]).component("visualEditor",s["default"]).name;n["default"]=c},{"./../../components/components":18,"./visual.component":16,angular:42}],16:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./visual.controller"),o=r(i),a={bindings:{settings:"<",i18n:"<"},controller:o["default"],template:'\n <h2>{{ $ctrl.i18n.title }}</h2>\n <table class="form-table">\n <tbody>\n <tr>\n <th><label for="show_button">{{ ::$ctrl.settings.show_button.label }}</label></th>\n <td>\n <editor-select args="$ctrl.settings.show_button" on-update="$ctrl.update($event)"></editor-select>\n <p class="description" ng-bind-html="$ctrl.settings.show_button.desc"></p>\n <p ng-if="$ctrl.values.show_button != \'hover\'">\n <b ng-bind-html="$ctrl.i18n.pro_feature_error"></b>\n </p>\n </td>\n </tr>\n <tr>\n <th><label>{{ ::$ctrl.settings.description_option.label }}</label></th>\n <td>\n <editor-sortable-select args="$ctrl.settings.description_option" on-update="$ctrl.update($event)"></editor-sortable-select>\n <p class="description" ng-bind-html="$ctrl.settings.description_option.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label for="pinLinkedImages">{{ ::$ctrl.settings.pinLinkedImages.label }}</label></th>\n <td>\n <editor-checkbox args="$ctrl.settings.pinLinkedImages" on-update="$ctrl.update($event)"></editor-checkbox>\n <p class="description" ng-bind-html="$ctrl.settings.pinLinkedImages.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label for="transparency_value">{{ ::$ctrl.settings.transparency_value.label }}</label></th>\n <td>\n <editor-number args="$ctrl.settings.transparency_value" on-update="$ctrl.update($event)"></editor-number>\n <p class="description" ng-bind-html="$ctrl.settings.transparency_value.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label>{{ ::$ctrl.settings.pin_image.label }}</label></th>\n <td>\n <table class="jpibfi-inner-table">\n <tr>\n <th>{{ ::$ctrl.i18n.mode }}</th>\n <th ng-if="$ctrl.values.pin_image != \'old_default\'">{{ ::$ctrl.i18n.settings }}</th>\n <th>{{ ::$ctrl.i18n.preview }}</th>\n </tr>\n <tr>\n <td>\n <p><label><input type="radio" ng_model="$ctrl.values.pin_image" value="old_default">{{ ::$ctrl.settings.pin_image.options[\'old_default\'] }}</label></p>\n <p><label><input type="radio" ng_model="$ctrl.values.pin_image" value="default">{{ ::$ctrl.settings.pin_image.options[\'default\'] }}</label></p>\n <p><label><input type="radio" ng_model="$ctrl.values.pin_image" value="custom">{{ ::$ctrl.settings.pin_image.options[\'custom\'] }}</label></p>\n </td>\n <td ng-if="$ctrl.values.pin_image != \'old_default\'">\n <div ng-show="$ctrl.values.pin_image == \'default\'">\n <p>\n <label for="pin_image_icon">{{ ::$ctrl.settings.pin_image_icon.label }}</label>\n <editor-select args="$ctrl.settings.pin_image_icon" on-update="$ctrl.update($event)"></editor-select>\n <p ng-if="$ctrl.values.pin_image_icon != \'circle\'">\n <b ng-bind-html="$ctrl.i18n.pro_feature_error"></b>\n </p>\n </p>\n <p>\n <label for="pin_image_size">{{ ::$ctrl.settings.pin_image_size.label }}</label>\n <editor-select args="$ctrl.settings.pin_image_size" on-update="$ctrl.update($event)"></editor-select>\n </p>\n <p>\n <label for="pin_image_button">{{ ::$ctrl.settings.pin_image_button.label }}</label>\n <editor-select args="$ctrl.settings.pin_image_button" on-update="$ctrl.update($event)"></editor-select>\n </p>\n </div>\n <div ng-if="$ctrl.values.pin_image == \'custom\'">\n <p><button class="button button-default" ng-click="$ctrl.upload()">{{ ::$ctrl.i18n.custom_button_upload }}</button></p>\n <p>\n <label for="custom_image_url">{{ ::$ctrl.settings.custom_image_url.label }}</label>\n <editor-text args="$ctrl.settings.custom_image_url" on-update="$ctrl.update($event)"></editor-text>\n </p>\n <p>\n <div style="display: inline-block; width: 49%;">\n <label for="custom_image_height">{{ ::$ctrl.settings.custom_image_height.label }}</label>\n <editor-number args="$ctrl.settings.custom_image_height" on-update="$ctrl.update($event)"></editor-number>\n </div>\n <div style="display: inline-block; width: 49%;">\n <label for="custom_image_width">{{ ::$ctrl.settings.custom_image_width.label }}</label>\n <editor-number args="$ctrl.settings.custom_image_width" on-update="$ctrl.update($event)"></editor-number>\n </div>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.custom_button_desc"></p>\n </div>\n </td>\n <td>\n <div ng-if="$ctrl.values.pin_image == \'old_default\'">\n <a class="pinit-button old_default"><span></span></a>\n </div>\n <div ng-show="$ctrl.values.pin_image == \'default\'">\n <a class="pinit-button default" ng-class="[\'jpibfi-size-\' + $ctrl.values.pin_image_size, \'jpibfi-button-\' + $ctrl.values.pin_image_button]">\n <span ng-class="[\'jpibfi-icon-\' + $ctrl.values.pin_image_icon]"></span>\n </a>\n </div>\n <div ng-show="$ctrl.values.pin_image == \'custom\'">\n <div ng-if="$ctrl.values.custom_image_url">\n <div style="width: {{ $ctrl.values.custom_image_width }}px;\n height: {{ $ctrl.values.custom_image_height }}px;\n background-image: url(\'{{ $ctrl.values.custom_image_url }}\');">\n </div>\n </div>\n <div ng-if="!$ctrl.values.custom_image_url">\n {{ ::$ctrl.i18n.custom_button_no_image_to_preview }}\n </div>\n </div>\n </td>\n </tr>\n </table>\n </tr>\n <tr>\n <th><label for="button_position">{{ ::$ctrl.settings.button_position.label }}</label></th>\n <td>\n <editor-select args="$ctrl.settings.button_position" on-update="$ctrl.update($event)"></editor-select>\n <p class="description" ng-bind-html="$ctrl.settings.button_position.desc"></p>\n </td>\n </tr>\n <tr>\n <th><label>{{ ::$ctrl.i18n.margins_label }}</label></th>\n <td>\n <p>\n <label for="button_margin_top">{{ ::$ctrl.settings.button_margin_top.label }}</label>\n <editor-number ng-disabled="!$ctrl.marginAvailability.top" args="$ctrl.settings.button_margin_top" on-update="$ctrl.update($event)">\n </editor-number>\n </p>\n <p>\n <label for="button_margin_bottom">{{ ::$ctrl.settings.button_margin_bottom.label }}</label>\n <editor-number ng-disabled="!$ctrl.marginAvailability.bottom" args="$ctrl.settings.button_margin_bottom" on-update="$ctrl.update($event)">\n </editor-number>\n </p>\n <p>\n <label for="button_margin_left">{{ ::$ctrl.settings.button_margin_left.label }}</label>\n <editor-number ng-disabled="!$ctrl.marginAvailability.left" args="$ctrl.settings.button_margin_left" on-update="$ctrl.update($event)">\n </editor-number>\n </p>\n <p>\n <label for="button_margin_right">{{ ::$ctrl.settings.button_margin_right.label }}</label>\n <editor-number ng-disabled="!$ctrl.marginAvailability.right" args="$ctrl.settings.button_margin_right" on-update="$ctrl.update($event)">\n </editor-number>\n </p>\n <p class="description" ng-bind-html="$ctrl.i18n.margins_desc"></p>\n </td>\n </tr>\n </tbody>\n </table>\n <p ng-bind-html="$ctrl.i18n.attribution"></p>\n '};n["default"]=a},{"./visual.controller":17}],17:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=function d(e,t,n){null===e&&(e=Function.prototype);var r=Object.getOwnPropertyDescriptor(e,t);if(void 0===r){var i=Object.getPrototypeOf(e);return null===i?void 0:d(i,t,n)}if("value"in r)return r.value;var o=r.get;if(void 0!==o)return o.call(n)},l=e("./../base.controller"),c=r(l),f=function(e){function t(e){i(this,t);var n=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.$scope=e,n.fileFrame=null,n}return a(t,e),s(t,[{key:"$onChanges",value:function(e){u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"$onChanges",this).call(this,e),this.updateMarginAvailability()}},{key:"update",value:function(e){var t=e.key,n=e.value;this.values[t]=n,"button_position"===t&&this.updateMarginAvailability()}},{key:"updateMarginAvailability",value:function(){var e=this.values.button_position;this.marginAvailability={top:"top-left"===e||"top-right"===e,bottom:"bottom-left"===e||"bottom-right"===e,left:"top-left"===e||"bottom-left"===e,right:"top-right"===e||"bottom-right"===e}}},{key:"upload",value:function(){var e=this;return this.fileFrame?void this.fileFrame.open():(this.fileFrame=wp.media.frames.file_frame=wp.media({title:this.i18n.custom_button_frame_title,button:{text:this.i18n.custom_button_frame_button_text},multiple:!1}).on("select",function(){var t=e.fileFrame.state().get("selection").first().toJSON();e.updateValue("custom_image_url",t.url),e.updateValue("custom_image_width",t.width),e.updateValue("custom_image_height",t.height),e.$scope.$digest()}),void this.fileFrame.open())}}]),t}(c["default"]);f.$inject=["$scope"],n["default"]=f},{"./../base.controller":7}],18:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./navbar"),s=r(a),u=e("./editors"),l=r(u),c=o["default"].module("app.components",[s["default"],l["default"]]).name;n["default"]=c},{"./editors":32,"./navbar":33,angular:42}],19:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.checkbox.controller"),o=r(i),a={bindings:{args:"<",onUpdate:"&",addBr:"<?"},controller:o["default"],template:'<input type="checkbox" ng-change="$ctrl.change()" name="{{ ::$ctrl.key }}" id="{{ ::$ctrl.key }}" ng-model="$ctrl.value">\n <label for="{{ ::$ctrl.key }}">{{ ::$ctrl.args.text }}</label>\n <span ng-if="$ctrl.args.tooltip" tooltips tooltip-template="{{ ::$ctrl.args.tooltip }}" class="dashicons dashicons-editor-help"></span>\n <br ng-if="$ctrl.addBr" />'};n["default"]=a},{"./editor.checkbox.controller":20}],20:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=e("./editor.controller"),l=r(u),c=function(e){function t(){return i(this,t),o(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return a(t,e),s(t,[{key:"$onInit",value:function(){void 0===this.addBr&&(this.addBr=!0)}}]),t}(l["default"]);n["default"]=c},{"./editor.controller":21}],21:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e)}return o(e,[{key:"$onChanges",value:function(e){e.args&&(this.args=i({},this.args),this.key=this.args.key,this.value=this.args.value)}},{key:"change",value:function(){this.onUpdate({$event:{key:this.key,value:this.value}})}}]),e}();a.$inject=[],n["default"]=a},{}],22:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.image.controller"),o=r(i),a={
|
2 |
+
bindings:{args:"<",onUpdate:"&","class":"@"},controller:o["default"],template:'<input type="text" id="{{ $ctrl.key }}" name="{{ ::$ctrl.args.key }}" ng-model="$ctrl.value" ng-change="$ctrl.change()" class="regular-text" />\n<input type="button" class="button" value="{{ ::$ctrl.args.button_text }}" ng-click="$ctrl.selectFile()" />'};n["default"]=a},{"./editor.image.controller":23}],23:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=e("./editor.controller"),l=r(u),c=function(e){function t(e){i(this,t);var n=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.$scope=e,n}return a(t,e),s(t,[{key:"selectFile",value:function(){var e=this;return this.fileFrame=this.fileFrame||null,this.fileFrame?this.fileFrame.open():(this.fileFrame=wp.media.frames.file_frame=wp.media({title:this.args.title_text,button:{text:this.args.button_text},multiple:!1}).on("select",function(){var t=e.fileFrame.state().get("selection").first().toJSON();e.value=t.url,e.onUpdate({$event:{key:e.key,value:e.value}}),e.$scope.$apply()}),void this.fileFrame.open())}}]),t}(l["default"]);c.$inject=["$scope"],n["default"]=c},{"./editor.controller":21}],24:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.controller"),o=r(i),a={bindings:{args:"<",ngDisabled:"<",onUpdate:"&"},controller:o["default"],template:'\n <input id="{{ $ctrl.key }}" name="{{ ::$ctrl.args.key }}" ng-disabled="$ctrl.ngDisabled" number-attributes="$ctrl.args" class="small-text" type="number" ng-model="$ctrl.value" ng-change="$ctrl.change()" />'};n["default"]=a},{"./editor.controller":21}],25:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t){r(this,e),this.$parse=t,this.restrict="A"}return i(e,[{key:"link",value:function(e,t,n){var r=this.$parse(n.numberAttributes)(e),i=["step","min","max"];i.forEach(function(e){void 0!==r[e]&&t.attr(e,r[e])})}}]),e}();n["default"]=o},{}],26:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.select.controller"),o=r(i),a={bindings:{args:"<",onUpdate:"&"},controller:o["default"],template:'\n <select name="{{ ::$ctrl.key }}" ng-model="$ctrl.value" id="{{ ::$ctrl.args.key }}" ng-change="$ctrl.change()">\n <option ng-repeat="(value, name) in $ctrl.args.options" value="{{ value }}">{{ name }}</option>\n </select>'};n["default"]=a},{"./editor.select.controller":27}],27:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u=function d(e,t,n){null===e&&(e=Function.prototype);var r=Object.getOwnPropertyDescriptor(e,t);if(void 0===r){var i=Object.getPrototypeOf(e);return null===i?void 0:d(i,t,n)}if("value"in r)return r.value;var o=r.get;if(void 0!==o)return o.call(n)},l=e("./editor.controller"),c=r(l),f=function(e){function t(){return i(this,t),o(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return a(t,e),s(t,[{key:"$onChanges",value:function(e){u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"$onChanges",this).call(this,e),e.args&&(void 0!==this.args.value&&null!==this.args.value||(this.value=Object.keys(this.args.options)[0],this.change()),this.args.truthy&&(this.value=this.value?"1":"0"))}},{key:"change",value:function(){this.onUpdate({$event:{key:this.key,value:this.args.truthy?"1"===this.value:this.value}})}}]),t}(c["default"]);f.$inject=[],n["default"]=f},{"./editor.controller":21}],28:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.sortableSelect.controller"),o=r(i),a={bindings:{args:"<",onUpdate:"&"},controller:o["default"],template:'\n <input type="hidden" name="{{ ::$ctrl.args.key }}" ng-value="$ctrl.hiddenInputValue" />\n <ul class="frizzly-sortable" dnd-list="$ctrl.options">\n <li ng-repeat="item in $ctrl.options"\n dnd-draggable="item"\n dnd-moved="$ctrl.options.splice($index, 1); $ctrl.change()"\n dnd-effect-allowed="move">\n <input type="checkbox" id="{{ item.key }}" ng-model="item.selected" ng-change="$ctrl.change()" />\n <label for="{{ item.key }}">{{ item.label }}\n </li>\n </ul>\n '};n["default"]=a},{"./editor.sortableSelect.controller":29}],29:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e)}return o(e,[{key:"$onChanges",value:function(e){var t=this;if(e.args){this.args=i({},this.args),this.key=this.args.key,this.value=this.args.value||[],this.hiddenInputValue=this.value;var n=this.value.slice().concat(Object.keys(this.args.options).filter(function(e){return t.value.indexOf(e)===-1}));this.options=n.map(function(e){return{key:e,label:t.args.options[e],selected:t.value.indexOf(e)!==-1}})}}},{key:"change",value:function(){var e=this.options.reduce(function(e,t){return t.selected?e.concat([t.key]):e},[]);this.hiddenInputValue=e,this.onUpdate({$event:{key:this.key,value:e}})}}]),e}();a.$inject=[],n["default"]=a},{}],30:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(n,"__esModule",{value:!0});var s=e("./editor.controller"),u=r(s),l=function(e){function t(){i(this,t);var e=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return e["class"]="regular-text",e}return a(t,e),t}(u["default"]),c={bindings:{args:"<",onUpdate:"&","class":"@",ngDisabled:"<"},controller:l,template:'<input type="text" placeholder="{{ $ctrl.args.placeholder || \'\' }}" name="{{ ::$ctrl.key }}" id="{{ $ctrl.key }}" ng-model="$ctrl.value" ng-change="$ctrl.change()" ng-class="$ctrl.class" ng-disabled="$ctrl.ngDisabled" />'};n["default"]=c},{"./editor.controller":21}],31:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("./editor.controller"),o=r(i),a={bindings:{args:"<",onUpdate:"&"},controller:o["default"],template:'<textarea rows="3" cols="50" id="{{ $ctrl.key }}" name="{{ ::$ctrl.args.key }}" class="large-text code" ng-model="$ctrl.value" ng-change="$ctrl.change()"></textarea>'};n["default"]=a},{"./editor.controller":21}],32:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./editor.text.component"),s=r(a),u=e("./editor.textarea.component"),l=r(u),c=e("./editor.image.component"),f=r(c),d=e("./editor.number.component"),p=r(d),h=e("./editor.number.directive"),g=r(h),$=e("./editor.checkbox.component"),v=r($),m=e("./editor.select.component"),y=r(m),b=e("./editor.sortableSelect.component"),w=r(b),x=o["default"].module("editors",["dndLists"]).component("editorText",s["default"]).component("editorTextarea",l["default"]).component("editorImage",f["default"]).component("editorNumber",p["default"]).component("editorCheckbox",v["default"]).component("editorSelect",y["default"]).component("editorSortableSelect",w["default"]).directive("numberAttributes",["$parse",function(e){return new g["default"](e)}]).name;n["default"]=x},{"./editor.checkbox.component":19,"./editor.image.component":22,"./editor.number.component":24,"./editor.number.directive":25,"./editor.select.component":26,"./editor.sortableSelect.component":28,"./editor.text.component":30,"./editor.textarea.component":31,angular:42}],33:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./navbar.component"),s=r(a),u=o["default"].module("navbar",[]).component("navbar",s["default"]).name;n["default"]=u},{"./navbar.component":34,angular:42}],34:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={bindings:{currentTab:"<",tabs:"<",page:"<",links:"<"},controller:function(){},template:'\n <h2 class="nav-tab-wrapper">\n <a ng-repeat="tab in $ctrl.tabs" \n href="?page={{ $ctrl.page }}&tab={{ tab.slug }}" class="nav-tab {{ $ctrl.currentTab == tab.slug ? \'nav-tab-active\' : \'\' }}">\n {{ tab.name }}\n </a>\n <a ng-repeat="link in $ctrl.links" href="{{ link.url }}" target="_blank" class="nav-tab">\n {{ link.label }}\n </a>\n </h2>\n '};n["default"]=r},{}],35:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var i=e("angular"),o=r(i),a=e("./link.service"),s=r(a),u=o["default"].module("services",[]).service("linkService",s["default"]).name;n["default"]=u},{"./link.service":36,angular:42}],36:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(u){i=!0,o=u}finally{try{!r&&s["return"]&&s["return"]()}finally{if(i)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=function(){function e(){r(this,e),this.baseLink=""}return o(e,[{key:"init",value:function(e){this.baseLink="?page="+e}},{key:"generateQuery",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce(function(e,t){var n=i(t,2),r=n[0],o=n[1];return e+"&"+r+"="+o},this.baseLink)}}]),e}();a.$inject=[],n["default"]=a},{}],37:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{"default":e}}var i=e("./app/app");r(i);!function(e){e(document).ready(function(){})}(jQuery)},{"./app/app":3}],38:[function(e,t,n){angular.module("dndLists",[]).directive("dndDraggable",["$parse","$timeout","dndDropEffectWorkaround","dndDragTypeWorkaround",function(e,t,n,r){return function(i,o,a){o.attr("draggable","true"),a.dndDisableIf&&i.$watch(a.dndDisableIf,function(e){o.attr("draggable",!e)}),o.on("dragstart",function(s){return s=s.originalEvent||s,"false"==o.attr("draggable")||(s.dataTransfer.setData("Text",angular.toJson(i.$eval(a.dndDraggable))),s.dataTransfer.effectAllowed=a.dndEffectAllowed||"move",o.addClass("dndDragging"),t(function(){o.addClass("dndDraggingSource")},0),n.dropEffect="none",r.isDragging=!0,r.dragType=a.dndType?i.$eval(a.dndType):void 0,s._dndHandle&&s.dataTransfer.setDragImage&&s.dataTransfer.setDragImage(o[0],0,0),e(a.dndDragstart)(i,{event:s}),void s.stopPropagation())}),o.on("dragend",function(s){s=s.originalEvent||s;var u=n.dropEffect;i.$apply(function(){switch(u){case"move":e(a.dndMoved)(i,{event:s});break;case"copy":e(a.dndCopied)(i,{event:s});break;case"none":e(a.dndCanceled)(i,{event:s})}e(a.dndDragend)(i,{event:s,dropEffect:u})}),o.removeClass("dndDragging"),t(function(){o.removeClass("dndDraggingSource")},0),r.isDragging=!1,s.stopPropagation()}),o.on("click",function(t){a.dndSelected&&(t=t.originalEvent||t,i.$apply(function(){e(a.dndSelected)(i,{event:t})}),t.stopPropagation())}),o.on("selectstart",function(){this.dragDrop&&this.dragDrop()})}}]).directive("dndList",["$parse","$timeout","dndDropEffectWorkaround","dndDragTypeWorkaround",function(e,t,n,r){return function(i,o,a){function s(e,t,n){var r=v?e.offsetX||e.layerX:e.offsetY||e.layerY,i=v?t.offsetWidth:t.offsetHeight,o=v?t.offsetLeft:t.offsetTop;return o=n?o:0,r<o+i/2}function u(){var e;return angular.forEach(o.children(),function(t){var n=angular.element(t);n.hasClass("dndPlaceholder")&&(e=n)}),e||angular.element("<li class='dndPlaceholder'></li>")}function l(){return Array.prototype.indexOf.call($.children,g)}function c(e){if(!r.isDragging&&!m)return!1;if(!p(e.dataTransfer.types))return!1;if(a.dndAllowedTypes&&r.isDragging){var t=i.$eval(a.dndAllowedTypes);if(angular.isArray(t)&&t.indexOf(r.dragType)===-1)return!1}return!a.dndDisableIf||!i.$eval(a.dndDisableIf)}function f(){return h.remove(),o.removeClass("dndDragover"),!0}function d(t,n,o,a){return e(t)(i,{event:n,index:o,item:a||void 0,external:!r.isDragging,type:r.isDragging?r.dragType:void 0})}function p(e){if(!e)return!0;for(var t=0;t<e.length;t++)if("Text"===e[t]||"text/plain"===e[t])return!0;return!1}var h=u(),g=h[0],$=o[0];h.remove();var v=a.dndHorizontalList&&i.$eval(a.dndHorizontalList),m=a.dndExternalSources&&i.$eval(a.dndExternalSources);o.on("dragenter",function(e){return e=e.originalEvent||e,!c(e)||void e.preventDefault()}),o.on("dragover",function(e){if(e=e.originalEvent||e,!c(e))return!0;if(g.parentNode!=$&&o.append(h),e.target!==$){for(var t=e.target;t.parentNode!==$&&t.parentNode;)t=t.parentNode;t.parentNode===$&&t!==g&&(s(e,t)?$.insertBefore(g,t):$.insertBefore(g,t.nextSibling))}else if(s(e,g,!0))for(;g.previousElementSibling&&(s(e,g.previousElementSibling,!0)||0===g.previousElementSibling.offsetHeight);)$.insertBefore(g,g.previousElementSibling);else for(;g.nextElementSibling&&!s(e,g.nextElementSibling,!0);)$.insertBefore(g,g.nextElementSibling.nextElementSibling);return a.dndDragover&&!d(a.dndDragover,e,l())?f():(o.addClass("dndDragover"),e.preventDefault(),e.stopPropagation(),!1)}),o.on("drop",function(e){if(e=e.originalEvent||e,!c(e))return!0;e.preventDefault();var t,r=e.dataTransfer.getData("Text")||e.dataTransfer.getData("text/plain");try{t=JSON.parse(r)}catch(o){return f()}var s=l();return a.dndDrop&&(t=d(a.dndDrop,e,s,t),!t)?f():(t!==!0&&i.$apply(function(){i.$eval(a.dndList).splice(s,0,t)}),d(a.dndInserted,e,s,t),"none"===e.dataTransfer.dropEffect?"copy"===e.dataTransfer.effectAllowed||"move"===e.dataTransfer.effectAllowed?n.dropEffect=e.dataTransfer.effectAllowed:n.dropEffect=e.ctrlKey?"copy":"move":n.dropEffect=e.dataTransfer.dropEffect,f(),e.stopPropagation(),!1)}),o.on("dragleave",function(e){e=e.originalEvent||e,o.removeClass("dndDragover"),t(function(){o.hasClass("dndDragover")||h.remove()},100)})}}]).directive("dndNodrag",function(){return function(e,t,n){t.attr("draggable","true"),t.on("dragstart",function(e){e=e.originalEvent||e,e._dndHandle||(e.dataTransfer.types&&e.dataTransfer.types.length||e.preventDefault(),e.stopPropagation())}),t.on("dragend",function(e){e=e.originalEvent||e,e._dndHandle||e.stopPropagation()})}}).directive("dndHandle",function(){return function(e,t,n){t.attr("draggable","true"),t.on("dragstart dragend",function(e){e=e.originalEvent||e,e._dndHandle=!0})}}).factory("dndDragTypeWorkaround",function(){return{}}).factory("dndDropEffectWorkaround",function(){return{}})},{}],39:[function(e,t,n){!function(e,t){"use strict";function n(){function n(e,t){var n,r={},i=e.split(",");for(n=0;n<i.length;n++)r[t?u(i[n]):i[n]]=!0;return r}function r(t,n){null===t||void 0===t?t="":"string"!=typeof t&&(t=""+t),m.innerHTML=t;var r=5;do{if(0===r)throw d("uinput","Failed to sanitize html because the input is unstable");r--,e.document.documentMode&&$(m),t=m.innerHTML,m.innerHTML=t}while(t!==m.innerHTML);for(var i=m.firstChild;i;){switch(i.nodeType){case 1:n.start(i.nodeName.toLowerCase(),p(i.attributes));break;case 3:n.chars(i.textContent)}var o;if(!(o=i.firstChild)&&(1===i.nodeType&&n.end(i.nodeName.toLowerCase()),o=i.nextSibling,!o))for(;null==o&&(i=i.parentNode,i!==m);)o=i.nextSibling,1===i.nodeType&&n.end(i.nodeName.toLowerCase());i=o}for(;i=m.firstChild;)m.removeChild(i)}function p(e){for(var t={},n=0,r=e.length;n<r;n++){var i=e[n];t[i.name]=i.value}return t}function h(e){return e.replace(/&/g,"&").replace(y,function(e){var t=e.charCodeAt(0),n=e.charCodeAt(1);return"&#"+(1024*(t-55296)+(n-56320)+65536)+";"}).replace(b,function(e){return"&#"+e.charCodeAt(0)+";"}).replace(/</g,"<").replace(/>/g,">")}function g(e,t){var n=!1,r=i(e,e.push);return{start:function(e,i){e=u(e),!n&&A[e]&&(n=e),n||O[e]!==!0||(r("<"),r(e),a(i,function(n,i){var o=u(i),a="img"===e&&"src"===o||"background"===o;P[o]!==!0||M[o]===!0&&!t(n,a)||(r(" "),r(i),r('="'),r(h(n)),r('"'))}),r(">"))},end:function(e){e=u(e),n||O[e]!==!0||w[e]===!0||(r("</"),r(e),r(">")),e==n&&(n=!1)},chars:function(e){n||r(h(e))}}}function $(t){for(;t;){if(t.nodeType===e.Node.ELEMENT_NODE)for(var n=t.attributes,r=0,i=n.length;r<i;r++){var o=n[r],a=o.name.toLowerCase();"xmlns:ns1"!==a&&0!==a.lastIndexOf("ns1:",0)||(t.removeAttributeNode(o),r--,i--)}var s=t.firstChild;s&&$(s),t=t.nextSibling}}var v=!1;this.$get=["$$sanitizeUri",function(e){return v&&o(O,C),function(t){var n=[];return c(t,f(n,function(t,n){return!/^unsafe:/.test(e(t,n))})),n.join("")}}],this.enableSvg=function(e){return s(e)?(v=e,this):v},i=t.bind,o=t.extend,a=t.forEach,s=t.isDefined,u=t.lowercase,l=t.noop,c=r,f=g;var m,y=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,b=/([^#-~ |!])/g,w=n("area,br,col,hr,img,wbr"),x=n("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),_=n("rp,rt"),k=o({},_,x),E=o({},x,n("address,article,aside,blockquote,caption,center,del,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,map,menu,nav,ol,pre,section,table,ul")),S=o({},_,n("a,abbr,acronym,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,q,ruby,rp,rt,s,samp,small,span,strike,strong,sub,sup,time,tt,u,var")),C=n("circle,defs,desc,ellipse,font-face,font-face-name,font-face-src,g,glyph,hkern,image,linearGradient,line,marker,metadata,missing-glyph,mpath,path,polygon,polyline,radialGradient,rect,stop,svg,switch,text,title,tspan"),A=n("script,style"),O=o({},w,E,S,k),M=n("background,cite,href,longdesc,src,xlink:href"),j=n("abbr,align,alt,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,coords,dir,face,headers,height,hreflang,hspace,ismap,lang,language,nohref,nowrap,rel,rev,rows,rowspan,rules,scope,scrolling,shape,size,span,start,summary,tabindex,target,title,type,valign,value,vspace,width"),T=n("accent-height,accumulate,additive,alphabetic,arabic-form,ascent,baseProfile,bbox,begin,by,calcMode,cap-height,class,color,color-rendering,content,cx,cy,d,dx,dy,descent,display,dur,end,fill,fill-rule,font-family,font-size,font-stretch,font-style,font-variant,font-weight,from,fx,fy,g1,g2,glyph-name,gradientUnits,hanging,height,horiz-adv-x,horiz-origin-x,ideographic,k,keyPoints,keySplines,keyTimes,lang,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mathematical,max,min,offset,opacity,orient,origin,overline-position,overline-thickness,panose-1,path,pathLength,points,preserveAspectRatio,r,refX,refY,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,rotate,rx,ry,slope,stemh,stemv,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,systemLanguage,target,text-anchor,to,transform,type,u1,u2,underline-position,underline-thickness,unicode,unicode-range,units-per-em,values,version,viewBox,visibility,width,widths,x,x-height,x1,x2,xlink:actuate,xlink:arcrole,xlink:role,xlink:show,xlink:title,xlink:type,xml:base,xml:lang,xml:space,xmlns,xmlns:xlink,y,y1,y2,zoomAndPan",!0),P=o({},M,T,j);!function(e){var t;if(!e.document||!e.document.implementation)throw d("noinert","Can't create an inert html document");t=e.document.implementation.createHTMLDocument("inert");var n=t.documentElement||t.getDocumentElement(),r=n.getElementsByTagName("body");if(1===r.length)m=r[0];else{var i=t.createElement("html");m=t.createElement("body"),i.appendChild(m),t.appendChild(i)}}(e)}function r(e){var t=[],n=f(t,l);return n.chars(e),t.join("")}var i,o,a,s,u,l,c,f,d=t.$$minErr("$sanitize");t.module("ngSanitize",[]).provider("$sanitize",n),t.module("ngSanitize").filter("linky",["$sanitize",function(e){var n=/((ftp|https?):\/\/|(www\.)|(mailto:)?[A-Za-z0-9._%+-]+@)\S*[^\s.;,(){}<>"\u201d\u2019]/i,i=/^mailto:/i,o=t.$$minErr("linky"),a=t.isDefined,s=t.isFunction,u=t.isObject,l=t.isString;return function(t,c,f){function d(e){e&&y.push(r(e))}function p(e,t){var n,r=v(e);y.push("<a ");for(n in r)y.push(n+'="'+r[n]+'" ');!a(c)||"target"in r||y.push('target="',c,'" '),y.push('href="',e.replace(/"/g,"""),'">'),d(t),y.push("</a>")}if(null==t||""===t)return t;if(!l(t))throw o("notstring","Expected string but received: {0}",t);for(var h,g,$,v=s(f)?f:u(f)?function(){return f}:function(){return{}},m=t,y=[];h=m.match(n);)g=h[0],h[2]||h[4]||(g=(h[3]?"http://":"mailto:")+g),$=h.index,d(m.substr(0,$)),p(g,h[0].replace(i,"")),m=m.substring($+h[0].length);return d(m),e(y.join(""))}}])}(window,window.angular)},{}],40:[function(e,t,n){e("./angular-sanitize"),t.exports="ngSanitize"},{"./angular-sanitize":39}],41:[function(e,t,n){!function(e){"use strict";function t(e,t){return t=t||Error,function(){var n,r,i=2,o=arguments,a=o[0],s="["+(e?e+":":"")+a+"] ",u=o[1];for(s+=u.replace(/\{\d+\}/g,function(e){var t=+e.slice(1,-1),n=t+i;return n<o.length?we(o[n]):e}),s+="\nhttp://errors.angularjs.org/1.6.1/"+(e?e+"/":"")+a,r=i,n="?";r<o.length;r++,n="&")s+=n+"p"+(r-i)+"="+encodeURIComponent(we(o[r]));return new t(s)}}function n(e){if(null==e||S(e))return!1;if(li(e)||w(e)||Jr&&e instanceof Jr)return!0;var t="length"in Object(e)&&e.length;return x(t)&&(t>=0&&(t-1 in e||e instanceof Array)||"function"==typeof e.item)}function r(e,t,i){var o,a;if(e)if(k(e))for(o in e)"prototype"!==o&&"length"!==o&&"name"!==o&&e.hasOwnProperty(o)&&t.call(i,e[o],o,e);else if(li(e)||n(e)){var s="object"!=typeof e;for(o=0,a=e.length;o<a;o++)(s||o in e)&&t.call(i,e[o],o,e)}else if(e.forEach&&e.forEach!==r)e.forEach(t,i,e);else if(b(e))for(o in e)t.call(i,e[o],o,e);else if("function"==typeof e.hasOwnProperty)for(o in e)e.hasOwnProperty(o)&&t.call(i,e[o],o,e);else for(o in e)Br.call(e,o)&&t.call(i,e[o],o,e);return e}function i(e,t,n){for(var r=Object.keys(e).sort(),i=0;i<r.length;i++)t.call(n,e[r[i]],r[i]);return r}function o(e){return function(t,n){e(n,t)}}function a(){return++si}function s(e,t){t?e.$$hashKey=t:delete e.$$hashKey}function u(e,t,n){for(var r=e.$$hashKey,i=0,o=t.length;i<o;++i){var a=t[i];if(y(a)||k(a))for(var l=Object.keys(a),c=0,f=l.length;c<f;c++){var d=l[c],p=a[d];n&&y(p)?_(p)?e[d]=new Date(p.valueOf()):E(p)?e[d]=new RegExp(p):p.nodeName?e[d]=p.cloneNode(!0):V(p)?e[d]=p.clone():(y(e[d])||(e[d]=li(p)?[]:{}),u(e[d],[p],!0)):e[d]=p}}return s(e,r),e}function l(e){return u(e,ei.call(arguments,1),!1)}function c(e){return u(e,ei.call(arguments,1),!0)}function f(e){return parseInt(e,10)}function d(e,t){return l(Object.create(e),t)}function p(){}function h(e){return e}function g(e){return function(){return e}}function $(e){return k(e.toString)&&e.toString!==ri}function v(e){return"undefined"==typeof e}function m(e){return"undefined"!=typeof e}function y(e){return null!==e&&"object"==typeof e}function b(e){return null!==e&&"object"==typeof e&&!ii(e)}function w(e){return"string"==typeof e}function x(e){return"number"==typeof e}function _(e){return"[object Date]"===ri.call(e)}function k(e){return"function"==typeof e}function E(e){return"[object RegExp]"===ri.call(e)}function S(e){return e&&e.window===e}function C(e){return e&&e.$evalAsync&&e.$watch}function A(e){return"[object File]"===ri.call(e)}function O(e){return"[object FormData]"===ri.call(e)}function M(e){return"[object Blob]"===ri.call(e)}function j(e){return"boolean"==typeof e}function T(e){return e&&k(e.then)}function P(e){return e&&x(e.length)&&ci.test(ri.call(e))}function D(e){return"[object ArrayBuffer]"===ri.call(e)}function V(e){return!(!e||!(e.nodeName||e.prop&&e.attr&&e.find))}function I(e){var t,n={},r=e.split(",");for(t=0;t<r.length;t++)n[r[t]]=!0;return n}function U(e){return Wr(e.nodeName||e[0]&&e[0].nodeName)}function F(e,t){return Array.prototype.indexOf.call(e,t)!==-1}function N(e,t){var n=e.indexOf(t);return n>=0&&e.splice(n,1),n}function R(e,t){function n(e,t){var n,r=t.$$hashKey;if(li(e))for(var o=0,a=e.length;o<a;o++)t.push(i(e[o]));else if(b(e))for(n in e)t[n]=i(e[n]);else if(e&&"function"==typeof e.hasOwnProperty)for(n in e)e.hasOwnProperty(n)&&(t[n]=i(e[n]));else for(n in e)Br.call(e,n)&&(t[n]=i(e[n]));return s(t,r),t}function i(e){if(!y(e))return e;var t=a.indexOf(e);if(t!==-1)return u[t];if(S(e)||C(e))throw oi("cpws","Can't copy! Making copies of Window or Scope instances is not supported.");var r=!1,i=o(e);return void 0===i&&(i=li(e)?[]:Object.create(ii(e)),r=!0),a.push(e),u.push(i),r?n(e,i):i}function o(e){switch(ri.call(e)){case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Float32Array]":case"[object Float64Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return new e.constructor(i(e.buffer),e.byteOffset,e.length);case"[object ArrayBuffer]":if(!e.slice){var t=new ArrayBuffer(e.byteLength);return new Uint8Array(t).set(new Uint8Array(e)),t}return e.slice(0);case"[object Boolean]":case"[object Number]":case"[object String]":case"[object Date]":return new e.constructor(e.valueOf());case"[object RegExp]":var n=new RegExp(e.source,e.toString().match(/[^\/]*$/)[0]);return n.lastIndex=e.lastIndex,n;case"[object Blob]":return new e.constructor([e],{type:e.type})}if(k(e.cloneNode))return e.cloneNode(!0)}var a=[],u=[];if(t){if(P(t)||D(t))throw oi("cpta","Can't copy! TypedArray destination cannot be mutated.");if(e===t)throw oi("cpi","Can't copy! Source and destination are identical.");return li(t)?t.length=0:r(t,function(e,n){"$$hashKey"!==n&&delete t[n]}),a.push(e),u.push(t),n(e,t)}return i(e)}function z(e,t){if(e===t)return!0;if(null===e||null===t)return!1;if(e!==e&&t!==t)return!0;var n,r,i,o=typeof e,a=typeof t;if(o===a&&"object"===o){if(!li(e)){if(_(e))return!!_(t)&&z(e.getTime(),t.getTime());if(E(e))return!!E(t)&&e.toString()===t.toString();if(C(e)||C(t)||S(e)||S(t)||li(t)||_(t)||E(t))return!1;i=$e();for(r in e)if("$"!==r.charAt(0)&&!k(e[r])){if(!z(e[r],t[r]))return!1;i[r]=!0}for(r in t)if(!(r in i)&&"$"!==r.charAt(0)&&m(t[r])&&!k(t[r]))return!1;return!0}if(!li(t))return!1;if((n=e.length)===t.length){for(r=0;r<n;r++)if(!z(e[r],t[r]))return!1;return!0}}return!1}function L(e,t,n){return e.concat(ei.call(t,n))}function H(e,t){return ei.call(e,t||0)}function q(e,t){var n=arguments.length>2?H(arguments,2):[];return!k(t)||t instanceof RegExp?t:n.length?function(){return arguments.length?t.apply(e,L(n,arguments,0)):t.apply(e,n)}:function(){return arguments.length?t.apply(e,arguments):t.call(e)}}function B(t,n){var r=n;return"string"==typeof t&&"$"===t.charAt(0)&&"$"===t.charAt(1)?r=void 0:S(n)?r="$WINDOW":n&&e.document===n?r="$DOCUMENT":C(n)&&(r="$SCOPE"),r}function W(e,t){if(!v(e))return x(t)||(t=t?2:null),JSON.stringify(e,B,t)}function G(e){return w(e)?JSON.parse(e):e}function X(e,t){e=e.replace(gi,"");var n=Date.parse("Jan 01, 1970 00:00:00 "+e)/6e4;return ui(n)?t:n}function K(e,t){return e=new Date(e.getTime()),e.setMinutes(e.getMinutes()+t),e}function Y(e,t,n){n=n?-1:1;var r=e.getTimezoneOffset(),i=X(t,r);return K(e,n*(i-r))}function J(e){e=Jr(e).clone();try{e.empty()}catch(t){}var n=Jr("<div>").append(e).html();try{return e[0].nodeType===xi?Wr(n):n.match(/^(<[^>]+>)/)[1].replace(/^<([\w-]+)/,function(e,t){return"<"+Wr(t)})}catch(t){return Wr(n)}}function Z(e){try{return decodeURIComponent(e)}catch(t){}}function Q(e){var t={};return r((e||"").split("&"),function(e){var n,r,i;e&&(r=e=e.replace(/\+/g,"%20"),n=e.indexOf("="),n!==-1&&(r=e.substring(0,n),i=e.substring(n+1)),r=Z(r),m(r)&&(i=!m(i)||Z(i),Br.call(t,r)?li(t[r])?t[r].push(i):t[r]=[t[r],i]:t[r]=i))}),t}function ee(e){var t=[];return r(e,function(e,n){li(e)?r(e,function(e){t.push(ne(n,!0)+(e===!0?"":"="+ne(e,!0)))}):t.push(ne(n,!0)+(e===!0?"":"="+ne(e,!0)))}),t.length?t.join("&"):""}function te(e){return ne(e,!0).replace(/%26/gi,"&").replace(/%3D/gi,"=").replace(/%2B/gi,"+")}function ne(e,t){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%3B/gi,";").replace(/%20/g,t?"%20":"+")}function re(e,t){var n,r,i=$i.length;for(r=0;r<i;++r)if(n=$i[r]+t,w(n=e.getAttribute(n)))return n;return null}function ie(e){if(!e.currentScript)return!0;var t=e.currentScript.getAttribute("src"),n=e.createElement("a");if(n.href=t,e.location.origin===n.origin)return!0;switch(n.protocol){case"http:":case"https:":case"ftp:":case"blob:":case"file:":case"data:":return!0;default:return!1}}function oe(t,n){var i,o,a={};if(r($i,function(e){var n=e+"app";!i&&t.hasAttribute&&t.hasAttribute(n)&&(i=t,o=t.getAttribute(n))}),r($i,function(e){var n,r=e+"app";!i&&(n=t.querySelector("["+r.replace(":","\\:")+"]"))&&(i=n,
|
3 |
+
o=n.getAttribute(r))}),i){if(!vi)return void e.console.error("Angular: disabling automatic bootstrap. <script> protocol indicates an extension, document.location.href does not match.");a.strictDi=null!==re(i,"strict-di"),n(i,o?[o]:[],a)}}function ae(t,n,i){y(i)||(i={});var o={strictDi:!1};i=l(o,i);var a=function(){if(t=Jr(t),t.injector()){var r=t[0]===e.document?"document":J(t);throw oi("btstrpd","App already bootstrapped with this element '{0}'",r.replace(/</,"<").replace(/>/,">"))}n=n||[],n.unshift(["$provide",function(e){e.value("$rootElement",t)}]),i.debugInfoEnabled&&n.push(["$compileProvider",function(e){e.debugInfoEnabled(!0)}]),n.unshift("ng");var o=lt(n,i.strictDi);return o.invoke(["$rootScope","$rootElement","$compile","$injector",function(e,t,n,r){e.$apply(function(){t.data("$injector",r),n(t)(e)})}]),o},s=/^NG_ENABLE_DEBUG_INFO!/,u=/^NG_DEFER_BOOTSTRAP!/;return e&&s.test(e.name)&&(i.debugInfoEnabled=!0,e.name=e.name.replace(s,"")),e&&!u.test(e.name)?a():(e.name=e.name.replace(u,""),ai.resumeBootstrap=function(e){return r(e,function(e){n.push(e)}),a()},void(k(ai.resumeDeferredBootstrap)&&ai.resumeDeferredBootstrap()))}function se(){e.name="NG_ENABLE_DEBUG_INFO!"+e.name,e.location.reload()}function ue(e){var t=ai.element(e).injector();if(!t)throw oi("test","no injector found for element argument to getTestability");return t.get("$$testability")}function le(e,t){return t=t||"_",e.replace(mi,function(e,n){return(n?t:"")+e.toLowerCase()})}function ce(){var t;if(!yi){var n=hi();Zr=v(n)?e.jQuery:n?e[n]:void 0,Zr&&Zr.fn.on?(Jr=Zr,l(Zr.fn,{scope:Ni.scope,isolateScope:Ni.isolateScope,controller:Ni.controller,injector:Ni.injector,inheritedData:Ni.inheritedData}),t=Zr.cleanData,Zr.cleanData=function(e){for(var n,r,i=0;null!=(r=e[i]);i++)n=Zr._data(r,"events"),n&&n.$destroy&&Zr(r).triggerHandler("$destroy");t(e)}):Jr=De,ai.element=Jr,yi=!0}}function fe(e,t,n){if(!e)throw oi("areq","Argument '{0}' is {1}",t||"?",n||"required");return e}function de(e,t,n){return n&&li(e)&&(e=e[e.length-1]),fe(k(e),t,"not a function, got "+(e&&"object"==typeof e?e.constructor.name||"Object":typeof e)),e}function pe(e,t){if("hasOwnProperty"===e)throw oi("badname","hasOwnProperty is not a valid {0} name",t)}function he(e,t,n){if(!t)return e;for(var r,i=t.split("."),o=e,a=i.length,s=0;s<a;s++)r=i[s],e&&(e=(o=e)[r]);return!n&&k(e)?q(o,e):e}function ge(e){for(var t,n=e[0],r=e[e.length-1],i=1;n!==r&&(n=n.nextSibling);i++)(t||e[i]!==n)&&(t||(t=Jr(ei.call(e,0,i))),t.push(n));return t||e}function $e(){return Object.create(null)}function ve(e){if(null==e)return"";switch(typeof e){case"string":break;case"number":e=""+e;break;default:e=!$(e)||li(e)||_(e)?W(e):e.toString()}return e}function me(e){function n(e,t,n){return e[t]||(e[t]=n())}var r=t("$injector"),i=t("ng"),o=n(e,"angular",Object);return o.$$minErr=o.$$minErr||t,n(o,"module",function(){var e={};return function(t,o,a){var s=function(e,t){if("hasOwnProperty"===e)throw i("badname","hasOwnProperty is not a valid {0} name",t)};return s(t,"module"),o&&e.hasOwnProperty(t)&&(e[t]=null),n(e,t,function(){function e(e,t,n,r){return r||(r=i),function(){return r[n||"push"]([e,t,arguments]),c}}function n(e,n,r){return r||(r=i),function(i,o){return o&&k(o)&&(o.$$moduleName=t),r.push([e,n,arguments]),c}}if(!o)throw r("nomod","Module '{0}' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.",t);var i=[],s=[],u=[],l=e("$injector","invoke","push",s),c={_invokeQueue:i,_configBlocks:s,_runBlocks:u,requires:o,name:t,provider:n("$provide","provider"),factory:n("$provide","factory"),service:n("$provide","service"),value:e("$provide","value"),constant:e("$provide","constant","unshift"),decorator:n("$provide","decorator",s),animation:n("$animateProvider","register"),filter:n("$filterProvider","register"),controller:n("$controllerProvider","register"),directive:n("$compileProvider","directive"),component:n("$compileProvider","component"),config:l,run:function(e){return u.push(e),this}};return a&&l(a),c})}})}function ye(e,t){if(li(e)){t=t||[];for(var n=0,r=e.length;n<r;n++)t[n]=e[n]}else if(y(e)){t=t||{};for(var i in e)"$"===i.charAt(0)&&"$"===i.charAt(1)||(t[i]=e[i])}return t||e}function be(e){var t=[];return JSON.stringify(e,function(e,n){if(n=B(e,n),y(n)){if(t.indexOf(n)>=0)return"...";t.push(n)}return n})}function we(e){return"function"==typeof e?e.toString().replace(/ \{[\s\S]*$/,""):v(e)?"undefined":"string"!=typeof e?be(e):e}function xe(n){l(n,{bootstrap:ae,copy:R,extend:l,merge:c,equals:z,element:Jr,forEach:r,injector:lt,noop:p,bind:q,toJson:W,fromJson:G,identity:h,isUndefined:v,isDefined:m,isString:w,isFunction:k,isObject:y,isNumber:x,isElement:V,isArray:li,version:Si,isDate:_,lowercase:Wr,uppercase:Gr,callbacks:{$$counter:0},getTestability:ue,reloadWithDebugInfo:se,$$minErr:t,$$csp:pi,$$encodeUriSegment:te,$$encodeUriQuery:ne,$$stringify:ve}),(Qr=me(e))("ng",["ngLocale"],["$provide",function(e){e.provider({$$sanitizeUri:Cn}),e.provider("$compile",bt).directive({a:Go,input:pa,textarea:pa,form:Qo,script:ss,select:cs,option:fs,ngBind:$a,ngBindHtml:ma,ngBindTemplate:va,ngClass:ba,ngClassEven:xa,ngClassOdd:wa,ngCloak:_a,ngController:ka,ngForm:ea,ngHide:es,ngIf:Ca,ngInclude:Aa,ngInit:Ma,ngNonBindable:Ba,ngPluralize:Ka,ngRepeat:Ya,ngShow:Qa,ngStyle:ts,ngSwitch:ns,ngSwitchWhen:rs,ngSwitchDefault:is,ngOptions:Xa,ngTransclude:as,ngModel:La,ngList:ja,ngChange:ya,pattern:ps,ngPattern:ps,required:ds,ngRequired:ds,minlength:gs,ngMinlength:gs,maxlength:hs,ngMaxlength:hs,ngValue:ga,ngModelOptions:qa}).directive({ngInclude:Oa}).directive(Xo).directive(Ea),e.provider({$anchorScroll:ct,$animate:to,$animateCss:io,$$animateJs:Qi,$$animateQueue:eo,$$AnimateRunner:ro,$$animateAsyncRun:no,$browser:$t,$cacheFactory:vt,$controller:St,$document:Ct,$$isDocumentHidden:At,$exceptionHandler:Ot,$filter:Ln,$$forceReflow:fo,$interpolate:Ht,$interval:qt,$http:Nt,$httpParamSerializer:jt,$httpParamSerializerJQLike:Tt,$httpBackend:zt,$xhrFactory:Rt,$jsonpCallbacks:bo,$location:an,$log:sn,$parse:wn,$rootScope:Sn,$q:xn,$$q:_n,$sce:Tn,$sceDelegate:jn,$sniffer:Pn,$templateCache:mt,$templateRequest:Dn,$$testability:Vn,$timeout:In,$window:Nn,$$rAF:En,$$jqLite:nt,$$HashMap:Hi,$$cookieReader:zn})}])}function _e(){return++Ai}function ke(e){return Se(e.replace(Mi,"ms-"))}function Ee(e,t){return t.toUpperCase()}function Se(e){return e.replace(Oi,Ee)}function Ce(e){return!Di.test(e)}function Ae(e){var t=e.nodeType;return t===bi||!t||t===ki}function Oe(e){for(var t in Ci[e.ng339])return!0;return!1}function Me(e){for(var t=0,n=e.length;t<n;t++)Fe(e[t])}function je(e,t){var n,i,o,a,s=t.createDocumentFragment(),u=[];if(Ce(e))u.push(t.createTextNode(e));else{for(n=s.appendChild(t.createElement("div")),i=(Vi.exec(e)||["",""])[1].toLowerCase(),o=Ui[i]||Ui._default,n.innerHTML=o[1]+e.replace(Ii,"<$1></$2>")+o[2],a=o[0];a--;)n=n.lastChild;u=L(u,n.childNodes),n=s.firstChild,n.textContent=""}return s.textContent="",s.innerHTML="",r(u,function(e){s.appendChild(e)}),s}function Te(t,n){n=n||e.document;var r;return(r=Pi.exec(t))?[n.createElement(r[1])]:(r=je(t,n))?r.childNodes:[]}function Pe(e,t){var n=e.parentNode;n&&n.replaceChild(t,e),t.appendChild(e)}function De(e){if(e instanceof De)return e;var t;if(w(e)&&(e=fi(e),t=!0),!(this instanceof De)){if(t&&"<"!==e.charAt(0))throw Ti("nosel","Looking up elements via selectors is not supported by jqLite! See: http://docs.angularjs.org/api/angular.element");return new De(e)}t?qe(this,Te(e)):k(e)?Ye(e):qe(this,e)}function Ve(e){return e.cloneNode(!0)}function Ie(e,t){if(t||Fe(e),e.querySelectorAll)for(var n=e.querySelectorAll("*"),r=0,i=n.length;r<i;r++)Fe(n[r])}function Ue(e,t,n,i){if(m(i))throw Ti("offargs","jqLite#off() does not support the `selector` argument");var o=Ne(e),a=o&&o.events,s=o&&o.handle;if(s)if(t){var u=function(t){var r=a[t];m(n)&&N(r||[],n),m(n)&&r&&r.length>0||(e.removeEventListener(t,s),delete a[t])};r(t.split(" "),function(e){u(e),ji[e]&&u(ji[e])})}else for(t in a)"$destroy"!==t&&e.removeEventListener(t,s),delete a[t]}function Fe(e,t){var n=e.ng339,r=n&&Ci[n];if(r){if(t)return void delete r.data[t];r.handle&&(r.events.$destroy&&r.handle({},"$destroy"),Ue(e)),delete Ci[n],e.ng339=void 0}}function Ne(e,t){var n=e.ng339,r=n&&Ci[n];return t&&!r&&(e.ng339=n=_e(),r=Ci[n]={events:{},data:{},handle:void 0}),r}function Re(e,t,n){if(Ae(e)){var r,i=m(n),o=!i&&t&&!y(t),a=!t,s=Ne(e,!o),u=s&&s.data;if(i)u[Se(t)]=n;else{if(a)return u;if(o)return u&&u[Se(t)];for(r in t)u[Se(r)]=t[r]}}}function ze(e,t){return!!e.getAttribute&&(" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ").indexOf(" "+t+" ")>-1}function Le(e,t){t&&e.setAttribute&&r(t.split(" "),function(t){e.setAttribute("class",fi((" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ").replace(" "+fi(t)+" "," ")))})}function He(e,t){if(t&&e.setAttribute){var n=(" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ");r(t.split(" "),function(e){e=fi(e),n.indexOf(" "+e+" ")===-1&&(n+=e+" ")}),e.setAttribute("class",fi(n))}}function qe(e,t){if(t)if(t.nodeType)e[e.length++]=t;else{var n=t.length;if("number"==typeof n&&t.window!==t){if(n)for(var r=0;r<n;r++)e[e.length++]=t[r]}else e[e.length++]=t}}function Be(e,t){return We(e,"$"+(t||"ngController")+"Controller")}function We(e,t,n){e.nodeType===ki&&(e=e.documentElement);for(var r=li(t)?t:[t];e;){for(var i=0,o=r.length;i<o;i++)if(m(n=Jr.data(e,r[i])))return n;e=e.parentNode||e.nodeType===Ei&&e.host}}function Ge(e){for(Ie(e,!0);e.firstChild;)e.removeChild(e.firstChild)}function Xe(e,t){t||Ie(e);var n=e.parentNode;n&&n.removeChild(e)}function Ke(t,n){n=n||e,"complete"===n.document.readyState?n.setTimeout(t):Jr(n).on("load",t)}function Ye(t){function n(){e.document.removeEventListener("DOMContentLoaded",n),e.removeEventListener("load",n),t()}"complete"===e.document.readyState?e.setTimeout(t):(e.document.addEventListener("DOMContentLoaded",n),e.addEventListener("load",n))}function Je(e,t){var n=Ri[t.toLowerCase()];return n&&zi[U(e)]&&n}function Ze(e){return Li[e]}function Qe(e,t){var n=function(n,r){n.isDefaultPrevented=function(){return n.defaultPrevented};var i=t[r||n.type],o=i?i.length:0;if(o){if(v(n.immediatePropagationStopped)){var a=n.stopImmediatePropagation;n.stopImmediatePropagation=function(){n.immediatePropagationStopped=!0,n.stopPropagation&&n.stopPropagation(),a&&a.call(n)}}n.isImmediatePropagationStopped=function(){return n.immediatePropagationStopped===!0};var s=i.specialHandlerWrapper||et;o>1&&(i=ye(i));for(var u=0;u<o;u++)n.isImmediatePropagationStopped()||s(e,n,i[u])}};return n.elem=e,n}function et(e,t,n){n.call(e,t)}function tt(e,t,n){var r=t.relatedTarget;r&&(r===e||Fi.call(e,r))||n.call(e,t)}function nt(){this.$get=function(){return l(De,{hasClass:function(e,t){return e.attr&&(e=e[0]),ze(e,t)},addClass:function(e,t){return e.attr&&(e=e[0]),He(e,t)},removeClass:function(e,t){return e.attr&&(e=e[0]),Le(e,t)}})}}function rt(e,t){var n=e&&e.$$hashKey;if(n)return"function"==typeof n&&(n=e.$$hashKey()),n;var r=typeof e;return n="function"===r||"object"===r&&null!==e?e.$$hashKey=r+":"+(t||a)():r+":"+e}function it(e,t){if(t){var n=0;this.nextUid=function(){return++n}}r(e,this.put,this)}function ot(e){return Function.prototype.toString.call(e)+" "}function at(e){var t=ot(e).replace(Xi,""),n=t.match(qi)||t.match(Bi);return n}function st(e){var t=at(e);return t?"function("+(t[1]||"").replace(/[\s\r\n]+/," ")+")":"fn"}function ut(e,t,n){var i,o,a;if("function"==typeof e){if(!(i=e.$inject)){if(i=[],e.length){if(t)throw w(n)&&n||(n=e.name||st(e)),Ki("strictdi","{0} is not using explicit annotation and cannot be invoked in strict mode",n);o=at(e),r(o[1].split(Wi),function(e){e.replace(Gi,function(e,t,n){i.push(n)})})}e.$inject=i}}else li(e)?(a=e.length-1,de(e[a],"fn"),i=e.slice(0,a)):de(e,"fn",!0);return i}function lt(e,t){function n(e){return function(t,n){return y(t)?void r(t,o(e)):e(t,n)}}function i(e,t){if(pe(e,"service"),(k(t)||li(t))&&(t=_.instantiate(t)),!t.$get)throw Ki("pget","Provider '{0}' must define $get factory method.",e);return x[e+$]=t}function a(e,t){return function(){var n=C.invoke(t,this);if(v(n))throw Ki("undef","Provider '{0}' must return a value from $get factory method.",e);return n}}function s(e,t,n){return i(e,{$get:n!==!1?a(e,t):t})}function u(e,t){return s(e,["$injector",function(e){return e.instantiate(t)}])}function l(e,t){return s(e,g(t),!1)}function c(e,t){pe(e,"constant"),x[e]=t,E[e]=t}function f(e,t){var n=_.get(e+$),r=n.$get;n.$get=function(){var e=C.invoke(r,n);return C.invoke(t,null,{$delegate:e})}}function d(e){fe(v(e)||li(e),"modulesToLoad","not an array");var t,n=[];return r(e,function(e){function r(e){var t,n;for(t=0,n=e.length;t<n;t++){var r=e[t],i=_.get(r[0]);i[r[1]].apply(i,r[2])}}if(!b.get(e)){b.put(e,!0);try{w(e)?(t=Qr(e),n=n.concat(d(t.requires)).concat(t._runBlocks),r(t._invokeQueue),r(t._configBlocks)):k(e)?n.push(_.invoke(e)):li(e)?n.push(_.invoke(e)):de(e,"module")}catch(i){throw li(e)&&(e=e[e.length-1]),i.message&&i.stack&&i.stack.indexOf(i.message)===-1&&(i=i.message+"\n"+i.stack),Ki("modulerr","Failed to instantiate module {0} due to:\n{1}",e,i.stack||i.message||i)}}}),n}function p(e,n){function r(t,r){if(e.hasOwnProperty(t)){if(e[t]===h)throw Ki("cdep","Circular dependency found: {0}",t+" <- "+m.join(" <- "));return e[t]}try{return m.unshift(t),e[t]=h,e[t]=n(t,r),e[t]}catch(i){throw e[t]===h&&delete e[t],i}finally{m.shift()}}function i(e,n,i){for(var o=[],a=lt.$$annotate(e,t,i),s=0,u=a.length;s<u;s++){var l=a[s];if("string"!=typeof l)throw Ki("itkn","Incorrect injection token! Expected service name as string, got {0}",l);o.push(n&&n.hasOwnProperty(l)?n[l]:r(l,i))}return o}function o(e){if(Yr||"function"!=typeof e)return!1;var t=e.$$ngIsClass;return j(t)||(t=e.$$ngIsClass=/^(?:class\b|constructor\()/.test(ot(e))),t}function a(e,t,n,r){"string"==typeof n&&(r=n,n=null);var a=i(e,n,r);return li(e)&&(e=e[e.length-1]),o(e)?(a.unshift(null),new(Function.prototype.bind.apply(e,a))):e.apply(t,a)}function s(e,t,n){var r=li(e)?e[e.length-1]:e,o=i(e,t,n);return o.unshift(null),new(Function.prototype.bind.apply(r,o))}return{invoke:a,instantiate:s,get:r,annotate:lt.$$annotate,has:function(t){return x.hasOwnProperty(t+$)||e.hasOwnProperty(t)}}}t=t===!0;var h={},$="Provider",m=[],b=new it([],(!0)),x={$provide:{provider:n(i),factory:n(s),service:n(u),value:n(l),constant:n(c),decorator:f}},_=x.$injector=p(x,function(e,t){throw ai.isString(t)&&m.push(t),Ki("unpr","Unknown provider: {0}",m.join(" <- "))}),E={},S=p(E,function(e,t){var n=_.get(e+$,t);return C.invoke(n.$get,n,void 0,e)}),C=S;x["$injector"+$]={$get:g(S)};var A=d(e);return C=S.get("$injector"),C.strictDi=t,r(A,function(e){e&&C.invoke(e)}),C}function ct(){var e=!0;this.disableAutoScrolling=function(){e=!1},this.$get=["$window","$location","$rootScope",function(t,n,r){function i(e){var t=null;return Array.prototype.some.call(e,function(e){if("a"===U(e))return t=e,!0}),t}function o(){var e=s.yOffset;if(k(e))e=e();else if(V(e)){var n=e[0],r=t.getComputedStyle(n);e="fixed"!==r.position?0:n.getBoundingClientRect().bottom}else x(e)||(e=0);return e}function a(e){if(e){e.scrollIntoView();var n=o();if(n){var r=e.getBoundingClientRect().top;t.scrollBy(0,r-n)}}else t.scrollTo(0,0)}function s(e){e=w(e)?e:x(e)?e.toString():n.hash();var t;e?(t=u.getElementById(e))?a(t):(t=i(u.getElementsByName(e)))?a(t):"top"===e&&a(null):a(null)}var u=t.document;return e&&r.$watch(function(){return n.hash()},function(e,t){e===t&&""===e||Ke(function(){r.$evalAsync(s)})}),s}]}function ft(e,t){return e||t?e?t?(li(e)&&(e=e.join(" ")),li(t)&&(t=t.join(" ")),e+" "+t):e:t:""}function dt(e){for(var t=0;t<e.length;t++){var n=e[t];if(n.nodeType===Ji)return n}}function pt(e){w(e)&&(e=e.split(" "));var t=$e();return r(e,function(e){e.length&&(t[e]=!0)}),t}function ht(e){return y(e)?e:{}}function gt(e,t,n,i){function o(e){try{e.apply(null,H(arguments,1))}finally{if(m--,0===m)for(;y.length;)try{y.pop()()}catch(t){n.error(t)}}}function a(e){var t=e.indexOf("#");return t===-1?"":e.substr(t)}function s(){k=null,u(),l()}function u(){b=E(),b=v(b)?null:b,z(b,A)&&(b=A),A=b}function l(){x===c.url()&&w===b||(x=c.url(),w=b,r(S,function(e){e(c.url(),b)}))}var c=this,f=e.location,d=e.history,h=e.setTimeout,g=e.clearTimeout,$={};c.isMock=!1;var m=0,y=[];c.$$completeOutstandingRequest=o,c.$$incOutstandingRequestCount=function(){m++},c.notifyWhenNoOutstandingRequests=function(e){0===m?e():y.push(e)};var b,w,x=f.href,_=t.find("base"),k=null,E=i.history?function(){try{return d.state}catch(e){}}:p;u(),w=b,c.url=function(t,n,r){if(v(r)&&(r=null),f!==e.location&&(f=e.location),d!==e.history&&(d=e.history),t){var o=w===r;if(x===t&&(!i.history||o))return c;var s=x&&Yt(x)===Yt(t);return x=t,w=r,!i.history||s&&o?(s||(k=t),n?f.replace(t):s?f.hash=a(t):f.href=t,f.href!==t&&(k=t)):(d[n?"replaceState":"pushState"](r,"",t),u(),w=b),k&&(k=t),c}return k||f.href.replace(/%27/g,"'")},c.state=function(){return b};var S=[],C=!1,A=null;c.onUrlChange=function(t){return C||(i.history&&Jr(e).on("popstate",s),Jr(e).on("hashchange",s),C=!0),S.push(t),t},c.$$applicationDestroyed=function(){Jr(e).off("hashchange popstate",s)},c.$$checkUrlChange=l,c.baseHref=function(){var e=_.attr("href");return e?e.replace(/^(https?:)?\/\/[^\/]*/,""):""},c.defer=function(e,t){var n;return m++,n=h(function(){delete $[n],o(e)},t||0),$[n]=!0,n},c.defer.cancel=function(e){return!!$[e]&&(delete $[e],g(e),o(p),!0)}}function $t(){this.$get=["$window","$log","$sniffer","$document",function(e,t,n,r){return new gt(e,r,t,n)}]}function vt(){this.$get=function(){function e(e,r){function i(e){e!==d&&(p?p===e&&(p=e.n):p=e,o(e.n,e.p),o(e,d),d=e,d.n=null)}function o(e,t){e!==t&&(e&&(e.p=t),t&&(t.n=e))}if(e in n)throw t("$cacheFactory")("iid","CacheId '{0}' is already taken!",e);var a=0,s=l({},r,{id:e}),u=$e(),c=r&&r.capacity||Number.MAX_VALUE,f=$e(),d=null,p=null;return n[e]={put:function(e,t){if(!v(t)){if(c<Number.MAX_VALUE){var n=f[e]||(f[e]={key:e});i(n)}return e in u||a++,u[e]=t,a>c&&this.remove(p.key),t}},get:function(e){if(c<Number.MAX_VALUE){var t=f[e];if(!t)return;i(t)}return u[e]},remove:function(e){if(c<Number.MAX_VALUE){var t=f[e];if(!t)return;t===d&&(d=t.p),t===p&&(p=t.n),o(t.n,t.p),delete f[e]}e in u&&(delete u[e],a--)},removeAll:function(){u=$e(),a=0,f=$e(),d=p=null},destroy:function(){u=null,s=null,f=null,delete n[e]},info:function(){return l({},s,{size:a})}}}var n={};return e.info=function(){var e={};return r(n,function(t,n){e[n]=t.info()}),e},e.get=function(e){return n[e]},e}}function mt(){this.$get=["$cacheFactory",function(e){return e("templates")}]}function yt(){}function bt(t,n){function i(e,t,n){var i=/^\s*([@&<]|=(\*?))(\??)\s*(\w*)\s*$/,o=$e();return r(e,function(e,r){if(e in A)return void(o[r]=A[e]);var a=e.match(i);if(!a)throw oo("iscp","Invalid {3} for directive '{0}'. Definition: {... {1}: '{2}' ...}",t,r,e,n?"controller bindings definition":"isolate scope definition");o[r]={mode:a[1][0],collection:"*"===a[2],optional:"?"===a[3],attrName:a[4]||r},a[4]&&(A[e]=o[r])}),o}function a(e,t){var n={isolateScope:null,bindToController:null};if(y(e.scope)&&(e.bindToController===!0?(n.bindToController=i(e.scope,t,!0),n.isolateScope={}):n.isolateScope=i(e.scope,t,!1)),y(e.bindToController)&&(n.bindToController=i(e.bindToController,t,!0)),n.bindToController&&!e.controller)throw oo("noctrl","Cannot bind to controller without directive '{0}'s controller.",t);return n}function s(e){var t=e.charAt(0);if(!t||t!==Wr(t))throw oo("baddir","Directive/Component name '{0}' is invalid. The first character must be a lowercase letter",e);if(e!==e.trim())throw oo("baddir","Directive/Component name '{0}' is invalid. The name should not contain leading or trailing whitespaces",e)}function u(e){var t=e.require||e.controller&&e.name;return!li(t)&&y(t)&&r(t,function(e,n){var r=e.match(E),i=e.substring(r[0].length);i||(t[n]=r[0]+n)}),t}function c(e,t){if(e&&(!w(e)||!/[EACM]/.test(e)))throw oo("badrestrict","Restrict property '{0}' of directive '{1}' is invalid",e,t);return e||"EA"}var f={},$="Directive",b=/^\s*directive:\s*([\w-]+)\s+(.*)$/,x=/(([\w-]+)(?::([^;]+))?;?)/,_=I("ngSrc,ngSrcset,src,srcset"),E=/^(?:(\^\^?)?(\?)?(\^\^?)?)?/,S=/^(on[a-z]+|formaction)$/,A=$e();this.directive=function V(e,n){return fe(e,"name"),pe(e,"directive"),w(e)?(s(e),fe(n,"directiveFactory"),f.hasOwnProperty(e)||(f[e]=[],t.factory(e+$,["$injector","$exceptionHandler",function(t,n){var i=[];return r(f[e],function(r,o){try{var a=t.invoke(r);k(a)?a={compile:g(a)}:!a.compile&&a.link&&(a.compile=g(a.link)),a.priority=a.priority||0,a.index=o,a.name=a.name||e,a.require=u(a),a.restrict=c(a.restrict,e),a.$$moduleName=r.$$moduleName,i.push(a)}catch(s){n(s)}}),i}])),f[e].push(n)):r(e,o(V)),this},this.component=function(e,t){function n(e){function n(t){return k(t)||li(t)?function(n,r){return e.invoke(t,this,{$element:n,$attrs:r})}:t}var o=t.template||t.templateUrl?t.template:"",a={controller:i,controllerAs:Et(t.controller)||t.controllerAs||"$ctrl",template:n(o),templateUrl:n(t.templateUrl),transclude:t.transclude,scope:{},bindToController:t.bindings||{},restrict:"E",require:t.require};return r(t,function(e,t){"$"===t.charAt(0)&&(a[t]=e)}),a}var i=t.controller||function(){};return r(t,function(e,t){"$"===t.charAt(0)&&(n[t]=e,k(i)&&(i[t]=e))}),n.$inject=["$injector"],this.directive(e,n)},this.aHrefSanitizationWhitelist=function(e){return m(e)?(n.aHrefSanitizationWhitelist(e),this):n.aHrefSanitizationWhitelist()},this.imgSrcSanitizationWhitelist=function(e){return m(e)?(n.imgSrcSanitizationWhitelist(e),this):n.imgSrcSanitizationWhitelist()};var O=!0;this.debugInfoEnabled=function(e){return m(e)?(O=e,this):O};var M=!1;this.preAssignBindingsEnabled=function(e){return m(e)?(M=e,this):M};var T=10;this.onChangesTtl=function(e){return arguments.length?(T=e,this):T};var P=!0;this.commentDirectivesEnabled=function(e){return arguments.length?(P=e,this):P};var D=!0;this.cssClassDirectivesEnabled=function(e){return arguments.length?(D=e,this):D},this.$get=["$injector","$interpolate","$exceptionHandler","$templateRequest","$parse","$controller","$rootScope","$sce","$animate","$$sanitizeUri",function(t,n,i,o,s,u,c,g,A,V){function I(){try{if(!--Oe)throw _e=void 0,oo("infchng","{0} $onChanges() iterations reached. Aborting!\n",T);c.$apply(function(){for(var e=[],t=0,n=_e.length;t<n;++t)try{_e[t]()}catch(r){e.push(r)}if(_e=void 0,e.length)throw e})}finally{Oe++}}function F(e,t){if(t){var n,r,i,o=Object.keys(t);for(n=0,r=o.length;n<r;n++)i=o[n],this[i]=t[i]}else this.$attr={};this.$$element=e}function R(e,t,n){Ee.innerHTML="<span "+t+">";var r=Ee.firstChild.attributes,i=r[0];r.removeNamedItem(i.name),i.value=n,e.attributes.setNamedItem(i)}function L(e,t){try{e.addClass(t)}catch(n){}}function B(e,t,n,r,i){e instanceof Jr||(e=Jr(e));var o=G(e,t,e,n,r,i);B.$$addScopeClass(e);var a=null;return function(t,n,r){if(!e)throw oo("multilink","This element has already been linked.");fe(t,"scope"),i&&i.needsNewScope&&(t=t.$parent.$new()),r=r||{};var s=r.parentBoundTranscludeFn,u=r.transcludeControllers,l=r.futureParentElement;s&&s.$$boundTransclude&&(s=s.$$boundTransclude),a||(a=W(l));var c;if(c="html"!==a?Jr(ge(a,Jr("<div>").append(e).html())):n?Ni.clone.call(e):e,u)for(var f in u)c.data("$"+f+"Controller",u[f].instance);return B.$$addScopeInfo(c,t),n&&n(c,t),o&&o(t,c,c,s),n||(e=o=null),c}}function W(e){var t=e&&e[0];return t&&"foreignobject"!==U(t)&&ri.call(t).match(/SVG/)?"svg":"html"}function G(e,t,n,r,i,o){function a(e,n,r,i){var o,a,s,u,l,c,f,d,g;if(p){var $=n.length;for(g=new Array($),l=0;l<h.length;l+=3)f=h[l],g[f]=n[f]}else g=n;for(l=0,c=h.length;l<c;)s=g[h[l++]],o=h[l++],a=h[l++],o?(o.scope?(u=e.$new(),B.$$addScopeInfo(Jr(s),u)):u=e,d=o.transcludeOnThisElement?K(e,o.transclude,i):!o.templateOnThisElement&&i?i:!i&&t?K(e,t):null,o(a,u,s,r,d)):a&&a(e,s.childNodes,void 0,i)}for(var s,u,l,c,f,d,p,h=[],g=li(e)||e instanceof Jr,$=0;$<e.length;$++)s=new F,11===Yr&&X(e,$,g),u=Y(e[$],[],s,0===$?r:void 0,i),l=u.length?ne(u,e[$],s,t,n,null,[],[],o):null,l&&l.scope&&B.$$addScopeClass(s.$$element),f=l&&l.terminal||!(c=e[$].childNodes)||!c.length?null:G(c,l?(l.transcludeOnThisElement||!l.templateOnThisElement)&&l.transclude:t),(l||f)&&(h.push($,l,f),d=!0,p=p||l),o=null;return d?a:null}function X(e,t,n){var r,i=e[t],o=i.parentNode;if(i.nodeType===xi)for(;;){if(r=o?i.nextSibling:e[t+1],!r||r.nodeType!==xi)break;i.nodeValue=i.nodeValue+r.nodeValue,r.parentNode&&r.parentNode.removeChild(r),n&&r===e[t+1]&&e.splice(t+1,1)}}function K(e,t,n){function r(r,i,o,a,s){return r||(r=e.$new(!1,s),r.$$transcluded=!0),t(r,i,{parentBoundTranscludeFn:n,transcludeControllers:o,futureParentElement:a})}var i=r.$$slots=$e();for(var o in t.$$slots)t.$$slots[o]?i[o]=K(e,t.$$slots[o],n):i[o]=null;return r}function Y(e,t,n,r,i){var o,a,s,u=e.nodeType,l=n.$attr;switch(u){case bi:a=U(e),ae(t,xt(a),"E",r,i);for(var c,f,d,p,h,g,$=e.attributes,v=0,m=$&&$.length;v<m;v++){var b=!1,_=!1;c=$[v],f=c.name,h=c.value,p=xt(f),g=Pe.test(p),g&&(f=f.replace(so,"").substr(8).replace(/_(.)/g,function(e,t){return t.toUpperCase()}));var k=p.match(De);k&&se(k[1])&&(b=f,_=f.substr(0,f.length-5)+"end",f=f.substr(0,f.length-6)),d=xt(f.toLowerCase()),l[d]=f,!g&&n.hasOwnProperty(d)||(n[d]=h,Je(e,d)&&(n[d]=!0)),me(e,t,h,d,g),ae(t,d,"A",r,i,b,_)}if("input"===a&&"hidden"===e.getAttribute("type")&&e.setAttribute("autocomplete","off"),!Ae)break;if(s=e.className,y(s)&&(s=s.animVal),w(s)&&""!==s)for(;o=x.exec(s);)d=xt(o[2]),ae(t,d,"C",r,i)&&(n[d]=fi(o[3])),s=s.substr(o.index+o[0].length);break;case xi:he(t,e.nodeValue);break;case _i:if(!Se)break;Z(e,t,n,r,i)}return t.sort(de),t}function Z(e,t,n,r,i){try{var o=b.exec(e.nodeValue);if(o){var a=xt(o[1]);ae(t,a,"M",r,i)&&(n[a]=fi(o[2]))}}catch(s){}}function Q(e,t,n){var r=[],i=0;if(t&&e.hasAttribute&&e.hasAttribute(t)){do{if(!e)throw oo("uterdir","Unterminated attribute, found '{0}' but no matching '{1}' found.",t,n);e.nodeType===bi&&(e.hasAttribute(t)&&i++,e.hasAttribute(n)&&i--),r.push(e),e=e.nextSibling}while(i>0)}else r.push(e);return Jr(r)}function ee(e,t,n){return function(r,i,o,a,s){return i=Q(i[0],t,n),e(r,i,o,a,s)}}function te(e,t,n,r,i,o){var a;return e?B(t,n,r,i,o):function(){return a||(a=B(t,n,r,i,o),t=n=o=null),a.apply(this,arguments)}}function ne(e,t,n,o,a,s,u,c,f){function d(e,t,n,r){e&&(n&&(e=ee(e,n,r)),e.require=h.require,e.directiveName=g,(E===h||h.$$isolateScope)&&(e=be(e,{isolateScope:!0})),u.push(e)),t&&(n&&(t=ee(t,n,r)),t.require=h.require,t.directiveName=g,(E===h||h.$$isolateScope)&&(t=be(t,{isolateScope:!0})),c.push(t))}function p(e,o,a,s,f){function d(e,t,n,r){var i;if(C(e)||(r=n,n=t,t=e,e=void 0),T&&(i=b),n||(n=T?A.parent():A),!r)return f(e,t,i,n,N);var o=f.$$slots[r];if(o)return o(e,t,i,n,N);if(v(o))throw oo("noslot",'No parent directive that requires a transclusion with slot name "{0}". Element: {1}',r,J(A))}var p,h,g,$,m,b,w,A,O,j;t===a?(O=n,A=n.$$element):(A=Jr(a),O=new F(A,n)),m=o,E?$=o.$new(!0):x&&(m=o.$parent),f&&(w=d,w.$$boundTransclude=f,w.isSlotFilled=function(e){return!!f.$$slots[e]}),_&&(b=ie(A,O,w,_,$,o,E)),E&&(B.$$addScopeInfo(A,$,!0,!(S&&(S===E||S===E.$$originalDirective))),B.$$addScopeClass(A,!0),$.$$isolateBindings=E.$$isolateBindings,j=xe(o,O,$,$.$$isolateBindings,E),j.removeWatches&&$.$on("$destroy",j.removeWatches));for(var P in b){var D=_[P],V=b[P],I=D.$$bindings.bindToController;if(M){I?V.bindingInfo=xe(m,O,V.instance,I,D):V.bindingInfo={};var U=V();U!==V.instance&&(V.instance=U,A.data("$"+D.name+"Controller",U),V.bindingInfo.removeWatches&&V.bindingInfo.removeWatches(),V.bindingInfo=xe(m,O,V.instance,I,D))}else V.instance=V(),A.data("$"+D.name+"Controller",V.instance),V.bindingInfo=xe(m,O,V.instance,I,D)}for(r(_,function(e,t){var n=e.require;e.bindToController&&!li(n)&&y(n)&&l(b[t].instance,re(t,n,A,b))}),r(b,function(e){var t=e.instance;if(k(t.$onChanges))try{t.$onChanges(e.bindingInfo.initialChanges)}catch(n){i(n)}if(k(t.$onInit))try{t.$onInit()}catch(n){i(n)}k(t.$doCheck)&&(m.$watch(function(){t.$doCheck()}),t.$doCheck()),k(t.$onDestroy)&&m.$on("$destroy",function(){t.$onDestroy()})}),p=0,h=u.length;p<h;p++)g=u[p],we(g,g.isolateScope?$:o,A,O,g.require&&re(g.directiveName,g.require,A,b),w);var N=o;for(E&&(E.template||null===E.templateUrl)&&(N=$),e&&e(N,a.childNodes,void 0,f),p=c.length-1;p>=0;p--)g=c[p],we(g,g.isolateScope?$:o,A,O,g.require&&re(g.directiveName,g.require,A,b),w);r(b,function(e){var t=e.instance;k(t.$postLink)&&t.$postLink()})}f=f||{};for(var h,g,$,m,b,w=-Number.MAX_VALUE,x=f.newScopeDirective,_=f.controllerDirectives,E=f.newIsolateScopeDirective,S=f.templateDirective,A=f.nonTlbTranscludeDirective,O=!1,j=!1,T=f.hasElementTranscludeDirective,P=n.$$element=Jr(t),D=s,V=o,I=!1,N=!1,R=0,z=e.length;R<z;R++){h=e[R];var L=h.$$start,W=h.$$end;if(L&&(P=Q(t,L,W)),$=void 0,w>h.priority)break;if(b=h.scope,b&&(h.templateUrl||(y(b)?(pe("new/isolated scope",E||x,h,P),E=h):pe("new/isolated scope",E,h,P)),x=x||h),g=h.name,!I&&(h.replace&&(h.templateUrl||h.template)||h.transclude&&!h.$$tlb)){for(var G,X=R+1;G=e[X++];)if(G.transclude&&!G.$$tlb||G.replace&&(G.templateUrl||G.template)){N=!0;break}I=!0}if(!h.templateUrl&&h.controller&&(_=_||$e(),pe("'"+g+"' controller",_[g],h,P),_[g]=h),b=h.transclude)if(O=!0,h.$$tlb||(pe("transclusion",A,h,P),A=h),"element"===b)T=!0,w=h.priority,$=P,P=n.$$element=Jr(B.$$createComment(g,n[g])),t=P[0],ye(a,H($),t),$[0].$$parentNode=$[0].parentNode,V=te(N,$,o,w,D&&D.name,{nonTlbTranscludeDirective:A});else{var K=$e();if(y(b)){$=[];var Z=$e(),ne=$e();r(b,function(e,t){var n="?"===e.charAt(0);e=n?e.substring(1):e,Z[e]=t,K[t]=null,ne[t]=n}),r(P.contents(),function(e){var t=Z[xt(U(e))];t?(ne[t]=!0,K[t]=K[t]||[],K[t].push(e)):$.push(e)}),r(ne,function(e,t){if(!e)throw oo("reqslot","Required transclusion slot `{0}` was not filled.",t)});for(var ae in K)K[ae]&&(K[ae]=te(N,K[ae],o))}else $=Jr(Ve(t)).contents();P.empty(),V=te(N,$,o,void 0,void 0,{needsNewScope:h.$$isolateScope||h.$$newScope}),V.$$slots=K}if(h.template)if(j=!0,pe("template",S,h,P),S=h,b=k(h.template)?h.template(P,n):h.template,b=Te(b),h.replace){if(D=h,$=Ce(b)?[]:kt(ge(h.templateNamespace,fi(b))),t=$[0],1!==$.length||t.nodeType!==bi)throw oo("tplrt","Template for directive '{0}' must have exactly one root element. {1}",g,"");ye(a,P,t);var se={$attr:{}},le=Y(t,[],se),fe=e.splice(R+1,e.length-(R+1));(E||x)&&oe(le,E,x),e=e.concat(le).concat(fe),ue(n,se),z=e.length}else P.html(b);if(h.templateUrl)j=!0,pe("template",S,h,P),S=h,h.replace&&(D=h),p=ce(e.splice(R,e.length-R),P,n,a,O&&V,u,c,{controllerDirectives:_,newScopeDirective:x!==h&&x,newIsolateScopeDirective:E,templateDirective:S,nonTlbTranscludeDirective:A}),z=e.length;else if(h.compile)try{m=h.compile(P,n,V);var de=h.$$originalDirective||h;k(m)?d(null,q(de,m),L,W):m&&d(q(de,m.pre),q(de,m.post),L,W)}catch(he){i(he,J(P))}h.terminal&&(p.terminal=!0,w=Math.max(w,h.priority))}return p.scope=x&&x.scope===!0,p.transcludeOnThisElement=O,p.templateOnThisElement=j,p.transclude=V,f.hasElementTranscludeDirective=T,p}function re(e,t,n,i){var o;if(w(t)){var a=t.match(E),s=t.substring(a[0].length),u=a[1]||a[3],l="?"===a[2];if("^^"===u?n=n.parent():(o=i&&i[s],o=o&&o.instance),!o){var c="$"+s+"Controller";o=u?n.inheritedData(c):n.data(c)}if(!o&&!l)throw oo("ctreq","Controller '{0}', required by directive '{1}', can't be found!",s,e)}else if(li(t)){o=[];for(var f=0,d=t.length;f<d;f++)o[f]=re(e,t[f],n,i)}else y(t)&&(o={},r(t,function(t,r){o[r]=re(e,t,n,i)}));return o||null}function ie(e,t,n,r,i,o,a){var s=$e();for(var l in r){var c=r[l],f={$scope:c===a||c.$$isolateScope?i:o,$element:e,$attrs:t,$transclude:n},d=c.controller;"@"===d&&(d=t[c.name]);var p=u(d,f,!0,c.controllerAs);s[c.name]=p,e.data("$"+c.name+"Controller",p.instance)}return s}function oe(e,t,n){for(var r=0,i=e.length;r<i;r++)e[r]=d(e[r],{$$isolateScope:t,$$newScope:n})}function ae(e,n,r,i,o,s,u){if(n===o)return null;var l=null;if(f.hasOwnProperty(n))for(var c,p=t.get(n+$),h=0,g=p.length;h<g;h++)if(c=p[h],(v(i)||i>c.priority)&&c.restrict.indexOf(r)!==-1){
|
4 |
+
if(s&&(c=d(c,{$$start:s,$$end:u})),!c.$$bindings){var m=c.$$bindings=a(c,c.name);y(m.isolateScope)&&(c.$$isolateBindings=m.isolateScope)}e.push(c),l=c}return l}function se(e){if(f.hasOwnProperty(e))for(var n,r=t.get(e+$),i=0,o=r.length;i<o;i++)if(n=r[i],n.multiElement)return!0;return!1}function ue(e,t){var n=t.$attr,i=e.$attr;r(e,function(r,i){"$"!==i.charAt(0)&&(t[i]&&t[i]!==r&&(r.length?r+=("style"===i?";":" ")+t[i]:r=t[i]),e.$set(i,r,!0,n[i]))}),r(t,function(t,r){e.hasOwnProperty(r)||"$"===r.charAt(0)||(e[r]=t,"class"!==r&&"style"!==r&&(i[r]=n[r]))})}function ce(e,t,n,a,s,u,l,c){var f,h,g=[],$=t[0],v=e.shift(),m=d(v,{templateUrl:null,transclude:null,replace:null,$$originalDirective:v}),b=k(v.templateUrl)?v.templateUrl(t,n):v.templateUrl,w=v.templateNamespace;return t.empty(),o(b).then(function(i){var o,d,p,x;if(i=Te(i),v.replace){if(p=Ce(i)?[]:kt(ge(w,fi(i))),o=p[0],1!==p.length||o.nodeType!==bi)throw oo("tplrt","Template for directive '{0}' must have exactly one root element. {1}",v.name,b);d={$attr:{}},ye(a,t,o);var _=Y(o,[],d);y(v.scope)&&oe(_,!0),e=_.concat(e),ue(n,d)}else o=$,t.html(i);for(e.unshift(m),f=ne(e,o,n,s,t,v,u,l,c),r(a,function(e,n){e===o&&(a[n]=t[0])}),h=G(t[0].childNodes,s);g.length;){var k=g.shift(),E=g.shift(),S=g.shift(),C=g.shift(),A=t[0];if(!k.$$destroyed){if(E!==$){var O=E.className;c.hasElementTranscludeDirective&&v.replace||(A=Ve(o)),ye(S,Jr(E),A),L(Jr(A),O)}x=f.transcludeOnThisElement?K(k,f.transclude,C):C,f(h,k,A,a,x)}}g=null})["catch"](function(e){e instanceof Error&&i(e)})["catch"](p),function(e,t,n,r,i){var o=i;t.$$destroyed||(g?g.push(t,n,r,o):(f.transcludeOnThisElement&&(o=K(t,f.transclude,i)),f(h,t,n,r,o)))}}function de(e,t){var n=t.priority-e.priority;return 0!==n?n:e.name!==t.name?e.name<t.name?-1:1:e.index-t.index}function pe(e,t,n,r){function i(e){return e?" (module: "+e+")":""}if(t)throw oo("multidir","Multiple directives [{0}{1}, {2}{3}] asking for {4} on: {5}",t.name,i(t.$$moduleName),n.name,i(n.$$moduleName),e,J(r))}function he(e,t){var r=n(t,!0);r&&e.push({priority:0,compile:function(e){var t=e.parent(),n=!!t.length;return n&&B.$$addBindingClass(t),function(e,t){var i=t.parent();n||B.$$addBindingClass(i),B.$$addBindingInfo(i,r.expressions),e.$watch(r,function(e){t[0].nodeValue=e})}}})}function ge(t,n){switch(t=Wr(t||"html")){case"svg":case"math":var r=e.document.createElement("div");return r.innerHTML="<"+t+">"+n+"</"+t+">",r.childNodes[0].childNodes;default:return n}}function ve(e,t){if("srcdoc"===t)return g.HTML;var n=U(e);if("src"===t||"ngSrc"===t){if(["img","video","audio","source","track"].indexOf(n)===-1)return g.RESOURCE_URL}else if("xlinkHref"===t||"form"===n&&"action"===t||"link"===n&&"href"===t)return g.RESOURCE_URL}function me(e,t,r,i,o){var a=ve(e,i),s=!o,u=_[i]||o,l=n(r,s,a,u);if(l){if("multiple"===i&&"select"===U(e))throw oo("selmulti","Binding to the 'multiple' attribute is not supported. Element: {0}",J(e));if(S.test(i))throw oo("nodomevents","Interpolations for HTML DOM event attributes are disallowed. Please use the ng- versions (such as ng-click instead of onclick) instead.");t.push({priority:100,compile:function(){return{pre:function(e,t,o){var s=o.$$observers||(o.$$observers=$e()),c=o[i];c!==r&&(l=c&&n(c,!0,a,u),r=c),l&&(o[i]=l(e),(s[i]||(s[i]=[])).$$inter=!0,(o.$$observers&&o.$$observers[i].$$scope||e).$watch(l,function(e,t){"class"===i&&e!==t?o.$updateClass(e,t):o.$set(i,e)}))}}}})}}function ye(t,n,r){var i,o,a=n[0],s=n.length,u=a.parentNode;if(t)for(i=0,o=t.length;i<o;i++)if(t[i]===a){t[i++]=r;for(var l=i,c=l+s-1,f=t.length;l<f;l++,c++)c<f?t[l]=t[c]:delete t[l];t.length-=s-1,t.context===a&&(t.context=r);break}u&&u.replaceChild(r,a);var d=e.document.createDocumentFragment();for(i=0;i<s;i++)d.appendChild(n[i]);for(Jr.hasData(a)&&(Jr.data(r,Jr.data(a)),Jr(a).off("$destroy")),Jr.cleanData(d.querySelectorAll("*")),i=1;i<s;i++)delete n[i];n[0]=r,n.length=1}function be(e,t){return l(function(){return e.apply(null,arguments)},e,t)}function we(e,t,n,r,o,a){try{e(t,n,r,o,a)}catch(s){i(s,J(n))}}function xe(e,t,i,o,a){function u(t,n,r){!k(i.$onChanges)||n===r||n!==n&&r!==r||(_e||(e.$$postDigest(I),_e=[]),c||(c={},_e.push(l)),c[t]&&(r=c[t].previousValue),c[t]=new wt(r,n))}function l(){i.$onChanges(c),c=void 0}var c,f=[],d={};return r(o,function(r,o){var l,c,h,g,$,v=r.attrName,m=r.optional,y=r.mode;switch(y){case"@":m||Br.call(t,v)||(i[o]=t[v]=void 0),$=t.$observe(v,function(e){if(w(e)||j(e)){var t=i[o];u(o,e,t),i[o]=e}}),t.$$observers[v].$$scope=e,l=t[v],w(l)?i[o]=n(l)(e):j(l)&&(i[o]=l),d[o]=new wt(ao,i[o]),f.push($);break;case"=":if(!Br.call(t,v)){if(m)break;t[v]=void 0}if(m&&!t[v])break;c=s(t[v]),g=c.literal?z:function(e,t){return e===t||e!==e&&t!==t},h=c.assign||function(){throw l=i[o]=c(e),oo("nonassign","Expression '{0}' in attribute '{1}' used with directive '{2}' is non-assignable!",t[v],v,a.name)},l=i[o]=c(e);var b=function(t){return g(t,i[o])||(g(t,l)?h(e,t=i[o]):i[o]=t),l=t};b.$stateful=!0,$=r.collection?e.$watchCollection(t[v],b):e.$watch(s(t[v],b),null,c.literal),f.push($);break;case"<":if(!Br.call(t,v)){if(m)break;t[v]=void 0}if(m&&!t[v])break;c=s(t[v]);var x=c.literal,_=i[o]=c(e);d[o]=new wt(ao,i[o]),$=e.$watch(c,function(e,t){if(t===e){if(t===_||x&&z(t,_))return;t=_}u(o,e,t),i[o]=e},x),f.push($);break;case"&":if(c=t.hasOwnProperty(v)?s(t[v]):p,c===p&&m)break;i[o]=function(t){return c(e,t)}}}),{initialChanges:d,removeWatches:f.length&&function(){for(var e=0,t=f.length;e<t;++e)f[e]()}}}var _e,ke=/^\w/,Ee=e.document.createElement("div"),Se=P,Ae=D,Oe=T;F.prototype={$normalize:xt,$addClass:function(e){e&&e.length>0&&A.addClass(this.$$element,e)},$removeClass:function(e){e&&e.length>0&&A.removeClass(this.$$element,e)},$updateClass:function(e,t){var n=_t(e,t);n&&n.length&&A.addClass(this.$$element,n);var r=_t(t,e);r&&r.length&&A.removeClass(this.$$element,r)},$set:function(e,t,n,o){var a,s=this.$$element[0],u=Je(s,e),l=Ze(e),c=e;if(u?(this.$$element.prop(e,t),o=u):l&&(this[l]=t,c=l),this[e]=t,o?this.$attr[e]=o:(o=this.$attr[e],o||(this.$attr[e]=o=le(e,"-"))),a=U(this.$$element),"a"===a&&("href"===e||"xlinkHref"===e)||"img"===a&&"src"===e)this[e]=t=V(t,"src"===e);else if("img"===a&&"srcset"===e&&m(t)){for(var f="",d=fi(t),p=/(\s+\d+x\s*,|\s+\d+w\s*,|\s+,|,\s+)/,h=/\s/.test(d)?p:/(,)/,g=d.split(h),$=Math.floor(g.length/2),y=0;y<$;y++){var b=2*y;f+=V(fi(g[b]),!0),f+=" "+fi(g[b+1])}var w=fi(g[2*y]).split(/\s/);f+=V(fi(w[0]),!0),2===w.length&&(f+=" "+fi(w[1])),this[e]=t=f}n!==!1&&(null===t||v(t)?this.$$element.removeAttr(o):ke.test(o)?this.$$element.attr(o,t):R(this.$$element[0],o,t));var x=this.$$observers;x&&r(x[c],function(e){try{e(t)}catch(n){i(n)}})},$observe:function(e,t){var n=this,r=n.$$observers||(n.$$observers=$e()),i=r[e]||(r[e]=[]);return i.push(t),c.$evalAsync(function(){i.$$inter||!n.hasOwnProperty(e)||v(n[e])||t(n[e])}),function(){N(i,t)}}};var Me=n.startSymbol(),je=n.endSymbol(),Te="{{"===Me&&"}}"===je?h:function(e){return e.replace(/\{\{/g,Me).replace(/}}/g,je)},Pe=/^ngAttr[A-Z]/,De=/^(.+)Start$/;return B.$$addBindingInfo=O?function(e,t){var n=e.data("$binding")||[];li(t)?n=n.concat(t):n.push(t),e.data("$binding",n)}:p,B.$$addBindingClass=O?function(e){L(e,"ng-binding")}:p,B.$$addScopeInfo=O?function(e,t,n,r){var i=n?r?"$isolateScopeNoTemplate":"$isolateScope":"$scope";e.data(i,t)}:p,B.$$addScopeClass=O?function(e,t){L(e,t?"ng-isolate-scope":"ng-scope")}:p,B.$$createComment=function(t,n){var r="";return O&&(r=" "+(t||"")+": ",n&&(r+=n+" ")),e.document.createComment(r)},B}]}function wt(e,t){this.previousValue=e,this.currentValue=t}function xt(e){return e.replace(so,"").replace(uo,Ee)}function _t(e,t){var n="",r=e.split(/\s+/),i=t.split(/\s+/);e:for(var o=0;o<r.length;o++){for(var a=r[o],s=0;s<i.length;s++)if(a===i[s])continue e;n+=(n.length>0?" ":"")+a}return n}function kt(e){e=Jr(e);var t=e.length;if(t<=1)return e;for(;t--;){var n=e[t];(n.nodeType===_i||n.nodeType===xi&&""===n.nodeValue.trim())&&ti.call(e,t,1)}return e}function Et(e,t){if(t&&w(t))return t;if(w(e)){var n=co.exec(e);if(n)return n[3]}}function St(){var e={},n=!1;this.has=function(t){return e.hasOwnProperty(t)},this.register=function(t,n){pe(t,"controller"),y(t)?l(e,t):e[t]=n},this.allowGlobals=function(){n=!0},this.$get=["$injector","$window",function(r,i){function o(e,n,r,i){if(!e||!y(e.$scope))throw t("$controller")("noscp","Cannot export controller '{0}' as '{1}'! No $scope object provided via `locals`.",i,n);e.$scope[n]=r}return function(t,a,s,u){var c,f,d,p;if(s=s===!0,u&&w(u)&&(p=u),w(t)){if(f=t.match(co),!f)throw lo("ctrlfmt","Badly formed controller string '{0}'. Must match `__name__ as __id__` or `__name__`.",t);if(d=f[1],p=p||f[3],t=e.hasOwnProperty(d)?e[d]:he(a.$scope,d,!0)||(n?he(i,d,!0):void 0),!t)throw lo("ctrlreg","The controller with the name '{0}' is not registered.",d);de(t,d,!0)}if(s){var h=(li(t)?t[t.length-1]:t).prototype;return c=Object.create(h||null),p&&o(a,p,c,d||t.name),l(function(){var e=r.invoke(t,c,a,d);return e!==c&&(y(e)||k(e))&&(c=e,p&&o(a,p,c,d||t.name)),c},{instance:c,identifier:p})}return c=r.instantiate(t,a,d),p&&o(a,p,c,d||t.name),c}}]}function Ct(){this.$get=["$window",function(e){return Jr(e.document)}]}function At(){this.$get=["$document","$rootScope",function(e,t){function n(){i=r.hidden}var r=e[0],i=r&&r.hidden;return e.on("visibilitychange",n),t.$on("$destroy",function(){e.off("visibilitychange",n)}),function(){return i}}]}function Ot(){this.$get=["$log",function(e){return function(t,n){e.error.apply(e,arguments)}}]}function Mt(e){return y(e)?_(e)?e.toISOString():W(e):e}function jt(){this.$get=function(){return function(e){if(!e)return"";var t=[];return i(e,function(e,n){null===e||v(e)||(li(e)?r(e,function(e){t.push(ne(n)+"="+ne(Mt(e)))}):t.push(ne(n)+"="+ne(Mt(e))))}),t.join("&")}}}function Tt(){this.$get=function(){return function(e){function t(e,o,a){null===e||v(e)||(li(e)?r(e,function(e,n){t(e,o+"["+(y(e)?n:"")+"]")}):y(e)&&!_(e)?i(e,function(e,n){t(e,o+(a?"":"[")+n+(a?"":"]"))}):n.push(ne(o)+"="+ne(Mt(e))))}if(!e)return"";var n=[];return t(e,"",!0),n.join("&")}}}function Pt(e,t){if(w(e)){var n=e.replace(vo,"").trim();if(n){var r=t("Content-Type");(r&&0===r.indexOf(po)||Dt(n))&&(e=G(n))}}return e}function Dt(e){var t=e.match(go);return t&&$o[t[0]].test(e)}function Vt(e){function t(e,t){e&&(i[e]=i[e]?i[e]+", "+t:t)}var n,i=$e();return w(e)?r(e.split("\n"),function(e){n=e.indexOf(":"),t(Wr(fi(e.substr(0,n))),fi(e.substr(n+1)))}):y(e)&&r(e,function(e,n){t(Wr(n),fi(e))}),i}function It(e){var t;return function(n){if(t||(t=Vt(e)),n){var r=t[Wr(n)];return void 0===r&&(r=null),r}return t}}function Ut(e,t,n,i){return k(i)?i(e,t,n):(r(i,function(r){e=r(e,t,n)}),e)}function Ft(e){return 200<=e&&e<300}function Nt(){var e=this.defaults={transformResponse:[Pt],transformRequest:[function(e){return!y(e)||A(e)||M(e)||O(e)?e:W(e)}],headers:{common:{Accept:"application/json, text/plain, */*"},post:ye(ho),put:ye(ho),patch:ye(ho)},xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",paramSerializer:"$httpParamSerializer",jsonpCallbackParam:"callback"},n=!1;this.useApplyAsync=function(e){return m(e)?(n=!!e,this):n};var i=this.interceptors=[];this.$get=["$browser","$httpBackend","$$cookieReader","$cacheFactory","$rootScope","$q","$injector","$sce",function(o,a,s,u,c,f,d,h){function g(n){function i(e,t){for(var n=0,r=t.length;n<r;){var i=t[n++],o=t[n++];e=e.then(i,o)}return t.length=0,e}function a(){o.$$completeOutstandingRequest(p)}function s(e,t){var n,i={};return r(e,function(e,r){k(e)?(n=e(t),null!=n&&(i[r]=n)):i[r]=e}),i}function u(t){var n,r,i,o=e.headers,a=l({},t.headers);o=l({},o.common,o[Wr(t.method)]);e:for(n in o){r=Wr(n);for(i in a)if(Wr(i)===r)continue e;a[n]=o[n]}return s(a,ye(t))}function c(t){var n=t.headers,i=Ut(t.data,It(n),void 0,t.transformRequest);return v(i)&&r(n,function(e,t){"content-type"===Wr(t)&&delete n[t]}),v(t.withCredentials)&&!v(e.withCredentials)&&(t.withCredentials=e.withCredentials),x(t,i).then(g,g)}function g(e){var t=l({},e);return t.data=Ut(e.data,e.headers,e.status,$.transformResponse),Ft(e.status)?t:f.reject(t)}if(!y(n))throw t("$http")("badreq","Http request configuration must be an object. Received: {0}",n);if(!w(h.valueOf(n.url)))throw t("$http")("badreq","Http request configuration url must be a string or a $sce trusted object. Received: {0}",n.url);var $=l({method:"get",transformRequest:e.transformRequest,transformResponse:e.transformResponse,paramSerializer:e.paramSerializer,jsonpCallbackParam:e.jsonpCallbackParam},n);$.headers=u(n),$.method=Gr($.method),$.paramSerializer=w($.paramSerializer)?d.get($.paramSerializer):$.paramSerializer,o.$$incOutstandingRequestCount();var m=[],b=[],_=f.resolve($);return r(C,function(e){(e.request||e.requestError)&&m.unshift(e.request,e.requestError),(e.response||e.responseError)&&b.push(e.response,e.responseError)}),_=i(_,m),_=_.then(c),_=i(_,b),_=_["finally"](a)}function $(e){r(arguments,function(e){g[e]=function(t,n){return g(l({},n||{},{method:e,url:t}))}})}function b(e){r(arguments,function(e){g[e]=function(t,n,r){return g(l({},r||{},{method:e,url:t,data:n}))}})}function x(t,i){function o(e){if(e){var t={};return r(e,function(e,r){t[r]=function(t){function r(){e(t)}n?c.$applyAsync(r):c.$$phase?r():c.$apply(r)}}),t}}function u(e,t,r,i){function o(){l(t,e,r,i)}$&&(Ft(e)?$.put(O,[e,t,Vt(r),i]):$.remove(O)),n?c.$applyAsync(o):(o(),c.$$phase||c.$apply())}function l(e,n,r,i){n=n>=-1?n:0,(Ft(n)?x.resolve:x.reject)({data:e,status:n,headers:It(r),config:t,statusText:i})}function d(e){l(e.data,e.status,ye(e.headers()),e.statusText)}function p(){var e=g.pendingRequests.indexOf(t);e!==-1&&g.pendingRequests.splice(e,1)}var $,b,x=f.defer(),k=x.promise,C=t.headers,A="jsonp"===Wr(t.method),O=t.url;if(A?O=h.getTrustedResourceUrl(O):w(O)||(O=h.valueOf(O)),O=_(O,t.paramSerializer(t.params)),A&&(O=E(O,t.jsonpCallbackParam)),g.pendingRequests.push(t),k.then(p,p),!t.cache&&!e.cache||t.cache===!1||"GET"!==t.method&&"JSONP"!==t.method||($=y(t.cache)?t.cache:y(e.cache)?e.cache:S),$&&(b=$.get(O),m(b)?T(b)?b.then(d,d):li(b)?l(b[1],b[0],ye(b[2]),b[3]):l(b,200,{},"OK"):$.put(O,k)),v(b)){var M=Fn(t.url)?s()[t.xsrfCookieName||e.xsrfCookieName]:void 0;M&&(C[t.xsrfHeaderName||e.xsrfHeaderName]=M),a(t.method,O,i,u,C,t.timeout,t.withCredentials,t.responseType,o(t.eventHandlers),o(t.uploadEventHandlers))}return k}function _(e,t){return t.length>0&&(e+=(e.indexOf("?")===-1?"?":"&")+t),e}function E(e,t){if(/[&?][^=]+=JSON_CALLBACK/.test(e))throw mo("badjsonp",'Illegal use of JSON_CALLBACK in url, "{0}"',e);var n=new RegExp("[&?]"+t+"=");if(n.test(e))throw mo("badjsonp",'Illegal use of callback param, "{0}", in url, "{1}"',t,e);return e+=(e.indexOf("?")===-1?"?":"&")+t+"=JSON_CALLBACK"}var S=u("$http");e.paramSerializer=w(e.paramSerializer)?d.get(e.paramSerializer):e.paramSerializer;var C=[];return r(i,function(e){C.unshift(w(e)?d.get(e):d.invoke(e))}),g.pendingRequests=[],$("get","delete","head","jsonp"),b("post","put","patch"),g.defaults=e,g}]}function Rt(){this.$get=function(){return function(){return new e.XMLHttpRequest}}}function zt(){this.$get=["$browser","$jsonpCallbacks","$document","$xhrFactory",function(e,t,n,r){return Lt(e,r,e.defer,t,n[0])}]}function Lt(e,t,n,i,o){function a(e,t,n){e=e.replace("JSON_CALLBACK",t);var r=o.createElement("script"),a=null;return r.type="text/javascript",r.src=e,r.async=!0,a=function(e){r.removeEventListener("load",a),r.removeEventListener("error",a),o.body.removeChild(r),r=null;var s=-1,u="unknown";e&&("load"!==e.type||i.wasCalled(t)||(e={type:"error"}),u=e.type,s="error"===e.type?404:200),n&&n(s,u)},r.addEventListener("load",a),r.addEventListener("error",a),o.body.appendChild(r),a}return function(o,s,u,l,c,f,d,p,h,g){function $(){w&&w(),x&&x.abort()}function y(e,t,r,i,o){m(E)&&n.cancel(E),w=x=null,e(t,r,i,o)}if(s=s||e.url(),"jsonp"===Wr(o))var b=i.createCallback(s),w=a(s,b,function(e,t){var n=200===e&&i.getResponse(b);y(l,e,n,"",t),i.removeCallback(b)});else{var x=t(o,s);x.open(o,s,!0),r(c,function(e,t){m(e)&&x.setRequestHeader(t,e)}),x.onload=function(){var e=x.statusText||"",t="response"in x?x.response:x.responseText,n=1223===x.status?204:x.status;0===n&&(n=t?200:"file"===Un(s).protocol?404:0),y(l,n,t,x.getAllResponseHeaders(),e)};var _=function(){y(l,-1,null,null,"")};if(x.onerror=_,x.onabort=_,x.ontimeout=_,r(h,function(e,t){x.addEventListener(t,e)}),r(g,function(e,t){x.upload.addEventListener(t,e)}),d&&(x.withCredentials=!0),p)try{x.responseType=p}catch(k){if("json"!==p)throw k}x.send(v(u)?null:u)}if(f>0)var E=n($,f);else T(f)&&f.then($)}}function Ht(){var e="{{",t="}}";this.startSymbol=function(t){return t?(e=t,this):e},this.endSymbol=function(e){return e?(t=e,this):t},this.$get=["$parse","$exceptionHandler","$sce",function(n,r,i){function o(e){return"\\\\\\"+e}function a(n){return n.replace(d,e).replace(p,t)}function s(e,t,n,r){var i=e.$watch(function(e){return i(),r(e)},t,n);return i}function u(o,u,d,p){function h(e){try{return e=j(e),p&&!m(e)?e:ve(e)}catch(t){r(yo.interr(o,t))}}if(!o.length||o.indexOf(e)===-1){var $;if(!u){var y=a(o);$=g(y),$.exp=o,$.expressions=[],$.$$watchDelegate=s}return $}p=!!p;for(var b,w,x,_=0,E=[],S=[],C=o.length,A=[],O=[];_<C;){if((b=o.indexOf(e,_))===-1||(w=o.indexOf(t,b+c))===-1){_!==C&&A.push(a(o.substring(_)));break}_!==b&&A.push(a(o.substring(_,b))),x=o.substring(b+c,w),E.push(x),S.push(n(x,h)),_=w+f,O.push(A.length),A.push("")}if(d&&A.length>1&&yo.throwNoconcat(o),!u||E.length){var M=function(e){for(var t=0,n=E.length;t<n;t++){if(p&&v(e[t]))return;A[O[t]]=e[t]}return A.join("")},j=function(e){return d?i.getTrusted(d,e):i.valueOf(e)};return l(function(e){var t=0,n=E.length,i=new Array(n);try{for(;t<n;t++)i[t]=S[t](e);return M(i)}catch(a){r(yo.interr(o,a))}},{exp:o,expressions:E,$$watchDelegate:function(e,t){var n;return e.$watchGroup(S,function(r,i){var o=M(r);k(t)&&t.call(this,o,r!==i?n:o,e),n=o})}})}}var c=e.length,f=t.length,d=new RegExp(e.replace(/./g,o),"g"),p=new RegExp(t.replace(/./g,o),"g");return u.startSymbol=function(){return e},u.endSymbol=function(){return t},u}]}function qt(){this.$get=["$rootScope","$window","$q","$$q","$browser",function(e,t,n,r,i){function o(o,s,u,l){function c(){f?o.apply(null,d):o(g)}var f=arguments.length>4,d=f?H(arguments,4):[],p=t.setInterval,h=t.clearInterval,g=0,$=m(l)&&!l,v=($?r:n).defer(),y=v.promise;return u=m(u)?u:0,y.$$intervalId=p(function(){$?i.defer(c):e.$evalAsync(c),v.notify(g++),u>0&&g>=u&&(v.resolve(g),h(y.$$intervalId),delete a[y.$$intervalId]),$||e.$apply()},s),a[y.$$intervalId]=v,y}var a={};return o.cancel=function(e){return!!(e&&e.$$intervalId in a)&&(a[e.$$intervalId].promise["catch"](p),a[e.$$intervalId].reject("canceled"),t.clearInterval(e.$$intervalId),delete a[e.$$intervalId],!0)},o}]}function Bt(e){for(var t=e.split("/"),n=t.length;n--;)t[n]=te(t[n]);return t.join("/")}function Wt(e,t){var n=Un(e);t.$$protocol=n.protocol,t.$$host=n.hostname,t.$$port=f(n.port)||xo[n.protocol]||null}function Gt(e,t){if(ko.test(e))throw _o("badpath",'Invalid url "{0}".',e);var n="/"!==e.charAt(0);n&&(e="/"+e);var r=Un(e);t.$$path=decodeURIComponent(n&&"/"===r.pathname.charAt(0)?r.pathname.substring(1):r.pathname),t.$$search=Q(r.search),t.$$hash=decodeURIComponent(r.hash),t.$$path&&"/"!==t.$$path.charAt(0)&&(t.$$path="/"+t.$$path)}function Xt(e,t){return e.slice(0,t.length)===t}function Kt(e,t){if(Xt(t,e))return t.substr(e.length)}function Yt(e){var t=e.indexOf("#");return t===-1?e:e.substr(0,t)}function Jt(e){return e.replace(/(#.+)|#$/,"$1")}function Zt(e){return e.substr(0,Yt(e).lastIndexOf("/")+1)}function Qt(e){return e.substring(0,e.indexOf("/",e.indexOf("//")+2))}function en(e,t,n){this.$$html5=!0,n=n||"",Wt(e,this),this.$$parse=function(e){var n=Kt(t,e);if(!w(n))throw _o("ipthprfx",'Invalid url "{0}", missing path prefix "{1}".',e,t);Gt(n,this),this.$$path||(this.$$path="/"),this.$$compose()},this.$$compose=function(){var e=ee(this.$$search),n=this.$$hash?"#"+te(this.$$hash):"";this.$$url=Bt(this.$$path)+(e?"?"+e:"")+n,this.$$absUrl=t+this.$$url.substr(1)},this.$$parseLinkUrl=function(r,i){if(i&&"#"===i[0])return this.hash(i.slice(1)),!0;var o,a,s;return m(o=Kt(e,r))?(a=o,s=n&&m(o=Kt(n,o))?t+(Kt("/",o)||o):e+a):m(o=Kt(t,r))?s=t+o:t===r+"/"&&(s=t),s&&this.$$parse(s),!!s}}function tn(e,t,n){Wt(e,this),this.$$parse=function(r){function i(e,t,n){var r,i=/^\/[A-Z]:(\/.*)/;return Xt(t,n)&&(t=t.replace(n,"")),i.exec(t)?e:(r=i.exec(e),r?r[1]:e)}var o,a=Kt(e,r)||Kt(t,r);v(a)||"#"!==a.charAt(0)?this.$$html5?o=a:(o="",v(a)&&(e=r,this.replace())):(o=Kt(n,a),v(o)&&(o=a)),Gt(o,this),this.$$path=i(this.$$path,o,e),this.$$compose()},this.$$compose=function(){var t=ee(this.$$search),r=this.$$hash?"#"+te(this.$$hash):"";this.$$url=Bt(this.$$path)+(t?"?"+t:"")+r,this.$$absUrl=e+(this.$$url?n+this.$$url:"")},this.$$parseLinkUrl=function(t,n){return Yt(e)===Yt(t)&&(this.$$parse(t),!0)}}function nn(e,t,n){this.$$html5=!0,tn.apply(this,arguments),this.$$parseLinkUrl=function(r,i){if(i&&"#"===i[0])return this.hash(i.slice(1)),!0;var o,a;return e===Yt(r)?o=r:(a=Kt(t,r))?o=e+n+a:t===r+"/"&&(o=t),o&&this.$$parse(o),!!o},this.$$compose=function(){var t=ee(this.$$search),r=this.$$hash?"#"+te(this.$$hash):"";this.$$url=Bt(this.$$path)+(t?"?"+t:"")+r,this.$$absUrl=e+n+this.$$url}}function rn(e){return function(){return this[e]}}function on(e,t){return function(n){return v(n)?this[e]:(this[e]=t(n),this.$$compose(),this)}}function an(){var e="!",t={enabled:!1,requireBase:!0,rewriteLinks:!0};this.hashPrefix=function(t){return m(t)?(e=t,this):e},this.html5Mode=function(e){return j(e)?(t.enabled=e,this):y(e)?(j(e.enabled)&&(t.enabled=e.enabled),j(e.requireBase)&&(t.requireBase=e.requireBase),(j(e.rewriteLinks)||w(e.rewriteLinks))&&(t.rewriteLinks=e.rewriteLinks),this):t},this.$get=["$rootScope","$browser","$sniffer","$rootElement","$window",function(n,r,i,o,a){function s(e,t,n){var i=l.url(),o=l.$$state;try{r.url(e,t,n),l.$$state=r.state()}catch(a){throw l.url(i),l.$$state=o,a}}function u(e,t){n.$broadcast("$locationChangeSuccess",l.absUrl(),e,l.$$state,t)}var l,c,f,d=r.baseHref(),p=r.url();if(t.enabled){if(!d&&t.requireBase)throw _o("nobase","$location in HTML5 mode requires a <base> tag to be present!");f=Qt(p)+(d||"/"),c=i.history?en:nn}else f=Yt(p),c=tn;var h=Zt(f);l=new c(f,h,"#"+e),l.$$parseLinkUrl(p,p),l.$$state=r.state();var g=/^\s*(javascript|mailto):/i;o.on("click",function(e){var i=t.rewriteLinks;if(i&&!e.ctrlKey&&!e.metaKey&&!e.shiftKey&&2!==e.which&&2!==e.button){for(var s=Jr(e.target);"a"!==U(s[0]);)if(s[0]===o[0]||!(s=s.parent())[0])return;if(!w(i)||!v(s.attr(i))){var u=s.prop("href"),c=s.attr("href")||s.attr("xlink:href");y(u)&&"[object SVGAnimatedString]"===u.toString()&&(u=Un(u.animVal).href),g.test(u)||!u||s.attr("target")||e.isDefaultPrevented()||l.$$parseLinkUrl(u,c)&&(e.preventDefault(),l.absUrl()!==r.url()&&(n.$apply(),a.angular["ff-684208-preventDefault"]=!0))}}}),Jt(l.absUrl())!==Jt(p)&&r.url(l.absUrl(),!0);var $=!0;return r.onUrlChange(function(e,t){return Xt(e,h)?(n.$evalAsync(function(){var r,i=l.absUrl(),o=l.$$state;e=Jt(e),l.$$parse(e),l.$$state=t,r=n.$broadcast("$locationChangeStart",e,i,t,o).defaultPrevented,l.absUrl()===e&&(r?(l.$$parse(i),l.$$state=o,s(i,!1,o)):($=!1,u(i,o)))}),void(n.$$phase||n.$digest())):void(a.location.href=e)}),n.$watch(function(){var e=Jt(r.url()),t=Jt(l.absUrl()),o=r.state(),a=l.$$replace,c=e!==t||l.$$html5&&i.history&&o!==l.$$state;($||c)&&($=!1,n.$evalAsync(function(){var t=l.absUrl(),r=n.$broadcast("$locationChangeStart",t,e,l.$$state,o).defaultPrevented;l.absUrl()===t&&(r?(l.$$parse(e),l.$$state=o):(c&&s(t,a,o===l.$$state?null:l.$$state),u(e,o)))})),l.$$replace=!1}),l}]}function sn(){var e=!0,t=this;this.debugEnabled=function(t){return m(t)?(e=t,this):e},this.$get=["$window",function(n){function i(e){return e instanceof Error&&(e.stack?e=e.message&&e.stack.indexOf(e.message)===-1?"Error: "+e.message+"\n"+e.stack:e.stack:e.sourceURL&&(e=e.message+"\n"+e.sourceURL+":"+e.line)),e}function o(e){var t=n.console||{},o=t[e]||t.log||p,a=!1;try{a=!!o.apply}catch(s){}return a?function(){var e=[];return r(arguments,function(t){e.push(i(t))}),o.apply(t,e)}:function(e,t){o(e,null==t?"":t)}}return{log:o("log"),info:o("info"),warn:o("warn"),error:o("error"),debug:function(){var n=o("debug");return function(){e&&n.apply(t,arguments)}}()}}]}function un(e){return e+""}function ln(e,t){return"undefined"!=typeof e?e:t}function cn(e,t){return"undefined"==typeof e?t:"undefined"==typeof t?e:e+t}function fn(e,t){var n=e(t);return!n.$stateful}function dn(e,t){var n,i,o;switch(e.type){case jo.Program:n=!0,r(e.body,function(e){dn(e.expression,t),n=n&&e.expression.constant}),e.constant=n;break;case jo.Literal:e.constant=!0,e.toWatch=[];break;case jo.UnaryExpression:dn(e.argument,t),e.constant=e.argument.constant,e.toWatch=e.argument.toWatch;break;case jo.BinaryExpression:dn(e.left,t),dn(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=e.left.toWatch.concat(e.right.toWatch);break;case jo.LogicalExpression:dn(e.left,t),dn(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=e.constant?[]:[e];break;case jo.ConditionalExpression:dn(e.test,t),dn(e.alternate,t),dn(e.consequent,t),e.constant=e.test.constant&&e.alternate.constant&&e.consequent.constant,e.toWatch=e.constant?[]:[e];break;case jo.Identifier:e.constant=!1,e.toWatch=[e];break;case jo.MemberExpression:dn(e.object,t),e.computed&&dn(e.property,t),e.constant=e.object.constant&&(!e.computed||e.property.constant),e.toWatch=[e];break;case jo.CallExpression:o=!!e.filter&&fn(t,e.callee.name),n=o,i=[],r(e.arguments,function(e){dn(e,t),n=n&&e.constant,e.constant||i.push.apply(i,e.toWatch)}),e.constant=n,e.toWatch=o?i:[e];break;case jo.AssignmentExpression:dn(e.left,t),dn(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=[e];break;case jo.ArrayExpression:n=!0,i=[],r(e.elements,function(e){dn(e,t),n=n&&e.constant,e.constant||i.push.apply(i,e.toWatch)}),e.constant=n,e.toWatch=i;break;case jo.ObjectExpression:n=!0,i=[],r(e.properties,function(e){dn(e.value,t),n=n&&e.value.constant&&!e.computed,e.value.constant||i.push.apply(i,e.value.toWatch)}),e.constant=n,e.toWatch=i;break;case jo.ThisExpression:e.constant=!1,e.toWatch=[];break;case jo.LocalsExpression:e.constant=!1,e.toWatch=[]}}function pn(e){if(1===e.length){var t=e[0].expression,n=t.toWatch;return 1!==n.length?n:n[0]!==t?n:void 0}}function hn(e){return e.type===jo.Identifier||e.type===jo.MemberExpression}function gn(e){if(1===e.body.length&&hn(e.body[0].expression))return{type:jo.AssignmentExpression,left:e.body[0].expression,right:{type:jo.NGValueParameter},operator:"="}}function $n(e){return 0===e.body.length||1===e.body.length&&(e.body[0].expression.type===jo.Literal||e.body[0].expression.type===jo.ArrayExpression||e.body[0].expression.type===jo.ObjectExpression)}function vn(e){return e.constant}function mn(e,t){this.astBuilder=e,this.$filter=t}function yn(e,t){this.astBuilder=e,this.$filter=t}function bn(e){return k(e.valueOf)?e.valueOf():Co.call(e)}function wn(){var e,t,n=$e(),i={"true":!0,"false":!1,"null":null,undefined:void 0};this.addLiteral=function(e,t){i[e]=t},this.setIdentifierFns=function(n,r){return e=n,t=r,this},this.$get=["$filter",function(o){function a(e,t){var r,i,a;switch(typeof e){case"string":if(e=e.trim(),a=e,r=n[a],!r){":"===e.charAt(0)&&":"===e.charAt(1)&&(i=!0,e=e.substring(2));var s=new Mo(g),h=new To(s,o,g);r=h.parse(e),r.constant?r.$$watchDelegate=f:i?r.$$watchDelegate=r.literal?c:l:r.inputs&&(r.$$watchDelegate=u),n[a]=r}return d(r,t);case"function":return d(e,t);default:return d(p,t)}}function s(e,t){return null==e||null==t?e===t:("object"!=typeof e||(e=bn(e),"object"!=typeof e))&&(e===t||e!==e&&t!==t)}function u(e,t,n,r,i){var o,a=r.inputs;if(1===a.length){var u=s;return a=a[0],e.$watch(function(e){var t=a(e);return s(t,u)||(o=r(e,void 0,void 0,[t]),u=t&&bn(t)),o},t,n,i)}for(var l=[],c=[],f=0,d=a.length;f<d;f++)l[f]=s,c[f]=null;return e.$watch(function(e){for(var t=!1,n=0,i=a.length;n<i;n++){var u=a[n](e);(t||(t=!s(u,l[n])))&&(c[n]=u,l[n]=u&&bn(u))}return t&&(o=r(e,void 0,void 0,c)),o},t,n,i)}function l(e,t,n,r,i){function o(e){return r(e)}function a(e,n,r){l=e,k(t)&&t(e,n,r),m(e)&&r.$$postDigest(function(){m(l)&&s()})}var s,l;return s=r.inputs?u(e,a,n,r,i):e.$watch(o,a,n)}function c(e,t,n,i){function o(e){var t=!0;return r(e,function(e){m(e)||(t=!1)}),t}var a,s;return a=e.$watch(function(e){return i(e)},function(e,n,r){s=e,k(t)&&t(e,n,r),o(e)&&r.$$postDigest(function(){o(s)&&a()})},n)}function f(e,t,n,r){var i=e.$watch(function(e){return i(),r(e)},t,n);return i}function d(e,t){if(!t)return e;var n=e.$$watchDelegate,r=!1,i=n!==c&&n!==l,o=i?function(n,i,o,a){var s=r&&a?a[0]:e(n,i,o,a);return t(s,n,i)}:function(n,r,i,o){var a=e(n,r,i,o),s=t(a,n,r);return m(a)?s:a};return r=!e.inputs,e.$$watchDelegate&&e.$$watchDelegate!==u?(o.$$watchDelegate=e.$$watchDelegate,o.inputs=e.inputs):t.$stateful||(o.$$watchDelegate=u,o.inputs=e.inputs?e.inputs:[e]),o}var h=pi().noUnsafeEval,g={csp:h,literals:R(i),isIdentifierStart:k(e)&&e,isIdentifierContinue:k(t)&&t};return a}]}function xn(){var e=!0;this.$get=["$rootScope","$exceptionHandler",function(t,n){return kn(function(e){t.$evalAsync(e)},n,e)}],this.errorOnUnhandledRejections=function(t){return m(t)?(e=t,this):e}}function _n(){var e=!0;this.$get=["$browser","$exceptionHandler",function(t,n){return kn(function(e){t.defer(e)},n,e)}],this.errorOnUnhandledRejections=function(t){return m(t)?(e=t,this):e}}function kn(e,n,i){function o(){return new a}function a(){var e=this.promise=new s;this.resolve=function(t){d(e,t)},this.reject=function(t){h(e,t)},this.notify=function(t){$(e,t)}}function s(){this.$$state={status:0}}function u(t){var n,r,o;o=t.pending,t.processScheduled=!1,t.pending=void 0;try{for(var a=0,s=o.length;a<s;++a){t.pur=!0,r=o[a][0],n=o[a][t.status];try{k(n)?d(r,n(t.value)):1===t.status?d(r,t.value):h(r,t.value)}catch(u){h(r,u)}}}finally{--C,i&&0===C&&e(c)}}function c(){for(;!C&&A.length;){var e=A.shift();if(!e.pur){e.pur=!0;var t="Possibly unhandled rejection: "+we(e.value);e.value instanceof Error?n(e.value,t):n(t)}}}function f(t){!i||t.pending||2!==t.status||t.pur||(0===C&&0===A.length&&e(c),A.push(t)),!t.processScheduled&&t.pending&&(t.processScheduled=!0,++C,e(function(){u(t)}))}function d(e,t){e.$$state.status||(t===e?g(e,S("qcycle","Expected promise to be resolved with value other than itself '{0}'",t)):p(e,t))}function p(e,t){function n(t){a||(a=!0,p(e,t))}function r(t){a||(a=!0,g(e,t))}function i(t){$(e,t)}var o,a=!1;try{(y(t)||k(t))&&(o=t.then),k(o)?(e.$$state.status=-1,o.call(t,n,r,i)):(e.$$state.value=t,e.$$state.status=1,f(e.$$state))}catch(s){r(s)}}function h(e,t){e.$$state.status||g(e,t)}function g(e,t){e.$$state.value=t,e.$$state.status=2,f(e.$$state)}function $(t,r){var i=t.$$state.pending;t.$$state.status<=0&&i&&i.length&&e(function(){for(var e,t,o=0,a=i.length;o<a;o++){t=i[o][0],e=i[o][3];try{$(t,k(e)?e(r):r)}catch(s){n(s)}}})}function m(e){var t=new s;return h(t,e),t}function b(e,t,n){var r=null;try{k(n)&&(r=n())}catch(i){return m(i)}return T(r)?r.then(function(){return t(e)},m):t(e)}function w(e,t,n,r){var i=new s;return d(i,e),i.then(t,n,r)}function x(e){var t=new s,n=0,i=li(e)?[]:{};return r(e,function(e,r){n++,w(e).then(function(e){i[r]=e,--n||d(t,i)},function(e){h(t,e)})}),0===n&&d(t,i),t}function _(e){var t=o();return r(e,function(e){w(e).then(t.resolve,t.reject)}),t.promise}function E(e){function t(e){d(r,e)}function n(e){h(r,e)}if(!k(e))throw S("norslvr","Expected resolverFn, got '{0}'",e);var r=new s;return e(t,n),r}var S=t("$q",TypeError),C=0,A=[];l(s.prototype,{then:function(e,t,n){if(v(e)&&v(t)&&v(n))return this;var r=new s;return this.$$state.pending=this.$$state.pending||[],this.$$state.pending.push([r,e,t,n]),this.$$state.status>0&&f(this.$$state),r},"catch":function(e){return this.then(null,e)},"finally":function(e,t){return this.then(function(t){return b(t,O,e)},function(t){return b(t,m,e)},t)}});var O=w;return E.prototype=s.prototype,E.defer=o,E.reject=m,E.when=w,E.resolve=O,E.all=x,E.race=_,
|
5 |
+
E}function En(){this.$get=["$window","$timeout",function(e,t){var n=e.requestAnimationFrame||e.webkitRequestAnimationFrame,r=e.cancelAnimationFrame||e.webkitCancelAnimationFrame||e.webkitCancelRequestAnimationFrame,i=!!n,o=i?function(e){var t=n(e);return function(){r(t)}}:function(e){var n=t(e,16.66,!1);return function(){t.cancel(n)}};return o.supported=i,o}]}function Sn(){function e(e){function t(){this.$$watchers=this.$$nextSibling=this.$$childHead=this.$$childTail=null,this.$$listeners={},this.$$listenerCount={},this.$$watchersCount=0,this.$id=a(),this.$$ChildScope=null}return t.prototype=e,t}var i=10,o=t("$rootScope"),s=null,u=null;this.digestTtl=function(e){return arguments.length&&(i=e),i},this.$get=["$exceptionHandler","$parse","$browser",function(t,l,c){function f(e){e.currentScope.$$destroyed=!0}function d(e){9===Yr&&(e.$$childHead&&d(e.$$childHead),e.$$nextSibling&&d(e.$$nextSibling)),e.$parent=e.$$nextSibling=e.$$prevSibling=e.$$childHead=e.$$childTail=e.$root=e.$$watchers=null}function h(){this.$id=a(),this.$$phase=this.$parent=this.$$watchers=this.$$nextSibling=this.$$prevSibling=this.$$childHead=this.$$childTail=null,this.$root=this,this.$$destroyed=!1,this.$$listeners={},this.$$listenerCount={},this.$$watchersCount=0,this.$$isolateBindings=null}function g(e){if(E.$$phase)throw o("inprog","{0} already in progress",E.$$phase);E.$$phase=e}function $(){E.$$phase=null}function m(e,t){do e.$$watchersCount+=t;while(e=e.$parent)}function b(e,t,n){do e.$$listenerCount[n]-=t,0===e.$$listenerCount[n]&&delete e.$$listenerCount[n];while(e=e.$parent)}function w(){}function x(){for(;A.length;)try{A.shift()()}catch(e){t(e)}u=null}function _(){null===u&&(u=c.defer(function(){E.$apply(x)}))}h.prototype={constructor:h,$new:function(t,n){var r;return n=n||this,t?(r=new h,r.$root=this.$root):(this.$$ChildScope||(this.$$ChildScope=e(this)),r=new this.$$ChildScope),r.$parent=n,r.$$prevSibling=n.$$childTail,n.$$childHead?(n.$$childTail.$$nextSibling=r,n.$$childTail=r):n.$$childHead=n.$$childTail=r,(t||n!==this)&&r.$on("$destroy",f),r},$watch:function(e,t,n,r){var i=l(e);if(i.$$watchDelegate)return i.$$watchDelegate(this,t,n,i,e);var o=this,a=o.$$watchers,u={fn:t,last:w,get:i,exp:r||e,eq:!!n};return s=null,k(t)||(u.fn=p),a||(a=o.$$watchers=[],a.$$digestWatchIndex=-1),a.unshift(u),a.$$digestWatchIndex++,m(this,1),function(){var e=N(a,u);e>=0&&(m(o,-1),e<a.$$digestWatchIndex&&a.$$digestWatchIndex--),s=null}},$watchGroup:function(e,t){function n(){u=!1,l?(l=!1,t(o,o,s)):t(o,i,s)}var i=new Array(e.length),o=new Array(e.length),a=[],s=this,u=!1,l=!0;if(!e.length){var c=!0;return s.$evalAsync(function(){c&&t(o,o,s)}),function(){c=!1}}return 1===e.length?this.$watch(e[0],function(e,n,r){o[0]=e,i[0]=n,t(o,e===n?o:i,r)}):(r(e,function(e,t){var r=s.$watch(e,function(e,r){o[t]=e,i[t]=r,u||(u=!0,s.$evalAsync(n))});a.push(r)}),function(){for(;a.length;)a.shift()()})},$watchCollection:function(e,t){function r(e){o=e;var t,r,i,s,u;if(!v(o)){if(y(o))if(n(o)){a!==p&&(a=p,$=a.length=0,f++),t=o.length,$!==t&&(f++,a.length=$=t);for(var l=0;l<t;l++)u=a[l],s=o[l],i=u!==u&&s!==s,i||u===s||(f++,a[l]=s)}else{a!==h&&(a=h={},$=0,f++),t=0;for(r in o)Br.call(o,r)&&(t++,s=o[r],u=a[r],r in a?(i=u!==u&&s!==s,i||u===s||(f++,a[r]=s)):($++,a[r]=s,f++));if($>t){f++;for(r in a)Br.call(o,r)||($--,delete a[r])}}else a!==o&&(a=o,f++);return f}}function i(){if(g?(g=!1,t(o,o,u)):t(o,s,u),c)if(y(o))if(n(o)){s=new Array(o.length);for(var e=0;e<o.length;e++)s[e]=o[e]}else{s={};for(var r in o)Br.call(o,r)&&(s[r]=o[r])}else s=o}r.$stateful=!0;var o,a,s,u=this,c=t.length>1,f=0,d=l(e,r),p=[],h={},g=!0,$=0;return this.$watch(d,i)},$digest:function(){var e,n,r,a,l,f,d,p,h,v,m,y=i,b=this,_=[];g("$digest"),c.$$checkUrlChange(),this===E&&null!==u&&(c.defer.cancel(u),x()),s=null;do{d=!1,h=b;for(var A=0;A<S.length;A++){try{m=S[A],m.scope.$eval(m.expression,m.locals)}catch(M){t(M)}s=null}S.length=0;e:do{if(f=h.$$watchers)for(f.$$digestWatchIndex=f.length;f.$$digestWatchIndex--;)try{if(e=f[f.$$digestWatchIndex])if(l=e.get,(n=l(h))===(r=e.last)||(e.eq?z(n,r):ui(n)&&ui(r))){if(e===s){d=!1;break e}}else d=!0,s=e,e.last=e.eq?R(n,null):n,a=e.fn,a(n,r===w?n:r,h),y<5&&(v=4-y,_[v]||(_[v]=[]),_[v].push({msg:k(e.exp)?"fn: "+(e.exp.name||e.exp.toString()):e.exp,newVal:n,oldVal:r}))}catch(M){t(M)}if(!(p=h.$$watchersCount&&h.$$childHead||h!==b&&h.$$nextSibling))for(;h!==b&&!(p=h.$$nextSibling);)h=h.$parent}while(h=p);if((d||S.length)&&!y--)throw $(),o("infdig","{0} $digest() iterations reached. Aborting!\nWatchers fired in the last 5 iterations: {1}",i,_)}while(d||S.length);for($();O<C.length;)try{C[O++]()}catch(M){t(M)}C.length=O=0},$destroy:function(){if(!this.$$destroyed){var e=this.$parent;this.$broadcast("$destroy"),this.$$destroyed=!0,this===E&&c.$$applicationDestroyed(),m(this,-this.$$watchersCount);for(var t in this.$$listenerCount)b(this,this.$$listenerCount[t],t);e&&e.$$childHead===this&&(e.$$childHead=this.$$nextSibling),e&&e.$$childTail===this&&(e.$$childTail=this.$$prevSibling),this.$$prevSibling&&(this.$$prevSibling.$$nextSibling=this.$$nextSibling),this.$$nextSibling&&(this.$$nextSibling.$$prevSibling=this.$$prevSibling),this.$destroy=this.$digest=this.$apply=this.$evalAsync=this.$applyAsync=p,this.$on=this.$watch=this.$watchGroup=function(){return p},this.$$listeners={},this.$$nextSibling=null,d(this)}},$eval:function(e,t){return l(e)(this,t)},$evalAsync:function(e,t){E.$$phase||S.length||c.defer(function(){S.length&&E.$digest()}),S.push({scope:this,expression:l(e),locals:t})},$$postDigest:function(e){C.push(e)},$apply:function(e){try{g("$apply");try{return this.$eval(e)}finally{$()}}catch(n){t(n)}finally{try{E.$digest()}catch(n){throw t(n),n}}},$applyAsync:function(e){function t(){n.$eval(e)}var n=this;e&&A.push(t),e=l(e),_()},$on:function(e,t){var n=this.$$listeners[e];n||(this.$$listeners[e]=n=[]),n.push(t);var r=this;do r.$$listenerCount[e]||(r.$$listenerCount[e]=0),r.$$listenerCount[e]++;while(r=r.$parent);var i=this;return function(){var r=n.indexOf(t);r!==-1&&(n[r]=null,b(i,1,e))}},$emit:function(e,n){var r,i,o,a=[],s=this,u=!1,l={name:e,targetScope:s,stopPropagation:function(){u=!0},preventDefault:function(){l.defaultPrevented=!0},defaultPrevented:!1},c=L([l],arguments,1);do{for(r=s.$$listeners[e]||a,l.currentScope=s,i=0,o=r.length;i<o;i++)if(r[i])try{r[i].apply(null,c)}catch(f){t(f)}else r.splice(i,1),i--,o--;if(u)return l.currentScope=null,l;s=s.$parent}while(s);return l.currentScope=null,l},$broadcast:function(e,n){var r=this,i=r,o=r,a={name:e,targetScope:r,preventDefault:function(){a.defaultPrevented=!0},defaultPrevented:!1};if(!r.$$listenerCount[e])return a;for(var s,u,l,c=L([a],arguments,1);i=o;){for(a.currentScope=i,s=i.$$listeners[e]||[],u=0,l=s.length;u<l;u++)if(s[u])try{s[u].apply(null,c)}catch(f){t(f)}else s.splice(u,1),u--,l--;if(!(o=i.$$listenerCount[e]&&i.$$childHead||i!==r&&i.$$nextSibling))for(;i!==r&&!(o=i.$$nextSibling);)i=i.$parent}return a.currentScope=null,a}};var E=new h,S=E.$$asyncQueue=[],C=E.$$postDigestQueue=[],A=E.$$applyAsyncQueue=[],O=0;return E}]}function Cn(){var e=/^\s*(https?|ftp|mailto|tel|file):/,t=/^\s*((https?|ftp|file|blob):|data:image\/)/;this.aHrefSanitizationWhitelist=function(t){return m(t)?(e=t,this):e},this.imgSrcSanitizationWhitelist=function(e){return m(e)?(t=e,this):t},this.$get=function(){return function(n,r){var i,o=r?t:e;return i=Un(n).href,""===i||i.match(o)?n:"unsafe:"+i}}}function An(e){return e.replace(Vo,Ee)}function On(e){if("self"===e)return e;if(w(e)){if(e.indexOf("***")>-1)throw Po("iwcard","Illegal sequence *** in string matcher. String: {0}",e);return e=di(e).replace(/\\\*\\\*/g,".*").replace(/\\\*/g,"[^:/.?&;]*"),new RegExp("^"+e+"$")}if(E(e))return new RegExp("^"+e.source+"$");throw Po("imatcher",'Matchers may only be "self", string patterns or RegExp objects')}function Mn(e){var t=[];return m(e)&&r(e,function(e){t.push(On(e))}),t}function jn(){this.SCE_CONTEXTS=Do;var e=["self"],t=[];this.resourceUrlWhitelist=function(t){return arguments.length&&(e=Mn(t)),e},this.resourceUrlBlacklist=function(e){return arguments.length&&(t=Mn(e)),t},this.$get=["$injector",function(n){function r(e,t){return"self"===e?Fn(t):!!e.exec(t.href)}function i(n){var i,o,a=Un(n.toString()),s=!1;for(i=0,o=e.length;i<o;i++)if(r(e[i],a)){s=!0;break}if(s)for(i=0,o=t.length;i<o;i++)if(r(t[i],a)){s=!1;break}return s}function o(e){var t=function(e){this.$$unwrapTrustedValue=function(){return e}};return e&&(t.prototype=new e),t.prototype.valueOf=function(){return this.$$unwrapTrustedValue()},t.prototype.toString=function(){return this.$$unwrapTrustedValue().toString()},t}function a(e,t){var n=f.hasOwnProperty(e)?f[e]:null;if(!n)throw Po("icontext","Attempted to trust a value in invalid context. Context: {0}; Value: {1}",e,t);if(null===t||v(t)||""===t)return t;if("string"!=typeof t)throw Po("itype","Attempted to trust a non-string value in a content requiring a string: Context: {0}",e);return new n(t)}function s(e){return e instanceof c?e.$$unwrapTrustedValue():e}function u(e,t){if(null===t||v(t)||""===t)return t;var n=f.hasOwnProperty(e)?f[e]:null;if(n&&t instanceof n)return t.$$unwrapTrustedValue();if(e===Do.RESOURCE_URL){if(i(t))return t;throw Po("insecurl","Blocked loading resource from url not allowed by $sceDelegate policy. URL: {0}",t.toString())}if(e===Do.HTML)return l(t);throw Po("unsafe","Attempting to use an unsafe value in a safe context.")}var l=function(e){throw Po("unsafe","Attempting to use an unsafe value in a safe context.")};n.has("$sanitize")&&(l=n.get("$sanitize"));var c=o(),f={};return f[Do.HTML]=o(c),f[Do.CSS]=o(c),f[Do.URL]=o(c),f[Do.JS]=o(c),f[Do.RESOURCE_URL]=o(f[Do.URL]),{trustAs:a,getTrusted:u,valueOf:s}}]}function Tn(){var e=!0;this.enabled=function(t){return arguments.length&&(e=!!t),e},this.$get=["$parse","$sceDelegate",function(t,n){if(e&&Yr<8)throw Po("iequirks","Strict Contextual Escaping does not support Internet Explorer version < 11 in quirks mode. You can fix this by adding the text <!doctype html> to the top of your HTML document. See http://docs.angularjs.org/api/ng.$sce for more information.");var i=ye(Do);i.isEnabled=function(){return e},i.trustAs=n.trustAs,i.getTrusted=n.getTrusted,i.valueOf=n.valueOf,e||(i.trustAs=i.getTrusted=function(e,t){return t},i.valueOf=h),i.parseAs=function(e,n){var r=t(n);return r.literal&&r.constant?r:t(n,function(t){return i.getTrusted(e,t)})};var o=i.parseAs,a=i.getTrusted,s=i.trustAs;return r(Do,function(e,t){var n=Wr(t);i[An("parse_as_"+n)]=function(t){return o(e,t)},i[An("get_trusted_"+n)]=function(t){return a(e,t)},i[An("trust_as_"+n)]=function(t){return s(e,t)}}),i}]}function Pn(){this.$get=["$window","$document",function(e,t){var n={},r=e.chrome&&(e.chrome.app&&e.chrome.app.runtime||!e.chrome.app&&e.chrome.runtime&&e.chrome.runtime.id),i=!r&&e.history&&e.history.pushState,o=f((/android (\d+)/.exec(Wr((e.navigator||{}).userAgent))||[])[1]),a=/Boxee/i.test((e.navigator||{}).userAgent),s=t[0]||{},u=s.body&&s.body.style,l=!1,c=!1;return u&&(l=!!("transition"in u||"webkitTransition"in u),c=!!("animation"in u||"webkitAnimation"in u)),{history:!(!i||o<4||a),hasEvent:function(e){if("input"===e&&Yr)return!1;if(v(n[e])){var t=s.createElement("div");n[e]="on"+e in t}return n[e]},csp:pi(),transitions:l,animations:c,android:o}}]}function Dn(){var e;this.httpOptions=function(t){return t?(e=t,this):e},this.$get=["$exceptionHandler","$templateCache","$http","$q","$sce",function(t,n,r,i,o){function a(s,u){function c(e){return u||(e=Io("tpload","Failed to load template: {0} (HTTP status: {1} {2})",s,e.status,e.statusText),t(e)),i.reject(e)}a.totalPendingRequests++,w(s)&&!v(n.get(s))||(s=o.getTrustedResourceUrl(s));var f=r.defaults&&r.defaults.transformResponse;return li(f)?f=f.filter(function(e){return e!==Pt}):f===Pt&&(f=null),r.get(s,l({cache:n,transformResponse:f},e))["finally"](function(){a.totalPendingRequests--}).then(function(e){return n.put(s,e.data),e.data},c)}return a.totalPendingRequests=0,a}]}function Vn(){this.$get=["$rootScope","$browser","$location",function(e,t,n){var i={};return i.findBindings=function(e,t,n){var i=e.getElementsByClassName("ng-binding"),o=[];return r(i,function(e){var i=ai.element(e).data("$binding");i&&r(i,function(r){if(n){var i=new RegExp("(^|\\s)"+di(t)+"(\\s|\\||$)");i.test(r)&&o.push(e)}else r.indexOf(t)!==-1&&o.push(e)})}),o},i.findModels=function(e,t,n){for(var r=["ng-","data-ng-","ng\\:"],i=0;i<r.length;++i){var o=n?"=":"*=",a="["+r[i]+"model"+o+'"'+t+'"]',s=e.querySelectorAll(a);if(s.length)return s}},i.getLocation=function(){return n.url()},i.setLocation=function(t){t!==n.url()&&(n.url(t),e.$digest())},i.whenStable=function(e){t.notifyWhenNoOutstandingRequests(e)},i}]}function In(){this.$get=["$rootScope","$browser","$q","$$q","$exceptionHandler",function(e,t,n,r,i){function o(o,s,u){k(o)||(u=s,s=o,o=p);var l,c=H(arguments,3),f=m(u)&&!u,d=(f?r:n).defer(),h=d.promise;return l=t.defer(function(){try{d.resolve(o.apply(null,c))}catch(t){d.reject(t),i(t)}finally{delete a[h.$$timeoutId]}f||e.$apply()},s),h.$$timeoutId=l,a[l]=d,h}var a={};return o.cancel=function(e){return!!(e&&e.$$timeoutId in a)&&(a[e.$$timeoutId].promise["catch"](p),a[e.$$timeoutId].reject("canceled"),delete a[e.$$timeoutId],t.defer.cancel(e.$$timeoutId))},o}]}function Un(e){var t=e;return Yr&&(Uo.setAttribute("href",t),t=Uo.href),Uo.setAttribute("href",t),{href:Uo.href,protocol:Uo.protocol?Uo.protocol.replace(/:$/,""):"",host:Uo.host,search:Uo.search?Uo.search.replace(/^\?/,""):"",hash:Uo.hash?Uo.hash.replace(/^#/,""):"",hostname:Uo.hostname,port:Uo.port,pathname:"/"===Uo.pathname.charAt(0)?Uo.pathname:"/"+Uo.pathname}}function Fn(e){var t=w(e)?Un(e):e;return t.protocol===Fo.protocol&&t.host===Fo.host}function Nn(){this.$get=g(e)}function Rn(e){function t(e){try{return e.cookie||""}catch(t){return""}}function n(e){try{return decodeURIComponent(e)}catch(t){return e}}var r=e[0]||{},i={},o="";return function(){var e,a,s,u,l,c=t(r);if(c!==o)for(o=c,e=o.split("; "),i={},s=0;s<e.length;s++)a=e[s],u=a.indexOf("="),u>0&&(l=n(a.substring(0,u)),v(i[l])&&(i[l]=n(a.substring(u+1))));return i}}function zn(){this.$get=Rn}function Ln(e){function t(i,o){if(y(i)){var a={};return r(i,function(e,n){a[n]=t(n,e)}),a}return e.factory(i+n,o)}var n="Filter";this.register=t,this.$get=["$injector",function(e){return function(t){return e.get(t+n)}}],t("currency",Gn),t("date",ur),t("filter",Hn),t("json",lr),t("limitTo",cr),t("lowercase",Bo),t("number",Xn),t("orderBy",dr),t("uppercase",Wo)}function Hn(){return function(e,r,i,o){if(!n(e)){if(null==e)return e;throw t("filter")("notarray","Expected array but received: {0}",e)}o=o||"$";var a,s,u=Wn(r);switch(u){case"function":a=r;break;case"boolean":case"null":case"number":case"string":s=!0;case"object":a=qn(r,i,o,s);break;default:return e}return Array.prototype.filter.call(e,a)}}function qn(e,t,n,r){var i,o=y(e)&&n in e;return t===!0?t=z:k(t)||(t=function(e,t){return!v(e)&&(null===e||null===t?e===t:!(y(t)||y(e)&&!$(e))&&(e=Wr(""+e),t=Wr(""+t),e.indexOf(t)!==-1))}),i=function(i){return o&&!y(i)?Bn(i,e[n],t,n,!1):Bn(i,e,t,n,r)}}function Bn(e,t,n,r,i,o){var a=Wn(e),s=Wn(t);if("string"===s&&"!"===t.charAt(0))return!Bn(e,t.substring(1),n,r,i);if(li(e))return e.some(function(e){return Bn(e,t,n,r,i)});switch(a){case"object":var u;if(i){for(u in e)if("$"!==u.charAt(0)&&Bn(e[u],t,n,r,!0))return!0;return!o&&Bn(e,t,n,r,!1)}if("object"===s){for(u in t){var l=t[u];if(!k(l)&&!v(l)){var c=u===r,f=c?e:e[u];if(!Bn(f,l,n,r,c,c))return!1}}return!0}return n(e,t);case"function":return!1;default:return n(e,t)}}function Wn(e){return null===e?"null":typeof e}function Gn(e){var t=e.NUMBER_FORMATS;return function(e,n,r){return v(n)&&(n=t.CURRENCY_SYM),v(r)&&(r=t.PATTERNS[1].maxFrac),null==e?e:Jn(e,t.PATTERNS[1],t.GROUP_SEP,t.DECIMAL_SEP,r).replace(/\u00A4/g,n)}}function Xn(e){var t=e.NUMBER_FORMATS;return function(e,n){return null==e?e:Jn(e,t.PATTERNS[0],t.GROUP_SEP,t.DECIMAL_SEP,n)}}function Kn(e){var t,n,r,i,o,a=0;for((n=e.indexOf(Ro))>-1&&(e=e.replace(Ro,"")),(r=e.search(/e/i))>0?(n<0&&(n=r),n+=+e.slice(r+1),e=e.substring(0,r)):n<0&&(n=e.length),r=0;e.charAt(r)===zo;r++);if(r===(o=e.length))t=[0],n=1;else{for(o--;e.charAt(o)===zo;)o--;for(n-=r,t=[],i=0;r<=o;r++,i++)t[i]=+e.charAt(r)}return n>No&&(t=t.splice(0,No-1),a=n-1,n=1),{d:t,e:a,i:n}}function Yn(e,t,n,r){var i=e.d,o=i.length-e.i;t=v(t)?Math.min(Math.max(n,o),r):+t;var a=t+e.i,s=i[a];if(a>0){i.splice(Math.max(e.i,a));for(var u=a;u<i.length;u++)i[u]=0}else{o=Math.max(0,o),e.i=1,i.length=Math.max(1,a=t+1),i[0]=0;for(var l=1;l<a;l++)i[l]=0}if(s>=5)if(a-1<0){for(var c=0;c>a;c--)i.unshift(0),e.i++;i.unshift(1),e.i++}else i[a-1]++;for(;o<Math.max(0,t);o++)i.push(0);var f=i.reduceRight(function(e,t,n,r){return t+=e,r[n]=t%10,Math.floor(t/10)},0);f&&(i.unshift(f),e.i++)}function Jn(e,t,n,r,i){if(!w(e)&&!x(e)||isNaN(e))return"";var o,a=!isFinite(e),s=!1,u=Math.abs(e)+"",l="";if(a)l="∞";else{o=Kn(u),Yn(o,i,t.minFrac,t.maxFrac);var c=o.d,f=o.i,d=o.e,p=[];for(s=c.reduce(function(e,t){return e&&!t},!0);f<0;)c.unshift(0),f++;f>0?p=c.splice(f,c.length):(p=c,c=[0]);var h=[];for(c.length>=t.lgSize&&h.unshift(c.splice(-t.lgSize,c.length).join(""));c.length>t.gSize;)h.unshift(c.splice(-t.gSize,c.length).join(""));c.length&&h.unshift(c.join("")),l=h.join(n),p.length&&(l+=r+p.join("")),d&&(l+="e+"+d)}return e<0&&!s?t.negPre+l+t.negSuf:t.posPre+l+t.posSuf}function Zn(e,t,n,r){var i="";for((e<0||r&&e<=0)&&(r?e=-e+1:(e=-e,i="-")),e=""+e;e.length<t;)e=zo+e;return n&&(e=e.substr(e.length-t)),i+e}function Qn(e,t,n,r,i){return n=n||0,function(o){var a=o["get"+e]();return(n>0||a>-n)&&(a+=n),0===a&&n===-12&&(a=12),Zn(a,t,r,i)}}function er(e,t,n){return function(r,i){var o=r["get"+e](),a=(n?"STANDALONE":"")+(t?"SHORT":""),s=Gr(a+e);return i[s][o]}}function tr(e,t,n){var r=-1*n,i=r>=0?"+":"";return i+=Zn(Math[r>0?"floor":"ceil"](r/60),2)+Zn(Math.abs(r%60),2)}function nr(e){var t=new Date(e,0,1).getDay();return new Date(e,0,(t<=4?5:12)-t)}function rr(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate()+(4-e.getDay()))}function ir(e){return function(t){var n=nr(t.getFullYear()),r=rr(t),i=+r-+n,o=1+Math.round(i/6048e5);return Zn(o,e)}}function or(e,t){return e.getHours()<12?t.AMPMS[0]:t.AMPMS[1]}function ar(e,t){return e.getFullYear()<=0?t.ERAS[0]:t.ERAS[1]}function sr(e,t){return e.getFullYear()<=0?t.ERANAMES[0]:t.ERANAMES[1]}function ur(e){function t(e){var t;if(t=e.match(n)){var r=new Date(0),i=0,o=0,a=t[8]?r.setUTCFullYear:r.setFullYear,s=t[8]?r.setUTCHours:r.setHours;t[9]&&(i=f(t[9]+t[10]),o=f(t[9]+t[11])),a.call(r,f(t[1]),f(t[2])-1,f(t[3]));var u=f(t[4]||0)-i,l=f(t[5]||0)-o,c=f(t[6]||0),d=Math.round(1e3*parseFloat("0."+(t[7]||0)));return s.call(r,u,l,c,d),r}return e}var n=/^(\d{4})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/;return function(n,i,o){var a,s,u="",l=[];if(i=i||"mediumDate",i=e.DATETIME_FORMATS[i]||i,w(n)&&(n=qo.test(n)?f(n):t(n)),x(n)&&(n=new Date(n)),!_(n)||!isFinite(n.getTime()))return n;for(;i;)s=Ho.exec(i),s?(l=L(l,s,1),i=l.pop()):(l.push(i),i=null);var c=n.getTimezoneOffset();return o&&(c=X(o,c),n=Y(n,o,!0)),r(l,function(t){a=Lo[t],u+=a?a(n,e.DATETIME_FORMATS,c):"''"===t?"'":t.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),u}}function lr(){return function(e,t){return v(t)&&(t=2),W(e,t)}}function cr(){return function(e,t,r){return t=Math.abs(Number(t))===1/0?Number(t):f(t),ui(t)?e:(x(e)&&(e=e.toString()),n(e)?(r=!r||isNaN(r)?0:f(r),r=r<0?Math.max(0,e.length+r):r,t>=0?fr(e,r,r+t):0===r?fr(e,t,e.length):fr(e,Math.max(0,r+t),r)):e)}}function fr(e,t,n){return w(e)?e.slice(t,n):ei.call(e,t,n)}function dr(e){function r(t){return t.map(function(t){var n=1,r=h;if(k(t))r=t;else if(w(t)&&("+"!==t.charAt(0)&&"-"!==t.charAt(0)||(n="-"===t.charAt(0)?-1:1,t=t.substring(1)),""!==t&&(r=e(t),r.constant))){var i=r();r=function(e){return e[i]}}return{get:r,descending:n}})}function i(e){switch(typeof e){case"number":case"boolean":case"string":return!0;default:return!1}}function o(e){return k(e.valueOf)&&(e=e.valueOf(),i(e))?e:$(e)&&(e=e.toString(),i(e))?e:e}function a(e,t){var n=typeof e;return null===e?(n="string",e="null"):"object"===n&&(e=o(e)),{value:e,type:n,index:t}}function s(e,t){var n=0,r=e.type,i=t.type;if(r===i){var o=e.value,a=t.value;"string"===r?(o=o.toLowerCase(),a=a.toLowerCase()):"object"===r&&(y(o)&&(o=e.index),y(a)&&(a=t.index)),o!==a&&(n=o<a?-1:1)}else n=r<i?-1:1;return n}return function(e,i,o,u){function l(e,t){return{value:e,tieBreaker:{value:t,type:"number",index:t},predicateValues:f.map(function(n){return a(n.get(e),t)})}}function c(e,t){for(var n=0,r=f.length;n<r;n++){var i=p(e.predicateValues[n],t.predicateValues[n]);if(i)return i*f[n].descending*d}return p(e.tieBreaker,t.tieBreaker)*d}if(null==e)return e;if(!n(e))throw t("orderBy")("notarray","Expected array but received: {0}",e);li(i)||(i=[i]),0===i.length&&(i=["+"]);var f=r(i),d=o?-1:1,p=k(u)?u:s,h=Array.prototype.map.call(e,l);return h.sort(c),e=h.map(function(e){return e.value})}}function pr(e){return k(e)&&(e={link:e}),e.restrict=e.restrict||"AC",g(e)}function hr(e,t){e.$name=t}function gr(e,t,n,r,i){this.$$controls=[],this.$error={},this.$$success={},this.$pending=void 0,this.$name=i(t.name||t.ngForm||"")(n),this.$dirty=!1,this.$pristine=!0,this.$valid=!0,this.$invalid=!1,this.$submitted=!1,this.$$parentForm=Ko,this.$$element=e,this.$$animate=r,$r(this)}function $r(e){e.$$classCache={},e.$$classCache[Pa]=!(e.$$classCache[Ta]=e.$$element.hasClass(Ta))}function vr(e){function t(e,t,n,r){e[t]||(e[t]={}),a(e[t],n,r)}function n(e,t,n,r){e[t]&&s(e[t],n,r),mr(e[t])&&(e[t]=void 0)}function r(e,t,n){n&&!e.$$classCache[t]?(e.$$animate.addClass(e.$$element,t),e.$$classCache[t]=!0):!n&&e.$$classCache[t]&&(e.$$animate.removeClass(e.$$element,t),e.$$classCache[t]=!1)}function i(e,t,n){t=t?"-"+le(t,"-"):"",r(e,Ta+t,n===!0),r(e,Pa+t,n===!1)}var o=e.clazz,a=e.set,s=e.unset;o.prototype.$setValidity=function(e,o,u){v(o)?t(this,"$pending",e,u):n(this,"$pending",e,u),j(o)?o?(s(this.$error,e,u),a(this.$$success,e,u)):(a(this.$error,e,u),s(this.$$success,e,u)):(s(this.$error,e,u),s(this.$$success,e,u)),this.$pending?(r(this,Yo,!0),this.$valid=this.$invalid=void 0,i(this,"",null)):(r(this,Yo,!1),this.$valid=mr(this.$error),this.$invalid=!this.$valid,i(this,"",this.$valid));var l;l=this.$pending&&this.$pending[e]?void 0:!this.$error[e]&&(!!this.$$success[e]||null),i(this,e,l),this.$$parentForm.$setValidity(e,l,this)}}function mr(e){if(e)for(var t in e)if(e.hasOwnProperty(t))return!1;return!0}function yr(e){e.$formatters.push(function(t){return e.$isEmpty(t)?t:t.toString()})}function br(e,t,n,r,i,o){wr(e,t,n,r,i,o),yr(r)}function wr(e,t,n,r,i,o){var a=Wr(t[0].type);if(!i.android){var s=!1;t.on("compositionstart",function(){s=!0}),t.on("compositionend",function(){s=!1,l()})}var u,l=function(e){if(u&&(o.defer.cancel(u),u=null),!s){var i=t.val(),l=e&&e.type;"password"===a||n.ngTrim&&"false"===n.ngTrim||(i=fi(i)),(r.$viewValue!==i||""===i&&r.$$hasNativeValidators)&&r.$setViewValue(i,l)}};if(i.hasEvent("input"))t.on("input",l);else{var c=function(e,t,n){u||(u=o.defer(function(){u=null,t&&t.value===n||l(e)}))};t.on("keydown",function(e){var t=e.keyCode;91===t||15<t&&t<19||37<=t&&t<=40||c(e,this,this.value)}),i.hasEvent("paste")&&t.on("paste cut",c)}t.on("change",l),fa[a]&&r.$$hasNativeValidators&&a===n.type&&t.on(ca,function(e){if(!u){var t=this[qr],n=t.badInput,r=t.typeMismatch;u=o.defer(function(){u=null,t.badInput===n&&t.typeMismatch===r||l(e)})}}),r.$render=function(){var e=r.$isEmpty(r.$viewValue)?"":r.$viewValue;t.val()!==e&&t.val(e)}}function xr(e,t){if(_(e))return e;if(w(e)){sa.lastIndex=0;var n=sa.exec(e);if(n){var r=+n[1],i=+n[2],o=0,a=0,s=0,u=0,l=nr(r),c=7*(i-1);return t&&(o=t.getHours(),a=t.getMinutes(),s=t.getSeconds(),u=t.getMilliseconds()),new Date(r,0,l.getDate()+c,o,a,s,u)}}return NaN}function _r(e,t){return function(n,i){var o,a;if(_(n))return n;if(w(n)){if('"'===n.charAt(0)&&'"'===n.charAt(n.length-1)&&(n=n.substring(1,n.length-1)),ta.test(n))return new Date(n);if(e.lastIndex=0,o=e.exec(n))return o.shift(),a=i?{yyyy:i.getFullYear(),MM:i.getMonth()+1,dd:i.getDate(),HH:i.getHours(),mm:i.getMinutes(),ss:i.getSeconds(),sss:i.getMilliseconds()/1e3}:{yyyy:1970,MM:1,dd:1,HH:0,mm:0,ss:0,sss:0},r(o,function(e,n){n<t.length&&(a[t[n]]=+e)}),new Date(a.yyyy,a.MM-1,a.dd,a.HH,a.mm,a.ss||0,1e3*a.sss||0)}return NaN}}function kr(e,t,n,r){return function(i,o,a,s,u,l,c){function f(e){return e&&!(e.getTime&&e.getTime()!==e.getTime())}function d(e){return m(e)&&!_(e)?n(e)||void 0:e}Er(i,o,a,s),wr(i,o,a,s,u,l);var p,h=s&&s.$options.getOption("timezone");if(s.$$parserName=e,s.$parsers.push(function(e){if(s.$isEmpty(e))return null;if(t.test(e)){var r=n(e,p);return h&&(r=Y(r,h)),r}}),s.$formatters.push(function(e){if(e&&!_(e))throw Ra("datefmt","Expected `{0}` to be a date",e);return f(e)?(p=e,p&&h&&(p=Y(p,h,!0)),c("date")(e,r,h)):(p=null,"")}),m(a.min)||a.ngMin){var g;s.$validators.min=function(e){return!f(e)||v(g)||n(e)>=g},a.$observe("min",function(e){g=d(e),s.$validate()})}if(m(a.max)||a.ngMax){var $;s.$validators.max=function(e){return!f(e)||v($)||n(e)<=$},a.$observe("max",function(e){$=d(e),s.$validate()})}}}function Er(e,t,n,r){var i=t[0],o=r.$$hasNativeValidators=y(i.validity);o&&r.$parsers.push(function(e){var n=t.prop(qr)||{};return n.badInput||n.typeMismatch?void 0:e})}function Sr(e){e.$$parserName="number",e.$parsers.push(function(t){return e.$isEmpty(t)?null:ia.test(t)?parseFloat(t):void 0}),e.$formatters.push(function(t){if(!e.$isEmpty(t)){if(!x(t))throw Ra("numfmt","Expected `{0}` to be a number",t);t=t.toString()}return t})}function Cr(e){return m(e)&&!x(e)&&(e=parseFloat(e)),ui(e)?void 0:e}function Ar(e){return(0|e)===e}function Or(e){var t=e.toString(),n=t.indexOf(".");if(n===-1){if(-1<e&&e<1){var r=/e-(\d+)$/.exec(t);if(r)return Number(r[1])}return 0}return t.length-n-1}function Mr(e,t,n){var r=Number(e);if(!Ar(r)||!Ar(t)||!Ar(n)){var i=Math.max(Or(r),Or(t),Or(n)),o=Math.pow(10,i);r*=o,t*=o,n*=o}return(r-t)%n===0}function jr(e,t,n,r,i,o){Er(e,t,n,r),Sr(r),wr(e,t,n,r,i,o);var a,s;if((m(n.min)||n.ngMin)&&(r.$validators.min=function(e){return r.$isEmpty(e)||v(a)||e>=a},n.$observe("min",function(e){a=Cr(e),r.$validate()})),(m(n.max)||n.ngMax)&&(r.$validators.max=function(e){return r.$isEmpty(e)||v(s)||e<=s},n.$observe("max",function(e){s=Cr(e),r.$validate()})),m(n.step)||n.ngStep){var u;r.$validators.step=function(e,t){return r.$isEmpty(t)||v(u)||Mr(t,a||0,u)},n.$observe("step",function(e){u=Cr(e),r.$validate()})}}function Tr(e,t,n,r,i,o){function a(e,r){t.attr(e,n[e]),n.$observe(e,r)}function s(e){if(f=Cr(e),!ui(r.$modelValue))if(c){var n=t.val();f>n&&(n=f,t.val(n)),r.$setViewValue(n)}else r.$validate()}function u(e){if(d=Cr(e),!ui(r.$modelValue))if(c){var n=t.val();d<n&&(t.val(d),n=d<f?f:d),r.$setViewValue(n)}else r.$validate()}function l(e){p=Cr(e),ui(r.$modelValue)||(c&&r.$viewValue!==t.val()?r.$setViewValue(t.val()):r.$validate())}Er(e,t,n,r),Sr(r),wr(e,t,n,r,i,o);var c=r.$$hasNativeValidators&&"range"===t[0].type,f=c?0:void 0,d=c?100:void 0,p=c?1:void 0,h=t[0].validity,g=m(n.min),$=m(n.max),y=m(n.step),b=r.$render;r.$render=c&&m(h.rangeUnderflow)&&m(h.rangeOverflow)?function(){b(),r.$setViewValue(t.val())}:b,g&&(r.$validators.min=c?function(){return!0}:function(e,t){return r.$isEmpty(t)||v(f)||t>=f},a("min",s)),$&&(r.$validators.max=c?function(){return!0}:function(e,t){return r.$isEmpty(t)||v(d)||t<=d},a("max",u)),y&&(r.$validators.step=c?function(){return!h.stepMismatch}:function(e,t){return r.$isEmpty(t)||v(p)||Mr(t,f||0,p)},a("step",l))}function Pr(e,t,n,r,i,o){wr(e,t,n,r,i,o),yr(r),r.$$parserName="url",r.$validators.url=function(e,t){var n=e||t;return r.$isEmpty(n)||na.test(n)}}function Dr(e,t,n,r,i,o){wr(e,t,n,r,i,o),yr(r),r.$$parserName="email",r.$validators.email=function(e,t){var n=e||t;return r.$isEmpty(n)||ra.test(n)}}function Vr(e,t,n,r){var i=!n.ngTrim||"false"!==fi(n.ngTrim);v(n.name)&&t.attr("name",a());var o=function(e){var o;t[0].checked&&(o=n.value,i&&(o=fi(o)),r.$setViewValue(o,e&&e.type))};t.on("click",o),r.$render=function(){var e=n.value;i&&(e=fi(e)),t[0].checked=e===r.$viewValue},n.$observe("value",r.$render)}function Ir(e,t,n,r,i){var o;if(m(r)){if(o=e(r),!o.constant)throw Ra("constexpr","Expected constant expression for `{0}`, but saw `{1}`.",n,r);return o(t)}return i}function Ur(e,t,n,r,i,o,a,s){var u=Ir(s,e,"ngTrueValue",n.ngTrueValue,!0),l=Ir(s,e,"ngFalseValue",n.ngFalseValue,!1),c=function(e){r.$setViewValue(t[0].checked,e&&e.type)};t.on("click",c),r.$render=function(){t[0].checked=r.$viewValue},r.$isEmpty=function(e){return e===!1},r.$formatters.push(function(e){return z(e,u)}),r.$parsers.push(function(e){return e?u:l})}function Fr(e,t){function n(e,t){if(!e||!e.length)return[];if(!t||!t.length)return e;var n=[];e:for(var r=0;r<e.length;r++){for(var i=e[r],o=0;o<t.length;o++)if(i===t[o])continue e;n.push(i)}return n}function i(e){return e&&e.split(" ")}function o(e){var t=e;return li(e)?t=e.map(o).join(" "):y(e)&&(t=Object.keys(e).filter(function(t){return e[t]}).join(" ")),t}function a(e){var t=e;if(li(e))t=e.map(a);else if(y(e)){var n=!1;t=Object.keys(e).filter(function(t){var r=e[t];return!n&&v(r)&&(n=!0),r}),n&&t.push(void 0)}return t}e="ngClass"+e;var s;return["$parse",function(u){return{restrict:"AC",link:function(l,c,f){function d(e){e=g(i(e),1),f.$addClass(e)}function p(e){e=g(i(e),-1),f.$removeClass(e)}function h(e,t){var r=i(e),o=i(t),a=n(r,o),s=n(o,r),u=g(a,-1),l=g(s,1);f.$addClass(l),f.$removeClass(u)}function g(e,t){var n=[];return r(e,function(e){(t>0||E[e])&&(E[e]=(E[e]||0)+t,E[e]===+(t>0)&&n.push(e))}),n.join(" ")}function $(e){e===t?d(y):p(y),S=e}function v(e){var t=o(e);t!==y&&m(t)}function m(e){S===t&&h(y,e),y=e}var y,b=f[e].trim(),w=":"===b.charAt(0)&&":"===b.charAt(1),x=w?a:o,_=u(b,x),k=w?v:m,E=c.data("$classCounts"),S=!0;E||(E=$e(),c.data("$classCounts",E)),"ngClass"!==e&&(s||(s=u("$index",function(e){return 1&e})),l.$watch(s,$)),l.$watch(_,k,w)}}}]}function Nr(e,t,n,r,i,o,a,s,u){this.$viewValue=Number.NaN,this.$modelValue=Number.NaN,this.$$rawModelValue=void 0,this.$validators={},this.$asyncValidators={},this.$parsers=[],this.$formatters=[],this.$viewChangeListeners=[],this.$untouched=!0,this.$touched=!1,this.$pristine=!0,this.$dirty=!1,this.$valid=!0,this.$invalid=!1,this.$error={},this.$$success={},this.$pending=void 0,this.$name=u(n.name||"",!1)(e),this.$$parentForm=Ko,this.$options=za,this.$$parsedNgModel=i(n.ngModel),this.$$parsedNgModelAssign=this.$$parsedNgModel.assign,this.$$ngModelGet=this.$$parsedNgModel,this.$$ngModelSet=this.$$parsedNgModelAssign,this.$$pendingDebounce=null,this.$$parserValid=void 0,this.$$currentValidationRunId=0,this.$$scope=e,this.$$attr=n,this.$$element=r,this.$$animate=o,this.$$timeout=a,this.$$parse=i,this.$$q=s,this.$$exceptionHandler=t,$r(this),Rr(this)}function Rr(e){e.$$scope.$watch(function(){var t=e.$$ngModelGet(e.$$scope);if(t!==e.$modelValue&&(e.$modelValue===e.$modelValue||t===t)){e.$modelValue=e.$$rawModelValue=t,e.$$parserValid=void 0;for(var n=e.$formatters,r=n.length,i=t;r--;)i=n[r](i);e.$viewValue!==i&&(e.$$updateEmptyClasses(i),e.$viewValue=e.$$lastCommittedViewValue=i,e.$render(),e.$$runValidators(e.$modelValue,e.$viewValue,p))}return t})}function zr(e){this.$$options=e}function Lr(e,t){r(t,function(t,n){m(e[n])||(e[n]=t)})}var Hr=/^\/(.+)\/([a-z]*)$/,qr="validity",Br=Object.prototype.hasOwnProperty,Wr=function(e){return w(e)?e.toLowerCase():e},Gr=function(e){return w(e)?e.toUpperCase():e},Xr=function(e){return w(e)?e.replace(/[A-Z]/g,function(e){return String.fromCharCode(32|e.charCodeAt(0))}):e},Kr=function(e){return w(e)?e.replace(/[a-z]/g,function(e){return String.fromCharCode(e.charCodeAt(0)&-33)}):e};"i"!=="I".toLowerCase()&&(Wr=Xr,Gr=Kr);var Yr,Jr,Zr,Qr,ei=[].slice,ti=[].splice,ni=[].push,ri=Object.prototype.toString,ii=Object.getPrototypeOf,oi=t("ng"),ai=e.angular||(e.angular={}),si=0;Yr=e.document.documentMode;var ui=Number.isNaN||function(e){return e!==e};p.$inject=[],h.$inject=[];var li=Array.isArray,ci=/^\[object (?:Uint8|Uint8Clamped|Uint16|Uint32|Int8|Int16|Int32|Float32|Float64)Array]$/,fi=function(e){
|
6 |
+
return w(e)?e.trim():e},di=function(e){return e.replace(/([-()[\]{}+?*.$^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08")},pi=function(){function t(){try{return new Function(""),!1}catch(e){return!0}}if(!m(pi.rules)){var n=e.document.querySelector("[ng-csp]")||e.document.querySelector("[data-ng-csp]");if(n){var r=n.getAttribute("ng-csp")||n.getAttribute("data-ng-csp");pi.rules={noUnsafeEval:!r||r.indexOf("no-unsafe-eval")!==-1,noInlineStyle:!r||r.indexOf("no-inline-style")!==-1}}else pi.rules={noUnsafeEval:t(),noInlineStyle:!1}}return pi.rules},hi=function(){if(m(hi.name_))return hi.name_;var t,n,r,i,o=$i.length;for(n=0;n<o;++n)if(r=$i[n],t=e.document.querySelector("["+r.replace(":","\\:")+"jq]")){i=t.getAttribute(r+"jq");break}return hi.name_=i},gi=/:/g,$i=["ng-","data-ng-","ng:","x-ng-"],vi=ie(e.document),mi=/[A-Z]/g,yi=!1,bi=1,wi=2,xi=3,_i=8,ki=9,Ei=11,Si={full:"1.6.1",major:1,minor:6,dot:1,codeName:"promise-rectification"};De.expando="ng339";var Ci=De.cache={},Ai=1;De._data=function(e){return this.cache[e[this.expando]]||{}};var Oi=/-([a-z])/g,Mi=/^-ms-/,ji={mouseleave:"mouseout",mouseenter:"mouseover"},Ti=t("jqLite"),Pi=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,Di=/<|&#?\w+;/,Vi=/<([\w:-]+)/,Ii=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,Ui={option:[1,'<select multiple="multiple">',"</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};Ui.optgroup=Ui.option,Ui.tbody=Ui.tfoot=Ui.colgroup=Ui.caption=Ui.thead,Ui.th=Ui.td;var Fi=e.Node.prototype.contains||function(e){return!!(16&this.compareDocumentPosition(e))},Ni=De.prototype={ready:Ye,toString:function(){var e=[];return r(this,function(t){e.push(""+t)}),"["+e.join(", ")+"]"},eq:function(e){return Jr(e>=0?this[e]:this[this.length+e])},length:0,push:ni,sort:[].sort,splice:[].splice},Ri={};r("multiple,selected,checked,disabled,readOnly,required,open".split(","),function(e){Ri[Wr(e)]=e});var zi={};r("input,select,option,textarea,button,form,details".split(","),function(e){zi[e]=!0});var Li={ngMinlength:"minlength",ngMaxlength:"maxlength",ngMin:"min",ngMax:"max",ngPattern:"pattern",ngStep:"step"};r({data:Re,removeData:Fe,hasData:Oe,cleanData:Me},function(e,t){De[t]=e}),r({data:Re,inheritedData:We,scope:function(e){return Jr.data(e,"$scope")||We(e.parentNode||e,["$isolateScope","$scope"])},isolateScope:function(e){return Jr.data(e,"$isolateScope")||Jr.data(e,"$isolateScopeNoTemplate")},controller:Be,injector:function(e){return We(e,"$injector")},removeAttr:function(e,t){e.removeAttribute(t)},hasClass:ze,css:function(e,t,n){return t=ke(t),m(n)?void(e.style[t]=n):e.style[t]},attr:function(e,t,n){var r,i=e.nodeType;if(i!==xi&&i!==wi&&i!==_i&&e.getAttribute){var o=Wr(t),a=Ri[o];return m(n)?void(null===n||n===!1&&a?e.removeAttribute(t):e.setAttribute(t,a?o:n)):(r=e.getAttribute(t),a&&null!==r&&(r=o),null===r?void 0:r)}},prop:function(e,t,n){return m(n)?void(e[t]=n):e[t]},text:function(){function e(e,t){if(v(t)){var n=e.nodeType;return n===bi||n===xi?e.textContent:""}e.textContent=t}return e.$dv="",e}(),val:function(e,t){if(v(t)){if(e.multiple&&"select"===U(e)){var n=[];return r(e.options,function(e){e.selected&&n.push(e.value||e.text)}),n}return e.value}e.value=t},html:function(e,t){return v(t)?e.innerHTML:(Ie(e,!0),void(e.innerHTML=t))},empty:Ge},function(e,t){De.prototype[t]=function(t,n){var r,i,o=this.length;if(e!==Ge&&v(2===e.length&&e!==ze&&e!==Be?t:n)){if(y(t)){for(r=0;r<o;r++)if(e===Re)e(this[r],t);else for(i in t)e(this[r],i,t[i]);return this}for(var a=e.$dv,s=v(a)?Math.min(o,1):o,u=0;u<s;u++){var l=e(this[u],t,n);a=a?a+l:l}return a}for(r=0;r<o;r++)e(this[r],t,n);return this}}),r({removeData:Fe,on:function(e,t,n,r){if(m(r))throw Ti("onargs","jqLite#on() does not support the `selector` or `eventData` parameters");if(Ae(e)){var i=Ne(e,!0),o=i.events,a=i.handle;a||(a=i.handle=Qe(e,o));for(var s=t.indexOf(" ")>=0?t.split(" "):[t],u=s.length,l=function(t,r,i){var s=o[t];s||(s=o[t]=[],s.specialHandlerWrapper=r,"$destroy"===t||i||e.addEventListener(t,a)),s.push(n)};u--;)t=s[u],ji[t]?(l(ji[t],tt),l(t,void 0,!0)):l(t)}},off:Ue,one:function(e,t,n){e=Jr(e),e.on(t,function r(){e.off(t,n),e.off(t,r)}),e.on(t,n)},replaceWith:function(e,t){var n,i=e.parentNode;Ie(e),r(new De(t),function(t){n?i.insertBefore(t,n.nextSibling):i.replaceChild(t,e),n=t})},children:function(e){var t=[];return r(e.childNodes,function(e){e.nodeType===bi&&t.push(e)}),t},contents:function(e){return e.contentDocument||e.childNodes||[]},append:function(e,t){var n=e.nodeType;if(n===bi||n===Ei){t=new De(t);for(var r=0,i=t.length;r<i;r++){var o=t[r];e.appendChild(o)}}},prepend:function(e,t){if(e.nodeType===bi){var n=e.firstChild;r(new De(t),function(t){e.insertBefore(t,n)})}},wrap:function(e,t){Pe(e,Jr(t).eq(0).clone()[0])},remove:Xe,detach:function(e){Xe(e,!0)},after:function(e,t){var n=e,r=e.parentNode;if(r){t=new De(t);for(var i=0,o=t.length;i<o;i++){var a=t[i];r.insertBefore(a,n.nextSibling),n=a}}},addClass:He,removeClass:Le,toggleClass:function(e,t,n){t&&r(t.split(" "),function(t){var r=n;v(r)&&(r=!ze(e,t)),(r?He:Le)(e,t)})},parent:function(e){var t=e.parentNode;return t&&t.nodeType!==Ei?t:null},next:function(e){return e.nextElementSibling},find:function(e,t){return e.getElementsByTagName?e.getElementsByTagName(t):[]},clone:Ve,triggerHandler:function(e,t,n){var i,o,a,s=t.type||t,u=Ne(e),c=u&&u.events,f=c&&c[s];f&&(i={preventDefault:function(){this.defaultPrevented=!0},isDefaultPrevented:function(){return this.defaultPrevented===!0},stopImmediatePropagation:function(){this.immediatePropagationStopped=!0},isImmediatePropagationStopped:function(){return this.immediatePropagationStopped===!0},stopPropagation:p,type:s,target:e},t.type&&(i=l(i,t)),o=ye(f),a=n?[i].concat(n):[i],r(o,function(t){i.isImmediatePropagationStopped()||t.apply(e,a)}))}},function(e,t){De.prototype[t]=function(t,n,r){for(var i,o=0,a=this.length;o<a;o++)v(i)?(i=e(this[o],t,n,r),m(i)&&(i=Jr(i))):qe(i,e(this[o],t,n,r));return m(i)?i:this}}),De.prototype.bind=De.prototype.on,De.prototype.unbind=De.prototype.off,it.prototype={put:function(e,t){this[rt(e,this.nextUid)]=t},get:function(e){return this[rt(e,this.nextUid)]},remove:function(e){var t=this[e=rt(e,this.nextUid)];return delete this[e],t}};var Hi=[function(){this.$get=[function(){return it}]}],qi=/^([^(]+?)=>/,Bi=/^[^(]*\(\s*([^)]*)\)/m,Wi=/,/,Gi=/^\s*(_?)(\S+?)\1\s*$/,Xi=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/gm,Ki=t("$injector");lt.$$annotate=ut;var Yi=t("$animate"),Ji=1,Zi="ng-animate",Qi=function(){this.$get=p},eo=function(){var e=new it,t=[];this.$get=["$$AnimateRunner","$rootScope",function(n,i){function o(e,t,n){var i=!1;return t&&(t=w(t)?t.split(" "):li(t)?t:[],r(t,function(t){t&&(i=!0,e[t]=n)})),i}function a(){r(t,function(t){var n=e.get(t);if(n){var i=pt(t.attr("class")),o="",a="";r(n,function(e,t){var n=!!i[t];e!==n&&(e?o+=(o.length?" ":"")+t:a+=(a.length?" ":"")+t)}),r(t,function(e){o&&He(e,o),a&&Le(e,a)}),e.remove(t)}}),t.length=0}function s(n,r,s){var u=e.get(n)||{},l=o(u,r,!0),c=o(u,s,!1);(l||c)&&(e.put(n,u),t.push(n),1===t.length&&i.$$postDigest(a))}return{enabled:p,on:p,off:p,pin:p,push:function(e,t,r,i){i&&i(),r=r||{},r.from&&e.css(r.from),r.to&&e.css(r.to),(r.addClass||r.removeClass)&&s(e,r.addClass,r.removeClass);var o=new n;return o.complete(),o}}}]},to=["$provide",function(e){var t=this;this.$$registeredAnimations=Object.create(null),this.register=function(n,r){if(n&&"."!==n.charAt(0))throw Yi("notcsel","Expecting class selector starting with '.' got '{0}'.",n);var i=n+"-animation";t.$$registeredAnimations[n.substr(1)]=i,e.factory(i,r)},this.classNameFilter=function(e){if(1===arguments.length&&(this.$$classNameFilter=e instanceof RegExp?e:null,this.$$classNameFilter)){var t=new RegExp("(\\s+|\\/)"+Zi+"(\\s+|\\/)");if(t.test(this.$$classNameFilter.toString()))throw Yi("nongcls",'$animateProvider.classNameFilter(regex) prohibits accepting a regex value which matches/contains the "{0}" CSS class.',Zi)}return this.$$classNameFilter},this.$get=["$$animateQueue",function(e){function t(e,t,n){if(n){var r=dt(n);!r||r.parentNode||r.previousElementSibling||(n=null)}n?n.after(e):t.prepend(e)}return{on:e.on,off:e.off,pin:e.pin,enabled:e.enabled,cancel:function(e){e.end&&e.end()},enter:function(n,r,i,o){return r=r&&Jr(r),i=i&&Jr(i),r=r||i.parent(),t(n,r,i),e.push(n,"enter",ht(o))},move:function(n,r,i,o){return r=r&&Jr(r),i=i&&Jr(i),r=r||i.parent(),t(n,r,i),e.push(n,"move",ht(o))},leave:function(t,n){return e.push(t,"leave",ht(n),function(){t.remove()})},addClass:function(t,n,r){return r=ht(r),r.addClass=ft(r.addclass,n),e.push(t,"addClass",r)},removeClass:function(t,n,r){return r=ht(r),r.removeClass=ft(r.removeClass,n),e.push(t,"removeClass",r)},setClass:function(t,n,r,i){return i=ht(i),i.addClass=ft(i.addClass,n),i.removeClass=ft(i.removeClass,r),e.push(t,"setClass",i)},animate:function(t,n,r,i,o){return o=ht(o),o.from=o.from?l(o.from,n):n,o.to=o.to?l(o.to,r):r,i=i||"ng-inline-animate",o.tempClasses=ft(o.tempClasses,i),e.push(t,"animate",o)}}}]}],no=function(){this.$get=["$$rAF",function(e){function t(t){n.push(t),n.length>1||e(function(){for(var e=0;e<n.length;e++)n[e]();n=[]})}var n=[];return function(){var e=!1;return t(function(){e=!0}),function(n){e?n():t(n)}}}]},ro=function(){this.$get=["$q","$sniffer","$$animateAsyncRun","$$isDocumentHidden","$timeout",function(e,t,n,i,o){function a(e){this.setHost(e);var t=n(),r=function(e){o(e,0,!1)};this._doneCallbacks=[],this._tick=function(e){i()?r(e):t(e)},this._state=0}var s=0,u=1,l=2;return a.chain=function(e,t){function n(){return r===e.length?void t(!0):void e[r](function(e){return e===!1?void t(!1):(r++,void n())})}var r=0;n()},a.all=function(e,t){function n(n){o=o&&n,++i===e.length&&t(o)}var i=0,o=!0;r(e,function(e){e.done(n)})},a.prototype={setHost:function(e){this.host=e||{}},done:function(e){this._state===l?e():this._doneCallbacks.push(e)},progress:p,getPromise:function(){if(!this.promise){var t=this;this.promise=e(function(e,n){t.done(function(t){t===!1?n():e()})})}return this.promise},then:function(e,t){return this.getPromise().then(e,t)},"catch":function(e){return this.getPromise()["catch"](e)},"finally":function(e){return this.getPromise()["finally"](e)},pause:function(){this.host.pause&&this.host.pause()},resume:function(){this.host.resume&&this.host.resume()},end:function(){this.host.end&&this.host.end(),this._resolve(!0)},cancel:function(){this.host.cancel&&this.host.cancel(),this._resolve(!1)},complete:function(e){var t=this;t._state===s&&(t._state=u,t._tick(function(){t._resolve(e)}))},_resolve:function(e){this._state!==l&&(r(this._doneCallbacks,function(t){t(e)}),this._doneCallbacks.length=0,this._state=l)}},a}]},io=function(){this.$get=["$$rAF","$q","$$AnimateRunner",function(e,t,n){return function(t,r){function i(){return e(function(){o(),s||u.complete(),s=!0}),u}function o(){a.addClass&&(t.addClass(a.addClass),a.addClass=null),a.removeClass&&(t.removeClass(a.removeClass),a.removeClass=null),a.to&&(t.css(a.to),a.to=null)}var a=r||{};a.$$prepared||(a=R(a)),a.cleanupStyles&&(a.from=a.to=null),a.from&&(t.css(a.from),a.from=null);var s,u=new n;return{start:i,end:i}}}]},oo=t("$compile"),ao=new yt;bt.$inject=["$provide","$$sanitizeUriProvider"],wt.prototype.isFirstChange=function(){return this.previousValue===ao};var so=/^((?:x|data)[:\-_])/i,uo=/[:\-_]+(.)/g,lo=t("$controller"),co=/^(\S+)(\s+as\s+([\w$]+))?$/,fo=function(){this.$get=["$document",function(e){return function(t){return t?!t.nodeType&&t instanceof Jr&&(t=t[0]):t=e[0].body,t.offsetWidth+1}}]},po="application/json",ho={"Content-Type":po+";charset=utf-8"},go=/^\[|^\{(?!\{)/,$o={"[":/]$/,"{":/}$/},vo=/^\)]\}',?\n/,mo=t("$http"),yo=ai.$interpolateMinErr=t("$interpolate");yo.throwNoconcat=function(e){throw yo("noconcat","Error while interpolating: {0}\nStrict Contextual Escaping disallows interpolations that concatenate multiple expressions when a trusted value is required. See http://docs.angularjs.org/api/ng.$sce",e)},yo.interr=function(e,t){return yo("interr","Can't interpolate: {0}\n{1}",e,t.toString())};var bo=function(){this.$get=["$window",function(e){function t(e){var t=function(e){t.data=e,t.called=!0};return t.id=e,t}var n=e.angular.callbacks,r={};return{createCallback:function(e){var i="_"+(n.$$counter++).toString(36),o="angular.callbacks."+i,a=t(i);return r[o]=n[i]=a,o},wasCalled:function(e){return r[e].called},getResponse:function(e){return r[e].data},removeCallback:function(e){var t=r[e];delete n[t.id],delete r[e]}}}]},wo=/^([^?#]*)(\?([^#]*))?(#(.*))?$/,xo={http:80,https:443,ftp:21},_o=t("$location"),ko=/^\s*[\\/]{2,}/,Eo={$$absUrl:"",$$html5:!1,$$replace:!1,absUrl:rn("$$absUrl"),url:function(e){if(v(e))return this.$$url;var t=wo.exec(e);return(t[1]||""===e)&&this.path(decodeURIComponent(t[1])),(t[2]||t[1]||""===e)&&this.search(t[3]||""),this.hash(t[5]||""),this},protocol:rn("$$protocol"),host:rn("$$host"),port:rn("$$port"),path:on("$$path",function(e){return e=null!==e?e.toString():"","/"===e.charAt(0)?e:"/"+e}),search:function(e,t){switch(arguments.length){case 0:return this.$$search;case 1:if(w(e)||x(e))e=e.toString(),this.$$search=Q(e);else{if(!y(e))throw _o("isrcharg","The first argument of the `$location#search()` call must be a string or an object.");e=R(e,{}),r(e,function(t,n){null==t&&delete e[n]}),this.$$search=e}break;default:v(t)||null===t?delete this.$$search[e]:this.$$search[e]=t}return this.$$compose(),this},hash:on("$$hash",function(e){return null!==e?e.toString():""}),replace:function(){return this.$$replace=!0,this}};r([nn,tn,en],function(e){e.prototype=Object.create(Eo),e.prototype.state=function(t){if(!arguments.length)return this.$$state;if(e!==en||!this.$$html5)throw _o("nostate","History API state support is available only in HTML5 mode and only in browsers supporting HTML5 History API");return this.$$state=v(t)?null:t,this}});var So=t("$parse"),Co={}.constructor.prototype.valueOf,Ao=$e();r("+ - * / % === !== == != < > <= >= && || ! = |".split(" "),function(e){Ao[e]=!0});var Oo={n:"\n",f:"\f",r:"\r",t:"\t",v:"\x0B","'":"'",'"':'"'},Mo=function(e){this.options=e};Mo.prototype={constructor:Mo,lex:function(e){for(this.text=e,this.index=0,this.tokens=[];this.index<this.text.length;){var t=this.text.charAt(this.index);if('"'===t||"'"===t)this.readString(t);else if(this.isNumber(t)||"."===t&&this.isNumber(this.peek()))this.readNumber();else if(this.isIdentifierStart(this.peekMultichar()))this.readIdent();else if(this.is(t,"(){}[].,;:?"))this.tokens.push({index:this.index,text:t}),this.index++;else if(this.isWhitespace(t))this.index++;else{var n=t+this.peek(),r=n+this.peek(2),i=Ao[t],o=Ao[n],a=Ao[r];if(i||o||a){var s=a?r:o?n:t;this.tokens.push({index:this.index,text:s,operator:!0}),this.index+=s.length}else this.throwError("Unexpected next character ",this.index,this.index+1)}}return this.tokens},is:function(e,t){return t.indexOf(e)!==-1},peek:function(e){var t=e||1;return this.index+t<this.text.length&&this.text.charAt(this.index+t)},isNumber:function(e){return"0"<=e&&e<="9"&&"string"==typeof e},isWhitespace:function(e){return" "===e||"\r"===e||"\t"===e||"\n"===e||"\x0B"===e||" "===e},isIdentifierStart:function(e){return this.options.isIdentifierStart?this.options.isIdentifierStart(e,this.codePointAt(e)):this.isValidIdentifierStart(e)},isValidIdentifierStart:function(e){return"a"<=e&&e<="z"||"A"<=e&&e<="Z"||"_"===e||"$"===e},isIdentifierContinue:function(e){return this.options.isIdentifierContinue?this.options.isIdentifierContinue(e,this.codePointAt(e)):this.isValidIdentifierContinue(e)},isValidIdentifierContinue:function(e,t){return this.isValidIdentifierStart(e,t)||this.isNumber(e)},codePointAt:function(e){return 1===e.length?e.charCodeAt(0):(e.charCodeAt(0)<<10)+e.charCodeAt(1)-56613888},peekMultichar:function(){var e=this.text.charAt(this.index),t=this.peek();if(!t)return e;var n=e.charCodeAt(0),r=t.charCodeAt(0);return n>=55296&&n<=56319&&r>=56320&&r<=57343?e+t:e},isExpOperator:function(e){return"-"===e||"+"===e||this.isNumber(e)},throwError:function(e,t,n){n=n||this.index;var r=m(t)?"s "+t+"-"+this.index+" ["+this.text.substring(t,n)+"]":" "+n;throw So("lexerr","Lexer Error: {0} at column{1} in expression [{2}].",e,r,this.text)},readNumber:function(){for(var e="",t=this.index;this.index<this.text.length;){var n=Wr(this.text.charAt(this.index));if("."===n||this.isNumber(n))e+=n;else{var r=this.peek();if("e"===n&&this.isExpOperator(r))e+=n;else if(this.isExpOperator(n)&&r&&this.isNumber(r)&&"e"===e.charAt(e.length-1))e+=n;else{if(!this.isExpOperator(n)||r&&this.isNumber(r)||"e"!==e.charAt(e.length-1))break;this.throwError("Invalid exponent")}}this.index++}this.tokens.push({index:t,text:e,constant:!0,value:Number(e)})},readIdent:function(){var e=this.index;for(this.index+=this.peekMultichar().length;this.index<this.text.length;){var t=this.peekMultichar();if(!this.isIdentifierContinue(t))break;this.index+=t.length}this.tokens.push({index:e,text:this.text.slice(e,this.index),identifier:!0})},readString:function(e){var t=this.index;this.index++;for(var n="",r=e,i=!1;this.index<this.text.length;){var o=this.text.charAt(this.index);if(r+=o,i){if("u"===o){var a=this.text.substring(this.index+1,this.index+5);a.match(/[\da-f]{4}/i)||this.throwError("Invalid unicode escape [\\u"+a+"]"),this.index+=4,n+=String.fromCharCode(parseInt(a,16))}else{var s=Oo[o];n+=s||o}i=!1}else if("\\"===o)i=!0;else{if(o===e)return this.index++,void this.tokens.push({index:t,text:r,constant:!0,value:n});n+=o}this.index++}this.throwError("Unterminated quote",t)}};var jo=function(e,t){this.lexer=e,this.options=t};jo.Program="Program",jo.ExpressionStatement="ExpressionStatement",jo.AssignmentExpression="AssignmentExpression",jo.ConditionalExpression="ConditionalExpression",jo.LogicalExpression="LogicalExpression",jo.BinaryExpression="BinaryExpression",jo.UnaryExpression="UnaryExpression",jo.CallExpression="CallExpression",jo.MemberExpression="MemberExpression",jo.Identifier="Identifier",jo.Literal="Literal",jo.ArrayExpression="ArrayExpression",jo.Property="Property",jo.ObjectExpression="ObjectExpression",jo.ThisExpression="ThisExpression",jo.LocalsExpression="LocalsExpression",jo.NGValueParameter="NGValueParameter",jo.prototype={ast:function(e){this.text=e,this.tokens=this.lexer.lex(e);var t=this.program();return 0!==this.tokens.length&&this.throwError("is an unexpected token",this.tokens[0]),t},program:function(){for(var e=[];;)if(this.tokens.length>0&&!this.peek("}",")",";","]")&&e.push(this.expressionStatement()),!this.expect(";"))return{type:jo.Program,body:e}},expressionStatement:function(){return{type:jo.ExpressionStatement,expression:this.filterChain()}},filterChain:function(){for(var e=this.expression();this.expect("|");)e=this.filter(e);return e},expression:function(){return this.assignment()},assignment:function(){var e=this.ternary();if(this.expect("=")){if(!hn(e))throw So("lval","Trying to assign a value to a non l-value");e={type:jo.AssignmentExpression,left:e,right:this.assignment(),operator:"="}}return e},ternary:function(){var e,t,n=this.logicalOR();return this.expect("?")&&(e=this.expression(),this.consume(":"))?(t=this.expression(),{type:jo.ConditionalExpression,test:n,alternate:e,consequent:t}):n},logicalOR:function(){for(var e=this.logicalAND();this.expect("||");)e={type:jo.LogicalExpression,operator:"||",left:e,right:this.logicalAND()};return e},logicalAND:function(){for(var e=this.equality();this.expect("&&");)e={type:jo.LogicalExpression,operator:"&&",left:e,right:this.equality()};return e},equality:function(){for(var e,t=this.relational();e=this.expect("==","!=","===","!==");)t={type:jo.BinaryExpression,operator:e.text,left:t,right:this.relational()};return t},relational:function(){for(var e,t=this.additive();e=this.expect("<",">","<=",">=");)t={type:jo.BinaryExpression,operator:e.text,left:t,right:this.additive()};return t},additive:function(){for(var e,t=this.multiplicative();e=this.expect("+","-");)t={type:jo.BinaryExpression,operator:e.text,left:t,right:this.multiplicative()};return t},multiplicative:function(){for(var e,t=this.unary();e=this.expect("*","/","%");)t={type:jo.BinaryExpression,operator:e.text,left:t,right:this.unary()};return t},unary:function(){var e;return(e=this.expect("+","-","!"))?{type:jo.UnaryExpression,operator:e.text,prefix:!0,argument:this.unary()}:this.primary()},primary:function(){var e;this.expect("(")?(e=this.filterChain(),this.consume(")")):this.expect("[")?e=this.arrayDeclaration():this.expect("{")?e=this.object():this.selfReferential.hasOwnProperty(this.peek().text)?e=R(this.selfReferential[this.consume().text]):this.options.literals.hasOwnProperty(this.peek().text)?e={type:jo.Literal,value:this.options.literals[this.consume().text]}:this.peek().identifier?e=this.identifier():this.peek().constant?e=this.constant():this.throwError("not a primary expression",this.peek());for(var t;t=this.expect("(","[",".");)"("===t.text?(e={type:jo.CallExpression,callee:e,arguments:this.parseArguments()},this.consume(")")):"["===t.text?(e={type:jo.MemberExpression,object:e,property:this.expression(),computed:!0},this.consume("]")):"."===t.text?e={type:jo.MemberExpression,object:e,property:this.identifier(),computed:!1}:this.throwError("IMPOSSIBLE");return e},filter:function(e){for(var t=[e],n={type:jo.CallExpression,callee:this.identifier(),arguments:t,filter:!0};this.expect(":");)t.push(this.expression());return n},parseArguments:function(){var e=[];if(")"!==this.peekToken().text)do e.push(this.filterChain());while(this.expect(","));return e},identifier:function(){var e=this.consume();return e.identifier||this.throwError("is not a valid identifier",e),{type:jo.Identifier,name:e.text}},constant:function(){return{type:jo.Literal,value:this.consume().value}},arrayDeclaration:function(){var e=[];if("]"!==this.peekToken().text)do{if(this.peek("]"))break;e.push(this.expression())}while(this.expect(","));return this.consume("]"),{type:jo.ArrayExpression,elements:e}},object:function(){var e,t=[];if("}"!==this.peekToken().text)do{if(this.peek("}"))break;e={type:jo.Property,kind:"init"},this.peek().constant?(e.key=this.constant(),e.computed=!1,this.consume(":"),e.value=this.expression()):this.peek().identifier?(e.key=this.identifier(),e.computed=!1,this.peek(":")?(this.consume(":"),e.value=this.expression()):e.value=e.key):this.peek("[")?(this.consume("["),e.key=this.expression(),this.consume("]"),e.computed=!0,this.consume(":"),e.value=this.expression()):this.throwError("invalid key",this.peek()),t.push(e)}while(this.expect(","));return this.consume("}"),{type:jo.ObjectExpression,properties:t}},throwError:function(e,t){throw So("syntax","Syntax Error: Token '{0}' {1} at column {2} of the expression [{3}] starting at [{4}].",t.text,e,t.index+1,this.text,this.text.substring(t.index))},consume:function(e){if(0===this.tokens.length)throw So("ueoe","Unexpected end of expression: {0}",this.text);var t=this.expect(e);return t||this.throwError("is unexpected, expecting ["+e+"]",this.peek()),t},peekToken:function(){if(0===this.tokens.length)throw So("ueoe","Unexpected end of expression: {0}",this.text);return this.tokens[0]},peek:function(e,t,n,r){return this.peekAhead(0,e,t,n,r)},peekAhead:function(e,t,n,r,i){if(this.tokens.length>e){var o=this.tokens[e],a=o.text;if(a===t||a===n||a===r||a===i||!t&&!n&&!r&&!i)return o}return!1},expect:function(e,t,n,r){var i=this.peek(e,t,n,r);return!!i&&(this.tokens.shift(),i)},selfReferential:{"this":{type:jo.ThisExpression},$locals:{type:jo.LocalsExpression}}},mn.prototype={compile:function(e){var t=this,n=this.astBuilder.ast(e);this.state={nextId:0,filters:{},fn:{vars:[],body:[],own:{}},assign:{vars:[],body:[],own:{}},inputs:[]},dn(n,t.$filter);var i,o="";if(this.stage="assign",i=gn(n)){this.state.computing="assign";var a=this.nextId();this.recurse(i,a),this.return_(a),o="fn.assign="+this.generateFunction("assign","s,v,l")}var s=pn(n.body);t.stage="inputs",r(s,function(e,n){var r="fn"+n;t.state[r]={vars:[],body:[],own:{}},t.state.computing=r;var i=t.nextId();t.recurse(e,i),t.return_(i),t.state.inputs.push(r),e.watchId=n}),this.state.computing="fn",this.stage="main",this.recurse(n);var u='"'+this.USE+" "+this.STRICT+'";\n'+this.filterPrefix()+"var fn="+this.generateFunction("fn","s,l,a,i")+o+this.watchFns()+"return fn;",l=new Function("$filter","getStringValue","ifDefined","plus",u)(this.$filter,un,ln,cn);return this.state=this.stage=void 0,l.literal=$n(n),l.constant=vn(n),l},USE:"use",STRICT:"strict",watchFns:function(){var e=[],t=this.state.inputs,n=this;return r(t,function(t){e.push("var "+t+"="+n.generateFunction(t,"s"))}),t.length&&e.push("fn.inputs=["+t.join(",")+"];"),e.join("")},generateFunction:function(e,t){return"function("+t+"){"+this.varsPrefix(e)+this.body(e)+"};"},filterPrefix:function(){var e=[],t=this;return r(this.state.filters,function(n,r){e.push(n+"=$filter("+t.escape(r)+")")}),e.length?"var "+e.join(",")+";":""},varsPrefix:function(e){return this.state[e].vars.length?"var "+this.state[e].vars.join(",")+";":""},body:function(e){return this.state[e].body.join("")},recurse:function(e,t,n,i,o,a){var s,u,l,c,f,d=this;if(i=i||p,!a&&m(e.watchId))return t=t||this.nextId(),void this.if_("i",this.lazyAssign(t,this.computedMember("i",e.watchId)),this.lazyRecurse(e,t,n,i,o,!0));switch(e.type){case jo.Program:r(e.body,function(t,n){d.recurse(t.expression,void 0,void 0,function(e){u=e}),n!==e.body.length-1?d.current().body.push(u,";"):d.return_(u)});break;case jo.Literal:c=this.escape(e.value),this.assign(t,c),i(t||c);break;case jo.UnaryExpression:this.recurse(e.argument,void 0,void 0,function(e){u=e}),c=e.operator+"("+this.ifDefined(u,0)+")",this.assign(t,c),i(c);break;case jo.BinaryExpression:this.recurse(e.left,void 0,void 0,function(e){s=e}),this.recurse(e.right,void 0,void 0,function(e){u=e}),c="+"===e.operator?this.plus(s,u):"-"===e.operator?this.ifDefined(s,0)+e.operator+this.ifDefined(u,0):"("+s+")"+e.operator+"("+u+")",this.assign(t,c),i(c);break;case jo.LogicalExpression:t=t||this.nextId(),d.recurse(e.left,t),d.if_("&&"===e.operator?t:d.not(t),d.lazyRecurse(e.right,t)),i(t);break;case jo.ConditionalExpression:t=t||this.nextId(),d.recurse(e.test,t),d.if_(t,d.lazyRecurse(e.alternate,t),d.lazyRecurse(e.consequent,t)),i(t);break;case jo.Identifier:t=t||this.nextId(),n&&(n.context="inputs"===d.stage?"s":this.assign(this.nextId(),this.getHasOwnProperty("l",e.name)+"?l:s"),n.computed=!1,n.name=e.name),d.if_("inputs"===d.stage||d.not(d.getHasOwnProperty("l",e.name)),function(){d.if_("inputs"===d.stage||"s",function(){o&&1!==o&&d.if_(d.isNull(d.nonComputedMember("s",e.name)),d.lazyAssign(d.nonComputedMember("s",e.name),"{}")),d.assign(t,d.nonComputedMember("s",e.name))})},t&&d.lazyAssign(t,d.nonComputedMember("l",e.name))),i(t);break;case jo.MemberExpression:s=n&&(n.context=this.nextId())||this.nextId(),t=t||this.nextId(),d.recurse(e.object,s,void 0,function(){d.if_(d.notNull(s),function(){e.computed?(u=d.nextId(),d.recurse(e.property,u),d.getStringValue(u),o&&1!==o&&d.if_(d.not(d.computedMember(s,u)),d.lazyAssign(d.computedMember(s,u),"{}")),c=d.computedMember(s,u),d.assign(t,c),n&&(n.computed=!0,n.name=u)):(o&&1!==o&&d.if_(d.isNull(d.nonComputedMember(s,e.property.name)),d.lazyAssign(d.nonComputedMember(s,e.property.name),"{}")),c=d.nonComputedMember(s,e.property.name),d.assign(t,c),n&&(n.computed=!1,n.name=e.property.name))},function(){d.assign(t,"undefined")}),i(t)},!!o);break;case jo.CallExpression:t=t||this.nextId(),e.filter?(u=d.filter(e.callee.name),l=[],r(e.arguments,function(e){var t=d.nextId();d.recurse(e,t),l.push(t)}),c=u+"("+l.join(",")+")",d.assign(t,c),i(t)):(u=d.nextId(),s={},l=[],d.recurse(e.callee,u,s,function(){d.if_(d.notNull(u),function(){r(e.arguments,function(t){d.recurse(t,e.constant?void 0:d.nextId(),void 0,function(e){l.push(e)})}),c=s.name?d.member(s.context,s.name,s.computed)+"("+l.join(",")+")":u+"("+l.join(",")+")",d.assign(t,c)},function(){d.assign(t,"undefined")}),i(t)}));break;case jo.AssignmentExpression:u=this.nextId(),s={},this.recurse(e.left,void 0,s,function(){d.if_(d.notNull(s.context),function(){d.recurse(e.right,u),c=d.member(s.context,s.name,s.computed)+e.operator+u,d.assign(t,c),i(t||c)})},1);break;case jo.ArrayExpression:l=[],r(e.elements,function(t){d.recurse(t,e.constant?void 0:d.nextId(),void 0,function(e){l.push(e)})}),c="["+l.join(",")+"]",this.assign(t,c),i(t||c);break;case jo.ObjectExpression:l=[],f=!1,r(e.properties,function(e){e.computed&&(f=!0)}),f?(t=t||this.nextId(),this.assign(t,"{}"),r(e.properties,function(e){e.computed?(s=d.nextId(),d.recurse(e.key,s)):s=e.key.type===jo.Identifier?e.key.name:""+e.key.value,u=d.nextId(),d.recurse(e.value,u),d.assign(d.member(t,s,e.computed),u)})):(r(e.properties,function(t){d.recurse(t.value,e.constant?void 0:d.nextId(),void 0,function(e){l.push(d.escape(t.key.type===jo.Identifier?t.key.name:""+t.key.value)+":"+e)})}),c="{"+l.join(",")+"}",this.assign(t,c)),i(t||c);break;case jo.ThisExpression:this.assign(t,"s"),i(t||"s");break;case jo.LocalsExpression:this.assign(t,"l"),i(t||"l");break;case jo.NGValueParameter:this.assign(t,"v"),i(t||"v")}},getHasOwnProperty:function(e,t){var n=e+"."+t,r=this.current().own;return r.hasOwnProperty(n)||(r[n]=this.nextId(!1,e+"&&("+this.escape(t)+" in "+e+")")),r[n]},assign:function(e,t){if(e)return this.current().body.push(e,"=",t,";"),e},filter:function(e){return this.state.filters.hasOwnProperty(e)||(this.state.filters[e]=this.nextId(!0)),this.state.filters[e]},ifDefined:function(e,t){return"ifDefined("+e+","+this.escape(t)+")"},plus:function(e,t){return"plus("+e+","+t+")"},return_:function(e){this.current().body.push("return ",e,";")},if_:function(e,t,n){if(e===!0)t();else{var r=this.current().body;r.push("if(",e,"){"),t(),r.push("}"),n&&(r.push("else{"),n(),r.push("}"))}},not:function(e){return"!("+e+")"},isNull:function(e){return e+"==null"},notNull:function(e){return e+"!=null"},nonComputedMember:function(e,t){var n=/^[$_a-zA-Z][$_a-zA-Z0-9]*$/,r=/[^$_a-zA-Z0-9]/g;return n.test(t)?e+"."+t:e+'["'+t.replace(r,this.stringEscapeFn)+'"]'},computedMember:function(e,t){return e+"["+t+"]"},member:function(e,t,n){return n?this.computedMember(e,t):this.nonComputedMember(e,t)},getStringValue:function(e){this.assign(e,"getStringValue("+e+")")},lazyRecurse:function(e,t,n,r,i,o){var a=this;return function(){a.recurse(e,t,n,r,i,o)}},lazyAssign:function(e,t){var n=this;return function(){n.assign(e,t)}},stringEscapeRegex:/[^ a-zA-Z0-9]/g,stringEscapeFn:function(e){return"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)},escape:function(e){if(w(e))return"'"+e.replace(this.stringEscapeRegex,this.stringEscapeFn)+"'";if(x(e))return e.toString();if(e===!0)return"true";if(e===!1)return"false";if(null===e)return"null";if("undefined"==typeof e)return"undefined";throw So("esc","IMPOSSIBLE")},nextId:function(e,t){var n="v"+this.state.nextId++;return e||this.current().vars.push(n+(t?"="+t:"")),n},current:function(){return this.state[this.state.computing]}},yn.prototype={compile:function(e){var t=this,n=this.astBuilder.ast(e);dn(n,t.$filter);var i,o;(i=gn(n))&&(o=this.recurse(i));var a,s=pn(n.body);s&&(a=[],r(s,function(e,n){var r=t.recurse(e);e.input=r,a.push(r),e.watchId=n}));var u=[];r(n.body,function(e){u.push(t.recurse(e.expression))});var l=0===n.body.length?p:1===n.body.length?u[0]:function(e,t){var n;return r(u,function(r){n=r(e,t)}),n};return o&&(l.assign=function(e,t,n){return o(e,n,t)}),a&&(l.inputs=a),l.literal=$n(n),l.constant=vn(n),l},recurse:function(e,t,n){var i,o,a,s=this;if(e.input)return this.inputs(e.input,e.watchId);switch(e.type){case jo.Literal:return this.value(e.value,t);case jo.UnaryExpression:return o=this.recurse(e.argument),this["unary"+e.operator](o,t);case jo.BinaryExpression:return i=this.recurse(e.left),o=this.recurse(e.right),this["binary"+e.operator](i,o,t);case jo.LogicalExpression:return i=this.recurse(e.left),o=this.recurse(e.right),this["binary"+e.operator](i,o,t);
|
7 |
+
case jo.ConditionalExpression:return this["ternary?:"](this.recurse(e.test),this.recurse(e.alternate),this.recurse(e.consequent),t);case jo.Identifier:return s.identifier(e.name,t,n);case jo.MemberExpression:return i=this.recurse(e.object,!1,!!n),e.computed||(o=e.property.name),e.computed&&(o=this.recurse(e.property)),e.computed?this.computedMember(i,o,t,n):this.nonComputedMember(i,o,t,n);case jo.CallExpression:return a=[],r(e.arguments,function(e){a.push(s.recurse(e))}),e.filter&&(o=this.$filter(e.callee.name)),e.filter||(o=this.recurse(e.callee,!0)),e.filter?function(e,n,r,i){for(var s=[],u=0;u<a.length;++u)s.push(a[u](e,n,r,i));var l=o.apply(void 0,s,i);return t?{context:void 0,name:void 0,value:l}:l}:function(e,n,r,i){var s,u=o(e,n,r,i);if(null!=u.value){for(var l=[],c=0;c<a.length;++c)l.push(a[c](e,n,r,i));s=u.value.apply(u.context,l)}return t?{value:s}:s};case jo.AssignmentExpression:return i=this.recurse(e.left,!0,1),o=this.recurse(e.right),function(e,n,r,a){var s=i(e,n,r,a),u=o(e,n,r,a);return s.context[s.name]=u,t?{value:u}:u};case jo.ArrayExpression:return a=[],r(e.elements,function(e){a.push(s.recurse(e))}),function(e,n,r,i){for(var o=[],s=0;s<a.length;++s)o.push(a[s](e,n,r,i));return t?{value:o}:o};case jo.ObjectExpression:return a=[],r(e.properties,function(e){e.computed?a.push({key:s.recurse(e.key),computed:!0,value:s.recurse(e.value)}):a.push({key:e.key.type===jo.Identifier?e.key.name:""+e.key.value,computed:!1,value:s.recurse(e.value)})}),function(e,n,r,i){for(var o={},s=0;s<a.length;++s)a[s].computed?o[a[s].key(e,n,r,i)]=a[s].value(e,n,r,i):o[a[s].key]=a[s].value(e,n,r,i);return t?{value:o}:o};case jo.ThisExpression:return function(e){return t?{value:e}:e};case jo.LocalsExpression:return function(e,n){return t?{value:n}:n};case jo.NGValueParameter:return function(e,n,r){return t?{value:r}:r}}},"unary+":function(e,t){return function(n,r,i,o){var a=e(n,r,i,o);return a=m(a)?+a:0,t?{value:a}:a}},"unary-":function(e,t){return function(n,r,i,o){var a=e(n,r,i,o);return a=m(a)?-a:-0,t?{value:a}:a}},"unary!":function(e,t){return function(n,r,i,o){var a=!e(n,r,i,o);return t?{value:a}:a}},"binary+":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a),u=t(r,i,o,a),l=cn(s,u);return n?{value:l}:l}},"binary-":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a),u=t(r,i,o,a),l=(m(s)?s:0)-(m(u)?u:0);return n?{value:l}:l}},"binary*":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)*t(r,i,o,a);return n?{value:s}:s}},"binary/":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)/t(r,i,o,a);return n?{value:s}:s}},"binary%":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)%t(r,i,o,a);return n?{value:s}:s}},"binary===":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)===t(r,i,o,a);return n?{value:s}:s}},"binary!==":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)!==t(r,i,o,a);return n?{value:s}:s}},"binary==":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)==t(r,i,o,a);return n?{value:s}:s}},"binary!=":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)!=t(r,i,o,a);return n?{value:s}:s}},"binary<":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)<t(r,i,o,a);return n?{value:s}:s}},"binary>":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)>t(r,i,o,a);return n?{value:s}:s}},"binary<=":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)<=t(r,i,o,a);return n?{value:s}:s}},"binary>=":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)>=t(r,i,o,a);return n?{value:s}:s}},"binary&&":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)&&t(r,i,o,a);return n?{value:s}:s}},"binary||":function(e,t,n){return function(r,i,o,a){var s=e(r,i,o,a)||t(r,i,o,a);return n?{value:s}:s}},"ternary?:":function(e,t,n,r){return function(i,o,a,s){var u=e(i,o,a,s)?t(i,o,a,s):n(i,o,a,s);return r?{value:u}:u}},value:function(e,t){return function(){return t?{context:void 0,name:void 0,value:e}:e}},identifier:function(e,t,n){return function(r,i,o,a){var s=i&&e in i?i:r;n&&1!==n&&s&&null==s[e]&&(s[e]={});var u=s?s[e]:void 0;return t?{context:s,name:e,value:u}:u}},computedMember:function(e,t,n,r){return function(i,o,a,s){var u,l,c=e(i,o,a,s);return null!=c&&(u=t(i,o,a,s),u=un(u),r&&1!==r&&c&&!c[u]&&(c[u]={}),l=c[u]),n?{context:c,name:u,value:l}:l}},nonComputedMember:function(e,t,n,r){return function(i,o,a,s){var u=e(i,o,a,s);r&&1!==r&&u&&null==u[t]&&(u[t]={});var l=null!=u?u[t]:void 0;return n?{context:u,name:t,value:l}:l}},inputs:function(e,t){return function(n,r,i,o){return o?o[t]:e(n,r,i)}}};var To=function(e,t,n){this.lexer=e,this.$filter=t,this.options=n,this.ast=new jo(e,n),this.astCompiler=n.csp?new yn(this.ast,t):new mn(this.ast,t)};To.prototype={constructor:To,parse:function(e){return this.astCompiler.compile(e)}};var Po=t("$sce"),Do={HTML:"html",CSS:"css",URL:"url",RESOURCE_URL:"resourceUrl",JS:"js"},Vo=/_([a-z])/g,Io=t("$compile"),Uo=e.document.createElement("a"),Fo=Un(e.location.href);Rn.$inject=["$document"],Ln.$inject=["$provide"];var No=22,Ro=".",zo="0";Gn.$inject=["$locale"],Xn.$inject=["$locale"];var Lo={yyyy:Qn("FullYear",4,0,!1,!0),yy:Qn("FullYear",2,0,!0,!0),y:Qn("FullYear",1,0,!1,!0),MMMM:er("Month"),MMM:er("Month",!0),MM:Qn("Month",2,1),M:Qn("Month",1,1),LLLL:er("Month",!1,!0),dd:Qn("Date",2),d:Qn("Date",1),HH:Qn("Hours",2),H:Qn("Hours",1),hh:Qn("Hours",2,-12),h:Qn("Hours",1,-12),mm:Qn("Minutes",2),m:Qn("Minutes",1),ss:Qn("Seconds",2),s:Qn("Seconds",1),sss:Qn("Milliseconds",3),EEEE:er("Day"),EEE:er("Day",!0),a:or,Z:tr,ww:ir(2),w:ir(1),G:ar,GG:ar,GGG:ar,GGGG:sr},Ho=/((?:[^yMLdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|L+|d+|H+|h+|m+|s+|a|Z|G+|w+))(.*)/,qo=/^-?\d+$/;ur.$inject=["$locale"];var Bo=g(Wr),Wo=g(Gr);dr.$inject=["$parse"];var Go=g({restrict:"E",compile:function(e,t){if(!t.href&&!t.xlinkHref)return function(e,t){if("a"===t[0].nodeName.toLowerCase()){var n="[object SVGAnimatedString]"===ri.call(t.prop("href"))?"xlink:href":"href";t.on("click",function(e){t.attr(n)||e.preventDefault()})}}}}),Xo={};r(Ri,function(e,t){function n(e,n,i){e.$watch(i[r],function(e){i.$set(t,!!e)})}if("multiple"!==e){var r=xt("ng-"+t),i=n;"checked"===e&&(i=function(e,t,i){i.ngModel!==i[r]&&n(e,t,i)}),Xo[r]=function(){return{restrict:"A",priority:100,link:i}}}}),r(Li,function(e,t){Xo[t]=function(){return{priority:100,link:function(e,n,r){if("ngPattern"===t&&"/"===r.ngPattern.charAt(0)){var i=r.ngPattern.match(Hr);if(i)return void r.$set("ngPattern",new RegExp(i[1],i[2]))}e.$watch(r[t],function(e){r.$set(t,e)})}}}}),r(["src","srcset","href"],function(e){var t=xt("ng-"+e);Xo[t]=function(){return{priority:99,link:function(n,r,i){var o=e,a=e;"href"===e&&"[object SVGAnimatedString]"===ri.call(r.prop("href"))&&(a="xlinkHref",i.$attr[a]="xlink:href",o=null),i.$observe(t,function(t){return t?(i.$set(a,t),void(Yr&&o&&r.prop(o,i[a]))):void("href"===e&&i.$set(a,null))})}}}});var Ko={$addControl:p,$$renameControl:hr,$removeControl:p,$setValidity:p,$setDirty:p,$setPristine:p,$setSubmitted:p},Yo="ng-pending",Jo="ng-submitted";gr.$inject=["$element","$attrs","$scope","$animate","$interpolate"],gr.prototype={$rollbackViewValue:function(){r(this.$$controls,function(e){e.$rollbackViewValue()})},$commitViewValue:function(){r(this.$$controls,function(e){e.$commitViewValue()})},$addControl:function(e){pe(e.$name,"input"),this.$$controls.push(e),e.$name&&(this[e.$name]=e),e.$$parentForm=this},$$renameControl:function(e,t){var n=e.$name;this[n]===e&&delete this[n],this[t]=e,e.$name=t},$removeControl:function(e){e.$name&&this[e.$name]===e&&delete this[e.$name],r(this.$pending,function(t,n){this.$setValidity(n,null,e)},this),r(this.$error,function(t,n){this.$setValidity(n,null,e)},this),r(this.$$success,function(t,n){this.$setValidity(n,null,e)},this),N(this.$$controls,e),e.$$parentForm=Ko},$setDirty:function(){this.$$animate.removeClass(this.$$element,Da),this.$$animate.addClass(this.$$element,Va),this.$dirty=!0,this.$pristine=!1,this.$$parentForm.$setDirty()},$setPristine:function(){this.$$animate.setClass(this.$$element,Da,Va+" "+Jo),this.$dirty=!1,this.$pristine=!0,this.$submitted=!1,r(this.$$controls,function(e){e.$setPristine()})},$setUntouched:function(){r(this.$$controls,function(e){e.$setUntouched()})},$setSubmitted:function(){this.$$animate.addClass(this.$$element,Jo),this.$submitted=!0,this.$$parentForm.$setSubmitted()}},vr({clazz:gr,set:function(e,t,n){var r=e[t];if(r){var i=r.indexOf(n);i===-1&&r.push(n)}else e[t]=[n]},unset:function(e,t,n){var r=e[t];r&&(N(r,n),0===r.length&&delete e[t])}});var Zo=function(e){return["$timeout","$parse",function(t,n){function r(e){return""===e?n('this[""]').assign:n(e).assign||p}var i={name:"form",restrict:e?"EAC":"E",require:["form","^^?form"],controller:gr,compile:function(n,i){n.addClass(Da).addClass(Ta);var o=i.name?"name":!(!e||!i.ngForm)&&"ngForm";return{pre:function(e,n,i,a){var s=a[0];if(!("action"in i)){var u=function(t){e.$apply(function(){s.$commitViewValue(),s.$setSubmitted()}),t.preventDefault()};n[0].addEventListener("submit",u),n.on("$destroy",function(){t(function(){n[0].removeEventListener("submit",u)},0,!1)})}var c=a[1]||s.$$parentForm;c.$addControl(s);var f=o?r(s.$name):p;o&&(f(e,s),i.$observe(o,function(t){s.$name!==t&&(f(e,void 0),s.$$parentForm.$$renameControl(s,t),(f=r(s.$name))(e,s))})),n.on("$destroy",function(){s.$$parentForm.$removeControl(s),f(e,void 0),l(s,Ko)})}}}};return i}]},Qo=Zo(),ea=Zo(!0),ta=/^\d{4,}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+(?:[+-][0-2]\d:[0-5]\d|Z)$/,na=/^[a-z][a-z\d.+-]*:\/*(?:[^:@]+(?::[^@]+)?@)?(?:[^\s:\/?#]+|\[[a-f\d:]+])(?::\d+)?(?:\/[^?#]*)?(?:\?[^#]*)?(?:#.*)?$/i,ra=/^(?=.{1,254}$)(?=.{1,64}@)[-!#$%&'*+\/0-9=?A-Z^_`a-z{|}~]+(\.[-!#$%&'*+\/0-9=?A-Z^_`a-z{|}~]+)*@[A-Za-z0-9]([A-Za-z0-9-]{0,61}[A-Za-z0-9])?(\.[A-Za-z0-9]([A-Za-z0-9-]{0,61}[A-Za-z0-9])?)*$/,ia=/^\s*(-|\+)?(\d+|(\d*(\.\d*)))([eE][+-]?\d+)?\s*$/,oa=/^(\d{4,})-(\d{2})-(\d{2})$/,aa=/^(\d{4,})-(\d\d)-(\d\d)T(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,sa=/^(\d{4,})-W(\d\d)$/,ua=/^(\d{4,})-(\d\d)$/,la=/^(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,ca="keydown wheel mousedown",fa=$e();r("date,datetime-local,month,time,week".split(","),function(e){fa[e]=!0});var da={text:br,date:kr("date",oa,_r(oa,["yyyy","MM","dd"]),"yyyy-MM-dd"),"datetime-local":kr("datetimelocal",aa,_r(aa,["yyyy","MM","dd","HH","mm","ss","sss"]),"yyyy-MM-ddTHH:mm:ss.sss"),time:kr("time",la,_r(la,["HH","mm","ss","sss"]),"HH:mm:ss.sss"),week:kr("week",sa,xr,"yyyy-Www"),month:kr("month",ua,_r(ua,["yyyy","MM"]),"yyyy-MM"),number:jr,url:Pr,email:Dr,radio:Vr,range:Tr,checkbox:Ur,hidden:p,button:p,submit:p,reset:p,file:p},pa=["$browser","$sniffer","$filter","$parse",function(e,t,n,r){return{restrict:"E",require:["?ngModel"],link:{pre:function(i,o,a,s){s[0]&&(da[Wr(a.type)]||da.text)(i,o,a,s[0],t,e,n,r)}}}}],ha=/^(true|false|\d+)$/,ga=function(){function e(e,t,n){e.prop("value",n),t.$set("value",n)}return{restrict:"A",priority:100,compile:function(t,n){return ha.test(n.ngValue)?function(t,n,r){var i=t.$eval(r.ngValue);e(n,r,i)}:function(t,n,r){t.$watch(r.ngValue,function(t){e(n,r,t)})}}}},$a=["$compile",function(e){return{restrict:"AC",compile:function(t){return e.$$addBindingClass(t),function(t,n,r){e.$$addBindingInfo(n,r.ngBind),n=n[0],t.$watch(r.ngBind,function(e){n.textContent=ve(e)})}}}}],va=["$interpolate","$compile",function(e,t){return{compile:function(n){return t.$$addBindingClass(n),function(n,r,i){var o=e(r.attr(i.$attr.ngBindTemplate));t.$$addBindingInfo(r,o.expressions),r=r[0],i.$observe("ngBindTemplate",function(e){r.textContent=v(e)?"":e})}}}}],ma=["$sce","$parse","$compile",function(e,t,n){return{restrict:"A",compile:function(r,i){var o=t(i.ngBindHtml),a=t(i.ngBindHtml,function(t){return e.valueOf(t)});return n.$$addBindingClass(r),function(t,r,i){n.$$addBindingInfo(r,i.ngBindHtml),t.$watch(a,function(){var n=o(t);r.html(e.getTrustedHtml(n)||"")})}}}}],ya=g({restrict:"A",require:"ngModel",link:function(e,t,n,r){r.$viewChangeListeners.push(function(){e.$eval(n.ngChange)})}}),ba=Fr("",!0),wa=Fr("Odd",0),xa=Fr("Even",1),_a=pr({compile:function(e,t){t.$set("ngCloak",void 0),e.removeClass("ng-cloak")}}),ka=[function(){return{restrict:"A",scope:!0,controller:"@",priority:500}}],Ea={},Sa={blur:!0,focus:!0};r("click dblclick mousedown mouseup mouseover mouseout mousemove mouseenter mouseleave keydown keyup keypress submit focus blur copy cut paste".split(" "),function(e){var t=xt("ng-"+e);Ea[t]=["$parse","$rootScope",function(n,r){return{restrict:"A",compile:function(i,o){var a=n(o[t],null,!0);return function(t,n){n.on(e,function(n){var i=function(){a(t,{$event:n})};Sa[e]&&r.$$phase?t.$evalAsync(i):t.$apply(i)})}}}}]});var Ca=["$animate","$compile",function(e,t){return{multiElement:!0,transclude:"element",priority:600,terminal:!0,restrict:"A",$$tlb:!0,link:function(n,r,i,o,a){var s,u,l;n.$watch(i.ngIf,function(n){n?u||a(function(n,o){u=o,n[n.length++]=t.$$createComment("end ngIf",i.ngIf),s={clone:n},e.enter(n,r.parent(),r)}):(l&&(l.remove(),l=null),u&&(u.$destroy(),u=null),s&&(l=ge(s.clone),e.leave(l).done(function(e){e!==!1&&(l=null)}),s=null))})}}}],Aa=["$templateRequest","$anchorScroll","$animate",function(e,t,n){return{restrict:"ECA",priority:400,terminal:!0,transclude:"element",controller:ai.noop,compile:function(r,i){var o=i.ngInclude||i.src,a=i.onload||"",s=i.autoscroll;return function(r,i,u,l,c){var f,d,p,h=0,g=function(){d&&(d.remove(),d=null),f&&(f.$destroy(),f=null),p&&(n.leave(p).done(function(e){e!==!1&&(d=null)}),d=p,p=null)};r.$watch(o,function(o){var u=function(e){e===!1||!m(s)||s&&!r.$eval(s)||t()},d=++h;o?(e(o,!0).then(function(e){if(!r.$$destroyed&&d===h){var t=r.$new();l.template=e;var s=c(t,function(e){g(),n.enter(e,null,i).done(u)});f=t,p=s,f.$emit("$includeContentLoaded",o),r.$eval(a)}},function(){r.$$destroyed||d===h&&(g(),r.$emit("$includeContentError",o))}),r.$emit("$includeContentRequested",o)):(g(),l.template=null)})}}}}],Oa=["$compile",function(t){return{restrict:"ECA",priority:-400,require:"ngInclude",link:function(n,r,i,o){return ri.call(r[0]).match(/SVG/)?(r.empty(),void t(je(o.template,e.document).childNodes)(n,function(e){r.append(e)},{futureParentElement:r})):(r.html(o.template),void t(r.contents())(n))}}}],Ma=pr({priority:450,compile:function(){return{pre:function(e,t,n){e.$eval(n.ngInit)}}}}),ja=function(){return{restrict:"A",priority:100,require:"ngModel",link:function(e,t,n,i){var o=n.ngList||", ",a="false"!==n.ngTrim,s=a?fi(o):o,u=function(e){if(!v(e)){var t=[];return e&&r(e.split(s),function(e){e&&t.push(a?fi(e):e)}),t}};i.$parsers.push(u),i.$formatters.push(function(e){if(li(e))return e.join(o)}),i.$isEmpty=function(e){return!e||!e.length}}}},Ta="ng-valid",Pa="ng-invalid",Da="ng-pristine",Va="ng-dirty",Ia="ng-untouched",Ua="ng-touched",Fa="ng-empty",Na="ng-not-empty",Ra=t("ngModel");Nr.$inject=["$scope","$exceptionHandler","$attrs","$element","$parse","$animate","$timeout","$q","$interpolate"],Nr.prototype={$$initGetterSetters:function(){if(this.$options.getOption("getterSetter")){var e=this.$$parse(this.$$attr.ngModel+"()"),t=this.$$parse(this.$$attr.ngModel+"($$$p)");this.$$ngModelGet=function(t){var n=this.$$parsedNgModel(t);return k(n)&&(n=e(t)),n},this.$$ngModelSet=function(e,n){k(this.$$parsedNgModel(e))?t(e,{$$$p:n}):this.$$parsedNgModelAssign(e,n)}}else if(!this.$$parsedNgModel.assign)throw Ra("nonassign","Expression '{0}' is non-assignable. Element: {1}",this.$$attr.ngModel,J(this.$$element))},$render:p,$isEmpty:function(e){return v(e)||""===e||null===e||e!==e},$$updateEmptyClasses:function(e){this.$isEmpty(e)?(this.$$animate.removeClass(this.$$element,Na),this.$$animate.addClass(this.$$element,Fa)):(this.$$animate.removeClass(this.$$element,Fa),this.$$animate.addClass(this.$$element,Na))},$setPristine:function(){this.$dirty=!1,this.$pristine=!0,this.$$animate.removeClass(this.$$element,Va),this.$$animate.addClass(this.$$element,Da)},$setDirty:function(){this.$dirty=!0,this.$pristine=!1,this.$$animate.removeClass(this.$$element,Da),this.$$animate.addClass(this.$$element,Va),this.$$parentForm.$setDirty()},$setUntouched:function(){this.$touched=!1,this.$untouched=!0,this.$$animate.setClass(this.$$element,Ia,Ua)},$setTouched:function(){this.$touched=!0,this.$untouched=!1,this.$$animate.setClass(this.$$element,Ua,Ia)},$rollbackViewValue:function(){this.$$timeout.cancel(this.$$pendingDebounce),this.$viewValue=this.$$lastCommittedViewValue,this.$render()},$validate:function(){if(!ui(this.$modelValue)){var e=this.$$lastCommittedViewValue,t=this.$$rawModelValue,n=this.$valid,r=this.$modelValue,i=this.$options.getOption("allowInvalid"),o=this;this.$$runValidators(t,e,function(e){i||n===e||(o.$modelValue=e?t:void 0,o.$modelValue!==r&&o.$$writeModelToScope())})}},$$runValidators:function(e,t,n){function i(){var e=c.$$parserName||"parse";return v(c.$$parserValid)?(s(e,null),!0):(c.$$parserValid||(r(c.$validators,function(e,t){s(t,null)}),r(c.$asyncValidators,function(e,t){s(t,null)})),s(e,c.$$parserValid),c.$$parserValid)}function o(){var n=!0;return r(c.$validators,function(r,i){var o=Boolean(r(e,t));n=n&&o,s(i,o)}),!!n||(r(c.$asyncValidators,function(e,t){s(t,null)}),!1)}function a(){var n=[],i=!0;r(c.$asyncValidators,function(r,o){var a=r(e,t);if(!T(a))throw Ra("nopromise","Expected asynchronous validator to return a promise but got '{0}' instead.",a);s(o,void 0),n.push(a.then(function(){s(o,!0)},function(){i=!1,s(o,!1)}))}),n.length?c.$$q.all(n).then(function(){u(i)},p):u(!0)}function s(e,t){l===c.$$currentValidationRunId&&c.$setValidity(e,t)}function u(e){l===c.$$currentValidationRunId&&n(e)}this.$$currentValidationRunId++;var l=this.$$currentValidationRunId,c=this;return i()&&o()?void a():void u(!1)},$commitViewValue:function(){var e=this.$viewValue;this.$$timeout.cancel(this.$$pendingDebounce),(this.$$lastCommittedViewValue!==e||""===e&&this.$$hasNativeValidators)&&(this.$$updateEmptyClasses(e),this.$$lastCommittedViewValue=e,this.$pristine&&this.$setDirty(),this.$$parseAndValidate())},$$parseAndValidate:function(){function e(){r.$modelValue!==o&&r.$$writeModelToScope()}var t=this.$$lastCommittedViewValue,n=t,r=this;if(this.$$parserValid=!v(n)||void 0,this.$$parserValid)for(var i=0;i<this.$parsers.length;i++)if(n=this.$parsers[i](n),v(n)){this.$$parserValid=!1;break}ui(this.$modelValue)&&(this.$modelValue=this.$$ngModelGet(this.$$scope));var o=this.$modelValue,a=this.$options.getOption("allowInvalid");this.$$rawModelValue=n,a&&(this.$modelValue=n,e()),this.$$runValidators(n,this.$$lastCommittedViewValue,function(t){a||(r.$modelValue=t?n:void 0,e())})},$$writeModelToScope:function(){this.$$ngModelSet(this.$$scope,this.$modelValue),r(this.$viewChangeListeners,function(e){try{e()}catch(t){this.$$exceptionHandler(t)}},this)},$setViewValue:function(e,t){this.$viewValue=e,this.$options.getOption("updateOnDefault")&&this.$$debounceViewValueCommit(t)},$$debounceViewValueCommit:function(e){var t=this.$options.getOption("debounce");x(t[e])?t=t[e]:x(t["default"])&&(t=t["default"]),this.$$timeout.cancel(this.$$pendingDebounce);var n=this;t>0?this.$$pendingDebounce=this.$$timeout(function(){n.$commitViewValue()},t):this.$$scope.$root.$$phase?this.$commitViewValue():this.$$scope.$apply(function(){n.$commitViewValue()})}},vr({clazz:Nr,set:function(e,t){e[t]=!0},unset:function(e,t){delete e[t]}});var za,La=["$rootScope",function(e){return{restrict:"A",require:["ngModel","^?form","^?ngModelOptions"],controller:Nr,priority:1,compile:function(t){return t.addClass(Da).addClass(Ia).addClass(Ta),{pre:function(e,t,n,r){var i=r[0],o=r[1]||i.$$parentForm,a=r[2];a&&(i.$options=a.$options),i.$$initGetterSetters(),o.$addControl(i),n.$observe("name",function(e){i.$name!==e&&i.$$parentForm.$$renameControl(i,e)}),e.$on("$destroy",function(){i.$$parentForm.$removeControl(i)})},post:function(t,n,r,i){function o(){a.$setTouched()}var a=i[0];a.$options.getOption("updateOn")&&n.on(a.$options.getOption("updateOn"),function(e){a.$$debounceViewValueCommit(e&&e.type)}),n.on("blur",function(){a.$touched||(e.$$phase?t.$evalAsync(o):t.$apply(o))})}}}}}],Ha=/(\s+|^)default(\s+|$)/;zr.prototype={getOption:function(e){return this.$$options[e]},createChild:function(e){var t=!1;return e=l({},e),r(e,function(n,r){"$inherit"===n?"*"===r?t=!0:(e[r]=this.$$options[r],"updateOn"===r&&(e.updateOnDefault=this.$$options.updateOnDefault)):"updateOn"===r&&(e.updateOnDefault=!1,e[r]=fi(n.replace(Ha,function(){return e.updateOnDefault=!0," "})))},this),t&&(delete e["*"],Lr(e,this.$$options)),Lr(e,za.$$options),new zr(e)}},za=new zr({updateOn:"",updateOnDefault:!0,debounce:0,getterSetter:!1,allowInvalid:!1,timezone:null});var qa=function(){function e(e,t){this.$$attrs=e,this.$$scope=t}return e.$inject=["$attrs","$scope"],e.prototype={$onInit:function(){var e=this.parentCtrl?this.parentCtrl.$options:za,t=this.$$scope.$eval(this.$$attrs.ngModelOptions);this.$options=e.createChild(t)}},{restrict:"A",priority:10,require:{parentCtrl:"?^^ngModelOptions"},bindToController:!0,controller:e}},Ba=pr({terminal:!0,priority:1e3}),Wa=t("ngOptions"),Ga=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+group\s+by\s+([\s\S]+?))?(?:\s+disable\s+when\s+([\s\S]+?))?\s+for\s+(?:([$\w][$\w]*)|(?:\(\s*([$\w][$\w]*)\s*,\s*([$\w][$\w]*)\s*\)))\s+in\s+([\s\S]+?)(?:\s+track\s+by\s+([\s\S]+?))?$/,Xa=["$compile","$document","$parse",function(t,i,o){function a(e,t,r){function i(e,t,n,r,i){this.selectValue=e,this.viewValue=t,this.label=n,this.group=r,this.disabled=i}function a(e){var t;if(!l&&n(e))t=e;else{t=[];for(var r in e)e.hasOwnProperty(r)&&"$"!==r.charAt(0)&&t.push(r)}return t}var s=e.match(Ga);if(!s)throw Wa("iexp","Expected expression in form of '_select_ (as _label_)? for (_key_,)?_value_ in _collection_' but got '{0}'. Element: {1}",e,J(t));var u=s[5]||s[7],l=s[6],c=/ as /.test(s[0])&&s[1],f=s[9],d=o(s[2]?s[1]:u),p=c&&o(c),h=p||d,g=f&&o(f),$=f?function(e,t){return g(r,t)}:function(e){return rt(e)},v=function(e,t){return $(e,_(e,t))},m=o(s[2]||s[1]),y=o(s[3]||""),b=o(s[4]||""),w=o(s[8]),x={},_=l?function(e,t){return x[l]=t,x[u]=e,x}:function(e){return x[u]=e,x};return{trackBy:f,getTrackByValue:v,getWatchables:o(w,function(e){var t=[];e=e||[];for(var n=a(e),i=n.length,o=0;o<i;o++){var u=e===n?o:n[o],l=e[u],c=_(l,u),f=$(l,c);if(t.push(f),s[2]||s[1]){var d=m(r,c);t.push(d)}if(s[4]){var p=b(r,c);t.push(p)}}return t}),getOptions:function(){for(var e=[],t={},n=w(r)||[],o=a(n),s=o.length,u=0;u<s;u++){var l=n===o?u:o[u],c=n[l],d=_(c,l),p=h(r,d),g=$(p,d),x=m(r,d),k=y(r,d),E=b(r,d),S=new i(g,p,x,k,E);e.push(S),t[g]=S}return{items:e,selectValueMap:t,getOptionFromViewValue:function(e){return t[v(e)]},getViewValueFromOption:function(e){return f?R(e.viewValue):e.viewValue}}}}}function s(e,n,o,s){function c(e,t){var n=u.cloneNode(!1);t.appendChild(n),d(e,n)}function f(e){var t=_.getOptionFromViewValue(e),n=t&&t.element;return n&&!n.selected&&(n.selected=!0),t}function d(e,t){e.element=t,t.disabled=e.disabled,e.label!==t.label&&(t.label=e.label,t.textContent=e.label),t.value=e.selectValue}function p(){var e=_&&h.readValue();if(_)for(var t=_.items.length-1;t>=0;t--){var r=_.items[t];Xe(m(r.group)?r.element.parentNode:r.element)}_=k.getOptions();var i={};if(w&&n.prepend(h.emptyOption),_.items.forEach(function(e){var t;m(e.group)?(t=i[e.group],t||(t=l.cloneNode(!1),E.appendChild(t),t.label=null===e.group?"null":e.group,i[e.group]=t),c(e,t)):c(e,E)}),n[0].appendChild(E),g.$render(),!g.$isEmpty(e)){var o=h.readValue(),a=k.trackBy||$;(a?z(e,o):e===o)||(g.$setViewValue(o),g.$render())}}for(var h=s[0],g=s[1],$=o.multiple,v=0,y=n.children(),b=y.length;v<b;v++)if(""===y[v].value){h.hasEmptyOption=!0,h.emptyOption=y.eq(v);break}var w=!!h.emptyOption,x=Jr(u.cloneNode(!1));x.val("?");var _,k=a(o.ngOptions,n,e),E=i[0].createDocumentFragment();h.generateUnknownOptionValue=function(e){return"?"},$?(h.writeValue=function(e){var t=e&&e.map(f)||[];_.items.forEach(function(e){e.element.selected&&!F(t,e)&&(e.element.selected=!1)})},h.readValue=function(){var e=n.val()||[],t=[];return r(e,function(e){var n=_.selectValueMap[e];n&&!n.disabled&&t.push(_.getViewValueFromOption(n))}),t},k.trackBy&&e.$watchCollection(function(){if(li(g.$viewValue))return g.$viewValue.map(function(e){return k.getTrackByValue(e)})},function(){g.$render()})):(h.writeValue=function(e){var t=_.selectValueMap[n.val()],r=_.getOptionFromViewValue(e);t&&t.element.removeAttribute("selected"),r?(n[0].value!==r.selectValue&&(h.removeUnknownOption(),h.unselectEmptyOption(),n[0].value=r.selectValue,r.element.selected=!0),r.element.setAttribute("selected","selected")):w?h.selectEmptyOption():h.unknownOption.parent().length?h.updateUnknownOption(e):h.renderUnknownOption(e)},h.readValue=function(){var e=_.selectValueMap[n.val()];return e&&!e.disabled?(h.unselectEmptyOption(),h.removeUnknownOption(),_.getViewValueFromOption(e)):null},k.trackBy&&e.$watch(function(){return k.getTrackByValue(g.$viewValue)},function(){g.$render()})),w&&(h.emptyOption.remove(),t(h.emptyOption)(e),h.emptyOption[0].nodeType===_i?(h.hasEmptyOption=!1,h.registerOption=function(e,t){""===t.val()&&(h.hasEmptyOption=!0,h.emptyOption=t,h.emptyOption.removeClass("ng-scope"),g.$render(),t.on("$destroy",function(){h.hasEmptyOption=!1,h.emptyOption=void 0}))}):h.emptyOption.removeClass("ng-scope")),n.empty(),p(),e.$watchCollection(k.getWatchables,p)}var u=e.document.createElement("option"),l=e.document.createElement("optgroup");return{restrict:"A",terminal:!0,require:["select","ngModel"],link:{pre:function(e,t,n,r){r[0].registerOption=p},post:s}}}],Ka=["$locale","$interpolate","$log",function(e,t,n){var i=/{}/g,o=/^when(Minus)?(.+)$/;return{link:function(a,s,u){function l(e){s.text(e||"")}var c,f=u.count,d=u.$attr.when&&s.attr(u.$attr.when),h=u.offset||0,g=a.$eval(d)||{},$={},m=t.startSymbol(),y=t.endSymbol(),b=m+f+"-"+h+y,w=ai.noop;r(u,function(e,t){var n=o.exec(t);if(n){var r=(n[1]?"-":"")+Wr(n[2]);g[r]=s.attr(u.$attr[t])}}),r(g,function(e,n){$[n]=t(e.replace(i,b))}),a.$watch(f,function(t){var r=parseFloat(t),i=ui(r);if(i||r in g||(r=e.pluralCat(r-h)),!(r===c||i&&ui(c))){w();var o=$[r];v(o)?(null!=t&&n.debug("ngPluralize: no rule defined for '"+r+"' in "+d),w=p,l()):w=a.$watch(o,l),c=r}})}}}],Ya=["$parse","$animate","$compile",function(e,i,o){var a="$$NG_REMOVED",s=t("ngRepeat"),u=function(e,t,n,r,i,o,a){e[n]=r,i&&(e[i]=o),e.$index=t,e.$first=0===t,e.$last=t===a-1,e.$middle=!(e.$first||e.$last),e.$odd=!(e.$even=0===(1&t))},l=function(e){return e.clone[0]},c=function(e){return e.clone[e.clone.length-1]};return{restrict:"A",multiElement:!0,transclude:"element",priority:1e3,terminal:!0,$$tlb:!0,compile:function(t,f){var d=f.ngRepeat,p=o.$$createComment("end ngRepeat",d),h=d.match(/^\s*([\s\S]+?)\s+in\s+([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+track\s+by\s+([\s\S]+?))?\s*$/);if(!h)throw s("iexp","Expected expression in form of '_item_ in _collection_[ track by _id_]' but got '{0}'.",d);var g=h[1],$=h[2],v=h[3],m=h[4];if(h=g.match(/^(?:(\s*[$\w]+)|\(\s*([$\w]+)\s*,\s*([$\w]+)\s*\))$/),!h)throw s("iidexp","'_item_' in '_item_ in _collection_' should be an identifier or '(_key_, _value_)' expression, but got '{0}'.",g);var y=h[3]||h[1],b=h[2];if(v&&(!/^[$a-zA-Z_][$a-zA-Z0-9_]*$/.test(v)||/^(null|undefined|this|\$index|\$first|\$middle|\$last|\$even|\$odd|\$parent|\$root|\$id)$/.test(v)))throw s("badident","alias '{0}' is invalid --- must be a valid JS identifier which is not a reserved name.",v);var w,x,_,k,E={$id:rt};return m?w=e(m):(_=function(e,t){return rt(t)},k=function(e){return e}),function(e,t,o,f,h){w&&(x=function(t,n,r){return b&&(E[b]=t),E[y]=n,E.$index=r,w(e,E)});var g=$e();e.$watchCollection($,function(o){var f,$,m,w,E,S,C,A,O,M,j,T,P=t[0],D=$e();if(v&&(e[v]=o),n(o))O=o,A=x||_;else{A=x||k,O=[];for(var V in o)Br.call(o,V)&&"$"!==V.charAt(0)&&O.push(V)}for(w=O.length,j=new Array(w),f=0;f<w;f++)if(E=o===O?f:O[f],S=o[E],C=A(E,S,f),g[C])M=g[C],delete g[C],D[C]=M,j[f]=M;else{if(D[C])throw r(j,function(e){e&&e.scope&&(g[e.id]=e)}),s("dupes","Duplicates in a repeater are not allowed. Use 'track by' expression to specify unique keys. Repeater: {0}, Duplicate key: {1}, Duplicate value: {2}",d,C,S);j[f]={id:C,scope:void 0,clone:void 0},D[C]=!0}for(var I in g){if(M=g[I],T=ge(M.clone),i.leave(T),T[0].parentNode)for(f=0,$=T.length;f<$;f++)T[f][a]=!0;M.scope.$destroy()}for(f=0;f<w;f++)if(E=o===O?f:O[f],S=o[E],M=j[f],M.scope){m=P;do m=m.nextSibling;while(m&&m[a]);l(M)!==m&&i.move(ge(M.clone),null,P),P=c(M),u(M.scope,f,y,S,b,E,w)}else h(function(e,t){M.scope=t;var n=p.cloneNode(!1);e[e.length++]=n,i.enter(e,null,P),P=n,M.clone=e,D[M.id]=M,u(M.scope,f,y,S,b,E,w)});g=D})}}}}],Ja="ng-hide",Za="ng-hide-animate",Qa=["$animate",function(e){return{restrict:"A",multiElement:!0,link:function(t,n,r){t.$watch(r.ngShow,function(t){e[t?"removeClass":"addClass"](n,Ja,{tempClasses:Za})})}}}],es=["$animate",function(e){return{restrict:"A",multiElement:!0,link:function(t,n,r){t.$watch(r.ngHide,function(t){e[t?"addClass":"removeClass"](n,Ja,{tempClasses:Za})})}}}],ts=pr(function(e,t,n){e.$watch(n.ngStyle,function(e,n){n&&e!==n&&r(n,function(e,n){t.css(n,"")}),e&&t.css(e)},!0)}),ns=["$animate","$compile",function(e,t){return{require:"ngSwitch",controller:["$scope",function(){this.cases={}}],link:function(n,i,o,a){var s=o.ngSwitch||o.on,u=[],l=[],c=[],f=[],d=function(e,t){return function(n){n!==!1&&e.splice(t,1)}};n.$watch(s,function(n){for(var i,o;c.length;)e.cancel(c.pop());for(i=0,o=f.length;i<o;++i){var s=ge(l[i].clone);f[i].$destroy();var p=c[i]=e.leave(s);p.done(d(c,i))}l.length=0,f.length=0,(u=a.cases["!"+n]||a.cases["?"])&&r(u,function(n){n.transclude(function(r,i){f.push(i);var o=n.element;r[r.length++]=t.$$createComment("end ngSwitchWhen");var a={clone:r};l.push(a),e.enter(r,o.parent(),o)})})})}}}],rs=pr({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(e,t,n,i,o){var a=n.ngSwitchWhen.split(n.ngSwitchWhenSeparator).sort().filter(function(e,t,n){return n[t-1]!==e});r(a,function(e){i.cases["!"+e]=i.cases["!"+e]||[],i.cases["!"+e].push({transclude:o,element:t})})}}),is=pr({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(e,t,n,r,i){r.cases["?"]=r.cases["?"]||[],r.cases["?"].push({transclude:i,element:t})}}),os=t("ngTransclude"),as=["$compile",function(e){return{restrict:"EAC",terminal:!0,compile:function(t){var n=e(t.contents());return t.empty(),function(e,t,r,i,o){function a(e,n){e.length&&u(e)?t.append(e):(s(),n.$destroy())}function s(){n(e,function(e){t.append(e)})}function u(e){for(var t=0,n=e.length;t<n;t++){var r=e[t];if(r.nodeType!==xi||r.nodeValue.trim())return!0}}if(!o)throw os("orphan","Illegal use of ngTransclude directive in the template! No parent directive that requires a transclusion found. Element: {0}",J(t));r.ngTransclude===r.$attr.ngTransclude&&(r.ngTransclude="");var l=r.ngTransclude||r.ngTranscludeSlot;o(a,null,l),l&&!o.isSlotFilled(l)&&s()}}}}],ss=["$templateCache",function(e){return{restrict:"E",terminal:!0,compile:function(t,n){if("text/ng-template"===n.type){var r=n.id,i=t[0].text;e.put(r,i)}}}}],us={$setViewValue:p,$render:p},ls=["$element","$scope",function(t,n){function r(){u||(u=!0,n.$$postDigest(function(){u=!1,a.ngModelCtrl.$render()}))}function i(e){l||(l=!0,n.$$postDigest(function(){n.$$destroyed||(l=!1,a.ngModelCtrl.$setViewValue(a.readValue()),e&&a.ngModelCtrl.$render())}))}function o(e){e.prop("selected",!0),e.attr("selected",!0)}var a=this,s=new it;a.selectValueMap={},a.ngModelCtrl=us,a.multiple=!1,a.unknownOption=Jr(e.document.createElement("option")),a.hasEmptyOption=!1,a.emptyOption=void 0,a.renderUnknownOption=function(e){var n=a.generateUnknownOptionValue(e);a.unknownOption.val(n),t.prepend(a.unknownOption),o(a.unknownOption),t.val(n)},a.updateUnknownOption=function(e){var n=a.generateUnknownOptionValue(e);a.unknownOption.val(n),o(a.unknownOption),t.val(n)},a.generateUnknownOptionValue=function(e){return"? "+rt(e)+" ?"},a.removeUnknownOption=function(){a.unknownOption.parent()&&a.unknownOption.remove()},a.selectEmptyOption=function(){a.emptyOption&&(t.val(""),o(a.emptyOption))},a.unselectEmptyOption=function(){
|
8 |
+
a.hasEmptyOption&&a.emptyOption.removeAttr("selected")},n.$on("$destroy",function(){a.renderUnknownOption=p}),a.readValue=function(){var e=t.val(),n=e in a.selectValueMap?a.selectValueMap[e]:e;return a.hasOption(n)?n:null},a.writeValue=function(e){var n=t[0].options[t[0].selectedIndex];if(n&&n.removeAttribute("selected"),a.hasOption(e)){a.removeUnknownOption();var r=rt(e);t.val(r in a.selectValueMap?r:e);var i=t[0].options[t[0].selectedIndex];o(Jr(i))}else null==e&&a.emptyOption?(a.removeUnknownOption(),a.selectEmptyOption()):a.unknownOption.parent().length?a.updateUnknownOption(e):a.renderUnknownOption(e)},a.addOption=function(e,t){if(t[0].nodeType!==_i){pe(e,'"option value"'),""===e&&(a.hasEmptyOption=!0,a.emptyOption=t);var n=s.get(e)||0;s.put(e,n+1),r()}},a.removeOption=function(e){var t=s.get(e);t&&(1===t?(s.remove(e),""===e&&(a.hasEmptyOption=!1,a.emptyOption=void 0)):s.put(e,t-1))},a.hasOption=function(e){return!!s.get(e)};var u=!1,l=!1;a.registerOption=function(e,t,n,r,o){if(n.$attr.ngValue){var s,u=NaN;n.$observe("value",function(e){var n,r=t.prop("selected");m(u)&&(a.removeOption(s),delete a.selectValueMap[u],n=!0),u=rt(e),s=e,a.selectValueMap[u]=e,a.addOption(e,t),t.attr("value",u),n&&r&&i()})}else r?n.$observe("value",function(e){a.readValue();var n,r=t.prop("selected");m(s)&&(a.removeOption(s),n=!0),s=e,a.addOption(e,t),n&&r&&i()}):o?e.$watch(o,function(e,r){n.$set("value",e);var o=t.prop("selected");r!==e&&a.removeOption(r),a.addOption(e,t),r&&o&&i()}):a.addOption(n.value,t);n.$observe("disabled",function(e){("true"===e||e&&t.prop("selected"))&&(a.multiple?i(!0):(a.ngModelCtrl.$setViewValue(null),a.ngModelCtrl.$render()))}),t.on("$destroy",function(){var e=a.readValue(),t=n.value;a.removeOption(t),a.ngModelCtrl.$render(),(a.multiple&&e&&e.indexOf(t)!==-1||e===t)&&i(!0)})}}],cs=function(){function e(e,t,n,i){var o=i[0],a=i[1];if(!a)return void(o.registerOption=p);if(o.ngModelCtrl=a,t.on("change",function(){o.removeUnknownOption(),e.$apply(function(){a.$setViewValue(o.readValue())})}),n.multiple){o.multiple=!0,o.readValue=function(){var e=[];return r(t.find("option"),function(t){if(t.selected&&!t.disabled){var n=t.value;e.push(n in o.selectValueMap?o.selectValueMap[n]:n)}}),e},o.writeValue=function(e){var n=new it(e);r(t.find("option"),function(e){e.selected=m(n.get(e.value))||m(n.get(o.selectValueMap[e.value]))})};var s,u=NaN;e.$watch(function(){u!==a.$viewValue||z(s,a.$viewValue)||(s=ye(a.$viewValue),a.$render()),u=a.$viewValue}),a.$isEmpty=function(e){return!e||0===e.length}}}function t(e,t,n,r){var i=r[1];if(i){var o=r[0];i.$render=function(){o.writeValue(i.$viewValue)}}}return{restrict:"E",require:["select","?ngModel"],controller:ls,priority:1,link:{pre:e,post:t}}},fs=["$interpolate",function(e){return{restrict:"E",priority:100,compile:function(t,n){var r,i;return m(n.ngValue)||(m(n.value)?r=e(n.value,!0):(i=e(t.text(),!0),i||n.$set("value",t.text()))),function(e,t,n){var o="$selectController",a=t.parent(),s=a.data(o)||a.parent().data(o);s&&s.registerOption(e,t,n,r,i)}}}}],ds=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,n,r){r&&(n.required=!0,r.$validators.required=function(e,t){return!n.required||!r.$isEmpty(t)},n.$observe("required",function(){r.$validate()}))}}},ps=function(){return{restrict:"A",require:"?ngModel",link:function(e,n,r,i){if(i){var o,a=r.ngPattern||r.pattern;r.$observe("pattern",function(e){if(w(e)&&e.length>0&&(e=new RegExp("^"+e+"$")),e&&!e.test)throw t("ngPattern")("noregexp","Expected {0} to be a RegExp but was {1}. Element: {2}",a,e,J(n));o=e||void 0,i.$validate()}),i.$validators.pattern=function(e,t){return i.$isEmpty(t)||v(o)||o.test(t)}}}}},hs=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,n,r){if(r){var i=-1;n.$observe("maxlength",function(e){var t=f(e);i=ui(t)?-1:t,r.$validate()}),r.$validators.maxlength=function(e,t){return i<0||r.$isEmpty(t)||t.length<=i}}}}},gs=function(){return{restrict:"A",require:"?ngModel",link:function(e,t,n,r){if(r){var i=0;n.$observe("minlength",function(e){i=f(e)||0,r.$validate()}),r.$validators.minlength=function(e,t){return r.$isEmpty(t)||t.length>=i}}}}};return e.angular.bootstrap?void(e.console&&console.log("WARNING: Tried to load angular more than once.")):(ce(),xe(ai),ai.module("ngLocale",[],["$provide",function(e){function t(e){e+="";var t=e.indexOf(".");return t==-1?0:e.length-t-1}function n(e,n){var r=n;void 0===r&&(r=Math.min(t(e),3));var i=Math.pow(10,r),o=(e*i|0)%i;return{v:r,f:o}}var r={ZERO:"zero",ONE:"one",TWO:"two",FEW:"few",MANY:"many",OTHER:"other"};e.value("$locale",{DATETIME_FORMATS:{AMPMS:["AM","PM"],DAY:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],ERANAMES:["Before Christ","Anno Domini"],ERAS:["BC","AD"],FIRSTDAYOFWEEK:6,MONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],SHORTDAY:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],SHORTMONTH:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],STANDALONEMONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],WEEKENDRANGE:[5,6],fullDate:"EEEE, MMMM d, y",longDate:"MMMM d, y",medium:"MMM d, y h:mm:ss a",mediumDate:"MMM d, y",mediumTime:"h:mm:ss a","short":"M/d/yy h:mm a",shortDate:"M/d/yy",shortTime:"h:mm a"},NUMBER_FORMATS:{CURRENCY_SYM:"$",DECIMAL_SEP:".",GROUP_SEP:",",PATTERNS:[{gSize:3,lgSize:3,maxFrac:3,minFrac:0,minInt:1,negPre:"-",negSuf:"",posPre:"",posSuf:""},{gSize:3,lgSize:3,maxFrac:2,minFrac:2,minInt:1,negPre:"-¤",negSuf:"",posPre:"¤",posSuf:""}]},id:"en-us",localeID:"en_US",pluralCat:function(e,t){var i=0|e,o=n(e,t);return 1==i&&0==o.v?r.ONE:r.OTHER}})}]),void Jr(function(){oe(e.document,ae)}))}(window),!window.angular.$$csp().noInlineStyle&&window.angular.element(document.head).prepend('<style type="text/css">@charset "UTF-8";[ng\\:cloak],[ng-cloak],[data-ng-cloak],[x-ng-cloak],.ng-cloak,.x-ng-cloak,.ng-hide:not(.ng-hide-animate){display:none !important;}ng\\:form{display:block;}.ng-animate-shim{visibility:hidden;}.ng-anchor{position:absolute;}</style>')},{}],42:[function(e,t,n){e("./angular"),t.exports=angular},{"./angular":41}],43:[function(e,t,n){!function(){function e(e,t){window.XMLHttpRequest.prototype[e]=t(window.XMLHttpRequest.prototype[e])}function t(e,t,n){try{Object.defineProperty(e,t,{get:n})}catch(r){}}if(window.FileAPI||(window.FileAPI={}),!window.XMLHttpRequest)throw"AJAX is not supported. XMLHttpRequest is not defined.";if(FileAPI.shouldLoad=!window.FormData||FileAPI.forceLoad,FileAPI.shouldLoad){var n=function(e){if(!e.__listeners){e.upload||(e.upload={}),e.__listeners=[];var t=e.upload.addEventListener;e.upload.addEventListener=function(n,r){e.__listeners[n]=r,t&&t.apply(this,arguments)}}};e("open",function(e){return function(t,r,i){n(this),this.__url=r;try{e.apply(this,[t,r,i])}catch(o){o.message.indexOf("Access is denied")>-1&&(this.__origError=o,e.apply(this,[t,"_fix_for_ie_crossdomain__",i]))}}}),e("getResponseHeader",function(e){return function(t){return this.__fileApiXHR&&this.__fileApiXHR.getResponseHeader?this.__fileApiXHR.getResponseHeader(t):null==e?null:e.apply(this,[t])}}),e("getAllResponseHeaders",function(e){return function(){return this.__fileApiXHR&&this.__fileApiXHR.getAllResponseHeaders?this.__fileApiXHR.getAllResponseHeaders():null==e?null:e.apply(this)}}),e("abort",function(e){return function(){return this.__fileApiXHR&&this.__fileApiXHR.abort?this.__fileApiXHR.abort():null==e?null:e.apply(this)}}),e("setRequestHeader",function(e){return function(t,r){if("__setXHR_"===t){n(this);var i=r(this);i instanceof Function&&i(this)}else this.__requestHeaders=this.__requestHeaders||{},this.__requestHeaders[t]=r,e.apply(this,arguments)}}),e("send",function(e){return function(){var n=this;if(arguments[0]&&arguments[0].__isFileAPIShim){var r=arguments[0],i={url:n.__url,jsonp:!1,cache:!0,complete:function(e,r){e&&angular.isString(e)&&e.indexOf("#2174")!==-1&&(e=null),n.__completed=!0,!e&&n.__listeners.load&&n.__listeners.load({type:"load",loaded:n.__loaded,total:n.__total,target:n,lengthComputable:!0}),!e&&n.__listeners.loadend&&n.__listeners.loadend({type:"loadend",loaded:n.__loaded,total:n.__total,target:n,lengthComputable:!0}),"abort"===e&&n.__listeners.abort&&n.__listeners.abort({type:"abort",loaded:n.__loaded,total:n.__total,target:n,lengthComputable:!0}),void 0!==r.status&&t(n,"status",function(){return 0===r.status&&e&&"abort"!==e?500:r.status}),void 0!==r.statusText&&t(n,"statusText",function(){return r.statusText}),t(n,"readyState",function(){return 4}),void 0!==r.response&&t(n,"response",function(){return r.response});var i=r.responseText||(e&&0===r.status&&"abort"!==e?e:void 0);t(n,"responseText",function(){return i}),t(n,"response",function(){return i}),e&&t(n,"err",function(){return e}),n.__fileApiXHR=r,n.onreadystatechange&&n.onreadystatechange(),n.onload&&n.onload()},progress:function(e){if(e.target=n,n.__listeners.progress&&n.__listeners.progress(e),n.__total=e.total,n.__loaded=e.loaded,e.total===e.loaded){var t=this;setTimeout(function(){n.__completed||(n.getAllResponseHeaders=function(){},t.complete(null,{status:204,statusText:"No Content"}))},FileAPI.noContentTimeout||1e4)}},headers:n.__requestHeaders};i.data={},i.files={};for(var o=0;o<r.data.length;o++){var a=r.data[o];null!=a.val&&null!=a.val.name&&null!=a.val.size&&null!=a.val.type?i.files[a.key]=a.val:i.data[a.key]=a.val}setTimeout(function(){if(!FileAPI.hasFlash)throw'Adode Flash Player need to be installed. To check ahead use "FileAPI.hasFlash"';n.__fileApiXHR=FileAPI.upload(i)},1)}else{if(this.__origError)throw this.__origError;e.apply(n,arguments)}}}),window.XMLHttpRequest.__isFileAPIShim=!0,window.FormData=FormData=function(){return{append:function(e,t,n){t.__isFileAPIBlobShim&&(t=t.data[0]),this.data.push({key:e,val:t,name:n})},data:[],__isFileAPIShim:!0}},window.Blob=Blob=function(e){return{data:e,__isFileAPIBlobShim:!0}}}}(),function(){function e(e){return"input"===e[0].tagName.toLowerCase()&&e.attr("type")&&"file"===e.attr("type").toLowerCase()}function t(){try{var e=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");if(e)return!0}catch(t){if(void 0!==navigator.mimeTypes["application/x-shockwave-flash"])return!0}return!1}function n(e){var t=0,n=0;if(window.jQuery)return jQuery(e).offset();if(e.offsetParent)do t+=e.offsetLeft-e.scrollLeft,n+=e.offsetTop-e.scrollTop,e=e.offsetParent;while(e);return{left:t,top:n}}if(FileAPI.shouldLoad){if(FileAPI.hasFlash=t(),FileAPI.forceLoad&&(FileAPI.html5=!1),!FileAPI.upload){var r,i,o,a,s,u=document.createElement("script"),l=document.getElementsByTagName("script");if(window.FileAPI.jsUrl)r=window.FileAPI.jsUrl;else if(window.FileAPI.jsPath)i=window.FileAPI.jsPath;else for(o=0;o<l.length;o++)if(s=l[o].src,a=s.search(/\/ng\-file\-upload[\-a-zA-z0-9\.]*\.js/),a>-1){i=s.substring(0,a+1);break}null==FileAPI.staticPath&&(FileAPI.staticPath=i),u.setAttribute("src",r||i+"FileAPI.min.js"),document.getElementsByTagName("head")[0].appendChild(u)}FileAPI.ngfFixIE=function(r,i,o){if(!t())throw'Adode Flash Player need to be installed. To check ahead use "FileAPI.hasFlash"';var a=function(){var t=i.parent();r.attr("disabled")?t&&t.removeClass("js-fileapi-wrapper"):(i.attr("__ngf_flash_")||(i.unbind("change"),i.unbind("click"),i.bind("change",function(e){s.apply(this,[e]),o.apply(this,[e])}),i.attr("__ngf_flash_","true")),t.addClass("js-fileapi-wrapper"),e(r)||(t.css("position","absolute").css("top",n(r[0]).top+"px").css("left",n(r[0]).left+"px").css("width",r[0].offsetWidth+"px").css("height",r[0].offsetHeight+"px").css("filter","alpha(opacity=0)").css("display",r.css("display")).css("overflow","hidden").css("z-index","900000").css("visibility","visible"),i.css("width",r[0].offsetWidth+"px").css("height",r[0].offsetHeight+"px").css("position","absolute").css("top","0px").css("left","0px")))};r.bind("mouseenter",a);var s=function(e){for(var t=FileAPI.getFiles(e),n=0;n<t.length;n++)void 0===t[n].size&&(t[n].size=0),void 0===t[n].name&&(t[n].name="file"),void 0===t[n].type&&(t[n].type="undefined");e.target||(e.target={}),e.target.files=t,e.target.files!==t&&(e.__files_=t),(e.__files_||e.target.files).item=function(t){return(e.__files_||e.target.files)[t]||null}}},FileAPI.disableFileInput=function(e,t){t?e.removeClass("js-fileapi-wrapper"):e.addClass("js-fileapi-wrapper")}}}(),window.FileReader||(window.FileReader=function(){var e=this,t=!1;this.listeners={},this.addEventListener=function(t,n){e.listeners[t]=e.listeners[t]||[],e.listeners[t].push(n)},this.removeEventListener=function(t,n){e.listeners[t]&&e.listeners[t].splice(e.listeners[t].indexOf(n),1)},this.dispatchEvent=function(t){var n=e.listeners[t.type];if(n)for(var r=0;r<n.length;r++)n[r].call(e,t)},this.onabort=this.onerror=this.onload=this.onloadstart=this.onloadend=this.onprogress=null;var n=function(t,n){var r={type:t,target:e,loaded:n.loaded,total:n.total,error:n.error};return null!=n.result&&(r.target.result=n.result),r},r=function(r){t||(t=!0,e.onloadstart&&e.onloadstart(n("loadstart",r)));var i;"load"===r.type?(e.onloadend&&e.onloadend(n("loadend",r)),i=n("load",r),e.onload&&e.onload(i),e.dispatchEvent(i)):"progress"===r.type?(i=n("progress",r),e.onprogress&&e.onprogress(i),e.dispatchEvent(i)):(i=n("error",r),e.onerror&&e.onerror(i),e.dispatchEvent(i))};this.readAsDataURL=function(e){FileAPI.readAsDataURL(e,r)},this.readAsText=function(e){FileAPI.readAsText(e,r)}}),!window.XMLHttpRequest||window.FileAPI&&FileAPI.shouldLoad||(window.XMLHttpRequest.prototype.setRequestHeader=function(e){return function(t,n){if("__setXHR_"===t){var r=n(this);r instanceof Function&&r(this)}else e.apply(this,arguments)}}(window.XMLHttpRequest.prototype.setRequestHeader));var r=angular.module("ngFileUpload",[]);r.version="12.2.13",r.service("UploadBase",["$http","$q","$timeout",function(e,t,n){function i(r){function i(e){l.notify&&l.notify(e),c.progressFunc&&n(function(){c.progressFunc(e)})}function o(e){return null!=r._start&&s?{loaded:e.loaded+r._start,total:r._file&&r._file.size||e.total,type:e.type,config:r,lengthComputable:!0,target:e.target}:e}function u(){e(r).then(function(e){if(s&&r._chunkSize&&!r._finished&&r._file){var t=r._file&&r._file.size||0;i({loaded:Math.min(r._end,t),total:t,config:r,type:"progress"}),a.upload(r,!0)}else r._finished&&delete r._finished,l.resolve(e)},function(e){l.reject(e)},function(e){l.notify(e)})}r.method=r.method||"POST",r.headers=r.headers||{};var l=r._deferred=r._deferred||t.defer(),c=l.promise;return r.disableProgress||(r.headers.__setXHR_=function(){return function(e){e&&e.upload&&e.upload.addEventListener&&(r.__XHR=e,r.xhrFn&&r.xhrFn(e),e.upload.addEventListener("progress",function(e){e.config=r,i(o(e))},!1),e.upload.addEventListener("load",function(e){e.lengthComputable&&(e.config=r,i(o(e)))},!1))}}),s?r._chunkSize&&r._end&&!r._finished?(r._start=r._end,r._end+=r._chunkSize,u()):r.resumeSizeUrl?e.get(r.resumeSizeUrl).then(function(e){r.resumeSizeResponseReader?r._start=r.resumeSizeResponseReader(e.data):r._start=parseInt((null==e.data.size?e.data:e.data.size).toString()),r._chunkSize&&(r._end=r._start+r._chunkSize),u()},function(e){throw e}):r.resumeSize?r.resumeSize().then(function(e){r._start=e,r._chunkSize&&(r._end=r._start+r._chunkSize),u()},function(e){throw e}):(r._chunkSize&&(r._start=0,r._end=r._start+r._chunkSize),u()):u(),c.success=function(e){return c.then(function(t){e(t.data,t.status,t.headers,r)}),c},c.error=function(e){return c.then(null,function(t){e(t.data,t.status,t.headers,r)}),c},c.progress=function(e){return c.progressFunc=e,c.then(null,null,function(t){e(t)}),c},c.abort=c.pause=function(){return r.__XHR&&n(function(){r.__XHR.abort()}),c},c.xhr=function(e){return r.xhrFn=function(t){return function(){t&&t.apply(c,arguments),e.apply(c,arguments)}}(r.xhrFn),c},a.promisesCount++,c["finally"]&&c["finally"]instanceof Function&&c["finally"](function(){a.promisesCount--}),c}function o(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}var a=this;a.promisesCount=0,this.isResumeSupported=function(){return window.Blob&&window.Blob.prototype.slice};var s=this.isResumeSupported();this.isUploadInProgress=function(){return a.promisesCount>0},this.rename=function(e,t){return e.ngfName=t,e},this.jsonBlob=function(e){null==e||angular.isString(e)||(e=JSON.stringify(e));var t=new window.Blob([e],{type:"application/json"});return t._ngfBlob=!0,t},this.json=function(e){return angular.toJson(e)},this.isFile=function(e){return null!=e&&(e instanceof window.Blob||e.flashId&&e.name&&e.size)},this.upload=function(e,t){function n(t,n){if(t._ngfBlob)return t;if(e._file=e._file||t,null!=e._start&&s){e._end&&e._end>=t.size&&(e._finished=!0,e._end=t.size);var r=t.slice(e._start,e._end||t.size);return r.name=t.name,r.ngfName=t.ngfName,e._chunkSize&&(n.append("_chunkSize",e._chunkSize),n.append("_currentChunkSize",e._end-e._start),n.append("_chunkNumber",Math.floor(e._start/e._chunkSize)),n.append("_totalSize",e._file.size)),r}return t}function r(t,i,o){if(void 0!==i)if(angular.isDate(i)&&(i=i.toISOString()),angular.isString(i))t.append(o,i);else if(a.isFile(i)){var s=n(i,t),u=o.split(",");u[1]&&(s.ngfName=u[1].replace(/^\s+|\s+$/g,""),o=u[0]),e._fileKey=e._fileKey||o,t.append(o,s,s.ngfName||s.name)}else if(angular.isObject(i)){if(i.$$ngfCircularDetection)throw"ngFileUpload: Circular reference in config.data. Make sure specified data for Upload.upload() has no circular reference: "+o;i.$$ngfCircularDetection=!0;try{for(var l in i)if(i.hasOwnProperty(l)&&"$$ngfCircularDetection"!==l){var c=null==e.objectKey?"[i]":e.objectKey;i.length&&parseInt(l)>-1&&(c=null==e.arrayKey?c:e.arrayKey),r(t,i[l],o+c.replace(/[ik]/g,l))}}finally{delete i.$$ngfCircularDetection}}else t.append(o,i)}function u(){e._chunkSize=a.translateScalars(e.resumeChunkSize),e._chunkSize=e._chunkSize?parseInt(e._chunkSize.toString()):null,e.headers=e.headers||{},e.headers["Content-Type"]=void 0,e.transformRequest=e.transformRequest?angular.isArray(e.transformRequest)?e.transformRequest:[e.transformRequest]:[],e.transformRequest.push(function(t){var n,i=new window.FormData;t=t||e.fields||{},e.file&&(t.file=e.file);for(n in t)if(t.hasOwnProperty(n)){var o=t[n];e.formDataAppender?e.formDataAppender(i,n,o):r(i,o,n)}return i})}return t||(e=o(e)),e._isDigested||(e._isDigested=!0,u()),i(e)},this.http=function(t){return t=o(t),t.transformRequest=t.transformRequest||function(t){return window.ArrayBuffer&&t instanceof window.ArrayBuffer||t instanceof window.Blob?t:e.defaults.transformRequest[0].apply(this,arguments)},t._chunkSize=a.translateScalars(t.resumeChunkSize),t._chunkSize=t._chunkSize?parseInt(t._chunkSize.toString()):null,i(t)},this.translateScalars=function(e){if(angular.isString(e)){if(e.search(/kb/i)===e.length-2)return parseFloat(1024*e.substring(0,e.length-2));if(e.search(/mb/i)===e.length-2)return parseFloat(1048576*e.substring(0,e.length-2));if(e.search(/gb/i)===e.length-2)return parseFloat(1073741824*e.substring(0,e.length-2));if(e.search(/b/i)===e.length-1)return parseFloat(e.substring(0,e.length-1));if(e.search(/s/i)===e.length-1)return parseFloat(e.substring(0,e.length-1));if(e.search(/m/i)===e.length-1)return parseFloat(60*e.substring(0,e.length-1));if(e.search(/h/i)===e.length-1)return parseFloat(3600*e.substring(0,e.length-1))}return e},this.urlToBlob=function(n){var r=t.defer();return e({url:n,method:"get",responseType:"arraybuffer"}).then(function(e){var t=new Uint8Array(e.data),i=e.headers("content-type")||"image/WebP",o=new window.Blob([t],{type:i}),a=n.match(/.*\/(.+?)(\?.*)?$/);a.length>1&&(o.name=a[1]),r.resolve(o)},function(e){r.reject(e)}),r.promise},this.setDefaults=function(e){this.defaults=e||{}},this.defaults={},this.version=r.version}]),r.service("Upload",["$parse","$timeout","$compile","$q","UploadExif",function(e,t,n,r,i){function o(e,t,n){var i=[u.emptyPromise()];return angular.forEach(e,function(r,o){0===r.type.indexOf("image/jpeg")&&u.attrGetter("ngfFixOrientation",t,n,{$file:r})&&i.push(u.happyPromise(u.applyExifRotation(r),r).then(function(t){e.splice(o,1,t)}))}),r.all(i)}function a(e,t,n,i){var o=u.attrGetter("ngfResize",t,n);if(!o||!u.isResizeSupported()||!e.length)return u.emptyPromise();if(o instanceof Function){var a=r.defer();return o(e).then(function(r){s(r,e,t,n,i).then(function(e){a.resolve(e)},function(e){a.reject(e)})},function(e){a.reject(e)})}return s(o,e,t,n,i)}function s(e,t,n,i,o){function a(r,a){if(0===r.type.indexOf("image")){if(e.pattern&&!u.validatePattern(r,e.pattern))return;e.resizeIf=function(e,t){return u.attrGetter("ngfResizeIf",n,i,{$width:e,$height:t,$file:r})};var l=u.resize(r,e);s.push(l),l.then(function(e){t.splice(a,1,e)},function(e){r.$error="resize",(r.$errorMessages=r.$errorMessages||{}).resize=!0,r.$errorParam=(e?(e.message?e.message:e)+": ":"")+(r&&r.name),o.$ngfValidations.push({name:"resize",valid:!1}),u.applyModelValidation(o,t)})}}for(var s=[u.emptyPromise()],l=0;l<t.length;l++)a(t[l],l);return r.all(s)}var u=i;return u.getAttrWithDefaults=function(e,t){if(null!=e[t])return e[t];var n=u.defaults[t];return null==n?n:angular.isString(n)?n:JSON.stringify(n)},u.attrGetter=function(t,n,r,i){var o=this.getAttrWithDefaults(n,t);if(!r)return o;try{return i?e(o)(r,i):e(o)(r)}catch(a){if(t.search(/min|max|pattern/i))return o;throw a}},u.shouldUpdateOn=function(e,t,n){var r=u.attrGetter("ngfModelOptions",t,n);return!r||!r.updateOn||r.updateOn.split(" ").indexOf(e)>-1},u.emptyPromise=function(){var e=r.defer(),n=arguments;return t(function(){e.resolve.apply(e,n)}),e.promise},u.rejectPromise=function(){var e=r.defer(),n=arguments;return t(function(){e.reject.apply(e,n)}),e.promise},u.happyPromise=function(e,n){var i=r.defer();return e.then(function(e){i.resolve(e)},function(e){t(function(){throw e}),i.resolve(n)}),i.promise},u.updateModel=function(n,r,i,s,l,c,f){function d(o,a,l,f,d){r.$$ngfPrevValidFiles=o,r.$$ngfPrevInvalidFiles=a;var p=o&&o.length?o[0]:null,h=a&&a.length?a[0]:null;n&&(u.applyModelValidation(n,o),n.$setViewValue(d?p:o)),s&&e(s)(i,{$files:o,$file:p,$newFiles:l,$duplicateFiles:f,$invalidFiles:a,$invalidFile:h,$event:c});var g=u.attrGetter("ngfModelInvalid",r);g&&t(function(){e(g).assign(i,d?h:a)}),t(function(){})}function p(){function e(e,t){return e.name===t.name&&(e.$ngfOrigSize||e.size)===(t.$ngfOrigSize||t.size)&&e.type===t.type}function t(t){var n;for(n=0;n<v.length;n++)if(e(t,v[n]))return!0;for(n=0;n<m.length;n++)if(e(t,m[n]))return!0;return!1}if(l){$=[],y=[];for(var n=0;n<l.length;n++)t(l[n])?y.push(l[n]):$.push(l[n])}}function h(e){return angular.isArray(e)?e:[e]}function g(){function e(){t(function(){d(x?v.concat(w):w,x?m.concat(b):b,l,y,_)},E&&E.debounce?E.debounce.change||E.debounce:0)}var o=k?$:w;a(o,r,i,n).then(function(){k?u.validate($,x?v.length:0,n,r,i).then(function(t){w=t.validsFiles,b=t.invalidsFiles,e()}):e()},function(){for(var t=0;t<o.length;t++){var n=o[t];if("resize"===n.$error){var r=w.indexOf(n);r>-1&&(w.splice(r,1),b.push(n)),e()}}})}var $,v,m,y=[],b=[],w=[];v=r.$$ngfPrevValidFiles||[],m=r.$$ngfPrevInvalidFiles||[],n&&n.$modelValue&&(v=h(n.$modelValue));var x=u.attrGetter("ngfKeep",r,i);$=(l||[]).slice(0),"distinct"!==x&&u.attrGetter("ngfKeepDistinct",r,i)!==!0||p(r,i);var _=!x&&!u.attrGetter("ngfMultiple",r,i)&&!u.attrGetter("multiple",r);if(!x||$.length){u.attrGetter("ngfBeforeModelChange",r,i,{$files:l,$file:l&&l.length?l[0]:null,$newFiles:$,$duplicateFiles:y,$event:c});var k=u.attrGetter("ngfValidateAfterResize",r,i),E=u.attrGetter("ngfModelOptions",r,i);u.validate($,x?v.length:0,n,r,i).then(function(e){f?d($,[],l,y,_):(E&&E.allowInvalid||k?w=$:(w=e.validFiles,b=e.invalidFiles),u.attrGetter("ngfFixOrientation",r,i)&&u.isExifSupported()?o(w,r,i).then(function(){g()}):g())})}},u}]),r.directive("ngfSelect",["$parse","$timeout","$compile","Upload",function(e,t,n,r){function i(e){var t=e.match(/Android[^\d]*(\d+)\.(\d+)/);if(t&&t.length>2){var n=r.defaults.androidFixMinorVersion||4;return parseInt(t[1])<4||parseInt(t[1])===n&&parseInt(t[2])<n}return e.indexOf("Chrome")===-1&&/.*Windows.*Safari.*/.test(e)}function o(e,t,n,r,o,s,u,l){function c(){return"input"===t[0].tagName.toLowerCase()&&n.type&&"file"===n.type.toLowerCase()}function f(){return y("ngfChange")||y("ngfSelect")}function d(t){if(l.shouldUpdateOn("change",n,e)){var i=t.__files_||t.target&&t.target.files,o=[];if(!i)return;for(var a=0;a<i.length;a++)o.push(i[a]);l.updateModel(r,n,e,f(),o.length?o:null,t)}}function p(e,r){function i(t){e.attr("id","ngf-"+t),r.attr("id","ngf-label-"+t)}for(var o=0;o<t[0].attributes.length;o++){var a=t[0].attributes[o];"type"!==a.name&&"class"!==a.name&&"style"!==a.name&&("id"===a.name?(i(a.value),b.push(n.$observe("id",i))):e.attr(a.name,a.value||"required"!==a.name&&"multiple"!==a.name?a.value:a.name))}}function h(){if(c())return t;var e=angular.element('<input type="file">'),n=angular.element("<label>upload</label>");return n.css("visibility","hidden").css("position","absolute").css("overflow","hidden").css("width","0px").css("height","0px").css("border","none").css("margin","0px").css("padding","0px").attr("tabindex","-1"),p(e,n),a.push({el:t,ref:n}),document.body.appendChild(n.append(e)[0]),e}function g(n){if(t.attr("disabled"))return!1;if(!y("ngfSelectDisabled",e)){var r=$(n);if(null!=r)return r;v(n);try{c()||document.body.contains(_[0])||(a.push({el:t,ref:_.parent()}),document.body.appendChild(_.parent()[0]),_.bind("change",d))}catch(o){}return i(navigator.userAgent)?setTimeout(function(){_[0].click()},0):_[0].click(),!1}}function $(e){var t=e.changedTouches||e.originalEvent&&e.originalEvent.changedTouches;if(t){if("touchstart"===e.type)return x=t[0].clientX,w=t[0].clientY,!0;if("touchend"===e.type){var n=t[0].clientX,r=t[0].clientY;if(Math.abs(n-x)>20||Math.abs(r-w)>20)return e.stopPropagation(),e.preventDefault(),!1}return!0}}function v(t){l.shouldUpdateOn("click",n,e)&&_.val()&&(_.val(null),l.updateModel(r,n,e,f(),null,t,!0))}function m(e){if(_&&!_.attr("__ngf_ie10_Fix_")){if(!_[0].parentNode)return void(_=null);e.preventDefault(),e.stopPropagation(),_.unbind("click");var t=_.clone();return _.replaceWith(t),_=t,_.attr("__ngf_ie10_Fix_","true"),_.bind("change",d),_.bind("click",m),_[0].click(),!1}_.removeAttr("__ngf_ie10_Fix_")}var y=function(e,t){return l.attrGetter(e,n,t)};l.registerModelChangeValidator(r,n,e);var b=[];y("ngfMultiple")&&b.push(e.$watch(y("ngfMultiple"),function(){_.attr("multiple",y("ngfMultiple",e))})),y("ngfCapture")&&b.push(e.$watch(y("ngfCapture"),function(){_.attr("capture",y("ngfCapture",e))})),y("ngfAccept")&&b.push(e.$watch(y("ngfAccept"),function(){_.attr("accept",y("ngfAccept",e))})),b.push(n.$observe("accept",function(){_.attr("accept",y("accept"))}));var w=0,x=0,_=t;c()||(_=h()),_.bind("change",d),c()?t.bind("click",v):t.bind("click touchstart touchend",g),navigator.appVersion.indexOf("MSIE 10")!==-1&&_.bind("click",m),r&&r.$formatters.push(function(e){return null!=e&&0!==e.length||_.val()&&_.val(null),e}),e.$on("$destroy",function(){c()||_.parent().remove(),angular.forEach(b,function(e){e()})}),s(function(){for(var e=0;e<a.length;e++){var t=a[e];document.body.contains(t.el[0])||(a.splice(e,1),t.ref.remove())}}),window.FileAPI&&window.FileAPI.ngfFixIE&&window.FileAPI.ngfFixIE(t,_,d)}var a=[];return{restrict:"AEC",require:"?ngModel",link:function(i,a,s,u){o(i,a,s,u,e,t,n,r)}}}]),function(){function e(e){return"img"===e.tagName.toLowerCase()?"image":"audio"===e.tagName.toLowerCase()?"audio":"video"===e.tagName.toLowerCase()?"video":/./}function t(t,n,r,i,o,a,s,u){function l(e){var a=t.attrGetter("ngfNoObjectUrl",o,r);t.dataUrl(e,a)["finally"](function(){n(function(){var t=(a?e.$ngfDataUrl:e.$ngfBlobUrl)||e.$ngfDataUrl;u?i.css("background-image","url('"+(t||"")+"')"):i.attr("src",t),t?i.removeClass("ng-hide"):i.addClass("ng-hide")})})}n(function(){var n=r.$watch(o[a],function(n){var c=s;if("ngfThumbnail"===a&&(c||(c={width:i[0].naturalWidth||i[0].clientWidth,height:i[0].naturalHeight||i[0].clientHeight}),0===c.width&&window.getComputedStyle)){var f=getComputedStyle(i[0]);f.width&&f.width.indexOf("px")>-1&&f.height&&f.height.indexOf("px")>-1&&(c={width:parseInt(f.width.slice(0,-2)),height:parseInt(f.height.slice(0,-2))})}return angular.isString(n)?(i.removeClass("ng-hide"),u?i.css("background-image","url('"+n+"')"):i.attr("src",n)):void(!n||!n.type||0!==n.type.search(e(i[0]))||u&&0!==n.type.indexOf("image")?i.addClass("ng-hide"):c&&t.isResizeSupported()?(c.resizeIf=function(e,i){return t.attrGetter("ngfResizeIf",o,r,{$width:e,$height:i,$file:n})},t.resize(n,c).then(function(e){l(e)},function(e){throw e})):l(n))});r.$on("$destroy",function(){n()})})}r.service("UploadDataUrl",["UploadBase","$timeout","$q",function(e,t,n){var r=e;return r.base64DataUrl=function(e){if(angular.isArray(e)){var t=n.defer(),i=0;return angular.forEach(e,function(n){r.dataUrl(n,!0)["finally"](function(){if(i++,i===e.length){var n=[];angular.forEach(e,function(e){n.push(e.$ngfDataUrl)}),t.resolve(n,e)}})}),t.promise}return r.dataUrl(e,!0)},r.dataUrl=function(e,i){if(!e)return r.emptyPromise(e,e);if(i&&null!=e.$ngfDataUrl||!i&&null!=e.$ngfBlobUrl)return r.emptyPromise(i?e.$ngfDataUrl:e.$ngfBlobUrl,e);var o=i?e.$$ngfDataUrlPromise:e.$$ngfBlobUrlPromise;if(o)return o;var a=n.defer();return t(function(){if(window.FileReader&&e&&(!window.FileAPI||navigator.userAgent.indexOf("MSIE 8")===-1||e.size<2e4)&&(!window.FileAPI||navigator.userAgent.indexOf("MSIE 9")===-1||e.size<4e6)){var n=window.URL||window.webkitURL;if(n&&n.createObjectURL&&!i){var o;try{o=n.createObjectURL(e)}catch(s){return void t(function(){e.$ngfBlobUrl="",a.reject()})}t(function(){if(e.$ngfBlobUrl=o,o){a.resolve(o,e),r.blobUrls=r.blobUrls||[],r.blobUrlsTotalSize=r.blobUrlsTotalSize||0,r.blobUrls.push({url:o,size:e.size}),r.blobUrlsTotalSize+=e.size||0;for(var t=r.defaults.blobUrlsMaxMemory||268435456,i=r.defaults.blobUrlsMaxQueueSize||200;(r.blobUrlsTotalSize>t||r.blobUrls.length>i)&&r.blobUrls.length>1;){var s=r.blobUrls.splice(0,1)[0];n.revokeObjectURL(s.url),r.blobUrlsTotalSize-=s.size}}})}else{var u=new FileReader;u.onload=function(n){t(function(){e.$ngfDataUrl=n.target.result,a.resolve(n.target.result,e),t(function(){delete e.$ngfDataUrl},1e3)})},u.onerror=function(){t(function(){e.$ngfDataUrl="",a.reject()})},u.readAsDataURL(e)}}else t(function(){e[i?"$ngfDataUrl":"$ngfBlobUrl"]="",a.reject()})}),o=i?e.$$ngfDataUrlPromise=a.promise:e.$$ngfBlobUrlPromise=a.promise,o["finally"](function(){delete e[i?"$$ngfDataUrlPromise":"$$ngfBlobUrlPromise"]}),o},r}]),r.directive("ngfSrc",["Upload","$timeout",function(e,n){return{restrict:"AE",link:function(r,i,o){t(e,n,r,i,o,"ngfSrc",e.attrGetter("ngfResize",o,r),!1)}}}]),r.directive("ngfBackground",["Upload","$timeout",function(e,n){return{restrict:"AE",link:function(r,i,o){t(e,n,r,i,o,"ngfBackground",e.attrGetter("ngfResize",o,r),!0)}}}]),r.directive("ngfThumbnail",["Upload","$timeout",function(e,n){return{restrict:"AE",link:function(r,i,o){var a=e.attrGetter("ngfSize",o,r);t(e,n,r,i,o,"ngfThumbnail",a,e.attrGetter("ngfAsBackground",o,r))}}}]),r.config(["$compileProvider",function(e){e.imgSrcSanitizationWhitelist&&e.imgSrcSanitizationWhitelist(/^\s*(https?|ftp|mailto|tel|webcal|local|file|data|blob):/),e.aHrefSanitizationWhitelist&&e.aHrefSanitizationWhitelist(/^\s*(https?|ftp|mailto|tel|webcal|local|file|data|blob):/)}]),r.filter("ngfDataUrl",["UploadDataUrl","$sce",function(e,t){return function(n,r,i){if(angular.isString(n))return t.trustAsResourceUrl(n);var o=n&&((r?n.$ngfDataUrl:n.$ngfBlobUrl)||n.$ngfDataUrl);return n&&!o?(!n.$ngfDataUrlFilterInProgress&&angular.isObject(n)&&(n.$ngfDataUrlFilterInProgress=!0,e.dataUrl(n,r)),""):(n&&delete n.$ngfDataUrlFilterInProgress,(n&&o?i?t.trustAsResourceUrl(o):o:n)||"")}}])}(),r.service("UploadValidate",["UploadDataUrl","$q","$timeout",function(e,t,n){function r(e){var t="",n=[];if(e.length>2&&"/"===e[0]&&"/"===e[e.length-1])t=e.substring(1,e.length-1);else{var i=e.split(",");if(i.length>1)for(var o=0;o<i.length;o++){
|
9 |
+
var a=r(i[o]);a.regexp?(t+="("+a.regexp+")",o<i.length-1&&(t+="|")):n=n.concat(a.excludes)}else 0===e.indexOf("!")?n.push("^((?!"+r(e.substring(1)).regexp+").)*$"):(0===e.indexOf(".")&&(e="*"+e),t="^"+e.replace(new RegExp("[.\\\\+*?\\[\\^\\]$(){}=!<>|:\\-]","g"),"\\$&")+"$",t=t.replace(/\\\*/g,".*").replace(/\\\?/g,"."))}return{regexp:t,excludes:n}}function i(e,t){null==t||e.$dirty||(e.$setDirty?e.$setDirty():e.$dirty=!0)}var o=e;return o.validatePattern=function(e,t){if(!t)return!0;var n=r(t),i=!0;if(n.regexp&&n.regexp.length){var o=new RegExp(n.regexp,"i");i=null!=e.type&&o.test(e.type)||null!=e.name&&o.test(e.name)}for(var a=n.excludes.length;a--;){var s=new RegExp(n.excludes[a],"i");i=i&&(null==e.type||s.test(e.type))&&(null==e.name||s.test(e.name))}return i},o.ratioToFloat=function(e){var t=e.toString(),n=t.search(/[x:]/i);return t=n>-1?parseFloat(t.substring(0,n))/parseFloat(t.substring(n+1)):parseFloat(t)},o.registerModelChangeValidator=function(e,t,n){e&&e.$formatters.push(function(r){if(e.$dirty){var i=r;r&&!angular.isArray(r)&&(i=[r]),o.validate(i,0,e,t,n).then(function(){o.applyModelValidation(e,i)})}return r})},o.applyModelValidation=function(e,t){i(e,t),angular.forEach(e.$ngfValidations,function(t){e.$setValidity(t.name,t.valid)})},o.getValidationAttr=function(e,t,n,r,i){var a="ngf"+n[0].toUpperCase()+n.substr(1),s=o.attrGetter(a,e,t,{$file:i});if(null==s&&(s=o.attrGetter("ngfValidate",e,t,{$file:i}))){var u=(r||n).split(".");s=s[u[0]],u.length>1&&(s=s&&s[u[1]])}return s},o.validate=function(e,n,r,i,a){function s(t,n,s){if(e){for(var u=e.length,l=null;u--;){var p=e[u];if(p){var h=o.getValidationAttr(i,a,t,n,p);null!=h&&(s(p,h,u)||(c.indexOf(t)===-1?(p.$error=t,(p.$errorMessages=p.$errorMessages||{})[t]=!0,p.$errorParam=h,d.indexOf(p)===-1&&d.push(p),f||e.splice(u,1),l=!1):e.splice(u,1)))}}null!==l&&r.$ngfValidations.push({name:t,valid:l})}}function u(n,s,u,p,h){function g(t,r,i){function o(o){if(o())if(c.indexOf(n)===-1){if(r.$error=n,(r.$errorMessages=r.$errorMessages||{})[n]=!0,r.$errorParam=i,d.indexOf(r)===-1&&d.push(r),!f){var a=e.indexOf(r);a>-1&&e.splice(a,1)}t.resolve(!1)}else{var s=e.indexOf(r);s>-1&&e.splice(s,1),t.resolve(!0)}else t.resolve(!0)}null!=i?p(r,i).then(function(e){o(function(){return!h(e,i)})},function(){o(function(){return l("ngfValidateForce",{$file:r})})}):t.resolve(!0)}var $=[o.emptyPromise(!0)];e&&(e=void 0===e.length?[e]:e,angular.forEach(e,function(e){var r=t.defer();return $.push(r.promise),!u||null!=e.type&&0===e.type.search(u)?void("dimensions"===n&&null!=o.attrGetter("ngfDimensions",i)?o.imageDimensions(e).then(function(t){g(r,e,l("ngfDimensions",{$file:e,$width:t.width,$height:t.height}))},function(){r.resolve(!1)}):"duration"===n&&null!=o.attrGetter("ngfDuration",i)?o.mediaDuration(e).then(function(t){g(r,e,l("ngfDuration",{$file:e,$duration:t}))},function(){r.resolve(!1)}):g(r,e,o.getValidationAttr(i,a,n,s,e))):void r.resolve(!0)}));var v=t.defer();return t.all($).then(function(e){for(var t=!0,i=0;i<e.length;i++)if(!e[i]){t=!1;break}r.$ngfValidations.push({name:n,valid:t}),v.resolve(t)}),v.promise}r=r||{},r.$ngfValidations=r.$ngfValidations||[],angular.forEach(r.$ngfValidations,function(e){e.valid=!0});var l=function(e,t){return o.attrGetter(e,i,a,t)},c=(o.attrGetter("ngfIgnoreInvalid",i,a)||"").split(" "),f=o.attrGetter("ngfRunAllValidations",i,a);if(null==e||0===e.length)return o.emptyPromise({validFiles:e,invalidFiles:[]});e=void 0===e.length?[e]:e.slice(0);var d=[];s("pattern",null,o.validatePattern),s("minSize","size.min",function(e,t){return e.size+.1>=o.translateScalars(t)}),s("maxSize","size.max",function(e,t){return e.size-.1<=o.translateScalars(t)});var p=0;if(s("maxTotalSize",null,function(t,n){return p+=t.size,!(p>o.translateScalars(n))||(e.splice(0,e.length),!1)}),s("validateFn",null,function(e,t){return t===!0||null===t||""===t}),!e.length)return o.emptyPromise({validFiles:[],invalidFiles:d});var h=t.defer(),g=[];return g.push(u("maxHeight","height.max",/image/,this.imageDimensions,function(e,t){return e.height<=t})),g.push(u("minHeight","height.min",/image/,this.imageDimensions,function(e,t){return e.height>=t})),g.push(u("maxWidth","width.max",/image/,this.imageDimensions,function(e,t){return e.width<=t})),g.push(u("minWidth","width.min",/image/,this.imageDimensions,function(e,t){return e.width>=t})),g.push(u("dimensions",null,/image/,function(e,t){return o.emptyPromise(t)},function(e){return e})),g.push(u("ratio",null,/image/,this.imageDimensions,function(e,t){for(var n=t.toString().split(","),r=!1,i=0;i<n.length;i++)Math.abs(e.width/e.height-o.ratioToFloat(n[i]))<.01&&(r=!0);return r})),g.push(u("maxRatio","ratio.max",/image/,this.imageDimensions,function(e,t){return e.width/e.height-o.ratioToFloat(t)<1e-4})),g.push(u("minRatio","ratio.min",/image/,this.imageDimensions,function(e,t){return e.width/e.height-o.ratioToFloat(t)>-1e-4})),g.push(u("maxDuration","duration.max",/audio|video/,this.mediaDuration,function(e,t){return e<=o.translateScalars(t)})),g.push(u("minDuration","duration.min",/audio|video/,this.mediaDuration,function(e,t){return e>=o.translateScalars(t)})),g.push(u("duration",null,/audio|video/,function(e,t){return o.emptyPromise(t)},function(e){return e})),g.push(u("validateAsyncFn",null,null,function(e,t){return t},function(e){return e===!0||null===e||""===e})),t.all(g).then(function(){if(f)for(var t=0;t<e.length;t++){var r=e[t];r.$error&&e.splice(t--,1)}f=!1,s("maxFiles",null,function(e,t,r){return n+r<t}),h.resolve({validFiles:e,invalidFiles:d})}),h.promise},o.imageDimensions=function(e){if(e.$ngfWidth&&e.$ngfHeight){var r=t.defer();return n(function(){r.resolve({width:e.$ngfWidth,height:e.$ngfHeight})}),r.promise}if(e.$ngfDimensionPromise)return e.$ngfDimensionPromise;var i=t.defer();return n(function(){return 0!==e.type.indexOf("image")?void i.reject("not image"):void o.dataUrl(e).then(function(t){function r(){var t=s[0].naturalWidth||s[0].clientWidth,n=s[0].naturalHeight||s[0].clientHeight;s.remove(),e.$ngfWidth=t,e.$ngfHeight=n,i.resolve({width:t,height:n})}function o(){s.remove(),i.reject("load error")}function a(){n(function(){s[0].parentNode&&(s[0].clientWidth?r():u++>10?o():a())},1e3)}var s=angular.element("<img>").attr("src",t).css("visibility","hidden").css("position","fixed").css("max-width","none !important").css("max-height","none !important");s.on("load",r),s.on("error",o);var u=0;a(),angular.element(document.getElementsByTagName("body")[0]).append(s)},function(){i.reject("load error")})}),e.$ngfDimensionPromise=i.promise,e.$ngfDimensionPromise["finally"](function(){delete e.$ngfDimensionPromise}),e.$ngfDimensionPromise},o.mediaDuration=function(e){if(e.$ngfDuration){var r=t.defer();return n(function(){r.resolve(e.$ngfDuration)}),r.promise}if(e.$ngfDurationPromise)return e.$ngfDurationPromise;var i=t.defer();return n(function(){return 0!==e.type.indexOf("audio")&&0!==e.type.indexOf("video")?void i.reject("not media"):void o.dataUrl(e).then(function(t){function r(){var t=s[0].duration;e.$ngfDuration=t,s.remove(),i.resolve(t)}function o(){s.remove(),i.reject("load error")}function a(){n(function(){s[0].parentNode&&(s[0].duration?r():u>10?o():a())},1e3)}var s=angular.element(0===e.type.indexOf("audio")?"<audio>":"<video>").attr("src",t).css("visibility","none").css("position","fixed");s.on("loadedmetadata",r),s.on("error",o);var u=0;a(),angular.element(document.body).append(s)},function(){i.reject("load error")})}),e.$ngfDurationPromise=i.promise,e.$ngfDurationPromise["finally"](function(){delete e.$ngfDurationPromise}),e.$ngfDurationPromise},o}]),r.service("UploadResize",["UploadValidate","$q",function(e,t){var n=e,r=function(e,t,n,r,i){var o=i?Math.max(n/e,r/t):Math.min(n/e,r/t);return{width:e*o,height:t*o,marginX:e*o-n,marginY:t*o-r}},i=function(e,i,o,a,s,u,l,c){var f=t.defer(),d=document.createElement("canvas"),p=document.createElement("img");return p.setAttribute("style","visibility:hidden;position:fixed;z-index:-100000"),document.body.appendChild(p),p.onload=function(){var e=p.width,t=p.height;if(p.parentNode.removeChild(p),null!=c&&c(e,t)===!1)return void f.reject("resizeIf");try{if(u){var h=n.ratioToFloat(u),g=e/t;g<h?(i=e,o=i/h):(o=t,i=o*h)}i||(i=e),o||(o=t);var $=r(e,t,i,o,l);d.width=Math.min($.width,i),d.height=Math.min($.height,o);var v=d.getContext("2d");v.drawImage(p,Math.min(0,-$.marginX/2),Math.min(0,-$.marginY/2),$.width,$.height),f.resolve(d.toDataURL(s||"image/WebP",a||.934))}catch(m){f.reject(m)}},p.onerror=function(){p.parentNode.removeChild(p),f.reject()},p.src=e,f.promise};return n.dataUrltoBlob=function(e,t,n){for(var r=e.split(","),i=r[0].match(/:(.*?);/)[1],o=atob(r[1]),a=o.length,s=new Uint8Array(a);a--;)s[a]=o.charCodeAt(a);var u=new window.Blob([s],{type:i});return u.name=t,u.$ngfOrigSize=n,u},n.isResizeSupported=function(){var e=document.createElement("canvas");return window.atob&&e.getContext&&e.getContext("2d")&&window.Blob},n.isResizeSupported()&&Object.defineProperty(window.Blob.prototype,"name",{get:function(){return this.$ngfName},set:function(e){this.$ngfName=e},configurable:!0}),n.resize=function(e,r){if(0!==e.type.indexOf("image"))return n.emptyPromise(e);var o=t.defer();return n.dataUrl(e,!0).then(function(t){i(t,r.width,r.height,r.quality,r.type||e.type,r.ratio,r.centerCrop,r.resizeIf).then(function(i){if("image/jpeg"===e.type&&r.restoreExif!==!1)try{i=n.restoreExif(t,i)}catch(a){setTimeout(function(){throw a},1)}try{var s=n.dataUrltoBlob(i,e.name,e.size);o.resolve(s)}catch(a){o.reject(a)}},function(t){"resizeIf"===t&&o.resolve(e),o.reject(t)})},function(e){o.reject(e)}),o.promise},n}]),function(){function e(e,n,r,i,o,a,s,u,l,c){function f(){return n.attr("disabled")||m("ngfDropDisabled",e)}function d(t,n,r){if(t){var i;try{i=t&&t.getData&&t.getData("text/html")}catch(o){}$(t.items,t.files,m("ngfAllowDir",e)!==!1,m("multiple")||m("ngfMultiple",e)).then(function(e){e.length?p(e,n):h(r,i).then(function(e){p(e,n)})})}}function p(t,n){u.updateModel(i,r,e,m("ngfChange")||m("ngfDrop"),t,n)}function h(t,n){if(!u.shouldUpdateOn(t,r,e)||"string"!=typeof n)return u.rejectPromise([]);var i=[];n.replace(/<(img src|img [^>]* src) *=\"([^\"]*)\"/gi,function(e,t,n){i.push(n)});var o=[],a=[];if(i.length){angular.forEach(i,function(e){o.push(u.urlToBlob(e).then(function(e){a.push(e)}))});var s=c.defer();return c.all(o).then(function(){s.resolve(a)},function(e){s.reject(e)}),s.promise}return u.emptyPromise()}function g(e,t,n,r){var i=m("ngfDragOverClass",e,{$event:n}),o="dragover";if(angular.isString(i))o=i;else if(i&&(i.delay&&(x=i.delay),i.accept||i.reject)){var a=n.dataTransfer.items;if(null!=a&&a.length)for(var s=i.pattern||m("ngfPattern",e,{$event:n}),l=a.length;l--;){if(!u.validatePattern(a[l],s)){o=i.reject;break}o=i.accept}else o=i.accept}r(o)}function $(t,n,i,o){function a(e,t){var n=c.defer();if(null!=e)if(e.isDirectory){var r=[u.emptyPromise()];if(d){var i={type:"directory"};i.name=i.path=(t||"")+e.name,p.push(i)}var o=e.createReader(),s=[],g=function(){o.readEntries(function(i){try{i.length?(s=s.concat(Array.prototype.slice.call(i||[],0)),g()):(angular.forEach(s.slice(0),function(n){p.length<=l&&h<=f&&r.push(a(n,(t?t:"")+e.name+"/"))}),c.all(r).then(function(){n.resolve()},function(e){n.reject(e)}))}catch(o){n.reject(o)}},function(e){n.reject(e)})};g()}else e.file(function(e){try{e.path=(t?t:"")+e.name,d&&(e=u.rename(e,e.path)),p.push(e),h+=e.size,n.resolve()}catch(r){n.reject(r)}},function(e){n.reject(e)});return n.promise}var l=u.getValidationAttr(r,e,"maxFiles");null==l&&(l=Number.MAX_VALUE);var f=u.getValidationAttr(r,e,"maxTotalSize");null==f&&(f=Number.MAX_VALUE);var d=m("ngfIncludeDir",e),p=[],h=0,g=[u.emptyPromise()];if(t&&t.length>0&&"file:"!==s.location.protocol)for(var $=0;$<t.length;$++){if(t[$].webkitGetAsEntry&&t[$].webkitGetAsEntry()&&t[$].webkitGetAsEntry().isDirectory){var v=t[$].webkitGetAsEntry();if(v.isDirectory&&!i)continue;null!=v&&g.push(a(v))}else{var y=t[$].getAsFile();null!=y&&(p.push(y),h+=y.size)}if(p.length>l||h>f||!o&&p.length>0)break}else if(null!=n)for(var b=0;b<n.length;b++){var w=n.item(b);if((w.type||w.size>0)&&(p.push(w),h+=w.size),p.length>l||h>f||!o&&p.length>0)break}var x=c.defer();return c.all(g).then(function(){if(o||d||!p.length)x.resolve(p);else{for(var e=0;p[e]&&"directory"===p[e].type;)e++;x.resolve([p[e]])}},function(e){x.reject(e)}),x.promise}var v=t(),m=function(e,t,n){return u.attrGetter(e,r,t,n)};if(m("dropAvailable")&&a(function(){e[m("dropAvailable")]?e[m("dropAvailable")].value=v:e[m("dropAvailable")]=v}),!v)return void(m("ngfHideOnDropNotAvailable",e)===!0&&n.css("display","none"));null==m("ngfSelect")&&u.registerModelChangeValidator(i,r,e);var y,b=null,w=o(m("ngfStopPropagation")),x=1;n[0].addEventListener("dragover",function(t){if(!f()&&u.shouldUpdateOn("drop",r,e)){if(t.preventDefault(),w(e)&&t.stopPropagation(),navigator.userAgent.indexOf("Chrome")>-1){var i=t.dataTransfer.effectAllowed;t.dataTransfer.dropEffect="move"===i||"linkMove"===i?"move":"copy"}a.cancel(b),y||(y="C",g(e,r,t,function(r){y=r,n.addClass(y),m("ngfDrag",e,{$isDragging:!0,$class:y,$event:t})}))}},!1),n[0].addEventListener("dragenter",function(t){!f()&&u.shouldUpdateOn("drop",r,e)&&(t.preventDefault(),w(e)&&t.stopPropagation())},!1),n[0].addEventListener("dragleave",function(t){!f()&&u.shouldUpdateOn("drop",r,e)&&(t.preventDefault(),w(e)&&t.stopPropagation(),b=a(function(){y&&n.removeClass(y),y=null,m("ngfDrag",e,{$isDragging:!1,$event:t})},x||100))},!1),n[0].addEventListener("drop",function(t){!f()&&u.shouldUpdateOn("drop",r,e)&&(t.preventDefault(),w(e)&&t.stopPropagation(),y&&n.removeClass(y),y=null,d(t.dataTransfer,t,"dropUrl"))},!1),n[0].addEventListener("paste",function(t){navigator.userAgent.toLowerCase().indexOf("firefox")>-1&&m("ngfEnableFirefoxPaste",e)&&t.preventDefault(),!f()&&u.shouldUpdateOn("paste",r,e)&&d(t.clipboardData||t.originalEvent.clipboardData,t,"pasteUrl")},!1),navigator.userAgent.toLowerCase().indexOf("firefox")>-1&&m("ngfEnableFirefoxPaste",e)&&(n.attr("contenteditable",!0),n.on("keypress",function(e){e.metaKey||e.ctrlKey||e.preventDefault()}))}function t(){var e=document.createElement("div");return"draggable"in e&&"ondrop"in e&&!/Edge\/12./i.test(navigator.userAgent)}r.directive("ngfDrop",["$parse","$timeout","$window","Upload","$http","$q",function(t,n,r,i,o,a){return{restrict:"AEC",require:"?ngModel",link:function(s,u,l,c){e(s,u,l,c,t,n,r,i,o,a)}}}]),r.directive("ngfNoFileDrop",function(){return function(e,n){t()&&n.css("display","none")}}),r.directive("ngfDropAvailable",["$parse","$timeout","Upload",function(e,n,r){return function(i,o,a){if(t()){var s=e(r.attrGetter("ngfDropAvailable",a));n(function(){s(i),s.assign&&s.assign(i,!0)})}}}])}(),r.service("UploadExif",["UploadResize","$q",function(e,t){function n(e,t,n,r){switch(t){case 2:return e.transform(-1,0,0,1,n,0);case 3:return e.transform(-1,0,0,-1,n,r);case 4:return e.transform(1,0,0,-1,0,r);case 5:return e.transform(0,1,1,0,0,0);case 6:return e.transform(0,1,-1,0,r,0);case 7:return e.transform(0,-1,-1,0,r,n);case 8:return e.transform(0,-1,1,0,0,n)}}function r(e){for(var t="",n=new Uint8Array(e),r=n.byteLength,i=0;i<r;i++)t+=String.fromCharCode(n[i]);return window.btoa(t)}var i=e;return i.isExifSupported=function(){return window.FileReader&&(new FileReader).readAsArrayBuffer&&i.isResizeSupported()},i.readOrientation=function(e){var n=t.defer(),r=new FileReader,i=e.slice?e.slice(0,65536):e;return r.readAsArrayBuffer(i),r.onerror=function(e){return n.reject(e)},r.onload=function(e){var t={orientation:1},r=new DataView(this.result);if(65496!==r.getUint16(0,!1))return n.resolve(t);for(var i=r.byteLength,o=2;o<i;){var a=r.getUint16(o,!1);if(o+=2,65505===a){if(1165519206!==r.getUint32(o+=2,!1))return n.resolve(t);var s=18761===r.getUint16(o+=6,!1);o+=r.getUint32(o+4,s);var u=r.getUint16(o,s);o+=2;for(var l=0;l<u;l++)if(274===r.getUint16(o+12*l,s)){var c=r.getUint16(o+12*l+8,s);return c>=2&&c<=8&&(r.setUint16(o+12*l+8,1,s),t.fixedArrayBuffer=e.target.result),t.orientation=c,n.resolve(t)}}else{if(65280!==(65280&a))break;o+=r.getUint16(o,!1)}}return n.resolve(t)},n.promise},i.applyExifRotation=function(e){if(0!==e.type.indexOf("image/jpeg"))return i.emptyPromise(e);var o=t.defer();return i.readOrientation(e).then(function(t){return t.orientation<2||t.orientation>8?o.resolve(e):void i.dataUrl(e,!0).then(function(a){var s=document.createElement("canvas"),u=document.createElement("img");u.onload=function(){try{s.width=t.orientation>4?u.height:u.width,s.height=t.orientation>4?u.width:u.height;var a=s.getContext("2d");n(a,t.orientation,u.width,u.height),a.drawImage(u,0,0);var l=s.toDataURL(e.type||"image/WebP",.934);l=i.restoreExif(r(t.fixedArrayBuffer),l);var c=i.dataUrltoBlob(l,e.name);o.resolve(c)}catch(f){return o.reject(f)}},u.onerror=function(){o.reject()},u.src=a},function(e){o.reject(e)})},function(e){o.reject(e)}),o.promise},i.restoreExif=function(e,t){var n={};return n.KEY_STR="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n.encode64=function(e){var t,n,r,i,o,a="",s="",u="",l=0;do t=e[l++],n=e[l++],s=e[l++],r=t>>2,i=(3&t)<<4|n>>4,o=(15&n)<<2|s>>6,u=63&s,isNaN(n)?o=u=64:isNaN(s)&&(u=64),a=a+this.KEY_STR.charAt(r)+this.KEY_STR.charAt(i)+this.KEY_STR.charAt(o)+this.KEY_STR.charAt(u),t=n=s="",r=i=o=u="";while(l<e.length);return a},n.restore=function(e,t){e.match("data:image/jpeg;base64,")&&(e=e.replace("data:image/jpeg;base64,",""));var n=this.decode64(e),r=this.slice2Segments(n),i=this.exifManipulation(t,r);return"data:image/jpeg;base64,"+this.encode64(i)},n.exifManipulation=function(e,t){var n=this.getExifArray(t),r=this.insertExif(e,n);return new Uint8Array(r)},n.getExifArray=function(e){for(var t,n=0;n<e.length;n++)if(t=e[n],255===t[0]&225===t[1])return t;return[]},n.insertExif=function(e,t){var n=e.replace("data:image/jpeg;base64,",""),r=this.decode64(n),i=r.indexOf(255,3),o=r.slice(0,i),a=r.slice(i),s=o;return s=s.concat(t),s=s.concat(a)},n.slice2Segments=function(e){for(var t=0,n=[];;){if(255===e[t]&218===e[t+1])break;if(255===e[t]&216===e[t+1])t+=2;else{var r=256*e[t+2]+e[t+3],i=t+r+2,o=e.slice(t,i);n.push(o),t=i}if(t>e.length)break}return n},n.decode64=function(e){var t,n,r,i,o,a="",s="",u=0,l=[],c=/[^A-Za-z0-9\+\/\=]/g;c.exec(e)&&console.log("There were invalid base64 characters in the input text.\nValid base64 characters are A-Z, a-z, 0-9, NaNExpect errors in decoding."),e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");do r=this.KEY_STR.indexOf(e.charAt(u++)),i=this.KEY_STR.indexOf(e.charAt(u++)),o=this.KEY_STR.indexOf(e.charAt(u++)),s=this.KEY_STR.indexOf(e.charAt(u++)),t=r<<2|i>>4,n=(15&i)<<4|o>>2,a=(3&o)<<6|s,l.push(t),64!==o&&l.push(n),64!==s&&l.push(a),t=n=a="",r=i=o=s="";while(u<e.length);return l},n.restore(e,t)},i}])},{}],44:[function(e,t,n){e("./dist/ng-file-upload-all"),t.exports="ngFileUpload"},{"./dist/ng-file-upload-all":43}]},{},[37]);
|
js/jpibfi.client.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function t(e,n,i){function r(a,u){if(!n[a]){if(!e[a]){var s="function"==typeof require&&require;if(!u&&s)return s(a,!0);if(o)return o(a,!0);var c=new Error("Cannot find module '"+a+"'");throw c.code="MODULE_NOT_FOUND",c}var l=n[a]={exports:{}};e[a][0].call(l.exports,function(t){var n=e[a][1][t];return r(n?n:t)},l,l.exports,t,e,n,i)}return n[a].exports}for(var o="function"==typeof require&&require,a=0;a<i.length;a++)r(i[a]);return r}({1:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),o=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.siteTitle,r=void 0===n?"":n;i(this,t),this.desc_funcs={img_title:function(t){return t.attr("title")},img_alt:function(t){return t.attr("alt")},post_title:function(t){return t.attr("data-jpibfi-post-title")},post_excerpt:function(t){return t.attr("data-jpibfi-post-excerpt")},img_description:function(t){return t.attr("data-jpibfi-description")},img_caption:function(t){return t.attr("data-jpibfi-caption")},site_title:function(){return r}}}return r(t,[{key:"getDescription",value:function(t,e){for(var n="",i=0;i<e.length&&!n;i++)n=this.desc_funcs[e[i]](t);return n||""}}]),t}();n["default"]=o},{}],2:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),a=t("./link-generator"),u=i(a),s=function(){function t(e,n){r(this,t),this.$=e,this.settings=n,this.linkGenerator=new u["default"](n),this.$element=this.$("<a />",{target:"_blank","class":"pinit-button "+n.pin_image});var i="default"===n.pin_image?"jpibfi-icon-"+n.pin_image_icon:"";this.$element.html('<span class="'+i+'"></span>'),"default"===n.pin_image&&this.$element.addClass("jpibfi-size-"+n.pin_image_size+" jpibfi-button-"+n.pin_image_button),this.size={height:n.pinImageHeight,width:n.pinImageWidth}}return o(t,[{key:"createButton",value:function(t){var e=this.$element.clone(!1);return e.attr("href",this.linkGenerator.generate(t)).click(function(t){t.preventDefault(),t.stopPropagation(),"#"!==t.currentTarget.href.slice(-1)&&window.open(t.currentTarget.href,"mw"+t.timeStamp,"left=20,top=20,width=500,height=500,toolbar=1,resizable=0")}),{$element:e,size:this.size}}}]),t}();n["default"]=s},{"./link-generator":5}],3:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),o=function(){function t(e){var n=this;i(this,t),this.settings=e,this.disabledClasses=this.createClassList(e.disabled_classes),this.enabledClasses=this.createClassList(e.enabled_classes),this.updateSizeConstraints(),window.addEventListener("resize",function(){return n.updateSizeConstraints()},!1)}return r(t,[{key:"createClassList",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return t.split(";").filter(function(t){return!!t})}},{key:"imageEligible",value:function(t){return this.enabledClasses.every(function(e){return t.hasClass(e)})&&!this.disabledClasses.some(function(e){return t.hasClass(e)})&&this.imageSizeIsOk(t)}},{key:"imageSizeIsOk",value:function(t){var e=t[0].clientWidth,n=t[0].clientHeight;return e>=this.minWidth&&n>=this.minHeight}},{key:"updateSizeConstraints",value:function(){this.minWidth=window.outerWidth<768?this.settings.min_image_width_small:this.settings.min_image_width,this.minHeight=window.outerWidth<768?this.settings.min_image_height_small:this.settings.min_image_height}}]),t}();n["default"]=o},{}],4:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),a=t("./show-on-hover-strategy"),u=i(a),s=function(){function t(e,n,i){r(this,t),this.settings=n,this.$=e,this.logger=i}return o(t,[{key:"init",value:function(){this.showStrategy=this.getStrategy(),this.showStrategy.start()}},{key:"getStrategy",value:function(){var t=null;return new(t=u["default"])(this.$,this.settings,this.logger)}}]),t}();n["default"]=s},{"./show-on-hover-strategy":7}],5:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),a=t("./../common/description-helper"),u=i(a),s=function(){function t(e){r(this,t),this.descriptionHelper=new u["default"]({siteTitle:e.siteTitle}),this.pinLinkedImages=e.pinLinkedImages,this.description_option=e.description_option,this.desc_funcs={img_title:function(t){return t.attr("title")},img_alt:function(t){return t.attr("alt")},post_title:function(t){return t.attr("data-jpibfi-post-title")},img_description:function(t){return t.attr("data-jpibfi-description")},img_caption:function(t){return t.attr("data-jpibfi-caption")},site_title:function(){return e.siteTitle}}}return o(t,[{key:"getDescription",value:function(t){return this.descriptionHelper.getDescription(t,this.description_option)}},{key:"getImage",value:function(t){var e=t.prop?t.prop("src"):t.attr("src");if(!this.pinLinkedImages)return e;var n=t.closest("a");if(0===n.length)return e;var i=e.split(".").pop(),r=n.attr("href"),o=r.split(".").pop();return o.toLowerCase()===i.toLowerCase()?r:e}},{key:"getUrl",value:function(t){return t.attr("data-jpibfi-post-url")||window.location.href}},{key:"generate",value:function(t){var e=encodeURIComponent(this.getDescription(t)),n=encodeURIComponent(this.getUrl(t)),i=encodeURIComponent(this.getImage(t));return"http://pinterest.com/pin/create/bookmarklet/?is_video=false&url="+n+"&media="+i+"&description="+e}}]),t}();n["default"]=s},{"./../common/description-helper":1}],6:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),o=function(t,e,n,i){return t.top+i.top},a=function(t,e,n,i){return t.left+i.left},u=function(t,e,n,i){return e.top-n.height-i.bottom},s=function(t,e,n,i){return e.left-i.right-n.width},c=function(t,e,n){return t.top+((e.top-t.top)/2-n.height/2)},l=function(t,e,n){return t.left+((e.left-t.left)/2-n.width/2)},f=function(){function t(e,n){i(this,t),this.topF=e,this.leftF=n}return r(t,[{key:"calculate",value:function(t,e,n,i){return{top:this.topF(t,e,n,i),left:this.leftF(t,e,n,i)}}}]),t}(),p=function(){function t(e,n){i(this,t),this.margins=n,this.positionCalculator=this.getPositionCalculator(e)}return r(t,[{key:"getPositionCalculator",value:function(t){switch(t){case"top-left":return new f(o,a);case"top-right":return new f(o,s);case"bottom-left":return new f(u,a);case"bottom-right":return new f(u,s);case"center":default:return new f(c,l)}}},{key:"calculatePosition",value:function(t,e,n){return this.positionCalculator.calculate(t,e,n,this.margins)}}]),t}();n["default"]=p},{}],7:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(n,"__esModule",{value:!0});var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),s=t("./show-strategy"),c=i(s),l=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return a(e,t),u(e,[{key:"init",value:function(){var t=this,e=function(){return t.$(".jpibfi").closest("div").addClass("jpibfi_container")};e()}},{key:"start",value:function(){var t=this;this.init();var e="data-jpibfi-timeout",n=0,i=function(e){return t.$("a.pinit-button["+t.indexerAttr+'="'+e+'"]')},r=this;r.$(document).delegate(this.settings.image_selector,"mouseenter",function(){var t=r.$(this);if(r.imageFilter.imageEligible(t)){t.addClass("pinit-hover");var o=t.attr(r.indexerAttr);o||(o=n++,t.attr(r.indexerAttr,o));var a=i(o);0===a.length?!function(){var n=r.buttonGenerator.createButton(t),i=n.$element,a=n.size,u=t.offset(),s={top:u.top+t[0].clientHeight,left:u.left+t[0].clientWidth},c=r.positioner.calculatePosition(u,s,a);t.after(i),i.attr(r.indexerAttr,o).css("visibility","hidden").show().offset(c).css("visibility","visible").hover(function(){return clearTimeout(i.attr(e))},function(){return i.attr(e,setTimeout(function(){t.removeClass("pinit-hover"),i.remove()},100))})}():clearTimeout(a.attr(e))}}),r.$(document).delegate(this.settings.image_selector,"mouseleave",function(){var t=r.$(this),n=t.attr(r.indexerAttr);if(n){var o=i(n);o.attr(e,setTimeout(function(){t.removeClass("pinit-hover"),o.remove()},100))}})}}]),e}(c["default"]);n["default"]=l},{"./show-strategy":8}],8:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=t("./image-filter"),a=i(o),u=t("./button-generator"),s=i(u),c=t("./positioner"),l=i(c),f=function p(t,e,n){r(this,p),this.$=t,this.settings=e,this.logger=n,this.imageFilter=new a["default"](e),this.buttonGenerator=new s["default"](t,e);var i={left:e.button_margin_left,top:e.button_margin_top,right:e.button_margin_right,bottom:e.button_margin_bottom};this.positioner=new l["default"](e.button_position,i),this.indexerAttr="data-jpibfi-indexer"};n["default"]=f},{"./button-generator":2,"./image-filter":3,"./positioner":6}],9:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}var r=t("./settings"),o=i(r),a=t("./logger"),u=i(a),s=t("./hover"),c=i(s);!function(t){var e=window.jpibfi_options,n=new o["default"](t.extend({pageUrl:document.URL,pageTitle:document.title,pageDescription:t('meta[name="description"]').attr("content")||""},e.hover)),i=new u["default"](/[?&]jpibfi_debug=/.test(location.search));i.logObject(n);var r=function(){var e=new c["default"](t,n,i);e.init()};t(document).ready(r)}(jQuery)},{"./hover":4,"./logger":10,"./settings":11}],10:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),o=function(){function t(e){var n=this;i(this,t);var r=e&&"undefined"!=typeof console&&"undefined"!=typeof console.log,o="undefined"!=typeof JSON&&"function"==typeof JSON.stringify;r?(this.logString=function(t){n.log(t)},this.logObject=o?function(t){n.log(JSON.stringify(t,null,4))}:function(t){return n.simplelogObject(t)}):(this.logString=function(){},this.logObject=function(){})}return r(t,[{key:"log",value:function(t){console.log("jpibfi debug: "+t)}},{key:"simplelogObject",value:function(t){var e=Object.keys(t).filter(function(e){return t.hasOwnPrototype(e)}).map(function(e){return e+": "+t[e]+"\n"}).join();this.log(e)}}]),t}();n["default"]=o},{}],11:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function o(t){var e=this;i(this,o),Object.keys(t).forEach(function(n){e[n]=t[n]}),this.isTouchDevice="ontouchstart"in window||{}.hasOwnProperty.call(navigator,"maxTouchPoints")};n["default"]=r},{}]},{},[9]);
|
1 |
+
!function t(e,n,i){function r(a,u){if(!n[a]){if(!e[a]){var s="function"==typeof require&&require;if(!u&&s)return s(a,!0);if(o)return o(a,!0);var l=new Error("Cannot find module '"+a+"'");throw l.code="MODULE_NOT_FOUND",l}var c=n[a]={exports:{}};e[a][0].call(c.exports,function(t){var n=e[a][1][t];return r(n?n:t)},c,c.exports,t,e,n,i)}return n[a].exports}for(var o="function"==typeof require&&require,a=0;a<i.length;a++)r(i[a]);return r}({1:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),o=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.siteTitle,r=void 0===n?"":n;i(this,t),this.desc_funcs={img_title:function(t){return t.attr("title")},img_alt:function(t){return t.attr("alt")},post_title:function(t){return t.attr("data-jpibfi-post-title")},post_excerpt:function(t){return t.attr("data-jpibfi-post-excerpt")},img_description:function(t){return t.attr("data-jpibfi-description")},img_caption:function(t){return t.attr("data-jpibfi-caption")},site_title:function(){return r}}}return r(t,[{key:"getDescription",value:function(t,e){for(var n="",i=0;i<e.length&&!n;i++)n=this.desc_funcs[e[i]](t);return n||""}}]),t}();n["default"]=o},{}],2:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),o=function(){function t(e){var n=this;i(this,t),this.flags={},this.pluginName=e;var r="undefined"!=typeof console&&"undefined"!=typeof console.log,o="undefined"!=typeof JSON&&"function"==typeof JSON.stringify;r?(this.logString=function(t){n.log(t)},this.logObject=o?function(t){n.log(JSON.stringify(t,null,4))}:function(t){return n.simplelogObject(t)}):(this.logString=function(){},this.logObject=function(){})}return r(t,[{key:"getFlag",value:function(t){return!!this.flags[t]}},{key:"log",value:function(t){this.getFlag("print")&&console.log(this.pluginName+" debug: "+t)}},{key:"setFlag",value:function(t){this.flags[t]=!0}},{key:"simplelogObject",value:function(t){if(this.getFlag("print")){var e=Object.keys(t).filter(function(e){return t.hasOwnPrototype(e)}).map(function(e){return e+": "+t[e]+"\n"}).join();this.log(e)}}}]),t}();n["default"]=o},{}],3:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),a=t("./link-generator"),u=i(a),s=function(){function t(e,n){r(this,t),this.$=e,this.settings=n,this.linkGenerator=new u["default"](n),this.$element=this.$("<a />",{target:"_blank","class":"pinit-button "+n.pin_image});var i="default"===n.pin_image?"jpibfi-icon-"+n.pin_image_icon:"";this.$element.html('<span class="'+i+'"></span>'),"default"===n.pin_image&&this.$element.addClass("jpibfi-size-"+n.pin_image_size+" jpibfi-button-"+n.pin_image_button),this.size={height:n.pinImageHeight,width:n.pinImageWidth}}return o(t,[{key:"createButton",value:function(t){var e=this.$element.clone(!1);return e.attr("href",this.linkGenerator.generate(t)).click(function(t){t.preventDefault(),t.stopPropagation(),"#"!==t.currentTarget.href.slice(-1)&&window.open(t.currentTarget.href,"mw"+t.timeStamp,"left=20,top=20,width=500,height=500,toolbar=1,resizable=0")}),{$element:e,size:this.size}}}]),t}();n["default"]=s},{"./link-generator":6}],4:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),o=function(){function t(e){var n=this;i(this,t),this.settings=e,this.disabledClasses=this.createClassList(e.disabled_classes),this.enabledClasses=this.createClassList(e.enabled_classes),this.updateSizeConstraints(),window.addEventListener("resize",function(){return n.updateSizeConstraints()},!1)}return r(t,[{key:"createClassList",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return t.split(";").filter(function(t){return!!t})}},{key:"imageEligible",value:function(t){return this.enabledClasses.every(function(e){return t.hasClass(e)})&&!this.disabledClasses.some(function(e){return t.hasClass(e)})&&this.imageSizeIsOk(t)}},{key:"imageSizeIsOk",value:function(t){var e=t[0].clientWidth,n=t[0].clientHeight;return e>=this.minWidth&&n>=this.minHeight}},{key:"updateSizeConstraints",value:function(){this.minWidth=window.outerWidth<768?this.settings.min_image_width_small:this.settings.min_image_width,this.minHeight=window.outerWidth<768?this.settings.min_image_height_small:this.settings.min_image_height}}]),t}();n["default"]=o},{}],5:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),a=t("./show-on-hover-strategy"),u=i(a),s=function(){function t(e,n,i){r(this,t),this.settings=n,this.$=e,this.logger=i}return o(t,[{key:"init",value:function(){this.showStrategy=this.getStrategy(),this.showStrategy.start()}},{key:"getStrategy",value:function(){var t=null;return new(t=u["default"])(this.$,this.settings,this.logger)}}]),t}();n["default"]=s},{"./show-on-hover-strategy":8}],6:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),a=t("./../common/description-helper"),u=i(a),s=function(){function t(e){r(this,t),this.descriptionHelper=new u["default"]({siteTitle:e.siteTitle}),this.pinLinkedImages=e.pinLinkedImages,this.description_option=e.description_option,this.desc_funcs={img_title:function(t){return t.attr("title")},img_alt:function(t){return t.attr("alt")},post_title:function(t){return t.attr("data-jpibfi-post-title")},img_description:function(t){return t.attr("data-jpibfi-description")},img_caption:function(t){return t.attr("data-jpibfi-caption")},site_title:function(){return e.siteTitle}}}return o(t,[{key:"getDescription",value:function(t){return this.descriptionHelper.getDescription(t,this.description_option)}},{key:"getImage",value:function(t){var e=t.prop?t.prop("src"):t.attr("src");if(!this.pinLinkedImages)return e;var n=t.closest("a");if(0===n.length)return e;var i=e.split(".").pop(),r=n.attr("href"),o=r.split(".").pop();return o.toLowerCase()===i.toLowerCase()?r:e}},{key:"getUrl",value:function(t){return t.attr("data-jpibfi-post-url")||window.location.href}},{key:"generate",value:function(t){var e=encodeURIComponent(this.getDescription(t)),n=encodeURIComponent(this.getUrl(t)),i=encodeURIComponent(this.getImage(t));return"http://pinterest.com/pin/create/bookmarklet/?is_video=false&url="+n+"&media="+i+"&description="+e}}]),t}();n["default"]=s},{"./../common/description-helper":1}],7:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),o=function(t,e,n,i){return t.top+i.top},a=function(t,e,n,i){return t.left+i.left},u=function(t,e,n,i){return e.top-n.height-i.bottom},s=function(t,e,n,i){return e.left-i.right-n.width},l=function(t,e,n){return t.top+((e.top-t.top)/2-n.height/2)},c=function(t,e,n){return t.left+((e.left-t.left)/2-n.width/2)},f=function(){function t(e,n){i(this,t),this.topF=e,this.leftF=n}return r(t,[{key:"calculate",value:function(t,e,n,i){return{top:this.topF(t,e,n,i),left:this.leftF(t,e,n,i)}}}]),t}(),p=function(){function t(e,n){i(this,t),this.margins=n,this.positionCalculator=this.getPositionCalculator(e)}return r(t,[{key:"getPositionCalculator",value:function(t){switch(t){case"top-left":return new f(o,a);case"top-right":return new f(o,s);case"bottom-left":return new f(u,a);case"bottom-right":return new f(u,s);case"center":default:return new f(l,c)}}},{key:"calculatePosition",value:function(t,e,n){return this.positionCalculator.calculate(t,e,n,this.margins)}}]),t}();n["default"]=p},{}],8:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(n,"__esModule",{value:!0});var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}(),s=t("./show-strategy"),l=i(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return a(e,t),u(e,[{key:"init",value:function(){var t=this,e=function(){return t.$(".jpibfi").closest("div").addClass("jpibfi_container")};e()}},{key:"start",value:function(){var t=this;this.init();var e="data-jpibfi-timeout",n=0,i=function(e){return t.$("a.pinit-button["+t.indexerAttr+'="'+e+'"]')},r=this;r.$(document).delegate(this.settings.image_selector,"mouseenter",function(){var t=r.$(this);if(r.imageFilter.imageEligible(t)){t.addClass("pinit-hover");var o=t.attr(r.indexerAttr);o||(o=n++,t.attr(r.indexerAttr,o));var a=i(o);0===a.length?!function(){var n=r.buttonGenerator.createButton(t),i=n.$element,a=n.size,u=t.offset(),s={top:u.top+t[0].clientHeight,left:u.left+t[0].clientWidth},l=r.positioner.calculatePosition(u,s,a);t.after(i),i.attr(r.indexerAttr,o).css("visibility","hidden").show().offset(l).css("visibility","visible").hover(function(){return clearTimeout(i.attr(e))},function(){return i.attr(e,setTimeout(function(){t.removeClass("pinit-hover"),i.remove()},100))})}():clearTimeout(a.attr(e))}}),r.$(document).delegate(this.settings.image_selector,"mouseleave",function(){if(!r.logger.getFlag("prevent_hide")){var t=r.$(this),n=t.attr(r.indexerAttr);if(n){var o=i(n);o.attr(e,setTimeout(function(){t.removeClass("pinit-hover"),o.remove()},100))}}})}}]),e}(l["default"]);n["default"]=c},{"./show-strategy":9}],9:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=t("./image-filter"),a=i(o),u=t("./button-generator"),s=i(u),l=t("./positioner"),c=i(l),f=function p(t,e,n){r(this,p),this.$=t,this.settings=e,this.logger=n,this.imageFilter=new a["default"](e),this.buttonGenerator=new s["default"](t,e);var i={left:e.button_margin_left,top:e.button_margin_top,right:e.button_margin_right,bottom:e.button_margin_bottom};this.positioner=new c["default"](e.button_position,i),this.indexerAttr="data-jpibfi-indexer"};n["default"]=f},{"./button-generator":3,"./image-filter":4,"./positioner":7}],10:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}var r=t("./settings"),o=i(r),a=t("./debugger"),u=i(a),s=t("./hover"),l=i(s);!function(t){var e=window.jpibfi_options,n=new o["default"](t.extend({pageUrl:document.URL,pageTitle:document.title,pageDescription:t('meta[name="description"]').attr("content")||""},e.hover)),i=new u["default"]("jpibfi");window.jpibfi_debugger=i;var r=function(){var e=new l["default"](t,n,i);e.init()};t(document).ready(r)}(jQuery)},{"./debugger":2,"./hover":5,"./settings":11}],11:[function(t,e,n){"use strict";function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=function o(t){var e=this;i(this,o),Object.keys(t).forEach(function(n){e[n]=t[n]}),this.isTouchDevice="ontouchstart"in window||{}.hasOwnProperty.call(navigator,"maxTouchPoints")};n["default"]=r},{}]},{},[10]);
|
languages/jquery-pin-it-button-for-images.pot
CHANGED
@@ -14,36 +14,141 @@ msgstr ""
|
|
14 |
"X-Poedit-SearchPath-0: .\n"
|
15 |
"X-Poedit-SearchPathExcluded-0: *.js\n"
|
16 |
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
17 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
18 |
msgid "Settings"
|
19 |
msgstr ""
|
20 |
|
21 |
-
#: includes/admin/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
22 |
msgid "Documentation"
|
23 |
msgstr ""
|
24 |
|
25 |
-
#: includes/admin/
|
|
|
|
|
|
|
|
|
26 |
msgid "Support"
|
27 |
msgstr ""
|
28 |
|
29 |
-
#: includes/admin/
|
30 |
-
msgid "
|
31 |
msgstr ""
|
32 |
|
33 |
-
#: includes/admin/
|
34 |
-
msgid "
|
35 |
msgstr ""
|
36 |
|
37 |
-
#: includes/admin/
|
38 |
-
msgid "
|
39 |
msgstr ""
|
40 |
|
41 |
-
#: includes/admin/jpibfi-admin.php:
|
42 |
-
msgid "
|
43 |
msgstr ""
|
44 |
|
45 |
-
#: includes/admin/
|
46 |
-
msgid "
|
|
|
|
|
|
|
|
|
47 |
msgstr ""
|
48 |
|
49 |
#: includes/admin/settings/jpibfi-advanced-settings.php:25
|
@@ -74,44 +179,108 @@ msgstr ""
|
|
74 |
msgid "post_thumbnail_html priority"
|
75 |
msgstr ""
|
76 |
|
77 |
-
#: includes/admin/settings/jpibfi-import-export-settings.php:
|
78 |
msgid "The file did not upload properly. Please try again."
|
79 |
msgstr ""
|
80 |
|
81 |
-
#: includes/admin/settings/jpibfi-import-export-settings.php:
|
82 |
msgid "The export file could not be found at <code>%s</code>. It is likely that this was caused by a permissions problem."
|
83 |
msgstr ""
|
84 |
|
85 |
-
#: includes/admin/settings/jpibfi-import-export-settings.php:
|
86 |
msgid "The path is not a file, please try again."
|
87 |
msgstr ""
|
88 |
|
89 |
-
#: includes/admin/settings/jpibfi-import-export-settings.php:
|
90 |
msgid "Export"
|
91 |
msgstr ""
|
92 |
|
93 |
-
#: includes/admin/settings/jpibfi-import-export-settings.php:
|
94 |
msgid "Download Export File"
|
95 |
msgstr ""
|
96 |
|
97 |
-
#: includes/admin/settings/jpibfi-import-export-settings.php:
|
98 |
msgid "Import"
|
99 |
msgstr ""
|
100 |
|
101 |
-
#: includes/admin/settings/jpibfi-import-export-settings.php:
|
102 |
msgid "Import Settings"
|
103 |
msgstr ""
|
104 |
|
105 |
-
#: includes/admin/settings/jpibfi-
|
106 |
-
msgid "
|
107 |
msgstr ""
|
108 |
|
109 |
-
#: includes/admin/settings/jpibfi-
|
110 |
-
msgid "
|
111 |
msgstr ""
|
112 |
|
113 |
-
#: includes/admin/settings/jpibfi-
|
114 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
115 |
msgstr ""
|
116 |
|
117 |
#: includes/admin/settings/jpibfi-selection-settings.php:49
|
@@ -150,94 +319,62 @@ msgstr ""
|
|
150 |
msgid "jQuery selector for all the images that should have the \"Pin it\" button. Set the value to %s if you want the \"Pin it\" button to appear only on images in content or %s to appear on all images on site (including sidebar, header and footer). If you know a thing or two about jQuery, you might use your own selector. %sClick here%s to read about jQuery selectors."
|
151 |
msgstr ""
|
152 |
|
153 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
154 |
msgid "Disabled classes"
|
155 |
msgstr ""
|
156 |
|
157 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
158 |
msgid "Images with these CSS classes won't show the \"Pin it\" button. Please separate multiple classes with semicolons. Spaces are not accepted."
|
159 |
msgstr ""
|
160 |
|
161 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
162 |
msgid "Enabled classes"
|
163 |
msgstr ""
|
164 |
|
165 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
166 |
msgid "Only images with these CSS classes will show the \"Pin it\" button. Please separate multiple classes with semicolons. If this field is empty, images with any (besides disabled ones) classes will show the Pin It button."
|
167 |
msgstr ""
|
168 |
|
169 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
170 |
msgid "Height"
|
171 |
msgstr ""
|
172 |
|
173 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
174 |
msgid "Minimum image height"
|
175 |
msgstr ""
|
176 |
|
177 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
178 |
msgid "Width"
|
179 |
msgstr ""
|
180 |
|
181 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
182 |
msgid "Minimum image width"
|
183 |
msgstr ""
|
184 |
|
185 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
186 |
msgid "Minimum image height for mobile"
|
187 |
msgstr ""
|
188 |
|
189 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
190 |
msgid "Minimum image width for mobile"
|
191 |
msgstr ""
|
192 |
|
193 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
194 |
msgid "Show on"
|
195 |
msgstr ""
|
196 |
|
197 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
198 |
msgid "Disable on"
|
199 |
msgstr ""
|
200 |
|
201 |
-
#: includes/admin/settings/jpibfi-selection-settings.php:
|
202 |
msgid "Disable plugin on this post"
|
203 |
msgstr ""
|
204 |
|
205 |
-
#: includes/admin/settings/jpibfi-settings-base.php:
|
206 |
-
msgid "Error"
|
207 |
-
msgstr ""
|
208 |
-
|
209 |
-
#: includes/admin/settings/jpibfi-settings-base.php:109
|
210 |
-
msgid "Save Changes"
|
211 |
-
msgstr ""
|
212 |
-
|
213 |
-
#: includes/admin/settings/jpibfi-settings-base.php:113
|
214 |
msgid "This feature is available in <a target=\"_blank\" href=\"%s\">the PRO version</a>."
|
215 |
msgstr ""
|
216 |
|
217 |
-
#: includes/admin/settings/jpibfi-settings-base.php:231
|
218 |
-
msgid "Settings not saved."
|
219 |
-
msgstr ""
|
220 |
-
|
221 |
-
#: includes/admin/settings/jpibfi-settings-base.php:253
|
222 |
-
msgid "Settings saved."
|
223 |
-
msgstr ""
|
224 |
-
|
225 |
-
#: includes/admin/settings/jpibfi-validator.php:137, includes/admin/settings/jpibfi-validator.php:159
|
226 |
-
msgid "%1$s value is not a number."
|
227 |
-
msgstr ""
|
228 |
-
|
229 |
-
#: includes/admin/settings/jpibfi-validator.php:181
|
230 |
-
msgid "%1$s value is less than the minimum value of %2$s."
|
231 |
-
msgstr ""
|
232 |
-
|
233 |
-
#: includes/admin/settings/jpibfi-validator.php:195
|
234 |
-
msgid "%1$s value is greater than the minimum value of %2$s."
|
235 |
-
msgstr ""
|
236 |
-
|
237 |
-
#: includes/admin/settings/jpibfi-validator.php:215, includes/admin/settings/jpibfi-validator.php:251
|
238 |
-
msgid "%1$s value is invalid."
|
239 |
-
msgstr ""
|
240 |
-
|
241 |
#: includes/admin/settings/jpibfi-visual-settings.php:23
|
242 |
msgid "\"Pin it\" button margins"
|
243 |
msgstr ""
|
@@ -522,6 +659,6 @@ msgstr ""
|
|
522 |
msgid "Transparency value must be a number between %.02d and %.02f."
|
523 |
msgstr ""
|
524 |
|
525 |
-
#: jquery-pin-it-button-for-images.php:
|
526 |
msgid "You have two versions of jQuery Pin It Button for Images installed. Please deactivate and remove one of them."
|
527 |
msgstr ""
|
14 |
"X-Poedit-SearchPath-0: .\n"
|
15 |
"X-Poedit-SearchPathExcluded-0: *.js\n"
|
16 |
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
17 |
+
|
18 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:49, includes/admin/JPIBFI_Welcome_Screen.php:51
|
19 |
+
msgid "Welcome to jQuery Pin It Button for Images"
|
20 |
+
msgstr ""
|
21 |
+
|
22 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:77
|
23 |
+
msgid "Welcome to %s %s"
|
24 |
+
msgstr ""
|
25 |
+
|
26 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:81
|
27 |
+
msgid "Thank you for updating to the latest version! %s helps your readers share your images using Pinterest."
|
28 |
+
msgstr ""
|
29 |
+
|
30 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:91, includes/admin/jpibfi-admin.php:73, includes/admin/settings/jpibfi-visual-settings.php:39
|
31 |
msgid "Settings"
|
32 |
msgstr ""
|
33 |
|
34 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:93
|
35 |
+
msgid "The most important part of the plugin is the settings panel."
|
36 |
+
msgstr ""
|
37 |
+
|
38 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:103
|
39 |
+
msgid "Finding the settings panel"
|
40 |
+
msgstr ""
|
41 |
+
|
42 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:105
|
43 |
+
msgid "You can find the plugin's settings panel in the <b>Settings</b> submenu under the name <b>%s</b>. There you can find all the settings the plugin allows you to adjust. All settings are divided into several tabs so you can find what you're looking for easily."
|
44 |
+
msgstr ""
|
45 |
+
|
46 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:119
|
47 |
+
msgid "Settings link"
|
48 |
+
msgstr ""
|
49 |
+
|
50 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:127
|
51 |
+
msgid "Everything at hand"
|
52 |
+
msgstr ""
|
53 |
+
|
54 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:129
|
55 |
+
msgid "You can find all the links mentioned below in the settings panel."
|
56 |
+
msgstr ""
|
57 |
+
|
58 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:135
|
59 |
+
msgid "Settings tabs"
|
60 |
+
msgstr ""
|
61 |
+
|
62 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:145, includes/admin/settings/jpibfi-selection-settings.php:47
|
63 |
+
msgid "Selection settings"
|
64 |
+
msgstr ""
|
65 |
+
|
66 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:147
|
67 |
+
msgid "In this tab you choose which images should feature the \"Pin it\" button. You can choose images with specific classes or set up a minimum image resolution to prevent the button from showing up on small images. You can also choose on which pages the \"Pin it\" button should show up."
|
68 |
+
msgstr ""
|
69 |
+
|
70 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:149
|
71 |
+
msgid "<a href=\"%s\" class=\"button button-primary\">Go to Selection settings</a>"
|
72 |
+
msgstr ""
|
73 |
+
|
74 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:155
|
75 |
+
msgid "Visual settings"
|
76 |
+
msgstr ""
|
77 |
+
|
78 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:157
|
79 |
+
msgid "This tab helps you configure how the \"Pin it\" button looks like and where it appears. If you want to use your own \"Pin it\" icon or make the button show up in the upper right corner of the image, this is the tab you are looking for."
|
80 |
+
msgstr ""
|
81 |
+
|
82 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:159
|
83 |
+
msgid "<a href=\"%s\" class=\"button button-primary\">Go to Visual settings</a>"
|
84 |
+
msgstr ""
|
85 |
+
|
86 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:169, includes/admin/settings/jpibfi-advanced-settings.php:23
|
87 |
+
msgid "Advanced settings"
|
88 |
+
msgstr ""
|
89 |
+
|
90 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:171
|
91 |
+
msgid "In most cases you won't have to visit this tab ever. It features a few advanced settings used in most cases to resolve conflicts with other plugins."
|
92 |
+
msgstr ""
|
93 |
+
|
94 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:173
|
95 |
+
msgid "<a href=\"%s\" class=\"button button-primary\">Go to Advanced settings</a>"
|
96 |
+
msgstr ""
|
97 |
+
|
98 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:179, includes/admin/settings/jpibfi-import-export-settings.php:145
|
99 |
+
msgid "Import/Export"
|
100 |
+
msgstr ""
|
101 |
+
|
102 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:181
|
103 |
+
msgid "If you would like to quickly copy the plugin's settings to another instance of WordPress, that's the place for you. You can download a file with your current settings and import it to another instance easily."
|
104 |
+
msgstr ""
|
105 |
+
|
106 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:183
|
107 |
+
msgid "<a href=\"%s\" class=\"button button-primary\">Go to Import/Export</a>"
|
108 |
+
msgstr ""
|
109 |
+
|
110 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:197
|
111 |
+
msgid "Finding help"
|
112 |
+
msgstr ""
|
113 |
+
|
114 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:199
|
115 |
+
msgid "If you're stuck and can't get the plugin to work the way you want it to, get help!"
|
116 |
+
msgstr ""
|
117 |
+
|
118 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:209, includes/admin/jpibfi-admin.php:235
|
119 |
msgid "Documentation"
|
120 |
msgstr ""
|
121 |
|
122 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:211
|
123 |
+
msgid "If you are having difficulties with some aspects of the plugin, the first place to look for help is <a href=\"%s\" target=\"_blank\">the documentation</a> of the plugin. Chances are you will find what you are looking for there."
|
124 |
+
msgstr ""
|
125 |
+
|
126 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:217, includes/admin/jpibfi-admin.php:243
|
127 |
msgid "Support"
|
128 |
msgstr ""
|
129 |
|
130 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:221
|
131 |
+
msgid "Users of the Pro version can get support by sending an email to %s."
|
132 |
msgstr ""
|
133 |
|
134 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:233
|
135 |
+
msgid "Next steps"
|
136 |
msgstr ""
|
137 |
|
138 |
+
#: includes/admin/JPIBFI_Welcome_Screen.php:237
|
139 |
+
msgid "In most cases, the plugin is ready to go without any configuration. You just need to <a href=\"%s\">activate your license</a> to get automatic updates. If there is anything you would like to change, go to the <a href=\"%s\">Settings panel</a>."
|
140 |
msgstr ""
|
141 |
|
142 |
+
#: includes/admin/jpibfi-admin.php:225, includes/admin/settings/jpibfi-settings-base.php:59
|
143 |
+
msgid "Save Changes"
|
144 |
msgstr ""
|
145 |
|
146 |
+
#: includes/admin/jpibfi-admin.php:255
|
147 |
+
msgid "Saving changes ..."
|
148 |
+
msgstr ""
|
149 |
+
|
150 |
+
#: includes/admin/jpibfi-admin.php:311
|
151 |
+
msgid "jQuery Pin It Button For Images Options"
|
152 |
msgstr ""
|
153 |
|
154 |
#: includes/admin/settings/jpibfi-advanced-settings.php:25
|
179 |
msgid "post_thumbnail_html priority"
|
180 |
msgstr ""
|
181 |
|
182 |
+
#: includes/admin/settings/jpibfi-import-export-settings.php:45
|
183 |
msgid "The file did not upload properly. Please try again."
|
184 |
msgstr ""
|
185 |
|
186 |
+
#: includes/admin/settings/jpibfi-import-export-settings.php:59
|
187 |
msgid "The export file could not be found at <code>%s</code>. It is likely that this was caused by a permissions problem."
|
188 |
msgstr ""
|
189 |
|
190 |
+
#: includes/admin/settings/jpibfi-import-export-settings.php:73
|
191 |
msgid "The path is not a file, please try again."
|
192 |
msgstr ""
|
193 |
|
194 |
+
#: includes/admin/settings/jpibfi-import-export-settings.php:117
|
195 |
msgid "Export"
|
196 |
msgstr ""
|
197 |
|
198 |
+
#: includes/admin/settings/jpibfi-import-export-settings.php:121
|
199 |
msgid "Download Export File"
|
200 |
msgstr ""
|
201 |
|
202 |
+
#: includes/admin/settings/jpibfi-import-export-settings.php:125
|
203 |
msgid "Import"
|
204 |
msgstr ""
|
205 |
|
206 |
+
#: includes/admin/settings/jpibfi-import-export-settings.php:127
|
207 |
msgid "Import Settings"
|
208 |
msgstr ""
|
209 |
|
210 |
+
#: includes/admin/settings/jpibfi-license-settings.php:65, includes/admin/settings/jpibfi-license-settings.php:129, includes/admin/settings/jpibfi-license-settings.php:195
|
211 |
+
msgid "An error occurred, please try again."
|
212 |
msgstr ""
|
213 |
|
214 |
+
#: includes/admin/settings/jpibfi-license-settings.php:87
|
215 |
+
msgid "Your license key expired on %s."
|
216 |
msgstr ""
|
217 |
|
218 |
+
#: includes/admin/settings/jpibfi-license-settings.php:97
|
219 |
+
msgid "Your license key has been disabled."
|
220 |
+
msgstr ""
|
221 |
+
|
222 |
+
#: includes/admin/settings/jpibfi-license-settings.php:103
|
223 |
+
msgid "Invalid license."
|
224 |
+
msgstr ""
|
225 |
+
|
226 |
+
#: includes/admin/settings/jpibfi-license-settings.php:111
|
227 |
+
msgid "Your license is not active for this URL."
|
228 |
+
msgstr ""
|
229 |
+
|
230 |
+
#: includes/admin/settings/jpibfi-license-settings.php:117
|
231 |
+
msgid "This appears to be an invalid license key for %s."
|
232 |
+
msgstr ""
|
233 |
+
|
234 |
+
#: includes/admin/settings/jpibfi-license-settings.php:123
|
235 |
+
msgid "Your license key has reached its activation limit."
|
236 |
+
msgstr ""
|
237 |
+
|
238 |
+
#: includes/admin/settings/jpibfi-license-settings.php:151
|
239 |
+
msgid "License Activated."
|
240 |
+
msgstr ""
|
241 |
+
|
242 |
+
#: includes/admin/settings/jpibfi-license-settings.php:223
|
243 |
+
msgid "License deactivated."
|
244 |
+
msgstr ""
|
245 |
+
|
246 |
+
#: includes/admin/settings/jpibfi-license-settings.php:227
|
247 |
+
msgid "License deactivation failed."
|
248 |
+
msgstr ""
|
249 |
+
|
250 |
+
#: includes/admin/settings/jpibfi-license-settings.php:241
|
251 |
+
msgid "Plugin License"
|
252 |
+
msgstr ""
|
253 |
+
|
254 |
+
#: includes/admin/settings/jpibfi-license-settings.php:243
|
255 |
+
msgid "Action"
|
256 |
+
msgstr ""
|
257 |
+
|
258 |
+
#: includes/admin/settings/jpibfi-license-settings.php:245
|
259 |
+
msgid "Activate License"
|
260 |
+
msgstr ""
|
261 |
+
|
262 |
+
#: includes/admin/settings/jpibfi-license-settings.php:249
|
263 |
+
msgid "Deactivate License"
|
264 |
+
msgstr ""
|
265 |
+
|
266 |
+
#: includes/admin/settings/jpibfi-license-settings.php:253
|
267 |
+
msgid "License active"
|
268 |
+
msgstr ""
|
269 |
+
|
270 |
+
#: includes/admin/settings/jpibfi-license-settings.php:269
|
271 |
+
msgid "License"
|
272 |
+
msgstr ""
|
273 |
+
|
274 |
+
#: includes/admin/settings/jpibfi-license-settings.php:347
|
275 |
+
msgid "License Key"
|
276 |
+
msgstr ""
|
277 |
+
|
278 |
+
#: includes/admin/settings/jpibfi-license-settings.php:403
|
279 |
+
msgid "Expires %s"
|
280 |
+
msgstr ""
|
281 |
+
|
282 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:27
|
283 |
+
msgid "jQuery Pin It Button for Images Settings"
|
284 |
msgstr ""
|
285 |
|
286 |
#: includes/admin/settings/jpibfi-selection-settings.php:49
|
319 |
msgid "jQuery selector for all the images that should have the \"Pin it\" button. Set the value to %s if you want the \"Pin it\" button to appear only on images in content or %s to appear on all images on site (including sidebar, header and footer). If you know a thing or two about jQuery, you might use your own selector. %sClick here%s to read about jQuery selectors."
|
320 |
msgstr ""
|
321 |
|
322 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:147
|
323 |
msgid "Disabled classes"
|
324 |
msgstr ""
|
325 |
|
326 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:149
|
327 |
msgid "Images with these CSS classes won't show the \"Pin it\" button. Please separate multiple classes with semicolons. Spaces are not accepted."
|
328 |
msgstr ""
|
329 |
|
330 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:161
|
331 |
msgid "Enabled classes"
|
332 |
msgstr ""
|
333 |
|
334 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:163
|
335 |
msgid "Only images with these CSS classes will show the \"Pin it\" button. Please separate multiple classes with semicolons. If this field is empty, images with any (besides disabled ones) classes will show the Pin It button."
|
336 |
msgstr ""
|
337 |
|
338 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:185, includes/admin/settings/jpibfi-selection-settings.php:207, includes/admin/settings/jpibfi-visual-settings.php:389
|
339 |
msgid "Height"
|
340 |
msgstr ""
|
341 |
|
342 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:187
|
343 |
msgid "Minimum image height"
|
344 |
msgstr ""
|
345 |
|
346 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:195, includes/admin/settings/jpibfi-selection-settings.php:217, includes/admin/settings/jpibfi-visual-settings.php:399
|
347 |
msgid "Width"
|
348 |
msgstr ""
|
349 |
|
350 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:197
|
351 |
msgid "Minimum image width"
|
352 |
msgstr ""
|
353 |
|
354 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:209
|
355 |
msgid "Minimum image height for mobile"
|
356 |
msgstr ""
|
357 |
|
358 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:219
|
359 |
msgid "Minimum image width for mobile"
|
360 |
msgstr ""
|
361 |
|
362 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:229
|
363 |
msgid "Show on"
|
364 |
msgstr ""
|
365 |
|
366 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:241
|
367 |
msgid "Disable on"
|
368 |
msgstr ""
|
369 |
|
370 |
+
#: includes/admin/settings/jpibfi-selection-settings.php:287
|
371 |
msgid "Disable plugin on this post"
|
372 |
msgstr ""
|
373 |
|
374 |
+
#: includes/admin/settings/jpibfi-settings-base.php:63
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
375 |
msgid "This feature is available in <a target=\"_blank\" href=\"%s\">the PRO version</a>."
|
376 |
msgstr ""
|
377 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
378 |
#: includes/admin/settings/jpibfi-visual-settings.php:23
|
379 |
msgid "\"Pin it\" button margins"
|
380 |
msgstr ""
|
659 |
msgid "Transparency value must be a number between %.02d and %.02f."
|
660 |
msgstr ""
|
661 |
|
662 |
+
#: jquery-pin-it-button-for-images.php:89
|
663 |
msgid "You have two versions of jQuery Pin It Button for Images installed. Please deactivate and remove one of them."
|
664 |
msgstr ""
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: mrsztuczkens, redearthdesign, brocheafoin, robertark
|
|
3 |
Tags: pinterest, pin it, button, image, images, pinit, social media, hover, click, photo, photos
|
4 |
Requires at least: 3.3.0
|
5 |
Tested up to: 4.6.1
|
6 |
-
Stable tag: 2.
|
7 |
License: GPLv2 or later
|
8 |
|
9 |
Highlights images on hover and adds a Pinterest "Pin It" button over them for easy pinning.
|
@@ -68,6 +68,11 @@ Please report them in the plugin's support forum on Wordpress.org.
|
|
68 |
|
69 |
== Changelog ==
|
70 |
|
|
|
|
|
|
|
|
|
|
|
71 |
= 2.1.3 =
|
72 |
* Released 2017-01-12
|
73 |
* Added ability to disable the plugin on certain filters and changing filters priority
|
@@ -282,6 +287,9 @@ Please report them in the plugin's support forum on Wordpress.org.
|
|
282 |
|
283 |
== Upgrade Notice ==
|
284 |
|
|
|
|
|
|
|
285 |
= 2.1.3 =
|
286 |
* Added ability to manipulate filters the plugin uses and added additional validation to settings.
|
287 |
|
3 |
Tags: pinterest, pin it, button, image, images, pinit, social media, hover, click, photo, photos
|
4 |
Requires at least: 3.3.0
|
5 |
Tested up to: 4.6.1
|
6 |
+
Stable tag: 2.2.0
|
7 |
License: GPLv2 or later
|
8 |
|
9 |
Highlights images on hover and adds a Pinterest "Pin It" button over them for easy pinning.
|
68 |
|
69 |
== Changelog ==
|
70 |
|
71 |
+
= 2.2.0 =
|
72 |
+
* Release 2017-01-21
|
73 |
+
* Settings panel switched to saving via form submit instead of an Ajax request to avoid conflicts with security plugins
|
74 |
+
* Settings panel cleanup
|
75 |
+
|
76 |
= 2.1.3 =
|
77 |
* Released 2017-01-12
|
78 |
* Added ability to disable the plugin on certain filters and changing filters priority
|
287 |
|
288 |
== Upgrade Notice ==
|
289 |
|
290 |
+
= 2.2.0 =
|
291 |
+
* Changed how settings are saved to avoid conflicts with security plugins
|
292 |
+
|
293 |
= 2.1.3 =
|
294 |
* Added ability to manipulate filters the plugin uses and added additional validation to settings.
|
295 |
|