Make minor buttons smaller, change conflicting class (used elsewhere)

This commit is contained in:
Paul Clarke 2016-10-21 11:58:18 +13:00
parent c0623a4962
commit df9b73725a
3 changed files with 10 additions and 10 deletions

View File

@ -19,7 +19,7 @@ $.entwine('ss', function($) {
// This ensures we don't get bogus previews on readonly fields. // This ensures we don't get bogus previews on readonly fields.
if(this.find(':text').length) this.toggleEdit(false); if(this.find(':text').length) this.toggleEdit(false);
this.redraw(); this.redraw();
this._super(); this._super();
}, },
@ -34,7 +34,7 @@ $.entwine('ss', function($) {
} }
// Transfer current value to holder // Transfer current value to holder
this.find('.preview').attr('href', encodeURI(url + field.data('suffix'))).text(previewUrl); this.find('.URL-link').attr('href', encodeURI(url + field.data('suffix'))).text(previewUrl);
}, },
/** /**
@ -51,7 +51,7 @@ $.entwine('ss', function($) {
field.focus(); field.focus();
} }
}, },
/** /**
* Commits the change of the URLSegment to the field * Commits the change of the URLSegment to the field
* Optional: pass in (String) to update the URLSegment * Optional: pass in (String) to update the URLSegment
@ -62,7 +62,7 @@ $.entwine('ss', function($) {
currentVal = field.data('origval'), currentVal = field.data('origval'),
title = arguments[0], title = arguments[0],
updateVal = (title && title !== "") ? title : field.val(); updateVal = (title && title !== "") ? title : field.val();
if (currentVal != updateVal) { if (currentVal != updateVal) {
this.addClass('loading'); this.addClass('loading');
this.suggest(updateVal, function(data) { this.suggest(updateVal, function(data) {
@ -76,7 +76,7 @@ $.entwine('ss', function($) {
this.redraw(); this.redraw();
} }
}, },
/** /**
* Cancels any changes to the field * Cancels any changes to the field
*/ */

View File

@ -99,7 +99,7 @@
background: url(../../images/loading.gif) no-repeat 162px 8px; background: url(../../images/loading.gif) no-repeat 162px 8px;
} }
.preview { .URL-link {
padding-top: 8px; padding-top: 8px;
display: inline-block; display: inline-block;
} }

View File

@ -1,19 +1,19 @@
<div class="preview-holder"> <div class="preview-holder">
<a class="preview" href="$URL" target="_blank"> <a class="URL-link" href="$URL" target="_blank">
$URL $URL
</a> </a>
<% if not $IsReadonly %> <% if not $IsReadonly %>
<button role="button" type="button" class="btn ui-button-text-only ss-ui-button edit"> <button role="button" type="button" class="btn btn-sm ui-button-text-only ss-ui-button edit">
<% _t('URLSegmentField.Edit', 'Edit') %> <% _t('URLSegmentField.Edit', 'Edit') %>
</button> </button>
<% end_if %> <% end_if %>
</div> </div>
<div class="edit-holder"> <div class="edit-holder">
<input $AttributesHTML /> <input $AttributesHTML />
<button role="button" data-icon="accept" type="button" class="btn ui-button-text-icon-primary ss-ui-button update"> <button role="button" data-icon="accept" type="button" class="btn btn-sm ui-button-text-icon-primary ss-ui-button update">
<% _t('URLSegmentField.OK', 'OK') %> <% _t('URLSegmentField.OK', 'OK') %>
</button> </button>
<button role="button" data-icon="cancel" type="button" class="btn ui-button-text-icon-secondary ss-ui-button cancel"> <button role="button" data-icon="cancel" type="button" class="btn btn-sm ui-button-text-icon-secondary ss-ui-button cancel">
<% _t('URLSegmentField.Cancel', 'Cancel') %> <% _t('URLSegmentField.Cancel', 'Cancel') %>
</button> </button>
<% if $HelpText %><p class="form__field-description">$HelpText</p><% end_if %> <% if $HelpText %><p class="form__field-description">$HelpText</p><% end_if %>