Permalink
Browse files

BUG Visual cue that URLSegment is updating

Added a loading class on .field.urlsegment to indicate that the URLSegment is updating its value, set before and after self.suggest().
  • Loading branch information...
ryanwachtl committed Aug 17, 2012
1 parent 2923e55 commit 5f9362e7424ce71cde850d5ba87b03cb0c795458
Showing with 6 additions and 8 deletions.
  1. +2 −2 css/screen.css
  2. BIN images/loading.gif
  3. +2 −0 javascript/SiteTreeURLSegmentField.js
  4. +2 −6 scss/_CMSMain.scss
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View
Binary file not shown.
@@ -94,10 +94,12 @@
}
if (currentVal != updateVal) {
+ self.addClass('loading');
self.suggest(updateVal, function(data) {
var newVal = decodeURIComponent(data.value);
field.val(newVal);
self.edit(title);
+ self.removeClass('loading');
});
} else {
self.edit();
View
@@ -93,12 +93,8 @@
* ----------------------------------------------------------------- */
.field.urlsegment {
- &.disabled {
- color: #444;
- padding-left: 0px;
- margin-left: 0px;
- background: none;
- border-color: transparent;
+ &.loading {
+ background: url(../images/loading.gif) no-repeat 162px 8px;
}
.prefix,

0 comments on commit 5f9362e

Please sign in to comment.