diff --git a/dbd/qq/SYS_SAIMOD_API_SINGLE_SELECT.php b/dbd/qq/SYS_SAIMOD_API_SINGLE_SELECT.php new file mode 100644 index 0000000..d90fb8f --- /dev/null +++ b/dbd/qq/SYS_SAIMOD_API_SINGLE_SELECT.php @@ -0,0 +1,11 @@ + +
Api Call: ${ID}
+
+ + + + + + + + + + + + + + + + + + + +
IDGroupTypeParentIDParentValueNameVerify
${ID}${group}${type}${parentID}${parentValue}${name}${verify}
+ + + diff --git a/sai/modules/saimod_sys_api/saimod_sys_api.js b/sai/modules/saimod_sys_api/saimod_sys_api.js index 8095bef..9aca751 100644 --- a/sai/modules/saimod_sys_api/saimod_sys_api.js +++ b/sai/modules/saimod_sys_api/saimod_sys_api.js @@ -1,31 +1,51 @@ var currentID = ''; + function init__SYSTEM_SAI_saimod_sys_api() { - $('tr.api_entries').click(function() { - currentID = $(this).attr("id"); - $('#modaltitle').html("Call ID: "+currentID+'
'); - $('#modal_description').append('
Group: '+$(this).attr("group")+'
'); - $('#modal_description').append('Type: '+$(this).attr("typ")+'
'); - $('#modal_description').append('ParentID: '+$(this).attr("parentID")+'
'); - $('#modal_description').append('ParentValue: '+$(this).attr("parentValue")+'
'); - $('#modal_description').append('Name: '+$(this).attr("name")+'
'); - $('#modal_description').append('Verify: '+$(this).attr("verify")+'
'); - $('#modal_api').modal('show'); + saimod_sys_api_register_clickevents(); + +} + +function saimod_sys_api_loadcontent(){ + $('#api_wrapper').load(SAI_ENDPOINT+'sai_mod=.SYSTEM.SAI.saimod_sys_api', function(){ + console.log('api module loaded'); + saimod_sys_api_register_clickevents(); }); - $('#del_api').click(function() { + +} + +function saimod_sys_api_register_clickevents(){ + $('tr.api_entries').click(function() { + console.log("ahsf"); + currentID = $(this).attr("id"); $.ajax({ url: SAI_ENDPOINT, data: { sai_mod: '.SYSTEM.SAI.saimod_sys_api', - action: 'deletecall', + action: 'deletedialog', ID: currentID}, type: 'GET', success: function(data) { - console.log("api call deleted"); - $('#modal_api').modal('hide'); - } - }); - }); + console.log("works"); + $('#api_content').html(data); + $('#del_api_close').click(function() { + console.log("olenski"); + $('#del_api_description').hide(); + $('#del_api_del').show(); + saimod_sys_api_loadcontent(); + }); + $('#del_api_del').click(function() { + $.ajax({ + url: SAI_ENDPOINT, + data: { sai_mod: '.SYSTEM.SAI.saimod_sys_api', + action: 'deletecall', + ID: currentID}, + type: 'GET', + success: function(data) { + console.log("api call deleted"); + $('#api_deletedialog').html('

Api call deleted!

'); + $('#del_api_del').hide(); + }});});}});}); + $('#addcall').click(function() { - console.log("bla"); var id = $('#new_call_id').val(); var group = $('#new_call_group').val(); var type = $('#new_call_type').val(); @@ -47,8 +67,16 @@ function init__SYSTEM_SAI_saimod_sys_api() { type: 'GET', success: function(data) { console.log("new api call added"); + saimod_sys_api_loadcontent(); } - });}); + }); + }); + $('#del_api_close').click(function() { + console.log("olenski"); + $('#del_api_description').hide(); + $('#del_api_del').show(); + saimod_sys_api_loadcontent(); + }); $('#localetab a').click(function (e) {e.preventDefault(); $(this).tab('show');}); } \ No newline at end of file diff --git a/sai/modules/saimod_sys_api/saimod_sys_api.php b/sai/modules/saimod_sys_api/saimod_sys_api.php index 1024146..0aa884e 100644 --- a/sai/modules/saimod_sys_api/saimod_sys_api.php +++ b/sai/modules/saimod_sys_api/saimod_sys_api.php @@ -50,6 +50,13 @@ class saimod_sys_api extends \SYSTEM\SAI\SaiModule { return $result;*/ } + public static function sai_mod__system_sai_saimod_sys_api_action_deletedialog($ID){ + new \SYSTEM\LOG\WARNING("api call added"); + new \SYSTEM\LOG\WARNING(print_r($ID, true)); + $res = \SYSTEM\DBD\SYS_SAIMOD_API_SINGLE_SELECT::Q1(array($ID)); + return \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_api/delete_dialog.tpl'), $res); + } + public static function sai_mod__system_sai_saimod_sys_api_action_addcall($ID,$group,$type,$parentID,$parentValue,$name,$verify){ new \SYSTEM\LOG\WARNING("api call added"); $res = \SYSTEM\DBD\SYS_SAIMOD_API_ADD::QI(array($ID,$group,$type,$parentID,$parentValue,$name,$verify)); diff --git a/sai/modules/saimod_sys_api/tabs.tpl b/sai/modules/saimod_sys_api/tabs.tpl index e59aaca..508cdcc 100644 --- a/sai/modules/saimod_sys_api/tabs.tpl +++ b/sai/modules/saimod_sys_api/tabs.tpl @@ -1,5 +1,7 @@ +

System API


+
\ No newline at end of file +
+
\ No newline at end of file diff --git a/sai/modules/saimod_sys_files/saimod_sys_files.js b/sai/modules/saimod_sys_files/saimod_sys_files.js index 264f45b..c2d2548 100644 --- a/sai/modules/saimod_sys_files/saimod_sys_files.js +++ b/sai/modules/saimod_sys_files/saimod_sys_files.js @@ -1,4 +1,5 @@ -function init__SYSTEM_SAI_saimod_sys_files() { +function init__SYSTEM_SAI_saimod_sys_files() { + $('.tooltip').tooltipster(); $('#filestab a').click(function (e) {e.preventDefault(); load_tab($(this).attr('tabname')); $(this).tab('show');}); register_controlls(); } diff --git a/sai/page/default_page.php b/sai/page/default_page.php index bd9d029..5ef5460 100644 --- a/sai/page/default_page.php +++ b/sai/page/default_page.php @@ -44,6 +44,7 @@ class default_page extends \SYSTEM\PAGE\Page { private static function js(){ $result = ''. ''. + ''. ''. ''. ''. diff --git a/sai/page/js/libs/tooltipster-master/.gitignore b/sai/page/js/libs/tooltipster-master/.gitignore new file mode 100644 index 0000000..e43b0f9 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/.gitignore @@ -0,0 +1 @@ +.DS_Store diff --git a/sai/page/js/libs/tooltipster-master/README.md b/sai/page/js/libs/tooltipster-master/README.md new file mode 100644 index 0000000..54c0cc3 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/README.md @@ -0,0 +1,59 @@ +Tooltipster +=========== + +A jQuery tooltip plugin by Caleb Jacob under MIT license. +Compatible with Mozilla Firefox, Google Chrome, IE8+ and others. Requires jQuery 1.7+ + +A reminder of options/methods lies below. For detailed documentation, visit http://iamceege.github.io/tooltipster/ + +Options +------------------------- + +animation +arrow +arrowColor +autoClose +content +contentAsHTML +contentCloning +delay +minWidth +maxWidth +functionInit +functionBefore +functionReady +functionAfter +icon +iconCloning +iconDesktop +iconTheme +iconTouch +interactive +interactiveTolerance +multiple +offsetX +offsetY +onlyOne +position +positionTracker +speed +timer +theme +touchDevices +trigger +updateAnimation + +Methods +------------------------- + +$.fn.tooltipster('setDefaults', {}) +$(...).tooltipster('show' [, callback]) +$(...).tooltipster('hide' [, callback]) +$(...).tooltipster('disable') +$(...).tooltipster('enable') +$(...).tooltipster('destroy') +$(...).tooltipster('content') +$(...).tooltipster('content', myNewContent) +$(...).tooltipster('reposition') +$(...).tooltipster('elementTooltip') +$(...).tooltipster('elementIcon') \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/bower.json b/sai/page/js/libs/tooltipster-master/bower.json new file mode 100644 index 0000000..52f12dd --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/bower.json @@ -0,0 +1,8 @@ +{ + "name": "tooltipster", + "version": "3.2.4", + "main": ["js/jquery.tooltipster.min.js", "css/tooltipster.css"], + "dependencies": { + "jquery": ">=1.7" + } +} \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-light.css b/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-light.css new file mode 100644 index 0000000..945aa69 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-light.css @@ -0,0 +1,12 @@ +.tooltipster-light { + border-radius: 5px; + border: 1px solid #cccccc; + background: #ededed; + color: #666666; +} +.tooltipster-light .tooltipster-content { + font-family: Arial, sans-serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; +} \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-noir.css b/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-noir.css new file mode 100644 index 0000000..548b245 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-noir.css @@ -0,0 +1,12 @@ +.tooltipster-noir { + border-radius: 0px; + border: 3px solid #2c2c2c; + background: #fff; + color: #2c2c2c; +} +.tooltipster-noir .tooltipster-content { + font-family: 'Georgia', serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; +} \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-punk.css b/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-punk.css new file mode 100644 index 0000000..0b7362c --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-punk.css @@ -0,0 +1,12 @@ +.tooltipster-punk { + border-radius: 5px; + border-bottom: 3px solid #f71169; + background: #2a2a2a; + color: #fff; +} +.tooltipster-punk .tooltipster-content { + font-family: 'Courier', monospace; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; +} \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-shadow.css b/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-shadow.css new file mode 100644 index 0000000..e869c5e --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/css/themes/tooltipster-shadow.css @@ -0,0 +1,12 @@ +.tooltipster-shadow { + border-radius: 5px; + background: #fff; + box-shadow: 0px 0px 14px rgba(0,0,0,0.3); + color: #2c2c2c; +} +.tooltipster-shadow .tooltipster-content { + font-family: 'Arial', sans-serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; +} \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/css/tooltipster.css b/sai/page/js/libs/tooltipster-master/css/tooltipster.css new file mode 100644 index 0000000..e5c609c --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/css/tooltipster.css @@ -0,0 +1,274 @@ +/* This is the default Tooltipster theme (feel free to modify or duplicate and create multiple themes!): */ +.tooltipster-default { + border-radius: 5px; + border: 2px solid #000; + background: #4c4c4c; + color: #fff; +} + +/* Use this next selector to style things like font-size and line-height: */ +.tooltipster-default .tooltipster-content { + font-family: Arial, sans-serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; + overflow: hidden; +} + +/* This next selector defines the color of the border on the outside of the arrow. This will automatically match the color and size of the border set on the main tooltip styles. Set display: none; if you would like a border around the tooltip but no border around the arrow */ +.tooltipster-default .tooltipster-arrow .tooltipster-arrow-border { + /* border-color: ... !important; */ +} + + +/* If you're using the icon option, use this next selector to style them */ +.tooltipster-icon { + cursor: help; + margin-left: 4px; +} + + + + + + + + +/* This is the base styling required to make all Tooltipsters work */ +.tooltipster-base { + padding: 0; + font-size: 0; + line-height: 0; + position: absolute; + left: 0; + top: 0; + z-index: 9999999; + pointer-events: none; + width: auto; + overflow: visible; +} +.tooltipster-base .tooltipster-content { + overflow: hidden; +} + + +/* These next classes handle the styles for the little arrow attached to the tooltip. By default, the arrow will inherit the same colors and border as what is set on the main tooltip itself. */ +.tooltipster-arrow { + display: block; + text-align: center; + width: 100%; + height: 100%; + position: absolute; + top: 0; + left: 0; + z-index: -1; +} +.tooltipster-arrow span, .tooltipster-arrow-border { + display: block; + width: 0; + height: 0; + position: absolute; +} +.tooltipster-arrow-top span, .tooltipster-arrow-top-right span, .tooltipster-arrow-top-left span { + border-left: 8px solid transparent !important; + border-right: 8px solid transparent !important; + border-top: 8px solid; + bottom: -7px; +} +.tooltipster-arrow-top .tooltipster-arrow-border, .tooltipster-arrow-top-right .tooltipster-arrow-border, .tooltipster-arrow-top-left .tooltipster-arrow-border { + border-left: 9px solid transparent !important; + border-right: 9px solid transparent !important; + border-top: 9px solid; + bottom: -7px; +} + +.tooltipster-arrow-bottom span, .tooltipster-arrow-bottom-right span, .tooltipster-arrow-bottom-left span { + border-left: 8px solid transparent !important; + border-right: 8px solid transparent !important; + border-bottom: 8px solid; + top: -7px; +} +.tooltipster-arrow-bottom .tooltipster-arrow-border, .tooltipster-arrow-bottom-right .tooltipster-arrow-border, .tooltipster-arrow-bottom-left .tooltipster-arrow-border { + border-left: 9px solid transparent !important; + border-right: 9px solid transparent !important; + border-bottom: 9px solid; + top: -7px; +} +.tooltipster-arrow-top span, .tooltipster-arrow-top .tooltipster-arrow-border, .tooltipster-arrow-bottom span, .tooltipster-arrow-bottom .tooltipster-arrow-border { + left: 0; + right: 0; + margin: 0 auto; +} +.tooltipster-arrow-top-left span, .tooltipster-arrow-bottom-left span { + left: 6px; +} +.tooltipster-arrow-top-left .tooltipster-arrow-border, .tooltipster-arrow-bottom-left .tooltipster-arrow-border { + left: 5px; +} +.tooltipster-arrow-top-right span, .tooltipster-arrow-bottom-right span { + right: 6px; +} +.tooltipster-arrow-top-right .tooltipster-arrow-border, .tooltipster-arrow-bottom-right .tooltipster-arrow-border { + right: 5px; +} +.tooltipster-arrow-left span, .tooltipster-arrow-left .tooltipster-arrow-border { + border-top: 8px solid transparent !important; + border-bottom: 8px solid transparent !important; + border-left: 8px solid; + top: 50%; + margin-top: -7px; + right: -7px; +} +.tooltipster-arrow-left .tooltipster-arrow-border { + border-top: 9px solid transparent !important; + border-bottom: 9px solid transparent !important; + border-left: 9px solid; + margin-top: -8px; +} +.tooltipster-arrow-right span, .tooltipster-arrow-right .tooltipster-arrow-border { + border-top: 8px solid transparent !important; + border-bottom: 8px solid transparent !important; + border-right: 8px solid; + top: 50%; + margin-top: -7px; + left: -7px; +} +.tooltipster-arrow-right .tooltipster-arrow-border { + border-top: 9px solid transparent !important; + border-bottom: 9px solid transparent !important; + border-right: 9px solid; + margin-top: -8px; +} + + +/* Some CSS magic for the awesome animations - feel free to make your own custom animations and reference it in your Tooltipster settings! */ + +.tooltipster-fade { + opacity: 0; + -webkit-transition-property: opacity; + -moz-transition-property: opacity; + -o-transition-property: opacity; + -ms-transition-property: opacity; + transition-property: opacity; +} +.tooltipster-fade-show { + opacity: 1; +} + +.tooltipster-grow { + -webkit-transform: scale(0,0); + -moz-transform: scale(0,0); + -o-transform: scale(0,0); + -ms-transform: scale(0,0); + transform: scale(0,0); + -webkit-transition-property: -webkit-transform; + -moz-transition-property: -moz-transform; + -o-transition-property: -o-transform; + -ms-transition-property: -ms-transform; + transition-property: transform; + -webkit-backface-visibility: hidden; +} +.tooltipster-grow-show { + -webkit-transform: scale(1,1); + -moz-transform: scale(1,1); + -o-transform: scale(1,1); + -ms-transform: scale(1,1); + transform: scale(1,1); + -webkit-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1); + -webkit-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + -moz-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + -ms-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + -o-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); +} + +.tooltipster-swing { + opacity: 0; + -webkit-transform: rotateZ(4deg); + -moz-transform: rotateZ(4deg); + -o-transform: rotateZ(4deg); + -ms-transform: rotateZ(4deg); + transform: rotateZ(4deg); + -webkit-transition-property: -webkit-transform, opacity; + -moz-transition-property: -moz-transform; + -o-transition-property: -o-transform; + -ms-transition-property: -ms-transform; + transition-property: transform; +} +.tooltipster-swing-show { + opacity: 1; + -webkit-transform: rotateZ(0deg); + -moz-transform: rotateZ(0deg); + -o-transform: rotateZ(0deg); + -ms-transform: rotateZ(0deg); + transform: rotateZ(0deg); + -webkit-transition-timing-function: cubic-bezier(0.230, 0.635, 0.495, 1); + -webkit-transition-timing-function: cubic-bezier(0.230, 0.635, 0.495, 2.4); + -moz-transition-timing-function: cubic-bezier(0.230, 0.635, 0.495, 2.4); + -ms-transition-timing-function: cubic-bezier(0.230, 0.635, 0.495, 2.4); + -o-transition-timing-function: cubic-bezier(0.230, 0.635, 0.495, 2.4); + transition-timing-function: cubic-bezier(0.230, 0.635, 0.495, 2.4); +} + +.tooltipster-fall { + top: 0; + -webkit-transition-property: top; + -moz-transition-property: top; + -o-transition-property: top; + -ms-transition-property: top; + transition-property: top; + -webkit-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1); + -webkit-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + -moz-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + -ms-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + -o-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); +} +.tooltipster-fall-show { +} +.tooltipster-fall.tooltipster-dying { + -webkit-transition-property: all; + -moz-transition-property: all; + -o-transition-property: all; + -ms-transition-property: all; + transition-property: all; + top: 0px !important; + opacity: 0; +} + +.tooltipster-slide { + left: -40px; + -webkit-transition-property: left; + -moz-transition-property: left; + -o-transition-property: left; + -ms-transition-property: left; + transition-property: left; + -webkit-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1); + -webkit-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + -moz-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + -ms-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + -o-transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); + transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.15); +} +.tooltipster-slide.tooltipster-slide-show { +} +.tooltipster-slide.tooltipster-dying { + -webkit-transition-property: all; + -moz-transition-property: all; + -o-transition-property: all; + -ms-transition-property: all; + transition-property: all; + left: 0px !important; + opacity: 0; +} + + +/* CSS transition for when contenting is changing in a tooltip that is still open. The only properties that will NOT transition are: width, height, top, and left */ +.tooltipster-content-changing { + opacity: 0.5; + -webkit-transform: scale(1.1, 1.1); + -moz-transform: scale(1.1, 1.1); + -o-transform: scale(1.1, 1.1); + -ms-transform: scale(1.1, 1.1); + transform: scale(1.1, 1.1); +} diff --git a/sai/page/js/libs/tooltipster-master/demo/index.html b/sai/page/js/libs/tooltipster-master/demo/index.html new file mode 100644 index 0000000..531e5b5 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/demo/index.html @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + +
+ Google +
+ +
+ +
+ + + + +
+ + diff --git a/sai/page/js/libs/tooltipster-master/demo/map.png b/sai/page/js/libs/tooltipster-master/demo/map.png new file mode 100644 index 0000000..2f68c91 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/demo/map.png differ diff --git a/sai/page/js/libs/tooltipster-master/demo/reset.css b/sai/page/js/libs/tooltipster-master/demo/reset.css new file mode 100644 index 0000000..39a6a66 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/demo/reset.css @@ -0,0 +1,45 @@ +@charset "UTF-8"; + +html, body, div, span, applet, object, iframe, +h1, h2, h3, h4, h5, h6, p, blockquote, pre, +a, abbr, acronym, address, big, cite, code, +del, dfn, em, img, ins, kbd, q, s, samp, +small, strike, strong, sub, sup, tt, var, +b, u, i, center, +dl, dt, dd, ol, ul, li, +fieldset, form, label, legend, +table, caption, tbody, tfoot, thead, tr, th, td, +article, aside, canvas, details, embed, +figure, figcaption, footer, header, hgroup, +menu, nav, output, ruby, section, summary, +time, mark, audio, video { + margin: 0; + padding: 0; + border: 0; + font-size:100%; + vertical-align: baseline; +} +/* HTML5 display-role reset for older browsers */ +article, aside, details, figcaption, figure, +footer, header, hgroup, menu, nav, section { + display: block; +} +body { + line-height: 1; +} +ol, ul { + list-style: none; +} +blockquote, q { + quotes: none; +} +blockquote:before, blockquote:after, +q:before, q:after { + content: ''; + content: none; +} +table { + border-collapse: collapse; + border-spacing: 0; +} + diff --git a/sai/page/js/libs/tooltipster-master/demo/style.css b/sai/page/js/libs/tooltipster-master/demo/style.css new file mode 100644 index 0000000..3b6162e --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/demo/style.css @@ -0,0 +1,28 @@ +/* Main */ + +body { + background-color: #dcdcdc; + color: #0b0b0b; + font-size: 16px; + line-height: 22px; +} + +.container, #container { + width: 978px; + margin: 10px auto; + padding: 60px; + box-shadow: 0px 0px 10px rgba(0,0,0,0.2); + background: #fff; + text-align: left; + display: block; + overflow: hidden; +} + +.item { + width: 200px; + float: left; + padding: 10px; + margin: 10px; + background: #000; + color: #fff; +} \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/doc/css/prettify.css b/sai/page/js/libs/tooltipster-master/doc/css/prettify.css new file mode 100644 index 0000000..90cfb39 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/doc/css/prettify.css @@ -0,0 +1,49 @@ +/* Pretty printing styles. Used with prettify.js. */ + +/* SPAN elements with the classes below are added by prettyprint. */ +.pln { color: #000 } /* plain text */ + +@media screen { + .str { color: #080 } /* string content */ + .kwd { color: #008 } /* a keyword */ + .com { color: #800 } /* a comment */ + .typ { color: #606 } /* a type name */ + .lit { color: #066 } /* a literal value */ + /* punctuation, lisp open bracket, lisp close bracket */ + .pun, .opn, .clo { color: #660 } + .tag { color: #008 } /* a markup tag name */ + .atn { color: #606 } /* a markup attribute name */ + .atv { color: #080 } /* a markup attribute value */ + .dec, .var { color: #606 } /* a declaration; a variable name */ + .fun { color: red } /* a function name */ +} + +/* Use higher contrast and text-weight for printable form. */ +@media print, projection { + .str { color: #060 } + .kwd { color: #006; font-weight: bold } + .com { color: #600; font-style: italic } + .typ { color: #404; font-weight: bold } + .lit { color: #044 } + .pun, .opn, .clo { color: #440 } + .tag { color: #006; font-weight: bold } + .atn { color: #404 } + .atv { color: #060 } +} + +/* Specify class=linenums on a pre to get line numbering */ +ol.linenums { margin-top: 0; margin-bottom: 0 } /* IE indents via margin-left */ +li.L0, +li.L1, +li.L2, +li.L3, +li.L5, +li.L6, +li.L7, +li.L8 { list-style-type: none } +/* Alternate shading for lines */ +li.L1, +li.L3, +li.L5, +li.L7, +li.L9 { background: #eee } diff --git a/sai/page/js/libs/tooltipster-master/doc/css/reset.css b/sai/page/js/libs/tooltipster-master/doc/css/reset.css new file mode 100644 index 0000000..39a6a66 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/doc/css/reset.css @@ -0,0 +1,45 @@ +@charset "UTF-8"; + +html, body, div, span, applet, object, iframe, +h1, h2, h3, h4, h5, h6, p, blockquote, pre, +a, abbr, acronym, address, big, cite, code, +del, dfn, em, img, ins, kbd, q, s, samp, +small, strike, strong, sub, sup, tt, var, +b, u, i, center, +dl, dt, dd, ol, ul, li, +fieldset, form, label, legend, +table, caption, tbody, tfoot, thead, tr, th, td, +article, aside, canvas, details, embed, +figure, figcaption, footer, header, hgroup, +menu, nav, output, ruby, section, summary, +time, mark, audio, video { + margin: 0; + padding: 0; + border: 0; + font-size:100%; + vertical-align: baseline; +} +/* HTML5 display-role reset for older browsers */ +article, aside, details, figcaption, figure, +footer, header, hgroup, menu, nav, section { + display: block; +} +body { + line-height: 1; +} +ol, ul { + list-style: none; +} +blockquote, q { + quotes: none; +} +blockquote:before, blockquote:after, +q:before, q:after { + content: ''; + content: none; +} +table { + border-collapse: collapse; + border-spacing: 0; +} + diff --git a/sai/page/js/libs/tooltipster-master/doc/css/style.css b/sai/page/js/libs/tooltipster-master/doc/css/style.css new file mode 100644 index 0000000..f47c843 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/doc/css/style.css @@ -0,0 +1,678 @@ +/*blue #0078c9 +orange #ff5e3c */ + +@import url(//fonts.googleapis.com/css?family=Open+Sans:300,400,600,700); + +@font-face { + font-family: 'icomoon'; + src:url('../images/icons/icomoon.eot'); + src:url('../images/icons/icomoond41d.eot?#iefix') format('embedded-opentype'), + url('../images/icons/icomoon.svg#icomoon') format('svg'), + url('../images/icons/icomoon.woff') format('woff'), + url('../images/icons/icomoon.ttf') format('truetype'); + font-weight: normal; + font-style: normal; +} + +::selection { + background: #0078c9; + color: #fff; +} +::-moz-selection { + background: #0078c9; + color: #fff; +} + +body { + color: #5d6365; + font-size: 1em; + line-height: 1.6em; + font-family: 'Open Sans', sans-serif; + font-weight: 300; + background: #5d6365; +} + +#background { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + overflow: hidden; +} +#background img { + min-height: 100%; + min-width: 100%; +} +#background:before { + content: ''; + display: block; + width: 100%; + height: 20%; + position: absolute; + bottom: 0; + background: -moz-linear-gradient(top, rgba(93,99,101,0) 0%, rgba(93,99,101,1) 100%); /* FF3.6+ */ + background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(93,99,101,0)), color-stop(100%,rgba(93,99,101,1))); /* Chrome,Safari4+ */ + background: -webkit-linear-gradient(top, rgba(93,99,101,0) 0%,rgba(93,99,101,1) 100%); /* Chrome10+,Safari5.1+ */ + background: -o-linear-gradient(top, rgba(93,99,101,0) 0%,rgba(93,99,101,1) 100%); /* Opera 11.10+ */ + background: -ms-linear-gradient(top, rgba(93,99,101,0) 0%,rgba(93,99,101,1) 100%); /* IE10+ */ + background: linear-gradient(to bottom, rgba(93,99,101,0) 0%,rgba(93,99,101,1) 100%); /* W3C */ + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#005d6365', endColorstr='#5d6365',GradientType=0 ); /* IE6-9 */ +} + +#wrapper { + width: 100%; + max-width: 1300px; + margin: 0 auto; + position: relative; + box-shadow: 0.6em 0px 15px rgba(0,0,0,0.1), -0.6em 0px 15px rgba(0,0,0,0.1); +} + +* { + -webkit-transition: all 300ms; + -moz-transition: all 300ms; + -o-transition: all 300ms; + -ms-transition: all 300ms; + transition: all 300ms; +} + +h1 { + font-weight: 300; + font-size: 1.4em; + line-height: 1.4em; + margin-bottom: 1.8em; +} +h2 { + color: #a9b1b3; + font-weight: 300; + font-size: 4em; + line-height: 1.4em; + margin-bottom: 0.5em; +} +h3 { + font-size: 2em; + line-height: 1.4em; + margin-bottom: 0.7em; + padding-top: 1em; +} +h4 { + font-size: 1.4em; + line-height: 1.4em; + font-weight: 400; + margin-bottom: 1em; +} +p { + margin-bottom: 1.5em; +} + +strong { + font-weight: 600; +} + +a { + text-decoration: none; + color: #0078c9; + font-weight: 600; +} +a:hover { + color: #a9b1b3; +} +a.alt { + color: rgba(255,255,255,0.75); +} +a.alt:hover { + color: rgba(255,255,255,1); +} + +a:before { + font-family: 'icomoon'; + font-style: normal; + speak: none; + font-weight: normal; + line-height: 1; + -webkit-font-smoothing: antialiased; +} + +a.button { + display: inline-block; + padding: 0.8em 1em; + border: 3px solid #ff5e3c; + border-radius: 6px; + color: #ff5e3c; + background: #fff; + font-weight: 600; +} +a.button:hover { + background: #ff5e3c; + color: #fff; +} +a.button.alt { + color: #ff5e3c; + border: none; +} +a.button.alt:hover { + background: #ff5e3c; + color: #fff; + border: none; +} +a.button:active { + -webkit-transform: scale3d(0.95,0.95,1); + -moz-transform: scale3d(0.95,0.95,1); + -o-transform: scale3d(0.95,0.95,1); + -ms-transform: scale3d(0.95,0.95,1); + transform: scale3d(0.95,0.95,1); +} + +a.white { + color: #fff; + padding-bottom: 3px; + border-bottom: 1px solid rgba(255,255,255,0); +} +a.white:hover { + border-bottom: 1px solid rgba(255,255,255,1); +} + +.row { + overflow: hidden; +} + +header { + background: #fff; + max-width: 1300px; + box-shadow: 0px 3px 0px rgba(0,0,0,0.05); +} +header select { + display: none; +} + +section { + width: 100%; + margin: 0 auto; + overflow: hidden; + border-bottom: 2px dashed #e5eaeb; + padding: 6em; + background: #fff; + box-sizing: border-box; + -moz-box-sizing: border-box; +} +#talk { + border-bottom: none !important; +} + +footer { + width: 100%; + margin: 0 auto; + padding: 6em; + background: #0078c9; + color: #fff; + box-sizing: border-box; + -moz-box-sizing: border-box; + text-align: center; +} + +nav { + width: 100%; + max-width: 1300px; + box-sizing: border-box; + -moz-box-sizing: border-box; + background: #fff; + float: right; + z-index: 2; + text-align: right; +} +nav ul { + display: block; + width: auto; + float: right; +} +nav li { + display: inline-block; + margin: 0; + float: left; +} +nav a { + display: inline-block; + font-weight: 400; + color: #a9b1b3; + padding: 1.5em 0.75em; +} +nav a:hover { + background: #0078c9; + color: #fff; +} + +#mobile-nav { + display: none; +} + +#social { + width: auto; + position: absolute; + left: 0; + top: 0; + z-index: 3; +} +#social div { + float: left; + width: 90px; + padding: 1.5em 2em; +} +#tweet { + margin-top: 2px; +} +div#github { + position: relative; + bottom: 4px; + margin-left: 0px; + padding-top: 2em; + width: 90px; +} +#github a { + -webkit-transition: none; + -moz-transition: none; + -o-transition: none; + -ms-transition: none; + transition: none; +} + +pre { + box-sizing: border-box; + -moz-box-sizing: border-box; + padding: 3em; + background: #e6eff1; + box-shadow: 0px 0px 20px rgba(0,0,0,0.0); + margin-bottom: 4em; + white-space: pre-wrap; +} +pre:hover { + background: #fff; + box-shadow: 0px 0px 20px rgba(0,0,0,0.3); +} +pre:last-child { + margin-bottom: 0; +} + + +/* +------------------------------------- +Welcome +------------------------------------- +*/ + +#welcome { + text-align: center; + padding: 12em 0 9em; + color: #fff; + width: 100%; + border-bottom: none; + background: rgba(0,0,0,0.3); +} + +#welcome h1 { + display: block; + max-width: 635px; + margin-left: auto; + margin-right: auto; +} + +#tooltipster { + width: 100%; + max-width: 258px; + margin-bottom: 2em; +} + +#browser-support { + margin-bottom: 2.8em; +} +#browser-support li { + display: inline-block; + margin: 0.25em; + font-size: 0; + line-height: 0; +} +#browser-support li img { + height: 42px; + opacity: 0.5; +} +#browser-support li img:hover { + opacity: 1; +} + +#download { + font-size: 1.2em; + line-height: 1.4em; + width: 100%; +} +#download a.button { + margin-right: 0.6em; +} +#download a.button:before { + content: "\64"; + padding-right: 1em; + font-size: 0.9em; +} + + +/* +------------------------------------- +Demos +------------------------------------- +*/ + +#demos ul { + display: block; + width: 100%; + font-size: 1.4em; + line-height: 1.4em; +} +#demos li { + display: block; + width: 50%; + font-weight: 400; + margin-bottom: 1em; + overflow: hidden; + padding-top: 1.4em; + padding-right: 2em; + box-sizing: border-box; + -moz-box-sizing: border-box; + float: left; +} +#demos span { + display: block; + border: 3px solid #ff5e3c; + border-radius: 100%; + box-sizing: border-box; + -moz-box-sizing: border-box; + width: 5em; + height: 5em; + background: #ff5e3c; + color: #fff; + font-size: 0.6em; + line-height: 1em; + font-weight: 700; + padding: 1.8em 0 0 0; + text-align: center; + margin: -1.4em 1em 0 0; + text-transform: uppercase; + float: left; +} +#demos span:hover { + background: #fff !important; + color: #5d6365; + border: 3px solid #5d6365 !important; + cursor: pointer; +} + + +/* +------------------------------------- +Tooltips +------------------------------------- +*/ + +#demos span.tooltipster-icon { + cursor: help; + margin-left: 4px; + background: #0078c9; + border: 3px solid #0078c9; + width: 2.3em; + height: 2.3em; + padding: 0.4em 0 0; + margin: 2em 0 0 -3em; +} + +.tooltipster-default .tooltipster-content { + font-family: 'Open Sans', sans-serif; +} +.tooltipster-default .tooltipster-content img { + float: left; + margin-right: 10px; + border: 2px solid #000; +} +.tooltipster-default .tooltipster-content p { + margin: 0; +} +.tooltipster-default .tooltipster-content a { + color: #fff; + border-bottom: 1px solid rgba(255,255,255,0.4); +} +.tooltipster-default .tooltipster-content a:hover { + color: #fff; + border-bottom: 1px solid rgba(255,255,255,1); +} + +.tooltipster-blue { + background: #0078c9; + color: #fff; + border-radius: 5px; +} +.tooltipster-blue .tooltipster-content { + font-family: 'Open Sans', sans-serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; +} + +.tooltipster-white { + background: #fff; + color: #0078c9; + border-radius: 5px; +} +.tooltipster-white .tooltipster-content { + font-family: 'Open Sans', sans-serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; +} + +.tooltipster-pink { + background: url(../images/pattern-navy.png); + background-color: #ff3c70; + color: #fff; + border-radius: 5px; + box-shadow: inset -3px -3px 0 #ff3c70; +} +.tooltipster-pink .tooltipster-content { + font-family: 'Courier', monospace; + font-weight: 400; + font-size: 16px; + line-height: 16px; + padding: 15px 18px; +} + + +/* +------------------------------------- +Options +------------------------------------- +*/ + +table { + width: 100%; +} +table h4 { + margin-bottom: 0; +} +tr:nth-child(odd) { + background: #f4f5f7; +} +td { + padding: 2em; +} +td h4 { + font-family: 'Courier', monospace; + color: #0078c9; +} + + +/* +------------------------------------- +Themes +------------------------------------- +*/ + +#themes .themes span { + display: inline-block; + padding: 1em; + margin-right: 1em; + margin-bottom: 1em; + opacity: 0.8; +} + +.tooltipster-default-preview { + border-radius: 5px; + border: 2px solid #000; + background: #4c4c4c; + color: #fff; + font-family: Arial, sans-serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; + font-weight: 400; + box-sizing: border-box; + -moz-box-sizing: border-box; +} + +.tooltipster-light-preview { + border-radius: 5px; + border: 1px solid #cccccc; + background: #ededed; + color: #666666; + font-family: Arial, sans-serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; + font-weight: 400; +} + +.tooltipster-punk-preview { + border-radius: 5px; + border-bottom: 3px solid #f71169; + background: #2a2a2a; + color: #fff; + font-family: 'Courier', monospace; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; + font-weight: 400; +} + +.tooltipster-noir-preview { + border-radius: 0px; + border: 3px solid #2c2c2c; + background: #fff; + color: #2c2c2c; + font-family: 'Georgia', serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; + font-weight: 400; +} + +.tooltipster-shadow-preview { + border-radius: 5px; + background: #fff; + box-shadow: 0px 0px 14px rgba(0,0,0,0.3); + color: #2c2c2c; + font-family: 'Arial', sans-serif; + font-size: 14px; + line-height: 16px; + padding: 8px 10px; + font-weight: 400; +} + + +/* +------------------------------------- +Talk +------------------------------------- +*/ + +#talk h3 { + margin-bottom: 1em; +} + + +/* +------------------------------------- +Breakpoints +------------------------------------- +*/ + +@media all and (max-width : 1100px) { + #tweet, #gplus { + display: none; + } + #demos li { + width: 100%; + } + table, tr, td { + display: block; + } + td { + padding: 2em 2em 0 2em; + } + td:last-child { + padding-bottom: 2em; + } +} + +@media all and (max-width : 920px) { + #demos ul { + width: 100%; + padding: 0; + } +} + +@media all and (max-width : 820px) { + nav ul { + display: none; + } + #social div { + padding: 0.5em 0.7em; + } + header { + padding: 0; + } + header select { + display: block; + float: right; + margin: 1em 1em; + } + section { + padding: 3em; + } + #welcome { + padding: 7.4em 3em 6em; + } + #download span { + display: block; + margin-top: 0.5em; + } +} + +@media all and (max-width : 450px) { + table h4 { + font-size: 1em; + line-height: 1em; + } + section { + padding: 2em; + } + h2 { + font-size: 3em; + line-height: 1.2em; + margin-bottom: 0.23em; + } + h3 { + font-size: 1.4em; + line-height: 1.4em; + margin-bottom: 1.3em; + } + h4 { + font-size: 1.2em; + } + pre { + padding: 1em; + } +} \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/doc/images/browser-chrome.png b/sai/page/js/libs/tooltipster-master/doc/images/browser-chrome.png new file mode 100644 index 0000000..7e76da6 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/browser-chrome.png differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/browser-firefox.png b/sai/page/js/libs/tooltipster-master/doc/images/browser-firefox.png new file mode 100644 index 0000000..555cb5b Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/browser-firefox.png differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/browser-ie.png b/sai/page/js/libs/tooltipster-master/doc/images/browser-ie.png new file mode 100644 index 0000000..8c63137 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/browser-ie.png differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/browser-opera.png b/sai/page/js/libs/tooltipster-master/doc/images/browser-opera.png new file mode 100644 index 0000000..f6997a3 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/browser-opera.png differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/browser-safari.png b/sai/page/js/libs/tooltipster-master/doc/images/browser-safari.png new file mode 100644 index 0000000..0ab4cc3 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/browser-safari.png differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/favicon.png b/sai/page/js/libs/tooltipster-master/doc/images/favicon.png new file mode 100644 index 0000000..80d6911 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/favicon.png differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.eot b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.eot new file mode 100644 index 0000000..520f558 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.eot differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.svg b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.svg new file mode 100644 index 0000000..7a26a2d --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.svg @@ -0,0 +1,16 @@ + + + + +This is a custom SVG font generated by IcoMoon. + + + + + + + + + + + \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.ttf b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.ttf new file mode 100644 index 0000000..16ba996 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.ttf differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.woff b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.woff new file mode 100644 index 0000000..e370491 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoon.woff differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoond41d.eot b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoond41d.eot new file mode 100644 index 0000000..520f558 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/icons/icomoond41d.eot differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/large-background.jpg b/sai/page/js/libs/tooltipster-master/doc/images/large-background.jpg new file mode 100644 index 0000000..47bafb4 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/large-background.jpg differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/pattern-navy.png b/sai/page/js/libs/tooltipster-master/doc/images/pattern-navy.png new file mode 100644 index 0000000..8c6bb56 Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/pattern-navy.png differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/social.jpg b/sai/page/js/libs/tooltipster-master/doc/images/social.jpg new file mode 100644 index 0000000..f36164a Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/social.jpg differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/spiderman.png b/sai/page/js/libs/tooltipster-master/doc/images/spiderman.png new file mode 100644 index 0000000..ccd88fd Binary files /dev/null and b/sai/page/js/libs/tooltipster-master/doc/images/spiderman.png differ diff --git a/sai/page/js/libs/tooltipster-master/doc/images/tooltipster.svg b/sai/page/js/libs/tooltipster-master/doc/images/tooltipster.svg new file mode 100644 index 0000000..a054afa --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/doc/images/tooltipster.svg @@ -0,0 +1,212 @@ + + + + + + + + + + + + + + diff --git a/sai/page/js/libs/tooltipster-master/doc/js/jquery.jgfeed.js b/sai/page/js/libs/tooltipster-master/doc/js/jquery.jgfeed.js new file mode 100644 index 0000000..36059ee --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/doc/js/jquery.jgfeed.js @@ -0,0 +1,34 @@ +/* + * jGFeed 1.0 - Google Feed API abstraction plugin for jQuery + * + * Copyright (c) 2009 jQuery HowTo + * + * Licensed under the GPL license: + * http://www.gnu.org/licenses/gpl.html + * + * URL: + * http://jquery-howto.blogspot.com + * + * Author URL: + * http://me.boo.uz + * + */ +(function($){ + $.extend({ + jGFeed : function(url, fnk, num, key){ + // Make sure url to get is defined + if(url == null) return false; + // Build Google Feed API URL + var gurl = "http://ajax.googleapis.com/ajax/services/feed/load?v=1.0&callback=?&q="+url+"?"; + if(num != null) gurl += "&num="+num; + if(key != null) gurl += "&key="+key; + // AJAX request the API + $.getJSON(gurl, function(data){ + if(typeof fnk == 'function') + fnk.call(this, data.responseData.feed); + else + return false; + }); + } + }); +})(jQuery); \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/doc/js/lang-css.js b/sai/page/js/libs/tooltipster-master/doc/js/lang-css.js new file mode 100644 index 0000000..034bd59 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/doc/js/lang-css.js @@ -0,0 +1,78 @@ +// Copyright (C) 2009 Google Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + + + +/** + * @fileoverview + * Registers a language handler for CSS. + * + * + * To use, include prettify.js and this file in your HTML page. + * Then put your code in an HTML tag like + *

+ *
+ *
+ * http://www.w3.org/TR/CSS21/grammar.html Section G2 defines the lexical
+ * grammar.  This scheme does not recognize keywords containing escapes.
+ *
+ * @author mikesamuel@gmail.com
+ */
+
+PR['registerLangHandler'](
+    PR['createSimpleLexer'](
+        [
+         // The space production 
+         [PR['PR_PLAIN'],       /^[ \t\r\n\f]+/, null, ' \t\r\n\f']
+        ],
+        [
+         // Quoted strings.   and 
+         [PR['PR_STRING'],
+          /^\"(?:[^\n\r\f\\\"]|\\(?:\r\n?|\n|\f)|\\[\s\S])*\"/, null],
+         [PR['PR_STRING'],
+          /^\'(?:[^\n\r\f\\\']|\\(?:\r\n?|\n|\f)|\\[\s\S])*\'/, null],
+         ['lang-css-str', /^url\(([^\)\"\']*)\)/i],
+         [PR['PR_KEYWORD'],
+          /^(?:url|rgb|\!important|@import|@page|@media|@charset|inherit)(?=[^\-\w]|$)/i,
+          null],
+         // A property name -- an identifier followed by a colon.
+         ['lang-css-kw', /^(-?(?:[_a-z]|(?:\\[0-9a-f]+ ?))(?:[_a-z0-9\-]|\\(?:\\[0-9a-f]+ ?))*)\s*:/i],
+         // A C style block comment.  The  production.
+         [PR['PR_COMMENT'], /^\/\*[^*]*\*+(?:[^\/*][^*]*\*+)*\//],
+         // Escaping text spans
+         [PR['PR_COMMENT'], /^(?:)/],
+         // A number possibly containing a suffix.
+         [PR['PR_LITERAL'], /^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],
+         // A hex color
+         [PR['PR_LITERAL'], /^#(?:[0-9a-f]{3}){1,2}/i],
+         // An identifier
+         [PR['PR_PLAIN'],
+          /^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i],
+         // A run of punctuation
+         [PR['PR_PUNCTUATION'], /^[^\s\w\'\"]+/]
+        ]),
+    ['css']);
+PR['registerLangHandler'](
+    PR['createSimpleLexer']([],
+        [
+         [PR['PR_KEYWORD'],
+          /^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i]
+        ]),
+    ['css-kw']);
+PR['registerLangHandler'](
+    PR['createSimpleLexer']([],
+        [
+         [PR['PR_STRING'], /^[^\)\"\']+/]
+        ]),
+    ['css-str']);
diff --git a/sai/page/js/libs/tooltipster-master/doc/js/prettify.js b/sai/page/js/libs/tooltipster-master/doc/js/prettify.js
new file mode 100644
index 0000000..f66f6f2
--- /dev/null
+++ b/sai/page/js/libs/tooltipster-master/doc/js/prettify.js
@@ -0,0 +1,28 @@
+var q=null;window.PR_SHOULD_USE_CONTINUATION=!0;
+(function(){function L(a){function m(a){var f=a.charCodeAt(0);if(f!==92)return f;var b=a.charAt(1);return(f=r[b])?f:"0"<=b&&b<="7"?parseInt(a.substring(1),8):b==="u"||b==="x"?parseInt(a.substring(2),16):a.charCodeAt(1)}function e(a){if(a<32)return(a<16?"\\x0":"\\x")+a.toString(16);a=String.fromCharCode(a);if(a==="\\"||a==="-"||a==="["||a==="]")a="\\"+a;return a}function h(a){for(var f=a.substring(1,a.length-1).match(/\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\[0-3][0-7]{0,2}|\\[0-7]{1,2}|\\[\S\s]|[^\\]/g),a=
+[],b=[],o=f[0]==="^",c=o?1:0,i=f.length;c122||(d<65||j>90||b.push([Math.max(65,j)|32,Math.min(d,90)|32]),d<97||j>122||b.push([Math.max(97,j)&-33,Math.min(d,122)&-33]))}}b.sort(function(a,f){return a[0]-f[0]||f[1]-a[1]});f=[];j=[NaN,NaN];for(c=0;ci[0]&&(i[1]+1>i[0]&&b.push("-"),b.push(e(i[1])));b.push("]");return b.join("")}function y(a){for(var f=a.source.match(/\[(?:[^\\\]]|\\[\S\s])*]|\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\\d+|\\[^\dux]|\(\?[!:=]|[()^]|[^()[\\^]+/g),b=f.length,d=[],c=0,i=0;c=2&&a==="["?f[c]=h(j):a!=="\\"&&(f[c]=j.replace(/[A-Za-z]/g,function(a){a=a.charCodeAt(0);return"["+String.fromCharCode(a&-33,a|32)+"]"}));return f.join("")}for(var t=0,s=!1,l=!1,p=0,d=a.length;p=5&&"lang-"===b.substring(0,5))&&!(o&&typeof o[1]==="string"))c=!1,b="src";c||(r[f]=b)}i=d;d+=f.length;if(c){c=o[1];var j=f.indexOf(c),k=j+c.length;o[2]&&(k=f.length-o[2].length,j=k-c.length);b=b.substring(5);B(l+i,f.substring(0,j),e,p);B(l+i+j,c,C(b,c),p);B(l+i+k,f.substring(k),e,p)}else p.push(l+i,b)}a.e=p}var h={},y;(function(){for(var e=a.concat(m),
+l=[],p={},d=0,g=e.length;d=0;)h[n.charAt(k)]=r;r=r[1];n=""+r;p.hasOwnProperty(n)||(l.push(r),p[n]=q)}l.push(/[\S\s]/);y=L(l)})();var t=m.length;return e}function u(a){var m=[],e=[];a.tripleQuotedStrings?m.push(["str",/^(?:'''(?:[^'\\]|\\[\S\s]|''?(?=[^']))*(?:'''|$)|"""(?:[^"\\]|\\[\S\s]|""?(?=[^"]))*(?:"""|$)|'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$))/,q,"'\""]):a.multiLineStrings?m.push(["str",/^(?:'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$)|`(?:[^\\`]|\\[\S\s])*(?:`|$))/,
+q,"'\"`"]):m.push(["str",/^(?:'(?:[^\n\r'\\]|\\.)*(?:'|$)|"(?:[^\n\r"\\]|\\.)*(?:"|$))/,q,"\"'"]);a.verbatimStrings&&e.push(["str",/^@"(?:[^"]|"")*(?:"|$)/,q]);var h=a.hashComments;h&&(a.cStyleComments?(h>1?m.push(["com",/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,q,"#"]):m.push(["com",/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\n\r]*)/,q,"#"]),e.push(["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,q])):m.push(["com",/^#[^\n\r]*/,
+q,"#"]));a.cStyleComments&&(e.push(["com",/^\/\/[^\n\r]*/,q]),e.push(["com",/^\/\*[\S\s]*?(?:\*\/|$)/,q]));a.regexLiterals&&e.push(["lang-regex",/^(?:^^\.?|[!+-]|!=|!==|#|%|%=|&|&&|&&=|&=|\(|\*|\*=|\+=|,|-=|->|\/|\/=|:|::|;|<|<<|<<=|<=|=|==|===|>|>=|>>|>>=|>>>|>>>=|[?@[^]|\^=|\^\^|\^\^=|{|\||\|=|\|\||\|\|=|~|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\s*(\/(?=[^*/])(?:[^/[\\]|\\[\S\s]|\[(?:[^\\\]]|\\[\S\s])*(?:]|$))+\/)/]);(h=a.types)&&e.push(["typ",h]);a=(""+a.keywords).replace(/^ | $/g,
+"");a.length&&e.push(["kwd",RegExp("^(?:"+a.replace(/[\s,]+/g,"|")+")\\b"),q]);m.push(["pln",/^\s+/,q," \r\n\t\xa0"]);e.push(["lit",/^@[$_a-z][\w$@]*/i,q],["typ",/^(?:[@_]?[A-Z]+[a-z][\w$@]*|\w+_t\b)/,q],["pln",/^[$_a-z][\w$@]*/i,q],["lit",/^(?:0x[\da-f]+|(?:\d(?:_\d+)*\d*(?:\.\d*)?|\.\d\+)(?:e[+-]?\d+)?)[a-z]*/i,q,"0123456789"],["pln",/^\\[\S\s]?/,q],["pun",/^.[^\s\w"-$'./@\\`]*/,q]);return x(m,e)}function D(a,m){function e(a){switch(a.nodeType){case 1:if(k.test(a.className))break;if("BR"===a.nodeName)h(a),
+a.parentNode&&a.parentNode.removeChild(a);else for(a=a.firstChild;a;a=a.nextSibling)e(a);break;case 3:case 4:if(p){var b=a.nodeValue,d=b.match(t);if(d){var c=b.substring(0,d.index);a.nodeValue=c;(b=b.substring(d.index+d[0].length))&&a.parentNode.insertBefore(s.createTextNode(b),a.nextSibling);h(a);c||a.parentNode.removeChild(a)}}}}function h(a){function b(a,d){var e=d?a.cloneNode(!1):a,f=a.parentNode;if(f){var f=b(f,1),g=a.nextSibling;f.appendChild(e);for(var h=g;h;h=g)g=h.nextSibling,f.appendChild(h)}return e}
+for(;!a.nextSibling;)if(a=a.parentNode,!a)return;for(var a=b(a.nextSibling,0),e;(e=a.parentNode)&&e.nodeType===1;)a=e;d.push(a)}var k=/(?:^|\s)nocode(?:\s|$)/,t=/\r\n?|\n/,s=a.ownerDocument,l;a.currentStyle?l=a.currentStyle.whiteSpace:window.getComputedStyle&&(l=s.defaultView.getComputedStyle(a,q).getPropertyValue("white-space"));var p=l&&"pre"===l.substring(0,3);for(l=s.createElement("LI");a.firstChild;)l.appendChild(a.firstChild);for(var d=[l],g=0;g=0;){var h=m[e];A.hasOwnProperty(h)?window.console&&console.warn("cannot override language handler %s",h):A[h]=a}}function C(a,m){if(!a||!A.hasOwnProperty(a))a=/^\s*=o&&(h+=2);e>=c&&(a+=2)}}catch(w){"console"in window&&console.log(w&&w.stack?w.stack:w)}}var v=["break,continue,do,else,for,if,return,while"],w=[[v,"auto,case,char,const,default,double,enum,extern,float,goto,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"],
+"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"],F=[w,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,dynamic_cast,explicit,export,friend,inline,late_check,mutable,namespace,nullptr,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"],G=[w,"abstract,boolean,byte,extends,final,finally,implements,import,instanceof,null,native,package,strictfp,super,synchronized,throws,transient"],
+H=[G,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,interface,internal,into,is,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var"],w=[w,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"],I=[v,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"],
+J=[v,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"],v=[v,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"],K=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)/,N=/\S/,O=u({keywords:[F,H,w,"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END"+
+I,J,v],hashComments:!0,cStyleComments:!0,multiLineStrings:!0,regexLiterals:!0}),A={};k(O,["default-code"]);k(x([],[["pln",/^[^]*(?:>|$)/],["com",/^<\!--[\S\s]*?(?:--\>|$)/],["lang-",/^<\?([\S\s]+?)(?:\?>|$)/],["lang-",/^<%([\S\s]+?)(?:%>|$)/],["pun",/^(?:<[%?]|[%?]>)/],["lang-",/^]*>([\S\s]+?)<\/xmp\b[^>]*>/i],["lang-js",/^]*>([\S\s]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\S\s]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),
+["default-markup","htm","html","mxml","xhtml","xml","xsl"]);k(x([["pln",/^\s+/,q," \t\r\n"],["atv",/^(?:"[^"]*"?|'[^']*'?)/,q,"\"'"]],[["tag",/^^<\/?[a-z](?:[\w-.:]*\w)?|\/?>$/i],["atn",/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^\s"'>]*(?:[^\s"'/>]|\/(?=\s)))/],["pun",/^[/<->]+/],["lang-js",/^on\w+\s*=\s*"([^"]+)"/i],["lang-js",/^on\w+\s*=\s*'([^']+)'/i],["lang-js",/^on\w+\s*=\s*([^\s"'>]+)/i],["lang-css",/^style\s*=\s*"([^"]+)"/i],["lang-css",/^style\s*=\s*'([^']+)'/i],["lang-css",
+/^style\s*=\s*([^\s"'>]+)/i]]),["in.tag"]);k(x([],[["atv",/^[\S\s]+/]]),["uq.val"]);k(u({keywords:F,hashComments:!0,cStyleComments:!0,types:K}),["c","cc","cpp","cxx","cyc","m"]);k(u({keywords:"null,true,false"}),["json"]);k(u({keywords:H,hashComments:!0,cStyleComments:!0,verbatimStrings:!0,types:K}),["cs"]);k(u({keywords:G,cStyleComments:!0}),["java"]);k(u({keywords:v,hashComments:!0,multiLineStrings:!0}),["bsh","csh","sh"]);k(u({keywords:I,hashComments:!0,multiLineStrings:!0,tripleQuotedStrings:!0}),
+["cv","py"]);k(u({keywords:"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["perl","pl","pm"]);k(u({keywords:J,hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["rb"]);k(u({keywords:w,cStyleComments:!0,regexLiterals:!0}),["js"]);k(u({keywords:"all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,true,try,unless,until,when,while,yes",
+hashComments:3,cStyleComments:!0,multilineStrings:!0,tripleQuotedStrings:!0,regexLiterals:!0}),["coffee"]);k(x([],[["str",/^[\S\s]+/]]),["regex"]);window.prettyPrintOne=function(a,m,e){var h=document.createElement("PRE");h.innerHTML=a;e&&D(h,e);E({g:m,i:e,h:h});return h.innerHTML};window.prettyPrint=function(a){function m(){for(var e=window.PR_SHOULD_USE_CONTINUATION?l.now()+250:Infinity;p=0){var k=k.match(g),f,b;if(b=
+!k){b=n;for(var o=void 0,c=b.firstChild;c;c=c.nextSibling)var i=c.nodeType,o=i===1?o?b:c:i===3?N.test(c.nodeValue)?b:o:o;b=(f=o===b?void 0:o)&&"CODE"===f.tagName}b&&(k=f.className.match(g));k&&(k=k[1]);b=!1;for(o=n.parentNode;o;o=o.parentNode)if((o.tagName==="pre"||o.tagName==="code"||o.tagName==="xmp")&&o.className&&o.className.indexOf("prettyprint")>=0){b=!0;break}b||((b=(b=n.className.match(/\blinenums\b(?::(\d+))?/))?b[1]&&b[1].length?+b[1]:!0:!1)&&D(n,b),d={g:k,h:n,i:b},E(d))}}p

Soufflé chocolate cake powder. Applicake lollipop oat cake gingerbread.

'), + fixedWidth: 300, + position: 'right' + }); + $('#demo-theme').tooltipster({ + animation: 'grow', + theme: 'tooltipster-pink' + }); + $('#demo-callback').tooltipster({ + content: 'Loading...', + updateAnimation: false, + functionBefore: function(origin, continueTooltip) { + continueTooltip(); + + if (origin.data('ajax') !== 'cached') { + + $.jGFeed('http://ws.audioscrobbler.com/2.0/user/ce3ge/recenttracks.rss?', + function(feeds){ + var content = ''; + if(!feeds){ + content = 'Woops - there was an error retrieving my last.fm RSS feed'; + origin.tooltipster('content', content); + } + else { + content = $('I last listened to: ' + feeds.entries[0].title + ''); + origin + .tooltipster('content', content) + .data('ajax', 'cached'); + } + }, 10); + + origin.data('ajax', 'cached'); + } + }, + functionAfter: function(origin) { + alert('The tooltip has closed!'); + } + }); + $('#demo-events').tooltipster({ + trigger: 'click' + }); + $(window).keypress(function() { + $('#demo-events').tooltipster('hide'); + }); + $('#demo-interact').tooltipster({ + contentAsHTML: true, + interactive: true + }); + $('#demo-touch').tooltipster({ + touchDevices: false + }); + $('#demo-icon').tooltipster({ + iconDesktop: true, + iconTouch: true + }); + $('#demo-multiple').tooltipster({ + animation: 'swing', + content: 'North', + multiple: true, + position: 'top' + }); + $('#demo-multiple').tooltipster({ + content: 'East', + multiple: true, + position: 'right', + theme: 'tooltipster-punk' + }); + $('#demo-multiple').tooltipster({ + animation: 'grow', + content: 'South', + delay: 200, + multiple: true, + position: 'bottom', + theme: 'tooltipster-light' + }); + $('#demo-multiple').tooltipster({ + animation: 'fall', + content: 'West', + multiple: true, + position: 'left', + theme: 'tooltipster-shadow' + }); + $('.tooltipster-light-preview').tooltipster({ + theme: 'tooltipster-light' + }); + $('.tooltipster-punk-preview').tooltipster({ + theme: 'tooltipster-punk' + }); + $('.tooltipster-noir-preview').tooltipster({ + theme: 'tooltipster-noir' + }); + $('.tooltipster-shadow-preview').tooltipster({ + theme: 'tooltipster-shadow' + }); + + $('header select').change(function() { + var goTo = $(this).val(); + var section = $('#'+goTo); + var offset = section.offset().top; + $('html, body').scrollTop(offset); + }); + + prettyPrint(); + + +}); \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/index.html b/sai/page/js/libs/tooltipster-master/index.html new file mode 100644 index 0000000..9a789df --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/index.html @@ -0,0 +1,664 @@ + + + + Tooltipster - The jQuery Tooltip Plugin + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+
+
+
+ +
+
+ + +
+
+ +
+
+ + +
+
+ Tooltipster +

A powerful, flexible jQuery plugin enabling you to easily create semantic, modern tooltips enhanced with the power of CSS.

+
    +
  • + Chrome +
  • +
  • + Safari +
  • +
  • + Opera +
  • +
  • + FireFox +
  • +
  • + Internet Explorer +
  • +
+ +
+ +
+

Demos

+
    +
  • + Hover Default settings +
  • +
  • + Hover Fixed width, position, & HTML +
  • +
  • + Click Custom show / hide triggers +
  • +
  • + Hover Disable touch devices +
  • +
  • + Hover Custom themes & animations +
  • +
  • + Hover Custom callbacks (AJAX <3) +
  • +
  • + Hover Interaction with tooltips +
  • +
  • + Attach tooltips to icons +
  • +
  • + Hover Multiple tooltips on a single element +
  • +
  • ...& more!
  • +
+
+ +
+

Getting Started

+

1. Load jQuery and include Tooltipster's plugin files

+

After you download Tooltipster, move tooltipster.css and jquery.tooltipster.min.js to your root's CSS and JavaScript directories. Next, load jQuery and include Tooltipster's CSS and JavaScript files inside of your tags:

+
+<head>
+...
+
+    <link rel="stylesheet" type="text/css" href="css/tooltipster.css" />
+
+    <script type="text/javascript" src="http://code.jquery.com/jquery-1.7.0.min.js"></script>
+    <script type="text/javascript" src="js/jquery.tooltipster.min.js"></script>
+
+...
+</head>
+
+

2. Set up your HTML

+

In order for Tooltipster to work, we first need to add the .tooltip class (or whatever class / means of selection you'd like to use) to whatever element we wish to have a tooltip. Next, we'll set the title attribute to whatever we'd like our tooltip to say. Here are a few examples:

+

Adding a tooltip to an image:

+
+<img src="my-image.png" class="tooltip" title="This is my image's tooltip message!" />
+

Adding a tooltip to a link that already has a class:

+
+<a href="http://calebjacob.com" class="ketchup tooltip" title="This is my link's tooltip message!">Link</a>
+

Adding a tooltip to a div:

+
+<div class="tooltip" title="This is my div's tooltip message!"> 
+    This div has a tooltip when you hover over it!
+</div>
+ +

3. Activate Tooltipster

+

The last thing we have to do is activate the plugin. To do this, add the following script right before your closing </head> tag (using whatever selector you'd like - in this case we're using the .tooltip class):

+
+<head>
+
+    ...
+
+    <script>
+        $(document).ready(function() {
+            $('.tooltip').tooltipster();
+        });
+    </script>
+</head>
+ +

4. Taking It a Step Further

+

Using HTML tags inside your tooltips

+

Tooltipster allows you to use any HTML markup you can think of inside your tooltips. This means you can insert things like images and text formatting tags. To achieve this, the recommended method is a little different : provide your content as a jQuery object in the script rather than in the title attribute :

+
+<head>
+
+    ...
+
+    <script>
+        $(document).ready(function() {
+            $('#my-tooltip').tooltipster({
+                content: $('<span><img src="my-image.png" /> <strong>This text is in bold case !</strong></span>')
+            });
+        });
+    </script>
+</head>
+<body>
+    
+    <div id="my-tooltip"> 
+        This div has a tooltip with HTML when you hover over it!
+    </div>
+	
+</body>
+ +

Another (less recommended) way of achieving this is to put encoded HTML markup directly in your title attribute and set the 'contentAsHTML' option to 'true'. In all cases, make sure you have tight control over the content you wish to display in the tooltip, as unwanted <script> or <iframe> tags for example would be a serious security issue for your website.

+ +
+<head>
+
+    ...
+
+    <script>
+        $(document).ready(function() {
+            $('.tooltip').tooltipster({
+                contentAsHTML: true
+            });
+        });
+    </script>
+</head>
+<body>
+    
+    <div class="tooltip" title="&lt;img src=&quot;my-image.png&quot; /&gt; &lt;strong&gt; This text is in bold case !&lt;/strong&gt;"> 
+        This div has a tooltip with HTML when you hover over it!
+    </div>
+	
+</body>
+ +

Customizing Your Tooltipster's Style

+

The style of your Tooltipsters can be easily changed by editing/overriding the default Tooltipster theme, located in the css/tooltipster.css file.

+

Tooltipster is also packaged with 4 alternative themes to choose from. They are demonstrated at the bottom of this page. To use a theme, just include its css file (located in the css/themes folder) in your page and specify its name in Tooltipster's settings :

+
+$('.tooltip').tooltipster({
+    theme: 'tooltipster-noir'
+});
+

And of course, you also have the option to create a brand new theme to suit your needs. To do this, start with the example below and add your flair. When you are done, include and specify your theme just like you would for one of Tooltipster's existing themes.

+
+/* This is how you would create a theme called "my-custom-theme": */
+
+.my-custom-theme {
+	border-radius: 5px; 
+	border: 2px solid #000;
+	background: #4c4c4c;
+	color: #fff;
+}
+/* Use this next selector to style things like font-size and line-height: */
+.my-custom-theme .tooltipster-content {
+	font-family: Arial, sans-serif;
+	font-size: 14px;
+	line-height: 16px;
+	padding: 8px 10px;
+}
+ +

Customizing Tooltipster's Functionality

+

Tooltipster's options gives you a wide range of variables to tweak your tooltip to your heart's content. To learn more about all of the options, read the Options section. Here's just a few of the things you can play with:

+
+$('.tooltip').tooltipster({
+   animation: 'fade',
+   delay: 200,
+   theme: 'tooltipster-default',
+   touchDevices: false,
+   trigger: 'hover'
+});
+
+ +
+

Options

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

animation

fade, grow, swing, slide, fallDetermines how the tooltip will animate in and out. Feel free to modify or create custom transitions in the tooltipster.css file. In IE9 and 8, all animations default to a JavaScript generated, fade animation. Default: 'fade'

arrow

booleanAdds the "speech bubble arrow" to the tooltip. Default: true

arrowColor

hex code / rgbSelect a specific color for the "speech bubble arrow". Default: will inherit the tooltip's background color

autoClose

booleanIf autoClose is set to false, the tooltip will never close unless you call the 'close' method yourself. Default: true

content

string, jQuery objectIf set, this will override the content of the tooltip. Default: null

contentAsHTML

booleanIf the content of the tooltip is provided as a string, it is displayed as plain text by default. If this content should actually be interpreted as HTML, set this option to true. Default: false

contentCloning

booleanIf you provide a jQuery object to the 'content' option, this sets if it is a clone of this object that should actually be used. Default: true

delay

integerDelay how long it takes (in milliseconds) for the tooltip to start animating in. Default: 200

minWidth

integerSet a minimum width for the tooltip. Default: 0 (auto width)

maxWidth

integerSet a maximum width for the tooltip. Default: null (no max width)

functionInit

functionCreate a custom function to be fired only once at instantiation. If the function returns a value, this value will become the content of the tooltip. See the advanced section to learn more. Default: function(origin, content) {}

functionBefore

functionCreate a custom function to be fired before the tooltip opens. This function may prevent or hold off the opening. See the advanced section to learn more. Default: function(origin, continueTooltip) { continueTooltip(); }

functionReady

functionCreate a custom function to be fired when the tooltip and its contents have been added to the DOM. Default: function(origin, tooltip) {}

functionAfter

functionCreate a custom function to be fired once the tooltip has been closed and removed from the DOM. Default: function(origin) {}

icon

string, jQuery objectIf using the iconDesktop or iconTouch options, this sets the content for your icon. Default: '(?)'

iconCloning

booleanIf you provide a jQuery object to the 'icon' option, this sets if it is a clone of this object that should actually be used. Default: true

iconDesktop

booleanGenerate an icon next to your content that is responsible for activating the tooltip on non-touch devices. Default: false

iconTheme

CSS classIf using the iconDesktop or iconTouch options, this sets the class on the icon (used to style the icon). Default: 'tooltipster-icon'

iconTouch

booleanGenerate an icon next to your content that is responsible for activating the tooltip on touch devices (tablets, phones, etc). Default: false

interactive

booleanGive users the possibility to interact with the tooltip. Unless autoClose is set to false, the tooltip will still close if the user moves away from or clicks out of the tooltip. Default: false

interactiveTolerance

integerIf the tooltip is interactive and activated by a hover event, set the amount of time (milliseconds) allowed for a user to hover off of the tooltip activator (origin) on to the tooltip itself - keeping the tooltip from closing. Default: 350

multiple

booleanAllows you to put multiple tooltips on a single element. Read further instructions down this page. Default: false

offsetX

integerOffsets the tooltip (in pixels) farther left/right from the origin. Default: 0

offsetY

integerOffsets the tooltip (in pixels) farther up/down from the origin. Default: 0

onlyOne

booleanIf true, only one tooltip will be allowed to be active at a time. Non-autoclosing tooltips will not be closed though. Default: false

position

right, left, top, top-right, top-left, bottom, bottom-right, bottom-leftSet the position of the tooltip. Default: 'top'

positionTracker

booleanWill reposition the tooltip if the origin moves. As this option may have an impact on performance, we suggest you enable it only if you need to. Default: false

speed

integerSet the speed of the animation. Default: 350

timer

integerHow long the tooltip should be allowed to live before closing. Default: 0 (disabled)

theme

CSS classSet the theme used for your tooltip. Default: 'tooltipster-default'

touchDevices

booleanIf set to false, tooltips will not show on pure-touch devices, unless you open them yourself with the 'show' method. Touch gestures on devices which also have a mouse will still open the tooltips though. Default: true

trigger

hover, click, customSet how tooltips should be activated and closed. See the advanced section to learn how to build custom triggers. Default: 'hover'

updateAnimation

booleanIf a tooltip is open while its content is updated, play a subtle animation when the content changes. Default: true
+
+ +
+

Advanced

+ + +

The awesomesauce Tooltipster API

+

The Tooltipster API was created to be as flexible and easy to use as possible (thanks to glebtv for the inspiration). The API allows you to create custom triggers, update tooltip content on the fly (whether the tooltip is currently open or not), destroy Tooltipster functionality if needed, and reposition tooltips for unique use cases.

+

Here is a quick look at all of the API methods:

+
+// set default options for all future tooltip instantiations
+$.fn.tooltipster('setDefaults', {
+  position: 'bottom'
+});
+
+// show a tooltip (the 'callback' argument is optional)
+$(...).tooltipster('show', callback);
+
+// hide a tooltip (the 'callback' argument is optional)
+$(...).tooltipster('hide', callback);
+
+// temporarily disable a tooltip from being able to open
+$(...).tooltipster('disable');
+
+// if a tooltip was disabled from opening, reenable its previous functionality
+$(...).tooltipster('enable');
+
+// hide and destroy tooltip functionality
+$(...).tooltipster('destroy');
+
+// return a tooltip's current content (if selector contains multiple origins, only the value of the first will be returned)
+$(...).tooltipster('content');
+
+// update tooltip content
+$(...).tooltipster('content', myNewContent);
+
+// reposition and resize the tooltip
+$(...).tooltipster('reposition');
+
+// return the HTML root element of the tooltip
+$(...).tooltipster('elementTooltip');
+
+// return the HTML root element of the icon if there is one, 'undefined' otherwise
+$(...).tooltipster('elementIcon');
+ + +

Using AJAX to generate your tooltip content

+

Tooltipster gives you the ability to fire a custom synchronous or asynchronous function everytime before the tooltip launches (functionBefore) or just once upon instantiation (functionInit). One great use for this is to grab dynamic content for your tooltips via AJAX.

+

Here is an example of using functionBefore() asynchronously to replace a loading notification with our AJAX call. Once the content has been retrieved and updated, we'll take advantage of setting $.data() to keep our content cached for the next time the tooltip is opened:

+
+$('.tooltip').tooltipster({
+    content: 'Loading...',
+    functionBefore: function(origin, continueTooltip) {
+
+        // we'll make this function asynchronous and allow the tooltip to go ahead and show the loading notification while fetching our data
+        continueTooltip();
+        
+        // next, we want to check if our data has already been cached
+        if (origin.data('ajax') !== 'cached') {
+            $.ajax({
+                type: 'POST',
+                url: 'example.php',
+                success: function(data) {
+                    // update our tooltip content with our returned data and cache it
+                    origin.tooltipster('content', data).data('ajax', 'cached');
+                }
+            });
+        }
+    }
+});
+

However, maybe you just need to make one call and only need it to fire once instead of everytime the tooltip opens. This is where you could use functionInit(). This function will fire only once - right at the beginning of the instantiation process. You'll have the ability to do things like check the current content and set new content. Since the fancy API methods for returning and setting the value aren't instantiated yet, the way we go about this is a little different than functionBefore(): +

+$('.tooltip').tooltipster({
+    functionInit: function(origin, content) {
+		
+        if (content === 'This is bad content') {
+            
+            // when the request has finished loading, we will change the tooltip's content
+            $.ajax({
+                type: 'POST',
+                url: 'example.php',
+                success: function(data) {
+                    origin.tooltipster('content', 'New content has been loaded : ' + data);
+                }
+            });
+			
+            // this returned string will overwrite the content of the tooltip for the time being
+            return 'Wait while we load new content...';
+        }
+        else {
+            // return nothing : the initialization continues normally with its content unchanged.
+        }
+    }
+});
+ + +

Manually show and hide a tooltip

+

By default and according to the 'trigger' option, Tooltipster automatically shows tooltips upon users' mouse clicks or mouse hovering (or their touch-gesture equivalents). In addition to this, you may also manually open or close a tooltip at anytime with a simple javascript command.

+

To achieve this, Tooltipster has the 'show' and 'hide' methods. Both of them may receive an optional 'callback' parameter, which represents a function you'd like to call when the tooltip is done animating.

+

Here's an example of how you could launch a specific tooltip on page load and close it when any key on your keyboard is pressed. This will still preserve the default hover trigger.

+
+<span class="tooltip" id="example" title="My tooltip content">Example</span>
+
+
+$(document).ready(function() {
+   
+   // first on page load, initiate the Tooltipster plugin
+   $('.tooltip').tooltipster();
+   
+   // then immediately show the tooltip
+   $('#example').tooltipster('show');
+   
+   // as soon as a key is pressed on the keyboard, hide the tooltip.
+   $(window).keypress(function() {
+      $('#example').tooltipster('hide');
+   });
+});
+
+

You may also provide a function as the callback parameter of the show/hide methods. The callback functions are called in the context of the tooltipstered element. If the tooltip is already in the state you are asking for (open/closed), the callback is executed immediately. Please note that if the show/hide action is somehow cancelled before it has completed its animation, the callback function will never be called.

+
+$(document).ready(function() {
+   
+   $('.tooltip').tooltipster();
+   
+   $('#example').tooltipster('show', function() {
+       alert('The tooltip is now fully open. The content is: ' + this.tooltipster('content'));
+   });
+   
+   $(window).keypress(function() {
+      $('#example').tooltipster('hide', function() {
+         alert('The tooltip is now fully closed');
+      });
+   });
+});
+
+ + +

Updating a tooltip's content

+

It's easy as pie to update a tooltip's content - whether it's open or closed. Depending on your selector, you can update multiple tooltips at once or just one:

+
+$('#my-special-element').tooltipster('content', 'My new content');
+

By default, Tooltipster will play a subtle animation when the content changes. To tweak the animation, check out the '.tooltipster-content-changing' class in your tooltipster.css file. It's important to note that only CSS transforms will be animated. To disable this animation, set updateAnimation to false.

+ + +

Using several tooltips on a single element

+

Several independant tooltips can be set on a single element, each one having its own triggers and options. Just set the 'multiple' option to true when you initialize your tooltip. This will only change two things that you might want to be aware of.

+

Firstly, the instantiation call will now return an array of Tooltipster objects generated by the call, instead of the tooltipped jQuery-wrapped elements.

+

Secondly, you will have to use the Tooltipster object of a tooltip to make any API method calls on it. All methods documented on this page remain available, only the way to call them changes.

+ +
+// create a first tooltip as usual. The multiple option is actually optional for the first tooltip
+$('#my-element').tooltipster({
+	content: 'My first tooltip',
+	position: 'top'
+});
+
+// instantiate a second tooltip and keep the returned Tooltipster objects array for later use of the API
+var tooltipsterObjects = $('#my-element').tooltipster({
+	// don't forget to provide content here as the 1st tooltip will have deleted the original title attribute of the element
+	content: 'My second tooltip',
+	multiple: true,
+	position: 'bottom'
+});
+
+// since the jQuery selector matches only one element, the array will contain only one Tooltipster object.
+// Otherwise the array would contain one object for each matched element, in the same order as them
+var tooltip2 = tooltipsterObjects[0];
+
+// use this Tooltipster object to make any API method call on the tooltip
+tooltip2.content('New content for my second tooltip').show();
+// all documented methods can be called that way
+var element = tooltip2.elementTooltip();
+
+// calling the API methods in the usual way only affects the first tooltip that was created on the element
+$('#my-element').tooltipster('content', 'New content for my first tooltip')
+
+ +
+// You may use the 'multiple' option on the first tooltip as well, it will return an array of objects too
+var tooltipsterObjects = $('#my-element').tooltipster({
+	content: 'My first tooltip',
+	multiple: true
+});
+
+// this is also a way to call API methods on the first tooltip
+var tooltip1 = tooltipsterObjects[0];
+tooltip1.content('New content for my first tooltip').show();
+ +

Note : if you have multiple tooltips and destroy them, only the last destroyed tooltip will transfer its content back to the title attribute of the tooltipped element.

+ +

Community submitted use cases

+

Using Tooltipster alongside jQuery Validate by sparky672

+

Did you do something awesome with Tooltipster? Tell me and I'll post it up here!

+
+ +
+

Themes

+

Tired of the same old? Four other rocking themes are available for your tooltips, and you can always create yours ! Share them with us on GitHub !

+
+ Default + Light + Punk + Noir + Shadow +
+
+ +
+

Talk

+

Share thoughts, questions, & bugs!

+

Head on over to Tooltipster's issue tracker on GitHub: https://github.com/iamceege/tooltipster/issues

+

Before opening a new issue, please be sure to search through the backlog to see if your question or bug has been / is being resolved. Thank you! :)

+
+ + +
+ +
+ + + + diff --git a/sai/page/js/libs/tooltipster-master/js/jquery.tooltipster.js b/sai/page/js/libs/tooltipster-master/js/jquery.tooltipster.js new file mode 100644 index 0000000..0a68403 --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/js/jquery.tooltipster.js @@ -0,0 +1,1276 @@ +/* + +Tooltipster 3.2.4 | 2014-05-14 +A rockin' custom tooltip jQuery plugin + +Developed by Caleb Jacob under the MIT license http://opensource.org/licenses/MIT + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +*/ + +;(function ($, window, document) { + + var pluginName = "tooltipster", + defaults = { + animation: 'fade', + arrow: true, + arrowColor: '', + autoClose: true, + content: null, + contentAsHTML: false, + contentCloning: true, + delay: 200, + minWidth: 0, + maxWidth: null, + functionInit: function(origin, content) {}, + functionBefore: function(origin, continueTooltip) { + continueTooltip(); + }, + functionReady: function(origin, tooltip) {}, + functionAfter: function(origin) {}, + icon: '(?)', + iconCloning: true, + iconDesktop: false, + iconTouch: false, + iconTheme: 'tooltipster-icon', + interactive: false, + interactiveTolerance: 350, + multiple: false, + offsetX: 0, + offsetY: 0, + onlyOne: false, + position: 'top', + positionTracker: false, + speed: 350, + timer: 0, + theme: 'tooltipster-default', + touchDevices: true, + trigger: 'hover', + updateAnimation: true + }; + + function Plugin(element, options) { + + // list of instance variables + + this.bodyOverflowX; + // stack of custom callbacks provided as parameters to API methods + this.callbacks = { + hide: [], + show: [] + }; + this.checkInterval = null; + // this will be the user content shown in the tooltip. A capital "C" is used because there is also a method called content() + this.Content; + // this is the original element which is being applied the tooltipster plugin + this.$el = $(element); + // this will be the element which triggers the appearance of the tooltip on hover/click/custom events. + // it will be the same as this.$el if icons are not used (see in the options), otherwise it will correspond to the created icon + this.$elProxy; + this.elProxyPosition; + this.enabled = true; + this.options = $.extend({}, defaults, options); + this.mouseIsOverProxy = false; + // a unique namespace per instance, for easy selective unbinding + this.namespace = 'tooltipster-'+ Math.round(Math.random()*100000); + // Status (capital S) can be either : appearing, shown, disappearing, hidden + this.Status = 'hidden'; + this.timerHide = null; + this.timerShow = null; + // this will be the tooltip element (jQuery wrapped HTML element) + this.$tooltip; + + // for backward compatibility + this.options.iconTheme = this.options.iconTheme.replace('.', ''); + this.options.theme = this.options.theme.replace('.', ''); + + // launch + + this._init(); + } + + Plugin.prototype = { + + _init: function() { + + var self = this; + + // disable the plugin on old browsers (including IE7 and lower) + if (document.querySelector) { + + // note : the content is null (empty) by default and can stay that way if the plugin remains initialized but not fed any content. The tooltip will just not appear. + + // if content is provided in the options, its has precedence over the title attribute. Remark : an empty string is considered content, only 'null' represents the absence of content. + if (self.options.content !== null){ + self._content_set(self.options.content); + } + else { + // the same remark as above applies : empty strings (like title="") are considered content and will be shown. Do not define any attribute at all if you want to initialize the plugin without content at start. + var t = self.$el.attr('title'); + if(typeof t === 'undefined') t = null; + + self._content_set(t); + } + + var c = self.options.functionInit.call(self.$el, self.$el, self.Content); + if(typeof c !== 'undefined') self._content_set(c); + + self.$el + // strip the title off of the element to prevent the default tooltips from popping up + .removeAttr('title') + // to be able to find all instances on the page later (upon window events in particular) + .addClass('tooltipstered'); + + // detect if we're changing the tooltip origin to an icon + // note about this condition : if the device has touch capability and self.options.iconTouch is false, you'll have no icons event though you may consider your device as a desktop if it also has a mouse. Not sure why someone would have this use case though. + if ((!deviceHasTouchCapability && self.options.iconDesktop) || (deviceHasTouchCapability && self.options.iconTouch)) { + + // TODO : the tooltip should be automatically be given an absolute position to be near the origin. Otherwise, when the origin is floating or what, it's going to be nowhere near it and disturb the position flow of the page elements. It will imply that the icon also detects when its origin moves, to follow it : not trivial. + // Until it's done, the icon feature does not really make sense since the user still has most of the work to do by himself + + // if the icon provided is in the form of a string + if(typeof self.options.icon === 'string'){ + // wrap it in a span with the icon class + self.$elProxy = $(''); + self.$elProxy.text(self.options.icon); + } + // if it is an object (sensible choice) + else { + // (deep) clone the object if iconCloning == true, to make sure every instance has its own proxy. We use the icon without wrapping, no need to. We do not give it a class either, as the user will undoubtedly style the object on his own and since our css properties may conflict with his own + if (self.options.iconCloning) self.$elProxy = self.options.icon.clone(true); + else self.$elProxy = self.options.icon; + } + + self.$elProxy.insertAfter(self.$el); + } + else { + self.$elProxy = self.$el; + } + + // for 'click' and 'hover' triggers : bind on events to open the tooltip. Closing is now handled in _showNow() because of its bindings. + // Notes about touch events : + // - mouseenter, mouseleave and clicks happen even on pure touch devices because they are emulated. deviceIsPureTouch() is a simple attempt to detect them. + // - on hybrid devices, we do not prevent touch gesture from opening tooltips. It would be too complex to differentiate real mouse events from emulated ones. + // - we check deviceIsPureTouch() at each event rather than prior to binding because the situation may change during browsing + if (self.options.trigger == 'hover') { + + // these binding are for mouse interaction only + self.$elProxy + .on('mouseenter.'+ self.namespace, function() { + if (!deviceIsPureTouch() || self.options.touchDevices) { + self.mouseIsOverProxy = true; + self._show(); + } + }) + .on('mouseleave.'+ self.namespace, function() { + if (!deviceIsPureTouch() || self.options.touchDevices) { + self.mouseIsOverProxy = false; + } + }); + + // for touch interaction only + if (deviceHasTouchCapability && self.options.touchDevices) { + + // for touch devices, we immediately display the tooltip because we cannot rely on mouseleave to handle the delay + self.$elProxy.on('touchstart.'+ self.namespace, function() { + self._showNow(); + }); + } + } + else if (self.options.trigger == 'click') { + + // note : for touch devices, we do not bind on touchstart, we only rely on the emulated clicks (triggered by taps) + self.$elProxy.on('click.'+ self.namespace, function() { + if (!deviceIsPureTouch() || self.options.touchDevices) { + self._show(); + } + }); + } + } + }, + + // this function will schedule the opening of the tooltip after the delay, if there is one + _show: function() { + + var self = this; + + if (self.Status != 'shown' && self.Status != 'appearing') { + + if (self.options.delay) { + self.timerShow = setTimeout(function(){ + + // for hover trigger, we check if the mouse is still over the proxy, otherwise we do not show anything + if (self.options.trigger == 'click' || (self.options.trigger == 'hover' && self.mouseIsOverProxy)) { + self._showNow(); + } + }, self.options.delay); + } + else self._showNow(); + } + }, + + // this function will open the tooltip right away + _showNow: function(callback) { + + var self = this; + + // call our constructor custom function before continuing + self.options.functionBefore.call(self.$el, self.$el, function() { + + // continue only if the tooltip is enabled and has any content + if (self.enabled && self.Content !== null) { + + // save the method callback and cancel hide method callbacks + if (callback) self.callbacks.show.push(callback); + self.callbacks.hide = []; + + //get rid of any appearance timer + clearTimeout(self.timerShow); + self.timerShow = null; + clearTimeout(self.timerHide); + self.timerHide = null; + + // if we only want one tooltip open at a time, close all auto-closing tooltips currently open and not already disappearing + if (self.options.onlyOne) { + $('.tooltipstered').not(self.$el).each(function(i,el) { + + var $el = $(el), + nss = $el.data('tooltipster-ns'); + + // iterate on all tooltips of the element + $.each(nss, function(i, ns){ + var instance = $el.data(ns), + // we have to use the public methods here + s = instance.status(), + ac = instance.option('autoClose'); + + if (s !== 'hidden' && s !== 'disappearing' && ac) { + instance.hide(); + } + }); + }); + } + + var finish = function() { + self.Status = 'shown'; + + // trigger any show method custom callbacks and reset them + $.each(self.callbacks.show, function(i,c) { c.call(self.$el); }); + self.callbacks.show = []; + }; + + // if this origin already has its tooltip open + if (self.Status !== 'hidden') { + + // the timer (if any) will start (or restart) right now + var extraTime = 0; + + // if it was disappearing, cancel that + if (self.Status === 'disappearing') { + + self.Status = 'appearing'; + + if (supportsTransitions()) { + + self.$tooltip + .clearQueue() + .removeClass('tooltipster-dying') + .addClass('tooltipster-'+ self.options.animation +'-show'); + + if (self.options.speed > 0) self.$tooltip.delay(self.options.speed); + + self.$tooltip.queue(finish); + } + else { + // in case the tooltip was currently fading out, bring it back to life + self.$tooltip + .stop() + .fadeIn(finish); + } + } + // if the tooltip is already open, we still need to trigger the method custom callback + else if(self.Status === 'shown') { + finish(); + } + } + // if the tooltip isn't already open, open that sucker up! + else { + + self.Status = 'appearing'; + + // the timer (if any) will start when the tooltip has fully appeared after its transition + var extraTime = self.options.speed; + + // disable horizontal scrollbar to keep overflowing tooltips from jacking with it and then restore it to its previous value + self.bodyOverflowX = $('body').css('overflow-x'); + $('body').css('overflow-x', 'hidden'); + + // get some other settings related to building the tooltip + var animation = 'tooltipster-' + self.options.animation, + animationSpeed = '-webkit-transition-duration: '+ self.options.speed +'ms; -webkit-animation-duration: '+ self.options.speed +'ms; -moz-transition-duration: '+ self.options.speed +'ms; -moz-animation-duration: '+ self.options.speed +'ms; -o-transition-duration: '+ self.options.speed +'ms; -o-animation-duration: '+ self.options.speed +'ms; -ms-transition-duration: '+ self.options.speed +'ms; -ms-animation-duration: '+ self.options.speed +'ms; transition-duration: '+ self.options.speed +'ms; animation-duration: '+ self.options.speed +'ms;', + minWidth = self.options.minWidth ? 'min-width:'+ Math.round(self.options.minWidth) +'px;' : '', + maxWidth = self.options.maxWidth ? 'max-width:'+ Math.round(self.options.maxWidth) +'px;' : '', + pointerEvents = self.options.interactive ? 'pointer-events: auto;' : ''; + + // build the base of our tooltip + self.$tooltip = $('
'); + + // only add the animation class if the user has a browser that supports animations + if (supportsTransitions()) self.$tooltip.addClass(animation); + + // insert the content + self._content_insert(); + + // attach + self.$tooltip.appendTo('body'); + + // do all the crazy calculations and positioning + self.reposition(); + + // call our custom callback since the content of the tooltip is now part of the DOM + self.options.functionReady.call(self.$el, self.$el, self.$tooltip); + + // animate in the tooltip + if (supportsTransitions()) { + + self.$tooltip.addClass(animation + '-show'); + + if(self.options.speed > 0) self.$tooltip.delay(self.options.speed); + + self.$tooltip.queue(finish); + } + else { + self.$tooltip.css('display', 'none').fadeIn(self.options.speed, finish); + } + + // will check if our tooltip origin is removed while the tooltip is shown + self._interval_set(); + + // reposition on scroll (otherwise position:fixed element's tooltips will move away form their origin) and on resize (in case position can/has to be changed) + $(window).on('scroll.'+ self.namespace +' resize.'+ self.namespace, function() { + self.reposition(); + }); + + // auto-close bindings + if (self.options.autoClose) { + + // in case a listener is already bound for autoclosing (mouse or touch, hover or click), unbind it first + $('body').off('.'+ self.namespace); + + // here we'll have to set different sets of bindings for both touch and mouse + if (self.options.trigger == 'hover') { + + // if the user touches the body, hide + if (deviceHasTouchCapability) { + // timeout 0 : explanation below in click section + setTimeout(function() { + // we don't want to bind on click here because the initial touchstart event has not yet triggered its click event, which is thus about to happen + $('body').on('touchstart.'+ self.namespace, function() { + self.hide(); + }); + }, 0); + } + + // if we have to allow interaction + if (self.options.interactive) { + + // touch events inside the tooltip must not close it + if (deviceHasTouchCapability) { + self.$tooltip.on('touchstart.'+ self.namespace, function(event) { + event.stopPropagation(); + }); + } + + // as for mouse interaction, we get rid of the tooltip only after the mouse has spent some time out of it + var tolerance = null; + + self.$elProxy.add(self.$tooltip) + // hide after some time out of the proxy and the tooltip + .on('mouseleave.'+ self.namespace + '-autoClose', function() { + clearTimeout(tolerance); + tolerance = setTimeout(function(){ + self.hide(); + }, self.options.interactiveTolerance); + }) + // suspend timeout when the mouse is over the proxy or the tooltip + .on('mouseenter.'+ self.namespace + '-autoClose', function() { + clearTimeout(tolerance); + }); + } + // if this is a non-interactive tooltip, get rid of it if the mouse leaves + else { + self.$elProxy.on('mouseleave.'+ self.namespace + '-autoClose', function() { + self.hide(); + }); + } + } + // here we'll set the same bindings for both clicks and touch on the body to hide the tooltip + else if(self.options.trigger == 'click'){ + + // use a timeout to prevent immediate closing if the method was called on a click event and if options.delay == 0 (because of bubbling) + setTimeout(function() { + $('body').on('click.'+ self.namespace +' touchstart.'+ self.namespace, function() { + self.hide(); + }); + }, 0); + + // if interactive, we'll stop the events that were emitted from inside the tooltip to stop autoClosing + if (self.options.interactive) { + + // note : the touch events will just not be used if the plugin is not enabled on touch devices + self.$tooltip.on('click.'+ self.namespace +' touchstart.'+ self.namespace, function(event) { + event.stopPropagation(); + }); + } + } + } + } + + // if we have a timer set, let the countdown begin + if (self.options.timer > 0) { + + self.timerHide = setTimeout(function() { + self.timerHide = null; + self.hide(); + }, self.options.timer + extraTime); + } + } + }); + }, + + _interval_set: function() { + + var self = this; + + self.checkInterval = setInterval(function() { + + // if the tooltip and/or its interval should be stopped + if ( + // if the origin has been removed + $('body').find(self.$el).length === 0 + // if the elProxy has been removed + || $('body').find(self.$elProxy).length === 0 + // if the tooltip has been closed + || self.Status == 'hidden' + // if the tooltip has somehow been removed + || $('body').find(self.$tooltip).length === 0 + ) { + // remove the tooltip if it's still here + if (self.Status == 'shown' || self.Status == 'appearing') self.hide(); + + // clear this interval as it is no longer necessary + self._interval_cancel(); + } + // if everything is alright + else { + // compare the former and current positions of the elProxy to reposition the tooltip if need be + if(self.options.positionTracker){ + + var p = self._repositionInfo(self.$elProxy), + identical = false; + + // compare size first (a change requires repositioning too) + if(areEqual(p.dimension, self.elProxyPosition.dimension)){ + + // for elements with a fixed position, we track the top and left properties (relative to window) + if(self.$elProxy.css('position') === 'fixed'){ + if(areEqual(p.position, self.elProxyPosition.position)) identical = true; + } + // otherwise, track total offset (relative to document) + else { + if(areEqual(p.offset, self.elProxyPosition.offset)) identical = true; + } + } + + if(!identical){ + self.reposition(); + } + } + } + }, 200); + }, + + _interval_cancel: function() { + clearInterval(this.checkInterval); + // clean delete + this.checkInterval = null; + }, + + _content_set: function(content) { + // clone if asked. Cloning the object makes sure that each instance has its own version of the content (in case a same object were provided for several instances) + // reminder : typeof null === object + if (typeof content === 'object' && content !== null && this.options.contentCloning) { + content = content.clone(true); + } + this.Content = content; + }, + + _content_insert: function() { + + var self = this, + $d = this.$tooltip.find('.tooltipster-content'); + + if (typeof self.Content === 'string' && !self.options.contentAsHTML) { + $d.text(self.Content); + } + else { + $d + .empty() + .append(self.Content); + } + }, + + _update: function(content) { + + var self = this; + + // change the content + self._content_set(content); + + if (self.Content !== null) { + + // update the tooltip if it is open + if (self.Status !== 'hidden') { + + // reset the content in the tooltip + self._content_insert(); + + // reposition and resize the tooltip + self.reposition(); + + // if we want to play a little animation showing the content changed + if (self.options.updateAnimation) { + + if (supportsTransitions()) { + + self.$tooltip.css({ + 'width': '', + '-webkit-transition': 'all ' + self.options.speed + 'ms, width 0ms, height 0ms, left 0ms, top 0ms', + '-moz-transition': 'all ' + self.options.speed + 'ms, width 0ms, height 0ms, left 0ms, top 0ms', + '-o-transition': 'all ' + self.options.speed + 'ms, width 0ms, height 0ms, left 0ms, top 0ms', + '-ms-transition': 'all ' + self.options.speed + 'ms, width 0ms, height 0ms, left 0ms, top 0ms', + 'transition': 'all ' + self.options.speed + 'ms, width 0ms, height 0ms, left 0ms, top 0ms' + }).addClass('tooltipster-content-changing'); + + // reset the CSS transitions and finish the change animation + setTimeout(function() { + + if(self.Status != 'hidden'){ + + self.$tooltip.removeClass('tooltipster-content-changing'); + + // after the changing animation has completed, reset the CSS transitions + setTimeout(function() { + + if(self.Status !== 'hidden'){ + self.$tooltip.css({ + '-webkit-transition': self.options.speed + 'ms', + '-moz-transition': self.options.speed + 'ms', + '-o-transition': self.options.speed + 'ms', + '-ms-transition': self.options.speed + 'ms', + 'transition': self.options.speed + 'ms' + }); + } + }, self.options.speed); + } + }, self.options.speed); + } + else { + self.$tooltip.fadeTo(self.options.speed, 0.5, function() { + if(self.Status != 'hidden'){ + self.$tooltip.fadeTo(self.options.speed, 1); + } + }); + } + } + } + } + else { + self.hide(); + } + }, + + _repositionInfo: function($el) { + return { + dimension: { + height: $el.outerHeight(false), + width: $el.outerWidth(false) + }, + offset: $el.offset(), + position: { + left: parseInt($el.css('left')), + top: parseInt($el.css('top')) + } + }; + }, + + hide: function(callback) { + + var self = this; + + // save the method custom callback and cancel any show method custom callbacks + if (callback) self.callbacks.hide.push(callback); + self.callbacks.show = []; + + // get rid of any appearance timeout + clearTimeout(self.timerShow); + self.timerShow = null; + clearTimeout(self.timerHide); + self.timerHide = null; + + var finishCallbacks = function() { + // trigger any hide method custom callbacks and reset them + $.each(self.callbacks.hide, function(i,c) { c.call(self.$el); }); + self.callbacks.hide = []; + }; + + // hide + if (self.Status == 'shown' || self.Status == 'appearing') { + + self.Status = 'disappearing'; + + var finish = function() { + + self.Status = 'hidden'; + + // detach our content object first, so the next jQuery's remove() call does not unbind its event handlers + if (typeof self.Content == 'object' && self.Content !== null) { + self.Content.detach(); + } + + self.$tooltip.remove(); + self.$tooltip = null; + + // unbind orientationchange, scroll and resize listeners + $(window).off('.'+ self.namespace); + + $('body') + // unbind any auto-closing click/touch listeners + .off('.'+ self.namespace) + .css('overflow-x', self.bodyOverflowX); + + // unbind any auto-closing click/touch listeners + $('body').off('.'+ self.namespace); + + // unbind any auto-closing hover listeners + self.$elProxy.off('.'+ self.namespace + '-autoClose'); + + // call our constructor custom callback function + self.options.functionAfter.call(self.$el, self.$el); + + // call our method custom callbacks functions + finishCallbacks(); + }; + + if (supportsTransitions()) { + + self.$tooltip + .clearQueue() + .removeClass('tooltipster-' + self.options.animation + '-show') + // for transitions only + .addClass('tooltipster-dying'); + + if(self.options.speed > 0) self.$tooltip.delay(self.options.speed); + + self.$tooltip.queue(finish); + } + else { + self.$tooltip + .stop() + .fadeOut(self.options.speed, finish); + } + } + // if the tooltip is already hidden, we still need to trigger the method custom callback + else if(self.Status == 'hidden') { + finishCallbacks(); + } + + return self; + }, + + // the public show() method is actually an alias for the private showNow() method + show: function(callback) { + this._showNow(callback); + return this; + }, + + // 'update' is deprecated in favor of 'content' but is kept for backward compatibility + update: function(c) { + return this.content(c); + }, + content: function(c) { + // getter method + if(typeof c === 'undefined'){ + return this.Content; + } + // setter method + else { + this._update(c); + return this; + } + }, + + reposition: function() { + + var self = this; + + // in case the tooltip has been removed from DOM manually + if ($('body').find(self.$tooltip).length !== 0) { + + // reset width + self.$tooltip.css('width', ''); + + // find variables to determine placement + self.elProxyPosition = self._repositionInfo(self.$elProxy); + var arrowReposition = null, + windowWidth = $(window).width(), + // shorthand + proxy = self.elProxyPosition, + tooltipWidth = self.$tooltip.outerWidth(false), + tooltipInnerWidth = self.$tooltip.innerWidth() + 1, // this +1 stops FireFox from sometimes forcing an additional text line + tooltipHeight = self.$tooltip.outerHeight(false); + + // if this is an tag inside a , all hell breaks loose. Recalculate all the measurements based on coordinates + if (self.$elProxy.is('area')) { + var areaShape = self.$elProxy.attr('shape'), + mapName = self.$elProxy.parent().attr('name'), + map = $('img[usemap="#'+ mapName +'"]'), + mapOffsetLeft = map.offset().left, + mapOffsetTop = map.offset().top, + areaMeasurements = self.$elProxy.attr('coords') !== undefined ? self.$elProxy.attr('coords').split(',') : undefined; + + if (areaShape == 'circle') { + var areaLeft = parseInt(areaMeasurements[0]), + areaTop = parseInt(areaMeasurements[1]), + areaWidth = parseInt(areaMeasurements[2]); + proxy.dimension.height = areaWidth * 2; + proxy.dimension.width = areaWidth * 2; + proxy.offset.top = mapOffsetTop + areaTop - areaWidth; + proxy.offset.left = mapOffsetLeft + areaLeft - areaWidth; + } + else if (areaShape == 'rect') { + var areaLeft = parseInt(areaMeasurements[0]), + areaTop = parseInt(areaMeasurements[1]), + areaRight = parseInt(areaMeasurements[2]), + areaBottom = parseInt(areaMeasurements[3]); + proxy.dimension.height = areaBottom - areaTop; + proxy.dimension.width = areaRight - areaLeft; + proxy.offset.top = mapOffsetTop + areaTop; + proxy.offset.left = mapOffsetLeft + areaLeft; + } + else if (areaShape == 'poly') { + var areaXs = [], + areaYs = [], + areaSmallestX = 0, + areaSmallestY = 0, + areaGreatestX = 0, + areaGreatestY = 0, + arrayAlternate = 'even'; + + for (var i = 0; i < areaMeasurements.length; i++) { + var areaNumber = parseInt(areaMeasurements[i]); + + if (arrayAlternate == 'even') { + if (areaNumber > areaGreatestX) { + areaGreatestX = areaNumber; + if (i === 0) { + areaSmallestX = areaGreatestX; + } + } + + if (areaNumber < areaSmallestX) { + areaSmallestX = areaNumber; + } + + arrayAlternate = 'odd'; + } + else { + if (areaNumber > areaGreatestY) { + areaGreatestY = areaNumber; + if (i == 1) { + areaSmallestY = areaGreatestY; + } + } + + if (areaNumber < areaSmallestY) { + areaSmallestY = areaNumber; + } + + arrayAlternate = 'even'; + } + } + + proxy.dimension.height = areaGreatestY - areaSmallestY; + proxy.dimension.width = areaGreatestX - areaSmallestX; + proxy.offset.top = mapOffsetTop + areaSmallestY; + proxy.offset.left = mapOffsetLeft + areaSmallestX; + } + else { + proxy.dimension.height = map.outerHeight(false); + proxy.dimension.width = map.outerWidth(false); + proxy.offset.top = mapOffsetTop; + proxy.offset.left = mapOffsetLeft; + } + } + + // our function and global vars for positioning our tooltip + var myLeft = 0, + myLeftMirror = 0, + myTop = 0, + offsetY = parseInt(self.options.offsetY), + offsetX = parseInt(self.options.offsetX), + // this is the arrow position that will eventually be used. It may differ from the position option if the tooltip cannot be displayed in this position + practicalPosition = self.options.position; + + // a function to detect if the tooltip is going off the screen horizontally. If so, reposition the crap out of it! + function dontGoOffScreenX() { + + var windowLeft = $(window).scrollLeft(); + + // if the tooltip goes off the left side of the screen, line it up with the left side of the window + if((myLeft - windowLeft) < 0) { + arrowReposition = myLeft - windowLeft; + myLeft = windowLeft; + } + + // if the tooltip goes off the right of the screen, line it up with the right side of the window + if (((myLeft + tooltipWidth) - windowLeft) > windowWidth) { + arrowReposition = myLeft - ((windowWidth + windowLeft) - tooltipWidth); + myLeft = (windowWidth + windowLeft) - tooltipWidth; + } + } + + // a function to detect if the tooltip is going off the screen vertically. If so, switch to the opposite! + function dontGoOffScreenY(switchTo, switchFrom) { + // if it goes off the top off the page + if(((proxy.offset.top - $(window).scrollTop() - tooltipHeight - offsetY - 12) < 0) && (switchFrom.indexOf('top') > -1)) { + practicalPosition = switchTo; + } + + // if it goes off the bottom of the page + if (((proxy.offset.top + proxy.dimension.height + tooltipHeight + 12 + offsetY) > ($(window).scrollTop() + $(window).height())) && (switchFrom.indexOf('bottom') > -1)) { + practicalPosition = switchTo; + myTop = (proxy.offset.top - tooltipHeight) - offsetY - 12; + } + } + + if(practicalPosition == 'top') { + var leftDifference = (proxy.offset.left + tooltipWidth) - (proxy.offset.left + proxy.dimension.width); + myLeft = (proxy.offset.left + offsetX) - (leftDifference / 2); + myTop = (proxy.offset.top - tooltipHeight) - offsetY - 12; + dontGoOffScreenX(); + dontGoOffScreenY('bottom', 'top'); + } + + if(practicalPosition == 'top-left') { + myLeft = proxy.offset.left + offsetX; + myTop = (proxy.offset.top - tooltipHeight) - offsetY - 12; + dontGoOffScreenX(); + dontGoOffScreenY('bottom-left', 'top-left'); + } + + if(practicalPosition == 'top-right') { + myLeft = (proxy.offset.left + proxy.dimension.width + offsetX) - tooltipWidth; + myTop = (proxy.offset.top - tooltipHeight) - offsetY - 12; + dontGoOffScreenX(); + dontGoOffScreenY('bottom-right', 'top-right'); + } + + if(practicalPosition == 'bottom') { + var leftDifference = (proxy.offset.left + tooltipWidth) - (proxy.offset.left + proxy.dimension.width); + myLeft = proxy.offset.left - (leftDifference / 2) + offsetX; + myTop = (proxy.offset.top + proxy.dimension.height) + offsetY + 12; + dontGoOffScreenX(); + dontGoOffScreenY('top', 'bottom'); + } + + if(practicalPosition == 'bottom-left') { + myLeft = proxy.offset.left + offsetX; + myTop = (proxy.offset.top + proxy.dimension.height) + offsetY + 12; + dontGoOffScreenX(); + dontGoOffScreenY('top-left', 'bottom-left'); + } + + if(practicalPosition == 'bottom-right') { + myLeft = (proxy.offset.left + proxy.dimension.width + offsetX) - tooltipWidth; + myTop = (proxy.offset.top + proxy.dimension.height) + offsetY + 12; + dontGoOffScreenX(); + dontGoOffScreenY('top-right', 'bottom-right'); + } + + if(practicalPosition == 'left') { + myLeft = proxy.offset.left - offsetX - tooltipWidth - 12; + myLeftMirror = proxy.offset.left + offsetX + proxy.dimension.width + 12; + var topDifference = (proxy.offset.top + tooltipHeight) - (proxy.offset.top + proxy.dimension.height); + myTop = proxy.offset.top - (topDifference / 2) - offsetY; + + // if the tooltip goes off boths sides of the page + if((myLeft < 0) && ((myLeftMirror + tooltipWidth) > windowWidth)) { + var borderWidth = parseFloat(self.$tooltip.css('border-width')) * 2, + newWidth = (tooltipWidth + myLeft) - borderWidth; + self.$tooltip.css('width', newWidth + 'px'); + + tooltipHeight = self.$tooltip.outerHeight(false); + myLeft = proxy.offset.left - offsetX - newWidth - 12 - borderWidth; + topDifference = (proxy.offset.top + tooltipHeight) - (proxy.offset.top + proxy.dimension.height); + myTop = proxy.offset.top - (topDifference / 2) - offsetY; + } + + // if it only goes off one side, flip it to the other side + else if(myLeft < 0) { + myLeft = proxy.offset.left + offsetX + proxy.dimension.width + 12; + arrowReposition = 'left'; + } + } + + if(practicalPosition == 'right') { + myLeft = proxy.offset.left + offsetX + proxy.dimension.width + 12; + myLeftMirror = proxy.offset.left - offsetX - tooltipWidth - 12; + var topDifference = (proxy.offset.top + tooltipHeight) - (proxy.offset.top + proxy.dimension.height); + myTop = proxy.offset.top - (topDifference / 2) - offsetY; + + // if the tooltip goes off boths sides of the page + if(((myLeft + tooltipWidth) > windowWidth) && (myLeftMirror < 0)) { + var borderWidth = parseFloat(self.$tooltip.css('border-width')) * 2, + newWidth = (windowWidth - myLeft) - borderWidth; + self.$tooltip.css('width', newWidth + 'px'); + + tooltipHeight = self.$tooltip.outerHeight(false); + topDifference = (proxy.offset.top + tooltipHeight) - (proxy.offset.top + proxy.dimension.height); + myTop = proxy.offset.top - (topDifference / 2) - offsetY; + } + + // if it only goes off one side, flip it to the other side + else if((myLeft + tooltipWidth) > windowWidth) { + myLeft = proxy.offset.left - offsetX - tooltipWidth - 12; + arrowReposition = 'right'; + } + } + + // if arrow is set true, style it and append it + if (self.options.arrow) { + + var arrowClass = 'tooltipster-arrow-' + practicalPosition; + + // set color of the arrow + if(self.options.arrowColor.length < 1) { + var arrowColor = self.$tooltip.css('background-color'); + } + else { + var arrowColor = self.options.arrowColor; + } + + // if the tooltip was going off the page and had to re-adjust, we need to update the arrow's position + if (!arrowReposition) { + arrowReposition = ''; + } + else if (arrowReposition == 'left') { + arrowClass = 'tooltipster-arrow-right'; + arrowReposition = ''; + } + else if (arrowReposition == 'right') { + arrowClass = 'tooltipster-arrow-left'; + arrowReposition = ''; + } + else { + arrowReposition = 'left:'+ Math.round(arrowReposition) +'px;'; + } + + // building the logic to create the border around the arrow of the tooltip + if ((practicalPosition == 'top') || (practicalPosition == 'top-left') || (practicalPosition == 'top-right')) { + var tooltipBorderWidth = parseFloat(self.$tooltip.css('border-bottom-width')), + tooltipBorderColor = self.$tooltip.css('border-bottom-color'); + } + else if ((practicalPosition == 'bottom') || (practicalPosition == 'bottom-left') || (practicalPosition == 'bottom-right')) { + var tooltipBorderWidth = parseFloat(self.$tooltip.css('border-top-width')), + tooltipBorderColor = self.$tooltip.css('border-top-color'); + } + else if (practicalPosition == 'left') { + var tooltipBorderWidth = parseFloat(self.$tooltip.css('border-right-width')), + tooltipBorderColor = self.$tooltip.css('border-right-color'); + } + else if (practicalPosition == 'right') { + var tooltipBorderWidth = parseFloat(self.$tooltip.css('border-left-width')), + tooltipBorderColor = self.$tooltip.css('border-left-color'); + } + else { + var tooltipBorderWidth = parseFloat(self.$tooltip.css('border-bottom-width')), + tooltipBorderColor = self.$tooltip.css('border-bottom-color'); + } + + if (tooltipBorderWidth > 1) { + tooltipBorderWidth++; + } + + var arrowBorder = ''; + if (tooltipBorderWidth !== 0) { + var arrowBorderSize = '', + arrowBorderColor = 'border-color: '+ tooltipBorderColor +';'; + if (arrowClass.indexOf('bottom') !== -1) { + arrowBorderSize = 'margin-top: -'+ Math.round(tooltipBorderWidth) +'px;'; + } + else if (arrowClass.indexOf('top') !== -1) { + arrowBorderSize = 'margin-bottom: -'+ Math.round(tooltipBorderWidth) +'px;'; + } + else if (arrowClass.indexOf('left') !== -1) { + arrowBorderSize = 'margin-right: -'+ Math.round(tooltipBorderWidth) +'px;'; + } + else if (arrowClass.indexOf('right') !== -1) { + arrowBorderSize = 'margin-left: -'+ Math.round(tooltipBorderWidth) +'px;'; + } + arrowBorder = ''; + } + + // if the arrow already exists, remove and replace it + self.$tooltip.find('.tooltipster-arrow').remove(); + + // build out the arrow and append it + var arrowConstruct = '
'+ arrowBorder +'
'; + self.$tooltip.append(arrowConstruct); + } + + // position the tooltip + self.$tooltip.css({'top': Math.round(myTop) + 'px', 'left': Math.round(myLeft) + 'px'}); + } + + return self; + }, + + enable: function() { + this.enabled = true; + return this; + }, + + disable: function() { + // hide first, in case the tooltip would not disappear on its own (autoClose false) + this.hide(); + this.enabled = false; + return this; + }, + + destroy: function() { + + var self = this; + + self.hide(); + + // remove the icon, if any + if(self.$el[0] !== self.$elProxy[0]) self.$elProxy.remove(); + + self.$el + .removeData(self.namespace) + .off('.'+ self.namespace); + + var ns = self.$el.data('tooltipster-ns'); + + // if there are no more tooltips on this element + if(ns.length === 1){ + + // old school technique when outerHTML is not supported + var stringifiedContent = (typeof self.Content === 'string') ? self.Content : $('
').append(self.Content).html(); + + self.$el + .removeClass('tooltipstered') + .attr('title', stringifiedContent) + .removeData(self.namespace) + .removeData('tooltipster-ns') + .off('.'+ self.namespace); + } + else { + // remove the instance namespace from the list of namespaces of tooltips present on the element + ns = $.grep(ns, function(el, i){ + return el !== self.namespace; + }); + self.$el.data('tooltipster-ns', ns); + } + + return self; + }, + + elementIcon: function() { + return (this.$el[0] !== this.$elProxy[0]) ? this.$elProxy[0] : undefined; + }, + + elementTooltip: function() { + return this.$tooltip ? this.$tooltip[0] : undefined; + }, + + // public methods but for internal use only + // getter if val is ommitted, setter otherwise + option: function(o, val) { + if (typeof val == 'undefined') return this.options[o]; + else { + this.options[o] = val; + return this; + } + }, + status: function() { + return this.Status; + } + }; + + $.fn[pluginName] = function () { + + // for using in closures + var args = arguments; + + // if we are not in the context of jQuery wrapped HTML element(s) : + // this happens when calling static methods in the form $.fn.tooltipster('methodName'), or when calling $(sel).tooltipster('methodName or options') where $(sel) does not match anything + if (this.length === 0) { + + // if the first argument is a method name + if (typeof args[0] === 'string') { + + var methodIsStatic = true; + + // list static methods here (usable by calling $.fn.tooltipster('methodName');) + switch (args[0]) { + + case 'setDefaults': + // change default options for all future instances + $.extend(defaults, args[1]); + break; + + default: + methodIsStatic = false; + break; + } + + // $.fn.tooltipster('methodName') calls will return true + if (methodIsStatic) return true; + // $(sel).tooltipster('methodName') calls will return the list of objects event though it's empty because chaining should work on empty lists + else return this; + } + // the first argument is undefined or an object of options : we are initalizing but there is no element matched by selector + else { + // still chainable : same as above + return this; + } + } + // this happens when calling $(sel).tooltipster('methodName or options') where $(sel) matches one or more elements + else { + + // method calls + if (typeof args[0] === 'string') { + + var v = '#*$~&'; + + this.each(function() { + + // retrieve the namepaces of the tooltip(s) that exist on that element. We will interact with the first tooltip only. + var ns = $(this).data('tooltipster-ns'), + // self represents the instance of the first tooltipster plugin associated to the current HTML object of the loop + self = ns ? $(this).data(ns[0]) : null; + + // if the current element holds a tooltipster instance + if(self){ + + if (typeof self[args[0]] === 'function') { + // note : args[1] and args[2] may not be defined + var resp = self[args[0]](args[1], args[2]); + } + else { + throw new Error('Unknown method .tooltipster("' + args[0] + '")'); + } + + // if the function returned anything other than the instance itself (which implies chaining) + if (resp !== self){ + v = resp; + // return false to stop .each iteration on the first element matched by the selector + return false; + } + } + else { + throw new Error('You called Tooltipster\'s "' + args[0] + '" method on an uninitialized element'); + } + }); + + return (v !== '#*$~&') ? v : this; + } + // first argument is undefined or an object : the tooltip is initializing + else { + + var instances = [], + // is there a defined value for the multiple option in the options object ? + multipleIsSet = args[0] && typeof args[0].multiple !== 'undefined', + // if the multople option is set to true, or if it's not defined but set to true in the defaults + multiple = (multipleIsSet && args[0].multiple) || (!multipleIsSet && defaults.multiple); + + // initialize a tooltipster instance for each element if it doesn't already have one or if the multiple option is set, and attach the object to it + this.each(function () { + + var go = false, + ns = $(this).data('tooltipster-ns'), + instance = null; + + if (!ns) { + go = true; + } + else { + if(multiple) go = true; + else console.log('Tooltipster: one or more tooltips are already attached to this element: ignoring. Use the "multiple" option to attach more tooltips.'); + } + + if(go) { + instance = new Plugin(this, args[0]); + + // save the reference of the new instance + if (!ns) ns = []; + ns.push(instance.namespace); + $(this).data('tooltipster-ns', ns) + + // save the instance itself + $(this).data(instance.namespace, instance); + } + + instances.push(instance); + }); + + if(multiple) return instances; + else return this; + } + } + }; + + // quick & dirty compare function (not bijective nor multidimensional) + function areEqual(a,b) { + var same = true; + $.each(a, function(i, el){ + if(typeof b[i] === 'undefined' || a[i] !== b[i]){ + same = false; + return false; + } + }); + return same; + } + + // detect if this device can trigger touch events + var deviceHasTouchCapability = !!('ontouchstart' in window); + + // we'll assume the device has no mouse until we detect any mouse movement + var deviceHasMouse = false; + $('body').one('mousemove', function() { + deviceHasMouse = true; + }); + + function deviceIsPureTouch() { + return (!deviceHasMouse && deviceHasTouchCapability); + } + + // detecting support for CSS transitions + function supportsTransitions() { + var b = document.body || document.documentElement, + s = b.style, + p = 'transition'; + + if(typeof s[p] == 'string') {return true; } + + v = ['Moz', 'Webkit', 'Khtml', 'O', 'ms'], + p = p.charAt(0).toUpperCase() + p.substr(1); + for(var i=0; i');t.$elProxy.text(t.options.icon)}else{if(t.options.iconCloning)t.$elProxy=t.options.icon.clone(true);else t.$elProxy=t.options.icon}t.$elProxy.insertAfter(t.$el)}else{t.$elProxy=t.$el}if(t.options.trigger=="hover"){t.$elProxy.on("mouseenter."+t.namespace,function(){if(!f()||t.options.touchDevices){t.mouseIsOverProxy=true;t._show()}}).on("mouseleave."+t.namespace,function(){if(!f()||t.options.touchDevices){t.mouseIsOverProxy=false}});if(u&&t.options.touchDevices){t.$elProxy.on("touchstart."+t.namespace,function(){t._showNow()})}}else if(t.options.trigger=="click"){t.$elProxy.on("click."+t.namespace,function(){if(!f()||t.options.touchDevices){t._show()}})}}},_show:function(){var e=this;if(e.Status!="shown"&&e.Status!="appearing"){if(e.options.delay){e.timerShow=setTimeout(function(){if(e.options.trigger=="click"||e.options.trigger=="hover"&&e.mouseIsOverProxy){e._showNow()}},e.options.delay)}else e._showNow()}},_showNow:function(n){var r=this;r.options.functionBefore.call(r.$el,r.$el,function(){if(r.enabled&&r.Content!==null){if(n)r.callbacks.show.push(n);r.callbacks.hide=[];clearTimeout(r.timerShow);r.timerShow=null;clearTimeout(r.timerHide);r.timerHide=null;if(r.options.onlyOne){e(".tooltipstered").not(r.$el).each(function(t,n){var r=e(n),i=r.data("tooltipster-ns");e.each(i,function(e,t){var n=r.data(t),i=n.status(),s=n.option("autoClose");if(i!=="hidden"&&i!=="disappearing"&&s){n.hide()}})})}var i=function(){r.Status="shown";e.each(r.callbacks.show,function(e,t){t.call(r.$el)});r.callbacks.show=[]};if(r.Status!=="hidden"){var s=0;if(r.Status==="disappearing"){r.Status="appearing";if(l()){r.$tooltip.clearQueue().removeClass("tooltipster-dying").addClass("tooltipster-"+r.options.animation+"-show");if(r.options.speed>0)r.$tooltip.delay(r.options.speed);r.$tooltip.queue(i)}else{r.$tooltip.stop().fadeIn(i)}}else if(r.Status==="shown"){i()}}else{r.Status="appearing";var s=r.options.speed;r.bodyOverflowX=e("body").css("overflow-x");e("body").css("overflow-x","hidden");var o="tooltipster-"+r.options.animation,a="-webkit-transition-duration: "+r.options.speed+"ms; -webkit-animation-duration: "+r.options.speed+"ms; -moz-transition-duration: "+r.options.speed+"ms; -moz-animation-duration: "+r.options.speed+"ms; -o-transition-duration: "+r.options.speed+"ms; -o-animation-duration: "+r.options.speed+"ms; -ms-transition-duration: "+r.options.speed+"ms; -ms-animation-duration: "+r.options.speed+"ms; transition-duration: "+r.options.speed+"ms; animation-duration: "+r.options.speed+"ms;",f=r.options.minWidth?"min-width:"+Math.round(r.options.minWidth)+"px;":"",c=r.options.maxWidth?"max-width:"+Math.round(r.options.maxWidth)+"px;":"",h=r.options.interactive?"pointer-events: auto;":"";r.$tooltip=e('
');if(l())r.$tooltip.addClass(o);r._content_insert();r.$tooltip.appendTo("body");r.reposition();r.options.functionReady.call(r.$el,r.$el,r.$tooltip);if(l()){r.$tooltip.addClass(o+"-show");if(r.options.speed>0)r.$tooltip.delay(r.options.speed);r.$tooltip.queue(i)}else{r.$tooltip.css("display","none").fadeIn(r.options.speed,i)}r._interval_set();e(t).on("scroll."+r.namespace+" resize."+r.namespace,function(){r.reposition()});if(r.options.autoClose){e("body").off("."+r.namespace);if(r.options.trigger=="hover"){if(u){setTimeout(function(){e("body").on("touchstart."+r.namespace,function(){r.hide()})},0)}if(r.options.interactive){if(u){r.$tooltip.on("touchstart."+r.namespace,function(e){e.stopPropagation()})}var p=null;r.$elProxy.add(r.$tooltip).on("mouseleave."+r.namespace+"-autoClose",function(){clearTimeout(p);p=setTimeout(function(){r.hide()},r.options.interactiveTolerance)}).on("mouseenter."+r.namespace+"-autoClose",function(){clearTimeout(p)})}else{r.$elProxy.on("mouseleave."+r.namespace+"-autoClose",function(){r.hide()})}}else if(r.options.trigger=="click"){setTimeout(function(){e("body").on("click."+r.namespace+" touchstart."+r.namespace,function(){r.hide()})},0);if(r.options.interactive){r.$tooltip.on("click."+r.namespace+" touchstart."+r.namespace,function(e){e.stopPropagation()})}}}}if(r.options.timer>0){r.timerHide=setTimeout(function(){r.timerHide=null;r.hide()},r.options.timer+s)}}})},_interval_set:function(){var t=this;t.checkInterval=setInterval(function(){if(e("body").find(t.$el).length===0||e("body").find(t.$elProxy).length===0||t.Status=="hidden"||e("body").find(t.$tooltip).length===0){if(t.Status=="shown"||t.Status=="appearing")t.hide();t._interval_cancel()}else{if(t.options.positionTracker){var n=t._repositionInfo(t.$elProxy),r=false;if(o(n.dimension,t.elProxyPosition.dimension)){if(t.$elProxy.css("position")==="fixed"){if(o(n.position,t.elProxyPosition.position))r=true}else{if(o(n.offset,t.elProxyPosition.offset))r=true}}if(!r){t.reposition()}}}},200)},_interval_cancel:function(){clearInterval(this.checkInterval);this.checkInterval=null},_content_set:function(e){if(typeof e==="object"&&e!==null&&this.options.contentCloning){e=e.clone(true)}this.Content=e},_content_insert:function(){var e=this,t=this.$tooltip.find(".tooltipster-content");if(typeof e.Content==="string"&&!e.options.contentAsHTML){t.text(e.Content)}else{t.empty().append(e.Content)}},_update:function(e){var t=this;t._content_set(e);if(t.Content!==null){if(t.Status!=="hidden"){t._content_insert();t.reposition();if(t.options.updateAnimation){if(l()){t.$tooltip.css({width:"","-webkit-transition":"all "+t.options.speed+"ms, width 0ms, height 0ms, left 0ms, top 0ms","-moz-transition":"all "+t.options.speed+"ms, width 0ms, height 0ms, left 0ms, top 0ms","-o-transition":"all "+t.options.speed+"ms, width 0ms, height 0ms, left 0ms, top 0ms","-ms-transition":"all "+t.options.speed+"ms, width 0ms, height 0ms, left 0ms, top 0ms",transition:"all "+t.options.speed+"ms, width 0ms, height 0ms, left 0ms, top 0ms"}).addClass("tooltipster-content-changing");setTimeout(function(){if(t.Status!="hidden"){t.$tooltip.removeClass("tooltipster-content-changing");setTimeout(function(){if(t.Status!=="hidden"){t.$tooltip.css({"-webkit-transition":t.options.speed+"ms","-moz-transition":t.options.speed+"ms","-o-transition":t.options.speed+"ms","-ms-transition":t.options.speed+"ms",transition:t.options.speed+"ms"})}},t.options.speed)}},t.options.speed)}else{t.$tooltip.fadeTo(t.options.speed,.5,function(){if(t.Status!="hidden"){t.$tooltip.fadeTo(t.options.speed,1)}})}}}}else{t.hide()}},_repositionInfo:function(e){return{dimension:{height:e.outerHeight(false),width:e.outerWidth(false)},offset:e.offset(),position:{left:parseInt(e.css("left")),top:parseInt(e.css("top"))}}},hide:function(n){var r=this;if(n)r.callbacks.hide.push(n);r.callbacks.show=[];clearTimeout(r.timerShow);r.timerShow=null;clearTimeout(r.timerHide);r.timerHide=null;var i=function(){e.each(r.callbacks.hide,function(e,t){t.call(r.$el)});r.callbacks.hide=[]};if(r.Status=="shown"||r.Status=="appearing"){r.Status="disappearing";var s=function(){r.Status="hidden";if(typeof r.Content=="object"&&r.Content!==null){r.Content.detach()}r.$tooltip.remove();r.$tooltip=null;e(t).off("."+r.namespace);e("body").off("."+r.namespace).css("overflow-x",r.bodyOverflowX);e("body").off("."+r.namespace);r.$elProxy.off("."+r.namespace+"-autoClose");r.options.functionAfter.call(r.$el,r.$el);i()};if(l()){r.$tooltip.clearQueue().removeClass("tooltipster-"+r.options.animation+"-show").addClass("tooltipster-dying");if(r.options.speed>0)r.$tooltip.delay(r.options.speed);r.$tooltip.queue(s)}else{r.$tooltip.stop().fadeOut(r.options.speed,s)}}else if(r.Status=="hidden"){i()}return r},show:function(e){this._showNow(e);return this},update:function(e){return this.content(e)},content:function(e){if(typeof e==="undefined"){return this.Content}else{this._update(e);return this}},reposition:function(){var n=this;if(e("body").find(n.$tooltip).length!==0){n.$tooltip.css("width","");n.elProxyPosition=n._repositionInfo(n.$elProxy);var r=null,i=e(t).width(),s=n.elProxyPosition,o=n.$tooltip.outerWidth(false),u=n.$tooltip.innerWidth()+1,a=n.$tooltip.outerHeight(false);if(n.$elProxy.is("area")){var f=n.$elProxy.attr("shape"),l=n.$elProxy.parent().attr("name"),c=e('img[usemap="#'+l+'"]'),h=c.offset().left,p=c.offset().top,d=n.$elProxy.attr("coords")!==undefined?n.$elProxy.attr("coords").split(","):undefined;if(f=="circle"){var v=parseInt(d[0]),m=parseInt(d[1]),g=parseInt(d[2]);s.dimension.height=g*2;s.dimension.width=g*2;s.offset.top=p+m-g;s.offset.left=h+v-g}else if(f=="rect"){var v=parseInt(d[0]),m=parseInt(d[1]),y=parseInt(d[2]),b=parseInt(d[3]);s.dimension.height=b-m;s.dimension.width=y-v;s.offset.top=p+m;s.offset.left=h+v}else if(f=="poly"){var w=[],E=[],S=0,x=0,T=0,N=0,C="even";for(var k=0;kT){T=L;if(k===0){S=T}}if(LN){N=L;if(k==1){x=N}}if(Li){r=A-(i+n-o);A=i+n-o}}function B(n,r){if(s.offset.top-e(t).scrollTop()-a-_-12<0&&r.indexOf("top")>-1){P=n}if(s.offset.top+s.dimension.height+a+12+_>e(t).scrollTop()+e(t).height()&&r.indexOf("bottom")>-1){P=n;M=s.offset.top-a-_-12}}if(P=="top"){var j=s.offset.left+o-(s.offset.left+s.dimension.width);A=s.offset.left+D-j/2;M=s.offset.top-a-_-12;H();B("bottom","top")}if(P=="top-left"){A=s.offset.left+D;M=s.offset.top-a-_-12;H();B("bottom-left","top-left")}if(P=="top-right"){A=s.offset.left+s.dimension.width+D-o;M=s.offset.top-a-_-12;H();B("bottom-right","top-right")}if(P=="bottom"){var j=s.offset.left+o-(s.offset.left+s.dimension.width);A=s.offset.left-j/2+D;M=s.offset.top+s.dimension.height+_+12;H();B("top","bottom")}if(P=="bottom-left"){A=s.offset.left+D;M=s.offset.top+s.dimension.height+_+12;H();B("top-left","bottom-left")}if(P=="bottom-right"){A=s.offset.left+s.dimension.width+D-o;M=s.offset.top+s.dimension.height+_+12;H();B("top-right","bottom-right")}if(P=="left"){A=s.offset.left-D-o-12;O=s.offset.left+D+s.dimension.width+12;var F=s.offset.top+a-(s.offset.top+s.dimension.height);M=s.offset.top-F/2-_;if(A<0&&O+o>i){var I=parseFloat(n.$tooltip.css("border-width"))*2,q=o+A-I;n.$tooltip.css("width",q+"px");a=n.$tooltip.outerHeight(false);A=s.offset.left-D-q-12-I;F=s.offset.top+a-(s.offset.top+s.dimension.height);M=s.offset.top-F/2-_}else if(A<0){A=s.offset.left+D+s.dimension.width+12;r="left"}}if(P=="right"){A=s.offset.left+D+s.dimension.width+12;O=s.offset.left-D-o-12;var F=s.offset.top+a-(s.offset.top+s.dimension.height);M=s.offset.top-F/2-_;if(A+o>i&&O<0){var I=parseFloat(n.$tooltip.css("border-width"))*2,q=i-A-I;n.$tooltip.css("width",q+"px");a=n.$tooltip.outerHeight(false);F=s.offset.top+a-(s.offset.top+s.dimension.height);M=s.offset.top-F/2-_}else if(A+o>i){A=s.offset.left-D-o-12;r="right"}}if(n.options.arrow){var R="tooltipster-arrow-"+P;if(n.options.arrowColor.length<1){var U=n.$tooltip.css("background-color")}else{var U=n.options.arrowColor}if(!r){r=""}else if(r=="left"){R="tooltipster-arrow-right";r=""}else if(r=="right"){R="tooltipster-arrow-left";r=""}else{r="left:"+Math.round(r)+"px;"}if(P=="top"||P=="top-left"||P=="top-right"){var z=parseFloat(n.$tooltip.css("border-bottom-width")),W=n.$tooltip.css("border-bottom-color")}else if(P=="bottom"||P=="bottom-left"||P=="bottom-right"){var z=parseFloat(n.$tooltip.css("border-top-width")),W=n.$tooltip.css("border-top-color")}else if(P=="left"){var z=parseFloat(n.$tooltip.css("border-right-width")),W=n.$tooltip.css("border-right-color")}else if(P=="right"){var z=parseFloat(n.$tooltip.css("border-left-width")),W=n.$tooltip.css("border-left-color")}else{var z=parseFloat(n.$tooltip.css("border-bottom-width")),W=n.$tooltip.css("border-bottom-color")}if(z>1){z++}var X="";if(z!==0){var V="",J="border-color: "+W+";";if(R.indexOf("bottom")!==-1){V="margin-top: -"+Math.round(z)+"px;"}else if(R.indexOf("top")!==-1){V="margin-bottom: -"+Math.round(z)+"px;"}else if(R.indexOf("left")!==-1){V="margin-right: -"+Math.round(z)+"px;"}else if(R.indexOf("right")!==-1){V="margin-left: -"+Math.round(z)+"px;"}X=''}n.$tooltip.find(".tooltipster-arrow").remove();var K='
'+X+'
';n.$tooltip.append(K)}n.$tooltip.css({top:Math.round(M)+"px",left:Math.round(A)+"px"})}return n},enable:function(){this.enabled=true;return this},disable:function(){this.hide();this.enabled=false;return this},destroy:function(){var t=this;t.hide();if(t.$el[0]!==t.$elProxy[0])t.$elProxy.remove();t.$el.removeData(t.namespace).off("."+t.namespace);var n=t.$el.data("tooltipster-ns");if(n.length===1){var r=typeof t.Content==="string"?t.Content:e("
").append(t.Content).html();t.$el.removeClass("tooltipstered").attr("title",r).removeData(t.namespace).removeData("tooltipster-ns").off("."+t.namespace)}else{n=e.grep(n,function(e,n){return e!==t.namespace});t.$el.data("tooltipster-ns",n)}return t},elementIcon:function(){return this.$el[0]!==this.$elProxy[0]?this.$elProxy[0]:undefined},elementTooltip:function(){return this.$tooltip?this.$tooltip[0]:undefined},option:function(e,t){if(typeof t=="undefined")return this.options[e];else{this.options[e]=t;return this}},status:function(){return this.Status}};e.fn[r]=function(){var t=arguments;if(this.length===0){if(typeof t[0]==="string"){var n=true;switch(t[0]){case"setDefaults":e.extend(i,t[1]);break;default:n=false;break}if(n)return true;else return this}else{return this}}else{if(typeof t[0]==="string"){var r="#*$~&";this.each(function(){var n=e(this).data("tooltipster-ns"),i=n?e(this).data(n[0]):null;if(i){if(typeof i[t[0]]==="function"){var s=i[t[0]](t[1],t[2])}else{throw new Error('Unknown method .tooltipster("'+t[0]+'")')}if(s!==i){r=s;return false}}else{throw new Error("You called Tooltipster's \""+t[0]+'" method on an uninitialized element')}});return r!=="#*$~&"?r:this}else{var o=[],u=t[0]&&typeof t[0].multiple!=="undefined",a=u&&t[0].multiple||!u&&i.multiple;this.each(function(){var n=false,r=e(this).data("tooltipster-ns"),i=null;if(!r){n=true}else{if(a)n=true;else console.log('Tooltipster: one or more tooltips are already attached to this element: ignoring. Use the "multiple" option to attach more tooltips.')}if(n){i=new s(this,t[0]);if(!r)r=[];r.push(i.namespace);e(this).data("tooltipster-ns",r);e(this).data(i.namespace,i)}o.push(i)});if(a)return o;else return this}}};var u=!!("ontouchstart"in t);var a=false;e("body").one("mousemove",function(){a=true})})(jQuery,window,document); \ No newline at end of file diff --git a/sai/page/js/libs/tooltipster-master/tooltipster.jquery.json b/sai/page/js/libs/tooltipster-master/tooltipster.jquery.json new file mode 100644 index 0000000..aceb7fa --- /dev/null +++ b/sai/page/js/libs/tooltipster-master/tooltipster.jquery.json @@ -0,0 +1,36 @@ +{ + "name": "tooltipster", + "title": "Tooltipster", + "description": "A lightweight, flexible jQuery plugin enabling you to easily create semantic, modern tooltips enhanced with the power of CSS.", + "keywords": [ + "tooltip" + ], + "version": "3.2.4", + "author": { + "name": "Caleb Jacob", + "url": "http://calebjacob.com/" + }, + "maintainers": [ + { + "name": "Caleb Jacob", + "email": "hello@calebjacob.com", + "url": "http://calebjacob.com/" + }, + { + "name": "Louis Ameline", + "email": "evangun2001@yahoo.fr", + "url": "https://github.com/louisameline" + } + ], + "licenses": [ + { + "type": "MIT", + "url": "http://opensource.org/licenses/MIT" + } + ], + "homepage": "https://github.com/iamceege/tooltipster", + "docs": "http://iamceege.github.io/tooltipster", + "dependencies": { + "jquery": ">=1.7" + } +} \ No newline at end of file