"
39 | ],
40 | "js": [
41 | "js/jquery-3.0.0.min.js",
42 | "js/contentScript.js"
43 | ],
44 | "css": [
45 | "css/contentScript.css"
46 | ],
47 | "run_at": "document_start"
48 | }
49 | ],
50 | "web_accessible_resources": [
51 | ],
52 | "homepage_url": "https://github.com/scoful/cloudSkyMonster",
53 | "default_locale": "zh_CN",
54 | "commands": {
55 | "toggle-feature-save-all": {
56 | "suggested_key": {
57 | "default": "Ctrl+Q",
58 | "mac": "Command+Q"
59 | },
60 | "description": "__MSG_toggleFeatureSaveAllTabs__"
61 | },
62 | "toggle-feature-save-current": {
63 | "suggested_key": {
64 | "default": "Alt+Q",
65 | "mac": "Alt+Q"
66 | },
67 | "description": "__MSG_toggleFeatureSaveCurrentTabs__"
68 | }
69 | }
70 | }
71 |
--------------------------------------------------------------------------------
/js/popup.js:
--------------------------------------------------------------------------------
1 | ;(function (m) {
2 | 'use strict';
3 | console.log("popup_js is done!");
4 | // 定义一个n次循环定时器
5 | let intervalId;
6 |
7 | document.addEventListener('DOMContentLoaded', function () {
8 | console.log("load完popup了");
9 | // 点击插件图标直接跳到后台管理页
10 | sendMessageToBackground("openbackgroundpage", "");
11 |
12 | document.getElementById("deadLine").innerHTML = `
13 |
14 |
15 |
16 | `;
17 |
18 | });
19 |
20 | // 主动发送消息给后台
21 | function sendMessageToBackground(action, message) {
22 | chrome.runtime.sendMessage({action: action, message: message}, function (res) {
23 | if (res === 'ok') {
24 | console.log("content-->background发送的消息被消费了");
25 | }
26 | });
27 | }
28 |
29 | // 列出当前窗口打开的tab,方便浏览
30 | chrome.tabs.query({currentWindow: true}, function (allTabs) {
31 | let tabs = {};
32 |
33 | tabs.TabsList = Array;
34 |
35 | tabs.vm = new function () {
36 | let vm = {};
37 | vm.init = function () {
38 | vm.list = new tabs.TabsList();
39 | };
40 | vm.rmTab = function (index) {
41 | chrome.tabs.remove(tabs.vm.list[index].id, function callback() {
42 | });
43 | tabs.vm.list.splice(index, 1);
44 | };
45 | return vm;
46 | };
47 |
48 | tabs.controller = function () {
49 | let i;
50 | tabs.vm.init();
51 | for (i = 0; i < allTabs.length; i += 1) {
52 | let tab = {"title": allTabs[i].title, "id": allTabs[i].id, "favIconUrl": allTabs[i].favIconUrl};
53 | tabs.vm.list.push(tab);
54 | }
55 | };
56 |
57 | tabs.view = function () {
58 | return tabs.vm.list.map(function (tab, i) {
59 | let favIconUrl = tab.favIconUrl
60 | if (favIconUrl && typeof (favIconUrl) !== undefined && favIconUrl.indexOf("chrome") !== -1) {
61 | favIconUrl = "./images/48.png"
62 | }
63 | if (!favIconUrl) {
64 | favIconUrl = "./images/48.png"
65 | }
66 | if (typeof (favIconUrl) === undefined) {
67 | favIconUrl = "./images/48.png"
68 | }
69 | return m('div.row', {
70 | onclick: function () {
71 | chrome.tabs.highlight({tabs: i}, function callback() {
72 | });
73 | }
74 | }, [m("div.menu-entry", [m('span.delete-link', {
75 | onclick: function (event) {
76 | tabs.vm.rmTab(i);
77 | event.stopPropagation();
78 | }
79 | }), m('img', {
80 | src: favIconUrl, height: '15', width: '15'
81 | }), ' ', m("span", {}, tab.title)])]);
82 | });
83 | };
84 |
85 | // init the app
86 | m.module(document.getElementById('allTabs'), {controller: tabs.controller, view: tabs.view});
87 | });
88 |
89 | }(m));
90 |
--------------------------------------------------------------------------------
/js/contentScript.js:
--------------------------------------------------------------------------------
1 | console.log("content_script is done!!");
2 | let pageX;
3 | let pageY;
4 | let scrollTop;
5 | let scrollLeft;
6 | let autoHideTimeout;
7 |
8 | document.addEventListener('DOMContentLoaded', function () {
9 | // 鼠标划词(双击取词或者滑动取词)
10 | $(document).mouseup(function (e) {
11 | let txt = window.getSelection();
12 | console.log(txt.toString())
13 | if (txt.toString().trim().length > 0) {
14 | chrome.storage.local.get('dragOpenTranslate', function (storage) {
15 | if (storage.dragOpenTranslate) {
16 | sendMessageToBackground("translate", txt.toString());
17 | }
18 | });
19 | }
20 | });
21 |
22 | // 点击弹窗外部关闭弹窗
23 | $(document).click(function () {
24 | hidePopup();
25 | });
26 |
27 | // 持续获取鼠标所在坐标
28 | $(document).mousemove(function (e) {
29 | pageX = e.pageX;
30 | pageY = e.pageY;
31 | scrollTop = $(document).scrollTop();
32 | scrollLeft = $(document).scrollLeft();
33 | // console.log("x is " + pageX + ", y is " + pageY);
34 | // console.log("scrollTop is " + scrollTop + ", scrollLeft is " + scrollLeft);
35 | // console.log("x1 is " + parseInt(pageY - scrollTop) + ", y1 is " + parseInt(pageX - scrollLeft));
36 |
37 | // 获取弹窗元素
38 | let popup = document.getElementById('descDiv');
39 | if (popup) {
40 | // 鼠标悬停在弹窗上时保持显示
41 | popup.addEventListener('mouseenter', function () {
42 | clearTimeout(autoHideTimeout);
43 | });
44 | // 鼠标离开弹窗,触发自动关闭
45 | popup.addEventListener('mouseleave', function () {
46 | autoHidePopup();
47 | });
48 | }
49 | });
50 |
51 | });
52 |
53 |
54 | // 自动关闭弹窗
55 | function autoHidePopup() {
56 | autoHideTimeout = setTimeout(() => {
57 | hidePopup()
58 | }, 3000);
59 | }
60 |
61 |
62 | // 关闭弹窗
63 | function hidePopup() {
64 | // 获取弹窗元素
65 | let popup = document.getElementById('descDiv');
66 | if (popup) {
67 | popup.style.top = '-100px';
68 | setTimeout(() => {
69 | popup.remove();
70 | // flag = false;
71 | }, 400);
72 | }
73 | }
74 |
75 | // 主动发送消息给后台
76 | function sendMessageToBackground(action, message) {
77 | chrome.runtime.sendMessage({action: action, message: message}, function (res) {
78 | if (res === 'ok') {
79 | console.log("content-->background发送的消息被消费了");
80 | }
81 | });
82 | }
83 |
84 | // 持续监听发送给contentscript的消息
85 | chrome.runtime.onMessage.addListener(function (req, sender, sendRes) {
86 | switch (req.action) {
87 | case 'translateResult':
88 | sendRes('ok'); // acknowledge
89 | if (req.message.trim().length > 0) {
90 | tip(req.message);
91 | }
92 | break;
93 | default:
94 | sendRes('nope'); // acknowledge
95 | break;
96 | }
97 | });
98 |
99 | // 简单的消息通知
100 | function tip(info) {
101 | info = info || '';
102 | let ele = document.createElement('div');
103 | ele.id = 'descDiv';
104 | ele.className = 'chrome-plugin-simple-tip';
105 | ele.style.top = parseInt(pageY - scrollTop) + 20 + 'px';
106 | ele.style.left = pageX + 'px';
107 | ele.innerHTML = `${info}
`;
108 | document.body.appendChild(ele);
109 | autoHidePopup()
110 | }
111 |
--------------------------------------------------------------------------------
/privacy.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | 隐私权政策 | Privacy Policy
7 |
8 |
9 |
10 | 隐私权政策
11 | Privacy Policy
12 |
13 | 感谢您使用 N-Tab(以下简称"我们"或"插件")。我们非常重视您的隐私权,并致力于保护您的个人信息。本隐私权政策旨在向您说明我们收集、使用和保护您的个人信息的方式。请在使用我们的插件之前仔细阅读本隐私权政策。
14 | Thank you for using N-Tab (hereinafter referred to as "we" or "the plugin"). We value your privacy and are committed to protecting your personal information. This Privacy Policy is intended to inform you about how we collect, use, and protect your personal information. Please read this Privacy Policy carefully before using our plugin.
15 |
16 | 1. 信息收集 | Information Collection
17 |
18 |
19 | 1.1 自动收集信息 | Automatic Information Collection
20 |
21 |
22 | 当您使用 N-Tab 插件时,我们可能会自动收集与您的使用相关的信息,包括但不限于浏览器类型、操作系统、IP 地址、访问时间等。这些信息将用于改进插件的性能和功能,并帮助我们提供更好的用户体验。
23 | When you use the N-Tab plugin, we may automatically collect information related to your use, including but not limited to your browser type, operating system, IP address, and access time. This information will be used to improve the performance and functionality of the plugin and help us provide a better user experience.
24 |
25 | 1.2 个人信息 | Personal Information
26 |
27 |
28 | N-Tab 不会主动收集您的个人身份信息。然而,如果您选择向我们提供反馈、报告问题或与我们联系,您可能会提供一些个人信息,如您的姓名、电子邮件地址等。我们承诺保护您提供的个人信息,并仅在必要时用于回复您的请求和提供支持服务。
29 | N-Tab does not actively collect your personal identification information. However, if you choose to provide feedback, report issues, or contact us, you may provide some personal information such as your name, email address, etc. We promise to protect the personal information you provide and only use it to respond to your requests and provide support services when necessary.
30 |
31 | 2. 信息使用 | Information Use
32 |
33 |
34 | 我们仅会将您的个人信息用于以下目的:
35 | We will only use your personal information for the following purposes:
36 |
37 |
38 | - 提供、维护和改进 N-Tab 插件的功能和服务;
39 | - 回复您的反馈、问题和支持请求;
40 | - 向您发送与插件相关的通知和更新;
41 | - 遵守适用的法律法规和法律程序要求。
42 |
43 |
44 | - To provide, maintain, and improve the functionality and services of the N-Tab plugin;
45 | - To respond to your feedback, questions, and support requests;
46 | - To send you notifications and updates related to the plugin;
47 | - To comply with applicable laws, regulations, and legal process requirements.
48 |
49 |
50 | 3. 信息共享与披露 | Information Sharing and Disclosure
51 |
52 | 我们不会向任何第三方出售、交易或转让您的个人信息。然而,在以下情况下,我们可能会与第三方共享您的个人信息:
53 | We will not sell, trade, or transfer your personal information to any third party. However, we may share your personal information with third parties in the following circumstances:
54 |
55 |
56 | - 获得您的明确同意;
57 | - 遵守适用的法律法规和法律程序要求;
58 | - 保护我们的权利、财产或安全,以及其他用户的权利、财产或安全。
59 |
60 |
61 | - With your explicit consent;
62 | - To comply with applicable laws, regulations, and legal process requirements;
63 | - To protect our rights, property, or safety, as well as the rights, property, or safety of other users.
64 |
65 |
66 | 4. 信息安全 | Information Security
67 |
68 | 我们采取合理的安全措施来保护您的个人信息。然而,请注意,互联网上的数据传输和存储并不完全安全,我们无法保证数据的绝对安全性。使用 N-Tab 插件时,您自行承担风险。
69 | We take reasonable security measures to protect your personal information. However, please note that data transmission and storage over the Internet are not completely secure, and we cannot guarantee the absolute security of the data. You assume the risk when using the N-Tab plugin.
70 |
71 | 5. 隐私权政策的更新 | Privacy Policy Updates
72 |
73 | 我们可能会不时更新本隐私权政策。更新后的隐私权政策将在插件上发布,并自更新生效之日起取代先前版本。建议您定期查看本隐私权政策,以了解任何变更。继续使用 N-Tab 插件将被视为您接受更新后的隐私权政策。
74 | We may update this Privacy Policy from time to time. The updated Privacy Policy will be posted on the plugin and will replace the previous version from the effective date of the update. It is recommended that you regularly review this Privacy Policy for any changes. Continued use of the N-Tab plugin will be deemed as your acceptance of the updated Privacy Policy.
75 |
76 | 6. 联系我们 | Contact Us
77 |
78 | 如果您对本隐私权政策或您的个人信息有任何疑问或意见,请联系我们:scoful.tw@gmail.com。
79 | If you have any questions or concerns about this Privacy Policy or your personal information, please contact us at: scoful.tw@gmail.com.
80 |
81 | 最后更新时间 | Last Updated: 2023年10月9日 | October 9, 2023
82 |
83 |
84 |
85 |
--------------------------------------------------------------------------------
/css/workbench.css:
--------------------------------------------------------------------------------
1 | * {
2 | text-shadow: transparent 0 0 0, rgba(0, 0, 0, 0.68) 0 0 0 !important;
3 | }
4 |
5 | .fixed-bottom-right {
6 | position: fixed;
7 | bottom: 20px;
8 | right: 20px;
9 | z-index: 99;
10 | }
11 |
12 | .group-amount {
13 | font-size: 120%;
14 | }
15 |
16 | .group-name {
17 | font-size: 130%;
18 | font-weight: bold;
19 | }
20 |
21 | .group-date {
22 | opacity: 0.7;
23 | }
24 |
25 | .group-title {
26 | margin-bottom: 10px;
27 | }
28 |
29 | .restore-all {
30 | margin-left: 20px;
31 | cursor: pointer;
32 | color: #234da7;
33 | }
34 |
35 | .restore-all:hover {
36 | color: #234da7;
37 | text-decoration: underline;
38 | }
39 |
40 | .delete-all {
41 | margin-left: 20px;
42 | cursor: pointer;
43 | color: #234da7;
44 | }
45 |
46 | .delete-all:hover {
47 | color: #234da7;
48 | text-decoration: underline;
49 | }
50 |
51 | .about-lock {
52 | margin-left: 20px;
53 | cursor: pointer;
54 | color: #234da7;
55 | }
56 |
57 | .about-lock:hover {
58 | color: #234da7;
59 | text-decoration: underline;
60 | }
61 |
62 | .about-top {
63 | margin-left: 20px;
64 | cursor: pointer;
65 | color: #234da7;
66 | }
67 |
68 | .about-top:hover {
69 | color: #234da7;
70 | text-decoration: underline;
71 | }
72 |
73 | .about-name {
74 | margin-left: 20px;
75 | cursor: pointer;
76 | color: #234da7;
77 | }
78 |
79 | .about-name:hover {
80 | color: #234da7;
81 | text-decoration: underline;
82 | }
83 |
84 | .about-recover {
85 | margin-left: 20px;
86 | cursor: pointer;
87 | color: #234da7;
88 | }
89 |
90 | .about-recover:hover {
91 | color: #234da7;
92 | text-decoration: underline;
93 | }
94 |
95 | ul {
96 | margin-left: 2em;
97 | }
98 |
99 | .li-hover:hover {
100 | cursor: pointer;
101 | background: #f0f0f0;
102 | padding-bottom: 3px;
103 | }
104 |
105 | .li-standard {
106 | padding-bottom: 3px;
107 | }
108 |
109 | .strikethrough {
110 | text-decoration: line-through;
111 | }
112 |
113 | .delete-link {
114 | font-size: 70%;
115 | font-weight: bold;
116 | background: #eee;
117 | color: white;
118 | display: inline-block;
119 | border-radius: 1em;
120 | padding: 0 .3em;
121 | margin-right: 10px;
122 | }
123 |
124 | .no-delete-link {
125 | margin-right: 5px;
126 | }
127 |
128 | .delete-link:before {
129 | content: "✖";
130 | }
131 |
132 | *:hover > .delete-link {
133 | background: #aaa;
134 | }
135 |
136 | .delete-link:hover {
137 | background: red;
138 | cursor: pointer;
139 | }
140 |
141 | .link, .link:visited {
142 | color: #234da7;
143 | text-decoration: none;
144 | padding: .2em;
145 | font-size: 85%;
146 | }
147 |
148 | .link:hover {
149 | cursor: pointer;
150 | text-decoration: underline;
151 | }
152 |
153 | .my-handle {
154 | cursor: move;
155 | }
156 |
157 | .ghost {
158 | opacity: .5;
159 | background: #C8EBFB;
160 | }
161 |
162 | .tabs {
163 | padding-top: 10px;
164 | padding-bottom: 10px;
165 | }
166 |
167 | .lock-img {
168 | height: 18px;
169 | margin-right: 6px;
170 | padding-top: 3px;
171 | }
172 |
173 | .no-lock-img {
174 | height: 18px;
175 | display: none;
176 | }
177 |
178 | .pin-img {
179 | height: 25px;
180 | }
181 |
182 | .no-pin-img {
183 | height: 25px;
184 | display: none;
185 | }
186 |
187 | .group-title-input {
188 | width: 75px;
189 | overflow: hidden;
190 | border: none;
191 | margin-right: 5px;
192 | }
193 |
194 | .line {
195 | text-decoration: none;
196 | padding: .2em;
197 | }
198 |
199 | .div-top {
200 | margin-top: 15px;
201 | }
202 |
203 | .option {
204 | margin: 15px 0;
205 | }
206 |
207 | .option:first-of-type {
208 | margin-top: 0;
209 | }
210 |
211 | .desc {
212 | font-size: 1.1em;
213 | margin-bottom: 5px;
214 | }
215 |
216 | .choices {
217 | font-size: .9em;
218 | }
219 |
220 | #saved {
221 | display: none;
222 | background: green;
223 | color: white;
224 | width: 300px;
225 | margin-top: 15px;
226 | }
227 |
228 | .taskButtonGroup {
229 | float: right;
230 | margin-right: 20px;
231 | }
232 |
233 | .addTaskTextClass {
234 | margin: 10px;
235 | }
236 |
237 | .chrome-plugin-simple-tip {
238 | position: fixed;
239 | z-index: 999999; /* 这里是该元素与显示屏的距离,据说越大越好,但是我也没有看到效果,因为没有它也是可以的 */
240 | padding: 16px 10px;
241 | color: #FFFFFF;
242 | min-width: 150px;
243 | max-width: 700px;
244 | border-radius: 3px;
245 | text-align: center;
246 | font-size: 20px;
247 | background: #003366;
248 | /*background-image: linear-gradient(to bottom, #dff0d8, #70a800);*/
249 | box-shadow: 0 0 3px rgba(0, 0, 0, .2);
250 | transition: top .4s;
251 | }
252 |
--------------------------------------------------------------------------------
/css/bootstrap-switch.min.css:
--------------------------------------------------------------------------------
1 | /**
2 | * bootstrap-switch - Turn checkboxes and radio buttons into toggle switches.
3 | *
4 | * @version v3.3.4
5 | * @homepage https://bttstrp.github.io/bootstrap-switch
6 | * @author Mattia Larentis (http://larentis.eu)
7 | * @license Apache-2.0
8 | */
9 |
10 | .bootstrap-switch{display:inline-block;direction:ltr;cursor:pointer;border-radius:4px;border:1px solid #ccc;position:relative;text-align:left;overflow:hidden;line-height:8px;z-index:0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-webkit-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;-o-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s}.bootstrap-switch .bootstrap-switch-container{display:inline-block;top:0;border-radius:4px;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}.bootstrap-switch .bootstrap-switch-handle-off,.bootstrap-switch .bootstrap-switch-handle-on,.bootstrap-switch .bootstrap-switch-label{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;cursor:pointer;display:table-cell;vertical-align:middle;padding:6px 12px;font-size:14px;line-height:20px}.bootstrap-switch .bootstrap-switch-handle-off,.bootstrap-switch .bootstrap-switch-handle-on{text-align:center;z-index:1}.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-primary,.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-primary{color:#fff;background:#337ab7}.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-info,.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-info{color:#fff;background:#5bc0de}.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-success,.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-success{color:#fff;background:#5cb85c}.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-warning,.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-warning{background:#f0ad4e;color:#fff}.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-danger,.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-danger{color:#fff;background:#d9534f}.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-default,.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-default{color:#000;background:#eee}.bootstrap-switch .bootstrap-switch-label{text-align:center;margin-top:-1px;margin-bottom:-1px;z-index:100;color:#333;background:#fff}.bootstrap-switch span::before{content:"\200b"}.bootstrap-switch .bootstrap-switch-handle-on{border-bottom-left-radius:3px;border-top-left-radius:3px}.bootstrap-switch .bootstrap-switch-handle-off{border-bottom-right-radius:3px;border-top-right-radius:3px}.bootstrap-switch input[type=radio],.bootstrap-switch input[type=checkbox]{position:absolute!important;top:0;left:0;margin:0;z-index:-1;opacity:0;filter:alpha(opacity=0);visibility:hidden}.bootstrap-switch.bootstrap-switch-mini .bootstrap-switch-handle-off,.bootstrap-switch.bootstrap-switch-mini .bootstrap-switch-handle-on,.bootstrap-switch.bootstrap-switch-mini .bootstrap-switch-label{padding:1px 5px;font-size:12px;line-height:1.5}.bootstrap-switch.bootstrap-switch-small .bootstrap-switch-handle-off,.bootstrap-switch.bootstrap-switch-small .bootstrap-switch-handle-on,.bootstrap-switch.bootstrap-switch-small .bootstrap-switch-label{padding:5px 10px;font-size:12px;line-height:1.5}.bootstrap-switch.bootstrap-switch-large .bootstrap-switch-handle-off,.bootstrap-switch.bootstrap-switch-large .bootstrap-switch-handle-on,.bootstrap-switch.bootstrap-switch-large .bootstrap-switch-label{padding:6px 16px;font-size:18px;line-height:1.3333333}.bootstrap-switch.bootstrap-switch-disabled,.bootstrap-switch.bootstrap-switch-indeterminate,.bootstrap-switch.bootstrap-switch-readonly{cursor:default!important}.bootstrap-switch.bootstrap-switch-disabled .bootstrap-switch-handle-off,.bootstrap-switch.bootstrap-switch-disabled .bootstrap-switch-handle-on,.bootstrap-switch.bootstrap-switch-disabled .bootstrap-switch-label,.bootstrap-switch.bootstrap-switch-indeterminate .bootstrap-switch-handle-off,.bootstrap-switch.bootstrap-switch-indeterminate .bootstrap-switch-handle-on,.bootstrap-switch.bootstrap-switch-indeterminate .bootstrap-switch-label,.bootstrap-switch.bootstrap-switch-readonly .bootstrap-switch-handle-off,.bootstrap-switch.bootstrap-switch-readonly .bootstrap-switch-handle-on,.bootstrap-switch.bootstrap-switch-readonly .bootstrap-switch-label{opacity:.5;filter:alpha(opacity=50);cursor:default!important}.bootstrap-switch.bootstrap-switch-animate .bootstrap-switch-container{-webkit-transition:margin-left .5s;-o-transition:margin-left .5s;transition:margin-left .5s}.bootstrap-switch.bootstrap-switch-inverse .bootstrap-switch-handle-on{border-radius:0 3px 3px 0}.bootstrap-switch.bootstrap-switch-inverse .bootstrap-switch-handle-off{border-radius:3px 0 0 3px}.bootstrap-switch.bootstrap-switch-focused{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.bootstrap-switch.bootstrap-switch-inverse.bootstrap-switch-off .bootstrap-switch-label,.bootstrap-switch.bootstrap-switch-on .bootstrap-switch-label{border-bottom-right-radius:3px;border-top-right-radius:3px}.bootstrap-switch.bootstrap-switch-inverse.bootstrap-switch-on .bootstrap-switch-label,.bootstrap-switch.bootstrap-switch-off .bootstrap-switch-label{border-bottom-left-radius:3px;border-top-left-radius:3px}
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # N-Tab
2 |
3 | **目录**
4 | ----
5 | * [N-Tab](#N-Tab)
6 | * [背景介绍](#背景介绍)
7 | * [模拟使用场景](#模拟使用场景)
8 | * [支持多款浏览器](#支持多款浏览器)
9 | * [快速使用](#快速使用)
10 | * [安装方法](#安装方法)
11 | * [功能界面截图](#功能界面截图)
12 | * [获取token方法](#获取token方法)
13 | * [To Do List](#to-do-list)
14 | * [Discussing](#discussing)
15 | * [感谢以下大神的肩膀](#感谢以下大神的肩膀)
16 | * [Star历史](#Star历史)
17 |
18 |
19 | ## 背景介绍
20 |
21 | 0. 改名N-Tab,方便口头传播,之前的名字太中二了,Orz
22 | 1. 本项目是一个Chrome插件
23 | 2. 经过4年时间自用,敢保证永不丢失数据,速度超快,可存储数据超多,绝对是效率提升工具!
24 | 3. OneTab的平替,OneTab丢过数据的举手集合!
25 |
26 | ## 模拟使用场景
27 | - 打开了N多Tab,每一个都不想关闭,浏览器已经到了点不了的情况,怎么办?--->一键收集起来慢慢看
28 | - 今天上班为了解决某个问题/寻找某个选题,打开了很多相关的网站,但是要下班了,要关电脑怎么办?--->一键收集起来第二天一键打开
29 | - 很多常用要打开的网站,浏览器自带的标签栏都放不下了?--->直接收集起来,置顶锁定,省心省力
30 | - 可以做任务优先级分类,**紧急的事**,**重要的事**,**紧急但不重要的事**,**重要但不紧急的事**--->或者完全自定义
31 | - 可以做历史时间线回顾,看看一个星期前,一个月前,都在看什么资料,关注什么内容
32 |
33 | ## 支持多款浏览器
34 | - 谷歌 Chrome 浏览器:[Chrome商店](https://chrome.google.com/webstore/detail/cloudskymonster/niahhcandihcfbamcfhikgojghnnfjan)
35 | - 微软 Edge 浏览器:[Edge商店](https://microsoftedge.microsoft.com/addons/detail/cloudskymonster/hfinincbgekmplkkhnpaodhconghkboh)
36 |
37 | ## 快速使用
38 |
39 | - **PS:** 不想看长篇大论的介绍和功能说明,直接看[安装方法](#安装方法)
40 | - 点击插件图标,会打开后台管理页
41 | - 在任何打开的网页(包括本地打开的文件,如PDF,视频,照片),空白处直接右键点击,找到N-Tab,有多种功能可选
42 | - 在任何打开的网页(包括本地打开的文件,如PDF,视频,照片),按快捷键Ctrl+Q,可以**发送所有标签**
43 | - 在任何打开的网页(包括本地打开的文件,如PDF,视频,照片),按快捷键Alt+Q,可以**发送当前标签**
44 | - 如需要定时同步功能,请配置GitHub或Gitee的token,可二选一或全配置
45 | - [查看全功能介绍(详细啰嗦版)](README_ALL.md)
46 | - 关于暗黑模式,折腾了一下发现,Chrome浏览器自带的暗黑模式效果就很不错,就没有另外添加了。[暗黑模式开启方法](#暗黑模式开启方法)
47 |
48 | ## 安装方法
49 |
50 | 0. 直接在Chrome插件商店下载安装,[地址](https://chrome.google.com/webstore/detail/cloudskymonster/niahhcandihcfbamcfhikgojghnnfjan)
51 |
52 | 1. 或者直接下载[最新的crx或zip](https://github.com/scoful/cloudSkyMonster/releases)文件,右键选择解压缩到文件名,不要解压缩到当前目录,或者直接下载源码;
53 |
54 | 2. 打开Chrome浏览器或其他支持Chrome内核的浏览器,找到并点开“扩展程序”项;
55 |
56 | 3. 在打开的新页面中,勾选“开发者模式”,点击“加载已解压的拓展程序”按钮;
57 |
58 | 4. 从打开的“浏览文件夹”窗口中,选择第1步解压缩的的文件夹,点击“确定”按钮;
59 |
60 | 5. 此时该插件就正式启动了,观察浏览器右上角是否有新的插件图标,新版Chrome浏览器要手动固定才会显示。
61 |
62 | 6. 建议插件安装成功后,关闭开发者模式。
63 |
64 | 7. 现在就可以正常使用了,假如需要同步功能,先[获取GitHub和Gitee的token](#获取token方法),在“其他功能”-“查看配置”里对应的地方填写token,然后在“同步功能”-“是否自动同步”选是;
65 |
66 | 8. 2个同步平台,可以同时配置,也可以只配置1个,不冲突,假如选了自动同步,会自动无感知的**定时**同步到2个平台里(请先手动同步一次,通过查看日志,检查链路是否通顺),注意:Gitee特别设置了只要有修改就无感知自动**实时**同步,也就是说只要有修改,删除,移动等动作,就自动实时同步到Gitee,选Gitee更保险,真.理论上永不丢失数据。
67 |
68 | ## 功能界面截图
69 | - 后台管理页面截图 
70 | - 同步功能截图
71 | - 其他功能截图 
72 | - 回收站截图 
73 | - 暗黑模式截图 
74 | - 英文版截图 
75 |
76 | ## 获取token方法
77 | ### Gitee
78 | - 打开[Gitee](https://gitee.com/),登录后
79 | - 打开[私人令牌](https://gitee.com/profile/personal_access_tokens)
80 | - 右上角生成新令牌,输入一个看起来有意义能明白啥用途的名字,比如: my-onetab-syncing-settings ,注意只勾选gist(可Ctrl+F搜索一下),其他的不要勾选,
81 | - 提交后,输入密码,生成后,要把显示的token另外找地方备份记录一下,只有在第一次创建的时候才会显示的,错过了只能重来。
82 |
83 | ### GitHub
84 | - 打开[GitHub](https://github.com/),登录后
85 | - 打开[私人令牌](https://github.com/settings/tokens)
86 | - 右上角选择Generate new token (classic),输入一个看起来有意义能明白啥用途的名字,比如: my-onetab-syncing-settings ,注意只勾选gist(可Ctrl+F搜索一下),其他的不要勾选,
87 | - 提交后,输入密码,生成后,要把显示的token另外找地方备份记录一下,只有在第一次创建的时候才会显示的,错过了只能重来。
88 |
89 |
90 | ## 暗黑模式开启方法
91 | ### (可选)Win10本身变成暗黑模式
92 | - Windows 设置--个性化--颜色--选择颜色(自定义)--选择默认应用模式(暗)--这就是系统级别的暗黑模式,所有支持暗黑模式的软件都会自动变成暗黑模式
93 | 
94 |
95 | ### 只是网页内容变成暗黑模式
96 | - 打开Chrome浏览器,输入 **Chrome://flags**,在搜索框输入**Auto Dark Mode for Web Contents**,在找到的设置右边改成**Enabled**
97 | - 重启Chrome浏览器,这样本插件就自动变成暗黑模式了!
98 | 
99 |
100 | ## To Do List
101 |
102 | - 优化代码,修改bug
103 | - 根据需求再添加新功能
104 | - etc...
105 |
106 |
107 | ## Discussing
108 |
109 | - [在GitHub上提问](https://github.com/scoful/cloudSkyMonster/issues/new "在GitHub上提问")
110 | - wechat:scoful
111 | - QQ:1269717999
112 | - email:1269717999@qq.com
113 |
114 |
115 |
116 | 
117 |
118 | 
119 |
120 |
121 | ------
122 |
123 | ## 感谢以下大神的肩膀
124 |
125 | [chrome插件官网](https://developer.chrome.com/extensions)
126 |
127 | [chrome api官网](https://developer.chrome.com/extensions/api_index)
128 |
129 | [【干货】Chrome插件(扩展)开发全攻略](https://www.cnblogs.com/liuxianan/p/chrome-plugin-develop.html#%E9%95%BF%E8%BF%9E%E6%8E%A5%E5%92%8C%E7%9F%AD%E8%BF%9E%E6%8E%A5)
130 |
131 | [chrome-plugin-demo插件](https://github.com/sxei/chrome-plugin-demo)
132 |
133 | [chrome-ext-tabulator插件](https://github.com/greduan/chrome-ext-tabulator)
134 |
135 | [ContextSearch插件](https://github.com/lo0kup/ContextSearch)
136 |
137 | [一篇文章搞定GitHub API 调用 (v3)](https://segmentfault.com/a/1190000015144126)
138 |
139 | [Sortable官网](https://github.com/SortableJS/Sortable)
140 |
141 | [Sortable.js拖拽排序使用方法解析](https://www.jb51.net/article/96446.htm)
142 |
143 | [js数组内元素移动,适用于拖动排序](https://www.cnblogs.com/zwhblog/p/7941744.html)
144 |
145 | [GitHubApi文档](https://developer.github.com/v3/)
146 |
147 | [GiteeAPI文档](https://gitee.com/api/v5/swagger)
148 |
149 | [Bootstrap中文网](https://www.bootcss.com/)
150 |
151 | [腾讯交互翻译](https://transmart.qq.com/zh-CN/index)
152 |
153 | [辅助生成百度统计插件](https://github.com/krapnikkk/baidutongji-generator)
154 |
155 | ## Star历史
156 |
157 | [](https://starchart.cc/scoful/cloudSkyMonster)
158 |
159 | You are my th visitor
160 |
161 |
--------------------------------------------------------------------------------
/js/prefixfree.min.js:
--------------------------------------------------------------------------------
1 | /**
2 | * StyleFix 1.0.3 & PrefixFree 1.0.7
3 | * @author Lea Verou
4 | * MIT license
5 | */(function(){function t(e,t){return[].slice.call((t||document).querySelectorAll(e))}if(!window.addEventListener)return;var e=window.StyleFix={link:function(t){try{if(t.rel!=="stylesheet"||t.hasAttribute("data-noprefix"))return}catch(n){return}var r=t.href||t.getAttribute("data-href"),i=r.replace(/[^\/]+$/,""),s=(/^[a-z]{3,10}:/.exec(i)||[""])[0],o=(/^[a-z]{3,10}:\/\/[^\/]+/.exec(i)||[""])[0],u=/^([^?]*)\??/.exec(r)[1],a=t.parentNode,f=new XMLHttpRequest,l;f.onreadystatechange=function(){f.readyState===4&&l()};l=function(){var n=f.responseText;if(n&&t.parentNode&&(!f.status||f.status<400||f.status>600)){n=e.fix(n,!0,t);if(i){n=n.replace(/url\(\s*?((?:"|')?)(.+?)\1\s*?\)/gi,function(e,t,n){return/^([a-z]{3,10}:|#)/i.test(n)?e:/^\/\//.test(n)?'url("'+s+n+'")':/^\//.test(n)?'url("'+o+n+'")':/^\?/.test(n)?'url("'+u+n+'")':'url("'+i+n+'")'});var r=i.replace(/([\\\^\$*+[\]?{}.=!:(|)])/g,"\\$1");n=n.replace(RegExp("\\b(behavior:\\s*?url\\('?\"?)"+r,"gi"),"$1")}var l=document.createElement("style");l.textContent=n;l.media=t.media;l.disabled=t.disabled;l.setAttribute("data-href",t.getAttribute("href"));a.insertBefore(l,t);a.removeChild(t);l.media=t.media}};try{f.open("GET",r);f.send(null)}catch(n){if(typeof XDomainRequest!="undefined"){f=new XDomainRequest;f.onerror=f.onprogress=function(){};f.onload=l;f.open("GET",r);f.send(null)}}t.setAttribute("data-inprogress","")},styleElement:function(t){if(t.hasAttribute("data-noprefix"))return;var n=t.disabled;t.textContent=e.fix(t.textContent,!0,t);t.disabled=n},styleAttribute:function(t){var n=t.getAttribute("style");n=e.fix(n,!1,t);t.setAttribute("style",n)},process:function(){t('link[rel="stylesheet"]:not([data-inprogress])').forEach(StyleFix.link);t("style").forEach(StyleFix.styleElement);t("[style]").forEach(StyleFix.styleAttribute)},register:function(t,n){(e.fixers=e.fixers||[]).splice(n===undefined?e.fixers.length:n,0,t)},fix:function(t,n,r){for(var i=0;i-1&&(e=e.replace(/(\s|:|,)(repeating-)?linear-gradient\(\s*(-?\d*\.?\d*)deg/ig,function(e,t,n,r){return t+(n||"")+"linear-gradient("+(90-r)+"deg"}));e=t("functions","(\\s|:|,)","\\s*\\(","$1"+s+"$2(",e);e=t("keywords","(\\s|:)","(\\s|;|\\}|$)","$1"+s+"$2$3",e);e=t("properties","(^|\\{|\\s|;)","\\s*:","$1"+s+"$2:",e);if(n.properties.length){var o=RegExp("\\b("+n.properties.join("|")+")(?!:)","gi");e=t("valueProperties","\\b",":(.+?);",function(e){return e.replace(o,s+"$1")},e)}if(r){e=t("selectors","","\\b",n.prefixSelector,e);e=t("atrules","@","\\b","@"+s+"$1",e)}e=e.replace(RegExp("-"+s,"g"),"-");e=e.replace(/-\*-(?=[a-z]+)/gi,n.prefix);return e},property:function(e){return(n.properties.indexOf(e)>=0?n.prefix:"")+e},value:function(e,r){e=t("functions","(^|\\s|,)","\\s*\\(","$1"+n.prefix+"$2(",e);e=t("keywords","(^|\\s)","(\\s|$)","$1"+n.prefix+"$2$3",e);n.valueProperties.indexOf(r)>=0&&(e=t("properties","(^|\\s|,)","($|\\s|,)","$1"+n.prefix+"$2$3",e));return e},prefixSelector:function(e){return e.replace(/^:{1,2}/,function(e){return e+n.prefix})},prefixProperty:function(e,t){var r=n.prefix+e;return t?StyleFix.camelCase(r):r}};(function(){var e={},t=[],r={},i=getComputedStyle(document.documentElement,null),s=document.createElement("div").style,o=function(n){if(n.charAt(0)==="-"){t.push(n);var r=n.split("-"),i=r[1];e[i]=++e[i]||1;while(r.length>3){r.pop();var s=r.join("-");u(s)&&t.indexOf(s)===-1&&t.push(s)}}},u=function(e){return StyleFix.camelCase(e)in s};if(i.length>0)for(var a=0;a (http://larentis.eu)
7 | * @license Apache-2.0
8 | */
9 |
10 | (function(a,b){if('function'==typeof define&&define.amd)define(['jquery'],b);else if('undefined'!=typeof exports)b(require('jquery'));else{b(a.jquery),a.bootstrapSwitch={exports:{}}.exports}})(this,function(a){'use strict';function c(j,k){if(!(j instanceof k))throw new TypeError('Cannot call a class as a function')}var d=function(j){return j&&j.__esModule?j:{default:j}}(a),e=Object.assign||function(j){for(var l,k=1;k',{class:function(){var o=[];return o.push(l.options.state?'on':'off'),l.options.size&&o.push(l.options.size),l.options.disabled&&o.push('disabled'),l.options.readonly&&o.push('readonly'),l.options.indeterminate&&o.push('indeterminate'),l.options.inverse&&o.push('inverse'),l.$element.attr('id')&&o.push('id-'+l.$element.attr('id')),o.map(l._getClass.bind(l)).concat([l.options.baseClass],l._getClasses(l.options.wrapperClass)).join(' ')}}),this.$container=g('',{class:this._getClass('container')}),this.$on=g('
',{html:this.options.onText,class:this._getClass('handle-on')+' '+this._getClass(this.options.onColor)}),this.$off=g('',{html:this.options.offText,class:this._getClass('handle-off')+' '+this._getClass(this.options.offColor)}),this.$label=g('',{html:this.options.labelText,class:this._getClass('label')}),this.$element.on('init.bootstrapSwitch',this.options.onInit.bind(this,k)),this.$element.on('switchChange.bootstrapSwitch',function(){for(var n=arguments.length,o=Array(n),p=0;p-(l._handleWidth/2);l._dragEnd=!1,l.state(l.options.inverse?!p:p)}else l.state(!l.options.state);l._dragStart=!1}},'mouseleave.bootstrapSwitch':function(){l.$label.trigger('mouseup.bootstrapSwitch')}})}},{key:'_externalLabelHandler',value:function(){var l=this,m=this.$element.closest('label');m.on('click',function(n){n.preventDefault(),n.stopImmediatePropagation(),n.target===m[0]&&l.toggleState()})}},{key:'_formHandler',value:function(){var l=this.$element.closest('form');l.data('bootstrap-switch')||l.on('reset.bootstrapSwitch',function(){window.setTimeout(function(){l.find('input').filter(function(){return g(this).data('bootstrap-switch')}).each(function(){return g(this).bootstrapSwitch('state',this.checked)})},1)}).data('bootstrap-switch',!0)}},{key:'_getClass',value:function(l){return this.options.baseClass+'-'+l}},{key:'_getClasses',value:function(l){return g.isArray(l)?l.map(this._getClass.bind(this)):[this._getClass(l)]}}]),j}();g.fn.bootstrapSwitch=function(j){for(var l=arguments.length,m=Array(11||i[0].nodeValue.trim&&!i[0].nodeValue.trim())&&(Q(t.nodes,t),i=[Ne.createTextNode(e)]),v(n,i[0],o,e))),t=new e.constructor(e),t.nodes=i,t.$trusted=e.$trusted,t}function S(e,t,n,r,o,a,i){return e.nodes.length?e.valueOf()!==t.valueOf()||o?A(t,e,r,a,n,i):(e.nodes.intact=!0,e):j(t,r,n)}function R(e){return e.$trusted?e.nodes.length:Se(e)?e.length:1}function M(e,t,r,o,a,i,u,l,c){e=m(e);var s=[],d=t.length===e.length,f=0,p={},v=!1;h(t,function(e,n){v=!0,p[t[n].attrs.key]={action:Me,index:n}}),x(e),v&&(t=w(e,t,p,r));for(var g=0,y=0,C=e.length;y0?K(t,e.tag,n,n,e.children,r.children,!0,0,e.attrs.contenteditable?t:o,a,i):e.children}function U(e,t,n,r,o,a,i){var u={tag:e.tag,attrs:t,children:n,nodes:[r]};return T(u,a,i),u.children&&!u.children.nodes&&(u.children.nodes=[]),u}function q(e,t,n,o){var a;return(a="diff"===d.redraw.strategy()&&e?e.indexOf(t):-1)>-1?n[a]:r(o)?new o:{}}function z(e,t,n,r){null!=r.onunload&&Ue.map(function(e){return e.handler}).indexOf(r.onunload)<0&&Ue.push({controller:r,handler:r.onunload}),e.push(n),t.push(r)}function H(e,t,n,r,o,a){var i=q(n.views,t,r,e.controller),u=e&&e.attrs&&e.attrs.key;return"retain"===(e=0===Ie||qe||r&&r.indexOf(i)>-1?e.view(i):{tag:"placeholder"}).subtree?e:(e.attrs=e.attrs||{},e.attrs.key=u,z(a,o,t,i),e)}function J(e,t,n,r){for(var o=t&&t.controllers;null!=e.view;)e=H(e,e.view.$original||e.view,t,o,r,n);return e}function B(e,t,n,r,o,i,u,l){var c=[],s=[];if("retain"===(e=J(e,t,c,s)).subtree)return t;if(!e.tag&&s.length)throw new Error("Component template must return a virtual element, not an array, string, etc.");e.attrs=e.attrs||{},t.attrs=t.attrs||{};var d=Object.keys(e.attrs),f=d.length>("key"in e.attrs?1:0);if(b(e,t,d),a(e.tag)){var h=0===t.nodes.length;u=N(e,u);var p;if(h){var v=I(e,p=D(e,u),u,f);g(r,p,o),t=U(e,v,$(e,p,t,n,u,l),p,u,c,s)}else p=O(t,e,n,f,u,c,l,s);return"select"===e.tag&&"value"in e.attrs&&V(p,e.tag,{value:e.attrs.value},{},u),h||!0!==i||null==p||g(r,p,o),k(l,e,p,h,t),t}}function K(e,t,n,a,i,u,l,c,s,d,f){return"retain"===(i=p(i)).subtree?u:(u=L(i,u,c,a,n),Se(i)?M(i,u,e,c,t,l,s,d,f):null!=i&&o(i)?B(i,u,s,e,c,l,d,f):r(i)?u:S(u,i,c,e,l,s,t))}function _(e,t){return e.action-t.action||e.index-t.index}function F(e,t,n){n===t&&(e.style="",n={});for(var r in t)je.call(t,r)&&(null!=n&&n[r]===t[r]||(e.style[r]=t[r]));for(r in n)je.call(n,r)&&(je.call(t,r)||(e.style[r]=""))}function G(e,t,n,a,i,u){if("config"===t||"key"===t)return!0;if(r(n)&&"on"===t.slice(0,2))e[t]=te(n,e);else if("style"===t&&null!=n&&o(n))F(e,n,a);else if(null!=u)"href"===t?e.setAttributeNS("http://www.w3.org/1999/xlink","href",n):e.setAttribute("className"===t?"class":t,n);else if(t in e&&!ze[t])try{("input"!==i&&!e.isContentEditable||e[t]!=n)&&(e[t]=n)}catch(r){e.setAttribute(t,n)}else try{e.setAttribute(t,n)}catch(e){}}function P(e,t,n,r,o,a,i){if(t in o&&r===n&&"object"!=typeof n&&Ne.activeElement!==e)"value"===t&&"input"===a&&e.value!=n&&(e.value=n);else{o[t]=n;try{return G(e,t,n,r,a,i)}catch(e){if(e.message.indexOf("Invalid argument")<0)throw e}}}function V(e,t,n,r,o){for(var a in n)!je.call(n,a)||P(e,a,n[a],r[a],r,t,o);return r}function Q(e,t){for(var n=e.length-1;n>-1;n--)if(e[n]&&e[n].parentNode){try{e[n].parentNode.removeChild(e[n])}catch(e){}(t=[].concat(t))[n]&&Y(t[n])}e.length&&(e.length=0)}function Y(e){e.configContext&&r(e.configContext.onunload)&&(e.configContext.onunload(),e.configContext.onunload=null),e.controllers&&f(e.controllers,function(e){r(e.onunload)&&e.onunload({preventDefault:i})}),e.children&&(Se(e.children)?f(e.children,Y):e.children.tag&&Y(e.children))}function W(e,t){try{e.appendChild(Ne.createRange().createContextualFragment(t))}catch(n){e.insertAdjacentHTML("beforeend",t),X(e)}}function X(e){if("SCRIPT"===e.tagName)e.parentNode.replaceChild(Z(e),e);else{var t=e.childNodes;if(t&&t.length)for(var n=0;n0?"&":"?")+(e.callbackKey?e.callbackKey:"callback")+"="+r+"&"+he(e.data||{}),Ne.body.appendChild(o)}function Ee(e){var n=new t.XMLHttpRequest;if(n.open(e.method,e.url,!0,e.user,e.password),n.onreadystatechange=function(){4===n.readyState&&(n.status>=200&&n.status<300?e.onload({type:"load",target:n}):e.onerror({type:"error",target:n}))},e.serialize===JSON.stringify&&e.data&&"GET"!==e.method&&n.setRequestHeader("Content-Type","application/json; charset=utf-8"),e.deserialize===JSON.parse&&n.setRequestHeader("Accept","application/json, text/*"),o(e.headers))for(var i in e.headers)je.call(e.headers,i)&&n.setRequestHeader(i,e.headers[i]);if(r(e.config)){var u=e.config(n,e);null!=u&&(n=u)}var l="GET"!==e.method&&e.data?e.data:"";if(l&&!a(l)&&l.constructor!==t.FormData)throw new Error("Request data should be either be a string or FormData. Check the `serialize` option in `m.request`");return n.send(l),n}function xe(e){return e.dataType&&"jsonp"===e.dataType.toLowerCase()?we(e):Ee(e)}function Ce(e,t,n){if("GET"===e.method&&"jsonp"!==e.dataType){var r=e.url.indexOf("?")<0?"?":"&",o=he(t);e.url+=o?r+o:""}else e.data=n(t)}function be(e,t){return t&&(e=e.replace(/:[a-z]\w+/gi,function(e){var n=e.slice(1),r=t[n]||e;return delete t[n],r})),e}d.version=function(){return"v0.2.8"};var Ne,Te,ke,Oe,je={}.hasOwnProperty,Ae={}.toString,Se=Array.isArray||function(e){return"[object Array]"===Ae.call(e)},Re={AREA:1,BASE:1,BR:1,COL:1,COMMAND:1,EMBED:1,HR:1,IMG:1,INPUT:1,KEYGEN:1,LINK:1,META:1,PARAM:1,SOURCE:1,TRACK:1,WBR:1};d.deps=function(e){return u(t=e||window),t},d.deps.factory=d.factory=e,d.deps(t);var Me=1,Le=2,De=3,Ie=0;d.startComputation=function(){Ie++},d.endComputation=function(){Ie>1?Ie--:(Ie=0,d.redraw())};var $e,Ue=[],qe=!1,ze={list:1,style:1,form:1,type:1,width:1,height:1},He={appendChild:function(e){$e===n&&($e=Ne.createElement("html")),Ne.documentElement&&Ne.documentElement!==e?Ne.replaceChild(e,Ne.documentElement):Ne.appendChild(e),this.childNodes=Ne.childNodes},insertBefore:function(e){this.appendChild(e)},childNodes:[]},Je=[],Be={};d.render=function(e,t,r){if(!e)throw new Error("Ensure the DOM element being passed to m.route/m.mount/m.render is not undefined.");var o,a=[],i=ne(e),u=e===Ne;o=u||e===Ne.documentElement?He:e,u&&"html"!==t.tag&&(t={tag:"html",attrs:{},children:t}),Be[i]===n&&Q(o.childNodes),!0===r&&ve(e),Be[i]=K(o,null,n,n,t,Be[i],!1,0,null,n,a),f(a,function(e){e()})},d.trust=function(e){return e=new String(e),e.$trusted=!0,e},d.prop=function(e){return(null!=e&&(o(e)||r(e))||"undefined"!=typeof Promise&&e instanceof Promise)&&r(e.then)?me(e):re(e)};var Ke,_e=[],Fe=[],Ge=[],Pe=null,Ve=0,Qe=null,Ye=null;d.component=function(e){for(var t=new Array(arguments.length-1),n=1;n16)&&(Pe>0&&Oe(Pe),Pe=ke(ue,16)):(ue(),Pe=ke(function(){Pe=null},16))}finally{Ze=qe=!1}}},d.redraw.strategy=d.prop(),d.withAttr=function(e,t,n){return function(r){var o=(r=r||window.event).currentTarget||this,a=n||this,i=e in o?o[e]:o.getAttribute(e);t.call(a,i)}};var et,tt={pathname:"",hash:"#",search:"?"},nt=i,rt=!1;d.route=function(e,n,r,o){if(0===arguments.length)return We;if(3===arguments.length&&a(n)){nt=function(t){var o=We=ce(t);if(!se(e,r,o)){if(rt)throw new Error("Ensure the default route matches one of the routes defined in m.route");rt=!0,d.route(n,!0),rt=!1}};var i="hash"===d.route.mode?"onhashchange":"onpopstate";return t[i]=function(){var e=Te[d.route.mode];"pathname"===d.route.mode&&(e+=Te.search),We!==ce(e)&&nt(e)},Qe=fe,void t[i]()}if(e.addEventListener||e.attachEvent){var u="pathname"!==d.route.mode?Te.pathname:"";return e.href=u+tt[d.route.mode]+o.attrs.href,void(e.addEventListener?(e.removeEventListener("click",de),e.addEventListener("click",de)):(e.detachEvent("onclick",de),e.attachEvent("onclick",de)))}if(a(e)){Xe=We,We=e;var l,c=n||{},s=We.indexOf("?");l=s>-1?pe(We.slice(s+1)):{};for(var f in c)je.call(c,f)&&(l[f]=c[f]);var h,p=he(l);h=s>-1?We.slice(0,s):We,p&&(We=h+(-1===h.indexOf("?")?"?":"&")+p);var v=!0===(3===arguments.length?r:n)||Xe===We;if(t.history.pushState){var m=v?"replaceState":"pushState";Qe=fe,Ye=function(){try{t.history[m](null,Ne.title,tt[d.route.mode]+We)}catch(e){Te[d.route.mode]=We}},nt(tt[d.route.mode]+We)}else Te[d.route.mode]=We,nt(tt[d.route.mode]+We);Xe=null}},d.route.param=function(e){if(!et)throw new Error("You must call m.route(element, defaultRoute, routes) before calling m.route.param()");return e?et[e]:et},d.route.mode="search",d.route.buildQueryString=he,d.route.parseQueryString=pe,d.deferred=function(){var e=new ge;return e.promise=me(e.promise),e};var ot=1,at=2,it=3,ut=4;return d.deferred.onerror=function(e){if("[object Error]"===Ae.call(e)&&!/ Error/.test(e.constructor.toString()))throw Ie=0,e},d.sync=function(e){function t(e,t){return function(i){return o[e]=i,t||(a="reject"),0==--r&&(n.promise(o),n[a](o)),i}}var n=d.deferred(),r=e.length,o=[],a="resolve";return e.length>0?f(e,function(e,n){e.then(t(n,!0),t(n,!1))}):n.resolve([]),n.promise},d.request=function(e){!0!==e.background&&d.startComputation();var t,n,r,o=new ge;return e.dataType&&"jsonp"===e.dataType.toLowerCase()?(t=e.serialize=n=e.deserialize=ye,r=function(e){return e.responseText}):(t=e.serialize=e.serialize||JSON.stringify,n=e.deserialize=e.deserialize||JSON.parse,r=e.extract||function(e){return e.responseText.length||n!==JSON.parse?e.responseText:null}),e.method=(e.method||"GET").toUpperCase(),e.url=be(e.url,e.data),Ce(e,e.data,t),e.onload=e.onerror=function(t){try{t=t||event;var a=n(r(t.target,e));"load"===t.type?(e.unwrapSuccess&&(a=e.unwrapSuccess(a,t.target)),Se(a)&&e.type?f(a,function(t,n){a[n]=new e.type(t)}):e.type&&(a=new e.type(a)),o.resolve(a)):(e.unwrapError&&(a=e.unwrapError(a,t.target)),o.reject(a))}catch(e){o.reject(e),d.deferred.onerror(e)}finally{!0!==e.background&&d.endComputation()}},xe(e),o.promise=me(o.promise,e.initialValue),o.promise},d});
8 | //# sourceMappingURL=mithril.min.js.map
--------------------------------------------------------------------------------
/js/hm.js:
--------------------------------------------------------------------------------
1 | (function(){var h={},mt={},c={id:"04a27f0eb439061994965aa7c4992cf9",dm:["csm.lulua.net"],js:"tongji.baidu.com/hm-web/js/",etrk:[],cetrk:[],cptrk:[],icon:'',ctrk:[],vdur:1800000,age:31536000000,qiao:0,pt:0,spa:0,aet:'',hca:'655734ED2BB1D6CE',ab:'0',v:1};var s=void 0,t=!0,u=null,x=!1;mt.cookie={};mt.cookie.set=function(e,a,b){var k;b.C&&(k=new Date,k.setTime(k.getTime()+b.C));document.cookie=e+"="+a+(b.domain?"; domain="+b.domain:"")+(b.path?"; path="+b.path:"")+(k?"; expires="+k.toGMTString():"")+(b.dc?"; secure":"")};mt.cookie.get=function(e){return(e=RegExp("(^| )"+e+"=([^;]*)(;|$)").exec(document.cookie))?e[2]:u};
2 | mt.cookie.rb=function(e,a){try{var b="Hm_ck_"+ +new Date;mt.cookie.set(b,"42",{domain:e,path:a,C:s});var k="42"===mt.cookie.get(b)?"1":"0";mt.cookie.set(b,"",{domain:e,path:a,C:-1});return k}catch(d){return"0"}};mt.event={};mt.event.c=function(e,a,b,k){e.addEventListener?e.addEventListener(a,b,k||x):e.attachEvent&&e.attachEvent("on"+a,function(d){b.call(e,d)})};
3 | (function(){var e=mt.event;mt.lang={};mt.lang.i=function(a,b){return"[object "+b+"]"==={}.toString.call(a)};mt.lang.j=function(a){return mt.lang.i(a,"Function")};mt.lang.J=function(a){return mt.lang.i(a,"Object")};mt.lang.Wb=function(a){return mt.lang.i(a,"Number")&&isFinite(a)};mt.lang.Z=function(a){return mt.lang.i(a,"String")};mt.lang.isArray=function(a){return mt.lang.i(a,"Array")};mt.lang.n=function(a){return a.replace?a.replace(/'/g,"'0").replace(/\*/g,"'1").replace(/!/g,"'2"):a};mt.lang.trim=
4 | function(a){return a.replace(/^\s+|\s+$/g,"")};mt.lang.find=function(a,b,k){if(mt.lang.isArray(a)&&mt.lang.j(b))for(var d=a.length,f=0;f>>0).toString(2)).slice(-32)+(d+((f[1]|g[1])>>>0).toString(2)).slice(-32),2)};mt.lang.extend=function(a){for(var b=Array.prototype.slice.call(arguments,1),k=0;k"),d=document.body,a=k.length-1;0<=a;a--)if(-1"+d.join(">"):e,f.push(e)),d.unshift(encodeURIComponent(String(b.nodeName).toLowerCase())+(1"));return f};
11 | mt.d.Xa=function(b){return(b=mt.d.fa(b,t))&&b.length?String(b[0]):""};mt.d.Wa=function(b){return mt.d.fa(b,x)};mt.d.Ma=function(b){var a;for(a="A";(b=b.parentNode)&&1==b.nodeType;)if(b.tagName==a)return b;return u};mt.d.Pa=function(b){return 9===b.nodeType?b:b.ownerDocument||b.document};mt.d.Ua=function(b){var a={top:0,left:0};if(!b)return a;var d=mt.d.Pa(b).documentElement;"undefined"!==typeof b.getBoundingClientRect&&(a=b.getBoundingClientRect());return{top:a.top+(window.pageYOffset||d.scrollTop)-
12 | (d.clientTop||0),left:a.left+(window.pageXOffset||d.scrollLeft)-(d.clientLeft||0)}};mt.d.gc=function(b,a){if(b)for(var d=b.childNodes,f=0,g=d.length;fa?"0"+a:a}var b={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};return function(b){switch(typeof b){case "undefined":return"undefined";case "number":return isFinite(b)?String(b):"null";case "string":return e(b);case "boolean":return String(b);
21 | default:if(b===u)return"null";if(b instanceof Array){var d=["["],f=b.length,g,l,r;for(l=0;l(new Date).getTime())return e.substring(a+1)}}else if(mt.localStorage.Q())try{return mt.localStorage.g.load("csm.lulua.net"),mt.localStorage.g.getAttribute(e)}catch(k){}return u};
25 | mt.localStorage.remove=function(e){if(window.localStorage)window.localStorage.removeItem(e);else if(mt.localStorage.Q())try{mt.localStorage.g.load("csm.lulua.net"),mt.localStorage.g.removeAttribute(e),mt.localStorage.g.save("csm.lulua.net")}catch(a){}};mt.sessionStorage={};mt.sessionStorage.set=function(e,a){try{window.sessionStorage&&window.sessionStorage.setItem(e,a)}catch(b){}};
26 | mt.sessionStorage.get=function(e){try{return window.sessionStorage?window.sessionStorage.getItem(e):u}catch(a){return u}};mt.sessionStorage.remove=function(e){try{window.sessionStorage&&window.sessionStorage.removeItem(e)}catch(a){}};
27 | (function(){var e=mt.w;mt.A={};mt.A.log=function(a,b){var e=new Image,d="mini_tangram_log_"+Math.floor(2147483648*Math.random()).toString(36);window[d]=e;e.onload=function(){e.onload=u;e=window[d]=u;b&&b(a)};e.src=a};mt.A.get=function(a,b){return mt.A.wa({url:a,method:"GET",data:b.data,timeout:b.timeout,noCache:t,success:b.success,fail:b.fail})};mt.A.wa=function(a){function b(a){var b=[],d;for(d in a)a.hasOwnProperty(d)&&b.push(encodeURIComponent(d)+"="+encodeURIComponent(a[d]));return b.join("&")}
28 | function k(b){var d=a[b];if(d)if(q&&clearTimeout(q),"success"!==b)d&&d(m);else{var f;try{f=e.parse(m.responseText)}catch(g){d&&d(m);return}d&&d(m,f)}}a=a||{};var d=a.data;"object"===typeof d&&(d=b(a.data||{}));var f=a.url,g=(a.method||"GET").toUpperCase(),l=a.headers||{},r=a.timeout||0,p=a.noCache||x,n=a.withCredentials||x,m,q;try{a:if(window.XMLHttpRequest)m=new XMLHttpRequest;else{try{m=new ActiveXObject("Microsoft.XMLHTTP");break a}catch(v){}m=s}"GET"===g&&(d&&(f+=(0<=f.indexOf("?")?"&":"?")+d,
29 | d=u),p&&(f+=(0<=f.indexOf("?")?"&":"?")+"b"+ +new Date+"=1"));m.open(g,f,t);m.onreadystatechange=function(){if(4===m.readyState){var a=0;try{a=m.status}catch(b){k("fail");return}200<=a&&300>a||304===a||1223===a?k("success"):k("fail")}};for(var w in l)l.hasOwnProperty(w)&&m.setRequestHeader(w,l[w]);n&&(m.withCredentials=t);r&&(q=setTimeout(function(){m.onreadystatechange=function(){};m.abort();k("fail")},r));m.send(d)}catch(A){k("fail")}return m};return mt.A})();
30 | h.o={kb:"http://tongji.baidu.com/hm-web/welcome/ico",aa:"hm.baidu.com/hm.gif",xa:/^(tongji|hmcdn).baidu.com$/,Gb:"tongji.baidu.com",hb:"hmmd",ib:"hmpl",Jb:"utm_medium",gb:"hmkw",Lb:"utm_term",eb:"hmci",Ib:"utm_content",jb:"hmsr",Kb:"utm_source",fb:"hmcu",Hb:"utm_campaign",ka:0,B:Math.round(+new Date/1E3),protocol:"https:"===document.location.protocol?"https:":"http:",L:"https:",Da:6E5,bc:5E3,Ea:5,ca:1024,G:2147483647,ra:"hca cc cf ci ck cl cm cp cu cw ds vl ep et ja ln lo lt rnd si su v cv lv api sn r ww p u tt".split(" "),
31 | ga:t,Pb:{id:"data-hm-id",Tb:"data-hm-class",jc:"data-hm-xpath",content:"data-hm-content",hc:"data-hm-tag",link:"data-hm-link"},Rb:"data-hm-enabled",Qb:"data-hm-disabled",xb:"https://hmcdn.baidu.com/static/tongji/plugins/",na:["UrlChangeTracker"],Nb:{$b:0,ic:1,Xb:2},Yb:"https://fclog.baidu.com/log/ocpcagl?type=behavior&emd=euc"};
32 | (function(){var e={t:{},c:function(a,b){this.t[a]=this.t[a]||[];this.t[a].push(b)},k:function(a,b){this.t[a]=this.t[a]||[];for(var e=this.t[a].length,d=0;d
':''+a[0]+"")}}};h.s.c("pv-b",a.D);return a})();
37 | (function(){var e=mt.url,a=mt.cookie,b=mt.localStorage,k=mt.sessionStorage,d={getData:function(d){try{return a.get(d)||k.get(d)||b.get(d)}catch(e){}},setData:function(f,e,l){try{a.set(f,e,{domain:d.I(),path:d.U(),C:l}),l?b.set(f,e,l):k.set(f,e)}catch(r){}},removeData:function(e){try{a.set(e,"",{domain:d.I(),path:d.U(),C:-1}),k.remove(e),b.remove(e)}catch(g){}},I:function(){for(var a="csm.lulua.net",b=0,d=c.dm.length;br*p.split(">").length)for(p=0;p").length,k=0;k"));a&&(e.J(a)&&a.ba)&&a.ba(g)},zb:function(a,b){return function(e){(e.target||e.srcElement).setAttribute(a.P,e.clientX+":"+e.clientY);a&&a.N&&(b?a.N(b):a.N("#"+encodeURIComponent(this.id),e.type))}}};return h.Ia=k})();
41 | (function(){var e=mt.d,a=mt.event,b=h.S,k=h.Ia,d={P:"HM_fix",ua:function(){a.c(document,"click",k.Ha(d,c.etrk),t);if(!document.addEventListener)for(var f=b.H(c.etrk)||[],g=0;g")&&(0===l.indexOf("#")&&(l=l.substring(1)),(l=e.La(l))&&a.c(l,"click",k.zb(d),t))}},ba:function(a){for(var e=b.H(c.etrk)||[],k=0;kd.ca||(b+encodeURIComponent(g.join("!")+(g.length?"!":"")).length+(d.G+"").length>d.ca&&l.M(),g.push(a),
44 | (g.length>=d.Ea||/\*a\*/.test(a))&&l.M())}}},Na:function(b){var d=b.target||b.srcElement,f,m;k.mb?(m=Math.max(document.documentElement.scrollTop,document.body.scrollTop),f=Math.max(document.documentElement.scrollLeft,document.body.scrollLeft),f=b.clientX+f,m=b.clientY+m):(f=b.pageX,m=b.pageY);b=l.Ta(b,d,f,m);var q=window.innerWidth||document.documentElement.clientWidth||document.body.offsetWidth;switch(c.align){case 1:f-=q/2;break;case 2:f-=q}q=[];q.push(f);q.push(m);q.push(b.ub);q.push(b.vb);q.push(b.yb);
45 | q.push(a.n(b.wb));q.push(b.Mb);q.push(b.cb);(d="a"===(d.tagName||"").toLowerCase()?d:e.Ma(d))?(q.push("a"),q.push(a.n(encodeURIComponent(d.href)))):q.push("b");return q.join("*")},Ta:function(b,d,f,m){b=e.Xa(d);var q=0,g=0,w=0,l=0;if(d&&(q=d.offsetWidth||d.clientWidth,g=d.offsetHeight||d.clientHeight,l=e.Ua(d),w=l.left,l=l.top,a.j(d.getBBox)&&(g=d.getBBox(),q=g.width,g=g.height),"html"===(d.tagName||"").toLowerCase()))q=Math.max(q,d.clientWidth),g=Math.max(g,d.clientHeight);return{ub:Math.round(100*
46 | ((f-w)/q)),vb:Math.round(100*((m-l)/g)),yb:k.orientation,wb:b,Mb:q,cb:g}},M:function(){0!==g.length&&(h.b.a.et=2,h.b.a.ep=g.join("!"),h.b.m(),g=[])}};h.s.c("pv-b",l.ta);return l})();
47 | (function(){function e(){return function(){h.b.a.et=3;h.b.a.ep=h.T.Va()+","+h.T.Ra();h.b.a.hca=c.hca;h.b.m()}}function a(){clearTimeout(C);var b;w&&(b="visible"==document[w]);A&&(b=!document[A]);l="undefined"==typeof b?t:b;if((!g||!r)&&l&&p)v=t,m=+new Date;else if(g&&r&&(!l||!p))v=x,q+=+new Date-m;g=l;r=p;C=setTimeout(a,100)}function b(b){var a=document,d="";if(b in a)d=b;else for(var m=["webkit","ms","moz","o"],e=0;ea.length)){var d=a[1],e=a[4]||3;if(0d&&0e){n.O++;for(var f=(h.b.a.cv||"*").split("!"),g=f.length;gb.length?2:3;for(m.B-m.ka>c.vdur&&b.push(m.B);4Number(b)&&(this.da(),n.set(a,c.fc))},da:function(){for(var a=document.cookie.split(";"),b=0;be.length)&&(t=e.length);for(var n=0,r=new Array(t);n2&&void 0!==arguments[2]?arguments[2]:{},a=i.allOwnKeys,s=void 0!==a&&a;if(null!=t)if("object"!==e(t)&&(t=[t]),p(t))for(r=0,o=t.length;r0;)if(t===(n=r[o]).toLowerCase())return n;return null}var N="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,C=function(e){return!h(e)&&e!==N};var x,P=(x="undefined"!=typeof Uint8Array&&c(Uint8Array),function(e){return x&&e instanceof x}),k=l("HTMLFormElement"),U=function(e){var t=Object.prototype.hasOwnProperty;return function(e,n){return t.call(e,n)}}(),_=l("RegExp"),F=function(e,t){var n=Object.getOwnPropertyDescriptors(e),r={};T(n,(function(n,o){!1!==t(n,o,e)&&(r[o]=n)})),Object.defineProperties(e,r)},B="abcdefghijklmnopqrstuvwxyz",L="0123456789",D={DIGIT:L,ALPHA:B,ALPHA_DIGIT:B+B.toUpperCase()+L};var I=l("AsyncFunction"),q={isArray:p,isArrayBuffer:m,isBuffer:function(e){return null!==e&&!h(e)&&null!==e.constructor&&!h(e.constructor)&&v(e.constructor.isBuffer)&&e.constructor.isBuffer(e)},isFormData:function(e){var t;return e&&("function"==typeof FormData&&e instanceof FormData||v(e.append)&&("formdata"===(t=f(e))||"object"===t&&v(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&m(e.buffer)},isString:y,isNumber:b,isBoolean:function(e){return!0===e||!1===e},isObject:g,isPlainObject:w,isUndefined:h,isDate:E,isFile:O,isBlob:S,isRegExp:_,isFunction:v,isStream:function(e){return g(e)&&v(e.pipe)},isURLSearchParams:A,isTypedArray:P,isFileList:R,forEach:T,merge:function e(){for(var t=C(this)&&this||{},n=t.caseless,r={},o=function(t,o){var i=n&&j(r,o)||o;w(r[i])&&w(t)?r[i]=e(r[i],t):w(t)?r[i]=e({},t):p(t)?r[i]=t.slice():r[i]=t},i=0,a=arguments.length;i3&&void 0!==arguments[3]?arguments[3]:{},o=r.allOwnKeys;return T(t,(function(t,r){n&&v(t)?e[r]=a(t,n):e[r]=t}),{allOwnKeys:o}),e},trim:function(e){return e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")},stripBOM:function(e){return 65279===e.charCodeAt(0)&&(e=e.slice(1)),e},inherits:function(e,t,n,r){e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},toFlatObject:function(e,t,n,r){var o,i,a,s={};if(t=t||{},null==e)return t;do{for(i=(o=Object.getOwnPropertyNames(e)).length;i-- >0;)a=o[i],r&&!r(a,e,t)||s[a]||(t[a]=e[a],s[a]=!0);e=!1!==n&&c(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kindOf:f,kindOfTest:l,endsWith:function(e,t,n){e=String(e),(void 0===n||n>e.length)&&(n=e.length),n-=t.length;var r=e.indexOf(t,n);return-1!==r&&r===n},toArray:function(e){if(!e)return null;if(p(e))return e;var t=e.length;if(!b(t))return null;for(var n=new Array(t);t-- >0;)n[t]=e[t];return n},forEachEntry:function(e,t){for(var n,r=(e&&e[Symbol.iterator]).call(e);(n=r.next())&&!n.done;){var o=n.value;t.call(e,o[0],o[1])}},matchAll:function(e,t){for(var n,r=[];null!==(n=e.exec(t));)r.push(n);return r},isHTMLForm:k,hasOwnProperty:U,hasOwnProp:U,reduceDescriptors:F,freezeMethods:function(e){F(e,(function(t,n){if(v(e)&&-1!==["arguments","caller","callee"].indexOf(n))return!1;var r=e[n];v(r)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=function(){throw Error("Can not rewrite read-only method '"+n+"'")}))}))},toObjectSet:function(e,t){var n={},r=function(e){e.forEach((function(e){n[e]=!0}))};return p(e)?r(e):r(String(e).split(t)),n},toCamelCase:function(e){return e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(e,t,n){return t.toUpperCase()+n}))},noop:function(){},toFiniteNumber:function(e,t){return e=+e,Number.isFinite(e)?e:t},findKey:j,global:N,isContextDefined:C,ALPHABET:D,generateString:function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:16,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:D.ALPHA_DIGIT,n="",r=t.length;e--;)n+=t[Math.random()*r|0];return n},isSpecCompliantForm:function(e){return!!(e&&v(e.append)&&"FormData"===e[Symbol.toStringTag]&&e[Symbol.iterator])},toJSONObject:function(e){var t=new Array(10);return function e(n,r){if(g(n)){if(t.indexOf(n)>=0)return;if(!("toJSON"in n)){t[r]=n;var o=p(n)?[]:{};return T(n,(function(t,n){var i=e(t,r+1);!h(i)&&(o[n]=i)})),t[r]=void 0,o}}return n}(e,0)},isAsyncFn:I,isThenable:function(e){return e&&(g(e)||v(e))&&v(e.then)&&v(e.catch)}};function M(e,t,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o)}q.inherits(M,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:q.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var z=M.prototype,H={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach((function(e){H[e]={value:e}})),Object.defineProperties(M,H),Object.defineProperty(z,"isAxiosError",{value:!0}),M.from=function(e,t,n,r,o,i){var a=Object.create(z);return q.toFlatObject(e,a,(function(e){return e!==Error.prototype}),(function(e){return"isAxiosError"!==e})),M.call(a,e.message,t,n,r,o),a.cause=e,a.name=e.name,i&&Object.assign(a,i),a};function J(e){return q.isPlainObject(e)||q.isArray(e)}function W(e){return q.endsWith(e,"[]")?e.slice(0,-2):e}function K(e,t,n){return e?e.concat(t).map((function(e,t){return e=W(e),!n&&t?"["+e+"]":e})).join(n?".":""):t}var V=q.toFlatObject(q,{},null,(function(e){return/^is[A-Z]/.test(e)}));function G(t,n,r){if(!q.isObject(t))throw new TypeError("target must be an object");n=n||new FormData;var o=(r=q.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,t){return!q.isUndefined(t[e])}))).metaTokens,i=r.visitor||f,a=r.dots,s=r.indexes,u=(r.Blob||"undefined"!=typeof Blob&&Blob)&&q.isSpecCompliantForm(n);if(!q.isFunction(i))throw new TypeError("visitor must be a function");function c(e){if(null===e)return"";if(q.isDate(e))return e.toISOString();if(!u&&q.isBlob(e))throw new M("Blob is not supported. Use a Buffer instead.");return q.isArrayBuffer(e)||q.isTypedArray(e)?u&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function f(t,r,i){var u=t;if(t&&!i&&"object"===e(t))if(q.endsWith(r,"{}"))r=o?r:r.slice(0,-2),t=JSON.stringify(t);else if(q.isArray(t)&&function(e){return q.isArray(e)&&!e.some(J)}(t)||(q.isFileList(t)||q.endsWith(r,"[]"))&&(u=q.toArray(t)))return r=W(r),u.forEach((function(e,t){!q.isUndefined(e)&&null!==e&&n.append(!0===s?K([r],t,a):null===s?r:r+"[]",c(e))})),!1;return!!J(t)||(n.append(K(i,r,a),c(t)),!1)}var l=[],d=Object.assign(V,{defaultVisitor:f,convertValue:c,isVisitable:J});if(!q.isObject(t))throw new TypeError("data must be an object");return function e(t,r){if(!q.isUndefined(t)){if(-1!==l.indexOf(t))throw Error("Circular reference detected in "+r.join("."));l.push(t),q.forEach(t,(function(t,o){!0===(!(q.isUndefined(t)||null===t)&&i.call(n,t,q.isString(o)?o.trim():o,r,d))&&e(t,r?r.concat(o):[o])})),l.pop()}}(t),n}function $(e){var t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,(function(e){return t[e]}))}function X(e,t){this._pairs=[],e&&G(e,this,t)}var Q=X.prototype;function Z(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Y(e,t,n){if(!t)return e;var r,o=n&&n.encode||Z,i=n&&n.serialize;if(r=i?i(t,n):q.isURLSearchParams(t)?t.toString():new X(t,n).toString(o)){var a=e.indexOf("#");-1!==a&&(e=e.slice(0,a)),e+=(-1===e.indexOf("?")?"?":"&")+r}return e}Q.append=function(e,t){this._pairs.push([e,t])},Q.toString=function(e){var t=e?function(t){return e.call(this,t,$)}:$;return this._pairs.map((function(e){return t(e[0])+"="+t(e[1])}),"").join("&")};var ee,te=function(){function e(){t(this,e),this.handlers=[]}return r(e,[{key:"use",value:function(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1}},{key:"eject",value:function(e){this.handlers[e]&&(this.handlers[e]=null)}},{key:"clear",value:function(){this.handlers&&(this.handlers=[])}},{key:"forEach",value:function(e){q.forEach(this.handlers,(function(t){null!==t&&e(t)}))}}]),e}(),ne={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},re={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:X,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},isStandardBrowserEnv:("undefined"==typeof navigator||"ReactNative"!==(ee=navigator.product)&&"NativeScript"!==ee&&"NS"!==ee)&&"undefined"!=typeof window&&"undefined"!=typeof document,isStandardBrowserWebWorkerEnv:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,protocols:["http","https","file","blob","url","data"]};function oe(e){function t(e,n,r,o){var i=e[o++],a=Number.isFinite(+i),s=o>=e.length;return i=!i&&q.isArray(r)?r.length:i,s?(q.hasOwnProp(r,i)?r[i]=[r[i],n]:r[i]=n,!a):(r[i]&&q.isObject(r[i])||(r[i]=[]),t(e,n,r[i],o)&&q.isArray(r[i])&&(r[i]=function(e){var t,n,r={},o=Object.keys(e),i=o.length;for(t=0;t-1,i=q.isObject(e);if(i&&q.isHTMLForm(e)&&(e=new FormData(e)),q.isFormData(e))return o&&o?JSON.stringify(oe(e)):e;if(q.isArrayBuffer(e)||q.isBuffer(e)||q.isStream(e)||q.isFile(e)||q.isBlob(e))return e;if(q.isArrayBufferView(e))return e.buffer;if(q.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();if(i){if(r.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return G(e,new re.classes.URLSearchParams,Object.assign({visitor:function(e,t,n,r){return re.isNode&&q.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)}},t))}(e,this.formSerializer).toString();if((n=q.isFileList(e))||r.indexOf("multipart/form-data")>-1){var a=this.env&&this.env.FormData;return G(n?{"files[]":e}:e,a&&new a,this.formSerializer)}}return i||o?(t.setContentType("application/json",!1),function(e,t,n){if(q.isString(e))try{return(t||JSON.parse)(e),q.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(n||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){var t=this.transitional||ae.transitional,n=t&&t.forcedJSONParsing,r="json"===this.responseType;if(e&&q.isString(e)&&(n&&!this.responseType||r)){var o=!(t&&t.silentJSONParsing)&&r;try{return JSON.parse(e)}catch(e){if(o){if("SyntaxError"===e.name)throw M.from(e,M.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:re.classes.FormData,Blob:re.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};q.forEach(["delete","get","head"],(function(e){ae.headers[e]={}})),q.forEach(["post","put","patch"],(function(e){ae.headers[e]=q.merge(ie)}));var se=ae,ue=q.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),ce=Symbol("internals");function fe(e){return e&&String(e).trim().toLowerCase()}function le(e){return!1===e||null==e?e:q.isArray(e)?e.map(le):String(e)}function de(e,t,n,r,o){return q.isFunction(r)?r.call(this,t,n):(o&&(t=n),q.isString(t)?q.isString(r)?-1!==t.indexOf(r):q.isRegExp(r)?r.test(t):void 0:void 0)}var pe=function(e,n){function i(e){t(this,i),e&&this.set(e)}return r(i,[{key:"set",value:function(e,t,n){var r=this;function o(e,t,n){var o=fe(t);if(!o)throw new Error("header name must be a non-empty string");var i=q.findKey(r,o);(!i||void 0===r[i]||!0===n||void 0===n&&!1!==r[i])&&(r[i||t]=le(e))}var i,a,s,u,c,f=function(e,t){return q.forEach(e,(function(e,n){return o(e,n,t)}))};return q.isPlainObject(e)||e instanceof this.constructor?f(e,t):q.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim())?f((c={},(i=e)&&i.split("\n").forEach((function(e){u=e.indexOf(":"),a=e.substring(0,u).trim().toLowerCase(),s=e.substring(u+1).trim(),!a||c[a]&&ue[a]||("set-cookie"===a?c[a]?c[a].push(s):c[a]=[s]:c[a]=c[a]?c[a]+", "+s:s)})),c),t):null!=e&&o(t,e,n),this}},{key:"get",value:function(e,t){if(e=fe(e)){var n=q.findKey(this,e);if(n){var r=this[n];if(!t)return r;if(!0===t)return function(e){for(var t,n=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;t=r.exec(e);)n[t[1]]=t[2];return n}(r);if(q.isFunction(t))return t.call(this,r,n);if(q.isRegExp(t))return t.exec(r);throw new TypeError("parser must be boolean|regexp|function")}}}},{key:"has",value:function(e,t){if(e=fe(e)){var n=q.findKey(this,e);return!(!n||void 0===this[n]||t&&!de(0,this[n],n,t))}return!1}},{key:"delete",value:function(e,t){var n=this,r=!1;function o(e){if(e=fe(e)){var o=q.findKey(n,e);!o||t&&!de(0,n[o],o,t)||(delete n[o],r=!0)}}return q.isArray(e)?e.forEach(o):o(e),r}},{key:"clear",value:function(e){for(var t=Object.keys(this),n=t.length,r=!1;n--;){var o=t[n];e&&!de(0,this[o],o,e,!0)||(delete this[o],r=!0)}return r}},{key:"normalize",value:function(e){var t=this,n={};return q.forEach(this,(function(r,o){var i=q.findKey(n,o);if(i)return t[i]=le(r),void delete t[o];var a=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(function(e,t,n){return t.toUpperCase()+n}))}(o):String(o).trim();a!==o&&delete t[o],t[a]=le(r),n[a]=!0})),this}},{key:"concat",value:function(){for(var e,t=arguments.length,n=new Array(t),r=0;r1?n-1:0),o=1;o0;){var a=o[i],s=n[a];if(s){var u=t[a],c=void 0===u||s(u,a,t);if(!0!==c)throw new M("option "+a+" must be "+c,M.ERR_BAD_OPTION_VALUE)}else if(!0!==r)throw new M("Unknown option "+a,M.ERR_BAD_OPTION)}},validators:Ce},ke=Pe.validators,Ue=function(){function e(n){t(this,e),this.defaults=n,this.interceptors={request:new te,response:new te}}return r(e,[{key:"request",value:function(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{};var n,r=t=je(this.defaults,t),o=r.transitional,i=r.paramsSerializer,a=r.headers;void 0!==o&&Pe.assertOptions(o,{silentJSONParsing:ke.transitional(ke.boolean),forcedJSONParsing:ke.transitional(ke.boolean),clarifyTimeoutError:ke.transitional(ke.boolean)},!1),null!=i&&(q.isFunction(i)?t.paramsSerializer={serialize:i}:Pe.assertOptions(i,{encode:ke.function,serialize:ke.function},!0)),t.method=(t.method||this.defaults.method||"get").toLowerCase(),(n=a&&q.merge(a.common,a[t.method]))&&q.forEach(["delete","get","head","post","put","patch","common"],(function(e){delete a[e]})),t.headers=he.concat(n,a);var s=[],u=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(u=u&&e.synchronous,s.unshift(e.fulfilled,e.rejected))}));var c,f=[];this.interceptors.response.forEach((function(e){f.push(e.fulfilled,e.rejected)}));var l,d=0;if(!u){var p=[Ae.bind(this),void 0];for(p.unshift.apply(p,s),p.push.apply(p,f),l=p.length,c=Promise.resolve(t);d0;)o._listeners[t](e);o._listeners=null}})),this.promise.then=function(e){var t,n=new Promise((function(e){o.subscribe(e),t=e})).then(e);return n.cancel=function(){o.unsubscribe(t)},n},n((function(e,t,n){o.reason||(o.reason=new ve(e,t,n),r(o.reason))}))}return r(e,[{key:"throwIfRequested",value:function(){if(this.reason)throw this.reason}},{key:"subscribe",value:function(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}},{key:"unsubscribe",value:function(e){if(this._listeners){var t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}}}],[{key:"source",value:function(){var t;return{token:new e((function(e){t=e})),cancel:t}}}]),e}();var Be={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Be).forEach((function(e){var t=o(e,2),n=t[0],r=t[1];Be[r]=n}));var Le=Be;var De=function e(t){var n=new _e(t),r=a(_e.prototype.request,n);return q.extend(r,_e.prototype,n,{allOwnKeys:!0}),q.extend(r,n,null,{allOwnKeys:!0}),r.create=function(n){return e(je(t,n))},r}(se);return De.Axios=_e,De.CanceledError=ve,De.CancelToken=Fe,De.isCancel=ye,De.VERSION=Ne,De.toFormData=G,De.AxiosError=M,De.Cancel=De.CanceledError,De.all=function(e){return Promise.all(e)},De.spread=function(e){return function(t){return e.apply(null,t)}},De.isAxiosError=function(e){return q.isObject(e)&&!0===e.isAxiosError},De.mergeConfig=je,De.AxiosHeaders=he,De.formToJSON=function(e){return oe(q.isHTMLForm(e)?new FormData(e):e)},De.HttpStatusCode=Le,De.default=De,De}));
2 | //# sourceMappingURL=axios.min.js.map
3 |
--------------------------------------------------------------------------------
/js/bootstrap.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * Bootstrap v3.3.7 (http://getbootstrap.com)
3 | * Copyright 2011-2016 Twitter, Inc.
4 | * Licensed under the MIT license
5 | */
6 | if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(a){"use strict";var b=a.fn.jquery.split(" ")[0].split(".");if(b[0]<2&&b[1]<9||1==b[0]&&9==b[1]&&b[2]<1||b[0]>3)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 4")}(jQuery),+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]};return!1}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one("bsTransitionEnd",function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b(),a.support.transition&&(a.event.special.bsTransitionEnd={bindType:a.support.transition.end,delegateType:a.support.transition.end,handle:function(b){if(a(b.target).is(this))return b.handleObj.handler.apply(this,arguments)}})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var c=a(this),e=c.data("bs.alert");e||c.data("bs.alert",e=new d(this)),"string"==typeof b&&e[b].call(c)})}var c='[data-dismiss="alert"]',d=function(b){a(b).on("click",c,this.close)};d.VERSION="3.3.7",d.TRANSITION_DURATION=150,d.prototype.close=function(b){function c(){g.detach().trigger("closed.bs.alert").remove()}var e=a(this),f=e.attr("data-target");f||(f=e.attr("href"),f=f&&f.replace(/.*(?=#[^\s]*$)/,""));var g=a("#"===f?[]:f);b&&b.preventDefault(),g.length||(g=e.closest(".alert")),g.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(g.removeClass("in"),a.support.transition&&g.hasClass("fade")?g.one("bsTransitionEnd",c).emulateTransitionEnd(d.TRANSITION_DURATION):c())};var e=a.fn.alert;a.fn.alert=b,a.fn.alert.Constructor=d,a.fn.alert.noConflict=function(){return a.fn.alert=e,this},a(document).on("click.bs.alert.data-api",c,d.prototype.close)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof b&&b;e||d.data("bs.button",e=new c(this,f)),"toggle"==b?e.toggle():b&&e.setState(b)})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.isLoading=!1};c.VERSION="3.3.7",c.DEFAULTS={loadingText:"loading..."},c.prototype.setState=function(b){var c="disabled",d=this.$element,e=d.is("input")?"val":"html",f=d.data();b+="Text",null==f.resetText&&d.data("resetText",d[e]()),setTimeout(a.proxy(function(){d[e](null==f[b]?this.options[b]:f[b]),"loadingText"==b?(this.isLoading=!0,d.addClass(c).attr(c,c).prop(c,!0)):this.isLoading&&(this.isLoading=!1,d.removeClass(c).removeAttr(c).prop(c,!1))},this),0)},c.prototype.toggle=function(){var a=!0,b=this.$element.closest('[data-toggle="buttons"]');if(b.length){var c=this.$element.find("input");"radio"==c.prop("type")?(c.prop("checked")&&(a=!1),b.find(".active").removeClass("active"),this.$element.addClass("active")):"checkbox"==c.prop("type")&&(c.prop("checked")!==this.$element.hasClass("active")&&(a=!1),this.$element.toggleClass("active")),c.prop("checked",this.$element.hasClass("active")),a&&c.trigger("change")}else this.$element.attr("aria-pressed",!this.$element.hasClass("active")),this.$element.toggleClass("active")};var d=a.fn.button;a.fn.button=b,a.fn.button.Constructor=c,a.fn.button.noConflict=function(){return a.fn.button=d,this},a(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(c){var d=a(c.target).closest(".btn");b.call(d,"toggle"),a(c.target).is('input[type="radio"], input[type="checkbox"]')||(c.preventDefault(),d.is("input,button")?d.trigger("focus"):d.find("input:visible,button:visible").first().trigger("focus"))}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(b){a(b.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(b.type))})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b),g="string"==typeof b?b:f.slide;e||d.data("bs.carousel",e=new c(this,f)),"number"==typeof b?e.to(b):g?e[g]():f.interval&&e.pause().cycle()})}var c=function(b,c){this.$element=a(b),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=null,this.sliding=null,this.interval=null,this.$active=null,this.$items=null,this.options.keyboard&&this.$element.on("keydown.bs.carousel",a.proxy(this.keydown,this)),"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",a.proxy(this.pause,this)).on("mouseleave.bs.carousel",a.proxy(this.cycle,this))};c.VERSION="3.3.7",c.TRANSITION_DURATION=600,c.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0},c.prototype.keydown=function(a){if(!/input|textarea/i.test(a.target.tagName)){switch(a.which){case 37:this.prev();break;case 39:this.next();break;default:return}a.preventDefault()}},c.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},c.prototype.getItemIndex=function(a){return this.$items=a.parent().children(".item"),this.$items.index(a||this.$active)},c.prototype.getItemForDirection=function(a,b){var c=this.getItemIndex(b),d="prev"==a&&0===c||"next"==a&&c==this.$items.length-1;if(d&&!this.options.wrap)return b;var e="prev"==a?-1:1,f=(c+e)%this.$items.length;return this.$items.eq(f)},c.prototype.to=function(a){var b=this,c=this.getItemIndex(this.$active=this.$element.find(".item.active"));if(!(a>this.$items.length-1||a<0))return this.sliding?this.$element.one("slid.bs.carousel",function(){b.to(a)}):c==a?this.pause().cycle():this.slide(a>c?"next":"prev",this.$items.eq(a))},c.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},c.prototype.next=function(){if(!this.sliding)return this.slide("next")},c.prototype.prev=function(){if(!this.sliding)return this.slide("prev")},c.prototype.slide=function(b,d){var e=this.$element.find(".item.active"),f=d||this.getItemForDirection(b,e),g=this.interval,h="next"==b?"left":"right",i=this;if(f.hasClass("active"))return this.sliding=!1;var j=f[0],k=a.Event("slide.bs.carousel",{relatedTarget:j,direction:h});if(this.$element.trigger(k),!k.isDefaultPrevented()){if(this.sliding=!0,g&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var l=a(this.$indicators.children()[this.getItemIndex(f)]);l&&l.addClass("active")}var m=a.Event("slid.bs.carousel",{relatedTarget:j,direction:h});return a.support.transition&&this.$element.hasClass("slide")?(f.addClass(b),f[0].offsetWidth,e.addClass(h),f.addClass(h),e.one("bsTransitionEnd",function(){f.removeClass([b,h].join(" ")).addClass("active"),e.removeClass(["active",h].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger(m)},0)}).emulateTransitionEnd(c.TRANSITION_DURATION)):(e.removeClass("active"),f.addClass("active"),this.sliding=!1,this.$element.trigger(m)),g&&this.cycle(),this}};var d=a.fn.carousel;a.fn.carousel=b,a.fn.carousel.Constructor=c,a.fn.carousel.noConflict=function(){return a.fn.carousel=d,this};var e=function(c){var d,e=a(this),f=a(e.attr("data-target")||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""));if(f.hasClass("carousel")){var g=a.extend({},f.data(),e.data()),h=e.attr("data-slide-to");h&&(g.interval=!1),b.call(f,g),h&&f.data("bs.carousel").to(h),c.preventDefault()}};a(document).on("click.bs.carousel.data-api","[data-slide]",e).on("click.bs.carousel.data-api","[data-slide-to]",e),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var c=a(this);b.call(c,c.data())})})}(jQuery),+function(a){"use strict";function b(b){var c,d=b.attr("data-target")||(c=b.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,"");return a(d)}function c(b){return this.each(function(){var c=a(this),e=c.data("bs.collapse"),f=a.extend({},d.DEFAULTS,c.data(),"object"==typeof b&&b);!e&&f.toggle&&/show|hide/.test(b)&&(f.toggle=!1),e||c.data("bs.collapse",e=new d(this,f)),"string"==typeof b&&e[b]()})}var d=function(b,c){this.$element=a(b),this.options=a.extend({},d.DEFAULTS,c),this.$trigger=a('[data-toggle="collapse"][href="#'+b.id+'"],[data-toggle="collapse"][data-target="#'+b.id+'"]'),this.transitioning=null,this.options.parent?this.$parent=this.getParent():this.addAriaAndCollapsedClass(this.$element,this.$trigger),this.options.toggle&&this.toggle()};d.VERSION="3.3.7",d.TRANSITION_DURATION=350,d.DEFAULTS={toggle:!0},d.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},d.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var b,e=this.$parent&&this.$parent.children(".panel").children(".in, .collapsing");if(!(e&&e.length&&(b=e.data("bs.collapse"),b&&b.transitioning))){var f=a.Event("show.bs.collapse");if(this.$element.trigger(f),!f.isDefaultPrevented()){e&&e.length&&(c.call(e,"hide"),b||e.data("bs.collapse",null));var g=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[g](0).attr("aria-expanded",!0),this.$trigger.removeClass("collapsed").attr("aria-expanded",!0),this.transitioning=1;var h=function(){this.$element.removeClass("collapsing").addClass("collapse in")[g](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return h.call(this);var i=a.camelCase(["scroll",g].join("-"));this.$element.one("bsTransitionEnd",a.proxy(h,this)).emulateTransitionEnd(d.TRANSITION_DURATION)[g](this.$element[0][i])}}}},d.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded",!1),this.$trigger.addClass("collapsed").attr("aria-expanded",!1),this.transitioning=1;var e=function(){this.transitioning=0,this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")};return a.support.transition?void this.$element[c](0).one("bsTransitionEnd",a.proxy(e,this)).emulateTransitionEnd(d.TRANSITION_DURATION):e.call(this)}}},d.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()},d.prototype.getParent=function(){return a(this.options.parent).find('[data-toggle="collapse"][data-parent="'+this.options.parent+'"]').each(a.proxy(function(c,d){var e=a(d);this.addAriaAndCollapsedClass(b(e),e)},this)).end()},d.prototype.addAriaAndCollapsedClass=function(a,b){var c=a.hasClass("in");a.attr("aria-expanded",c),b.toggleClass("collapsed",!c).attr("aria-expanded",c)};var e=a.fn.collapse;a.fn.collapse=c,a.fn.collapse.Constructor=d,a.fn.collapse.noConflict=function(){return a.fn.collapse=e,this},a(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(d){var e=a(this);e.attr("data-target")||d.preventDefault();var f=b(e),g=f.data("bs.collapse"),h=g?"toggle":e.data();c.call(f,h)})}(jQuery),+function(a){"use strict";function b(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#[A-Za-z]/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}function c(c){c&&3===c.which||(a(e).remove(),a(f).each(function(){var d=a(this),e=b(d),f={relatedTarget:this};e.hasClass("open")&&(c&&"click"==c.type&&/input|textarea/i.test(c.target.tagName)&&a.contains(e[0],c.target)||(e.trigger(c=a.Event("hide.bs.dropdown",f)),c.isDefaultPrevented()||(d.attr("aria-expanded","false"),e.removeClass("open").trigger(a.Event("hidden.bs.dropdown",f)))))}))}function d(b){return this.each(function(){var c=a(this),d=c.data("bs.dropdown");d||c.data("bs.dropdown",d=new g(this)),"string"==typeof b&&d[b].call(c)})}var e=".dropdown-backdrop",f='[data-toggle="dropdown"]',g=function(b){a(b).on("click.bs.dropdown",this.toggle)};g.VERSION="3.3.7",g.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=b(e),g=f.hasClass("open");if(c(),!g){"ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(a(this)).on("click",c);var h={relatedTarget:this};if(f.trigger(d=a.Event("show.bs.dropdown",h)),d.isDefaultPrevented())return;e.trigger("focus").attr("aria-expanded","true"),f.toggleClass("open").trigger(a.Event("shown.bs.dropdown",h))}return!1}},g.prototype.keydown=function(c){if(/(38|40|27|32)/.test(c.which)&&!/input|textarea/i.test(c.target.tagName)){var d=a(this);if(c.preventDefault(),c.stopPropagation(),!d.is(".disabled, :disabled")){var e=b(d),g=e.hasClass("open");if(!g&&27!=c.which||g&&27==c.which)return 27==c.which&&e.find(f).trigger("focus"),d.trigger("click");var h=" li:not(.disabled):visible a",i=e.find(".dropdown-menu"+h);if(i.length){var j=i.index(c.target);38==c.which&&j>0&&j--,40==c.which&&jdocument.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&a?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!a?this.scrollbarWidth:""})},c.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})},c.prototype.checkScrollbar=function(){var a=window.innerWidth;if(!a){var b=document.documentElement.getBoundingClientRect();a=b.right-Math.abs(b.left)}this.bodyIsOverflowing=document.body.clientWidth ',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}},c.prototype.init=function(b,c,d){if(this.enabled=!0,this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.$viewport=this.options.viewport&&a(a.isFunction(this.options.viewport)?this.options.viewport.call(this,this.$element):this.options.viewport.selector||this.options.viewport),this.inState={click:!1,hover:!1,focus:!1},this.$element[0]instanceof document.constructor&&!this.options.selector)throw new Error("`selector` option must be specified when initializing "+this.type+" on the window.document object!");for(var e=this.options.trigger.split(" "),f=e.length;f--;){var g=e[f];if("click"==g)this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this));else if("manual"!=g){var h="hover"==g?"mouseenter":"focusin",i="hover"==g?"mouseleave":"focusout";this.$element.on(h+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,a.proxy(this.leave,this))}}this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.getOptions=function(b){return b=a.extend({},this.getDefaults(),this.$element.data(),b),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},c.prototype.getDelegateOptions=function(){var b={},c=this.getDefaults();return this._options&&a.each(this._options,function(a,d){c[a]!=d&&(b[a]=d)}),b},c.prototype.enter=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusin"==b.type?"focus":"hover"]=!0),c.tip().hasClass("in")||"in"==c.hoverState?void(c.hoverState="in"):(clearTimeout(c.timeout),c.hoverState="in",c.options.delay&&c.options.delay.show?void(c.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show)):c.show())},c.prototype.isInStateTrue=function(){for(var a in this.inState)if(this.inState[a])return!0;return!1},c.prototype.leave=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);if(c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusout"==b.type?"focus":"hover"]=!1),!c.isInStateTrue())return clearTimeout(c.timeout),c.hoverState="out",c.options.delay&&c.options.delay.hide?void(c.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide)):c.hide()},c.prototype.show=function(){var b=a.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(b);var d=a.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]);if(b.isDefaultPrevented()||!d)return;var e=this,f=this.tip(),g=this.getUID(this.type);this.setContent(),f.attr("id",g),this.$element.attr("aria-describedby",g),this.options.animation&&f.addClass("fade");var h="function"==typeof this.options.placement?this.options.placement.call(this,f[0],this.$element[0]):this.options.placement,i=/\s?auto?\s?/i,j=i.test(h);j&&(h=h.replace(i,"")||"top"),f.detach().css({top:0,left:0,display:"block"}).addClass(h).data("bs."+this.type,this),this.options.container?f.appendTo(this.options.container):f.insertAfter(this.$element),this.$element.trigger("inserted.bs."+this.type);var k=this.getPosition(),l=f[0].offsetWidth,m=f[0].offsetHeight;if(j){var n=h,o=this.getPosition(this.$viewport);h="bottom"==h&&k.bottom+m>o.bottom?"top":"top"==h&&k.top-mo.width?"left":"left"==h&&k.left-lg.top+g.height&&(e.top=g.top+g.height-i)}else{var j=b.left-f,k=b.left+f+c;jg.right&&(e.left=g.left+g.width-k)}return e},c.prototype.getTitle=function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||("function"==typeof c.title?c.title.call(b[0]):c.title)},c.prototype.getUID=function(a){do a+=~~(1e6*Math.random());while(document.getElementById(a));return a},c.prototype.tip=function(){if(!this.$tip&&(this.$tip=a(this.options.template),1!=this.$tip.length))throw new Error(this.type+" `template` option must consist of exactly 1 top-level element!");return this.$tip},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},c.prototype.enable=function(){this.enabled=!0},c.prototype.disable=function(){this.enabled=!1},c.prototype.toggleEnabled=function(){this.enabled=!this.enabled},c.prototype.toggle=function(b){var c=this;b&&(c=a(b.currentTarget).data("bs."+this.type),c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c))),b?(c.inState.click=!c.inState.click,c.isInStateTrue()?c.enter(c):c.leave(c)):c.tip().hasClass("in")?c.leave(c):c.enter(c)},c.prototype.destroy=function(){var a=this;clearTimeout(this.timeout),this.hide(function(){a.$element.off("."+a.type).removeData("bs."+a.type),a.$tip&&a.$tip.detach(),a.$tip=null,a.$arrow=null,a.$viewport=null,a.$element=null})};var d=a.fn.tooltip;a.fn.tooltip=b,a.fn.tooltip.Constructor=c,a.fn.tooltip.noConflict=function(){return a.fn.tooltip=d,this}}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof b&&b;!e&&/destroy|hide/.test(b)||(e||d.data("bs.popover",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.init("popover",a,b)};if(!a.fn.tooltip)throw new Error("Popover requires tooltip.js");c.VERSION="3.3.7",c.DEFAULTS=a.extend({},a.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:''}),c.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),c.prototype.constructor=c,c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content").children().detach().end()[this.options.html?"string"==typeof c?"html":"append":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},c.prototype.hasContent=function(){return this.getTitle()||this.getContent()},c.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};var d=a.fn.popover;a.fn.popover=b,a.fn.popover.Constructor=c,a.fn.popover.noConflict=function(){return a.fn.popover=d,this}}(jQuery),+function(a){"use strict";function b(c,d){this.$body=a(document.body),this.$scrollElement=a(a(c).is(document.body)?window:c),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",a.proxy(this.process,this)),this.refresh(),this.process()}function c(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})}b.VERSION="3.3.7",b.DEFAULTS={offset:10},b.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},b.prototype.refresh=function(){var b=this,c="offset",d=0;this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight(),a.isWindow(this.$scrollElement[0])||(c="position",d=this.$scrollElement.scrollTop()),this.$body.find(this.selector).map(function(){var b=a(this),e=b.data("target")||b.attr("href"),f=/^#./.test(e)&&a(e);return f&&f.length&&f.is(":visible")&&[[f[c]().top+d,e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){b.offsets.push(this[0]),b.targets.push(this[1])})},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.getScrollHeight(),d=this.options.offset+c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(this.scrollHeight!=c&&this.refresh(),b>=d)return g!=(a=f[f.length-1])&&this.activate(a);if(g&&b=e[a]&&(void 0===e[a+1]||b .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),b.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),h?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu").length&&b.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),e&&e()}var g=d.find("> .active"),h=e&&a.support.transition&&(g.length&&g.hasClass("fade")||!!d.find("> .fade").length);g.length&&h?g.one("bsTransitionEnd",f).emulateTransitionEnd(c.TRANSITION_DURATION):f(),g.removeClass("in")};var d=a.fn.tab;a.fn.tab=b,a.fn.tab.Constructor=c,a.fn.tab.noConflict=function(){return a.fn.tab=d,this};var e=function(c){c.preventDefault(),b.call(a(this),"show")};a(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',e).on("click.bs.tab.data-api",'[data-toggle="pill"]',e)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof b&&b;e||d.data("bs.affix",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.options=a.extend({},c.DEFAULTS,d),this.$target=a(this.options.target).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(b),this.affixed=null,this.unpin=null,this.pinnedOffset=null,this.checkPosition()};c.VERSION="3.3.7",c.RESET="affix affix-top affix-bottom",c.DEFAULTS={offset:0,target:window},c.prototype.getState=function(a,b,c,d){var e=this.$target.scrollTop(),f=this.$element.offset(),g=this.$target.height();if(null!=c&&"top"==this.affixed)return e=a-d&&"bottom"},c.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(c.RESET).addClass("affix");var a=this.$target.scrollTop(),b=this.$element.offset();return this.pinnedOffset=b.top-a},c.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},c.prototype.checkPosition=function(){if(this.$element.is(":visible")){var b=this.$element.height(),d=this.options.offset,e=d.top,f=d.bottom,g=Math.max(a(document).height(),a(document.body).height());"object"!=typeof d&&(f=e=d),"function"==typeof e&&(e=d.top(this.$element)),"function"==typeof f&&(f=d.bottom(this.$element));var h=this.getState(g,b,e,f);if(this.affixed!=h){null!=this.unpin&&this.$element.css("top","");var i="affix"+(h?"-"+h:""),j=a.Event(i+".bs.affix");if(this.$element.trigger(j),j.isDefaultPrevented())return;this.affixed=h,this.unpin="bottom"==h?this.getPinnedOffset():null,this.$element.removeClass(c.RESET).addClass(i).trigger(i.replace("affix","affixed")+".bs.affix")}"bottom"==h&&this.$element.offset({top:g-b-f})}};var d=a.fn.affix;a.fn.affix=b,a.fn.affix.Constructor=c,a.fn.affix.noConflict=function(){return a.fn.affix=d,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var c=a(this),d=c.data();d.offset=d.offset||{},null!=d.offsetBottom&&(d.offset.bottom=d.offsetBottom),null!=d.offsetTop&&(d.offset.top=d.offsetTop),b.call(c,d)})})}(jQuery);
--------------------------------------------------------------------------------