Diff
checker
文本
文本
图像
文档
Excel
文件夹
Legal
Enterprise
桌面版
定价
登录
下载 Diffchecker 桌面版
比较文本
查找两个文本文件之间的差异
工具
历史
实时编辑器
折叠未更改行
关闭换行
视图
拆分
统一
比对精度
智能
单词
字符
语法高亮
选择语法
忽略
文本转换
转到第一个差异
编辑输入
Diffchecker Desktop
运行Diffchecker最安全的方式。获取Diffchecker桌面应用:您的差异永远不会离开您的电脑!
获取桌面版
Untitled diff
创建于
11年前
差异永不过期
清除
导出
分享
解释
11 删除
行
总计
删除
字符
总计
删除
要继续使用此功能,请升级到
Diff
checker
Pro
查看价格
103 行
全部复制
8 添加
行
总计
添加
字符
总计
添加
要继续使用此功能,请升级到
Diff
checker
Pro
查看价格
103 行
全部复制
$(function() {
$(function() {
$(window).resize(function() {
$(window).resize(function() {
var width = $(window).width();
var width = $(window).width();
});
});
var b1 = document.querySelector('.backgroundOne');
var b1 = document.querySelector('.backgroundOne');
var b2 = document.querySelector('.backgroundTwo');
var b2 = document.querySelector('.backgroundTwo');
var b3 = document.querySelector('.backgroundThree');
var b3 = document.querySelector('.backgroundThree');
function setTranslate3d(element, y, x) {
function setTranslate3d(element, y, x) {
element.style['webkitTransform'] = 'translate3d(' + y + 'px,' + x + 'px, 0)';
element.style['webkitTransform'] = 'translate3d(' + y + 'px,' + x + 'px, 0)';
element.style['mozTransform'] = 'translate3d(' + y + 'px,' + x + 'px, 0)';
element.style['mozTransform'] = 'translate3d(' + y + 'px,' + x + 'px, 0)';
}
}
function handleOrientation(event) {
function handleOrientation(event) {
var x = Math.max(Math.min(event.beta, 90), -90);
var x = Math.max(Math.min(event.beta, 90), -90);
var y = event.gamma;
var y = event.gamma;
setTranslate3d(b1, y / 3, x / 3);
setTranslate3d(b1, y / 3, x / 3);
setTranslate3d(b2, y / 15, x / 15);
setTranslate3d(b2, y / 15, x / 15);
setTranslate3d(b3, y / 30, x / 30);
setTranslate3d(b3, y / 30, x / 30);
}
}
window.addEventListener('deviceorientation', handleOrientation);
window.addEventListener('deviceorientation', handleOrientation);
setInterval(function() {
setInterval(function() {
magicEightBall();
magicEightBall();
复制
已复制
复制
已复制
},
3
500);
},
5
500);
var inputArgs = [
var inputArgs = [
复制
已复制
复制
已复制
['
sashimi
', 'emoj
i1
'],
['
#trivia
', 'emoj
'],
['
bikeguy
', 'emoj
i2
'],
['
#bigbang
', 'emoj
'],
['
libby
', 'emoj
i3
']
['
#history
', 'emoj
']
];
];
var currentIdx = 0;
var currentIdx = 0;
function typeCurrent() {
function typeCurrent() {
performTyping(inputArgs[currentIdx][0], inputArgs[currentIdx][1], function() {
performTyping(inputArgs[currentIdx][0], inputArgs[currentIdx][1], function() {
currentIdx++;
currentIdx++;
if (currentIdx >= inputArgs.length) { currentIdx = 0; }
if (currentIdx >= inputArgs.length) { currentIdx = 0; }
复制
已复制
复制
已复制
setTimeout(function() { typeCurrent(); },
3
000);
setTimeout(function() { typeCurrent(); },
5
000);
});
});
}
}
typeCurrent();
typeCurrent();
});
});
function magicEightBall() {
function magicEightBall() {
var screens = $('#screens');
var screens = $('#screens');
var screen = $('#screen');
var screen = $('#screen');
var emoji = $('.animate');
var emoji = $('.animate');
var wash = $('.wash');
var wash = $('.wash');
screens.css({ '-webkit-animation-name' : 'dip', '-moz-animation-name' : 'dip' });
screens.css({ '-webkit-animation-name' : 'dip', '-moz-animation-name' : 'dip' });
setTimeout(function() {
setTimeout(function() {
screens.css({'-webkit-animation-name' : '', '-moz-animation-name' : '' });
screens.css({'-webkit-animation-name' : '', '-moz-animation-name' : '' });
}, 300);
}, 300);
var roomClasses = ['room1', 'room2', 'room3'];
var roomClasses = ['room1', 'room2', 'room3'];
setTimeout(function() {
setTimeout(function() {
for (var idx = 0; idx < roomClasses.length; idx++) {
for (var idx = 0; idx < roomClasses.length; idx++) {
if (screen.hasClass(roomClasses[idx])) {
if (screen.hasClass(roomClasses[idx])) {
break;
break;
}
}
}
}
screen.removeClass();
screen.removeClass();
idx++;
idx++;
idx = idx >= roomClasses.length ? 0 : idx;
idx = idx >= roomClasses.length ? 0 : idx;
setTimeout(function() { screen.addClass(roomClasses[idx]); }, 0);
setTimeout(function() { screen.addClass(roomClasses[idx]); }, 0);
复制
已复制
复制
已复制
},
1
00);
},
4
00);
setTimeout(function() {
setTimeout(function() {
emoji.css({'-webkit-animation-name' : 'like', '-moz-animation-name' : 'like'});
emoji.css({'-webkit-animation-name' : 'like', '-moz-animation-name' : 'like'});
wash.css({'-webkit-animation-name' : 'opacity', '-moz-animation-name' : 'opacity'});
wash.css({'-webkit-animation-name' : 'opacity', '-moz-animation-name' : 'opacity'});
setTimeout(function() {
setTimeout(function() {
emoji.css({'-webkit-animation-name' : '', '-moz-animation-name' : ''});
emoji.css({'-webkit-animation-name' : '', '-moz-animation-name' : ''});
wash.css({'-webkit-animation-name' : '', '-moz-animation-name' : ''});
wash.css({'-webkit-animation-name' : '', '-moz-animation-name' : ''});
复制
已复制
复制
已复制
},
2
000);
},
4
000);
},
800
);
},
2000
);
}
}
function performTyping(nameStr, emoji, callback) {
function performTyping(nameStr, emoji, callback) {
var name = $('#name');
var name = $('#name');
name.html(' ');
name.html(' ');
name.removeClass();
name.removeClass();
var idx = 0;
var idx = 0;
function typeChar() {
function typeChar() {
setTimeout(function() {
setTimeout(function() {
if (idx < nameStr.length) {
if (idx < nameStr.length) {
name.html(nameStr.substr(0, ++idx));
name.html(nameStr.substr(0, ++idx));
typeChar();
typeChar();
} else {
} else {
name.addClass(emoji);
name.addClass(emoji);
if (callback) { callback(); }
if (callback) { callback(); }
}
}
}, idx === 0 ? 300 : 100);
}, idx === 0 ? 300 : 100);
}
}
typeChar();
typeChar();
};
};
已保存差异
原始文本
打开文件
$(function() { $(window).resize(function() { var width = $(window).width(); }); var b1 = document.querySelector('.backgroundOne'); var b2 = document.querySelector('.backgroundTwo'); var b3 = document.querySelector('.backgroundThree'); function setTranslate3d(element, y, x) { element.style['webkitTransform'] = 'translate3d(' + y + 'px,' + x + 'px, 0)'; element.style['mozTransform'] = 'translate3d(' + y + 'px,' + x + 'px, 0)'; } function handleOrientation(event) { var x = Math.max(Math.min(event.beta, 90), -90); var y = event.gamma; setTranslate3d(b1, y / 3, x / 3); setTranslate3d(b2, y / 15, x / 15); setTranslate3d(b3, y / 30, x / 30); } window.addEventListener('deviceorientation', handleOrientation); setInterval(function() { magicEightBall(); }, 3500); var inputArgs = [ ['sashimi', 'emoji1'], ['bikeguy', 'emoji2'], ['libby', 'emoji3'] ]; var currentIdx = 0; function typeCurrent() { performTyping(inputArgs[currentIdx][0], inputArgs[currentIdx][1], function() { currentIdx++; if (currentIdx >= inputArgs.length) { currentIdx = 0; } setTimeout(function() { typeCurrent(); }, 3000); }); } typeCurrent(); }); function magicEightBall() { var screens = $('#screens'); var screen = $('#screen'); var emoji = $('.animate'); var wash = $('.wash'); screens.css({ '-webkit-animation-name' : 'dip', '-moz-animation-name' : 'dip' }); setTimeout(function() { screens.css({'-webkit-animation-name' : '', '-moz-animation-name' : '' }); }, 300); var roomClasses = ['room1', 'room2', 'room3']; setTimeout(function() { for (var idx = 0; idx < roomClasses.length; idx++) { if (screen.hasClass(roomClasses[idx])) { break; } } screen.removeClass(); idx++; idx = idx >= roomClasses.length ? 0 : idx; setTimeout(function() { screen.addClass(roomClasses[idx]); }, 0); }, 100); setTimeout(function() { emoji.css({'-webkit-animation-name' : 'like', '-moz-animation-name' : 'like'}); wash.css({'-webkit-animation-name' : 'opacity', '-moz-animation-name' : 'opacity'}); setTimeout(function() { emoji.css({'-webkit-animation-name' : '', '-moz-animation-name' : ''}); wash.css({'-webkit-animation-name' : '', '-moz-animation-name' : ''}); }, 2000); }, 800); } function performTyping(nameStr, emoji, callback) { var name = $('#name'); name.html(' '); name.removeClass(); var idx = 0; function typeChar() { setTimeout(function() { if (idx < nameStr.length) { name.html(nameStr.substr(0, ++idx)); typeChar(); } else { name.addClass(emoji); if (callback) { callback(); } } }, idx === 0 ? 300 : 100); } typeChar(); };
更改后文本
打开文件
$(function() { $(window).resize(function() { var width = $(window).width(); }); var b1 = document.querySelector('.backgroundOne'); var b2 = document.querySelector('.backgroundTwo'); var b3 = document.querySelector('.backgroundThree'); function setTranslate3d(element, y, x) { element.style['webkitTransform'] = 'translate3d(' + y + 'px,' + x + 'px, 0)'; element.style['mozTransform'] = 'translate3d(' + y + 'px,' + x + 'px, 0)'; } function handleOrientation(event) { var x = Math.max(Math.min(event.beta, 90), -90); var y = event.gamma; setTranslate3d(b1, y / 3, x / 3); setTranslate3d(b2, y / 15, x / 15); setTranslate3d(b3, y / 30, x / 30); } window.addEventListener('deviceorientation', handleOrientation); setInterval(function() { magicEightBall(); }, 5500); var inputArgs = [ ['#trivia', 'emoj'], ['#bigbang', 'emoj'], ['#history', 'emoj'] ]; var currentIdx = 0; function typeCurrent() { performTyping(inputArgs[currentIdx][0], inputArgs[currentIdx][1], function() { currentIdx++; if (currentIdx >= inputArgs.length) { currentIdx = 0; } setTimeout(function() { typeCurrent(); }, 5000); }); } typeCurrent(); }); function magicEightBall() { var screens = $('#screens'); var screen = $('#screen'); var emoji = $('.animate'); var wash = $('.wash'); screens.css({ '-webkit-animation-name' : 'dip', '-moz-animation-name' : 'dip' }); setTimeout(function() { screens.css({'-webkit-animation-name' : '', '-moz-animation-name' : '' }); }, 300); var roomClasses = ['room1', 'room2', 'room3']; setTimeout(function() { for (var idx = 0; idx < roomClasses.length; idx++) { if (screen.hasClass(roomClasses[idx])) { break; } } screen.removeClass(); idx++; idx = idx >= roomClasses.length ? 0 : idx; setTimeout(function() { screen.addClass(roomClasses[idx]); }, 0); }, 400); setTimeout(function() { emoji.css({'-webkit-animation-name' : 'like', '-moz-animation-name' : 'like'}); wash.css({'-webkit-animation-name' : 'opacity', '-moz-animation-name' : 'opacity'}); setTimeout(function() { emoji.css({'-webkit-animation-name' : '', '-moz-animation-name' : ''}); wash.css({'-webkit-animation-name' : '', '-moz-animation-name' : ''}); }, 4000); }, 2000); } function performTyping(nameStr, emoji, callback) { var name = $('#name'); name.html(' '); name.removeClass(); var idx = 0; function typeChar() { setTimeout(function() { if (idx < nameStr.length) { name.html(nameStr.substr(0, ++idx)); typeChar(); } else { name.addClass(emoji); if (callback) { callback(); } } }, idx === 0 ? 300 : 100); } typeChar(); };
查找差异