mirror of
https://github.com/silverstripe/silverstripe-cms
synced 2024-10-22 08:05:56 +02:00
Make minor buttons smaller, change conflicting class (used elsewhere)
This commit is contained in:
parent
c0623a4962
commit
df9b73725a
@ -19,7 +19,7 @@ $.entwine('ss', function($) {
|
||||
// This ensures we don't get bogus previews on readonly fields.
|
||||
if(this.find(':text').length) this.toggleEdit(false);
|
||||
this.redraw();
|
||||
|
||||
|
||||
this._super();
|
||||
},
|
||||
|
||||
@ -34,7 +34,7 @@ $.entwine('ss', function($) {
|
||||
}
|
||||
|
||||
// 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();
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Commits the change of the URLSegment to the field
|
||||
* Optional: pass in (String) to update the URLSegment
|
||||
@ -62,7 +62,7 @@ $.entwine('ss', function($) {
|
||||
currentVal = field.data('origval'),
|
||||
title = arguments[0],
|
||||
updateVal = (title && title !== "") ? title : field.val();
|
||||
|
||||
|
||||
if (currentVal != updateVal) {
|
||||
this.addClass('loading');
|
||||
this.suggest(updateVal, function(data) {
|
||||
@ -76,7 +76,7 @@ $.entwine('ss', function($) {
|
||||
this.redraw();
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Cancels any changes to the field
|
||||
*/
|
||||
|
@ -99,7 +99,7 @@
|
||||
background: url(../../images/loading.gif) no-repeat 162px 8px;
|
||||
}
|
||||
|
||||
.preview {
|
||||
.URL-link {
|
||||
padding-top: 8px;
|
||||
display: inline-block;
|
||||
}
|
||||
|
@ -1,19 +1,19 @@
|
||||
<div class="preview-holder">
|
||||
<a class="preview" href="$URL" target="_blank">
|
||||
<a class="URL-link" href="$URL" target="_blank">
|
||||
$URL
|
||||
</a>
|
||||
<% 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') %>
|
||||
</button>
|
||||
<% end_if %>
|
||||
</div>
|
||||
<div class="edit-holder">
|
||||
<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') %>
|
||||
</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') %>
|
||||
</button>
|
||||
<% if $HelpText %><p class="form__field-description">$HelpText</p><% end_if %>
|
||||
|
Loading…
Reference in New Issue
Block a user