私は TurnJS ライブラリを使用してフリップブックを作成しており、ツールチップ ライブラリも使用しています。
本とツールチップはいくつかのページで機能しますが、機能しない場合があります。ツールチップ機能が読み込めないようです。どうしてか分かりません。この問題を解決するには、特定のイベントを使用する必要がありますか? ここに私のツールチップ関数があります:
$(document).ready(function($) {
$('.source').each(function() {
var selector = '#' + $(this).data('source-id');
Tipped.create(this, $(selector)[0], {
skin: 'white',
hook: 'topleft',
hideOn: 'click',
showOn: 'click',
maxWidth: 250,
closeButton: true
});
});
});
フリップブックを次のようにロードします。
function loadApp() {
// Create the flipbook
$('.flipbook').turn({
// Width
width: 900,
// Height
height: 620,
// Elevation
elevation: 50,
// Enable gradients
gradients: true,
duration: 1000,
pages: 16,
// Auto center this flipbook
autoCenter: true,
});
}
// Load the HTML4 version if there's not CSS transform
yepnope({
test: Modernizr.csstransforms,
yep: ['lib/turn.js'],
nope: ['lib/turn.html4.min.js'],
both: ['css/basic.css'],
complete: loadApp
});
ご協力いただきありがとうございます