CRM-15856 - crmMailing - Submit button
authorTim Otten <totten@civicrm.org>
Mon, 2 Feb 2015 05:24:47 +0000 (21:24 -0800)
committerTim Otten <totten@civicrm.org>
Mon, 2 Feb 2015 05:27:19 +0000 (21:27 -0800)
Distinguish between blockage based on invalid data from blockage based on
pending AJAX.

css/angular-crmMailing.css
partials/crmMailing/edit-wizard.html
partials/crmMailing/edit.html
partials/crmMailingAB/edit.html

index d507b98009a0541c6c10a815f88874f541cd2382..1d86ccfcc722dc9b78541e1711686063fa54692f 100644 (file)
@@ -83,6 +83,7 @@ a.crmMailing-submit-button div {
 a.crmMailing-submit-button div:hover {
   background: #afa;
   border: 1px solid #7a7;
+  cursor: pointer;
 }
 a.crmMailing-submit-button:hover {
   text-decoration: none;
@@ -91,13 +92,25 @@ a.crmMailing-submit-button.disabled div {
   color: black;
   background: #aaa;
   border: 1px solid #8a8;
-  padding: 1em;
-  margin: 1em;
-  width: 15em;
 }
-a.crmMailing-submit-button.disabled div:hover {
+a.crmMailing-submit-button.blocking div {
+  -webkit-animation: crmMailingPulse 2s infinite !important; /* Chrome, Safari, Opera */
+  animation: crmMailingPulse 2s infinite !important;
+}
+@-webkit-keyframes crmMailingPulse {
+  0% {background: #bfb;}
+  50% {background: #aaa;}
+  100% {background: #bfb;}
+}
+@keyframes crmMailingPulse {
+  0% {background: #bfb;}
+  50% {background: #aaa;}
+  100% {background: #bfb;}
+}
+a.crmMailing-submit-button.disabled div:hover, a.crmMailing-submit-button.blocking div:hover {
   background: #aaa;
   border: 1px solid #7a7;
+  cursor: not-allowed;
 }
 
 .crm-container .crm-form-block label {
index b7cce60e9676ba0cea05dec6e29a6f3aa9915851..df8f8ad0a23c77f7513a76971cee62c243ff09bd 100644 (file)
@@ -53,7 +53,7 @@
           <div crm-mailing-block-review crm-mailing="mailing"/>
         </div>
         <center>
-          <a class="crmMailing-submit-button" ng-click="submit()" ng-class="{disabled: block.check() || crmMailing.$invalid}">
+          <a class="crmMailing-submit-button" ng-click="submit()" ng-class="{blocking: block.check(), disabled: crmMailing.$invalid}>
             <div>{{ts('Submit Mailing')}}</div>
           </a>
         </center>
index 84869726c89c31c257ba3acc31f7614b174eee3a..560bcdb3ef1fb81e4974bc3512b1a2e00ae55f5a 100644 (file)
@@ -51,7 +51,7 @@
           <div crm-mailing-block-schedule crm-mailing="mailing"/>
         </div>
         <center>
-          <a class="crmMailing-submit-button" ng-click="submit()" ng-class="{disabled: block.check() || crmMailing.$invalid}">
+          <a class="crmMailing-submit-button" ng-click="submit()" ng-class="{blocking: block.check(), disabled: crmMailing.$invalid}">
             <div>{{ts('Submit Mailing')}}</div>
           </a>
         </center>
index 177bbdf63d69738fafc4b4b464701e4629b51836..7776dea48fa01cca429b905e5b2fb77a5db450e2 100644 (file)
           }"
           crm-abtest="abtest"></div>
         <center>
-          <a class="crmMailing-submit-button" ng-click="submit()">
+          <a class="crmMailing-submit-button" ng-click="submit()" ng-class="{disabled: crmMailing.$invalid}">
             <div>{{ts('Submit Mailing')}}</div>
           </a>
         </center>