From 6a788e97a17a85cac9f940c43472ae70873d98ab Mon Sep 17 00:00:00 2001 From: Dan Date: Mon, 21 Mar 2016 11:56:55 -0400 Subject: [PATCH] Bumped version to 3.3.1 --- bower.json | 4 +- dist/docs/css/patternfly-additions.css | 153 ++-- dist/docs/css/patternfly.css | 266 +++---- dist/docs/grunt-scripts/angular-animate.js | 65 +- dist/docs/grunt-scripts/angular-sanitize.js | 2 +- dist/docs/grunt-scripts/angular.js | 670 +++++++++++------- dist/docs/grunt-scripts/patternfly.js | 64 -- .../api/patternfly.autofocus.pfFocused.html | 2 +- ....card.directive.pfAggregateStatusCard.html | 2 +- .../api/patternfly.card.directive.pfCard.html | 2 +- ...patternfly.charts.directive.pfC3Chart.html | 2 +- ...nfly.charts.directive.pfDonutPctChart.html | 2 +- ...patternfly.charts.directive.pfHeatMap.html | 2 +- ...fly.charts.directive.pfSparklineChart.html | 2 +- ...ernfly.charts.directive.pfTrendsChart.html | 2 +- ...harts.directive.pfUtilizationBarChart.html | 2 +- ...rts.directive.pfUtilizationTrendChart.html | 2 +- ...patternfly.filters.directive.pfFilter.html | 2 +- ...nfly.filters.directive.pfFilterFields.html | 2 +- ...fly.filters.directive.pfFilterResults.html | 2 +- ...atternfly.form.directive.pfDatepicker.html | 2 +- ...tternfly.form.directive.pfFormButtons.html | 2 +- ...patternfly.form.directive.pfFormGroup.html | 2 +- ....form.directive.pfRemainingCharsCount.html | 2 +- .../patternfly.notification.Notification.html | 2 +- ...cation.directive.pfInlineNotification.html | 2 +- ...fication.directive.pfNotificationList.html | 2 +- .../api/patternfly.select.pfSelect.html | 2 +- .../api/patternfly.sort.directive.pfSort.html | 2 +- ...tternfly.toolbars.directive.pfToolbar.html | 2 +- ...tternfly.utils.directive.pfTransclude.html | 2 +- .../patternfly.validation.pfValidation.html | 2 +- ...patternfly.views.directive.pfCardView.html | 2 +- ...patternfly.views.directive.pfListView.html | 2 +- package.json | 2 +- 35 files changed, 674 insertions(+), 606 deletions(-) diff --git a/bower.json b/bower.json index b02d1643d..6fca4d87c 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "angular-patternfly", - "version": "3.3.0", + "version": "3.3.1", "authors": [ "Red Hat" ], @@ -39,7 +39,7 @@ "angular-sanitize": "1.3.0 - 1.5.*", "angular-bootstrap": "0.13.x", "lodash": "3.x", - "patternfly": "~3.3.0" + "patternfly": "~3.3.1" }, "devDependencies": { "angular-mocks": "1.3.0 - 1.5.*" diff --git a/dist/docs/css/patternfly-additions.css b/dist/docs/css/patternfly-additions.css index ea3907e13..600527850 100644 --- a/dist/docs/css/patternfly-additions.css +++ b/dist/docs/css/patternfly-additions.css @@ -154,7 +154,7 @@ .datepicker table tr td.today:hover, .datepicker table tr td.today.disabled, .datepicker table tr td.today.disabled:hover { - color: #000000; + color: #000; background-color: #ffdb99; border-color: #ffb733; } @@ -166,7 +166,7 @@ .datepicker table tr td.today:hover.focus, .datepicker table tr td.today.disabled.focus, .datepicker table tr td.today.disabled:hover.focus { - color: #000000; + color: #000; background-color: #ffc966; border-color: #b37400; } @@ -174,7 +174,7 @@ .datepicker table tr td.today:hover:hover, .datepicker table tr td.today.disabled:hover, .datepicker table tr td.today.disabled:hover:hover { - color: #000000; + color: #000; background-color: #ffc966; border-color: #f59e00; } @@ -190,7 +190,7 @@ .open > .dropdown-toggle.datepicker table tr td.today:hover, .open > .dropdown-toggle.datepicker table tr td.today.disabled, .open > .dropdown-toggle.datepicker table tr td.today.disabled:hover { - color: #000000; + color: #000; background-color: #ffc966; border-color: #f59e00; } @@ -230,7 +230,7 @@ .open > .dropdown-toggle.datepicker table tr td.today:hover.focus, .open > .dropdown-toggle.datepicker table tr td.today.disabled.focus, .open > .dropdown-toggle.datepicker table tr td.today.disabled:hover.focus { - color: #000000; + color: #000; background-color: #ffbc42; border-color: #b37400; } @@ -292,7 +292,7 @@ fieldset[disabled] .datepicker table tr td.today.disabled:hover.focus { .datepicker table tr td.today.disabled .badge, .datepicker table tr td.today.disabled:hover .badge { color: #ffdb99; - background-color: #000000; + background-color: #000; } .datepicker table tr td.today:hover:hover { color: #000; @@ -311,7 +311,7 @@ fieldset[disabled] .datepicker table tr td.today.disabled:hover.focus { .datepicker table tr td.range.today:hover, .datepicker table tr td.range.today.disabled, .datepicker table tr td.range.today.disabled:hover { - color: #000000; + color: #000; background-color: #f7ca77; border-color: #f1a417; border-radius: 0; @@ -324,7 +324,7 @@ fieldset[disabled] .datepicker table tr td.today.disabled:hover.focus { .datepicker table tr td.range.today:hover.focus, .datepicker table tr td.range.today.disabled.focus, .datepicker table tr td.range.today.disabled:hover.focus { - color: #000000; + color: #000; background-color: #f4b747; border-color: #815608; } @@ -332,7 +332,7 @@ fieldset[disabled] .datepicker table tr td.today.disabled:hover.focus { .datepicker table tr td.range.today:hover:hover, .datepicker table tr td.range.today.disabled:hover, .datepicker table tr td.range.today.disabled:hover:hover { - color: #000000; + color: #000; background-color: #f4b747; border-color: #bf800c; } @@ -348,7 +348,7 @@ fieldset[disabled] .datepicker table tr td.today.disabled:hover.focus { .open > .dropdown-toggle.datepicker table tr td.range.today:hover, .open > .dropdown-toggle.datepicker table tr td.range.today.disabled, .open > .dropdown-toggle.datepicker table tr td.range.today.disabled:hover { - color: #000000; + color: #000; background-color: #f4b747; border-color: #bf800c; } @@ -388,7 +388,7 @@ fieldset[disabled] .datepicker table tr td.today.disabled:hover.focus { .open > .dropdown-toggle.datepicker table tr td.range.today:hover.focus, .open > .dropdown-toggle.datepicker table tr td.range.today.disabled.focus, .open > .dropdown-toggle.datepicker table tr td.range.today.disabled:hover.focus { - color: #000000; + color: #000; background-color: #f2aa25; border-color: #815608; } @@ -450,13 +450,13 @@ fieldset[disabled] .datepicker table tr td.range.today.disabled:hover.focus { .datepicker table tr td.range.today.disabled .badge, .datepicker table tr td.range.today.disabled:hover .badge { color: #f7ca77; - background-color: #000000; + background-color: #000; } .datepicker table tr td.selected, .datepicker table tr td.selected:hover, .datepicker table tr td.selected.disabled, .datepicker table tr td.selected.disabled:hover { - color: #ffffff; + color: #fff; background-color: #999999; border-color: #555555; text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); @@ -469,7 +469,7 @@ fieldset[disabled] .datepicker table tr td.range.today.disabled:hover.focus { .datepicker table tr td.selected:hover.focus, .datepicker table tr td.selected.disabled.focus, .datepicker table tr td.selected.disabled:hover.focus { - color: #ffffff; + color: #fff; background-color: #808080; border-color: #161616; } @@ -477,7 +477,7 @@ fieldset[disabled] .datepicker table tr td.range.today.disabled:hover.focus { .datepicker table tr td.selected:hover:hover, .datepicker table tr td.selected.disabled:hover, .datepicker table tr td.selected.disabled:hover:hover { - color: #ffffff; + color: #fff; background-color: #808080; border-color: #373737; } @@ -493,7 +493,7 @@ fieldset[disabled] .datepicker table tr td.range.today.disabled:hover.focus { .open > .dropdown-toggle.datepicker table tr td.selected:hover, .open > .dropdown-toggle.datepicker table tr td.selected.disabled, .open > .dropdown-toggle.datepicker table tr td.selected.disabled:hover { - color: #ffffff; + color: #fff; background-color: #808080; border-color: #373737; } @@ -533,7 +533,7 @@ fieldset[disabled] .datepicker table tr td.range.today.disabled:hover.focus { .open > .dropdown-toggle.datepicker table tr td.selected:hover.focus, .open > .dropdown-toggle.datepicker table tr td.selected.disabled.focus, .open > .dropdown-toggle.datepicker table tr td.selected.disabled:hover.focus { - color: #ffffff; + color: #fff; background-color: #6e6e6e; border-color: #161616; } @@ -595,13 +595,13 @@ fieldset[disabled] .datepicker table tr td.selected.disabled:hover.focus { .datepicker table tr td.selected.disabled .badge, .datepicker table tr td.selected.disabled:hover .badge { color: #999999; - background-color: #ffffff; + background-color: #fff; } .datepicker table tr td.active, .datepicker table tr td.active:hover, .datepicker table tr td.active.disabled, .datepicker table tr td.active.disabled:hover { - color: #ffffff; + color: #fff; background-color: #0085cf; border-color: #006e9c; text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); @@ -614,7 +614,7 @@ fieldset[disabled] .datepicker table tr td.selected.disabled:hover.focus { .datepicker table tr td.active:hover.focus, .datepicker table tr td.active.disabled.focus, .datepicker table tr td.active.disabled:hover.focus { - color: #ffffff; + color: #fff; background-color: #00649c; border-color: #00141d; } @@ -622,7 +622,7 @@ fieldset[disabled] .datepicker table tr td.selected.disabled:hover.focus { .datepicker table tr td.active:hover:hover, .datepicker table tr td.active.disabled:hover, .datepicker table tr td.active.disabled:hover:hover { - color: #ffffff; + color: #fff; background-color: #00649c; border-color: #00435f; } @@ -638,7 +638,7 @@ fieldset[disabled] .datepicker table tr td.selected.disabled:hover.focus { .open > .dropdown-toggle.datepicker table tr td.active:hover, .open > .dropdown-toggle.datepicker table tr td.active.disabled, .open > .dropdown-toggle.datepicker table tr td.active.disabled:hover { - color: #ffffff; + color: #fff; background-color: #00649c; border-color: #00435f; } @@ -678,7 +678,7 @@ fieldset[disabled] .datepicker table tr td.selected.disabled:hover.focus { .open > .dropdown-toggle.datepicker table tr td.active:hover.focus, .open > .dropdown-toggle.datepicker table tr td.active.disabled.focus, .open > .dropdown-toggle.datepicker table tr td.active.disabled:hover.focus { - color: #ffffff; + color: #fff; background-color: #004d78; border-color: #00141d; } @@ -740,7 +740,7 @@ fieldset[disabled] .datepicker table tr td.active.disabled:hover.focus { .datepicker table tr td.active.disabled .badge, .datepicker table tr td.active.disabled:hover .badge { color: #0085cf; - background-color: #ffffff; + background-color: #fff; } .datepicker table tr td span { display: block; @@ -765,7 +765,7 @@ fieldset[disabled] .datepicker table tr td.active.disabled:hover.focus { .datepicker table tr td span.active:hover, .datepicker table tr td span.active.disabled, .datepicker table tr td span.active.disabled:hover { - color: #ffffff; + color: #fff; background-color: #0085cf; border-color: #006e9c; text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); @@ -778,7 +778,7 @@ fieldset[disabled] .datepicker table tr td.active.disabled:hover.focus { .datepicker table tr td span.active:hover.focus, .datepicker table tr td span.active.disabled.focus, .datepicker table tr td span.active.disabled:hover.focus { - color: #ffffff; + color: #fff; background-color: #00649c; border-color: #00141d; } @@ -786,7 +786,7 @@ fieldset[disabled] .datepicker table tr td.active.disabled:hover.focus { .datepicker table tr td span.active:hover:hover, .datepicker table tr td span.active.disabled:hover, .datepicker table tr td span.active.disabled:hover:hover { - color: #ffffff; + color: #fff; background-color: #00649c; border-color: #00435f; } @@ -802,7 +802,7 @@ fieldset[disabled] .datepicker table tr td.active.disabled:hover.focus { .open > .dropdown-toggle.datepicker table tr td span.active:hover, .open > .dropdown-toggle.datepicker table tr td span.active.disabled, .open > .dropdown-toggle.datepicker table tr td span.active.disabled:hover { - color: #ffffff; + color: #fff; background-color: #00649c; border-color: #00435f; } @@ -842,7 +842,7 @@ fieldset[disabled] .datepicker table tr td.active.disabled:hover.focus { .open > .dropdown-toggle.datepicker table tr td span.active:hover.focus, .open > .dropdown-toggle.datepicker table tr td span.active.disabled.focus, .open > .dropdown-toggle.datepicker table tr td span.active.disabled:hover.focus { - color: #ffffff; + color: #fff; background-color: #004d78; border-color: #00141d; } @@ -904,7 +904,7 @@ fieldset[disabled] .datepicker table tr td span.active.disabled:hover.focus { .datepicker table tr td span.active.disabled .badge, .datepicker table tr td span.active.disabled:hover .badge { color: #0085cf; - background-color: #ffffff; + background-color: #fff; } .datepicker table tr td span.old, .datepicker table tr td span.new { @@ -956,7 +956,7 @@ fieldset[disabled] .datepicker table tr td span.active.disabled:hover.focus { text-shadow: 0 1px 0 #fff; vertical-align: middle; background-color: #eeeeee; - border: solid #bababa; + border: solid #BABABA; border-width: 1px 0; margin-left: -5px; margin-right: -5px; @@ -1626,7 +1626,7 @@ select.mobile-device { .bootstrap-datetimepicker-widget.dropdown-menu.bottom:before { border-left: 7px solid transparent; border-right: 7px solid transparent; - border-bottom: 7px solid #cccccc; + border-bottom: 7px solid #ccc; border-bottom-color: rgba(0, 0, 0, 0.2); top: -7px; left: 7px; @@ -1641,7 +1641,7 @@ select.mobile-device { .bootstrap-datetimepicker-widget.dropdown-menu.top:before { border-left: 7px solid transparent; border-right: 7px solid transparent; - border-top: 7px solid #cccccc; + border-top: 7px solid #ccc; border-top-color: rgba(0, 0, 0, 0.2); bottom: -7px; left: 6px; @@ -1901,7 +1901,7 @@ select.mobile-device { .bootstrap-datetimepicker-widget table td.active, .bootstrap-datetimepicker-widget table td.active:hover { background-color: #0085cf; - color: #ffffff; + color: #fff; text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); } .bootstrap-datetimepicker-widget table td.active.today:before { @@ -1927,7 +1927,7 @@ select.mobile-device { } .bootstrap-datetimepicker-widget table td span.active { background-color: #0085cf; - color: #ffffff; + color: #fff; text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); } .bootstrap-datetimepicker-widget table td span.old { @@ -2074,8 +2074,8 @@ fieldset[disabled] .combobox-container .input-group-addon.active { box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.2); } .bootstrap-datepicker.form-control[readonly] { - background-color: #ffffff; - border-color: #bababa !important; + background-color: #fff; + border-color: #BABABA !important; color: #333333; -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); @@ -2105,7 +2105,7 @@ fieldset[disabled] .combobox-container .input-group-addon.active { box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #faad60; } .bootstrap-datepicker.form-control[readonly]:hover { - border-color: #7bb2dd !important; + border-color: #7BB2DD !important; } .has-error .bootstrap-datepicker.form-control[readonly]:hover { border-color: #843534 !important; @@ -2185,7 +2185,7 @@ fieldset[disabled] .combobox-container .input-group-addon.active { } .input-daterange .input-group-addon { background-color: #eeeeee; - border-color: #bababa; + border-color: #BABABA; line-height: 1.66666667; padding: 2px 6px; } @@ -2198,7 +2198,7 @@ fieldset[disabled] .combobox-container .input-group-addon.active { transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s; } .bootstrap-select.btn-group .btn:hover { - border-color: #7bb2dd; + border-color: #7BB2DD; } .bootstrap-select.btn-group .btn .caret { margin-top: -4px; @@ -2336,7 +2336,7 @@ fieldset[disabled] .combobox-container .input-group-addon.active { .treeview .list-group-item.node-selected { background: #0099d3 !important; border-color: #0076b7 !important; - color: #ffffff !important; + color: #fff !important; } .treeview span.icon { display: inline-block; @@ -2351,7 +2351,7 @@ fieldset[disabled] .combobox-container .input-group-addon.active { margin-right: 5px; } .card-pf { - background: #ffffff; + background: #fff; border-top: 2px solid transparent; -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.175); box-shadow: 0 1px 1px rgba(0, 0, 0, 0.175); @@ -2499,7 +2499,7 @@ fieldset[disabled] .combobox-container .input-group-addon.active { } .card-pf-aggregate-status .card-pf-title .fa, .card-pf-aggregate-status .card-pf-title .pficon { - color: #333333; + color: #333; font-size: 16px; margin-right: 7px; } @@ -2597,7 +2597,7 @@ fieldset[disabled] .combobox-container .input-group-addon.active { .c3-tooltip td { background: transparent; border: 0; - color: #ffffff; + color: #fff; font-size: 12px; padding: 5px 10px; } @@ -2616,7 +2616,7 @@ fieldset[disabled] .combobox-container .input-group-addon.active { .c3-tooltip-sparkline, .donut-tooltip-pf { background: #434343; - color: #ffffff; + color: #fff; opacity: 0.9; filter: alpha(opacity=90); padding: 2px 6px; @@ -2661,7 +2661,7 @@ fieldset[disabled] .combobox-container .input-group-addon.active { z-index: 999; } .ColVis_collection { - background-color: #ffffff; + background-color: #fff; border: 1px solid #b6b6b6; border-radius: 1px; -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); @@ -3146,7 +3146,7 @@ table.datatable th:active { .infotip.bottom-left .arrow:after, .infotip.bottom-right .arrow:after { border-top-width: 0; - border-bottom-color: #ffffff; + border-bottom-color: #fff; content: " "; margin-left: -10px; top: 1px; @@ -3183,7 +3183,7 @@ table.datatable th:active { .infotip.right .arrow:after { bottom: -10px; border-left-width: 0; - border-right-color: #ffffff; + border-right-color: #fff; content: " "; left: 1px; } @@ -3196,7 +3196,7 @@ table.datatable th:active { top: 50%; } .infotip.left .arrow:after { - border-left-color: #ffffff; + border-left-color: #fff; border-right-width: 0; bottom: -10px; content: " "; @@ -3329,7 +3329,7 @@ table.datatable th:active { clear: both; } .list-view-pf .list-group-item.active { - color: #555555; + color: #555; background-color: #def3ff; } .list-view-pf .list-group-item:hover { @@ -3934,7 +3934,7 @@ table.datatable th:active { box-shadow: 0 0 3px #ffffff; } .navbar-pf .navbar-toggle .icon-bar { - background-color: #ffffff; + background-color: #fff; } .navbar-pf .navbar-utility { border-bottom: 1px solid #292929; @@ -4043,7 +4043,7 @@ table.datatable th:active { } .navbar-pf .navbar-primary.persistent-secondary > li > .navbar-persistent > li:hover:before, .navbar-pf .navbar-primary.persistent-secondary > li > .navbar-persistent > li.open:before { - background: #aaaaaa; + background: #aaa; bottom: -1px; content: ''; display: block; @@ -4265,12 +4265,12 @@ table.datatable th:active { .navbar-pf-alt .nav .nav-item-iconic:focus .glyphicon, .navbar-pf-alt .nav .nav-item-iconic:hover .pf-icon, .navbar-pf-alt .nav .nav-item-iconic:focus .pf-icon { - color: #ffffff; + color: #fff; } .navbar-pf-alt .nav .nav-item-iconic .badge { background-color: #cc0000; border-radius: 20px; - color: #ffffff; + color: #fff; cursor: pointer; font-size: 9px; font-weight: 700; @@ -4302,10 +4302,10 @@ table.datatable th:active { .navbar-pf-alt .nav .open > .nav-item-iconic .pf-icon, .navbar-pf-alt .nav .open > .nav-item-iconic:hover .pf-icon, .navbar-pf-alt .nav .open > .nav-item-iconic:focus .pf-icon { - color: #ffffff; + color: #fff; } .navbar-pf-alt .navbar-brand { - color: #ffffff; + color: #fff; height: auto; margin: 0 0 0 25px; min-height: 35px; @@ -4335,7 +4335,7 @@ table.datatable th:active { } .navbar-pf-alt .navbar-toggle:hover .icon-bar, .navbar-pf-alt .navbar-toggle:focus .icon-bar { - background: #ffffff; + background: #fff; } .navbar-pf-alt .navbar-toggle + .navbar-brand { margin-left: 0; @@ -4382,12 +4382,12 @@ table.datatable th:active { .navbar-pf-vertical .nav .nav-item-iconic:focus .glyphicon, .navbar-pf-vertical .nav .nav-item-iconic:hover .pf-icon, .navbar-pf-vertical .nav .nav-item-iconic:focus .pf-icon { - color: #ffffff; + color: #fff; } .navbar-pf-vertical .nav .nav-item-iconic .badge { background-color: #cc0000; border-radius: 20px; - color: #ffffff; + color: #fff; cursor: pointer; font-size: 9px; font-weight: 700; @@ -4419,10 +4419,10 @@ table.datatable th:active { .navbar-pf-vertical .nav .open > .nav-item-iconic .pf-icon, .navbar-pf-vertical .nav .open > .nav-item-iconic:hover .pf-icon, .navbar-pf-vertical .nav .open > .nav-item-iconic:focus .pf-icon { - color: #ffffff; + color: #fff; } .navbar-pf-vertical .navbar-brand { - color: #ffffff; + color: #fff; height: auto; margin: 0 0 0 25px; min-height: 35px; @@ -4452,7 +4452,7 @@ table.datatable th:active { } .navbar-pf-vertical .navbar-toggle:hover .icon-bar, .navbar-pf-vertical .navbar-toggle:focus .icon-bar { - background: #ffffff; + background: #fff; } .navbar-pf-vertical .navbar-toggle + .navbar-brand { margin-left: 0; @@ -4474,7 +4474,7 @@ table.datatable th:active { transition-delay: .15s; } .nav-pf-vertical-alt { - background: #ffffff; + background: #fff; } .ie9.layout-pf-alt-fixed .nav-pf-vertical-alt { box-sizing: content-box; @@ -4536,7 +4536,7 @@ table.datatable th:active { text-decoration: none; } .nav-pf-vertical-alt .list-group-item.active { - background-color: #ffffff; + background-color: #fff; border-color: #f2f2f2; } .nav-pf-vertical-alt .list-group-item.active:before { @@ -4554,9 +4554,9 @@ table.datatable th:active { } .nav-pf-vertical-alt .list-group-item .badge { background: #333333; - border: 1px solid #ffffff; + border: 1px solid #fff; border-radius: 3px; - color: #ffffff; + color: #fff; font-weight: 700; font-size: 9px; padding: 5px; @@ -5049,15 +5049,6 @@ table.datatable th:active { left: auto; } } -.toast-pf-area { - left: 66%; - position: fixed; - right: 20px; - top: 12px; - width: calc(34% - 20px); - word-wrap: break-word; - z-index: 1035; -} .toolbar-pf { background: #fff; border-bottom: 1px solid #d0d0d0; @@ -5395,7 +5386,7 @@ table.datatable th:active { .nav-pf-vertical > .list-group > .list-group-item.active > a, .nav-pf-vertical > .list-group > .list-group-item:hover > a { background-color: #393f44; - color: #ffffff; + color: #fff; font-weight: 600; } .nav-pf-vertical > .list-group > .list-group-item.active > a .fa, @@ -5533,7 +5524,7 @@ table.datatable th:active { bottom: 37px; } .nav-pf-persistent-secondary .persistent-secondary-header { - color: #ffffff; + color: #fff; font-size: 16px; margin: 18px 20px 10px 20px; } @@ -5546,7 +5537,7 @@ table.datatable th:active { color: #0099d3; } .nav-pf-persistent-secondary h5 { - color: #ffffff; + color: #fff; cursor: default; font-size: 13px; font-weight: 600; @@ -5572,12 +5563,12 @@ table.datatable th:active { white-space: nowrap; } .nav-pf-persistent-secondary > .list-group > .list-group-item > a:hover > .list-group-item-value { - color: #ffffff; + color: #fff; text-decoration: underline; } .nav-pf-persistent-secondary > .list-group > .list-group-item.active .list-group-item-value { background-color: #4d5258; - color: #ffffff; + color: #fff; } .nav-pf-persistent-secondary > .list-group > .list-group-item.active .fa, .nav-pf-persistent-secondary > .list-group > .list-group-item.active .glyphicon, @@ -5592,7 +5583,7 @@ table.datatable th:active { } .nav-pf-persistent-secondary > .list-group > .list-group-item .badge-container-pf .badge { background: #292e34; - color: #ffffff; + color: #fff; font-size: 12px; font-weight: 700; float: left; diff --git a/dist/docs/css/patternfly.css b/dist/docs/css/patternfly.css index d9e6c0d8a..a37c35bd1 100644 --- a/dist/docs/css/patternfly.css +++ b/dist/docs/css/patternfly.css @@ -1157,7 +1157,7 @@ img { padding: 4px; line-height: 1.66666667; background-color: #ffffff; - border: 1px solid #dddddd; + border: 1px solid #ddd; border-radius: 1px; -webkit-transition: all 0.2s ease-in-out; -o-transition: all 0.2s ease-in-out; @@ -1569,8 +1569,8 @@ code { kbd { padding: 2px 4px; font-size: 90%; - color: #ffffff; - background-color: #333333; + color: #fff; + background-color: #333; border-radius: 1px; box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.25); } @@ -1590,7 +1590,7 @@ pre { word-wrap: break-word; color: #333333; background-color: #fcfcfc; - border: 1px solid #cccccc; + border: 1px solid #ccc; border-radius: 1px; } pre code { @@ -2579,9 +2579,9 @@ output { font-size: 12px; line-height: 1.66666667; color: #333333; - background-color: #ffffff; + background-color: #fff; background-image: none; - border: 1px solid #bababa; + border: 1px solid #BABABA; border-radius: 1px; -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); @@ -2596,29 +2596,29 @@ output { box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, 0.6); } .form-control::-moz-placeholder { - color: #999999; + color: #999; opacity: 1; } .form-control:-ms-input-placeholder { - color: #999999; + color: #999; } .form-control::-webkit-input-placeholder { - color: #999999; + color: #999; } .form-control:-moz-placeholder { - color: #999999; + color: #999; font-style: italic; } .form-control::-moz-placeholder { - color: #999999; + color: #999; font-style: italic; } .form-control:-ms-input-placeholder { - color: #999999; + color: #999; font-style: italic; } .form-control::-webkit-input-placeholder { - color: #999999; + color: #999; font-style: italic; } .form-control::-ms-expand { @@ -2628,7 +2628,7 @@ output { .form-control[disabled], .form-control[readonly], fieldset[disabled] .form-control { - background-color: #f8f8f8; + background-color: #F8F8F8; opacity: 1; } .form-control[disabled], @@ -3155,25 +3155,25 @@ fieldset[disabled] .btn-default.focus { background-color: #4d5258; } .btn-primary { - color: #ffffff; + color: #fff; background-color: #0085cf; border-color: #006e9c; } .btn-primary:focus, .btn-primary.focus { - color: #ffffff; + color: #fff; background-color: #00649c; border-color: #00141d; } .btn-primary:hover { - color: #ffffff; + color: #fff; background-color: #00649c; border-color: #00435f; } .btn-primary:active, .btn-primary.active, .open > .dropdown-toggle.btn-primary { - color: #ffffff; + color: #fff; background-color: #00649c; border-color: #00435f; } @@ -3186,7 +3186,7 @@ fieldset[disabled] .btn-default.focus { .btn-primary:active.focus, .btn-primary.active.focus, .open > .dropdown-toggle.btn-primary.focus { - color: #ffffff; + color: #fff; background-color: #004d78; border-color: #00141d; } @@ -3209,28 +3209,28 @@ fieldset[disabled] .btn-primary.focus { } .btn-primary .badge { color: #0085cf; - background-color: #ffffff; + background-color: #fff; } .btn-success { - color: #ffffff; + color: #fff; background-color: #3f9c35; border-color: #37892f; } .btn-success:focus, .btn-success.focus { - color: #ffffff; + color: #fff; background-color: #307628; border-color: #112a0e; } .btn-success:hover { - color: #ffffff; + color: #fff; background-color: #307628; border-color: #255b1f; } .btn-success:active, .btn-success.active, .open > .dropdown-toggle.btn-success { - color: #ffffff; + color: #fff; background-color: #307628; border-color: #255b1f; } @@ -3243,7 +3243,7 @@ fieldset[disabled] .btn-primary.focus { .btn-success:active.focus, .btn-success.active.focus, .open > .dropdown-toggle.btn-success.focus { - color: #ffffff; + color: #fff; background-color: #255b1f; border-color: #112a0e; } @@ -3266,28 +3266,28 @@ fieldset[disabled] .btn-success.focus { } .btn-success .badge { color: #3f9c35; - background-color: #ffffff; + background-color: #fff; } .btn-info { - color: #ffffff; + color: #fff; background-color: #006e9c; border-color: #005c83; } .btn-info:focus, .btn-info.focus { - color: #ffffff; + color: #fff; background-color: #004a69; border-color: #000203; } .btn-info:hover { - color: #ffffff; + color: #fff; background-color: #004a69; border-color: #003145; } .btn-info:active, .btn-info.active, .open > .dropdown-toggle.btn-info { - color: #ffffff; + color: #fff; background-color: #004a69; border-color: #003145; } @@ -3300,7 +3300,7 @@ fieldset[disabled] .btn-success.focus { .btn-info:active.focus, .btn-info.active.focus, .open > .dropdown-toggle.btn-info.focus { - color: #ffffff; + color: #fff; background-color: #003145; border-color: #000203; } @@ -3323,28 +3323,28 @@ fieldset[disabled] .btn-info.focus { } .btn-info .badge { color: #006e9c; - background-color: #ffffff; + background-color: #fff; } .btn-warning { - color: #ffffff; + color: #fff; background-color: #ec7a08; border-color: #d36d07; } .btn-warning:focus, .btn-warning.focus { - color: #ffffff; + color: #fff; background-color: #bb6106; border-color: #582e03; } .btn-warning:hover { - color: #ffffff; + color: #fff; background-color: #bb6106; border-color: #984f05; } .btn-warning:active, .btn-warning.active, .open > .dropdown-toggle.btn-warning { - color: #ffffff; + color: #fff; background-color: #bb6106; border-color: #984f05; } @@ -3357,7 +3357,7 @@ fieldset[disabled] .btn-info.focus { .btn-warning:active.focus, .btn-warning.active.focus, .open > .dropdown-toggle.btn-warning.focus { - color: #ffffff; + color: #fff; background-color: #984f05; border-color: #582e03; } @@ -3380,28 +3380,28 @@ fieldset[disabled] .btn-warning.focus { } .btn-warning .badge { color: #ec7a08; - background-color: #ffffff; + background-color: #fff; } .btn-danger { - color: #ffffff; + color: #fff; background-color: #a30000; border-color: #781919; } .btn-danger:focus, .btn-danger.focus { - color: #ffffff; + color: #fff; background-color: #700000; border-color: #0e0303; } .btn-danger:hover { - color: #ffffff; + color: #fff; background-color: #700000; border-color: #450e0e; } .btn-danger:active, .btn-danger.active, .open > .dropdown-toggle.btn-danger { - color: #ffffff; + color: #fff; background-color: #700000; border-color: #450e0e; } @@ -3414,7 +3414,7 @@ fieldset[disabled] .btn-warning.focus { .btn-danger:active.focus, .btn-danger.active.focus, .open > .dropdown-toggle.btn-danger.focus { - color: #ffffff; + color: #fff; background-color: #4c0000; border-color: #0e0303; } @@ -3437,7 +3437,7 @@ fieldset[disabled] .btn-danger.focus { } .btn-danger .badge { color: #a30000; - background-color: #ffffff; + background-color: #fff; } .btn-link { color: #0099d3; @@ -3568,7 +3568,7 @@ tbody.collapse.in { list-style: none; font-size: 12px; text-align: left; - background-color: #ffffff; + background-color: #fff; border: 1px solid #b6b6b6; border-radius: 1px; -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); @@ -3604,7 +3604,7 @@ tbody.collapse.in { .dropdown-menu > .active > a, .dropdown-menu > .active > a:hover, .dropdown-menu > .active > a:focus { - color: #ffffff; + color: #fff; text-decoration: none; outline: 0; background-color: #0099d3; @@ -3940,7 +3940,7 @@ select[multiple].input-group-sm > .input-group-btn > .btn { color: #333333; text-align: center; background-color: #eeeeee; - border: 1px solid #bababa; + border: 1px solid #BABABA; border-radius: 1px; } .input-group-addon.input-sm { @@ -4074,7 +4074,7 @@ select[multiple].input-group-sm > .input-group-btn > .btn { .nav-tabs > li.active > a:focus { color: #0099d3; background-color: #ffffff; - border: 1px solid #dddddd; + border: 1px solid #ddd; border-bottom-color: transparent; cursor: default; } @@ -4134,7 +4134,7 @@ select[multiple].input-group-sm > .input-group-btn > .btn { .nav-pills > li.active > a, .nav-pills > li.active > a:hover, .nav-pills > li.active > a:focus { - color: #ffffff; + color: #fff; background-color: #00a8e1; } .nav-stacked > li { @@ -4534,7 +4534,7 @@ select[multiple].input-group-sm > .input-group-btn > .btn { border-color: #e7e7e7; } .navbar-default .navbar-brand { - color: #777777; + color: #777; } .navbar-default .navbar-brand:hover, .navbar-default .navbar-brand:focus { @@ -4542,37 +4542,37 @@ select[multiple].input-group-sm > .input-group-btn > .btn { background-color: transparent; } .navbar-default .navbar-text { - color: #777777; + color: #777; } .navbar-default .navbar-nav > li > a { - color: #777777; + color: #777; } .navbar-default .navbar-nav > li > a:hover, .navbar-default .navbar-nav > li > a:focus { - color: #333333; + color: #333; background-color: transparent; } .navbar-default .navbar-nav > .active > a, .navbar-default .navbar-nav > .active > a:hover, .navbar-default .navbar-nav > .active > a:focus { - color: #555555; + color: #555; background-color: #e7e7e7; } .navbar-default .navbar-nav > .disabled > a, .navbar-default .navbar-nav > .disabled > a:hover, .navbar-default .navbar-nav > .disabled > a:focus { - color: #cccccc; + color: #ccc; background-color: transparent; } .navbar-default .navbar-toggle { - border-color: #dddddd; + border-color: #ddd; } .navbar-default .navbar-toggle:hover, .navbar-default .navbar-toggle:focus { - background-color: #dddddd; + background-color: #ddd; } .navbar-default .navbar-toggle .icon-bar { - background-color: #888888; + background-color: #888; } .navbar-default .navbar-collapse, .navbar-default .navbar-form { @@ -4582,51 +4582,51 @@ select[multiple].input-group-sm > .input-group-btn > .btn { .navbar-default .navbar-nav > .open > a:hover, .navbar-default .navbar-nav > .open > a:focus { background-color: #e7e7e7; - color: #555555; + color: #555; } @media (max-width: 767px) { .navbar-default .navbar-nav .open .dropdown-menu > li > a { - color: #777777; + color: #777; } .navbar-default .navbar-nav .open .dropdown-menu > li > a:hover, .navbar-default .navbar-nav .open .dropdown-menu > li > a:focus { - color: #333333; + color: #333; background-color: transparent; } .navbar-default .navbar-nav .open .dropdown-menu > .active > a, .navbar-default .navbar-nav .open .dropdown-menu > .active > a:hover, .navbar-default .navbar-nav .open .dropdown-menu > .active > a:focus { - color: #555555; + color: #555; background-color: #e7e7e7; } .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a, .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:hover, .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:focus { - color: #cccccc; + color: #ccc; background-color: transparent; } } .navbar-default .navbar-link { - color: #777777; + color: #777; } .navbar-default .navbar-link:hover { - color: #333333; + color: #333; } .navbar-default .btn-link { - color: #777777; + color: #777; } .navbar-default .btn-link:hover, .navbar-default .btn-link:focus { - color: #333333; + color: #333; } .navbar-default .btn-link[disabled]:hover, fieldset[disabled] .navbar-default .btn-link:hover, .navbar-default .btn-link[disabled]:focus, fieldset[disabled] .navbar-default .btn-link:focus { - color: #cccccc; + color: #ccc; } .navbar-inverse { - background-color: #222222; + background-color: #222; border-color: #080808; } .navbar-inverse .navbar-brand { @@ -4634,7 +4634,7 @@ fieldset[disabled] .navbar-default .btn-link:focus { } .navbar-inverse .navbar-brand:hover, .navbar-inverse .navbar-brand:focus { - color: #ffffff; + color: #fff; background-color: transparent; } .navbar-inverse .navbar-text { @@ -4645,30 +4645,30 @@ fieldset[disabled] .navbar-default .btn-link:focus { } .navbar-inverse .navbar-nav > li > a:hover, .navbar-inverse .navbar-nav > li > a:focus { - color: #ffffff; + color: #fff; background-color: transparent; } .navbar-inverse .navbar-nav > .active > a, .navbar-inverse .navbar-nav > .active > a:hover, .navbar-inverse .navbar-nav > .active > a:focus { - color: #ffffff; + color: #fff; background-color: #080808; } .navbar-inverse .navbar-nav > .disabled > a, .navbar-inverse .navbar-nav > .disabled > a:hover, .navbar-inverse .navbar-nav > .disabled > a:focus { - color: #444444; + color: #444; background-color: transparent; } .navbar-inverse .navbar-toggle { - border-color: #333333; + border-color: #333; } .navbar-inverse .navbar-toggle:hover, .navbar-inverse .navbar-toggle:focus { - background-color: #333333; + background-color: #333; } .navbar-inverse .navbar-toggle .icon-bar { - background-color: #ffffff; + background-color: #fff; } .navbar-inverse .navbar-collapse, .navbar-inverse .navbar-form { @@ -4678,7 +4678,7 @@ fieldset[disabled] .navbar-default .btn-link:focus { .navbar-inverse .navbar-nav > .open > a:hover, .navbar-inverse .navbar-nav > .open > a:focus { background-color: #080808; - color: #ffffff; + color: #fff; } @media (max-width: 767px) { .navbar-inverse .navbar-nav .open .dropdown-menu > .dropdown-header { @@ -4692,19 +4692,19 @@ fieldset[disabled] .navbar-default .btn-link:focus { } .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:hover, .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:focus { - color: #ffffff; + color: #fff; background-color: transparent; } .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a, .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:hover, .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:focus { - color: #ffffff; + color: #fff; background-color: #080808; } .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a, .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:hover, .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:focus { - color: #444444; + color: #444; background-color: transparent; } } @@ -4712,20 +4712,20 @@ fieldset[disabled] .navbar-default .btn-link:focus { color: #bfbfbf; } .navbar-inverse .navbar-link:hover { - color: #ffffff; + color: #fff; } .navbar-inverse .btn-link { color: #bfbfbf; } .navbar-inverse .btn-link:hover, .navbar-inverse .btn-link:focus { - color: #ffffff; + color: #fff; } .navbar-inverse .btn-link[disabled]:hover, fieldset[disabled] .navbar-inverse .btn-link:hover, .navbar-inverse .btn-link[disabled]:focus, fieldset[disabled] .navbar-inverse .btn-link:focus { - color: #444444; + color: #444; } .breadcrumb { padding: 8px 15px; @@ -4784,7 +4784,7 @@ fieldset[disabled] .navbar-inverse .btn-link:focus { z-index: 2; color: #00618a; background-color: #ededed; - border-color: #dddddd; + border-color: #ddd; } .pagination > .active > a, .pagination > .active > span, @@ -4793,7 +4793,7 @@ fieldset[disabled] .navbar-inverse .btn-link:focus { .pagination > .active > a:focus, .pagination > .active > span:focus { z-index: 3; - color: #ffffff; + color: #fff; background-color: #00a8e1; border-color: #00a8e1; cursor: default; @@ -4805,8 +4805,8 @@ fieldset[disabled] .navbar-inverse .btn-link:focus { .pagination > .disabled > a:hover, .pagination > .disabled > a:focus { color: #999999; - background-color: #ffffff; - border-color: #dddddd; + background-color: #fff; + border-color: #ddd; cursor: not-allowed; } .pagination-lg > li > a, @@ -4885,7 +4885,7 @@ fieldset[disabled] .navbar-inverse .btn-link:focus { font-size: 75%; font-weight: bold; line-height: 1; - color: #ffffff; + color: #fff; text-align: center; white-space: nowrap; vertical-align: baseline; @@ -4893,7 +4893,7 @@ fieldset[disabled] .navbar-inverse .btn-link:focus { } a.label:hover, a.label:focus { - color: #ffffff; + color: #fff; text-decoration: none; cursor: pointer; } @@ -4952,7 +4952,7 @@ a.label:focus { padding: 3px 7px; font-size: 11px; font-weight: bold; - color: #ffffff; + color: #fff; line-height: 1; vertical-align: middle; white-space: nowrap; @@ -4974,14 +4974,14 @@ a.label:focus { } a.badge:hover, a.badge:focus { - color: #ffffff; + color: #fff; text-decoration: none; cursor: pointer; } .list-group-item.active > .badge, .nav-pills > .active > a > .badge { color: #0099d3; - background-color: #ffffff; + background-color: #fff; } .list-group-item > .badge { float: right; @@ -5041,7 +5041,7 @@ a.badge:focus { margin-bottom: 20px; line-height: 1.66666667; background-color: #ffffff; - border: 1px solid #dddddd; + border: 1px solid #ddd; border-radius: 1px; -webkit-transition: border 0.2s ease-in-out; -o-transition: border 0.2s ease-in-out; @@ -5167,7 +5167,7 @@ a.thumbnail.active { height: 100%; font-size: 11px; line-height: 20px; - color: #ffffff; + color: #fff; text-align: center; background-color: #00a8e1; -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); @@ -5288,7 +5288,7 @@ a.thumbnail.active { display: block; padding: 10px 15px; margin-bottom: -1px; - background-color: #ffffff; + background-color: #fff; border: 1px solid #f2f2f2; } .list-group-item:first-child { @@ -5302,18 +5302,18 @@ a.thumbnail.active { } a.list-group-item, button.list-group-item { - color: #555555; + color: #555; } a.list-group-item .list-group-item-heading, button.list-group-item .list-group-item-heading { - color: #333333; + color: #333; } a.list-group-item:hover, button.list-group-item:hover, a.list-group-item:focus, button.list-group-item:focus { text-decoration: none; - color: #555555; + color: #555; background-color: #d4edfa; } button.list-group-item { @@ -5341,7 +5341,7 @@ button.list-group-item { .list-group-item.active:hover, .list-group-item.active:focus { z-index: 2; - color: #ffffff; + color: #fff; background-color: #00a8e1; border-color: #00a8e1; } @@ -5487,7 +5487,7 @@ button.list-group-item-danger.active:focus { } .panel { margin-bottom: 20px; - background-color: #ffffff; + background-color: #fff; border: 1px solid transparent; border-radius: 1px; -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05); @@ -5721,22 +5721,22 @@ button.list-group-item-danger.active:focus { border-bottom: 1px solid #cecdcd; } .panel-default { - border-color: #dddddd; + border-color: #ddd; } .panel-default > .panel-heading { color: #333333; background-color: #f5f5f5; - border-color: #dddddd; + border-color: #ddd; } .panel-default > .panel-heading + .panel-collapse > .panel-body { - border-top-color: #dddddd; + border-top-color: #ddd; } .panel-default > .panel-heading .badge { color: #f5f5f5; background-color: #333333; } .panel-default > .panel-footer + .panel-collapse > .panel-body { - border-bottom-color: #dddddd; + border-bottom-color: #ddd; } .panel-primary { border-color: #00a8e1; @@ -5881,14 +5881,14 @@ button.list-group-item-danger.active:focus { font-size: 18px; font-weight: bold; line-height: 1; - color: #000000; - text-shadow: 0 1px 0 #ffffff; + color: #000; + text-shadow: 0 1px 0 #fff; opacity: 0.2; filter: alpha(opacity=20); } .close:hover, .close:focus { - color: #000000; + color: #000; text-decoration: none; cursor: pointer; opacity: 0.5; @@ -5943,8 +5943,8 @@ button.close { } .modal-content { position: relative; - background-color: #ffffff; - border: 1px solid #999999; + background-color: #fff; + border: 1px solid #999; border: 1px solid rgba(0, 0, 0, 0.2); border-radius: 1px; -webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5); @@ -5959,7 +5959,7 @@ button.close { bottom: 0; left: 0; z-index: 1040; - background-color: #000000; + background-color: #000; } .modal-backdrop.fade { opacity: 0; @@ -6070,7 +6070,7 @@ button.close { .tooltip-inner { max-width: 220px; padding: 3px 8px; - color: #ffffff; + color: #fff; text-align: center; background-color: #434343; border-radius: 1px; @@ -6162,9 +6162,9 @@ button.close { word-spacing: normal; word-wrap: normal; font-size: 12px; - background-color: #ffffff; + background-color: #fff; background-clip: padding-box; - border: 1px solid #cccccc; + border: 1px solid #ccc; border: 1px solid #bbbbbb; border-radius: 1px; -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); @@ -6222,7 +6222,7 @@ button.close { bottom: 1px; margin-left: -10px; border-bottom-width: 0; - border-top-color: #ffffff; + border-top-color: #fff; } .popover.right > .arrow { top: 50%; @@ -6237,7 +6237,7 @@ button.close { left: 1px; bottom: -10px; border-left-width: 0; - border-right-color: #ffffff; + border-right-color: #fff; } .popover.bottom > .arrow { left: 50%; @@ -6252,7 +6252,7 @@ button.close { top: 1px; margin-left: -10px; border-top-width: 0; - border-bottom-color: #ffffff; + border-bottom-color: #fff; } .popover.left > .arrow { top: 50%; @@ -6266,7 +6266,7 @@ button.close { content: " "; right: 1px; border-right-width: 0; - border-left-color: #ffffff; + border-left-color: #fff; bottom: -10px; } .carousel { @@ -6360,7 +6360,7 @@ button.close { opacity: 0.5; filter: alpha(opacity=50); font-size: 20px; - color: #ffffff; + color: #fff; text-align: center; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); background-color: rgba(0, 0, 0, 0); @@ -6384,7 +6384,7 @@ button.close { .carousel-control:hover, .carousel-control:focus { outline: 0; - color: #ffffff; + color: #fff; text-decoration: none; opacity: 0.9; filter: alpha(opacity=90); @@ -6439,7 +6439,7 @@ button.close { height: 10px; margin: 1px; text-indent: -999px; - border: 1px solid #ffffff; + border: 1px solid #fff; border-radius: 10px; cursor: pointer; background-color: #000 \9; @@ -6449,7 +6449,7 @@ button.close { margin: 0; width: 12px; height: 12px; - background-color: #ffffff; + background-color: #fff; } .carousel-caption { position: absolute; @@ -6459,7 +6459,7 @@ button.close { z-index: 10; padding-top: 20px; padding-bottom: 20px; - color: #ffffff; + color: #fff; text-align: center; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); } @@ -6852,7 +6852,7 @@ button.close { } .fa-border { padding: .2em .25em .15em; - border: solid 0.08em #eeeeee; + border: solid 0.08em #eee; border-radius: .1em; } .fa-pull-left { @@ -6967,7 +6967,7 @@ button.close { font-size: 2em; } .fa-inverse { - color: #ffffff; + color: #fff; } /* Font Awesome uses the Unicode Private Use Area (PUA) to ensure screen readers do not read off random characters that represent icons */ @@ -8975,7 +8975,7 @@ fieldset[disabled] .btn.btn-link { background-repeat: repeat-x; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffcc0000', endColorstr='#ffa30000', GradientType=0); border-color: #781919; - color: #ffffff; + color: #fff; } .btn-danger:hover, .btn-danger:focus, @@ -8985,7 +8985,7 @@ fieldset[disabled] .btn.btn-link { background-color: #a30000; background-image: none; border-color: #781919; - color: #ffffff; + color: #fff; } .btn-danger:active, .btn-danger.active, @@ -9090,7 +9090,7 @@ fieldset[disabled] .btn-default.active { background-repeat: repeat-x; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff00a8e1', endColorstr='#ff0085cf', GradientType=0); border-color: #006e9c; - color: #ffffff; + color: #fff; } .btn-primary:hover, .btn-primary:focus, @@ -9100,7 +9100,7 @@ fieldset[disabled] .btn-default.active { background-color: #0085cf; background-image: none; border-color: #006e9c; - color: #ffffff; + color: #fff; } .btn-primary:active, .btn-primary.active, @@ -9183,7 +9183,7 @@ fieldset[disabled] .btn-primary.active { .dropdown-menu > li > a:active { background-color: #0099d3; border-color: #0076b7; - color: #ffffff !important; + color: #fff !important; filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); } .dropdown-menu > .active > a, @@ -9294,7 +9294,7 @@ fieldset[disabled] .btn-primary.active { top: -11px; } .dropdown-kebab-pf .dropdown-menu:after { - border-bottom-color: #ffffff; + border-bottom-color: #fff; top: -10px; } .dropdown-kebab-pf.dropup .dropdown-menu { @@ -9311,7 +9311,7 @@ fieldset[disabled] .btn-primary.active { top: auto; } .dropdown-kebab-pf.dropup .dropdown-menu:after { - border-top-color: #ffffff; + border-top-color: #fff; bottom: -10px; } .chars-remaining-pf span { @@ -9330,7 +9330,7 @@ fieldset[disabled] .form-control { color: #969696; } .form-control:hover { - border-color: #7bb2dd; + border-color: #7BB2DD; } .has-error .form-control:hover { border-color: #843534; @@ -10070,7 +10070,7 @@ td > .progress:first-child:last-child { .nav-tabs-pf > li > a:active:before, .nav-tabs-pf > li > a:focus:before, .nav-tabs-pf > li > a:hover:before { - background: #aaaaaa; + background: #aaa; bottom: -1px; content: ''; display: block; diff --git a/dist/docs/grunt-scripts/angular-animate.js b/dist/docs/grunt-scripts/angular-animate.js index 2778fc564..1652a9bba 100644 --- a/dist/docs/grunt-scripts/angular-animate.js +++ b/dist/docs/grunt-scripts/angular-animate.js @@ -1,5 +1,5 @@ /** - * @license AngularJS v1.5.0 + * @license AngularJS v1.5.2 * (c) 2010-2016 Google, Inc. http://angularjs.org * License: MIT */ @@ -2337,7 +2337,7 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { return matches; } - return { + var $animate = { on: function(event, container, callback) { var node = extractElementNode(container); callbackRegistry[event] = callbackRegistry[event] || []; @@ -2345,6 +2345,11 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { node: node, callback: callback }); + + // Remove the callback when the element is removed from the DOM + jqLite(container).on('$destroy', function() { + $animate.off(event, container, callback); + }); }, off: function(event, container, callback) { @@ -2412,6 +2417,8 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { } }; + return $animate; + function queueAnimation(element, event, initialOptions) { // we always make a copy of the options since // there should never be any side effects on @@ -2728,30 +2735,31 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { var animateChildren; var elementDisabled = disabledElementsLookup.get(getDomNode(element)); - var parentHost = element.data(NG_ANIMATE_PIN_DATA); + var parentHost = jqLite.data(element[0], NG_ANIMATE_PIN_DATA); if (parentHost) { parentElement = parentHost; } - while (parentElement && parentElement.length) { + parentElement = getDomNode(parentElement); + + while (parentElement) { if (!rootElementDetected) { // angular doesn't want to attempt to animate elements outside of the application // therefore we need to ensure that the rootElement is an ancestor of the current element rootElementDetected = isMatchingElement(parentElement, $rootElement); } - var parentNode = parentElement[0]; - if (parentNode.nodeType !== ELEMENT_NODE) { + if (parentElement.nodeType !== ELEMENT_NODE) { // no point in inspecting the #document element break; } - var details = activeAnimationsLookup.get(parentNode) || {}; + var details = activeAnimationsLookup.get(parentElement) || {}; // either an enter, leave or move animation will commence // therefore we can't allow any animations to take place // but if a parent animation is class-based then that's ok if (!parentAnimationDetected) { - var parentElementDisabled = disabledElementsLookup.get(parentNode); + var parentElementDisabled = disabledElementsLookup.get(parentElement); if (parentElementDisabled === true && elementDisabled !== false) { // disable animations if the user hasn't explicitly enabled animations on the @@ -2766,7 +2774,7 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { } if (isUndefined(animateChildren) || animateChildren === true) { - var value = parentElement.data(NG_ANIMATE_CHILDREN_DATA); + var value = jqLite.data(parentElement, NG_ANIMATE_CHILDREN_DATA); if (isDefined(value)) { animateChildren = value; } @@ -2789,15 +2797,15 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { if (!rootElementDetected) { // If no rootElement is detected, check if the parentElement is pinned to another element - parentHost = parentElement.data(NG_ANIMATE_PIN_DATA); + parentHost = jqLite.data(parentElement, NG_ANIMATE_PIN_DATA); if (parentHost) { // The pin target element becomes the next parent element - parentElement = parentHost; + parentElement = getDomNode(parentHost); continue; } } - parentElement = parentElement.parent(); + parentElement = parentElement.parentNode; } var allowAnimation = (!parentAnimationDetected || animateChildren) && elementDisabled !== true; @@ -3238,11 +3246,17 @@ var $$AnimationProvider = ['$animateProvider', function($animateProvider) { * * ngAnimateSwap is a animation-oriented directive that allows for the container to * be removed and entered in whenever the associated expression changes. A - * common usecase for this directive is a rotating banner component which + * common usecase for this directive is a rotating banner or slider component which * contains one image being present at a time. When the active image changes * then the old image will perform a `leave` animation and the new element * will be inserted via an `enter` animation. * + * @animations + * | Animation | Occurs | + * |----------------------------------|--------------------------------------| + * | {@link ng.$animate#enter enter} | when the new element is inserted to the DOM | + * | {@link ng.$animate#leave leave} | when the old element is removed from the DOM | + * * @example * ` or `` tags. * - * Only one AngularJS application can be auto-bootstrapped per HTML document. The first `ngApp` - * found in the document will be used to define the root element to auto-bootstrap as an - * application. To run multiple applications in an HTML document you must manually bootstrap them using - * {@link angular.bootstrap} instead. AngularJS applications cannot be nested within each other. + * There are a few things to keep in mind when using `ngApp`: + * - only one AngularJS application can be auto-bootstrapped per HTML document. The first `ngApp` + * found in the document will be used to define the root element to auto-bootstrap as an + * application. To run multiple applications in an HTML document you must manually bootstrap them using + * {@link angular.bootstrap} instead. + * - AngularJS applications cannot be nested within each other. + * - Do not use a directive that uses {@link ng.$compile#transclusion transclusion} on the same element as `ngApp`. + * This includes directives such as {@link ng.ngIf `ngIf`}, {@link ng.ngInclude `ngInclude`} and + * {@link ngRoute.ngView `ngView`}. + * Doing this misplaces the app {@link ng.$rootElement `$rootElement`} and the app's {@link auto.$injector injector}, + * causing animations to stop working and making the injector inaccessible from outside the app. * * You can specify an **AngularJS module** to be used as the root module for the application. This * module will be loaded into the {@link auto.$injector} when the application is bootstrapped. It @@ -1614,16 +1624,25 @@ function angularInit(element, bootstrap) { * @description * Use this function to manually start up angular application. * - * See: {@link guide/bootstrap Bootstrap} - * - * Note that Protractor based end-to-end tests cannot use this function to bootstrap manually. - * They must use {@link ng.directive:ngApp ngApp}. + * For more information, see the {@link guide/bootstrap Bootstrap guide}. * * Angular will detect if it has been loaded into the browser more than once and only allow the * first loaded script to be bootstrapped and will report a warning to the browser console for * each of the subsequent scripts. This prevents strange results in applications, where otherwise * multiple instances of Angular try to work on the DOM. * + *
+ * **Note:** Protractor based end-to-end tests cannot use this function to bootstrap manually. + * They must use {@link ng.directive:ngApp ngApp}. + *
+ * + *
+ * **Note:** Do not bootstrap the app on an element with a directive that uses {@link ng.$compile#transclusion transclusion}, + * such as {@link ng.ngIf `ngIf`}, {@link ng.ngInclude `ngInclude`} and {@link ngRoute.ngView `ngView`}. + * Doing this misplaces the app {@link ng.$rootElement `$rootElement`} and the app's {@link auto.$injector injector}, + * causing animations to stop working and making the injector inaccessible from outside the app. + *
+ * * ```html * * @@ -2424,11 +2443,11 @@ function toDebugString(obj) { * - `codeName` – `{string}` – Code name of the release, such as "jiggling-armfat". */ var version = { - full: '1.5.0', // all of these placeholder strings will be replaced by grunt's + full: '1.5.2', // all of these placeholder strings will be replaced by grunt's major: 1, // package task minor: 5, - dot: 0, - codeName: 'ennoblement-facilitation' + dot: 2, + codeName: 'differential-recovery' }; @@ -4287,14 +4306,13 @@ function annotate(fn, strictDi, name) { * @description * * Register a **value service** with the {@link auto.$injector $injector}, such as a string, a - * number, an array, an object or a function. This is short for registering a service where its + * number, an array, an object or a function. This is short for registering a service where its * provider's `$get` property is a factory function that takes no arguments and returns the **value - * service**. + * service**. That also means it is not possible to inject other services into a value service. * * Value services are similar to constant services, except that they cannot be injected into a * module configuration function (see {@link angular.Module#config}) but they can be overridden by - * an Angular - * {@link auto.$provide#decorator decorator}. + * an Angular {@link auto.$provide#decorator decorator}. * * @param {string} name The name of the instance. * @param {*} value The value. @@ -4319,8 +4337,11 @@ function annotate(fn, strictDi, name) { * @name $provide#constant * @description * - * Register a **constant service**, such as a string, a number, an array, an object or a function, - * with the {@link auto.$injector $injector}. Unlike {@link auto.$provide#value value} it can be + * Register a **constant service** with the {@link auto.$injector $injector}, such as a string, + * a number, an array, an object or a function. Like the {@link auto.$provide#value value}, it is not + * possible to inject other services into a constant. + * + * But unlike {@link auto.$provide#value value}, a constant can be * injected into a module configuration function (see {@link angular.Module#config}) and it cannot * be overridden by an Angular {@link auto.$provide#decorator decorator}. * @@ -4959,7 +4980,7 @@ function prepareAnimateOptions(options) { } var $$CoreAnimateJsProvider = function() { - this.$get = function() {}; + this.$get = noop; }; // this is prefixed with Core since it conflicts with @@ -5779,7 +5800,6 @@ var $CoreAnimateCssProvider = function() { */ function Browser(window, document, $log, $sniffer) { var self = this, - rawDocument = document[0], location = window.location, history = window.history, setTimeout = window.setTimeout, @@ -7367,6 +7387,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { // The assumption is that future DOM event attribute names will begin with // 'on' and be composed of only English letters. var EVENT_HANDLER_ATTR_REGEXP = /^(on[a-z]+|formaction)$/; + var bindingCache = createMap(); function parseIsolateBindings(scope, directiveName, isController) { var LOCAL_REGEXP = /^\s*([@&<]|=(\*?))(\??)\s*(\w*)\s*$/; @@ -7374,6 +7395,10 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { var bindings = {}; forEach(scope, function(definition, scopeName) { + if (definition in bindingCache) { + bindings[scopeName] = bindingCache[definition]; + return; + } var match = definition.match(LOCAL_REGEXP); if (!match) { @@ -7391,6 +7416,9 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { optional: match[3] === '?', attrName: match[4] || scopeName }; + if (match[4]) { + bindingCache[definition] = bindings[scopeName]; + } }); return bindings; @@ -7460,7 +7488,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { * {@link guide/directive directive guide} and the {@link $compile compile API} for more info. * @returns {ng.$compileProvider} Self for chaining. */ - this.directive = function registerDirective(name, directiveFactory) { + this.directive = function registerDirective(name, directiveFactory) { assertNotHasOwnProperty(name, 'directive'); if (isString(name)) { assertValidDirectiveName(name); @@ -7483,11 +7511,6 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { directive.name = directive.name || name; directive.require = directive.require || (directive.controller && directive.name); directive.restrict = directive.restrict || 'EA'; - var bindings = directive.$$bindings = - parseDirectiveBindings(directive, directive.name); - if (isObject(bindings.isolateScope)) { - directive.$$isolateBindings = bindings.isolateScope; - } directive.$$moduleName = directiveFactory.$$moduleName; directives.push(directive); } catch (e) { @@ -7543,7 +7566,8 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { * See {@link ng.$compile#-bindtocontroller- `bindToController`}. * - `transclude` – `{boolean=}` – whether {@link $compile#transclusion content transclusion} is enabled. * Disabled by default. - * - `$...` – `{function()=}` – additional annotations to provide to the directive factory function. + * - `$...` – additional properties to attach to the directive factory function and the controller + * constructor function. (This is used by the component router to annotate) * * @returns {ng.$compileProvider} the compile provider itself, for chaining of function calls. * @description @@ -7575,7 +7599,8 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { * * myMod.component('myComp', { * templateUrl: 'views/my-comp.html', - * controller: 'MyCtrl as ctrl', + * controller: 'MyCtrl', + * controllerAs: 'ctrl', * bindings: {name: '@'} * }); * @@ -7586,7 +7611,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { * See also {@link ng.$compileProvider#directive $compileProvider.directive()}. */ this.component = function registerComponent(name, options) { - var controller = options.controller || function() {}; + var controller = options.controller || noop; function factory($injector) { function makeInjectable(fn) { @@ -7618,6 +7643,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { forEach(options, function(val, key) { if (key.charAt(0) === '$') { factory[key] = val; + controller[key] = val; } }); @@ -7725,7 +7751,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { var SIMPLE_ATTR_NAME = /^\w/; var specialAttrHolder = document.createElement('div'); - var Attributes = function(element, attributesToCopy) { + function Attributes(element, attributesToCopy) { if (attributesToCopy) { var keys = Object.keys(attributesToCopy); var i, l, key; @@ -7739,7 +7765,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { } this.$$element = element; - }; + } Attributes.prototype = { /** @@ -8020,6 +8046,14 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { safeAddClass($element, isolated ? 'ng-isolate-scope' : 'ng-scope'); } : noop; + compile.$$createComment = function(directiveName, comment) { + var content = ''; + if (debugInfoEnabled) { + content = ' ' + (directiveName || '') + ': ' + (comment || '') + ' '; + } + return document.createComment(content); + }; + return compile; //================================ @@ -8233,8 +8267,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { } function createBoundTranscludeFn(scope, transcludeFn, previousBoundTranscludeFn) { - - var boundTranscludeFn = function(transcludedScope, cloneFn, controllers, futureParentElement, containingScope) { + function boundTranscludeFn(transcludedScope, cloneFn, controllers, futureParentElement, containingScope) { if (!transcludedScope) { transcludedScope = scope.$new(false, containingScope); @@ -8246,7 +8279,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { transcludeControllers: controllers, futureParentElement: futureParentElement }); - }; + } // We need to attach the transclusion slots onto the `boundTranscludeFn` // so that they are available inside the `controllersBoundTransclude` function @@ -8411,7 +8444,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { * @returns {Function} */ function groupElementsLinkFnWrapper(linkFn, attrStart, attrEnd) { - return function(scope, element, attrs, controllers, transcludeFn) { + return function groupedElementsLink(scope, element, attrs, controllers, transcludeFn) { element = groupScan(element[0], attrStart, attrEnd); return linkFn(scope, element, attrs, controllers, transcludeFn); }; @@ -8429,23 +8462,21 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { * @returns {Function} */ function compilationGenerator(eager, $compileNodes, transcludeFn, maxPriority, ignoreDirective, previousCompileContext) { - if (eager) { - return compile($compileNodes, transcludeFn, maxPriority, ignoreDirective, previousCompileContext); - } + var compiled; - var compiled; - - return function() { - if (!compiled) { - compiled = compile($compileNodes, transcludeFn, maxPriority, ignoreDirective, previousCompileContext); - - // Null out all of these references in order to make them eligible for garbage collection - // since this is a potentially long lived closure - $compileNodes = transcludeFn = previousCompileContext = null; - } + if (eager) { + return compile($compileNodes, transcludeFn, maxPriority, ignoreDirective, previousCompileContext); + } + return function lazyCompilation() { + if (!compiled) { + compiled = compile($compileNodes, transcludeFn, maxPriority, ignoreDirective, previousCompileContext); - return compiled.apply(this, arguments); - }; + // Null out all of these references in order to make them eligible for garbage collection + // since this is a potentially long lived closure + $compileNodes = transcludeFn = previousCompileContext = null; + } + return compiled.apply(this, arguments); + }; } /** @@ -8581,8 +8612,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { terminalPriority = directive.priority; $template = $compileNode; $compileNode = templateAttrs.$$element = - jqLite(document.createComment(' ' + directiveName + ': ' + - templateAttrs[directiveName] + ' ')); + jqLite(compile.$$createComment(directiveName, templateAttrs[directiveName])); compileNode = $compileNode[0]; replaceWith(jqCollection, sliceArgs($template), compileNode); @@ -8788,82 +8818,6 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { } } - - function getControllers(directiveName, require, $element, elementControllers) { - var value; - - if (isString(require)) { - var match = require.match(REQUIRE_PREFIX_REGEXP); - var name = require.substring(match[0].length); - var inheritType = match[1] || match[3]; - var optional = match[2] === '?'; - - //If only parents then start at the parent element - if (inheritType === '^^') { - $element = $element.parent(); - //Otherwise attempt getting the controller from elementControllers in case - //the element is transcluded (and has no data) and to avoid .data if possible - } else { - value = elementControllers && elementControllers[name]; - value = value && value.instance; - } - - if (!value) { - var dataName = '$' + name + 'Controller'; - value = inheritType ? $element.inheritedData(dataName) : $element.data(dataName); - } - - if (!value && !optional) { - throw $compileMinErr('ctreq', - "Controller '{0}', required by directive '{1}', can't be found!", - name, directiveName); - } - } else if (isArray(require)) { - value = []; - for (var i = 0, ii = require.length; i < ii; i++) { - value[i] = getControllers(directiveName, require[i], $element, elementControllers); - } - } else if (isObject(require)) { - value = {}; - forEach(require, function(controller, property) { - value[property] = getControllers(directiveName, controller, $element, elementControllers); - }); - } - - return value || null; - } - - function setupControllers($element, attrs, transcludeFn, controllerDirectives, isolateScope, scope) { - var elementControllers = createMap(); - for (var controllerKey in controllerDirectives) { - var directive = controllerDirectives[controllerKey]; - var locals = { - $scope: directive === newIsolateScopeDirective || directive.$$isolateScope ? isolateScope : scope, - $element: $element, - $attrs: attrs, - $transclude: transcludeFn - }; - - var controller = directive.controller; - if (controller == '@') { - controller = attrs[directive.name]; - } - - var controllerInstance = $controller(controller, locals, true, directive.controllerAs); - - // For directives with element transclusion the element is a comment, - // but jQuery .data doesn't support attaching data to comment nodes as it's hard to - // clean up (http://bugs.jquery.com/ticket/8335). - // Instead, we save the controllers for the element in a local hash and attach to .data - // later, once we have the actual element. - elementControllers[directive.name] = controllerInstance; - if (!hasElementTranscludeDirective) { - $element.data('$' + directive.name + 'Controller', controllerInstance.instance); - } - } - return elementControllers; - } - function nodeLinkFn(childLinkFn, scope, linkNode, $rootElement, boundTranscludeFn) { var i, ii, linkFn, isolateScope, controllerScope, elementControllers, transcludeFn, $element, attrs, removeScopeBindingWatches, removeControllerBindingWatches; @@ -8895,7 +8849,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { } if (controllerDirectives) { - elementControllers = setupControllers($element, attrs, transcludeFn, controllerDirectives, isolateScope, scope); + elementControllers = setupControllers($element, attrs, transcludeFn, controllerDirectives, isolateScope, scope, newIsolateScopeDirective); } if (newIsolateScopeDirective) { @@ -9023,6 +8977,78 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { } } + function getControllers(directiveName, require, $element, elementControllers) { + var value; + + if (isString(require)) { + var match = require.match(REQUIRE_PREFIX_REGEXP); + var name = require.substring(match[0].length); + var inheritType = match[1] || match[3]; + var optional = match[2] === '?'; + + //If only parents then start at the parent element + if (inheritType === '^^') { + $element = $element.parent(); + //Otherwise attempt getting the controller from elementControllers in case + //the element is transcluded (and has no data) and to avoid .data if possible + } else { + value = elementControllers && elementControllers[name]; + value = value && value.instance; + } + + if (!value) { + var dataName = '$' + name + 'Controller'; + value = inheritType ? $element.inheritedData(dataName) : $element.data(dataName); + } + + if (!value && !optional) { + throw $compileMinErr('ctreq', + "Controller '{0}', required by directive '{1}', can't be found!", + name, directiveName); + } + } else if (isArray(require)) { + value = []; + for (var i = 0, ii = require.length; i < ii; i++) { + value[i] = getControllers(directiveName, require[i], $element, elementControllers); + } + } else if (isObject(require)) { + value = {}; + forEach(require, function(controller, property) { + value[property] = getControllers(directiveName, controller, $element, elementControllers); + }); + } + + return value || null; + } + + function setupControllers($element, attrs, transcludeFn, controllerDirectives, isolateScope, scope, newIsolateScopeDirective) { + var elementControllers = createMap(); + for (var controllerKey in controllerDirectives) { + var directive = controllerDirectives[controllerKey]; + var locals = { + $scope: directive === newIsolateScopeDirective || directive.$$isolateScope ? isolateScope : scope, + $element: $element, + $attrs: attrs, + $transclude: transcludeFn + }; + + var controller = directive.controller; + if (controller == '@') { + controller = attrs[directive.name]; + } + + var controllerInstance = $controller(controller, locals, true, directive.controllerAs); + + // For directives with element transclusion the element is a comment. + // In this case .data will not attach any data. + // Instead, we save the controllers for the element in a local hash and attach to .data + // later, once we have the actual element. + elementControllers[directive.name] = controllerInstance; + $element.data('$' + directive.name + 'Controller', controllerInstance.instance); + } + return elementControllers; + } + // Depending upon the context in which a directive finds itself it might need to have a new isolated // or child scope created. For instance: // * if the directive has been pulled into a template because another directive with a higher priority @@ -9063,6 +9089,13 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { if (startAttrName) { directive = inherit(directive, {$$start: startAttrName, $$end: endAttrName}); } + if (!directive.$$bindings) { + var bindings = directive.$$bindings = + parseDirectiveBindings(directive, directive.name); + if (isObject(bindings.isolateScope)) { + directive.$$isolateBindings = bindings.isolateScope; + } + } tDirectives.push(directive); match = directive; } @@ -9500,7 +9533,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { // only occurs for isolate scopes and new scopes with controllerAs. function initializeDirectiveBindings(scope, attrs, destination, bindings, directive) { var removeWatchCollection = []; - forEach(bindings, function(definition, scopeName) { + forEach(bindings, function initializeBinding(definition, scopeName) { var attrName = definition.attrName, optional = definition.optional, mode = definition.mode, // @, =, or & @@ -9542,7 +9575,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { if (parentGet.literal) { compare = equals; } else { - compare = function(a, b) { return a === b || (a !== a && b !== b); }; + compare = function simpleCompare(a, b) { return a === b || (a !== a && b !== b); }; } parentSet = parentGet.assign || function() { // reset the change, or we will throw this exception on every $digest @@ -9744,6 +9777,15 @@ function $ControllerProvider() { var controllers = {}, globals = false; + /** + * @ngdoc method + * @name $controllerProvider#has + * @param {string} name Controller name to check. + */ + this.has = function(name) { + return controllers.hasOwnProperty(name); + }; + /** * @ngdoc method * @name $controllerProvider#register @@ -9800,7 +9842,7 @@ function $ControllerProvider() { * It's just a simple call to {@link auto.$injector $injector}, but extracted into * a service, so that one can override this service with [BC version](https://gist.github.com/1649788). */ - return function(expression, locals, later, ident) { + return function $controller(expression, locals, later, ident) { // PRIVATE API: // param `later` --- indicates that the controller's constructor is invoked at a later time. // If true, $controller will allocate the object with the correct @@ -9851,7 +9893,7 @@ function $ControllerProvider() { } var instantiate; - return instantiate = extend(function() { + return instantiate = extend(function $controllerInit() { var result = $injector.invoke(expression, instance, locals, constructor); if (result !== instance && (isObject(result) || isFunction(result))) { instance = result; @@ -10037,7 +10079,7 @@ function $HttpParamSerializerProvider() { forEachSorted(params, function(value, key) { if (value === null || isUndefined(value)) return; if (isArray(value)) { - forEach(value, function(v, k) { + forEach(value, function(v) { parts.push(encodeUriQuery(key) + '=' + encodeUriQuery(serializeValue(v))); }); } else { @@ -10247,10 +10289,9 @@ function $HttpProvider() { * * Object containing default values for all {@link ng.$http $http} requests. * - * - **`defaults.cache`** - {Object} - an object built with {@link ng.$cacheFactory `$cacheFactory`} - * that will provide the cache for all requests who set their `cache` property to `true`. - * If you set the `defaults.cache = false` then only requests that specify their own custom - * cache object will be cached. See {@link $http#caching $http Caching} for more information. + * - **`defaults.cache`** - {boolean|Object} - A boolean value or object created with + * {@link ng.$cacheFactory `$cacheFactory`} to enable or disable caching of HTTP responses + * by default. See {@link $http#caching $http Caching} for more information. * * - **`defaults.xsrfCookieName`** - {string} - Name of cookie containing the XSRF token. * Defaults value is `'XSRF-TOKEN'`. @@ -10541,6 +10582,15 @@ function $HttpProvider() { * the transformed value (`function(data, headersGetter, status)`) or an array of such transformation functions, * which allows you to `push` or `unshift` a new transformation function into the transformation chain. * + *
+ * **Note:** Angular does not make a copy of the `data` parameter before it is passed into the `transformRequest` pipeline. + * That means changes to the properties of `data` are not local to the transform function (since Javascript passes objects by reference). + * For example, when calling `$http.get(url, $scope.myObject)`, modifications to the object's properties in a transformRequest + * function will be reflected on the scope and in any templates where the object is data-bound. + * To prevent his, transform functions should have no side-effects. + * If you need to modify properties, it is recommended to make a copy of the data, or create new object to return. + *
+ * * ### Default Transformations * * The `$httpProvider` provider and `$http` service expose `defaults.transformRequest` and @@ -10598,26 +10648,35 @@ function $HttpProvider() { * * ## Caching * - * To enable caching, set the request configuration `cache` property to `true` (to use default - * cache) or to a custom cache object (built with {@link ng.$cacheFactory `$cacheFactory`}). - * When the cache is enabled, `$http` stores the response from the server in the specified - * cache. The next time the same request is made, the response is served from the cache without - * sending a request to the server. + * {@link ng.$http `$http`} responses are not cached by default. To enable caching, you must + * set the config.cache value or the default cache value to TRUE or to a cache object (created + * with {@link ng.$cacheFactory `$cacheFactory`}). If defined, the value of config.cache takes + * precedence over the default cache value. + * + * In order to: + * * cache all responses - set the default cache value to TRUE or to a cache object + * * cache a specific response - set config.cache value to TRUE or to a cache object + * + * If caching is enabled, but neither the default cache nor config.cache are set to a cache object, + * then the default `$cacheFactory($http)` object is used. * - * Note that even if the response is served from cache, delivery of the data is asynchronous in - * the same way that real requests are. + * The default cache value can be set by updating the + * {@link ng.$http#defaults `$http.defaults.cache`} property or the + * {@link $httpProvider#defaults `$httpProvider.defaults.cache`} property. * - * If there are multiple GET requests for the same URL that should be cached using the same - * cache, but the cache is not populated yet, only one request to the server will be made and - * the remaining requests will be fulfilled using the response from the first request. + * When caching is enabled, {@link ng.$http `$http`} stores the response from the server using + * the relevant cache object. The next time the same request is made, the response is returned + * from the cache without sending a request to the server. * - * You can change the default cache to a new object (built with - * {@link ng.$cacheFactory `$cacheFactory`}) by updating the - * {@link ng.$http#defaults `$http.defaults.cache`} property. All requests who set - * their `cache` property to `true` will now use this cache object. + * Take note that: + * + * * Only GET and JSONP requests are cached. + * * The cache key is the request URL including search parameters; headers are not considered. + * * Cached responses are returned asynchronously, in the same way as responses from the server. + * * If multiple identical requests are made using the same cache, which is not yet populated, + * one request will be made to the server and remaining requests will return the same response. + * * A cache-control header on the response does not affect if or how responses are cached. * - * If you set the default cache to `false` then only requests that specify their own custom - * cache object will be cached. * * ## Interceptors * @@ -10787,7 +10846,7 @@ function $HttpProvider() { * transform function or an array of such functions. The transform function takes the http * response body, headers and status and returns its transformed (typically deserialized) version. * See {@link ng.$http#overriding-the-default-transformations-per-request - * Overriding the Default TransformationjqLiks} + * Overriding the Default Transformations} * - **paramSerializer** - `{string|function(Object):string}` - A function used to * prepare the string representation of request parameters (specified as an object). * If specified as string, it is interpreted as function registered with the @@ -10795,10 +10854,9 @@ function $HttpProvider() { * by registering it as a {@link auto.$provide#service service}. * The default serializer is the {@link $httpParamSerializer $httpParamSerializer}; * alternatively, you can use the {@link $httpParamSerializerJQLike $httpParamSerializerJQLike} - * - **cache** – `{boolean|Cache}` – If true, a default $http cache will be used to cache the - * GET request, otherwise if a cache instance built with - * {@link ng.$cacheFactory $cacheFactory}, this cache will be used for - * caching. + * - **cache** – `{boolean|Object}` – A boolean value or object created with + * {@link ng.$cacheFactory `$cacheFactory`} to enable or disable caching of the HTTP response. + * See {@link $http#caching $http Caching} for more information. * - **timeout** – `{number|Promise}` – timeout in milliseconds, or {@link ng.$q promise} * that should abort the request when resolved. * - **withCredentials** - `{boolean}` - whether to set the `withCredentials` flag on the @@ -13709,8 +13767,10 @@ AST.prototype = { primary = this.arrayDeclaration(); } else if (this.expect('{')) { primary = this.object(); - } else if (this.constants.hasOwnProperty(this.peek().text)) { - primary = copy(this.constants[this.consume().text]); + } else if (this.selfReferential.hasOwnProperty(this.peek().text)) { + primary = copy(this.selfReferential[this.consume().text]); + } else if (this.options.literals.hasOwnProperty(this.peek().text)) { + primary = { type: AST.Literal, value: this.options.literals[this.consume().text]}; } else if (this.peek().identifier) { primary = this.identifier(); } else if (this.peek().constant) { @@ -13862,15 +13922,7 @@ AST.prototype = { return false; }, - - /* `undefined` is not a constant, it is an identifier, - * but using it as an identifier is not supported - */ - constants: { - 'true': { type: AST.Literal, value: true }, - 'false': { type: AST.Literal, value: false }, - 'null': { type: AST.Literal, value: null }, - 'undefined': {type: AST.Literal, value: undefined }, + selfReferential: { 'this': {type: AST.ThisExpression }, '$locals': {type: AST.LocalsExpression } } @@ -14560,7 +14612,7 @@ ASTInterpreter.prototype = { forEach(ast.body, function(expression) { expressions.push(self.recurse(expression.expression)); }); - var fn = ast.body.length === 0 ? function() {} : + var fn = ast.body.length === 0 ? noop : ast.body.length === 1 ? expressions[0] : function(scope, locals) { var lastValue; @@ -14701,7 +14753,7 @@ ASTInterpreter.prototype = { return context ? {value: locals} : locals; }; case AST.NGValueParameter: - return function(scope, locals, assign, inputs) { + return function(scope, locals, assign) { return context ? {value: assign} : assign; }; } @@ -14915,7 +14967,7 @@ var Parser = function(lexer, $filter, options) { this.lexer = lexer; this.$filter = $filter; this.options = options; - this.ast = new AST(this.lexer); + this.ast = new AST(lexer, options); this.astCompiler = options.csp ? new ASTInterpreter(this.ast, $filter) : new ASTCompiler(this.ast, $filter); }; @@ -14992,16 +15044,39 @@ function getValueOf(value) { function $ParseProvider() { var cacheDefault = createMap(); var cacheExpensive = createMap(); + var literals = { + 'true': true, + 'false': false, + 'null': null, + 'undefined': undefined + }; + + /** + * @ngdoc method + * @name $parseProvider#addLiteral + * @description + * + * Configure $parse service to add literal values that will be present as literal at expressions. + * + * @param {string} literalName Token for the literal value. The literal name value must be a valid literal name. + * @param {*} literalValue Value for this literal. All literal values must be primitives or `undefined`. + * + **/ + this.addLiteral = function(literalName, literalValue) { + literals[literalName] = literalValue; + }; this.$get = ['$filter', function($filter) { var noUnsafeEval = csp().noUnsafeEval; var $parseOptions = { csp: noUnsafeEval, - expensiveChecks: false + expensiveChecks: false, + literals: copy(literals) }, $parseOptionsExpensive = { csp: noUnsafeEval, - expensiveChecks: true + expensiveChecks: true, + literals: copy(literals) }; var runningChecksEnabled = false; @@ -15423,7 +15498,7 @@ function $ParseProvider() { * - Q has many more features than $q, but that comes at a cost of bytes. $q is tiny, but contains * all the important functionality needed for common async tasks. * - * # Testing + * # Testing * * ```js * it('should simulate promise', inject(function($q, $rootScope) { @@ -16611,7 +16686,7 @@ function $RootScopeProvider() { dirty, ttl = TTL, next, current, target = this, watchLog = [], - logIdx, logMsg, asyncTask; + logIdx, asyncTask; beginPhase('$digest'); // Check for changes to browser url that happened in sync before the call to $digest @@ -18466,7 +18541,7 @@ function $SnifferProvider() { }]; } -var $compileMinErr = minErr('$compile'); +var $templateRequestMinErr = minErr('$compile'); /** * @ngdoc provider @@ -18562,7 +18637,7 @@ function $TemplateRequestProvider() { function handleError(resp) { if (!ignoreRequestError) { - throw $compileMinErr('tpload', 'Failed to load template: {0} (HTTP status: {1} {2})', + throw $templateRequestMinErr('tpload', 'Failed to load template: {0} (HTTP status: {1} {2})', tpl, resp.status, resp.statusText); } return $q.reject(resp); @@ -19484,7 +19559,7 @@ function currencyFilter($locale) { * Formats a number as text. * * If the input is null or undefined, it will just be returned. - * If the input is infinite (Infinity/-Infinity) the Infinity symbol '∞' is returned. + * If the input is infinite (Infinity or -Infinity), the Infinity symbol '∞' or '-∞' is returned, respectively. * If the input is not a number an empty string is returned. * * @@ -19574,7 +19649,7 @@ function parse(numStr) { } // Count the number of leading zeros. - for (i = 0; numStr.charAt(i) == ZERO_CHAR; i++); + for (i = 0; numStr.charAt(i) == ZERO_CHAR; i++) {/* jshint noempty: false */} if (i == (zeros = numStr.length)) { // The digits are all zero. @@ -19620,18 +19695,37 @@ function roundNumber(parsedNumber, fractionSize, minFrac, maxFrac) { var digit = digits[roundAt]; if (roundAt > 0) { - digits.splice(roundAt); + // Drop fractional digits beyond `roundAt` + digits.splice(Math.max(parsedNumber.i, roundAt)); + + // Set non-fractional digits beyond `roundAt` to 0 + for (var j = roundAt; j < digits.length; j++) { + digits[j] = 0; + } } else { // We rounded to zero so reset the parsedNumber + fractionLen = Math.max(0, fractionLen); parsedNumber.i = 1; - digits.length = roundAt = fractionSize + 1; - for (var i=0; i < roundAt; i++) digits[i] = 0; + digits.length = Math.max(1, roundAt = fractionSize + 1); + digits[0] = 0; + for (var i = 1; i < roundAt; i++) digits[i] = 0; } - if (digit >= 5) digits[roundAt - 1]++; + if (digit >= 5) { + if (roundAt - 1 < 0) { + for (var k = 0; k > roundAt; k--) { + digits.unshift(0); + parsedNumber.i++; + } + digits.unshift(1); + parsedNumber.i++; + } else { + digits[roundAt - 1]++; + } + } // Pad out with zeros to get the required fraction length - for (; fractionLen < fractionSize; fractionLen++) digits.push(0); + for (; fractionLen < Math.max(0, fractionSize); fractionLen++) digits.push(0); // Do any carrying, e.g. a digit was rounded up to 10 @@ -19730,11 +19824,15 @@ function formatNumber(number, pattern, groupSep, decimalSep, fractionSize) { } } -function padNumber(num, digits, trim) { +function padNumber(num, digits, trim, negWrap) { var neg = ''; - if (num < 0) { - neg = '-'; - num = -num; + if (num < 0 || (negWrap && num <= 0)) { + if (negWrap) { + num = -num + 1; + } else { + num = -num; + neg = '-'; + } } num = '' + num; while (num.length < digits) num = ZERO_CHAR + num; @@ -19745,7 +19843,7 @@ function padNumber(num, digits, trim) { } -function dateGetter(name, size, offset, trim) { +function dateGetter(name, size, offset, trim, negWrap) { offset = offset || 0; return function(date) { var value = date['get' + name](); @@ -19753,14 +19851,15 @@ function dateGetter(name, size, offset, trim) { value += offset; } if (value === 0 && offset == -12) value = 12; - return padNumber(value, size, trim); + return padNumber(value, size, trim, negWrap); }; } -function dateStrGetter(name, shortForm) { +function dateStrGetter(name, shortForm, standAlone) { return function(date, formats) { var value = date['get' + name](); - var get = uppercase(shortForm ? ('SHORT' + name) : name); + var propPrefix = (standAlone ? 'STANDALONE' : '') + (shortForm ? 'SHORT' : ''); + var get = uppercase(propPrefix + name); return formats[get][value]; }; @@ -19815,13 +19914,14 @@ function longEraGetter(date, formats) { } var DATE_FORMATS = { - yyyy: dateGetter('FullYear', 4), - yy: dateGetter('FullYear', 2, 0, true), - y: dateGetter('FullYear', 1), + yyyy: dateGetter('FullYear', 4, 0, false, true), + yy: dateGetter('FullYear', 2, 0, true, true), + y: dateGetter('FullYear', 1, 0, false, true), MMMM: dateStrGetter('Month'), MMM: dateStrGetter('Month', true), MM: dateGetter('Month', 2, 1), M: dateGetter('Month', 1, 1), + LLLL: dateStrGetter('Month', false, true), dd: dateGetter('Date', 2), d: dateGetter('Date', 1), HH: dateGetter('Hours', 2), @@ -19847,7 +19947,7 @@ var DATE_FORMATS = { GGGG: longEraGetter }; -var DATE_FORMATS_SPLIT = /((?:[^yMdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|d+|H+|h+|m+|s+|a|Z|G+|w+))(.*)/, +var DATE_FORMATS_SPLIT = /((?:[^yMLdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|L+|d+|H+|h+|m+|s+|a|Z|G+|w+))(.*)/, NUMBER_STRING = /^\-?\d+$/; /** @@ -19867,6 +19967,7 @@ var DATE_FORMATS_SPLIT = /((?:[^yMdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+| * * `'MMM'`: Month in year (Jan-Dec) * * `'MM'`: Month in year, padded (01-12) * * `'M'`: Month in year (1-12) + * * `'LLLL'`: Stand-alone month in year (January-December) * * `'dd'`: Day in month, padded (01-31) * * `'d'`: Day in month (1-31) * * `'EEEE'`: Day in Week,(Sunday-Saturday) @@ -21548,8 +21649,8 @@ var ngFormDirective = formDirectiveFactory(true); ngModelMinErr: false, */ -// Regex code is obtained from SO: https://stackoverflow.com/questions/3143070/javascript-regex-iso-datetime#answer-3143231 -var ISO_DATE_REGEXP = /\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z)/; +// Regex code was initially obtained from SO prior to modification: https://stackoverflow.com/questions/3143070/javascript-regex-iso-datetime#answer-3143231 +var ISO_DATE_REGEXP = /^\d{4,}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+(?:[+-][0-2]\d:[0-5]\d|Z)$/; // See valid URLs in RFC3987 (http://tools.ietf.org/html/rfc3987) // Note: We are being more lenient, because browsers are too. // 1. Scheme @@ -21565,12 +21666,18 @@ var ISO_DATE_REGEXP = /\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0- var URL_REGEXP = /^[a-z][a-z\d.+-]*:\/*(?:[^:@]+(?::[^@]+)?@)?(?:[^\s:/?#]+|\[[a-f\d:]+\])(?::\d+)?(?:\/[^?#]*)?(?:\?[^#]*)?(?:#.*)?$/i; var EMAIL_REGEXP = /^[a-z0-9!#$%&'*+\/=?^_`{|}~.-]+@[a-z0-9]([a-z0-9-]*[a-z0-9])?(\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$/i; var NUMBER_REGEXP = /^\s*(\-|\+)?(\d+|(\d*(\.\d*)))([eE][+-]?\d+)?\s*$/; -var DATE_REGEXP = /^(\d{4})-(\d{2})-(\d{2})$/; -var DATETIMELOCAL_REGEXP = /^(\d{4})-(\d\d)-(\d\d)T(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/; -var WEEK_REGEXP = /^(\d{4})-W(\d\d)$/; -var MONTH_REGEXP = /^(\d{4})-(\d\d)$/; +var DATE_REGEXP = /^(\d{4,})-(\d{2})-(\d{2})$/; +var DATETIMELOCAL_REGEXP = /^(\d{4,})-(\d\d)-(\d\d)T(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/; +var WEEK_REGEXP = /^(\d{4,})-W(\d\d)$/; +var MONTH_REGEXP = /^(\d{4,})-(\d\d)$/; var TIME_REGEXP = /^(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/; +var PARTIAL_VALIDATION_EVENTS = 'keydown wheel mousedown'; +var PARTIAL_VALIDATION_TYPES = createMap(); +forEach('date,datetime-local,month,time,week'.split(','), function(type) { + PARTIAL_VALIDATION_TYPES[type] = true; +}); + var inputType = { /** @@ -22647,7 +22754,7 @@ function baseInputType(scope, element, attr, ctrl, $sniffer, $browser) { if (!$sniffer.android) { var composing = false; - element.on('compositionstart', function(data) { + element.on('compositionstart', function() { composing = true; }); @@ -22657,6 +22764,8 @@ function baseInputType(scope, element, attr, ctrl, $sniffer, $browser) { }); } + var timeout; + var listener = function(ev) { if (timeout) { $browser.defer.cancel(timeout); @@ -22686,8 +22795,6 @@ function baseInputType(scope, element, attr, ctrl, $sniffer, $browser) { if ($sniffer.hasEvent('input')) { element.on('input', listener); } else { - var timeout; - var deferListener = function(ev, input, origValue) { if (!timeout) { timeout = $browser.defer(function() { @@ -22719,6 +22826,26 @@ function baseInputType(scope, element, attr, ctrl, $sniffer, $browser) { // or form autocomplete on newer browser, we need "change" event to catch it element.on('change', listener); + // Some native input types (date-family) have the ability to change validity without + // firing any input/change events. + // For these event types, when native validators are present and the browser supports the type, + // check for validity changes on various DOM events. + if (PARTIAL_VALIDATION_TYPES[type] && ctrl.$$hasNativeValidators && type === attr.type) { + element.on(PARTIAL_VALIDATION_EVENTS, function(ev) { + if (!timeout) { + var validity = this[VALIDITY_STATE_PROPERTY]; + var origBadInput = validity.badInput; + var origTypeMismatch = validity.typeMismatch; + timeout = $browser.defer(function() { + timeout = null; + if (validity.badInput !== origBadInput || validity.typeMismatch !== origTypeMismatch) { + listener(ev); + } + }); + } + }); + } + ctrl.$render = function() { // Workaround for Firefox validation #12102. var value = ctrl.$isEmpty(ctrl.$viewValue) ? '' : ctrl.$viewValue; @@ -23739,9 +23866,10 @@ function classDirective(name, selector) { * new classes added. * * @animations - * **add** - happens just before the class is applied to the elements - * - * **remove** - happens just before the class is removed from the element + * | Animation | Occurs | + * |----------------------------------|-------------------------------------| + * | {@link ng.$animate#addClass addClass} | just before the class is applied to the element | + * | {@link ng.$animate#removeClass removeClass} | just before the class is removed from the element | * * @element ANY * @param {expression} ngClass {@link guide/expression Expression} to eval. The result @@ -25000,8 +25128,10 @@ forEach( * and `leave` effects. * * @animations - * enter - happens just after the `ngIf` contents change and a new DOM element is created and injected into the `ngIf` container - * leave - happens just before the `ngIf` contents are removed from the DOM + * | Animation | Occurs | + * |----------------------------------|-------------------------------------| + * | {@link ng.$animate#enter enter} | just after the `ngIf` contents change and a new DOM element is created and injected into the `ngIf` container | + * | {@link ng.$animate#leave leave} | just before the `ngIf` contents are removed from the DOM | * * @element ANY * @scope @@ -25042,7 +25172,7 @@ forEach(
*/ -var ngIfDirective = ['$animate', function($animate) { +var ngIfDirective = ['$animate', '$compile', function($animate, $compile) { return { multiElement: true, transclude: 'element', @@ -25058,7 +25188,7 @@ var ngIfDirective = ['$animate', function($animate) { if (!childScope) { $transclude(function(clone, newScope) { childScope = newScope; - clone[clone.length++] = document.createComment(' end ngIf: ' + $attr.ngIf + ' '); + clone[clone.length++] = $compile.$$createComment('end ngIf', $attr.ngIf); // Note: We only need the first/last node of the cloned nodes. // However, we need to keep the reference to the jqlite wrapper as it might be changed later // by a directive with templateUrl when its template arrives. @@ -25113,8 +25243,10 @@ var ngIfDirective = ['$animate', function($animate) { * access on some browsers. * * @animations - * enter - animation is used to bring new content into the browser. - * leave - animation is used to animate existing content away. + * | Animation | Occurs | + * |----------------------------------|-------------------------------------| + * | {@link ng.$animate#enter enter} | when the expression changes, on the new include | + * | {@link ng.$animate#leave leave} | when the expression changes, on the old include | * * The enter and leave animation occur concurrently. * @@ -25855,9 +25987,9 @@ var NgModelController = ['$scope', '$exceptionHandler', '$attrs', '$element', '$ }; ngModelSet = function($scope, newValue) { if (isFunction(parsedNgModel($scope))) { - invokeModelSetter($scope, {$$$p: ctrl.$modelValue}); + invokeModelSetter($scope, {$$$p: newValue}); } else { - parsedNgModelAssign($scope, ctrl.$modelValue); + parsedNgModelAssign($scope, newValue); } }; } else if (!parsedNgModel.assign) { @@ -25882,7 +26014,7 @@ var NgModelController = ['$scope', '$exceptionHandler', '$attrs', '$element', '$ * the `$viewValue` are different from last time. * * Since `ng-model` does not do a deep watch, `$render()` is only invoked if the values of - * `$modelValue` and `$viewValue` are actually different from their previous value. If `$modelValue` + * `$modelValue` and `$viewValue` are actually different from their previous values. If `$modelValue` * or `$viewValue` are objects (rather than a string or number) then `$render()` will not be * invoked if you only change a property on the objects. */ @@ -26234,7 +26366,7 @@ var NgModelController = ['$scope', '$exceptionHandler', '$attrs', '$element', '$ setValidity(name, undefined); validatorPromises.push(promise.then(function() { setValidity(name, true); - }, function(error) { + }, function() { allValid = false; setValidity(name, false); })); @@ -26708,7 +26840,7 @@ var ngModelDirective = ['$rootScope', function($rootScope) { }); } - element.on('blur', function(ev) { + element.on('blur', function() { if (modelCtrl.$touched) return; if ($rootScope.$$phase) { @@ -27391,8 +27523,8 @@ var ngOptionsDirective = ['$compile', '$parse', function($compile, $parse) { var key = (optionValues === optionValuesKeys) ? index : optionValuesKeys[index]; var value = optionValues[key]; - var locals = getLocals(optionValues[key], key); - var selectValue = getTrackByValueFn(optionValues[key], locals); + var locals = getLocals(value, key); + var selectValue = getTrackByValueFn(value, locals); watchedArray.push(selectValue); // Only need to watch the displayFn if there is a specific label expression @@ -27517,14 +27649,20 @@ var ngOptionsDirective = ['$compile', '$parse', function($compile, $parse) { var option = options.getOptionFromViewValue(value); if (option && !option.disabled) { + // Don't update the option when it is already selected. + // For example, the browser will select the first option by default. In that case, + // most properties are set automatically - except the `selected` attribute, which we + // set always + if (selectElement[0].value !== option.selectValue) { removeUnknownOption(); removeEmptyOption(); selectElement[0].value = option.selectValue; option.element.selected = true; - option.element.setAttribute('selected', 'selected'); } + + option.element.setAttribute('selected', 'selected'); } else { if (value === null || providedEmptyOption) { removeUnknownOption(); @@ -28083,17 +28221,23 @@ var ngPluralizeDirective = ['$locale', '$interpolate', '$log', function($locale, *
...
* ``` * - * You need to be aware that the JavaScript specification does not define the order of keys - * returned for an object. (To mitigate this in Angular 1.3 the `ngRepeat` directive - * used to sort the keys alphabetically.) + * However, there are a limitations compared to array iteration: + * + * - The JavaScript specification does not define the order of keys + * returned for an object, so Angular relies on the order returned by the browser + * when running `for key in myObj`. Browsers generally follow the strategy of providing + * keys in the order in which they were defined, although there are exceptions when keys are deleted + * and reinstated. See the + * [MDN page on `delete` for more info](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/delete#Cross-browser_notes). + * + * - `ngRepeat` will silently *ignore* object keys starting with `$`, because + * it's a prefix used by Angular for public (`$`) and private (`$$`) properties. * - * Version 1.4 removed the alphabetic sorting. We now rely on the order returned by the browser - * when running `for key in myObj`. It seems that browsers generally follow the strategy of providing - * keys in the order in which they were defined, although there are exceptions when keys are deleted - * and reinstated. See the [MDN page on `delete` for more info](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/delete#Cross-browser_notes). + * - The built-in filters {@link ng.orderBy orderBy} and {@link ng.filter filter} do not work with + * objects, and will throw if used with one. * - * If this is not desired, the recommended workaround is to convert your object into an array - * that is sorted into the order that you prefer before providing it to `ngRepeat`. You could + * If you are hitting any of these limitations, the recommended workaround is to convert your object into an array + * that is sorted into the order that you prefer before providing it to `ngRepeat`. You could * do this with a filter such as [toArrayFilter](http://ngmodules.org/modules/angular-toArrayFilter) * or implement a `$watch` on the object yourself. * @@ -28211,11 +28355,11 @@ var ngPluralizeDirective = ['$locale', '$interpolate', '$log', function($locale, * as **data-ng-repeat-start**, **x-ng-repeat-start** and **ng:repeat-start**). * * @animations - * **.enter** - when a new item is added to the list or when an item is revealed after a filter - * - * **.leave** - when an item is removed from the list or when an item is filtered out - * - * **.move** - when an adjacent item is filtered out causing a reorder or when the item contents are reordered + * | Animation | Occurs | + * |----------------------------------|-------------------------------------| + * | {@link ng.$animate#enter enter} | when a new item is added to the list or when an item is revealed after a filter | + * | {@link ng.$animate#leave leave} | when an item is removed from the list or when an item is filtered out | + * | {@link ng.$animate#move move } | when an adjacent item is filtered out causing a reorder or when the item contents are reordered | * * See the example below for defining CSS animations with ngRepeat. * @@ -28363,7 +28507,7 @@ var ngPluralizeDirective = ['$locale', '$interpolate', '$log', function($locale, */ -var ngRepeatDirective = ['$parse', '$animate', function($parse, $animate) { +var ngRepeatDirective = ['$parse', '$animate', '$compile', function($parse, $animate, $compile) { var NG_REMOVED = '$$NG_REMOVED'; var ngRepeatMinErr = minErr('ngRepeat'); @@ -28398,7 +28542,7 @@ var ngRepeatDirective = ['$parse', '$animate', function($parse, $animate) { $$tlb: true, compile: function ngRepeatCompile($element, $attr) { var expression = $attr.ngRepeat; - var ngRepeatEndComment = document.createComment(' end ngRepeat: ' + expression + ' '); + var ngRepeatEndComment = $compile.$$createComment('end ngRepeat', expression); var match = expression.match(/^\s*([\s\S]+?)\s+in\s+([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+track\s+by\s+([\s\S]+?))?\s*$/); @@ -28562,7 +28706,7 @@ var ngRepeatDirective = ['$parse', '$animate', function($parse, $animate) { if (getBlockStart(block) != nextNode) { // existing item which got moved - $animate.move(getBlockNodes(block.clone), null, jqLite(previousNode)); + $animate.move(getBlockNodes(block.clone), null, previousNode); } previousNode = getBlockEnd(block); updateScope(block.scope, index, valueIdentifier, value, keyIdentifier, key, collectionLength); @@ -28574,8 +28718,7 @@ var ngRepeatDirective = ['$parse', '$animate', function($parse, $animate) { var endNode = ngRepeatEndComment.cloneNode(false); clone[clone.length++] = endNode; - // TODO(perf): support naked previousNode in `enter` to avoid creation of jqLite wrapper? - $animate.enter(clone, null, jqLite(previousNode)); + $animate.enter(clone, null, previousNode); previousNode = endNode; // Note: We only need the first/last node of the cloned nodes. // However, we need to keep the reference to the jqlite wrapper as it might be changed later @@ -28678,12 +28821,14 @@ var NG_HIDE_IN_PROGRESS_CLASS = 'ng-hide-animate'; * .my-element.ng-hide-remove.ng-hide-remove-active { ... } * ``` * - * Keep in mind that, as of AngularJS version 1.3.0-beta.11, there is no need to change the display + * Keep in mind that, as of AngularJS version 1.3, there is no need to change the display * property to block during animation states--ngAnimate will handle the style toggling automatically for you. * * @animations - * addClass: `.ng-hide` - happens after the `ngShow` expression evaluates to a truthy value and the just before contents are set to visible - * removeClass: `.ng-hide` - happens after the `ngShow` expression evaluates to a non truthy value and just before the contents are set to hidden + * | Animation | Occurs | + * |----------------------------------|-------------------------------------| + * | {@link $animate#addClass addClass} `.ng-hide` | after the `ngShow` expression evaluates to a non truthy value and just before the contents are set to hidden | + * | {@link $animate#removeClass removeClass} `.ng-hide` | after the `ngShow` expression evaluates to a truthy value and just before contents are set to visible | * * @element ANY * @param {expression} ngShow If the {@link guide/expression expression} is truthy @@ -28842,12 +28987,15 @@ var ngShowDirective = ['$animate', function($animate) { * .my-element.ng-hide-remove.ng-hide-remove-active { ... } * ``` * - * Keep in mind that, as of AngularJS version 1.3.0-beta.11, there is no need to change the display + * Keep in mind that, as of AngularJS version 1.3, there is no need to change the display * property to block during animation states--ngAnimate will handle the style toggling automatically for you. * * @animations - * removeClass: `.ng-hide` - happens after the `ngHide` expression evaluates to a truthy value and just before the contents are set to hidden - * addClass: `.ng-hide` - happens after the `ngHide` expression evaluates to a non truthy value and just before the contents are set to visible + * | Animation | Occurs | + * |----------------------------------|-------------------------------------| + * | {@link $animate#addClass addClass} `.ng-hide` | after the `ngHide` expression evaluates to a truthy value and just before the contents are set to hidden | + * | {@link $animate#removeClass removeClass} `.ng-hide` | after the `ngHide` expression evaluates to a non truthy value and just before contents are set to visible | + * * * @element ANY * @param {expression} ngHide If the {@link guide/expression expression} is truthy then @@ -29009,8 +29157,10 @@ var ngStyleDirective = ngDirective(function(scope, element, attr) { * * @animations - * enter - happens after the ngSwitch contents change and the matched child element is placed inside the container - * leave - happens just after the ngSwitch contents change and just before the former contents are removed from the DOM + * | Animation | Occurs | + * |----------------------------------|-------------------------------------| + * | {@link ng.$animate#enter enter} | after the ngSwitch contents change and the matched child element is placed inside the container | + * | {@link ng.$animate#leave leave} | after the ngSwitch contents change and just before the former contents are removed from the DOM | * * @usage * @@ -29109,7 +29259,7 @@ var ngStyleDirective = ngDirective(function(scope, element, attr) { */ -var ngSwitchDirective = ['$animate', function($animate) { +var ngSwitchDirective = ['$animate', '$compile', function($animate, $compile) { return { require: 'ngSwitch', @@ -29150,7 +29300,7 @@ var ngSwitchDirective = ['$animate', function($animate) { selectedTransclude.transclude(function(caseElement, selectedScope) { selectedScopes.push(selectedScope); var anchor = selectedTransclude.element; - caseElement[caseElement.length++] = document.createComment(' end ngSwitchWhen: '); + caseElement[caseElement.length++] = $compile.$$createComment('end ngSwitchWhen'); var block = { clone: caseElement }; selectedElements.push(block); @@ -29444,7 +29594,7 @@ function chromeHack(optionElement) { * added `