| @@ 825-848 (lines=24) @@ | ||
| 822 | } // Static |
|
| 823 | ; |
|
| 824 | ||
| 825 | Tooltip._jQueryInterface = function _jQueryInterface(config) { |
|
| 826 | return this.each(function () { |
|
| 827 | var data = $(this).data(DATA_KEY); |
|
| 828 | ||
| 829 | var _config = typeof config === 'object' && config; |
|
| 830 | ||
| 831 | if (!data && /dispose|hide/.test(config)) { |
|
| 832 | return; |
|
| 833 | } |
|
| 834 | ||
| 835 | if (!data) { |
|
| 836 | data = new Tooltip(this, _config); |
|
| 837 | $(this).data(DATA_KEY, data); |
|
| 838 | } |
|
| 839 | ||
| 840 | if (typeof config === 'string') { |
|
| 841 | if (typeof data[config] === 'undefined') { |
|
| 842 | throw new TypeError("No method named \"" + config + "\""); |
|
| 843 | } |
|
| 844 | ||
| 845 | data[config](); |
|
| 846 | } |
|
| 847 | }); |
|
| 848 | }; |
|
| 849 | ||
| 850 | _createClass(Tooltip, null, [{ |
|
| 851 | key: "VERSION", |
|
| @@ 178-201 (lines=24) @@ | ||
| 175 | } // Static |
|
| 176 | ; |
|
| 177 | ||
| 178 | Popover._jQueryInterface = function _jQueryInterface(config) { |
|
| 179 | return this.each(function () { |
|
| 180 | var data = $(this).data(DATA_KEY); |
|
| 181 | ||
| 182 | var _config = typeof config === 'object' ? config : null; |
|
| 183 | ||
| 184 | if (!data && /dispose|hide/.test(config)) { |
|
| 185 | return; |
|
| 186 | } |
|
| 187 | ||
| 188 | if (!data) { |
|
| 189 | data = new Popover(this, _config); |
|
| 190 | $(this).data(DATA_KEY, data); |
|
| 191 | } |
|
| 192 | ||
| 193 | if (typeof config === 'string') { |
|
| 194 | if (typeof data[config] === 'undefined') { |
|
| 195 | throw new TypeError("No method named \"" + config + "\""); |
|
| 196 | } |
|
| 197 | ||
| 198 | data[config](); |
|
| 199 | } |
|
| 200 | }); |
|
| 201 | }; |
|
| 202 | ||
| 203 | _createClass(Popover, null, [{ |
|
| 204 | key: "VERSION", |
|