소스 검색

Replace deprecated $.tipsy(...) by $.tooltip(...)

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
tags/v12.0.0beta1
Christoph Wurst 7 년 전
부모
커밋
3e7e49884e
4개의 변경된 파일11개의 추가작업 그리고 11개의 파일을 삭제
  1. 1
    1
      apps/files/js/breadcrumb.js
  2. 2
    2
      apps/files/js/file-upload.js
  3. 1
    1
      core/js/share.js
  4. 7
    7
      core/js/tests/specs/shareSpec.js

+ 1
- 1
apps/files/js/breadcrumb.js 파일 보기

@@ -272,7 +272,7 @@
// set the path of this one as title for the ellipsis
this.$el.find('.crumb.ellipsized')
.attr('title', $crumb.attr('data-dir'))
.tipsy();
.tooltip();
this.$el.find('.ellipsis')
.wrap('<a class="ellipsislink" href="' + encodeURI(OC.generateUrl('apps/files/?dir=' + $crumb.attr('data-dir'))) + '"></a>');
}

+ 2
- 2
apps/files/js/file-upload.js 파일 보기

@@ -895,7 +895,7 @@ OC.Uploader.prototype = _.extend({
start: function(e) {
self.log('start', e, null);
//hide the tooltip otherwise it covers the progress bar
$('#upload').tipsy('hide');
$('#upload').tooltip('hide');
},
fail: function(e, data) {
var upload = self.getUpload(data);
@@ -991,7 +991,7 @@ OC.Uploader.prototype = _.extend({
+ '</span><span class="mobile">'
+ t('files', '...')
+ '</span></em>');
$('#uploadprogressbar').tipsy({gravity:'n', fade:true, live:true});
$('#uploadprogressbar').toopltip({placement: 'bottom'});
self._showProgressBar();
self.trigger('start', e, data);
});

+ 1
- 1
core/js/share.js 파일 보기

@@ -302,7 +302,7 @@ OC.Share = _.extend(OC.Share || {}, {
}
action.html('<span> ' + message + '</span>').prepend(icon);
if (owner || recipients) {
action.find('.remoteAddress').tipsy({gravity: 's'});
action.find('.remoteAddress').tooltip({placement: 'top'});
}
}
else {

+ 7
- 7
core/js/tests/specs/shareSpec.js 파일 보기

@@ -23,10 +23,10 @@
describe('OC.Share tests', function() {
describe('markFileAsShared', function() {
var $file;
var tipsyStub;
var tooltipStub;

beforeEach(function() {
tipsyStub = sinon.stub($.fn, 'tipsy');
tooltipStub = sinon.stub($.fn, 'tooltip');
$file = $('<tr><td class="filename"><div class="thumbnail"></div><span class="name">File name</span></td></tr>');
$file.find('.filename').append(
'<span class="fileactions">' +
@@ -38,7 +38,7 @@ describe('OC.Share tests', function() {
});
afterEach(function() {
$file = null;
tipsyStub.restore();
tooltipStub.restore();
});
describe('displaying the share owner', function() {
function checkOwner(input, output, title) {
@@ -54,8 +54,8 @@ describe('OC.Share tests', function() {
} else {
expect($action.find('.remoteAddress').attr('title')).not.toBeDefined();
}
expect(tipsyStub.calledOnce).toEqual(true);
tipsyStub.reset();
expect(tooltipStub.calledOnce).toEqual(true);
tooltipStub.reset();
}

it('displays the local share owner as is', function() {
@@ -172,8 +172,8 @@ describe('OC.Share tests', function() {
} else {
expect($action.find('.remoteAddress').attr('title')).not.toBeDefined();
}
expect(tipsyStub.calledOnce).toEqual(true);
tipsyStub.reset();
expect(tooltipStub.calledOnce).toEqual(true);
tooltipStub.reset();
}

it('displays the local share owner as is', function() {

Loading…
취소
저장