diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f2ea25f --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +.eslintrc.json +.eslintrc.js +.prettierrc \ No newline at end of file diff --git a/ChromeExtension/background/background.js b/ChromeExtension/background/background.js new file mode 100644 index 0000000..f274364 --- /dev/null +++ b/ChromeExtension/background/background.js @@ -0,0 +1,23 @@ +chrome.tabs.onUpdated.addListener((tabId, changeInfo, tab) => { + if (changeInfo.status === "complete" && tab.status === "complete" && tab.url) { + chrome.tabs.sendMessage(tabId, { + type: "CHECK_URL", + }); + } + chrome.tabs.sendMessage(tabId, { + type: "UPDATE_REPO_LAYOUT", + }); +}); + +chrome.runtime.onMessage.addListener(handleMessage); + +/** + * Function name: handleMessage + * @param {string} msg + * Responds to changes in content script + */ +function handleMessage(msg) { + if (msg.type === "OPEN_COMPLETE_OVERVIEW") { + chrome.tabs.create({ url: chrome.runtime.getURL("content/overview.html") }); + } +} diff --git a/ChromeExtension/content/constants.js b/ChromeExtension/content/constants.js new file mode 100644 index 0000000..6326a4e --- /dev/null +++ b/ChromeExtension/content/constants.js @@ -0,0 +1,40 @@ +const constantStrings = { + NOW_EDITING_FILE_MESSAGE: + "You are now editing the file, make your changes below and press the green button to continue", + PULL_REQUEST_CREATED_MESSAGE: + "The pull request was created successfully and will be reviewed shortly", + COMMENT_ADDED_MESSAGE: + "The mentioned user will receive a notification and may help you work on the pull request.", + FILENAME_TOOLTIP: "This is the file name, changing it will create a new file with the new name.", + PROPOSE_CHANGES_TOOLTIP: + "By clicking the Propose changes button you will start the pull request submission process. You will have the chance to check your changes before finalizing it.", + DIRECTLY_COMMIT_CHANGES_TOOLTIP: + "By clicking the Commit Changes button the changes will automatically be pushed to the repo", + PULL_REQUEST_TITLE_TOOLTIP: + "This is the title of the pull request. Give a brief description of the change. Be short and objective.", + PULL_REQUEST_DESCRIPTION_TOOLTIP: + "Add a more detailed description of the pull request if needed. Here you can present your arguments and reasoning that lead to change.", + PULL_REQUEST_DETAILED_DESCRIPTION_TOOLTIP: + "You can add a more detailed description of the pull request here if needed.", + PULL_REQUEST_ORIGIN_AND_DESTINATION_TOOLTIP: + "By clicking this button you will create the pull request to allow others to view your changes and accept them into the repository.", + CREATE_PULL_REQUEST_TOOLTIP: + "By clicking this button you will create the pull request to allow others to view your changes and accept them into the repository.", + PULL_REQUEST_SUMMARY_TOOLTIP: + "This shows the amount of commits in the pull request, the amount of files you changed in the pull request, how many comments were on the commits for the pull request and the ammount of people who worked together on this pull request.", + PULL_REQUEST_FILE_COMPARISON_TOOLTIP: + "This shows the changes between the orginal file and your version. Green(+) represents lines added. Red(-) represents removed lines", + PULL_REQUEST_STATUS_TOOLTIP: + "This indicates that the pull request is open meaning someone will get to it soon.", + PULL_REQUEST_MENU_TOOLTIP: + "Feel free to explore this menu, you can discuss with project contributors, see the commits made, check the review status and see the files changed.", + CLOSE_PULL_REQUEST_TOOLTIP: + "This will close the pull request meaning people cannot view this! Do not click close unless the request was solved.", + COMMIT_TITLE_TOOLTIP: + "This is the title of the commit. Give a brief description of the change. Be short and objective.", + COMMIT_FILES_DESCRIPTION_TOOLTIP: + "Add a more detailed description of the commit if needed. Here you can describe the files uploaded.", + HISTORY_LINK_TOOLTIP: + 'Use the "History" link
to view changes to this
file by other contributors.', + PENCIL_ICON_TOOLTIP: "Click the pencil to edit the file and start a pull request", +}; diff --git a/ChromeExtension/content/content.js b/ChromeExtension/content/content.js new file mode 100644 index 0000000..5bc6d2d --- /dev/null +++ b/ChromeExtension/content/content.js @@ -0,0 +1,385 @@ +const plugin = { + currentPageUrl: document.location.pathname, + hasInjectedContent: false, + + checkUrl: () => { + const pathArray = document.location.pathname.split("/"); + const urlArray = [ + { + name: "/edit/", + runFunction: createFileEditorToolTips, + }, + { + name: "/compare/", + runFunction: createConfirmPullRequestToolTips, + }, + { + name: "/pull/", + runFunction: createReviewPullRequestToolTips, + }, + { + name: "/upload/", + runFunction: updateUploadFilesPage, + }, + { + name: "/blob/", + runFunction: updateViewFilePage, + }, + ]; + const foundUrl = urlArray.find((object) => plugin.currentPageUrl.includes(object.name)); + foundUrl?.runFunction() ?? console.log("URL was not found."); + + if (foundUrl === undefined && pathArray.length === 2) { + addCompleteOverviewButton(pathArray[1]); + } + }, +}; + +window.onload = () => { + if (!plugin.hasInjectedContent) { + plugin.hasInjectedContent = true; + plugin.currentPageUrl = document.location.pathname; + plugin.checkUrl(); + } +}; + +/** + * Object for monitoring progress of the pull request process + */ +const pullRequestProcess = { + steps: ["Edit File", "Confirm Pull Request", "Pull Request Opened"], + currentStep: 2, + totalSteps: 3, + + setCurrentStep: (newStep) => { + pullRequestProcess.currentStep = newStep; + }, + + getCurrentStep: () => { + return pullRequestProcess.currentStep; + }, + + createProgressBar: (updatedStep, rootElement) => { + pullRequestProcess.currentStep = updatedStep; + const { totalSteps, steps } = pullRequestProcess; + addProgressBar(updatedStep, totalSteps, rootElement, steps); + }, +}; + +/** + * Adds tooltips when editing files (First step) + */ +function createFileEditorToolTips() { + pullRequestProcess.createProgressBar(1, ".js-blob-form"); + + if (document.getElementsByClassName("flash-messages ")[0] !== null) { + $(".flash-messages").addClass("text-center"); + document.getElementsByClassName("flash")[0].innerText = getString("NOW_EDITING_FILE_MESSAGE"); + } + + const fileNameChangeIconText = getString("FILENAME_TOOLTIP"); + const branchNameLink = ".branch-name:eq(0)"; + createIconAfterElement(fileNameChangeIconText, branchNameLink); + + updatePullRequestTitleInput(); + updatePullRequestDescriptionInput(); + + const createPullRequestIconText = getString("PROPOSE_CHANGES_TOOLTIP"); + const directlyCommitIconText = getString("DIRECTLY_COMMIT_CHANGES_TOOLTIP"); + const submitButtonText = document.getElementsByClassName("btn-primary")[1].innerText; + const submitChangesIconText = + submitButtonText === "Propose changes" ? createPullRequestIconText : directlyCommitIconText; + createIconBeforeElement(submitChangesIconText, "#submit-file"); + + $('input[name="commit-choice"]').on("click", () => { + $(".helpIconText:eq(3)").toggleText(createPullRequestIconText, directlyCommitIconText); + }); +} + +const updatePullRequestTitleInput = () => { + const inputTitleLabel = document.createElement("h3"); + inputTitleLabel.innerHTML = "Insert a title here"; + inputTitleLabel.className = "label-margin-right"; + $(inputTitleLabel).insertBefore("#commit-summary-input"); + + const commitTitleIconText = getString("PULL_REQUEST_TITLE_TOOLTIP"); + createIconAfterElement(commitTitleIconText, "#commit-summary-input"); +}; + +const updatePullRequestDescriptionInput = () => { + const inputDescriptionLabel = document.createElement("h3"); + inputDescriptionLabel.innerHTML = "Insert a
description here"; + inputDescriptionLabel.className = "label-margin-right"; + $(inputDescriptionLabel).insertBefore("#commit-description-textarea"); + + const descriptionIconText = getString("PULL_REQUEST_DESCRIPTION_TOOLTIP"); + createIconAfterElement(descriptionIconText, "#commit-description-textarea"); +}; + +/** + * Creates tooltips when confirming a change to file (Second step) + */ +function createConfirmPullRequestToolTips() { + pullRequestProcess.createProgressBar(2, ".repository-content"); + + const pullRequestDescription = getString("PULL_REQUEST_DETAILED_DESCRIPTION_TOOLTIP"); + $("#pull_request_body").attr("placeholder", pullRequestDescription); + + let isComparingBranch = false; + + if (document.getElementsByClassName("branch-name").length > 0) { + isComparingBranch = true; + } + + if (isComparingBranch) { + $(".Subhead-heading").text("Create Pull Request"); + } + + const pullRequestTitle = document.getElementsByClassName("Subhead-heading")[1]; + pullRequestTitle.innerHTML = "Create pull request"; + + const topRibbon = document.getElementsByClassName("js-range-editor")[0]; + topRibbon.style.width = "93%"; + topRibbon.style.display = "inline-block"; + + const destinationIconText = getString("PULL_REQUEST_ORIGIN_AND_DESTINATION_TOOLTIP"); + createIconAfterElement(destinationIconText, ".js-range-editor:eq(0)"); + + if (!isComparingBranch) { + const buttonRow = document.getElementsByClassName("d-flex flex-justify-end m-2")[0]; + buttonRow.classList.remove("flex-justify-end"); + buttonRow.classList.add("flex-justify-start"); + } + + const createPullRequestButtonIconText = getString("CREATE_PULL_REQUEST_TOOLTIP"); + const submitButtonClass = ".js-pull-request-button"; + + createIconAfterElement(createPullRequestButtonIconText, submitButtonClass); + + const requestSummaryIconText = getString("PULL_REQUEST_SUMMARY_TOOLTIP"); + + const summaryClass = ".overall-summary"; + createIconAfterElement(requestSummaryIconText, summaryClass); + + createPullRequestComparisonIcon(); +} + +const createPullRequestComparisonIcon = () => { + const comparisonIconText = getString("PULL_REQUEST_FILE_COMPARISON_TOOLTIP"); + + const comparisonClass = "#commits_bucket"; + const comparisonIcon = createIconAfterElement(comparisonIconText, comparisonClass); + comparisonIcon.style.float = "right"; + comparisonIcon.style.marginTop = "20px"; + comparisonIcon.style.marginRight = "-10px"; +}; + +/** + * Adds tooltips when reviewing a pull request (Final step) + */ +function createReviewPullRequestToolTips() { + pullRequestProcess.createProgressBar(3, ".gh-header"); + + const pullRequestStatusIconText = getString("PULL_REQUEST_STATUS_TOOLTIP"); + const pullRequestState = $(".State:eq(0)").text().trim(); + + if (pullRequestState !== "Closed") { + const pullRequestStatusIcon = createIconAfterElement(pullRequestStatusIconText, ".State:eq(0)"); + + pullRequestStatusIcon.style.marginLeft = "10px"; + pullRequestStatusIcon.style.marginRight = "10px"; + } + + $(".tabnav-tabs:eq(0)").addClass("overflow-visible"); + $(".tabnav-tabs:eq(0)").removeClass("overflow-auto"); + + const pullRequestNavIconText = getString("PULL_REQUEST_MENU_TOOLTIP"); + + const totalTabs = $(".tabnav-tabs:eq(0) .tabnav-tab").length; + createIconAfterElement(pullRequestNavIconText, `.tabnav-tab:eq(${totalTabs - 1})`); + + $(".helpIconText:eq(1)").width(250); + + $("primer-tooltip[for='md-mention-new_comment_field']").html( + 'Use "@" to mention a project contributor.' + ); + + updatePullRequestButtonRow(); + updateClosePullRequestButton(); + $(document).on("submit", ".js-new-comment-form", () => { + chrome.storage.sync.set({ hasSubmittedMessage: true }); + createMessageSubmittedRibbon(); + }); +} + +const updatePullRequestButtonRow = () => { + $(".d-flex.flex-justify-end").removeClass("flex-justify-end"); +}; + +const updateClosePullRequestButton = () => { + const pullRequestName = document.getElementsByClassName("js-issue-title")[0].innerText; + const closePullRequestButtonClass = 'button[name="comment_and_close"]'; + const closePullRequestButton = $(closePullRequestButtonClass); + const closePullRequestIconText = getString("CLOSE_PULL_REQUEST_TOOLTIP"); + + const closePullRequestIcon = createIconBeforeElement( + closePullRequestIconText, + closePullRequestButtonClass + ); + closePullRequestIcon.style.marginRight = "20px"; + + closePullRequestButton.on("click", (event) => { + if (!confirm(`Are you sure that you want to close the pull request: ${pullRequestName}?`)) { + event.preventDefault(); + } + }); +}; + +/** + * Checks if the user is viewing a file that they do not own + */ +function isEditingForkedFile() { + const pencilIconLabelsList = [ + "Edit the file in your fork of this project", + "Fork this project and edit the file", + ]; + + try { + const pencilIconLabel = document + .getElementsByClassName("tooltipped")[2] + .getAttribute("aria-label"); + // check if there is a pencil icon with this aria label + return pencilIconLabelsList.includes(pencilIconLabel); + } catch (error) { + return false; + } +} + +function isCurrentlyViewingFile() { + return document.location.pathname.includes("blob") && $(".js-file-line-container").length > 0; +} + +/** + * Edits pencil label when viewing a file in a repository that you are not a contributor of + */ +function createForkedFileToolTips() { + $(".tooltipped-nw:nth-child(2)").attr("aria-label", "Edit File"); +} + +const isPullRequestOpen = () => { + const gitHubStateElements = document.getElementsByClassName("State"); + return gitHubStateElements[0]?.getAttribute("title") === "Status: Open" ?? false; +}; + +function createSuccessRibbon() { + if (document.location.pathname.includes("/pull")) { + const successRibbonContainer = document.createElement("div"); + const ribbonMessage = getString("PULL_REQUEST_CREATED_MESSAGE"); + const ribbonTextNode = document.createTextNode(ribbonMessage); + + successRibbonContainer.className = "successRibbon text-center"; + successRibbonContainer.appendChild(ribbonTextNode); + $(successRibbonContainer).insertBefore(".container"); + } +} + +const createMessageSubmittedRibbon = async () => { + const hasSubmittedMessage = await getValueFromStorage("hasSubmittedMessage", false); + if (hasSubmittedMessage && $(".successRibbon").length === 1) { + const ribbonMessage = getString("COMMENT_ADDED_MESSAGE"); + $(".successRibbon").html(ribbonMessage); + } + + if (hasSubmittedMessage && $(".container").length === 1) { + chrome.storage.sync.set({ hasSubmittedMessage: false }); + } +}; + +const updateUploadFilesPage = () => { + const totalForksLabel = "#repo-network-counter"; + + if (cannotForkRepository()) { + $(".blankslate p:first").text( + "In order to upload files, click the fork button on the upper right" + ); + + $(totalForksLabel).parent().addClass("btn-primary"); + } + + const commitIconText = getString("COMMIT_TITLE_TOOLTIP"); + createIconAfterElement(commitIconText, "#commit-summary-input"); + + const commitDescriptionText = getString("COMMIT_FILES_DESCRIPTION_TOOLTIP"); + createIconAfterElement(commitDescriptionText, "#commit-description-textarea"); + + $('button[data-edit-text="Commit changes"]').on("click", () => { + chrome.storage.sync.set({ hasUploadedNewFile: true, activePage: "home" }); + }); +}; + +const cannotForkRepository = () => { + return ( + $(".blankslate p:first").text().trim() === + "File uploads require push access to this repository." + ); +}; + +const updateViewFilePage = () => { + const historyLinkText = getString("HISTORY_LINK_TOOLTIP"); + const fileIconText = getString("PENCIL_ICON_TOOLTIP"); + const fileIconClassname = ".js-update-url-with-hash:eq(1)"; + + if ($(".helpIcon").length === 0) { + createIconAfterElement(historyLinkText, ".ml-3:eq(1)"); + createIconAfterElement(fileIconText, fileIconClassname); + } +}; + +const addCompleteOverviewButton = (username) => { + const overviewButton = document.createElement("span"); + overviewButton.className = "btn btn-primary"; + overviewButton.id = "overview-button"; + overviewButton.innerHTML = "Complete Overview"; + + if ($("#overview-button").length === 0) { + $(overviewButton).insertBefore(".graph-before-activity-overview"); + } + $("#overview-button").on("click", () => { + chrome.storage.sync.set({ username: username }); + + chrome.runtime.sendMessage({ + type: "OPEN_COMPLETE_OVERVIEW", + }); + }); +}; + +chrome.runtime.onMessage.addListener((msg) => { + if (msg.type === "CHECK_URL") { + if (!plugin.hasInjectedContent || $(".helpIcon").length === 0) { + plugin.hasInjectedContent = true; + plugin.currentPageUrl = document.location.pathname; + + plugin.checkUrl(); + } + if (isEditingForkedFile()) { + createForkedFileToolTips(); + } + if (isCurrentlyViewingFile()) { + plugin.currentPageUrl = document.location.pathname; + plugin.checkUrl(); + } + } else if (msg.type === "TOGGLE_EXTENSION") { + toggleExtension(); + } +}); + +function toggleExtension() { + $(".helpIcon").toggleClass("display-none"); + $(".successRibbon").toggleClass("display-none"); + $(".container").toggleClass("display-none"); +} + +// listen globaly for fork button to be clicked +$(".btn-with-count button:eq(0)").on("click", () => { + chrome.storage.sync.set({ hasForked: true }); +}); diff --git a/ChromeExtension/content/overview.html b/ChromeExtension/content/overview.html new file mode 100644 index 0000000..4faeb79 --- /dev/null +++ b/ChromeExtension/content/overview.html @@ -0,0 +1,1404 @@ + + + + + + + + +
+ Skip to content + + + + + +
+

+
+ + + + + + + + + + + + + +
+ + + + + diff --git a/ChromeExtension/content/overview.js b/ChromeExtension/content/overview.js new file mode 100644 index 0000000..b6c44b9 --- /dev/null +++ b/ChromeExtension/content/overview.js @@ -0,0 +1,385 @@ +class Card { + constructor( + repositoryName, + repositoryLink, + commitTotal, + topLanguage, + languageColor, + cardContainer + ) { + this.repositoryName = repositoryName; + this.repositoryLink = repositoryLink; + this.commitTotal = commitTotal; + this.topLanguage = topLanguage; + this.languageColor = languageColor; + this.cardContainer = cardContainer; + } + + createCard() { + const cardContainer = document.createElement("div"); + cardContainer.className = "card"; + + cardContainer.innerHTML = `
+
+ ${this.repositoryName} +
+
+
+
+ + Commits: ${this.commitTotal}
`; + + if (this.topLanguage !== null) { + cardContainer.innerHTML += ` +
+ +
${this.topLanguage}
+
`; + } + + cardContainer.innerHTML += ` +
+
+
+ Commits/Issues Overview +
+
`; + + this.cardContainer = cardContainer; + } +} + +window.onload = async () => { + const gitHubUsername = await retrieveGitHubUsername(); + + document.getElementById( + "username" + ).innerHTML = ` ${gitHubUsername}/Repositories`; + + $("#github-username").html(gitHubUsername); + updateOverviewPageLinks(gitHubUsername); + + const userProfileImage = await retrieveProfileImage(gitHubUsername); + + $("#profile-image").attr("src", userProfileImage); + getRepos(gitHubUsername); +}; + +/** + * Function name: updateOverviewPageLinks + * Updates links to point to current user's GitHub + */ +function updateOverviewPageLinks(gitHubUsername) { + const baseURL = "https://github.com"; + + $(".user-profile-link").prop("href", `${baseURL}/${gitHubUsername}`); + $("#profile-link").prop("href", `${baseURL}/${gitHubUsername}`); + $("#repositories-link").prop("href", `${baseURL}/${gitHubUsername}`); + $("#projects-link").prop("href", `${baseURL}/${gitHubUsername}?tab=projects`); + $("#stars-link").prop("href", `${baseURL}/${gitHubUsername}?tab=stars`); +} + +/** + * Creates cards containing total commits and top langauge + */ +async function createCompleteOverview(userData, username) { + const FIRST_PAGE = 1; + const MAX_CARDS_PER_ROW = 4; + const allRepositories = []; + + let isNewPage = false; + let rowElements = ""; + try { + rowElements = document.getElementsByClassName("row")[0].childElementCount; + } catch (error) { + isNewPage = true; + } + + let newRow = ""; + + if (rowElements === 4 || isNewPage) { + newRow = document.createElement("div"); + newRow.className = "row"; + $(newRow).insertAfter(".row:last"); + } + + for (const repo of userData) { + const totalCommits = await getAllCommits(repo.name, username, FIRST_PAGE); + const langaugeColor = await getLanguageColor(repo.language); + const { name, html_url, language } = repo; + const repositoryCard = new Card(name, html_url, totalCommits, language, langaugeColor); + allRepositories.push(repositoryCard); + } + + sortArrayByTotalCommits(allRepositories); + + allRepositories.forEach((repository) => { + repository.createCard(username); + + const totalRows = document.getElementsByClassName("row").length; + + let lastRowCardCount = 0; + + newRow = document.createElement("div"); + newRow.className = "row"; + + if (totalRows !== 0) { + lastRowCardCount = document.getElementsByClassName("row")[totalRows - 1].childElementCount; + } else if (totalRows === 0) { + $(newRow).appendTo("#content"); + } + + // if the row is full + if (lastRowCardCount === MAX_CARDS_PER_ROW) { + $(newRow).insertAfter(".row:last"); + } + + $(".row:last").append(repository.cardContainer); + }); + + return true; +} + +/** + * Sorts given array in descending order + */ +function sortArrayByTotalCommits(array) { + array.sort((a, b) => { + return b.commitTotal - a.commitTotal; + }); +} + +/** + * Uses GitHub API to view programming languages for user + */ +async function getRepos(username) { + const url = `https://api.github.com/users/${username}/repos`; + + const result = await parseGithubUrl(url); + + const repositoriesCreated = await createCompleteOverview(result, username); + + if (repositoriesCreated) { + document.getElementById("progressBar").style.display = "none"; + } +} + +async function getAllCommits(repositoryName, username, page) { + const MAX_PAGES = 25; + + const commitUrl = `https://api.github.com/repos/${username}/${repositoryName}/commits?page=${page}&per_page=100`; + + const commitResult = await parseGithubUrl(commitUrl); + + let totalCommits = commitResult.length; + + if (totalCommits % 100 === 0 && page < MAX_PAGES) { + totalCommits += await getAllCommits(repositoryName, username, page + 1); + } + + return totalCommits; +} + +async function parseGithubUrl(apiUrl) { + const oAuthToken = "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"; + + const apiHeaders = { + Authorization: `Token ${oAuthToken}`, + }; + + const apiResponse = await fetch(apiUrl, { + method: "GET", + headers: apiHeaders, + }); + + const apiResult = await apiResponse.json(); + + return apiResult; +} + +async function getAllCommitMessages(repository, username, page) { + const MAX_PAGES = 15; + + const commitsUrl = `https://api.github.com/repos/${username}/${repository}/commits?page=${page}&per_page=100`; + const commits = await parseGithubUrl(commitsUrl); + + document.getElementById( + "repo-name" + ).innerHTML = ` + ${repository}`; + + let modalContainerIsEmpty = true; + if (commits.length !== 0) { + commits.forEach((commit) => { + if (commit.author !== null && commit.author.login === username) { + updateRepositoryModal(commit.commit.message, commit.html_url, commit.commit.author.date); + + modalContainerIsEmpty = false; + } + }); + + document.getElementById("modalContainer").style.display = "block"; + if (commits.length % 100 === 0 && page < MAX_PAGES) { + getAllCommitMessages(repository, username, page + 1); + } + + if (modalContainerIsEmpty && page === 1) { + updateRepositoryModal(`There were no commits by ${username} in this repository.`, ""); + } + } +} + +async function updateRepositoryCounters(repository, username, page) { + const totalIssues = await getTotalIssues(repository, username, page); + const issueCounter = document.getElementById("issuesCounter"); + issueCounter.innerHTML = totalIssues; + + const totalCommits = await getTotalCommits(repository, username, page); + const commitCounter = document.getElementById("commitsCounter"); + commitCounter.innerHTML = totalCommits; +} + +async function getTotalIssues(repository, username, page) { + const issuesUrl = `https://api.github.com/repos/${username}/${repository}/issues?page=${page}&per_page=100`; + + const issues = await parseGithubUrl(issuesUrl); + let total = 0; + + issues.forEach((issue) => { + if (issue.user.login !== null && issue.user.login === username) { + total += 1; + } + }); + + return total; +} + +async function getTotalCommits(repository, username, page) { + const commitsUrl = `https://api.github.com/repos/${username}/${repository}/commits?page=${page}&per_page=100`; + + const commits = await parseGithubUrl(commitsUrl); + + const userCommits = commits.filter( + (commit) => commit.author !== null && commit.author.login === username + ); + let totalCommits = userCommits.length; + + const MAX_PAGE = 25; + + if (page < MAX_PAGE && total % 100 === 0) { + totalCommits += await getTotalCommits(repository, username, page + 1); + } + + return totalCommits; +} + +async function updateRepositoryModal(message, commitLink, createdDate) { + const username = await retrieveGitHubUsername(); + + const profileImage = await retrieveProfileImage(username); + + const innerContainer = document.getElementsByClassName("modal-content")[0]; + + const messageContainer = document.createElement("p"); + messageContainer.className = "message-title"; + if (createdDate === undefined) { + messageContainer.innerHTML = `${message}`; + } else { + const localTime = new Date(createdDate).toLocaleDateString(); + messageContainer.innerHTML = `${message}@${username} ${username} Committed at: ${localTime}`; + } + innerContainer.appendChild(messageContainer); +} + +async function getLanguageColor(language) { + if (language === null) { + return "#000"; + } + + const url = chrome.runtime.getURL("data/colors.json"); + + const response = await fetch(url); + const colors = await response.json(); + + return colors[language].color; +} + +async function getAllIssues(repository, username, page) { + const issuesUrl = `https://api.github.com/repos/${username}/${repository}/issues?page=${page}&per_page=100`; + const issues = await parseGithubUrl(issuesUrl); + + issues.forEach((issue) => { + if (issue.user.login !== null && issue.user.login === username) { + updateRepositoryModal(issue.title, issue.created_at, issue.html_url); + } + }); + + if (issues.length % 100 === 0) { + getAllIssues(repository, username, page + 1); + } +} + +async function retrieveProfileImage(username) { + const profileUrl = `https://api.github.com/users/${username}`; + const userProfile = await parseGithubUrl(profileUrl); + return userProfile.avatar_url; +} + +async function retrieveGitHubUsername() { + const localUsername = new Promise((resolve) => { + chrome.storage.sync.get("username", (result) => { + resolve(result.username); + }); + }); + + const username = await localUsername; + + return username; +} + +$("#repo-issues-link").click(async () => { + if ($("#commit-messages-link").attr("aria-current")) { + $("#commit-messages-link").removeAttr("aria-current"); + $("#repo-issues-link").attr("aria-current", "page"); + + const currentRepository = document.getElementById("repo-name").innerText.trim(); + const username = await retrieveGitHubUsername(); + + document.querySelectorAll(".message-title").forEach((element) => element.remove()); + + getAllIssues(currentRepository, username, 1); + } +}); + +$("#commit-messages-link").click(async () => { + if ($("#repo-issues-link").attr("aria-current")) { + $("#repo-issues-link").removeAttr("aria-current"); + $("#commit-messages-link").attr("aria-current", "page"); + + const currentRepository = document.getElementById("repo-name").innerText.trim(); + const username = await retrieveGitHubUsername(); + + document.querySelectorAll(".message-title").forEach((element) => element.remove()); + + getAllCommitMessages(currentRepository, username, 1); + } +}); + +document.body.onclick = async (event) => { + const gitHubUser = await retrieveGitHubUsername(); + + if (event.target.getAttribute("class") === "label") { + const repositoryName = event.srcElement.id; + getAllCommitMessages(repositoryName, gitHubUser, 1); + updateRepositoryCounters(repositoryName, gitHubUser, 1); + } +}; + +document.getElementsByClassName("close")[0].onclick = () => { + document.getElementById("modalContainer").style.display = "none"; + document.querySelectorAll(".message-title").forEach((element) => element.remove()); + document.getElementById("repo-name").innerHTML = ""; + + $("#repo-issues-link").removeAttr("aria-current"); + $("#commit-messages-link").attr("aria-current", "page"); +}; diff --git a/ChromeExtension/content/repositoryLayout.js b/ChromeExtension/content/repositoryLayout.js new file mode 100644 index 0000000..e31d6d2 --- /dev/null +++ b/ChromeExtension/content/repositoryLayout.js @@ -0,0 +1,135 @@ +function updateCodeTabId() { + const codeNavLinkText = $(".UnderlineNav-body:eq(0) a:eq(0)").text().trim(); + + if (codeNavLinkText === "Code") { + $(".js-repo-nav a:eq(0)").prop("id", "codeLink"); + } + + createNavLinkClickListener("#codeLink", "code"); +} + +/** + * Updates the main page of a repository to only dispay readme file + */ +async function createHomePage() { + const currentPage = await getCurrentRepositoryPage(); + const canUpdateHomePage = isOnHomeOrCodePage(); + const hasForked = await getValueFromStorage("hasForked", false); + const hasUploadedFile = await getValueFromStorage("hasUploadedNewFile", false); + createHomePageLink(); + + const filesContainer = $(".file-navigation"); + const totalIcons = $(".helpIcon").length; + + if (hasForked && !document.location.pathname.includes("upload") && filesContainer.length === 1) { + createNewMessage("The repository was successfully forked"); + } + if (hasUploadedFile && !document.location.pathname.includes("upload")) { + createNewMessage("The files were successfully added"); + } + + if (currentPage === "home" && canUpdateHomePage) { + hideFilesInRepository(); + + $(".selected:eq(0)").removeClass("selected"); + $("#homePage").addClass("selected"); + + if ($("#codeLink").attr("aria-current") === "page") { + $("#codeLink").addClass("repoNavButton"); + $("#codeLink").attr("aria-current", "false"); + } + + $("#readme").removeClass("display-none"); + + if (totalIcons < 1) { + const readmeIconText = + "To edit this file, go to the 'code' tab above, and select the file you want to edit."; + createIconAfterElement(readmeIconText, ".Box-title"); + } + } else if (currentPage === "code" && canUpdateHomePage) { + $(".Box-header:eq(0)").removeClass("display-none"); + $(".selected:eq(0)").removeClass("selected"); + $("#codeLink").addClass("selected"); + $("#codeLink").attr("aria-current", "page"); + + if (!document.location.pathname.includes("blob")) { + $("#readme").addClass("display-none"); + } + } + + if (!canUpdateHomePage && $(".selected:eq(0)").text().trim() === "Home") { + $(".selected:eq(0)").removeClass("selected"); + } +} + +const hideFilesInRepository = () => { + $(".file-navigation").addClass("display-none"); + $(".Box-header:eq(0)").addClass("display-none"); + $(".Details-content--hidden-not-important:eq(1)").removeClass("d-md-block"); + $(".js-details-container:eq(1)").addClass("d-none"); +}; + +/** + * Creates green ribbon above files in repository after the repo has been forked + */ +function createNewMessage(newMessageContent) { + const ribbonMessage = document.createTextNode(newMessageContent); + const successRibbonContainer = document.createElement("div"); + + successRibbonContainer.className = "successRibbon text-center"; + successRibbonContainer.appendChild(ribbonMessage); + $(successRibbonContainer).insertBefore(".repository-content"); + + if (newMessageContent.includes("file")) { + chrome.storage.sync.set({ hasUploadedNewFile: false }); + } else { + chrome.storage.sync.set({ hasForked: false }); + } +} + +const createHomePageLink = () => { + if ( + document.getElementById("homePage") === null && + document.getElementsByClassName("h-card").length === 0 + ) { + const imageSource = chrome.runtime.getURL("images/house.png"); + const repoLink = $(".js-repo-nav a:eq(0)").attr("href"); + const newNavLink = document.createElement("li"); + const newNavLinkClass = + "js-navigation-item UnderlineNav-item hx_underlinenav-item no-wrap js-responsive-underlinenav-item"; + + newNavLink.className = "d-flex"; + newNavLink.innerHTML = ` + + Home + `; + + $(".UnderlineNav-body").prepend(newNavLink); + } + + createNavLinkClickListener("#homePage", "home"); +}; + +async function getCurrentRepositoryPage() { + const currentPage = await getValueFromStorage("activePage", "home"); + + return currentPage; +} + +const isOnHomeOrCodePage = () => { + const currentUrl = document.location.pathname; + return currentUrl.split("/").length === 3; +}; + +const createNavLinkClickListener = (targetElement, targetPage) => { + $(targetElement).on("click", (event) => { + chrome.storage.sync.set({ activePage: targetPage }); + }); +}; + +chrome.runtime.onMessage.addListener((msg) => { + if (msg.type === "UPDATE_REPO_LAYOUT") { + updateCodeTabId(); + createHomePage(); + } +}); diff --git a/ChromeExtension/content/util.js b/ChromeExtension/content/util.js new file mode 100644 index 0000000..215dbf3 --- /dev/null +++ b/ChromeExtension/content/util.js @@ -0,0 +1,96 @@ +const isDarkMode = () => { + return $("html").attr("data-color-mode") === "dark"; +}; + +const addProgressBar = (currentStep, totalSteps, rootElement, stepsList) => { + const progressBarContainer = document.createElement("div"); + progressBarContainer.className = "container"; + + const progressBar = document.createElement("div"); + progressBar.className = "progressbar"; + + const progressBarSteps = document.createElement("ul"); + + let index; + + for (index = 1; index <= stepsList.length; index += 1) { + const progressBarStep = document.createElement("li"); + progressBarStep.innerHTML = stepsList[index - 1]; + + if (currentStep === totalSteps) { + progressBarStep.className = "completed"; + } else if (currentStep === index) { + progressBarStep.className = "partial"; + } else if (index < currentStep) { + progressBarStep.className = "partial completed"; + } + + if (isDarkMode()) { + progressBarStep.className += " dark-mode-step"; + } + + progressBarSteps.appendChild(progressBarStep); + } + + progressBar.appendChild(progressBarSteps); + + progressBarContainer.appendChild(progressBar); + $(progressBarContainer).insertBefore(rootElement); + + if (isPullRequestOpen()) { + createSuccessRibbon(); + } +}; + +const createIcon = (text) => { + const toolTipContainer = document.createElement("div"); + toolTipContainer.className = `helpIcon ${isDarkMode() ? "darkmode-icon" : ""}`; + + toolTipContainer.innerHTML = `? + ${text}`; + + return toolTipContainer; +}; + +const createIconAfterElement = (text, gitHubElement) => { + const toolTip = createIcon(text); + $(toolTip).insertAfter(gitHubElement); + return toolTip; +}; + +const createIconBeforeElement = (text, gitHubElement) => { + const toolTip = createIcon(text); + $(toolTip).insertBefore(gitHubElement); + return toolTip; +}; + +const createIconAfterLastElement = (text, gitHubElement) => { + const toolTip = createIcon(text); + $(toolTip).insertAfter(gitHubElement).last(); + return toolTip; +}; + +const getValueFromStorage = async (key, defaultValue) => { + const result = new Promise((resolve) => { + chrome.storage.sync.get(key, (result) => { + resolve(result[key]); + }); + }); + + const value = await result; + + return value ?? defaultValue; +}; + +const getString = (name) => { + return constantStrings[name] ?? ""; +}; + +/** + * Custom jQuery function to toggle text + */ +$.fn.extend({ + toggleText(firstElement, secondElement) { + return this.text(this.text() === secondElement ? firstElement : secondElement); + }, +}); diff --git a/ChromeExtension/data/colors.json b/ChromeExtension/data/colors.json new file mode 100644 index 0000000..4b051bd --- /dev/null +++ b/ChromeExtension/data/colors.json @@ -0,0 +1,1622 @@ +{ + "1C Enterprise": { + "color": "#814CCC", + "url": "https://github.com/trending?l=1C-Enterprise" + }, + "4D": { + "color": null, + "url": "https://github.com/trending?l=4D" + }, + "ABAP": { + "color": "#E8274B", + "url": "https://github.com/trending?l=ABAP" + }, + "ActionScript": { + "color": "#882B0F", + "url": "https://github.com/trending?l=ActionScript" + }, + "Ada": { + "color": "#02f88c", + "url": "https://github.com/trending?l=Ada" + }, + "Agda": { + "color": "#315665", + "url": "https://github.com/trending?l=Agda" + }, + "AGS Script": { + "color": "#B9D9FF", + "url": "https://github.com/trending?l=AGS-Script" + }, + "Alloy": { + "color": "#64C800", + "url": "https://github.com/trending?l=Alloy" + }, + "Alpine Abuild": { + "color": null, + "url": "https://github.com/trending?l=Alpine-Abuild" + }, + "AMPL": { + "color": "#E6EFBB", + "url": "https://github.com/trending?l=AMPL" + }, + "AngelScript": { + "color": "#C7D7DC", + "url": "https://github.com/trending?l=AngelScript" + }, + "ANTLR": { + "color": "#9DC3FF", + "url": "https://github.com/trending?l=ANTLR" + }, + "Apex": { + "color": null, + "url": "https://github.com/trending?l=Apex" + }, + "API Blueprint": { + "color": "#2ACCA8", + "url": "https://github.com/trending?l=API-Blueprint" + }, + "APL": { + "color": "#5A8164", + "url": "https://github.com/trending?l=APL" + }, + "Apollo Guidance Computer": { + "color": null, + "url": "https://github.com/trending?l=Apollo-Guidance-Computer" + }, + "AppleScript": { + "color": "#101F1F", + "url": "https://github.com/trending?l=AppleScript" + }, + "Arc": { + "color": "#aa2afe", + "url": "https://github.com/trending?l=Arc" + }, + "ASP": { + "color": "#6a40fd", + "url": "https://github.com/trending?l=ASP" + }, + "AspectJ": { + "color": "#a957b0", + "url": "https://github.com/trending?l=AspectJ" + }, + "Assembly": { + "color": "#6E4C13", + "url": "https://github.com/trending?l=Assembly" + }, + "Asymptote": { + "color": "#4a0c0c", + "url": "https://github.com/trending?l=Asymptote" + }, + "ATS": { + "color": "#1ac620", + "url": "https://github.com/trending?l=ATS" + }, + "Augeas": { + "color": null, + "url": "https://github.com/trending?l=Augeas" + }, + "AutoHotkey": { + "color": "#6594b9", + "url": "https://github.com/trending?l=AutoHotkey" + }, + "AutoIt": { + "color": "#1C3552", + "url": "https://github.com/trending?l=AutoIt" + }, + "Awk": { + "color": null, + "url": "https://github.com/trending?l=Awk" + }, + "Ballerina": { + "color": "#FF5000", + "url": "https://github.com/trending?l=Ballerina" + }, + "Batchfile": { + "color": "#C1F12E", + "url": "https://github.com/trending?l=Batchfile" + }, + "Befunge": { + "color": null, + "url": "https://github.com/trending?l=Befunge" + }, + "Bison": { + "color": null, + "url": "https://github.com/trending?l=Bison" + }, + "BitBake": { + "color": null, + "url": "https://github.com/trending?l=BitBake" + }, + "BlitzBasic": { + "color": null, + "url": "https://github.com/trending?l=BlitzBasic" + }, + "BlitzMax": { + "color": "#cd6400", + "url": "https://github.com/trending?l=BlitzMax" + }, + "Bluespec": { + "color": null, + "url": "https://github.com/trending?l=Bluespec" + }, + "Boo": { + "color": "#d4bec1", + "url": "https://github.com/trending?l=Boo" + }, + "Brainfuck": { + "color": "#2F2530", + "url": "https://github.com/trending?l=Brainfuck" + }, + "Brightscript": { + "color": null, + "url": "https://github.com/trending?l=Brightscript" + }, + "C": { + "color": "#555555", + "url": "https://github.com/trending?l=C" + }, + "C#": { + "color": "#178600", + "url": "https://github.com/trending?l=Csharp" + }, + "C++": { + "color": "#f34b7d", + "url": "https://github.com/trending?l=C++" + }, + "C2hs Haskell": { + "color": null, + "url": "https://github.com/trending?l=C2hs-Haskell" + }, + "Cap'n Proto": { + "color": null, + "url": "https://github.com/trending?l=Cap'n-Proto" + }, + "CartoCSS": { + "color": null, + "url": "https://github.com/trending?l=CartoCSS" + }, + "Ceylon": { + "color": "#dfa535", + "url": "https://github.com/trending?l=Ceylon" + }, + "Chapel": { + "color": "#8dc63f", + "url": "https://github.com/trending?l=Chapel" + }, + "Charity": { + "color": null, + "url": "https://github.com/trending?l=Charity" + }, + "ChucK": { + "color": null, + "url": "https://github.com/trending?l=ChucK" + }, + "Cirru": { + "color": "#ccccff", + "url": "https://github.com/trending?l=Cirru" + }, + "Clarion": { + "color": "#db901e", + "url": "https://github.com/trending?l=Clarion" + }, + "Clean": { + "color": "#3F85AF", + "url": "https://github.com/trending?l=Clean" + }, + "Click": { + "color": "#E4E6F3", + "url": "https://github.com/trending?l=Click" + }, + "CLIPS": { + "color": null, + "url": "https://github.com/trending?l=CLIPS" + }, + "Clojure": { + "color": "#db5855", + "url": "https://github.com/trending?l=Clojure" + }, + "CMake": { + "color": null, + "url": "https://github.com/trending?l=CMake" + }, + "COBOL": { + "color": null, + "url": "https://github.com/trending?l=COBOL" + }, + "CodeQL": { + "color": null, + "url": "https://github.com/trending?l=CodeQL" + }, + "CoffeeScript": { + "color": "#244776", + "url": "https://github.com/trending?l=CoffeeScript" + }, + "ColdFusion": { + "color": "#ed2cd6", + "url": "https://github.com/trending?l=ColdFusion" + }, + "ColdFusion CFC": { + "color": null, + "url": "https://github.com/trending?l=ColdFusion-CFC" + }, + "Common Lisp": { + "color": "#3fb68b", + "url": "https://github.com/trending?l=Common-Lisp" + }, + "Common Workflow Language": { + "color": "#B5314C", + "url": "https://github.com/trending?l=Common-Workflow-Language" + }, + "Component Pascal": { + "color": "#B0CE4E", + "url": "https://github.com/trending?l=Component-Pascal" + }, + "Cool": { + "color": null, + "url": "https://github.com/trending?l=Cool" + }, + "Coq": { + "color": null, + "url": "https://github.com/trending?l=Coq" + }, + "Crystal": { + "color": "#000100", + "url": "https://github.com/trending?l=Crystal" + }, + "Csound": { + "color": null, + "url": "https://github.com/trending?l=Csound" + }, + "Csound Document": { + "color": null, + "url": "https://github.com/trending?l=Csound-Document" + }, + "Csound Score": { + "color": null, + "url": "https://github.com/trending?l=Csound-Score" + }, + "CSS": { + "color": "#563d7c", + "url": "https://github.com/trending?l=CSS" + }, + "Cuda": { + "color": "#3A4E3A", + "url": "https://github.com/trending?l=Cuda" + }, + "CWeb": { + "color": null, + "url": "https://github.com/trending?l=CWeb" + }, + "Cycript": { + "color": null, + "url": "https://github.com/trending?l=Cycript" + }, + "Cython": { + "color": null, + "url": "https://github.com/trending?l=Cython" + }, + "D": { + "color": "#ba595e", + "url": "https://github.com/trending?l=D" + }, + "Dafny": { + "color": "#FFEC25", + "url": "https://github.com/trending?l=Dafny" + }, + "Dart": { + "color": "#00B4AB", + "url": "https://github.com/trending?l=Dart" + }, + "DataWeave": { + "color": "#003a52", + "url": "https://github.com/trending?l=DataWeave" + }, + "Dhall": { + "color": "#dfafff", + "url": "https://github.com/trending?l=Dhall" + }, + "DIGITAL Command Language": { + "color": null, + "url": "https://github.com/trending?l=DIGITAL-Command-Language" + }, + "DM": { + "color": "#447265", + "url": "https://github.com/trending?l=DM" + }, + "Dockerfile": { + "color": "#384d54", + "url": "https://github.com/trending?l=Dockerfile" + }, + "Dogescript": { + "color": "#cca760", + "url": "https://github.com/trending?l=Dogescript" + }, + "DTrace": { + "color": null, + "url": "https://github.com/trending?l=DTrace" + }, + "Dylan": { + "color": "#6c616e", + "url": "https://github.com/trending?l=Dylan" + }, + "E": { + "color": "#ccce35", + "url": "https://github.com/trending?l=E" + }, + "eC": { + "color": "#913960", + "url": "https://github.com/trending?l=eC" + }, + "ECL": { + "color": "#8a1267", + "url": "https://github.com/trending?l=ECL" + }, + "ECLiPSe": { + "color": null, + "url": "https://github.com/trending?l=ECLiPSe" + }, + "Eiffel": { + "color": "#946d57", + "url": "https://github.com/trending?l=Eiffel" + }, + "Elixir": { + "color": "#6e4a7e", + "url": "https://github.com/trending?l=Elixir" + }, + "Elm": { + "color": "#60B5CC", + "url": "https://github.com/trending?l=Elm" + }, + "Emacs Lisp": { + "color": "#c065db", + "url": "https://github.com/trending?l=Emacs-Lisp" + }, + "EmberScript": { + "color": "#FFF4F3", + "url": "https://github.com/trending?l=EmberScript" + }, + "EQ": { + "color": "#a78649", + "url": "https://github.com/trending?l=EQ" + }, + "Erlang": { + "color": "#B83998", + "url": "https://github.com/trending?l=Erlang" + }, + "F#": { + "color": "#b845fc", + "url": "https://github.com/trending?l=Fsharp" + }, + "F*": { + "color": "#572e30", + "url": "https://github.com/trending?l=F*" + }, + "Factor": { + "color": "#636746", + "url": "https://github.com/trending?l=Factor" + }, + "Fancy": { + "color": "#7b9db4", + "url": "https://github.com/trending?l=Fancy" + }, + "Fantom": { + "color": "#14253c", + "url": "https://github.com/trending?l=Fantom" + }, + "Faust": { + "color": "#c37240", + "url": "https://github.com/trending?l=Faust" + }, + "Filebench WML": { + "color": null, + "url": "https://github.com/trending?l=Filebench-WML" + }, + "Filterscript": { + "color": null, + "url": "https://github.com/trending?l=Filterscript" + }, + "fish": { + "color": null, + "url": "https://github.com/trending?l=fish" + }, + "FLUX": { + "color": "#88ccff", + "url": "https://github.com/trending?l=FLUX" + }, + "Forth": { + "color": "#341708", + "url": "https://github.com/trending?l=Forth" + }, + "Fortran": { + "color": "#4d41b1", + "url": "https://github.com/trending?l=Fortran" + }, + "Fortran Free Form": { + "color": null, + "url": "https://github.com/trending?l=Fortran-Free-Form" + }, + "FreeMarker": { + "color": "#0050b2", + "url": "https://github.com/trending?l=FreeMarker" + }, + "Frege": { + "color": "#00cafe", + "url": "https://github.com/trending?l=Frege" + }, + "Futhark": { + "color": "#5f021f", + "url": "https://github.com/trending?l=Futhark" + }, + "G-code": { + "color": "#D08CF2", + "url": "https://github.com/trending?l=G-code" + }, + "Game Maker Language": { + "color": "#71b417", + "url": "https://github.com/trending?l=Game-Maker-Language" + }, + "GAML": { + "color": "#FFC766", + "url": "https://github.com/trending?l=GAML" + }, + "GAMS": { + "color": null, + "url": "https://github.com/trending?l=GAMS" + }, + "GAP": { + "color": null, + "url": "https://github.com/trending?l=GAP" + }, + "GCC Machine Description": { + "color": null, + "url": "https://github.com/trending?l=GCC-Machine-Description" + }, + "GDB": { + "color": null, + "url": "https://github.com/trending?l=GDB" + }, + "GDScript": { + "color": "#355570", + "url": "https://github.com/trending?l=GDScript" + }, + "Genie": { + "color": "#fb855d", + "url": "https://github.com/trending?l=Genie" + }, + "Genshi": { + "color": null, + "url": "https://github.com/trending?l=Genshi" + }, + "Gentoo Ebuild": { + "color": null, + "url": "https://github.com/trending?l=Gentoo-Ebuild" + }, + "Gentoo Eclass": { + "color": null, + "url": "https://github.com/trending?l=Gentoo-Eclass" + }, + "Gherkin": { + "color": "#5B2063", + "url": "https://github.com/trending?l=Gherkin" + }, + "GLSL": { + "color": null, + "url": "https://github.com/trending?l=GLSL" + }, + "Glyph": { + "color": "#c1ac7f", + "url": "https://github.com/trending?l=Glyph" + }, + "Gnuplot": { + "color": "#f0a9f0", + "url": "https://github.com/trending?l=Gnuplot" + }, + "Go": { + "color": "#00ADD8", + "url": "https://github.com/trending?l=Go" + }, + "Golo": { + "color": "#88562A", + "url": "https://github.com/trending?l=Golo" + }, + "Gosu": { + "color": "#82937f", + "url": "https://github.com/trending?l=Gosu" + }, + "Grace": { + "color": null, + "url": "https://github.com/trending?l=Grace" + }, + "Grammatical Framework": { + "color": "#79aa7a", + "url": "https://github.com/trending?l=Grammatical-Framework" + }, + "Groovy": { + "color": "#e69f56", + "url": "https://github.com/trending?l=Groovy" + }, + "Groovy Server Pages": { + "color": null, + "url": "https://github.com/trending?l=Groovy-Server-Pages" + }, + "Hack": { + "color": "#878787", + "url": "https://github.com/trending?l=Hack" + }, + "Harbour": { + "color": "#0e60e3", + "url": "https://github.com/trending?l=Harbour" + }, + "Haskell": { + "color": "#5e5086", + "url": "https://github.com/trending?l=Haskell" + }, + "Haxe": { + "color": "#df7900", + "url": "https://github.com/trending?l=Haxe" + }, + "HCL": { + "color": null, + "url": "https://github.com/trending?l=HCL" + }, + "HiveQL": { + "color": "#dce200", + "url": "https://github.com/trending?l=HiveQL" + }, + "HLSL": { + "color": null, + "url": "https://github.com/trending?l=HLSL" + }, + "HolyC": { + "color": "#ffefaf", + "url": "https://github.com/trending?l=HolyC" + }, + "HTML": { + "color": "#e34c26", + "url": "https://github.com/trending?l=HTML" + }, + "Hy": { + "color": "#7790B2", + "url": "https://github.com/trending?l=Hy" + }, + "HyPhy": { + "color": null, + "url": "https://github.com/trending?l=HyPhy" + }, + "IDL": { + "color": "#a3522f", + "url": "https://github.com/trending?l=IDL" + }, + "Idris": { + "color": "#b30000", + "url": "https://github.com/trending?l=Idris" + }, + "IGOR Pro": { + "color": "#0000cc", + "url": "https://github.com/trending?l=IGOR-Pro" + }, + "Inform 7": { + "color": null, + "url": "https://github.com/trending?l=Inform-7" + }, + "Inno Setup": { + "color": null, + "url": "https://github.com/trending?l=Inno-Setup" + }, + "Io": { + "color": "#a9188d", + "url": "https://github.com/trending?l=Io" + }, + "Ioke": { + "color": "#078193", + "url": "https://github.com/trending?l=Ioke" + }, + "Isabelle": { + "color": "#FEFE00", + "url": "https://github.com/trending?l=Isabelle" + }, + "Isabelle ROOT": { + "color": null, + "url": "https://github.com/trending?l=Isabelle-ROOT" + }, + "J": { + "color": "#9EEDFF", + "url": "https://github.com/trending?l=J" + }, + "Jasmin": { + "color": null, + "url": "https://github.com/trending?l=Jasmin" + }, + "Java": { + "color": "#b07219", + "url": "https://github.com/trending?l=Java" + }, + "Java Server Pages": { + "color": null, + "url": "https://github.com/trending?l=Java-Server-Pages" + }, + "JavaScript": { + "color": "#f1e05a", + "url": "https://github.com/trending?l=JavaScript" + }, + "JavaScript+ERB": { + "color": null, + "url": "https://github.com/trending?l=JavaScript+ERB" + }, + "JFlex": { + "color": null, + "url": "https://github.com/trending?l=JFlex" + }, + "Jison": { + "color": null, + "url": "https://github.com/trending?l=Jison" + }, + "Jison Lex": { + "color": null, + "url": "https://github.com/trending?l=Jison-Lex" + }, + "Jolie": { + "color": "#843179", + "url": "https://github.com/trending?l=Jolie" + }, + "JSONiq": { + "color": "#40d47e", + "url": "https://github.com/trending?l=JSONiq" + }, + "Jsonnet": { + "color": "#0064bd", + "url": "https://github.com/trending?l=Jsonnet" + }, + "JSX": { + "color": null, + "url": "https://github.com/trending?l=JSX" + }, + "Julia": { + "color": "#a270ba", + "url": "https://github.com/trending?l=Julia" + }, + "Jupyter Notebook": { + "color": "#DA5B0B", + "url": "https://github.com/trending?l=Jupyter-Notebook" + }, + "Kaitai Struct": { + "color": "#773b37", + "url": "https://github.com/trending?l=Kaitai-Struct" + }, + "Kotlin": { + "color": "#F18E33", + "url": "https://github.com/trending?l=Kotlin" + }, + "KRL": { + "color": "#28430A", + "url": "https://github.com/trending?l=KRL" + }, + "LabVIEW": { + "color": null, + "url": "https://github.com/trending?l=LabVIEW" + }, + "Lasso": { + "color": "#999999", + "url": "https://github.com/trending?l=Lasso" + }, + "Lean": { + "color": null, + "url": "https://github.com/trending?l=Lean" + }, + "Lex": { + "color": "#DBCA00", + "url": "https://github.com/trending?l=Lex" + }, + "LFE": { + "color": "#4C3023", + "url": "https://github.com/trending?l=LFE" + }, + "LilyPond": { + "color": null, + "url": "https://github.com/trending?l=LilyPond" + }, + "Limbo": { + "color": null, + "url": "https://github.com/trending?l=Limbo" + }, + "Literate Agda": { + "color": null, + "url": "https://github.com/trending?l=Literate-Agda" + }, + "Literate CoffeeScript": { + "color": null, + "url": "https://github.com/trending?l=Literate-CoffeeScript" + }, + "Literate Haskell": { + "color": null, + "url": "https://github.com/trending?l=Literate-Haskell" + }, + "LiveScript": { + "color": "#499886", + "url": "https://github.com/trending?l=LiveScript" + }, + "LLVM": { + "color": "#185619", + "url": "https://github.com/trending?l=LLVM" + }, + "Logos": { + "color": null, + "url": "https://github.com/trending?l=Logos" + }, + "Logtalk": { + "color": null, + "url": "https://github.com/trending?l=Logtalk" + }, + "LOLCODE": { + "color": "#cc9900", + "url": "https://github.com/trending?l=LOLCODE" + }, + "LookML": { + "color": "#652B81", + "url": "https://github.com/trending?l=LookML" + }, + "LoomScript": { + "color": null, + "url": "https://github.com/trending?l=LoomScript" + }, + "LSL": { + "color": "#3d9970", + "url": "https://github.com/trending?l=LSL" + }, + "Lua": { + "color": "#000080", + "url": "https://github.com/trending?l=Lua" + }, + "M": { + "color": null, + "url": "https://github.com/trending?l=M" + }, + "M4": { + "color": null, + "url": "https://github.com/trending?l=M4" + }, + "M4Sugar": { + "color": null, + "url": "https://github.com/trending?l=M4Sugar" + }, + "Macaulay2": { + "color": "#d8ffff", + "url": "https://github.com/trending?l=Macaulay2" + }, + "Makefile": { + "color": "#427819", + "url": "https://github.com/trending?l=Makefile" + }, + "Mako": { + "color": null, + "url": "https://github.com/trending?l=Mako" + }, + "Mask": { + "color": "#f97732", + "url": "https://github.com/trending?l=Mask" + }, + "Mathematica": { + "color": null, + "url": "https://github.com/trending?l=Mathematica" + }, + "MATLAB": { + "color": "#e16737", + "url": "https://github.com/trending?l=MATLAB" + }, + "Max": { + "color": "#c4a79c", + "url": "https://github.com/trending?l=Max" + }, + "MAXScript": { + "color": "#00a6a6", + "url": "https://github.com/trending?l=MAXScript" + }, + "mcfunction": { + "color": "#E22837", + "url": "https://github.com/trending?l=mcfunction" + }, + "Mercury": { + "color": "#ff2b2b", + "url": "https://github.com/trending?l=Mercury" + }, + "Meson": { + "color": "#007800", + "url": "https://github.com/trending?l=Meson" + }, + "Metal": { + "color": "#8f14e9", + "url": "https://github.com/trending?l=Metal" + }, + "MiniD": { + "color": null, + "url": "https://github.com/trending?l=MiniD" + }, + "Mirah": { + "color": "#c7a938", + "url": "https://github.com/trending?l=Mirah" + }, + "mIRC Script": { + "color": "#926059", + "url": "https://github.com/trending?l=mIRC-Script" + }, + "MLIR": { + "color": "#5EC8DB", + "url": "https://github.com/trending?l=MLIR" + }, + "Modelica": { + "color": null, + "url": "https://github.com/trending?l=Modelica" + }, + "Modula-2": { + "color": null, + "url": "https://github.com/trending?l=Modula-2" + }, + "Modula-3": { + "color": "#223388", + "url": "https://github.com/trending?l=Modula-3" + }, + "Module Management System": { + "color": null, + "url": "https://github.com/trending?l=Module-Management-System" + }, + "Monkey": { + "color": null, + "url": "https://github.com/trending?l=Monkey" + }, + "Moocode": { + "color": null, + "url": "https://github.com/trending?l=Moocode" + }, + "MoonScript": { + "color": null, + "url": "https://github.com/trending?l=MoonScript" + }, + "Motorola 68K Assembly": { + "color": null, + "url": "https://github.com/trending?l=Motorola-68K-Assembly" + }, + "MQL4": { + "color": "#62A8D6", + "url": "https://github.com/trending?l=MQL4" + }, + "MQL5": { + "color": "#4A76B8", + "url": "https://github.com/trending?l=MQL5" + }, + "MTML": { + "color": "#b7e1f4", + "url": "https://github.com/trending?l=MTML" + }, + "MUF": { + "color": null, + "url": "https://github.com/trending?l=MUF" + }, + "mupad": { + "color": null, + "url": "https://github.com/trending?l=mupad" + }, + "Myghty": { + "color": null, + "url": "https://github.com/trending?l=Myghty" + }, + "NASL": { + "color": null, + "url": "https://github.com/trending?l=NASL" + }, + "NCL": { + "color": "#28431f", + "url": "https://github.com/trending?l=NCL" + }, + "Nearley": { + "color": "#990000", + "url": "https://github.com/trending?l=Nearley" + }, + "Nemerle": { + "color": "#3d3c6e", + "url": "https://github.com/trending?l=Nemerle" + }, + "nesC": { + "color": "#94B0C7", + "url": "https://github.com/trending?l=nesC" + }, + "NetLinx": { + "color": "#0aa0ff", + "url": "https://github.com/trending?l=NetLinx" + }, + "NetLinx+ERB": { + "color": "#747faa", + "url": "https://github.com/trending?l=NetLinx+ERB" + }, + "NetLogo": { + "color": "#ff6375", + "url": "https://github.com/trending?l=NetLogo" + }, + "NewLisp": { + "color": "#87AED7", + "url": "https://github.com/trending?l=NewLisp" + }, + "Nextflow": { + "color": "#3ac486", + "url": "https://github.com/trending?l=Nextflow" + }, + "Nim": { + "color": "#ffc200", + "url": "https://github.com/trending?l=Nim" + }, + "Nit": { + "color": "#009917", + "url": "https://github.com/trending?l=Nit" + }, + "Nix": { + "color": "#7e7eff", + "url": "https://github.com/trending?l=Nix" + }, + "NSIS": { + "color": null, + "url": "https://github.com/trending?l=NSIS" + }, + "Nu": { + "color": "#c9df40", + "url": "https://github.com/trending?l=Nu" + }, + "NumPy": { + "color": null, + "url": "https://github.com/trending?l=NumPy" + }, + "Objective-C": { + "color": "#438eff", + "url": "https://github.com/trending?l=Objective-C" + }, + "Objective-C++": { + "color": "#6866fb", + "url": "https://github.com/trending?l=Objective-C++" + }, + "Objective-J": { + "color": "#ff0c5a", + "url": "https://github.com/trending?l=Objective-J" + }, + "ObjectScript": { + "color": "#424893", + "url": "https://github.com/trending?l=ObjectScript" + }, + "OCaml": { + "color": "#3be133", + "url": "https://github.com/trending?l=OCaml" + }, + "Odin": { + "color": "#60AFFE", + "url": "https://github.com/trending?l=Odin" + }, + "Omgrofl": { + "color": "#cabbff", + "url": "https://github.com/trending?l=Omgrofl" + }, + "ooc": { + "color": "#b0b77e", + "url": "https://github.com/trending?l=ooc" + }, + "Opa": { + "color": null, + "url": "https://github.com/trending?l=Opa" + }, + "Opal": { + "color": "#f7ede0", + "url": "https://github.com/trending?l=Opal" + }, + "Open Policy Agent": { + "color": null, + "url": "https://github.com/trending?l=Open-Policy-Agent" + }, + "OpenCL": { + "color": null, + "url": "https://github.com/trending?l=OpenCL" + }, + "OpenEdge ABL": { + "color": null, + "url": "https://github.com/trending?l=OpenEdge-ABL" + }, + "OpenQASM": { + "color": "#AA70FF", + "url": "https://github.com/trending?l=OpenQASM" + }, + "OpenRC runscript": { + "color": null, + "url": "https://github.com/trending?l=OpenRC-runscript" + }, + "OpenSCAD": { + "color": null, + "url": "https://github.com/trending?l=OpenSCAD" + }, + "Ox": { + "color": null, + "url": "https://github.com/trending?l=Ox" + }, + "Oxygene": { + "color": "#cdd0e3", + "url": "https://github.com/trending?l=Oxygene" + }, + "Oz": { + "color": "#fab738", + "url": "https://github.com/trending?l=Oz" + }, + "P4": { + "color": "#7055b5", + "url": "https://github.com/trending?l=P4" + }, + "Pan": { + "color": "#cc0000", + "url": "https://github.com/trending?l=Pan" + }, + "Papyrus": { + "color": "#6600cc", + "url": "https://github.com/trending?l=Papyrus" + }, + "Parrot": { + "color": "#f3ca0a", + "url": "https://github.com/trending?l=Parrot" + }, + "Parrot Assembly": { + "color": null, + "url": "https://github.com/trending?l=Parrot-Assembly" + }, + "Parrot Internal Representation": { + "color": null, + "url": "https://github.com/trending?l=Parrot-Internal-Representation" + }, + "Pascal": { + "color": "#E3F171", + "url": "https://github.com/trending?l=Pascal" + }, + "Pawn": { + "color": "#dbb284", + "url": "https://github.com/trending?l=Pawn" + }, + "Pep8": { + "color": "#C76F5B", + "url": "https://github.com/trending?l=Pep8" + }, + "Perl": { + "color": "#0298c3", + "url": "https://github.com/trending?l=Perl" + }, + "PHP": { + "color": "#4F5D95", + "url": "https://github.com/trending?l=PHP" + }, + "PicoLisp": { + "color": null, + "url": "https://github.com/trending?l=PicoLisp" + }, + "PigLatin": { + "color": "#fcd7de", + "url": "https://github.com/trending?l=PigLatin" + }, + "Pike": { + "color": "#005390", + "url": "https://github.com/trending?l=Pike" + }, + "PLpgSQL": { + "color": null, + "url": "https://github.com/trending?l=PLpgSQL" + }, + "PLSQL": { + "color": "#dad8d8", + "url": "https://github.com/trending?l=PLSQL" + }, + "PogoScript": { + "color": "#d80074", + "url": "https://github.com/trending?l=PogoScript" + }, + "Pony": { + "color": null, + "url": "https://github.com/trending?l=Pony" + }, + "PostScript": { + "color": "#da291c", + "url": "https://github.com/trending?l=PostScript" + }, + "POV-Ray SDL": { + "color": null, + "url": "https://github.com/trending?l=POV-Ray-SDL" + }, + "PowerBuilder": { + "color": "#8f0f8d", + "url": "https://github.com/trending?l=PowerBuilder" + }, + "PowerShell": { + "color": "#012456", + "url": "https://github.com/trending?l=PowerShell" + }, + "Processing": { + "color": "#0096D8", + "url": "https://github.com/trending?l=Processing" + }, + "Prolog": { + "color": "#74283c", + "url": "https://github.com/trending?l=Prolog" + }, + "Propeller Spin": { + "color": "#7fa2a7", + "url": "https://github.com/trending?l=Propeller-Spin" + }, + "Puppet": { + "color": "#302B6D", + "url": "https://github.com/trending?l=Puppet" + }, + "PureBasic": { + "color": "#5a6986", + "url": "https://github.com/trending?l=PureBasic" + }, + "PureScript": { + "color": "#1D222D", + "url": "https://github.com/trending?l=PureScript" + }, + "Python": { + "color": "#3572A5", + "url": "https://github.com/trending?l=Python" + }, + "Python console": { + "color": null, + "url": "https://github.com/trending?l=Python-console" + }, + "q": { + "color": "#0040cd", + "url": "https://github.com/trending?l=q" + }, + "Q#": { + "color": "#fed659", + "url": "https://github.com/trending?l=Qsharp" + }, + "QMake": { + "color": null, + "url": "https://github.com/trending?l=QMake" + }, + "QML": { + "color": "#44a51c", + "url": "https://github.com/trending?l=QML" + }, + "Qt Script": { + "color": "#00b841", + "url": "https://github.com/trending?l=Qt-Script" + }, + "Quake": { + "color": "#882233", + "url": "https://github.com/trending?l=Quake" + }, + "R": { + "color": "#198CE7", + "url": "https://github.com/trending?l=R" + }, + "Racket": { + "color": "#3c5caa", + "url": "https://github.com/trending?l=Racket" + }, + "Ragel": { + "color": "#9d5200", + "url": "https://github.com/trending?l=Ragel" + }, + "Raku": { + "color": "#0000fb", + "url": "https://github.com/trending?l=Raku" + }, + "RAML": { + "color": "#77d9fb", + "url": "https://github.com/trending?l=RAML" + }, + "Rascal": { + "color": "#fffaa0", + "url": "https://github.com/trending?l=Rascal" + }, + "REALbasic": { + "color": null, + "url": "https://github.com/trending?l=REALbasic" + }, + "Reason": { + "color": "#ff5847", + "url": "https://github.com/trending?l=Reason" + }, + "Rebol": { + "color": "#358a5b", + "url": "https://github.com/trending?l=Rebol" + }, + "Red": { + "color": "#f50000", + "url": "https://github.com/trending?l=Red" + }, + "Redcode": { + "color": null, + "url": "https://github.com/trending?l=Redcode" + }, + "Ren'Py": { + "color": "#ff7f7f", + "url": "https://github.com/trending?l=Ren'Py" + }, + "RenderScript": { + "color": null, + "url": "https://github.com/trending?l=RenderScript" + }, + "REXX": { + "color": null, + "url": "https://github.com/trending?l=REXX" + }, + "Ring": { + "color": "#2D54CB", + "url": "https://github.com/trending?l=Ring" + }, + "Riot": { + "color": "#A71E49", + "url": "https://github.com/trending?l=Riot" + }, + "RobotFramework": { + "color": null, + "url": "https://github.com/trending?l=RobotFramework" + }, + "Roff": { + "color": "#ecdebe", + "url": "https://github.com/trending?l=Roff" + }, + "Rouge": { + "color": "#cc0088", + "url": "https://github.com/trending?l=Rouge" + }, + "RPC": { + "color": null, + "url": "https://github.com/trending?l=RPC" + }, + "Ruby": { + "color": "#701516", + "url": "https://github.com/trending?l=Ruby" + }, + "RUNOFF": { + "color": "#665a4e", + "url": "https://github.com/trending?l=RUNOFF" + }, + "Rust": { + "color": "#dea584", + "url": "https://github.com/trending?l=Rust" + }, + "Sage": { + "color": null, + "url": "https://github.com/trending?l=Sage" + }, + "SaltStack": { + "color": "#646464", + "url": "https://github.com/trending?l=SaltStack" + }, + "SAS": { + "color": "#B34936", + "url": "https://github.com/trending?l=SAS" + }, + "Scala": { + "color": "#c22d40", + "url": "https://github.com/trending?l=Scala" + }, + "Scheme": { + "color": "#1e4aec", + "url": "https://github.com/trending?l=Scheme" + }, + "Scilab": { + "color": null, + "url": "https://github.com/trending?l=Scilab" + }, + "sed": { + "color": "#64b970", + "url": "https://github.com/trending?l=sed" + }, + "Self": { + "color": "#0579aa", + "url": "https://github.com/trending?l=Self" + }, + "ShaderLab": { + "color": null, + "url": "https://github.com/trending?l=ShaderLab" + }, + "Shell": { + "color": "#89e051", + "url": "https://github.com/trending?l=Shell" + }, + "ShellSession": { + "color": null, + "url": "https://github.com/trending?l=ShellSession" + }, + "Shen": { + "color": "#120F14", + "url": "https://github.com/trending?l=Shen" + }, + "Sieve": { + "color": null, + "url": "https://github.com/trending?l=Sieve" + }, + "Slash": { + "color": "#007eff", + "url": "https://github.com/trending?l=Slash" + }, + "Slice": { + "color": "#003fa2", + "url": "https://github.com/trending?l=Slice" + }, + "Smali": { + "color": null, + "url": "https://github.com/trending?l=Smali" + }, + "Smalltalk": { + "color": "#596706", + "url": "https://github.com/trending?l=Smalltalk" + }, + "Smarty": { + "color": null, + "url": "https://github.com/trending?l=Smarty" + }, + "SmPL": { + "color": "#c94949", + "url": "https://github.com/trending?l=SmPL" + }, + "SMT": { + "color": null, + "url": "https://github.com/trending?l=SMT" + }, + "Solidity": { + "color": "#AA6746", + "url": "https://github.com/trending?l=Solidity" + }, + "SourcePawn": { + "color": "#5c7611", + "url": "https://github.com/trending?l=SourcePawn" + }, + "SQF": { + "color": "#3F3F3F", + "url": "https://github.com/trending?l=SQF" + }, + "SQLPL": { + "color": null, + "url": "https://github.com/trending?l=SQLPL" + }, + "Squirrel": { + "color": "#800000", + "url": "https://github.com/trending?l=Squirrel" + }, + "SRecode Template": { + "color": "#348a34", + "url": "https://github.com/trending?l=SRecode-Template" + }, + "Stan": { + "color": "#b2011d", + "url": "https://github.com/trending?l=Stan" + }, + "Standard ML": { + "color": "#dc566d", + "url": "https://github.com/trending?l=Standard-ML" + }, + "Starlark": { + "color": "#76d275", + "url": "https://github.com/trending?l=Starlark" + }, + "Stata": { + "color": null, + "url": "https://github.com/trending?l=Stata" + }, + "SuperCollider": { + "color": "#46390b", + "url": "https://github.com/trending?l=SuperCollider" + }, + "Swift": { + "color": "#ffac45", + "url": "https://github.com/trending?l=Swift" + }, + "SWIG": { + "color": null, + "url": "https://github.com/trending?l=SWIG" + }, + "SystemVerilog": { + "color": "#DAE1C2", + "url": "https://github.com/trending?l=SystemVerilog" + }, + "Tcl": { + "color": "#e4cc98", + "url": "https://github.com/trending?l=Tcl" + }, + "Tcsh": { + "color": null, + "url": "https://github.com/trending?l=Tcsh" + }, + "Terra": { + "color": "#00004c", + "url": "https://github.com/trending?l=Terra" + }, + "TeX": { + "color": "#3D6117", + "url": "https://github.com/trending?l=TeX" + }, + "Thrift": { + "color": null, + "url": "https://github.com/trending?l=Thrift" + }, + "TI Program": { + "color": "#A0AA87", + "url": "https://github.com/trending?l=TI-Program" + }, + "TLA": { + "color": null, + "url": "https://github.com/trending?l=TLA" + }, + "TSQL": { + "color": null, + "url": "https://github.com/trending?l=TSQL" + }, + "TSX": { + "color": null, + "url": "https://github.com/trending?l=TSX" + }, + "Turing": { + "color": "#cf142b", + "url": "https://github.com/trending?l=Turing" + }, + "TXL": { + "color": null, + "url": "https://github.com/trending?l=TXL" + }, + "TypeScript": { + "color": "#2b7489", + "url": "https://github.com/trending?l=TypeScript" + }, + "Unified Parallel C": { + "color": null, + "url": "https://github.com/trending?l=Unified-Parallel-C" + }, + "Unix Assembly": { + "color": null, + "url": "https://github.com/trending?l=Unix-Assembly" + }, + "Uno": { + "color": null, + "url": "https://github.com/trending?l=Uno" + }, + "UnrealScript": { + "color": "#a54c4d", + "url": "https://github.com/trending?l=UnrealScript" + }, + "UrWeb": { + "color": null, + "url": "https://github.com/trending?l=UrWeb" + }, + "V": { + "color": "#5d87bd", + "url": "https://github.com/trending?l=V" + }, + "Vala": { + "color": "#fbe5cd", + "url": "https://github.com/trending?l=Vala" + }, + "VBA": { + "color": "#867db1", + "url": "https://github.com/trending?l=VBA" + }, + "VBScript": { + "color": "#15dcdc", + "url": "https://github.com/trending?l=VBScript" + }, + "VCL": { + "color": "#148AA8", + "url": "https://github.com/trending?l=VCL" + }, + "Verilog": { + "color": "#b2b7f8", + "url": "https://github.com/trending?l=Verilog" + }, + "VHDL": { + "color": "#adb2cb", + "url": "https://github.com/trending?l=VHDL" + }, + "Vim script": { + "color": "#199f4b", + "url": "https://github.com/trending?l=Vim-script" + }, + "Visual Basic .NET": { + "color": "#945db7", + "url": "https://github.com/trending?l=Visual-Basic-.NET" + }, + "Volt": { + "color": "#1F1F1F", + "url": "https://github.com/trending?l=Volt" + }, + "Vue": { + "color": "#2c3e50", + "url": "https://github.com/trending?l=Vue" + }, + "wdl": { + "color": "#42f1f4", + "url": "https://github.com/trending?l=wdl" + }, + "WebAssembly": { + "color": "#04133b", + "url": "https://github.com/trending?l=WebAssembly" + }, + "WebIDL": { + "color": null, + "url": "https://github.com/trending?l=WebIDL" + }, + "wisp": { + "color": "#7582D1", + "url": "https://github.com/trending?l=wisp" + }, + "Wollok": { + "color": "#a23738", + "url": "https://github.com/trending?l=Wollok" + }, + "X10": { + "color": "#4B6BEF", + "url": "https://github.com/trending?l=X10" + }, + "xBase": { + "color": "#403a40", + "url": "https://github.com/trending?l=xBase" + }, + "XC": { + "color": "#99DA07", + "url": "https://github.com/trending?l=XC" + }, + "Xojo": { + "color": null, + "url": "https://github.com/trending?l=Xojo" + }, + "XProc": { + "color": null, + "url": "https://github.com/trending?l=XProc" + }, + "XQuery": { + "color": "#5232e7", + "url": "https://github.com/trending?l=XQuery" + }, + "XS": { + "color": null, + "url": "https://github.com/trending?l=XS" + }, + "XSLT": { + "color": "#EB8CEB", + "url": "https://github.com/trending?l=XSLT" + }, + "Xtend": { + "color": null, + "url": "https://github.com/trending?l=Xtend" + }, + "Yacc": { + "color": "#4B6C4B", + "url": "https://github.com/trending?l=Yacc" + }, + "YARA": { + "color": "#220000", + "url": "https://github.com/trending?l=YARA" + }, + "YASnippet": { + "color": "#32AB90", + "url": "https://github.com/trending?l=YASnippet" + }, + "ZAP": { + "color": "#0d665e", + "url": "https://github.com/trending?l=ZAP" + }, + "Zeek": { + "color": null, + "url": "https://github.com/trending?l=Zeek" + }, + "ZenScript": { + "color": "#00BCD1", + "url": "https://github.com/trending?l=ZenScript" + }, + "Zephir": { + "color": "#118f9e", + "url": "https://github.com/trending?l=Zephir" + }, + "Zig": { + "color": "#ec915c", + "url": "https://github.com/trending?l=Zig" + }, + "ZIL": { + "color": "#dc75e5", + "url": "https://github.com/trending?l=ZIL" + }, + "Zimpl": { + "color": null, + "url": "https://github.com/trending?l=Zimpl" + } +} diff --git a/ChromeExtension/images/house.png b/ChromeExtension/images/house.png new file mode 100644 index 0000000..9c755ea Binary files /dev/null and b/ChromeExtension/images/house.png differ diff --git a/Chart.bundle.js b/ChromeExtension/libraries/Chart.bundle.js similarity index 100% rename from Chart.bundle.js rename to ChromeExtension/libraries/Chart.bundle.js diff --git a/ChromeExtension/libraries/jquery.min.js b/ChromeExtension/libraries/jquery.min.js new file mode 100644 index 0000000..4cf0085 --- /dev/null +++ b/ChromeExtension/libraries/jquery.min.js @@ -0,0 +1,5221 @@ +/*! jQuery v3.6.0 | (c) OpenJS Foundation and other contributors | jquery.org/license */ +!(function (e, t) { + 'use strict'; + 'object' == typeof module && 'object' == typeof module.exports + ? (module.exports = e.document + ? t(e, !0) + : function (e) { + if (!e.document) throw new Error('jQuery requires a window with a document'); + return t(e); + }) + : t(e); +})('undefined' != typeof window ? window : this, function (C, e) { + 'use strict'; + var t = [], + r = Object.getPrototypeOf, + s = t.slice, + g = t.flat + ? function (e) { + return t.flat.call(e); + } + : function (e) { + return t.concat.apply([], e); + }, + u = t.push, + i = t.indexOf, + n = {}, + o = n.toString, + v = n.hasOwnProperty, + a = v.toString, + l = a.call(Object), + y = {}, + m = function (e) { + return ( + 'function' == typeof e && + 'number' != typeof e.nodeType && + 'function' != typeof e.item + ); + }, + x = function (e) { + return null != e && e === e.window; + }, + E = C.document, + c = { type: !0, src: !0, nonce: !0, noModule: !0 }; + function b(e, t, n) { + var r, + i, + o = (n = n || E).createElement('script'); + if (((o.text = e), t)) + for (r in c) + (i = t[r] || (t.getAttribute && t.getAttribute(r))) && o.setAttribute(r, i); + n.head.appendChild(o).parentNode.removeChild(o); + } + function w(e) { + return null == e + ? e + '' + : 'object' == typeof e || 'function' == typeof e + ? n[o.call(e)] || 'object' + : typeof e; + } + var f = '3.6.0', + S = function (e, t) { + return new S.fn.init(e, t); + }; + function p(e) { + var t = !!e && 'length' in e && e.length, + n = w(e); + return ( + !m(e) && + !x(e) && + ('array' === n || 0 === t || ('number' == typeof t && 0 < t && t - 1 in e)) + ); + } + (S.fn = S.prototype = { + jquery: f, + constructor: S, + length: 0, + toArray: function () { + return s.call(this); + }, + get: function (e) { + return null == e ? s.call(this) : e < 0 ? this[e + this.length] : this[e]; + }, + pushStack: function (e) { + var t = S.merge(this.constructor(), e); + return (t.prevObject = this), t; + }, + each: function (e) { + return S.each(this, e); + }, + map: function (n) { + return this.pushStack( + S.map(this, function (e, t) { + return n.call(e, t, e); + }) + ); + }, + slice: function () { + return this.pushStack(s.apply(this, arguments)); + }, + first: function () { + return this.eq(0); + }, + last: function () { + return this.eq(-1); + }, + even: function () { + return this.pushStack( + S.grep(this, function (e, t) { + return (t + 1) % 2; + }) + ); + }, + odd: function () { + return this.pushStack( + S.grep(this, function (e, t) { + return t % 2; + }) + ); + }, + eq: function (e) { + var t = this.length, + n = +e + (e < 0 ? t : 0); + return this.pushStack(0 <= n && n < t ? [this[n]] : []); + }, + end: function () { + return this.prevObject || this.constructor(); + }, + push: u, + sort: t.sort, + splice: t.splice, + }), + (S.extend = S.fn.extend = function () { + var e, + t, + n, + r, + i, + o, + a = arguments[0] || {}, + s = 1, + u = arguments.length, + l = !1; + for ( + 'boolean' == typeof a && ((l = a), (a = arguments[s] || {}), s++), + 'object' == typeof a || m(a) || (a = {}), + s === u && ((a = this), s--); + s < u; + s++ + ) + if (null != (e = arguments[s])) + for (t in e) + (r = e[t]), + '__proto__' !== t && + a !== r && + (l && r && (S.isPlainObject(r) || (i = Array.isArray(r))) + ? ((n = a[t]), + (o = i && !Array.isArray(n) ? [] : i || S.isPlainObject(n) ? n : {}), + (i = !1), + (a[t] = S.extend(l, o, r))) + : void 0 !== r && (a[t] = r)); + return a; + }), + S.extend({ + expando: 'jQuery' + (f + Math.random()).replace(/\D/g, ''), + isReady: !0, + error: function (e) { + throw new Error(e); + }, + noop: function () {}, + isPlainObject: function (e) { + var t, n; + return ( + !(!e || '[object Object]' !== o.call(e)) && + (!(t = r(e)) || + ('function' == typeof (n = v.call(t, 'constructor') && t.constructor) && + a.call(n) === l)) + ); + }, + isEmptyObject: function (e) { + var t; + for (t in e) return !1; + return !0; + }, + globalEval: function (e, t, n) { + b(e, { nonce: t && t.nonce }, n); + }, + each: function (e, t) { + var n, + r = 0; + if (p(e)) { + for (n = e.length; r < n; r++) if (!1 === t.call(e[r], r, e[r])) break; + } else for (r in e) if (!1 === t.call(e[r], r, e[r])) break; + return e; + }, + makeArray: function (e, t) { + var n = t || []; + return ( + null != e && + (p(Object(e)) ? S.merge(n, 'string' == typeof e ? [e] : e) : u.call(n, e)), + n + ); + }, + inArray: function (e, t, n) { + return null == t ? -1 : i.call(t, e, n); + }, + merge: function (e, t) { + for (var n = +t.length, r = 0, i = e.length; r < n; r++) e[i++] = t[r]; + return (e.length = i), e; + }, + grep: function (e, t, n) { + for (var r = [], i = 0, o = e.length, a = !n; i < o; i++) + !t(e[i], i) !== a && r.push(e[i]); + return r; + }, + map: function (e, t, n) { + var r, + i, + o = 0, + a = []; + if (p(e)) for (r = e.length; o < r; o++) null != (i = t(e[o], o, n)) && a.push(i); + else for (o in e) null != (i = t(e[o], o, n)) && a.push(i); + return g(a); + }, + guid: 1, + support: y, + }), + 'function' == typeof Symbol && (S.fn[Symbol.iterator] = t[Symbol.iterator]), + S.each( + 'Boolean Number String Function Array Date RegExp Object Error Symbol'.split(' '), + function (e, t) { + n['[object ' + t + ']'] = t.toLowerCase(); + } + ); + var d = (function (n) { + var e, + d, + b, + o, + i, + h, + f, + g, + w, + u, + l, + T, + C, + a, + E, + v, + s, + c, + y, + S = 'sizzle' + 1 * new Date(), + p = n.document, + k = 0, + r = 0, + m = ue(), + x = ue(), + A = ue(), + N = ue(), + j = function (e, t) { + return e === t && (l = !0), 0; + }, + D = {}.hasOwnProperty, + t = [], + q = t.pop, + L = t.push, + H = t.push, + O = t.slice, + P = function (e, t) { + for (var n = 0, r = e.length; n < r; n++) if (e[n] === t) return n; + return -1; + }, + R = + 'checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped', + M = '[\\x20\\t\\r\\n\\f]', + I = '(?:\\\\[\\da-fA-F]{1,6}' + M + '?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+', + W = + '\\[' + + M + + '*(' + + I + + ')(?:' + + M + + '*([*^$|!~]?=)' + + M + + '*(?:\'((?:\\\\.|[^\\\\\'])*)\'|"((?:\\\\.|[^\\\\"])*)"|(' + + I + + '))|)' + + M + + '*\\]', + F = + ':(' + + I + + ')(?:\\(((\'((?:\\\\.|[^\\\\\'])*)\'|"((?:\\\\.|[^\\\\"])*)")|((?:\\\\.|[^\\\\()[\\]]|' + + W + + ')*)|.*)\\)|)', + B = new RegExp(M + '+', 'g'), + $ = new RegExp('^' + M + '+|((?:^|[^\\\\])(?:\\\\.)*)' + M + '+$', 'g'), + _ = new RegExp('^' + M + '*,' + M + '*'), + z = new RegExp('^' + M + '*([>+~]|' + M + ')' + M + '*'), + U = new RegExp(M + '|>'), + X = new RegExp(F), + V = new RegExp('^' + I + '$'), + G = { + ID: new RegExp('^#(' + I + ')'), + CLASS: new RegExp('^\\.(' + I + ')'), + TAG: new RegExp('^(' + I + '|[*])'), + ATTR: new RegExp('^' + W), + PSEUDO: new RegExp('^' + F), + CHILD: new RegExp( + '^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\(' + + M + + '*(even|odd|(([+-]|)(\\d*)n|)' + + M + + '*(?:([+-]|)' + + M + + '*(\\d+)|))' + + M + + '*\\)|)', + 'i' + ), + bool: new RegExp('^(?:' + R + ')$', 'i'), + needsContext: new RegExp( + '^' + + M + + '*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\(' + + M + + '*((?:-\\d)?\\d*)' + + M + + '*\\)|)(?=[^-]|$)', + 'i' + ), + }, + Y = /HTML$/i, + Q = /^(?:input|select|textarea|button)$/i, + J = /^h\d$/i, + K = /^[^{]+\{\s*\[native \w/, + Z = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/, + ee = /[+~]/, + te = new RegExp('\\\\[\\da-fA-F]{1,6}' + M + '?|\\\\([^\\r\\n\\f])', 'g'), + ne = function (e, t) { + var n = '0x' + e.slice(1) - 65536; + return ( + t || + (n < 0 + ? String.fromCharCode(n + 65536) + : String.fromCharCode((n >> 10) | 55296, (1023 & n) | 56320)) + ); + }, + re = /([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g, + ie = function (e, t) { + return t + ? '\0' === e + ? '\ufffd' + : e.slice(0, -1) + '\\' + e.charCodeAt(e.length - 1).toString(16) + ' ' + : '\\' + e; + }, + oe = function () { + T(); + }, + ae = be( + function (e) { + return !0 === e.disabled && 'fieldset' === e.nodeName.toLowerCase(); + }, + { dir: 'parentNode', next: 'legend' } + ); + try { + H.apply((t = O.call(p.childNodes)), p.childNodes), t[p.childNodes.length].nodeType; + } catch (e) { + H = { + apply: t.length + ? function (e, t) { + L.apply(e, O.call(t)); + } + : function (e, t) { + var n = e.length, + r = 0; + while ((e[n++] = t[r++])); + e.length = n - 1; + }, + }; + } + function se(t, e, n, r) { + var i, + o, + a, + s, + u, + l, + c, + f = e && e.ownerDocument, + p = e ? e.nodeType : 9; + if (((n = n || []), 'string' != typeof t || !t || (1 !== p && 9 !== p && 11 !== p))) + return n; + if (!r && (T(e), (e = e || C), E)) { + if (11 !== p && (u = Z.exec(t))) + if ((i = u[1])) { + if (9 === p) { + if (!(a = e.getElementById(i))) return n; + if (a.id === i) return n.push(a), n; + } else if (f && (a = f.getElementById(i)) && y(e, a) && a.id === i) + return n.push(a), n; + } else { + if (u[2]) return H.apply(n, e.getElementsByTagName(t)), n; + if ((i = u[3]) && d.getElementsByClassName && e.getElementsByClassName) + return H.apply(n, e.getElementsByClassName(i)), n; + } + if ( + d.qsa && + !N[t + ' '] && + (!v || !v.test(t)) && + (1 !== p || 'object' !== e.nodeName.toLowerCase()) + ) { + if (((c = t), (f = e), 1 === p && (U.test(t) || z.test(t)))) { + ((f = (ee.test(t) && ye(e.parentNode)) || e) === e && d.scope) || + ((s = e.getAttribute('id')) + ? (s = s.replace(re, ie)) + : e.setAttribute('id', (s = S))), + (o = (l = h(t)).length); + while (o--) l[o] = (s ? '#' + s : ':scope') + ' ' + xe(l[o]); + c = l.join(','); + } + try { + return H.apply(n, f.querySelectorAll(c)), n; + } catch (e) { + N(t, !0); + } finally { + s === S && e.removeAttribute('id'); + } + } + } + return g(t.replace($, '$1'), e, n, r); + } + function ue() { + var r = []; + return function e(t, n) { + return r.push(t + ' ') > b.cacheLength && delete e[r.shift()], (e[t + ' '] = n); + }; + } + function le(e) { + return (e[S] = !0), e; + } + function ce(e) { + var t = C.createElement('fieldset'); + try { + return !!e(t); + } catch (e) { + return !1; + } finally { + t.parentNode && t.parentNode.removeChild(t), (t = null); + } + } + function fe(e, t) { + var n = e.split('|'), + r = n.length; + while (r--) b.attrHandle[n[r]] = t; + } + function pe(e, t) { + var n = t && e, + r = n && 1 === e.nodeType && 1 === t.nodeType && e.sourceIndex - t.sourceIndex; + if (r) return r; + if (n) while ((n = n.nextSibling)) if (n === t) return -1; + return e ? 1 : -1; + } + function de(t) { + return function (e) { + return 'input' === e.nodeName.toLowerCase() && e.type === t; + }; + } + function he(n) { + return function (e) { + var t = e.nodeName.toLowerCase(); + return ('input' === t || 'button' === t) && e.type === n; + }; + } + function ge(t) { + return function (e) { + return 'form' in e + ? e.parentNode && !1 === e.disabled + ? 'label' in e + ? 'label' in e.parentNode + ? e.parentNode.disabled === t + : e.disabled === t + : e.isDisabled === t || (e.isDisabled !== !t && ae(e) === t) + : e.disabled === t + : 'label' in e && e.disabled === t; + }; + } + function ve(a) { + return le(function (o) { + return ( + (o = +o), + le(function (e, t) { + var n, + r = a([], e.length, o), + i = r.length; + while (i--) e[(n = r[i])] && (e[n] = !(t[n] = e[n])); + }) + ); + }); + } + function ye(e) { + return e && 'undefined' != typeof e.getElementsByTagName && e; + } + for (e in ((d = se.support = {}), + (i = se.isXML = function (e) { + var t = e && e.namespaceURI, + n = e && (e.ownerDocument || e).documentElement; + return !Y.test(t || (n && n.nodeName) || 'HTML'); + }), + (T = se.setDocument = function (e) { + var t, + n, + r = e ? e.ownerDocument || e : p; + return ( + r != C && + 9 === r.nodeType && + r.documentElement && + ((a = (C = r).documentElement), + (E = !i(C)), + p != C && + (n = C.defaultView) && + n.top !== n && + (n.addEventListener + ? n.addEventListener('unload', oe, !1) + : n.attachEvent && n.attachEvent('onunload', oe)), + (d.scope = ce(function (e) { + return ( + a.appendChild(e).appendChild(C.createElement('div')), + 'undefined' != typeof e.querySelectorAll && + !e.querySelectorAll(':scope fieldset div').length + ); + })), + (d.attributes = ce(function (e) { + return (e.className = 'i'), !e.getAttribute('className'); + })), + (d.getElementsByTagName = ce(function (e) { + return ( + e.appendChild(C.createComment('')), !e.getElementsByTagName('*').length + ); + })), + (d.getElementsByClassName = K.test(C.getElementsByClassName)), + (d.getById = ce(function (e) { + return ( + (a.appendChild(e).id = S), + !C.getElementsByName || !C.getElementsByName(S).length + ); + })), + d.getById + ? ((b.filter.ID = function (e) { + var t = e.replace(te, ne); + return function (e) { + return e.getAttribute('id') === t; + }; + }), + (b.find.ID = function (e, t) { + if ('undefined' != typeof t.getElementById && E) { + var n = t.getElementById(e); + return n ? [n] : []; + } + })) + : ((b.filter.ID = function (e) { + var n = e.replace(te, ne); + return function (e) { + var t = + 'undefined' != typeof e.getAttributeNode && e.getAttributeNode('id'); + return t && t.value === n; + }; + }), + (b.find.ID = function (e, t) { + if ('undefined' != typeof t.getElementById && E) { + var n, + r, + i, + o = t.getElementById(e); + if (o) { + if ((n = o.getAttributeNode('id')) && n.value === e) return [o]; + (i = t.getElementsByName(e)), (r = 0); + while ((o = i[r++])) + if ((n = o.getAttributeNode('id')) && n.value === e) return [o]; + } + return []; + } + })), + (b.find.TAG = d.getElementsByTagName + ? function (e, t) { + return 'undefined' != typeof t.getElementsByTagName + ? t.getElementsByTagName(e) + : d.qsa + ? t.querySelectorAll(e) + : void 0; + } + : function (e, t) { + var n, + r = [], + i = 0, + o = t.getElementsByTagName(e); + if ('*' === e) { + while ((n = o[i++])) 1 === n.nodeType && r.push(n); + return r; + } + return o; + }), + (b.find.CLASS = + d.getElementsByClassName && + function (e, t) { + if ('undefined' != typeof t.getElementsByClassName && E) + return t.getElementsByClassName(e); + }), + (s = []), + (v = []), + (d.qsa = K.test(C.querySelectorAll)) && + (ce(function (e) { + var t; + (a.appendChild(e).innerHTML = + ""), + e.querySelectorAll("[msallowcapture^='']").length && + v.push('[*^$]=' + M + '*(?:\'\'|"")'), + e.querySelectorAll('[selected]').length || + v.push('\\[' + M + '*(?:value|' + R + ')'), + e.querySelectorAll('[id~=' + S + '-]').length || v.push('~='), + (t = C.createElement('input')).setAttribute('name', ''), + e.appendChild(t), + e.querySelectorAll("[name='']").length || + v.push('\\[' + M + '*name' + M + '*=' + M + '*(?:\'\'|"")'), + e.querySelectorAll(':checked').length || v.push(':checked'), + e.querySelectorAll('a#' + S + '+*').length || v.push('.#.+[+~]'), + e.querySelectorAll('\\\f'), + v.push('[\\r\\n\\f]'); + }), + ce(function (e) { + e.innerHTML = + ""; + var t = C.createElement('input'); + t.setAttribute('type', 'hidden'), + e.appendChild(t).setAttribute('name', 'D'), + e.querySelectorAll('[name=d]').length && + v.push('name' + M + '*[*^$|!~]?='), + 2 !== e.querySelectorAll(':enabled').length && + v.push(':enabled', ':disabled'), + (a.appendChild(e).disabled = !0), + 2 !== e.querySelectorAll(':disabled').length && + v.push(':enabled', ':disabled'), + e.querySelectorAll('*,:x'), + v.push(',.*:'); + })), + (d.matchesSelector = K.test( + (c = + a.matches || + a.webkitMatchesSelector || + a.mozMatchesSelector || + a.oMatchesSelector || + a.msMatchesSelector) + )) && + ce(function (e) { + (d.disconnectedMatch = c.call(e, '*')), + c.call(e, "[s!='']:x"), + s.push('!=', F); + }), + (v = v.length && new RegExp(v.join('|'))), + (s = s.length && new RegExp(s.join('|'))), + (t = K.test(a.compareDocumentPosition)), + (y = + t || K.test(a.contains) + ? function (e, t) { + var n = 9 === e.nodeType ? e.documentElement : e, + r = t && t.parentNode; + return ( + e === r || + !( + !r || + 1 !== r.nodeType || + !(n.contains + ? n.contains(r) + : e.compareDocumentPosition && 16 & e.compareDocumentPosition(r)) + ) + ); + } + : function (e, t) { + if (t) while ((t = t.parentNode)) if (t === e) return !0; + return !1; + }), + (j = t + ? function (e, t) { + if (e === t) return (l = !0), 0; + var n = !e.compareDocumentPosition - !t.compareDocumentPosition; + return ( + n || + (1 & + (n = + (e.ownerDocument || e) == (t.ownerDocument || t) + ? e.compareDocumentPosition(t) + : 1) || + (!d.sortDetached && t.compareDocumentPosition(e) === n) + ? e == C || (e.ownerDocument == p && y(p, e)) + ? -1 + : t == C || (t.ownerDocument == p && y(p, t)) + ? 1 + : u + ? P(u, e) - P(u, t) + : 0 + : 4 & n + ? -1 + : 1) + ); + } + : function (e, t) { + if (e === t) return (l = !0), 0; + var n, + r = 0, + i = e.parentNode, + o = t.parentNode, + a = [e], + s = [t]; + if (!i || !o) + return e == C + ? -1 + : t == C + ? 1 + : i + ? -1 + : o + ? 1 + : u + ? P(u, e) - P(u, t) + : 0; + if (i === o) return pe(e, t); + n = e; + while ((n = n.parentNode)) a.unshift(n); + n = t; + while ((n = n.parentNode)) s.unshift(n); + while (a[r] === s[r]) r++; + return r ? pe(a[r], s[r]) : a[r] == p ? -1 : s[r] == p ? 1 : 0; + })), + C + ); + }), + (se.matches = function (e, t) { + return se(e, null, null, t); + }), + (se.matchesSelector = function (e, t) { + if ( + (T(e), + d.matchesSelector && E && !N[t + ' '] && (!s || !s.test(t)) && (!v || !v.test(t))) + ) + try { + var n = c.call(e, t); + if (n || d.disconnectedMatch || (e.document && 11 !== e.document.nodeType)) + return n; + } catch (e) { + N(t, !0); + } + return 0 < se(t, C, null, [e]).length; + }), + (se.contains = function (e, t) { + return (e.ownerDocument || e) != C && T(e), y(e, t); + }), + (se.attr = function (e, t) { + (e.ownerDocument || e) != C && T(e); + var n = b.attrHandle[t.toLowerCase()], + r = n && D.call(b.attrHandle, t.toLowerCase()) ? n(e, t, !E) : void 0; + return void 0 !== r + ? r + : d.attributes || !E + ? e.getAttribute(t) + : (r = e.getAttributeNode(t)) && r.specified + ? r.value + : null; + }), + (se.escape = function (e) { + return (e + '').replace(re, ie); + }), + (se.error = function (e) { + throw new Error('Syntax error, unrecognized expression: ' + e); + }), + (se.uniqueSort = function (e) { + var t, + n = [], + r = 0, + i = 0; + if (((l = !d.detectDuplicates), (u = !d.sortStable && e.slice(0)), e.sort(j), l)) { + while ((t = e[i++])) t === e[i] && (r = n.push(i)); + while (r--) e.splice(n[r], 1); + } + return (u = null), e; + }), + (o = se.getText = function (e) { + var t, + n = '', + r = 0, + i = e.nodeType; + if (i) { + if (1 === i || 9 === i || 11 === i) { + if ('string' == typeof e.textContent) return e.textContent; + for (e = e.firstChild; e; e = e.nextSibling) n += o(e); + } else if (3 === i || 4 === i) return e.nodeValue; + } else while ((t = e[r++])) n += o(t); + return n; + }), + ((b = se.selectors = { + cacheLength: 50, + createPseudo: le, + match: G, + attrHandle: {}, + find: {}, + relative: { + '>': { dir: 'parentNode', first: !0 }, + ' ': { dir: 'parentNode' }, + '+': { dir: 'previousSibling', first: !0 }, + '~': { dir: 'previousSibling' }, + }, + preFilter: { + ATTR: function (e) { + return ( + (e[1] = e[1].replace(te, ne)), + (e[3] = (e[3] || e[4] || e[5] || '').replace(te, ne)), + '~=' === e[2] && (e[3] = ' ' + e[3] + ' '), + e.slice(0, 4) + ); + }, + CHILD: function (e) { + return ( + (e[1] = e[1].toLowerCase()), + 'nth' === e[1].slice(0, 3) + ? (e[3] || se.error(e[0]), + (e[4] = +(e[4] + ? e[5] + (e[6] || 1) + : 2 * ('even' === e[3] || 'odd' === e[3]))), + (e[5] = +(e[7] + e[8] || 'odd' === e[3]))) + : e[3] && se.error(e[0]), + e + ); + }, + PSEUDO: function (e) { + var t, + n = !e[6] && e[2]; + return G.CHILD.test(e[0]) + ? null + : (e[3] + ? (e[2] = e[4] || e[5] || '') + : n && + X.test(n) && + (t = h(n, !0)) && + (t = n.indexOf(')', n.length - t) - n.length) && + ((e[0] = e[0].slice(0, t)), (e[2] = n.slice(0, t))), + e.slice(0, 3)); + }, + }, + filter: { + TAG: function (e) { + var t = e.replace(te, ne).toLowerCase(); + return '*' === e + ? function () { + return !0; + } + : function (e) { + return e.nodeName && e.nodeName.toLowerCase() === t; + }; + }, + CLASS: function (e) { + var t = m[e + ' ']; + return ( + t || + ((t = new RegExp('(^|' + M + ')' + e + '(' + M + '|$)')) && + m(e, function (e) { + return t.test( + ('string' == typeof e.className && e.className) || + ('undefined' != typeof e.getAttribute && e.getAttribute('class')) || + '' + ); + })) + ); + }, + ATTR: function (n, r, i) { + return function (e) { + var t = se.attr(e, n); + return null == t + ? '!=' === r + : !r || + ((t += ''), + '=' === r + ? t === i + : '!=' === r + ? t !== i + : '^=' === r + ? i && 0 === t.indexOf(i) + : '*=' === r + ? i && -1 < t.indexOf(i) + : '$=' === r + ? i && t.slice(-i.length) === i + : '~=' === r + ? -1 < (' ' + t.replace(B, ' ') + ' ').indexOf(i) + : '|=' === r && (t === i || t.slice(0, i.length + 1) === i + '-')); + }; + }, + CHILD: function (h, e, t, g, v) { + var y = 'nth' !== h.slice(0, 3), + m = 'last' !== h.slice(-4), + x = 'of-type' === e; + return 1 === g && 0 === v + ? function (e) { + return !!e.parentNode; + } + : function (e, t, n) { + var r, + i, + o, + a, + s, + u, + l = y !== m ? 'nextSibling' : 'previousSibling', + c = e.parentNode, + f = x && e.nodeName.toLowerCase(), + p = !n && !x, + d = !1; + if (c) { + if (y) { + while (l) { + a = e; + while ((a = a[l])) + if (x ? a.nodeName.toLowerCase() === f : 1 === a.nodeType) + return !1; + u = l = 'only' === h && !u && 'nextSibling'; + } + return !0; + } + if (((u = [m ? c.firstChild : c.lastChild]), m && p)) { + (d = + (s = + (r = + (i = + (o = (a = c)[S] || (a[S] = {}))[a.uniqueID] || + (o[a.uniqueID] = {}))[h] || [])[0] === k && r[1]) && r[2]), + (a = s && c.childNodes[s]); + while ((a = (++s && a && a[l]) || (d = s = 0) || u.pop())) + if (1 === a.nodeType && ++d && a === e) { + i[h] = [k, s, d]; + break; + } + } else if ( + (p && + (d = s = + (r = + (i = + (o = (a = e)[S] || (a[S] = {}))[a.uniqueID] || + (o[a.uniqueID] = {}))[h] || [])[0] === k && r[1]), + !1 === d) + ) + while ((a = (++s && a && a[l]) || (d = s = 0) || u.pop())) + if ( + (x ? a.nodeName.toLowerCase() === f : 1 === a.nodeType) && + ++d && + (p && + ((i = + (o = a[S] || (a[S] = {}))[a.uniqueID] || + (o[a.uniqueID] = {}))[h] = [k, d]), + a === e) + ) + break; + return (d -= v) === g || (d % g == 0 && 0 <= d / g); + } + }; + }, + PSEUDO: function (e, o) { + var t, + a = + b.pseudos[e] || + b.setFilters[e.toLowerCase()] || + se.error('unsupported pseudo: ' + e); + return a[S] + ? a(o) + : 1 < a.length + ? ((t = [e, e, '', o]), + b.setFilters.hasOwnProperty(e.toLowerCase()) + ? le(function (e, t) { + var n, + r = a(e, o), + i = r.length; + while (i--) e[(n = P(e, r[i]))] = !(t[n] = r[i]); + }) + : function (e) { + return a(e, 0, t); + }) + : a; + }, + }, + pseudos: { + not: le(function (e) { + var r = [], + i = [], + s = f(e.replace($, '$1')); + return s[S] + ? le(function (e, t, n, r) { + var i, + o = s(e, null, r, []), + a = e.length; + while (a--) (i = o[a]) && (e[a] = !(t[a] = i)); + }) + : function (e, t, n) { + return (r[0] = e), s(r, null, n, i), (r[0] = null), !i.pop(); + }; + }), + has: le(function (t) { + return function (e) { + return 0 < se(t, e).length; + }; + }), + contains: le(function (t) { + return ( + (t = t.replace(te, ne)), + function (e) { + return -1 < (e.textContent || o(e)).indexOf(t); + } + ); + }), + lang: le(function (n) { + return ( + V.test(n || '') || se.error('unsupported lang: ' + n), + (n = n.replace(te, ne).toLowerCase()), + function (e) { + var t; + do { + if ( + (t = E ? e.lang : e.getAttribute('xml:lang') || e.getAttribute('lang')) + ) + return (t = t.toLowerCase()) === n || 0 === t.indexOf(n + '-'); + } while ((e = e.parentNode) && 1 === e.nodeType); + return !1; + } + ); + }), + target: function (e) { + var t = n.location && n.location.hash; + return t && t.slice(1) === e.id; + }, + root: function (e) { + return e === a; + }, + focus: function (e) { + return ( + e === C.activeElement && + (!C.hasFocus || C.hasFocus()) && + !!(e.type || e.href || ~e.tabIndex) + ); + }, + enabled: ge(!1), + disabled: ge(!0), + checked: function (e) { + var t = e.nodeName.toLowerCase(); + return ('input' === t && !!e.checked) || ('option' === t && !!e.selected); + }, + selected: function (e) { + return e.parentNode && e.parentNode.selectedIndex, !0 === e.selected; + }, + empty: function (e) { + for (e = e.firstChild; e; e = e.nextSibling) if (e.nodeType < 6) return !1; + return !0; + }, + parent: function (e) { + return !b.pseudos.empty(e); + }, + header: function (e) { + return J.test(e.nodeName); + }, + input: function (e) { + return Q.test(e.nodeName); + }, + button: function (e) { + var t = e.nodeName.toLowerCase(); + return ('input' === t && 'button' === e.type) || 'button' === t; + }, + text: function (e) { + var t; + return ( + 'input' === e.nodeName.toLowerCase() && + 'text' === e.type && + (null == (t = e.getAttribute('type')) || 'text' === t.toLowerCase()) + ); + }, + first: ve(function () { + return [0]; + }), + last: ve(function (e, t) { + return [t - 1]; + }), + eq: ve(function (e, t, n) { + return [n < 0 ? n + t : n]; + }), + even: ve(function (e, t) { + for (var n = 0; n < t; n += 2) e.push(n); + return e; + }), + odd: ve(function (e, t) { + for (var n = 1; n < t; n += 2) e.push(n); + return e; + }), + lt: ve(function (e, t, n) { + for (var r = n < 0 ? n + t : t < n ? t : n; 0 <= --r; ) e.push(r); + return e; + }), + gt: ve(function (e, t, n) { + for (var r = n < 0 ? n + t : n; ++r < t; ) e.push(r); + return e; + }), + }, + }).pseudos.nth = b.pseudos.eq), + { radio: !0, checkbox: !0, file: !0, password: !0, image: !0 })) + b.pseudos[e] = de(e); + for (e in { submit: !0, reset: !0 }) b.pseudos[e] = he(e); + function me() {} + function xe(e) { + for (var t = 0, n = e.length, r = ''; t < n; t++) r += e[t].value; + return r; + } + function be(s, e, t) { + var u = e.dir, + l = e.next, + c = l || u, + f = t && 'parentNode' === c, + p = r++; + return e.first + ? function (e, t, n) { + while ((e = e[u])) if (1 === e.nodeType || f) return s(e, t, n); + return !1; + } + : function (e, t, n) { + var r, + i, + o, + a = [k, p]; + if (n) { + while ((e = e[u])) if ((1 === e.nodeType || f) && s(e, t, n)) return !0; + } else + while ((e = e[u])) + if (1 === e.nodeType || f) + if ( + ((i = (o = e[S] || (e[S] = {}))[e.uniqueID] || (o[e.uniqueID] = {})), + l && l === e.nodeName.toLowerCase()) + ) + e = e[u] || e; + else { + if ((r = i[c]) && r[0] === k && r[1] === p) return (a[2] = r[2]); + if (((i[c] = a)[2] = s(e, t, n))) return !0; + } + return !1; + }; + } + function we(i) { + return 1 < i.length + ? function (e, t, n) { + var r = i.length; + while (r--) if (!i[r](e, t, n)) return !1; + return !0; + } + : i[0]; + } + function Te(e, t, n, r, i) { + for (var o, a = [], s = 0, u = e.length, l = null != t; s < u; s++) + (o = e[s]) && ((n && !n(o, r, i)) || (a.push(o), l && t.push(s))); + return a; + } + function Ce(d, h, g, v, y, e) { + return ( + v && !v[S] && (v = Ce(v)), + y && !y[S] && (y = Ce(y, e)), + le(function (e, t, n, r) { + var i, + o, + a, + s = [], + u = [], + l = t.length, + c = + e || + (function (e, t, n) { + for (var r = 0, i = t.length; r < i; r++) se(e, t[r], n); + return n; + })(h || '*', n.nodeType ? [n] : n, []), + f = !d || (!e && h) ? c : Te(c, s, d, n, r), + p = g ? (y || (e ? d : l || v) ? [] : t) : f; + if ((g && g(f, p, n, r), v)) { + (i = Te(p, u)), v(i, [], n, r), (o = i.length); + while (o--) (a = i[o]) && (p[u[o]] = !(f[u[o]] = a)); + } + if (e) { + if (y || d) { + if (y) { + (i = []), (o = p.length); + while (o--) (a = p[o]) && i.push((f[o] = a)); + y(null, (p = []), i, r); + } + o = p.length; + while (o--) + (a = p[o]) && -1 < (i = y ? P(e, a) : s[o]) && (e[i] = !(t[i] = a)); + } + } else (p = Te(p === t ? p.splice(l, p.length) : p)), y ? y(null, t, p, r) : H.apply(t, p); + }) + ); + } + function Ee(e) { + for ( + var i, + t, + n, + r = e.length, + o = b.relative[e[0].type], + a = o || b.relative[' '], + s = o ? 1 : 0, + u = be( + function (e) { + return e === i; + }, + a, + !0 + ), + l = be( + function (e) { + return -1 < P(i, e); + }, + a, + !0 + ), + c = [ + function (e, t, n) { + var r = + (!o && (n || t !== w)) || ((i = t).nodeType ? u(e, t, n) : l(e, t, n)); + return (i = null), r; + }, + ]; + s < r; + s++ + ) + if ((t = b.relative[e[s].type])) c = [be(we(c), t)]; + else { + if ((t = b.filter[e[s].type].apply(null, e[s].matches))[S]) { + for (n = ++s; n < r; n++) if (b.relative[e[n].type]) break; + return Ce( + 1 < s && we(c), + 1 < s && + xe( + e.slice(0, s - 1).concat({ value: ' ' === e[s - 2].type ? '*' : '' }) + ).replace($, '$1'), + t, + s < n && Ee(e.slice(s, n)), + n < r && Ee((e = e.slice(n))), + n < r && xe(e) + ); + } + c.push(t); + } + return we(c); + } + return ( + (me.prototype = b.filters = b.pseudos), + (b.setFilters = new me()), + (h = se.tokenize = function (e, t) { + var n, + r, + i, + o, + a, + s, + u, + l = x[e + ' ']; + if (l) return t ? 0 : l.slice(0); + (a = e), (s = []), (u = b.preFilter); + while (a) { + for (o in ((n && !(r = _.exec(a))) || + (r && (a = a.slice(r[0].length) || a), s.push((i = []))), + (n = !1), + (r = z.exec(a)) && + ((n = r.shift()), + i.push({ value: n, type: r[0].replace($, ' ') }), + (a = a.slice(n.length))), + b.filter)) + !(r = G[o].exec(a)) || + (u[o] && !(r = u[o](r))) || + ((n = r.shift()), + i.push({ value: n, type: o, matches: r }), + (a = a.slice(n.length))); + if (!n) break; + } + return t ? a.length : a ? se.error(e) : x(e, s).slice(0); + }), + (f = se.compile = function (e, t) { + var n, + v, + y, + m, + x, + r, + i = [], + o = [], + a = A[e + ' ']; + if (!a) { + t || (t = h(e)), (n = t.length); + while (n--) (a = Ee(t[n]))[S] ? i.push(a) : o.push(a); + (a = A( + e, + ((v = o), + (m = 0 < (y = i).length), + (x = 0 < v.length), + (r = function (e, t, n, r, i) { + var o, + a, + s, + u = 0, + l = '0', + c = e && [], + f = [], + p = w, + d = e || (x && b.find.TAG('*', i)), + h = (k += null == p ? 1 : Math.random() || 0.1), + g = d.length; + for (i && (w = t == C || t || i); l !== g && null != (o = d[l]); l++) { + if (x && o) { + (a = 0), t || o.ownerDocument == C || (T(o), (n = !E)); + while ((s = v[a++])) + if (s(o, t || C, n)) { + r.push(o); + break; + } + i && (k = h); + } + m && ((o = !s && o) && u--, e && c.push(o)); + } + if (((u += l), m && l !== u)) { + a = 0; + while ((s = y[a++])) s(c, f, t, n); + if (e) { + if (0 < u) while (l--) c[l] || f[l] || (f[l] = q.call(r)); + f = Te(f); + } + H.apply(r, f), + i && !e && 0 < f.length && 1 < u + y.length && se.uniqueSort(r); + } + return i && ((k = h), (w = p)), c; + }), + m ? le(r) : r) + )).selector = e; + } + return a; + }), + (g = se.select = function (e, t, n, r) { + var i, + o, + a, + s, + u, + l = 'function' == typeof e && e, + c = !r && h((e = l.selector || e)); + if (((n = n || []), 1 === c.length)) { + if ( + 2 < (o = c[0] = c[0].slice(0)).length && + 'ID' === (a = o[0]).type && + 9 === t.nodeType && + E && + b.relative[o[1].type] + ) { + if (!(t = (b.find.ID(a.matches[0].replace(te, ne), t) || [])[0])) return n; + l && (t = t.parentNode), (e = e.slice(o.shift().value.length)); + } + i = G.needsContext.test(e) ? 0 : o.length; + while (i--) { + if (((a = o[i]), b.relative[(s = a.type)])) break; + if ( + (u = b.find[s]) && + (r = u( + a.matches[0].replace(te, ne), + (ee.test(o[0].type) && ye(t.parentNode)) || t + )) + ) { + if ((o.splice(i, 1), !(e = r.length && xe(o)))) return H.apply(n, r), n; + break; + } + } + } + return ( + (l || f(e, c))(r, t, !E, n, !t || (ee.test(e) && ye(t.parentNode)) || t), n + ); + }), + (d.sortStable = S.split('').sort(j).join('') === S), + (d.detectDuplicates = !!l), + T(), + (d.sortDetached = ce(function (e) { + return 1 & e.compareDocumentPosition(C.createElement('fieldset')); + })), + ce(function (e) { + return ( + (e.innerHTML = ""), '#' === e.firstChild.getAttribute('href') + ); + }) || + fe('type|href|height|width', function (e, t, n) { + if (!n) return e.getAttribute(t, 'type' === t.toLowerCase() ? 1 : 2); + }), + (d.attributes && + ce(function (e) { + return ( + (e.innerHTML = ''), + e.firstChild.setAttribute('value', ''), + '' === e.firstChild.getAttribute('value') + ); + })) || + fe('value', function (e, t, n) { + if (!n && 'input' === e.nodeName.toLowerCase()) return e.defaultValue; + }), + ce(function (e) { + return null == e.getAttribute('disabled'); + }) || + fe(R, function (e, t, n) { + var r; + if (!n) + return !0 === e[t] + ? t.toLowerCase() + : (r = e.getAttributeNode(t)) && r.specified + ? r.value + : null; + }), + se + ); + })(C); + (S.find = d), + (S.expr = d.selectors), + (S.expr[':'] = S.expr.pseudos), + (S.uniqueSort = S.unique = d.uniqueSort), + (S.text = d.getText), + (S.isXMLDoc = d.isXML), + (S.contains = d.contains), + (S.escapeSelector = d.escape); + var h = function (e, t, n) { + var r = [], + i = void 0 !== n; + while ((e = e[t]) && 9 !== e.nodeType) + if (1 === e.nodeType) { + if (i && S(e).is(n)) break; + r.push(e); + } + return r; + }, + T = function (e, t) { + for (var n = []; e; e = e.nextSibling) 1 === e.nodeType && e !== t && n.push(e); + return n; + }, + k = S.expr.match.needsContext; + function A(e, t) { + return e.nodeName && e.nodeName.toLowerCase() === t.toLowerCase(); + } + var N = /^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i; + function j(e, n, r) { + return m(n) + ? S.grep(e, function (e, t) { + return !!n.call(e, t, e) !== r; + }) + : n.nodeType + ? S.grep(e, function (e) { + return (e === n) !== r; + }) + : 'string' != typeof n + ? S.grep(e, function (e) { + return -1 < i.call(n, e) !== r; + }) + : S.filter(n, e, r); + } + (S.filter = function (e, t, n) { + var r = t[0]; + return ( + n && (e = ':not(' + e + ')'), + 1 === t.length && 1 === r.nodeType + ? S.find.matchesSelector(r, e) + ? [r] + : [] + : S.find.matches( + e, + S.grep(t, function (e) { + return 1 === e.nodeType; + }) + ) + ); + }), + S.fn.extend({ + find: function (e) { + var t, + n, + r = this.length, + i = this; + if ('string' != typeof e) + return this.pushStack( + S(e).filter(function () { + for (t = 0; t < r; t++) if (S.contains(i[t], this)) return !0; + }) + ); + for (n = this.pushStack([]), t = 0; t < r; t++) S.find(e, i[t], n); + return 1 < r ? S.uniqueSort(n) : n; + }, + filter: function (e) { + return this.pushStack(j(this, e || [], !1)); + }, + not: function (e) { + return this.pushStack(j(this, e || [], !0)); + }, + is: function (e) { + return !!j(this, 'string' == typeof e && k.test(e) ? S(e) : e || [], !1).length; + }, + }); + var D, + q = /^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/; + ((S.fn.init = function (e, t, n) { + var r, i; + if (!e) return this; + if (((n = n || D), 'string' == typeof e)) { + if ( + !(r = + '<' === e[0] && '>' === e[e.length - 1] && 3 <= e.length + ? [null, e, null] + : q.exec(e)) || + (!r[1] && t) + ) + return !t || t.jquery ? (t || n).find(e) : this.constructor(t).find(e); + if (r[1]) { + if ( + ((t = t instanceof S ? t[0] : t), + S.merge( + this, + S.parseHTML(r[1], t && t.nodeType ? t.ownerDocument || t : E, !0) + ), + N.test(r[1]) && S.isPlainObject(t)) + ) + for (r in t) m(this[r]) ? this[r](t[r]) : this.attr(r, t[r]); + return this; + } + return (i = E.getElementById(r[2])) && ((this[0] = i), (this.length = 1)), this; + } + return e.nodeType + ? ((this[0] = e), (this.length = 1), this) + : m(e) + ? void 0 !== n.ready + ? n.ready(e) + : e(S) + : S.makeArray(e, this); + }).prototype = S.fn), + (D = S(E)); + var L = /^(?:parents|prev(?:Until|All))/, + H = { children: !0, contents: !0, next: !0, prev: !0 }; + function O(e, t) { + while ((e = e[t]) && 1 !== e.nodeType); + return e; + } + S.fn.extend({ + has: function (e) { + var t = S(e, this), + n = t.length; + return this.filter(function () { + for (var e = 0; e < n; e++) if (S.contains(this, t[e])) return !0; + }); + }, + closest: function (e, t) { + var n, + r = 0, + i = this.length, + o = [], + a = 'string' != typeof e && S(e); + if (!k.test(e)) + for (; r < i; r++) + for (n = this[r]; n && n !== t; n = n.parentNode) + if ( + n.nodeType < 11 && + (a ? -1 < a.index(n) : 1 === n.nodeType && S.find.matchesSelector(n, e)) + ) { + o.push(n); + break; + } + return this.pushStack(1 < o.length ? S.uniqueSort(o) : o); + }, + index: function (e) { + return e + ? 'string' == typeof e + ? i.call(S(e), this[0]) + : i.call(this, e.jquery ? e[0] : e) + : this[0] && this[0].parentNode + ? this.first().prevAll().length + : -1; + }, + add: function (e, t) { + return this.pushStack(S.uniqueSort(S.merge(this.get(), S(e, t)))); + }, + addBack: function (e) { + return this.add(null == e ? this.prevObject : this.prevObject.filter(e)); + }, + }), + S.each( + { + parent: function (e) { + var t = e.parentNode; + return t && 11 !== t.nodeType ? t : null; + }, + parents: function (e) { + return h(e, 'parentNode'); + }, + parentsUntil: function (e, t, n) { + return h(e, 'parentNode', n); + }, + next: function (e) { + return O(e, 'nextSibling'); + }, + prev: function (e) { + return O(e, 'previousSibling'); + }, + nextAll: function (e) { + return h(e, 'nextSibling'); + }, + prevAll: function (e) { + return h(e, 'previousSibling'); + }, + nextUntil: function (e, t, n) { + return h(e, 'nextSibling', n); + }, + prevUntil: function (e, t, n) { + return h(e, 'previousSibling', n); + }, + siblings: function (e) { + return T((e.parentNode || {}).firstChild, e); + }, + children: function (e) { + return T(e.firstChild); + }, + contents: function (e) { + return null != e.contentDocument && r(e.contentDocument) + ? e.contentDocument + : (A(e, 'template') && (e = e.content || e), S.merge([], e.childNodes)); + }, + }, + function (r, i) { + S.fn[r] = function (e, t) { + var n = S.map(this, i, e); + return ( + 'Until' !== r.slice(-5) && (t = e), + t && 'string' == typeof t && (n = S.filter(t, n)), + 1 < this.length && (H[r] || S.uniqueSort(n), L.test(r) && n.reverse()), + this.pushStack(n) + ); + }; + } + ); + var P = /[^\x20\t\r\n\f]+/g; + function R(e) { + return e; + } + function M(e) { + throw e; + } + function I(e, t, n, r) { + var i; + try { + e && m((i = e.promise)) + ? i.call(e).done(t).fail(n) + : e && m((i = e.then)) + ? i.call(e, t, n) + : t.apply(void 0, [e].slice(r)); + } catch (e) { + n.apply(void 0, [e]); + } + } + (S.Callbacks = function (r) { + var e, n; + r = + 'string' == typeof r + ? ((e = r), + (n = {}), + S.each(e.match(P) || [], function (e, t) { + n[t] = !0; + }), + n) + : S.extend({}, r); + var i, + t, + o, + a, + s = [], + u = [], + l = -1, + c = function () { + for (a = a || r.once, o = i = !0; u.length; l = -1) { + t = u.shift(); + while (++l < s.length) + !1 === s[l].apply(t[0], t[1]) && r.stopOnFalse && ((l = s.length), (t = !1)); + } + r.memory || (t = !1), (i = !1), a && (s = t ? [] : ''); + }, + f = { + add: function () { + return ( + s && + (t && !i && ((l = s.length - 1), u.push(t)), + (function n(e) { + S.each(e, function (e, t) { + m(t) + ? (r.unique && f.has(t)) || s.push(t) + : t && t.length && 'string' !== w(t) && n(t); + }); + })(arguments), + t && !i && c()), + this + ); + }, + remove: function () { + return ( + S.each(arguments, function (e, t) { + var n; + while (-1 < (n = S.inArray(t, s, n))) s.splice(n, 1), n <= l && l--; + }), + this + ); + }, + has: function (e) { + return e ? -1 < S.inArray(e, s) : 0 < s.length; + }, + empty: function () { + return s && (s = []), this; + }, + disable: function () { + return (a = u = []), (s = t = ''), this; + }, + disabled: function () { + return !s; + }, + lock: function () { + return (a = u = []), t || i || (s = t = ''), this; + }, + locked: function () { + return !!a; + }, + fireWith: function (e, t) { + return ( + a || ((t = [e, (t = t || []).slice ? t.slice() : t]), u.push(t), i || c()), + this + ); + }, + fire: function () { + return f.fireWith(this, arguments), this; + }, + fired: function () { + return !!o; + }, + }; + return f; + }), + S.extend({ + Deferred: function (e) { + var o = [ + ['notify', 'progress', S.Callbacks('memory'), S.Callbacks('memory'), 2], + [ + 'resolve', + 'done', + S.Callbacks('once memory'), + S.Callbacks('once memory'), + 0, + 'resolved', + ], + [ + 'reject', + 'fail', + S.Callbacks('once memory'), + S.Callbacks('once memory'), + 1, + 'rejected', + ], + ], + i = 'pending', + a = { + state: function () { + return i; + }, + always: function () { + return s.done(arguments).fail(arguments), this; + }, + catch: function (e) { + return a.then(null, e); + }, + pipe: function () { + var i = arguments; + return S.Deferred(function (r) { + S.each(o, function (e, t) { + var n = m(i[t[4]]) && i[t[4]]; + s[t[1]](function () { + var e = n && n.apply(this, arguments); + e && m(e.promise) + ? e.promise().progress(r.notify).done(r.resolve).fail(r.reject) + : r[t[0] + 'With'](this, n ? [e] : arguments); + }); + }), + (i = null); + }).promise(); + }, + then: function (t, n, r) { + var u = 0; + function l(i, o, a, s) { + return function () { + var n = this, + r = arguments, + e = function () { + var e, t; + if (!(i < u)) { + if ((e = a.apply(n, r)) === o.promise()) + throw new TypeError('Thenable self-resolution'); + (t = + e && + ('object' == typeof e || 'function' == typeof e) && + e.then), + m(t) + ? s + ? t.call(e, l(u, o, R, s), l(u, o, M, s)) + : (u++, + t.call( + e, + l(u, o, R, s), + l(u, o, M, s), + l(u, o, R, o.notifyWith) + )) + : (a !== R && ((n = void 0), (r = [e])), + (s || o.resolveWith)(n, r)); + } + }, + t = s + ? e + : function () { + try { + e(); + } catch (e) { + S.Deferred.exceptionHook && + S.Deferred.exceptionHook(e, t.stackTrace), + u <= i + 1 && + (a !== M && ((n = void 0), (r = [e])), + o.rejectWith(n, r)); + } + }; + i + ? t() + : (S.Deferred.getStackHook && + (t.stackTrace = S.Deferred.getStackHook()), + C.setTimeout(t)); + }; + } + return S.Deferred(function (e) { + o[0][3].add(l(0, e, m(r) ? r : R, e.notifyWith)), + o[1][3].add(l(0, e, m(t) ? t : R)), + o[2][3].add(l(0, e, m(n) ? n : M)); + }).promise(); + }, + promise: function (e) { + return null != e ? S.extend(e, a) : a; + }, + }, + s = {}; + return ( + S.each(o, function (e, t) { + var n = t[2], + r = t[5]; + (a[t[1]] = n.add), + r && + n.add( + function () { + i = r; + }, + o[3 - e][2].disable, + o[3 - e][3].disable, + o[0][2].lock, + o[0][3].lock + ), + n.add(t[3].fire), + (s[t[0]] = function () { + return s[t[0] + 'With'](this === s ? void 0 : this, arguments), this; + }), + (s[t[0] + 'With'] = n.fireWith); + }), + a.promise(s), + e && e.call(s, s), + s + ); + }, + when: function (e) { + var n = arguments.length, + t = n, + r = Array(t), + i = s.call(arguments), + o = S.Deferred(), + a = function (t) { + return function (e) { + (r[t] = this), + (i[t] = 1 < arguments.length ? s.call(arguments) : e), + --n || o.resolveWith(r, i); + }; + }; + if ( + n <= 1 && + (I(e, o.done(a(t)).resolve, o.reject, !n), + 'pending' === o.state() || m(i[t] && i[t].then)) + ) + return o.then(); + while (t--) I(i[t], a(t), o.reject); + return o.promise(); + }, + }); + var W = /^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/; + (S.Deferred.exceptionHook = function (e, t) { + C.console && + C.console.warn && + e && + W.test(e.name) && + C.console.warn('jQuery.Deferred exception: ' + e.message, e.stack, t); + }), + (S.readyException = function (e) { + C.setTimeout(function () { + throw e; + }); + }); + var F = S.Deferred(); + function B() { + E.removeEventListener('DOMContentLoaded', B), + C.removeEventListener('load', B), + S.ready(); + } + (S.fn.ready = function (e) { + return ( + F.then(e)['catch'](function (e) { + S.readyException(e); + }), + this + ); + }), + S.extend({ + isReady: !1, + readyWait: 1, + ready: function (e) { + (!0 === e ? --S.readyWait : S.isReady) || + ((S.isReady = !0) !== e && 0 < --S.readyWait) || + F.resolveWith(E, [S]); + }, + }), + (S.ready.then = F.then), + 'complete' === E.readyState || + ('loading' !== E.readyState && !E.documentElement.doScroll) + ? C.setTimeout(S.ready) + : (E.addEventListener('DOMContentLoaded', B), C.addEventListener('load', B)); + var $ = function (e, t, n, r, i, o, a) { + var s = 0, + u = e.length, + l = null == n; + if ('object' === w(n)) for (s in ((i = !0), n)) $(e, t, s, n[s], !0, o, a); + else if ( + void 0 !== r && + ((i = !0), + m(r) || (a = !0), + l && + (a + ? (t.call(e, r), (t = null)) + : ((l = t), + (t = function (e, t, n) { + return l.call(S(e), n); + }))), + t) + ) + for (; s < u; s++) t(e[s], n, a ? r : r.call(e[s], s, t(e[s], n))); + return i ? e : l ? t.call(e) : u ? t(e[0], n) : o; + }, + _ = /^-ms-/, + z = /-([a-z])/g; + function U(e, t) { + return t.toUpperCase(); + } + function X(e) { + return e.replace(_, 'ms-').replace(z, U); + } + var V = function (e) { + return 1 === e.nodeType || 9 === e.nodeType || !+e.nodeType; + }; + function G() { + this.expando = S.expando + G.uid++; + } + (G.uid = 1), + (G.prototype = { + cache: function (e) { + var t = e[this.expando]; + return ( + t || + ((t = {}), + V(e) && + (e.nodeType + ? (e[this.expando] = t) + : Object.defineProperty(e, this.expando, { + value: t, + configurable: !0, + }))), + t + ); + }, + set: function (e, t, n) { + var r, + i = this.cache(e); + if ('string' == typeof t) i[X(t)] = n; + else for (r in t) i[X(r)] = t[r]; + return i; + }, + get: function (e, t) { + return void 0 === t ? this.cache(e) : e[this.expando] && e[this.expando][X(t)]; + }, + access: function (e, t, n) { + return void 0 === t || (t && 'string' == typeof t && void 0 === n) + ? this.get(e, t) + : (this.set(e, t, n), void 0 !== n ? n : t); + }, + remove: function (e, t) { + var n, + r = e[this.expando]; + if (void 0 !== r) { + if (void 0 !== t) { + n = (t = Array.isArray(t) + ? t.map(X) + : (t = X(t)) in r + ? [t] + : t.match(P) || []).length; + while (n--) delete r[t[n]]; + } + (void 0 === t || S.isEmptyObject(r)) && + (e.nodeType ? (e[this.expando] = void 0) : delete e[this.expando]); + } + }, + hasData: function (e) { + var t = e[this.expando]; + return void 0 !== t && !S.isEmptyObject(t); + }, + }); + var Y = new G(), + Q = new G(), + J = /^(?:\{[\w\W]*\}|\[[\w\W]*\])$/, + K = /[A-Z]/g; + function Z(e, t, n) { + var r, i; + if (void 0 === n && 1 === e.nodeType) + if ( + ((r = 'data-' + t.replace(K, '-$&').toLowerCase()), + 'string' == typeof (n = e.getAttribute(r))) + ) { + try { + n = + 'true' === (i = n) || + ('false' !== i && + ('null' === i ? null : i === +i + '' ? +i : J.test(i) ? JSON.parse(i) : i)); + } catch (e) {} + Q.set(e, t, n); + } else n = void 0; + return n; + } + S.extend({ + hasData: function (e) { + return Q.hasData(e) || Y.hasData(e); + }, + data: function (e, t, n) { + return Q.access(e, t, n); + }, + removeData: function (e, t) { + Q.remove(e, t); + }, + _data: function (e, t, n) { + return Y.access(e, t, n); + }, + _removeData: function (e, t) { + Y.remove(e, t); + }, + }), + S.fn.extend({ + data: function (n, e) { + var t, + r, + i, + o = this[0], + a = o && o.attributes; + if (void 0 === n) { + if ( + this.length && + ((i = Q.get(o)), 1 === o.nodeType && !Y.get(o, 'hasDataAttrs')) + ) { + t = a.length; + while (t--) + a[t] && + 0 === (r = a[t].name).indexOf('data-') && + ((r = X(r.slice(5))), Z(o, r, i[r])); + Y.set(o, 'hasDataAttrs', !0); + } + return i; + } + return 'object' == typeof n + ? this.each(function () { + Q.set(this, n); + }) + : $( + this, + function (e) { + var t; + if (o && void 0 === e) + return void 0 !== (t = Q.get(o, n)) + ? t + : void 0 !== (t = Z(o, n)) + ? t + : void 0; + this.each(function () { + Q.set(this, n, e); + }); + }, + null, + e, + 1 < arguments.length, + null, + !0 + ); + }, + removeData: function (e) { + return this.each(function () { + Q.remove(this, e); + }); + }, + }), + S.extend({ + queue: function (e, t, n) { + var r; + if (e) + return ( + (t = (t || 'fx') + 'queue'), + (r = Y.get(e, t)), + n && + (!r || Array.isArray(n) ? (r = Y.access(e, t, S.makeArray(n))) : r.push(n)), + r || [] + ); + }, + dequeue: function (e, t) { + t = t || 'fx'; + var n = S.queue(e, t), + r = n.length, + i = n.shift(), + o = S._queueHooks(e, t); + 'inprogress' === i && ((i = n.shift()), r--), + i && + ('fx' === t && n.unshift('inprogress'), + delete o.stop, + i.call( + e, + function () { + S.dequeue(e, t); + }, + o + )), + !r && o && o.empty.fire(); + }, + _queueHooks: function (e, t) { + var n = t + 'queueHooks'; + return ( + Y.get(e, n) || + Y.access(e, n, { + empty: S.Callbacks('once memory').add(function () { + Y.remove(e, [t + 'queue', n]); + }), + }) + ); + }, + }), + S.fn.extend({ + queue: function (t, n) { + var e = 2; + return ( + 'string' != typeof t && ((n = t), (t = 'fx'), e--), + arguments.length < e + ? S.queue(this[0], t) + : void 0 === n + ? this + : this.each(function () { + var e = S.queue(this, t, n); + S._queueHooks(this, t), + 'fx' === t && 'inprogress' !== e[0] && S.dequeue(this, t); + }) + ); + }, + dequeue: function (e) { + return this.each(function () { + S.dequeue(this, e); + }); + }, + clearQueue: function (e) { + return this.queue(e || 'fx', []); + }, + promise: function (e, t) { + var n, + r = 1, + i = S.Deferred(), + o = this, + a = this.length, + s = function () { + --r || i.resolveWith(o, [o]); + }; + 'string' != typeof e && ((t = e), (e = void 0)), (e = e || 'fx'); + while (a--) + (n = Y.get(o[a], e + 'queueHooks')) && n.empty && (r++, n.empty.add(s)); + return s(), i.promise(t); + }, + }); + var ee = /[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source, + te = new RegExp('^(?:([+-])=|)(' + ee + ')([a-z%]*)$', 'i'), + ne = ['Top', 'Right', 'Bottom', 'Left'], + re = E.documentElement, + ie = function (e) { + return S.contains(e.ownerDocument, e); + }, + oe = { composed: !0 }; + re.getRootNode && + (ie = function (e) { + return S.contains(e.ownerDocument, e) || e.getRootNode(oe) === e.ownerDocument; + }); + var ae = function (e, t) { + return ( + 'none' === (e = t || e).style.display || + ('' === e.style.display && ie(e) && 'none' === S.css(e, 'display')) + ); + }; + function se(e, t, n, r) { + var i, + o, + a = 20, + s = r + ? function () { + return r.cur(); + } + : function () { + return S.css(e, t, ''); + }, + u = s(), + l = (n && n[3]) || (S.cssNumber[t] ? '' : 'px'), + c = e.nodeType && (S.cssNumber[t] || ('px' !== l && +u)) && te.exec(S.css(e, t)); + if (c && c[3] !== l) { + (u /= 2), (l = l || c[3]), (c = +u || 1); + while (a--) + S.style(e, t, c + l), + (1 - o) * (1 - (o = s() / u || 0.5)) <= 0 && (a = 0), + (c /= o); + (c *= 2), S.style(e, t, c + l), (n = n || []); + } + return ( + n && + ((c = +c || +u || 0), + (i = n[1] ? c + (n[1] + 1) * n[2] : +n[2]), + r && ((r.unit = l), (r.start = c), (r.end = i))), + i + ); + } + var ue = {}; + function le(e, t) { + for (var n, r, i, o, a, s, u, l = [], c = 0, f = e.length; c < f; c++) + (r = e[c]).style && + ((n = r.style.display), + t + ? ('none' === n && + ((l[c] = Y.get(r, 'display') || null), l[c] || (r.style.display = '')), + '' === r.style.display && + ae(r) && + (l[c] = + ((u = a = o = void 0), + (a = (i = r).ownerDocument), + (s = i.nodeName), + (u = ue[s]) || + ((o = a.body.appendChild(a.createElement(s))), + (u = S.css(o, 'display')), + o.parentNode.removeChild(o), + 'none' === u && (u = 'block'), + (ue[s] = u))))) + : 'none' !== n && ((l[c] = 'none'), Y.set(r, 'display', n))); + for (c = 0; c < f; c++) null != l[c] && (e[c].style.display = l[c]); + return e; + } + S.fn.extend({ + show: function () { + return le(this, !0); + }, + hide: function () { + return le(this); + }, + toggle: function (e) { + return 'boolean' == typeof e + ? e + ? this.show() + : this.hide() + : this.each(function () { + ae(this) ? S(this).show() : S(this).hide(); + }); + }, + }); + var ce, + fe, + pe = /^(?:checkbox|radio)$/i, + de = /<([a-z][^\/\0>\x20\t\r\n\f]*)/i, + he = /^$|^module$|\/(?:java|ecma)script/i; + (ce = E.createDocumentFragment().appendChild(E.createElement('div'))), + (fe = E.createElement('input')).setAttribute('type', 'radio'), + fe.setAttribute('checked', 'checked'), + fe.setAttribute('name', 't'), + ce.appendChild(fe), + (y.checkClone = ce.cloneNode(!0).cloneNode(!0).lastChild.checked), + (ce.innerHTML = ''), + (y.noCloneChecked = !!ce.cloneNode(!0).lastChild.defaultValue), + (ce.innerHTML = ''), + (y.option = !!ce.lastChild); + var ge = { + thead: [1, '', '
'], + col: [2, '', '
'], + tr: [2, '', '
'], + td: [3, '', '
'], + _default: [0, '', ''], + }; + function ve(e, t) { + var n; + return ( + (n = + 'undefined' != typeof e.getElementsByTagName + ? e.getElementsByTagName(t || '*') + : 'undefined' != typeof e.querySelectorAll + ? e.querySelectorAll(t || '*') + : []), + void 0 === t || (t && A(e, t)) ? S.merge([e], n) : n + ); + } + function ye(e, t) { + for (var n = 0, r = e.length; n < r; n++) + Y.set(e[n], 'globalEval', !t || Y.get(t[n], 'globalEval')); + } + (ge.tbody = ge.tfoot = ge.colgroup = ge.caption = ge.thead), + (ge.th = ge.td), + y.option || + (ge.optgroup = ge.option = [1, "']); + var me = /<|&#?\w+;/; + function xe(e, t, n, r, i) { + for ( + var o, a, s, u, l, c, f = t.createDocumentFragment(), p = [], d = 0, h = e.length; + d < h; + d++ + ) + if ((o = e[d]) || 0 === o) + if ('object' === w(o)) S.merge(p, o.nodeType ? [o] : o); + else if (me.test(o)) { + (a = a || f.appendChild(t.createElement('div'))), + (s = (de.exec(o) || ['', ''])[1].toLowerCase()), + (u = ge[s] || ge._default), + (a.innerHTML = u[1] + S.htmlPrefilter(o) + u[2]), + (c = u[0]); + while (c--) a = a.lastChild; + S.merge(p, a.childNodes), ((a = f.firstChild).textContent = ''); + } else p.push(t.createTextNode(o)); + (f.textContent = ''), (d = 0); + while ((o = p[d++])) + if (r && -1 < S.inArray(o, r)) i && i.push(o); + else if (((l = ie(o)), (a = ve(f.appendChild(o), 'script')), l && ye(a), n)) { + c = 0; + while ((o = a[c++])) he.test(o.type || '') && n.push(o); + } + return f; + } + var be = /^([^.]*)(?:\.(.+)|)/; + function we() { + return !0; + } + function Te() { + return !1; + } + function Ce(e, t) { + return ( + (e === + (function () { + try { + return E.activeElement; + } catch (e) {} + })()) == + ('focus' === t) + ); + } + function Ee(e, t, n, r, i, o) { + var a, s; + if ('object' == typeof t) { + for (s in ('string' != typeof n && ((r = r || n), (n = void 0)), t)) + Ee(e, s, n, r, t[s], o); + return e; + } + if ( + (null == r && null == i + ? ((i = n), (r = n = void 0)) + : null == i && + ('string' == typeof n + ? ((i = r), (r = void 0)) + : ((i = r), (r = n), (n = void 0))), + !1 === i) + ) + i = Te; + else if (!i) return e; + return ( + 1 === o && + ((a = i), + ((i = function (e) { + return S().off(e), a.apply(this, arguments); + }).guid = a.guid || (a.guid = S.guid++))), + e.each(function () { + S.event.add(this, t, i, r, n); + }) + ); + } + function Se(e, i, o) { + o + ? (Y.set(e, i, !1), + S.event.add(e, i, { + namespace: !1, + handler: function (e) { + var t, + n, + r = Y.get(this, i); + if (1 & e.isTrigger && this[i]) { + if (r.length) + (S.event.special[i] || {}).delegateType && e.stopPropagation(); + else if ( + ((r = s.call(arguments)), + Y.set(this, i, r), + (t = o(this, i)), + this[i](), + r !== (n = Y.get(this, i)) || t ? Y.set(this, i, !1) : (n = {}), + r !== n) + ) + return e.stopImmediatePropagation(), e.preventDefault(), n && n.value; + } else + r.length && + (Y.set(this, i, { + value: S.event.trigger( + S.extend(r[0], S.Event.prototype), + r.slice(1), + this + ), + }), + e.stopImmediatePropagation()); + }, + })) + : void 0 === Y.get(e, i) && S.event.add(e, i, we); + } + (S.event = { + global: {}, + add: function (t, e, n, r, i) { + var o, + a, + s, + u, + l, + c, + f, + p, + d, + h, + g, + v = Y.get(t); + if (V(t)) { + n.handler && ((n = (o = n).handler), (i = o.selector)), + i && S.find.matchesSelector(re, i), + n.guid || (n.guid = S.guid++), + (u = v.events) || (u = v.events = Object.create(null)), + (a = v.handle) || + (a = v.handle = function (e) { + return 'undefined' != typeof S && S.event.triggered !== e.type + ? S.event.dispatch.apply(t, arguments) + : void 0; + }), + (l = (e = (e || '').match(P) || ['']).length); + while (l--) + (d = g = (s = be.exec(e[l]) || [])[1]), + (h = (s[2] || '').split('.').sort()), + d && + ((f = S.event.special[d] || {}), + (d = (i ? f.delegateType : f.bindType) || d), + (f = S.event.special[d] || {}), + (c = S.extend( + { + type: d, + origType: g, + data: r, + handler: n, + guid: n.guid, + selector: i, + needsContext: i && S.expr.match.needsContext.test(i), + namespace: h.join('.'), + }, + o + )), + (p = u[d]) || + (((p = u[d] = []).delegateCount = 0), + (f.setup && !1 !== f.setup.call(t, r, h, a)) || + (t.addEventListener && t.addEventListener(d, a))), + f.add && (f.add.call(t, c), c.handler.guid || (c.handler.guid = n.guid)), + i ? p.splice(p.delegateCount++, 0, c) : p.push(c), + (S.event.global[d] = !0)); + } + }, + remove: function (e, t, n, r, i) { + var o, + a, + s, + u, + l, + c, + f, + p, + d, + h, + g, + v = Y.hasData(e) && Y.get(e); + if (v && (u = v.events)) { + l = (t = (t || '').match(P) || ['']).length; + while (l--) + if ( + ((d = g = (s = be.exec(t[l]) || [])[1]), + (h = (s[2] || '').split('.').sort()), + d) + ) { + (f = S.event.special[d] || {}), + (p = u[(d = (r ? f.delegateType : f.bindType) || d)] || []), + (s = s[2] && new RegExp('(^|\\.)' + h.join('\\.(?:.*\\.|)') + '(\\.|$)')), + (a = o = p.length); + while (o--) + (c = p[o]), + (!i && g !== c.origType) || + (n && n.guid !== c.guid) || + (s && !s.test(c.namespace)) || + (r && r !== c.selector && ('**' !== r || !c.selector)) || + (p.splice(o, 1), + c.selector && p.delegateCount--, + f.remove && f.remove.call(e, c)); + a && + !p.length && + ((f.teardown && !1 !== f.teardown.call(e, h, v.handle)) || + S.removeEvent(e, d, v.handle), + delete u[d]); + } else for (d in u) S.event.remove(e, d + t[l], n, r, !0); + S.isEmptyObject(u) && Y.remove(e, 'handle events'); + } + }, + dispatch: function (e) { + var t, + n, + r, + i, + o, + a, + s = new Array(arguments.length), + u = S.event.fix(e), + l = (Y.get(this, 'events') || Object.create(null))[u.type] || [], + c = S.event.special[u.type] || {}; + for (s[0] = u, t = 1; t < arguments.length; t++) s[t] = arguments[t]; + if ( + ((u.delegateTarget = this), !c.preDispatch || !1 !== c.preDispatch.call(this, u)) + ) { + (a = S.event.handlers.call(this, u, l)), (t = 0); + while ((i = a[t++]) && !u.isPropagationStopped()) { + (u.currentTarget = i.elem), (n = 0); + while ((o = i.handlers[n++]) && !u.isImmediatePropagationStopped()) + (u.rnamespace && !1 !== o.namespace && !u.rnamespace.test(o.namespace)) || + ((u.handleObj = o), + (u.data = o.data), + void 0 !== + (r = ((S.event.special[o.origType] || {}).handle || o.handler).apply( + i.elem, + s + )) && + !1 === (u.result = r) && + (u.preventDefault(), u.stopPropagation())); + } + return c.postDispatch && c.postDispatch.call(this, u), u.result; + } + }, + handlers: function (e, t) { + var n, + r, + i, + o, + a, + s = [], + u = t.delegateCount, + l = e.target; + if (u && l.nodeType && !('click' === e.type && 1 <= e.button)) + for (; l !== this; l = l.parentNode || this) + if (1 === l.nodeType && ('click' !== e.type || !0 !== l.disabled)) { + for (o = [], a = {}, n = 0; n < u; n++) + void 0 === a[(i = (r = t[n]).selector + ' ')] && + (a[i] = r.needsContext + ? -1 < S(i, this).index(l) + : S.find(i, this, null, [l]).length), + a[i] && o.push(r); + o.length && s.push({ elem: l, handlers: o }); + } + return (l = this), u < t.length && s.push({ elem: l, handlers: t.slice(u) }), s; + }, + addProp: function (t, e) { + Object.defineProperty(S.Event.prototype, t, { + enumerable: !0, + configurable: !0, + get: m(e) + ? function () { + if (this.originalEvent) return e(this.originalEvent); + } + : function () { + if (this.originalEvent) return this.originalEvent[t]; + }, + set: function (e) { + Object.defineProperty(this, t, { + enumerable: !0, + configurable: !0, + writable: !0, + value: e, + }); + }, + }); + }, + fix: function (e) { + return e[S.expando] ? e : new S.Event(e); + }, + special: { + load: { noBubble: !0 }, + click: { + setup: function (e) { + var t = this || e; + return pe.test(t.type) && t.click && A(t, 'input') && Se(t, 'click', we), !1; + }, + trigger: function (e) { + var t = this || e; + return pe.test(t.type) && t.click && A(t, 'input') && Se(t, 'click'), !0; + }, + _default: function (e) { + var t = e.target; + return ( + (pe.test(t.type) && t.click && A(t, 'input') && Y.get(t, 'click')) || + A(t, 'a') + ); + }, + }, + beforeunload: { + postDispatch: function (e) { + void 0 !== e.result && + e.originalEvent && + (e.originalEvent.returnValue = e.result); + }, + }, + }, + }), + (S.removeEvent = function (e, t, n) { + e.removeEventListener && e.removeEventListener(t, n); + }), + (S.Event = function (e, t) { + if (!(this instanceof S.Event)) return new S.Event(e, t); + e && e.type + ? ((this.originalEvent = e), + (this.type = e.type), + (this.isDefaultPrevented = + e.defaultPrevented || (void 0 === e.defaultPrevented && !1 === e.returnValue) + ? we + : Te), + (this.target = + e.target && 3 === e.target.nodeType ? e.target.parentNode : e.target), + (this.currentTarget = e.currentTarget), + (this.relatedTarget = e.relatedTarget)) + : (this.type = e), + t && S.extend(this, t), + (this.timeStamp = (e && e.timeStamp) || Date.now()), + (this[S.expando] = !0); + }), + (S.Event.prototype = { + constructor: S.Event, + isDefaultPrevented: Te, + isPropagationStopped: Te, + isImmediatePropagationStopped: Te, + isSimulated: !1, + preventDefault: function () { + var e = this.originalEvent; + (this.isDefaultPrevented = we), e && !this.isSimulated && e.preventDefault(); + }, + stopPropagation: function () { + var e = this.originalEvent; + (this.isPropagationStopped = we), e && !this.isSimulated && e.stopPropagation(); + }, + stopImmediatePropagation: function () { + var e = this.originalEvent; + (this.isImmediatePropagationStopped = we), + e && !this.isSimulated && e.stopImmediatePropagation(), + this.stopPropagation(); + }, + }), + S.each( + { + altKey: !0, + bubbles: !0, + cancelable: !0, + changedTouches: !0, + ctrlKey: !0, + detail: !0, + eventPhase: !0, + metaKey: !0, + pageX: !0, + pageY: !0, + shiftKey: !0, + view: !0, + char: !0, + code: !0, + charCode: !0, + key: !0, + keyCode: !0, + button: !0, + buttons: !0, + clientX: !0, + clientY: !0, + offsetX: !0, + offsetY: !0, + pointerId: !0, + pointerType: !0, + screenX: !0, + screenY: !0, + targetTouches: !0, + toElement: !0, + touches: !0, + which: !0, + }, + S.event.addProp + ), + S.each({ focus: 'focusin', blur: 'focusout' }, function (e, t) { + S.event.special[e] = { + setup: function () { + return Se(this, e, Ce), !1; + }, + trigger: function () { + return Se(this, e), !0; + }, + _default: function () { + return !0; + }, + delegateType: t, + }; + }), + S.each( + { + mouseenter: 'mouseover', + mouseleave: 'mouseout', + pointerenter: 'pointerover', + pointerleave: 'pointerout', + }, + function (e, i) { + S.event.special[e] = { + delegateType: i, + bindType: i, + handle: function (e) { + var t, + n = e.relatedTarget, + r = e.handleObj; + return ( + (n && (n === this || S.contains(this, n))) || + ((e.type = r.origType), + (t = r.handler.apply(this, arguments)), + (e.type = i)), + t + ); + }, + }; + } + ), + S.fn.extend({ + on: function (e, t, n, r) { + return Ee(this, e, t, n, r); + }, + one: function (e, t, n, r) { + return Ee(this, e, t, n, r, 1); + }, + off: function (e, t, n) { + var r, i; + if (e && e.preventDefault && e.handleObj) + return ( + (r = e.handleObj), + S(e.delegateTarget).off( + r.namespace ? r.origType + '.' + r.namespace : r.origType, + r.selector, + r.handler + ), + this + ); + if ('object' == typeof e) { + for (i in e) this.off(i, t, e[i]); + return this; + } + return ( + (!1 !== t && 'function' != typeof t) || ((n = t), (t = void 0)), + !1 === n && (n = Te), + this.each(function () { + S.event.remove(this, e, n, t); + }) + ); + }, + }); + var ke = /\s*$/g; + function je(e, t) { + return ( + (A(e, 'table') && + A(11 !== t.nodeType ? t : t.firstChild, 'tr') && + S(e).children('tbody')[0]) || + e + ); + } + function De(e) { + return (e.type = (null !== e.getAttribute('type')) + '/' + e.type), e; + } + function qe(e) { + return ( + 'true/' === (e.type || '').slice(0, 5) + ? (e.type = e.type.slice(5)) + : e.removeAttribute('type'), + e + ); + } + function Le(e, t) { + var n, r, i, o, a, s; + if (1 === t.nodeType) { + if (Y.hasData(e) && (s = Y.get(e).events)) + for (i in (Y.remove(t, 'handle events'), s)) + for (n = 0, r = s[i].length; n < r; n++) S.event.add(t, i, s[i][n]); + Q.hasData(e) && ((o = Q.access(e)), (a = S.extend({}, o)), Q.set(t, a)); + } + } + function He(n, r, i, o) { + r = g(r); + var e, + t, + a, + s, + u, + l, + c = 0, + f = n.length, + p = f - 1, + d = r[0], + h = m(d); + if (h || (1 < f && 'string' == typeof d && !y.checkClone && Ae.test(d))) + return n.each(function (e) { + var t = n.eq(e); + h && (r[0] = d.call(this, e, t.html())), He(t, r, i, o); + }); + if ( + f && + ((t = (e = xe(r, n[0].ownerDocument, !1, n, o)).firstChild), + 1 === e.childNodes.length && (e = t), + t || o) + ) { + for (s = (a = S.map(ve(e, 'script'), De)).length; c < f; c++) + (u = e), + c !== p && ((u = S.clone(u, !0, !0)), s && S.merge(a, ve(u, 'script'))), + i.call(n[c], u, c); + if (s) + for (l = a[a.length - 1].ownerDocument, S.map(a, qe), c = 0; c < s; c++) + (u = a[c]), + he.test(u.type || '') && + !Y.access(u, 'globalEval') && + S.contains(l, u) && + (u.src && 'module' !== (u.type || '').toLowerCase() + ? S._evalUrl && + !u.noModule && + S._evalUrl(u.src, { nonce: u.nonce || u.getAttribute('nonce') }, l) + : b(u.textContent.replace(Ne, ''), u, l)); + } + return n; + } + function Oe(e, t, n) { + for (var r, i = t ? S.filter(t, e) : e, o = 0; null != (r = i[o]); o++) + n || 1 !== r.nodeType || S.cleanData(ve(r)), + r.parentNode && (n && ie(r) && ye(ve(r, 'script')), r.parentNode.removeChild(r)); + return e; + } + S.extend({ + htmlPrefilter: function (e) { + return e; + }, + clone: function (e, t, n) { + var r, + i, + o, + a, + s, + u, + l, + c = e.cloneNode(!0), + f = ie(e); + if (!(y.noCloneChecked || (1 !== e.nodeType && 11 !== e.nodeType) || S.isXMLDoc(e))) + for (a = ve(c), r = 0, i = (o = ve(e)).length; r < i; r++) + (s = o[r]), + (u = a[r]), + void 0, + 'input' === (l = u.nodeName.toLowerCase()) && pe.test(s.type) + ? (u.checked = s.checked) + : ('input' !== l && 'textarea' !== l) || (u.defaultValue = s.defaultValue); + if (t) + if (n) + for (o = o || ve(e), a = a || ve(c), r = 0, i = o.length; r < i; r++) + Le(o[r], a[r]); + else Le(e, c); + return 0 < (a = ve(c, 'script')).length && ye(a, !f && ve(e, 'script')), c; + }, + cleanData: function (e) { + for (var t, n, r, i = S.event.special, o = 0; void 0 !== (n = e[o]); o++) + if (V(n)) { + if ((t = n[Y.expando])) { + if (t.events) + for (r in t.events) + i[r] ? S.event.remove(n, r) : S.removeEvent(n, r, t.handle); + n[Y.expando] = void 0; + } + n[Q.expando] && (n[Q.expando] = void 0); + } + }, + }), + S.fn.extend({ + detach: function (e) { + return Oe(this, e, !0); + }, + remove: function (e) { + return Oe(this, e); + }, + text: function (e) { + return $( + this, + function (e) { + return void 0 === e + ? S.text(this) + : this.empty().each(function () { + (1 !== this.nodeType && 11 !== this.nodeType && 9 !== this.nodeType) || + (this.textContent = e); + }); + }, + null, + e, + arguments.length + ); + }, + append: function () { + return He(this, arguments, function (e) { + (1 !== this.nodeType && 11 !== this.nodeType && 9 !== this.nodeType) || + je(this, e).appendChild(e); + }); + }, + prepend: function () { + return He(this, arguments, function (e) { + if (1 === this.nodeType || 11 === this.nodeType || 9 === this.nodeType) { + var t = je(this, e); + t.insertBefore(e, t.firstChild); + } + }); + }, + before: function () { + return He(this, arguments, function (e) { + this.parentNode && this.parentNode.insertBefore(e, this); + }); + }, + after: function () { + return He(this, arguments, function (e) { + this.parentNode && this.parentNode.insertBefore(e, this.nextSibling); + }); + }, + empty: function () { + for (var e, t = 0; null != (e = this[t]); t++) + 1 === e.nodeType && (S.cleanData(ve(e, !1)), (e.textContent = '')); + return this; + }, + clone: function (e, t) { + return ( + (e = null != e && e), + (t = null == t ? e : t), + this.map(function () { + return S.clone(this, e, t); + }) + ); + }, + html: function (e) { + return $( + this, + function (e) { + var t = this[0] || {}, + n = 0, + r = this.length; + if (void 0 === e && 1 === t.nodeType) return t.innerHTML; + if ( + 'string' == typeof e && + !ke.test(e) && + !ge[(de.exec(e) || ['', ''])[1].toLowerCase()] + ) { + e = S.htmlPrefilter(e); + try { + for (; n < r; n++) + 1 === (t = this[n] || {}).nodeType && + (S.cleanData(ve(t, !1)), (t.innerHTML = e)); + t = 0; + } catch (e) {} + } + t && this.empty().append(e); + }, + null, + e, + arguments.length + ); + }, + replaceWith: function () { + var n = []; + return He( + this, + arguments, + function (e) { + var t = this.parentNode; + S.inArray(this, n) < 0 && + (S.cleanData(ve(this)), t && t.replaceChild(e, this)); + }, + n + ); + }, + }), + S.each( + { + appendTo: 'append', + prependTo: 'prepend', + insertBefore: 'before', + insertAfter: 'after', + replaceAll: 'replaceWith', + }, + function (e, a) { + S.fn[e] = function (e) { + for (var t, n = [], r = S(e), i = r.length - 1, o = 0; o <= i; o++) + (t = o === i ? this : this.clone(!0)), S(r[o])[a](t), u.apply(n, t.get()); + return this.pushStack(n); + }; + } + ); + var Pe = new RegExp('^(' + ee + ')(?!px)[a-z%]+$', 'i'), + Re = function (e) { + var t = e.ownerDocument.defaultView; + return (t && t.opener) || (t = C), t.getComputedStyle(e); + }, + Me = function (e, t, n) { + var r, + i, + o = {}; + for (i in t) (o[i] = e.style[i]), (e.style[i] = t[i]); + for (i in ((r = n.call(e)), t)) e.style[i] = o[i]; + return r; + }, + Ie = new RegExp(ne.join('|'), 'i'); + function We(e, t, n) { + var r, + i, + o, + a, + s = e.style; + return ( + (n = n || Re(e)) && + ('' !== (a = n.getPropertyValue(t) || n[t]) || ie(e) || (a = S.style(e, t)), + !y.pixelBoxStyles() && + Pe.test(a) && + Ie.test(t) && + ((r = s.width), + (i = s.minWidth), + (o = s.maxWidth), + (s.minWidth = s.maxWidth = s.width = a), + (a = n.width), + (s.width = r), + (s.minWidth = i), + (s.maxWidth = o))), + void 0 !== a ? a + '' : a + ); + } + function Fe(e, t) { + return { + get: function () { + if (!e()) return (this.get = t).apply(this, arguments); + delete this.get; + }, + }; + } + !(function () { + function e() { + if (l) { + (u.style.cssText = + 'position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0'), + (l.style.cssText = + 'position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%'), + re.appendChild(u).appendChild(l); + var e = C.getComputedStyle(l); + (n = '1%' !== e.top), + (s = 12 === t(e.marginLeft)), + (l.style.right = '60%'), + (o = 36 === t(e.right)), + (r = 36 === t(e.width)), + (l.style.position = 'absolute'), + (i = 12 === t(l.offsetWidth / 3)), + re.removeChild(u), + (l = null); + } + } + function t(e) { + return Math.round(parseFloat(e)); + } + var n, + r, + i, + o, + a, + s, + u = E.createElement('div'), + l = E.createElement('div'); + l.style && + ((l.style.backgroundClip = 'content-box'), + (l.cloneNode(!0).style.backgroundClip = ''), + (y.clearCloneStyle = 'content-box' === l.style.backgroundClip), + S.extend(y, { + boxSizingReliable: function () { + return e(), r; + }, + pixelBoxStyles: function () { + return e(), o; + }, + pixelPosition: function () { + return e(), n; + }, + reliableMarginLeft: function () { + return e(), s; + }, + scrollboxSize: function () { + return e(), i; + }, + reliableTrDimensions: function () { + var e, t, n, r; + return ( + null == a && + ((e = E.createElement('table')), + (t = E.createElement('tr')), + (n = E.createElement('div')), + (e.style.cssText = + 'position:absolute;left:-11111px;border-collapse:separate'), + (t.style.cssText = 'border:1px solid'), + (t.style.height = '1px'), + (n.style.height = '9px'), + (n.style.display = 'block'), + re.appendChild(e).appendChild(t).appendChild(n), + (r = C.getComputedStyle(t)), + (a = + parseInt(r.height, 10) + + parseInt(r.borderTopWidth, 10) + + parseInt(r.borderBottomWidth, 10) === + t.offsetHeight), + re.removeChild(e)), + a + ); + }, + })); + })(); + var Be = ['Webkit', 'Moz', 'ms'], + $e = E.createElement('div').style, + _e = {}; + function ze(e) { + var t = S.cssProps[e] || _e[e]; + return ( + t || + (e in $e + ? e + : (_e[e] = + (function (e) { + var t = e[0].toUpperCase() + e.slice(1), + n = Be.length; + while (n--) if ((e = Be[n] + t) in $e) return e; + })(e) || e)) + ); + } + var Ue = /^(none|table(?!-c[ea]).+)/, + Xe = /^--/, + Ve = { position: 'absolute', visibility: 'hidden', display: 'block' }, + Ge = { letterSpacing: '0', fontWeight: '400' }; + function Ye(e, t, n) { + var r = te.exec(t); + return r ? Math.max(0, r[2] - (n || 0)) + (r[3] || 'px') : t; + } + function Qe(e, t, n, r, i, o) { + var a = 'width' === t ? 1 : 0, + s = 0, + u = 0; + if (n === (r ? 'border' : 'content')) return 0; + for (; a < 4; a += 2) + 'margin' === n && (u += S.css(e, n + ne[a], !0, i)), + r + ? ('content' === n && (u -= S.css(e, 'padding' + ne[a], !0, i)), + 'margin' !== n && (u -= S.css(e, 'border' + ne[a] + 'Width', !0, i))) + : ((u += S.css(e, 'padding' + ne[a], !0, i)), + 'padding' !== n + ? (u += S.css(e, 'border' + ne[a] + 'Width', !0, i)) + : (s += S.css(e, 'border' + ne[a] + 'Width', !0, i))); + return ( + !r && + 0 <= o && + (u += + Math.max( + 0, + Math.ceil(e['offset' + t[0].toUpperCase() + t.slice(1)] - o - u - s - 0.5) + ) || 0), + u + ); + } + function Je(e, t, n) { + var r = Re(e), + i = (!y.boxSizingReliable() || n) && 'border-box' === S.css(e, 'boxSizing', !1, r), + o = i, + a = We(e, t, r), + s = 'offset' + t[0].toUpperCase() + t.slice(1); + if (Pe.test(a)) { + if (!n) return a; + a = 'auto'; + } + return ( + ((!y.boxSizingReliable() && i) || + (!y.reliableTrDimensions() && A(e, 'tr')) || + 'auto' === a || + (!parseFloat(a) && 'inline' === S.css(e, 'display', !1, r))) && + e.getClientRects().length && + ((i = 'border-box' === S.css(e, 'boxSizing', !1, r)), (o = s in e) && (a = e[s])), + (a = parseFloat(a) || 0) + Qe(e, t, n || (i ? 'border' : 'content'), o, r, a) + 'px' + ); + } + function Ke(e, t, n, r, i) { + return new Ke.prototype.init(e, t, n, r, i); + } + S.extend({ + cssHooks: { + opacity: { + get: function (e, t) { + if (t) { + var n = We(e, 'opacity'); + return '' === n ? '1' : n; + } + }, + }, + }, + cssNumber: { + animationIterationCount: !0, + columnCount: !0, + fillOpacity: !0, + flexGrow: !0, + flexShrink: !0, + fontWeight: !0, + gridArea: !0, + gridColumn: !0, + gridColumnEnd: !0, + gridColumnStart: !0, + gridRow: !0, + gridRowEnd: !0, + gridRowStart: !0, + lineHeight: !0, + opacity: !0, + order: !0, + orphans: !0, + widows: !0, + zIndex: !0, + zoom: !0, + }, + cssProps: {}, + style: function (e, t, n, r) { + if (e && 3 !== e.nodeType && 8 !== e.nodeType && e.style) { + var i, + o, + a, + s = X(t), + u = Xe.test(t), + l = e.style; + if ((u || (t = ze(s)), (a = S.cssHooks[t] || S.cssHooks[s]), void 0 === n)) + return a && 'get' in a && void 0 !== (i = a.get(e, !1, r)) ? i : l[t]; + 'string' === (o = typeof n) && + (i = te.exec(n)) && + i[1] && + ((n = se(e, t, i)), (o = 'number')), + null != n && + n == n && + ('number' !== o || u || (n += (i && i[3]) || (S.cssNumber[s] ? '' : 'px')), + y.clearCloneStyle || + '' !== n || + 0 !== t.indexOf('background') || + (l[t] = 'inherit'), + (a && 'set' in a && void 0 === (n = a.set(e, n, r))) || + (u ? l.setProperty(t, n) : (l[t] = n))); + } + }, + css: function (e, t, n, r) { + var i, + o, + a, + s = X(t); + return ( + Xe.test(t) || (t = ze(s)), + (a = S.cssHooks[t] || S.cssHooks[s]) && 'get' in a && (i = a.get(e, !0, n)), + void 0 === i && (i = We(e, t, r)), + 'normal' === i && t in Ge && (i = Ge[t]), + '' === n || n ? ((o = parseFloat(i)), !0 === n || isFinite(o) ? o || 0 : i) : i + ); + }, + }), + S.each(['height', 'width'], function (e, u) { + S.cssHooks[u] = { + get: function (e, t, n) { + if (t) + return !Ue.test(S.css(e, 'display')) || + (e.getClientRects().length && e.getBoundingClientRect().width) + ? Je(e, u, n) + : Me(e, Ve, function () { + return Je(e, u, n); + }); + }, + set: function (e, t, n) { + var r, + i = Re(e), + o = !y.scrollboxSize() && 'absolute' === i.position, + a = (o || n) && 'border-box' === S.css(e, 'boxSizing', !1, i), + s = n ? Qe(e, u, n, a, i) : 0; + return ( + a && + o && + (s -= Math.ceil( + e['offset' + u[0].toUpperCase() + u.slice(1)] - + parseFloat(i[u]) - + Qe(e, u, 'border', !1, i) - + 0.5 + )), + s && + (r = te.exec(t)) && + 'px' !== (r[3] || 'px') && + ((e.style[u] = t), (t = S.css(e, u))), + Ye(0, t, s) + ); + }, + }; + }), + (S.cssHooks.marginLeft = Fe(y.reliableMarginLeft, function (e, t) { + if (t) + return ( + (parseFloat(We(e, 'marginLeft')) || + e.getBoundingClientRect().left - + Me(e, { marginLeft: 0 }, function () { + return e.getBoundingClientRect().left; + })) + 'px' + ); + })), + S.each({ margin: '', padding: '', border: 'Width' }, function (i, o) { + (S.cssHooks[i + o] = { + expand: function (e) { + for ( + var t = 0, n = {}, r = 'string' == typeof e ? e.split(' ') : [e]; + t < 4; + t++ + ) + n[i + ne[t] + o] = r[t] || r[t - 2] || r[0]; + return n; + }, + }), + 'margin' !== i && (S.cssHooks[i + o].set = Ye); + }), + S.fn.extend({ + css: function (e, t) { + return $( + this, + function (e, t, n) { + var r, + i, + o = {}, + a = 0; + if (Array.isArray(t)) { + for (r = Re(e), i = t.length; a < i; a++) o[t[a]] = S.css(e, t[a], !1, r); + return o; + } + return void 0 !== n ? S.style(e, t, n) : S.css(e, t); + }, + e, + t, + 1 < arguments.length + ); + }, + }), + (((S.Tween = Ke).prototype = { + constructor: Ke, + init: function (e, t, n, r, i, o) { + (this.elem = e), + (this.prop = n), + (this.easing = i || S.easing._default), + (this.options = t), + (this.start = this.now = this.cur()), + (this.end = r), + (this.unit = o || (S.cssNumber[n] ? '' : 'px')); + }, + cur: function () { + var e = Ke.propHooks[this.prop]; + return e && e.get ? e.get(this) : Ke.propHooks._default.get(this); + }, + run: function (e) { + var t, + n = Ke.propHooks[this.prop]; + return ( + this.options.duration + ? (this.pos = t = S.easing[this.easing]( + e, + this.options.duration * e, + 0, + 1, + this.options.duration + )) + : (this.pos = t = e), + (this.now = (this.end - this.start) * t + this.start), + this.options.step && this.options.step.call(this.elem, this.now, this), + n && n.set ? n.set(this) : Ke.propHooks._default.set(this), + this + ); + }, + }).init.prototype = Ke.prototype), + ((Ke.propHooks = { + _default: { + get: function (e) { + var t; + return 1 !== e.elem.nodeType || + (null != e.elem[e.prop] && null == e.elem.style[e.prop]) + ? e.elem[e.prop] + : (t = S.css(e.elem, e.prop, '')) && 'auto' !== t + ? t + : 0; + }, + set: function (e) { + S.fx.step[e.prop] + ? S.fx.step[e.prop](e) + : 1 !== e.elem.nodeType || + (!S.cssHooks[e.prop] && null == e.elem.style[ze(e.prop)]) + ? (e.elem[e.prop] = e.now) + : S.style(e.elem, e.prop, e.now + e.unit); + }, + }, + }).scrollTop = Ke.propHooks.scrollLeft = { + set: function (e) { + e.elem.nodeType && e.elem.parentNode && (e.elem[e.prop] = e.now); + }, + }), + (S.easing = { + linear: function (e) { + return e; + }, + swing: function (e) { + return 0.5 - Math.cos(e * Math.PI) / 2; + }, + _default: 'swing', + }), + (S.fx = Ke.prototype.init), + (S.fx.step = {}); + var Ze, + et, + tt, + nt, + rt = /^(?:toggle|show|hide)$/, + it = /queueHooks$/; + function ot() { + et && + (!1 === E.hidden && C.requestAnimationFrame + ? C.requestAnimationFrame(ot) + : C.setTimeout(ot, S.fx.interval), + S.fx.tick()); + } + function at() { + return ( + C.setTimeout(function () { + Ze = void 0; + }), + (Ze = Date.now()) + ); + } + function st(e, t) { + var n, + r = 0, + i = { height: e }; + for (t = t ? 1 : 0; r < 4; r += 2 - t) + i['margin' + (n = ne[r])] = i['padding' + n] = e; + return t && (i.opacity = i.width = e), i; + } + function ut(e, t, n) { + for ( + var r, i = (lt.tweeners[t] || []).concat(lt.tweeners['*']), o = 0, a = i.length; + o < a; + o++ + ) + if ((r = i[o].call(n, t, e))) return r; + } + function lt(o, e, t) { + var n, + a, + r = 0, + i = lt.prefilters.length, + s = S.Deferred().always(function () { + delete u.elem; + }), + u = function () { + if (a) return !1; + for ( + var e = Ze || at(), + t = Math.max(0, l.startTime + l.duration - e), + n = 1 - (t / l.duration || 0), + r = 0, + i = l.tweens.length; + r < i; + r++ + ) + l.tweens[r].run(n); + return ( + s.notifyWith(o, [l, n, t]), + n < 1 && i ? t : (i || s.notifyWith(o, [l, 1, 0]), s.resolveWith(o, [l]), !1) + ); + }, + l = s.promise({ + elem: o, + props: S.extend({}, e), + opts: S.extend(!0, { specialEasing: {}, easing: S.easing._default }, t), + originalProperties: e, + originalOptions: t, + startTime: Ze || at(), + duration: t.duration, + tweens: [], + createTween: function (e, t) { + var n = S.Tween(o, l.opts, e, t, l.opts.specialEasing[e] || l.opts.easing); + return l.tweens.push(n), n; + }, + stop: function (e) { + var t = 0, + n = e ? l.tweens.length : 0; + if (a) return this; + for (a = !0; t < n; t++) l.tweens[t].run(1); + return ( + e + ? (s.notifyWith(o, [l, 1, 0]), s.resolveWith(o, [l, e])) + : s.rejectWith(o, [l, e]), + this + ); + }, + }), + c = l.props; + for ( + !(function (e, t) { + var n, r, i, o, a; + for (n in e) + if ( + ((i = t[(r = X(n))]), + (o = e[n]), + Array.isArray(o) && ((i = o[1]), (o = e[n] = o[0])), + n !== r && ((e[r] = o), delete e[n]), + (a = S.cssHooks[r]) && ('expand' in a)) + ) + for (n in ((o = a.expand(o)), delete e[r], o)) + (n in e) || ((e[n] = o[n]), (t[n] = i)); + else t[r] = i; + })(c, l.opts.specialEasing); + r < i; + r++ + ) + if ((n = lt.prefilters[r].call(l, o, c, l.opts))) + return ( + m(n.stop) && (S._queueHooks(l.elem, l.opts.queue).stop = n.stop.bind(n)), n + ); + return ( + S.map(c, ut, l), + m(l.opts.start) && l.opts.start.call(o, l), + l + .progress(l.opts.progress) + .done(l.opts.done, l.opts.complete) + .fail(l.opts.fail) + .always(l.opts.always), + S.fx.timer(S.extend(u, { elem: o, anim: l, queue: l.opts.queue })), + l + ); + } + (S.Animation = S.extend(lt, { + tweeners: { + '*': [ + function (e, t) { + var n = this.createTween(e, t); + return se(n.elem, e, te.exec(t), n), n; + }, + ], + }, + tweener: function (e, t) { + m(e) ? ((t = e), (e = ['*'])) : (e = e.match(P)); + for (var n, r = 0, i = e.length; r < i; r++) + (n = e[r]), (lt.tweeners[n] = lt.tweeners[n] || []), lt.tweeners[n].unshift(t); + }, + prefilters: [ + function (e, t, n) { + var r, + i, + o, + a, + s, + u, + l, + c, + f = 'width' in t || 'height' in t, + p = this, + d = {}, + h = e.style, + g = e.nodeType && ae(e), + v = Y.get(e, 'fxshow'); + for (r in (n.queue || + (null == (a = S._queueHooks(e, 'fx')).unqueued && + ((a.unqueued = 0), + (s = a.empty.fire), + (a.empty.fire = function () { + a.unqueued || s(); + })), + a.unqueued++, + p.always(function () { + p.always(function () { + a.unqueued--, S.queue(e, 'fx').length || a.empty.fire(); + }); + })), + t)) + if (((i = t[r]), rt.test(i))) { + if ((delete t[r], (o = o || 'toggle' === i), i === (g ? 'hide' : 'show'))) { + if ('show' !== i || !v || void 0 === v[r]) continue; + g = !0; + } + d[r] = (v && v[r]) || S.style(e, r); + } + if ((u = !S.isEmptyObject(t)) || !S.isEmptyObject(d)) + for (r in (f && + 1 === e.nodeType && + ((n.overflow = [h.overflow, h.overflowX, h.overflowY]), + null == (l = v && v.display) && (l = Y.get(e, 'display')), + 'none' === (c = S.css(e, 'display')) && + (l + ? (c = l) + : (le([e], !0), + (l = e.style.display || l), + (c = S.css(e, 'display')), + le([e]))), + ('inline' === c || ('inline-block' === c && null != l)) && + 'none' === S.css(e, 'float') && + (u || + (p.done(function () { + h.display = l; + }), + null == l && ((c = h.display), (l = 'none' === c ? '' : c))), + (h.display = 'inline-block'))), + n.overflow && + ((h.overflow = 'hidden'), + p.always(function () { + (h.overflow = n.overflow[0]), + (h.overflowX = n.overflow[1]), + (h.overflowY = n.overflow[2]); + })), + (u = !1), + d)) + u || + (v + ? 'hidden' in v && (g = v.hidden) + : (v = Y.access(e, 'fxshow', { display: l })), + o && (v.hidden = !g), + g && le([e], !0), + p.done(function () { + for (r in (g || le([e]), Y.remove(e, 'fxshow'), d)) S.style(e, r, d[r]); + })), + (u = ut(g ? v[r] : 0, r, p)), + r in v || ((v[r] = u.start), g && ((u.end = u.start), (u.start = 0))); + }, + ], + prefilter: function (e, t) { + t ? lt.prefilters.unshift(e) : lt.prefilters.push(e); + }, + })), + (S.speed = function (e, t, n) { + var r = + e && 'object' == typeof e + ? S.extend({}, e) + : { + complete: n || (!n && t) || (m(e) && e), + duration: e, + easing: (n && t) || (t && !m(t) && t), + }; + return ( + S.fx.off + ? (r.duration = 0) + : 'number' != typeof r.duration && + (r.duration in S.fx.speeds + ? (r.duration = S.fx.speeds[r.duration]) + : (r.duration = S.fx.speeds._default)), + (null != r.queue && !0 !== r.queue) || (r.queue = 'fx'), + (r.old = r.complete), + (r.complete = function () { + m(r.old) && r.old.call(this), r.queue && S.dequeue(this, r.queue); + }), + r + ); + }), + S.fn.extend({ + fadeTo: function (e, t, n, r) { + return this.filter(ae) + .css('opacity', 0) + .show() + .end() + .animate({ opacity: t }, e, n, r); + }, + animate: function (t, e, n, r) { + var i = S.isEmptyObject(t), + o = S.speed(e, n, r), + a = function () { + var e = lt(this, S.extend({}, t), o); + (i || Y.get(this, 'finish')) && e.stop(!0); + }; + return ( + (a.finish = a), i || !1 === o.queue ? this.each(a) : this.queue(o.queue, a) + ); + }, + stop: function (i, e, o) { + var a = function (e) { + var t = e.stop; + delete e.stop, t(o); + }; + return ( + 'string' != typeof i && ((o = e), (e = i), (i = void 0)), + e && this.queue(i || 'fx', []), + this.each(function () { + var e = !0, + t = null != i && i + 'queueHooks', + n = S.timers, + r = Y.get(this); + if (t) r[t] && r[t].stop && a(r[t]); + else for (t in r) r[t] && r[t].stop && it.test(t) && a(r[t]); + for (t = n.length; t--; ) + n[t].elem !== this || + (null != i && n[t].queue !== i) || + (n[t].anim.stop(o), (e = !1), n.splice(t, 1)); + (!e && o) || S.dequeue(this, i); + }) + ); + }, + finish: function (a) { + return ( + !1 !== a && (a = a || 'fx'), + this.each(function () { + var e, + t = Y.get(this), + n = t[a + 'queue'], + r = t[a + 'queueHooks'], + i = S.timers, + o = n ? n.length : 0; + for ( + t.finish = !0, + S.queue(this, a, []), + r && r.stop && r.stop.call(this, !0), + e = i.length; + e--; + + ) + i[e].elem === this && + i[e].queue === a && + (i[e].anim.stop(!0), i.splice(e, 1)); + for (e = 0; e < o; e++) n[e] && n[e].finish && n[e].finish.call(this); + delete t.finish; + }) + ); + }, + }), + S.each(['toggle', 'show', 'hide'], function (e, r) { + var i = S.fn[r]; + S.fn[r] = function (e, t, n) { + return null == e || 'boolean' == typeof e + ? i.apply(this, arguments) + : this.animate(st(r, !0), e, t, n); + }; + }), + S.each( + { + slideDown: st('show'), + slideUp: st('hide'), + slideToggle: st('toggle'), + fadeIn: { opacity: 'show' }, + fadeOut: { opacity: 'hide' }, + fadeToggle: { opacity: 'toggle' }, + }, + function (e, r) { + S.fn[e] = function (e, t, n) { + return this.animate(r, e, t, n); + }; + } + ), + (S.timers = []), + (S.fx.tick = function () { + var e, + t = 0, + n = S.timers; + for (Ze = Date.now(); t < n.length; t++) + (e = n[t])() || n[t] !== e || n.splice(t--, 1); + n.length || S.fx.stop(), (Ze = void 0); + }), + (S.fx.timer = function (e) { + S.timers.push(e), S.fx.start(); + }), + (S.fx.interval = 13), + (S.fx.start = function () { + et || ((et = !0), ot()); + }), + (S.fx.stop = function () { + et = null; + }), + (S.fx.speeds = { slow: 600, fast: 200, _default: 400 }), + (S.fn.delay = function (r, e) { + return ( + (r = (S.fx && S.fx.speeds[r]) || r), + (e = e || 'fx'), + this.queue(e, function (e, t) { + var n = C.setTimeout(e, r); + t.stop = function () { + C.clearTimeout(n); + }; + }) + ); + }), + (tt = E.createElement('input')), + (nt = E.createElement('select').appendChild(E.createElement('option'))), + (tt.type = 'checkbox'), + (y.checkOn = '' !== tt.value), + (y.optSelected = nt.selected), + ((tt = E.createElement('input')).value = 't'), + (tt.type = 'radio'), + (y.radioValue = 't' === tt.value); + var ct, + ft = S.expr.attrHandle; + S.fn.extend({ + attr: function (e, t) { + return $(this, S.attr, e, t, 1 < arguments.length); + }, + removeAttr: function (e) { + return this.each(function () { + S.removeAttr(this, e); + }); + }, + }), + S.extend({ + attr: function (e, t, n) { + var r, + i, + o = e.nodeType; + if (3 !== o && 8 !== o && 2 !== o) + return 'undefined' == typeof e.getAttribute + ? S.prop(e, t, n) + : ((1 === o && S.isXMLDoc(e)) || + (i = + S.attrHooks[t.toLowerCase()] || + (S.expr.match.bool.test(t) ? ct : void 0)), + void 0 !== n + ? null === n + ? void S.removeAttr(e, t) + : i && 'set' in i && void 0 !== (r = i.set(e, n, t)) + ? r + : (e.setAttribute(t, n + ''), n) + : i && 'get' in i && null !== (r = i.get(e, t)) + ? r + : null == (r = S.find.attr(e, t)) + ? void 0 + : r); + }, + attrHooks: { + type: { + set: function (e, t) { + if (!y.radioValue && 'radio' === t && A(e, 'input')) { + var n = e.value; + return e.setAttribute('type', t), n && (e.value = n), t; + } + }, + }, + }, + removeAttr: function (e, t) { + var n, + r = 0, + i = t && t.match(P); + if (i && 1 === e.nodeType) while ((n = i[r++])) e.removeAttribute(n); + }, + }), + (ct = { + set: function (e, t, n) { + return !1 === t ? S.removeAttr(e, n) : e.setAttribute(n, n), n; + }, + }), + S.each(S.expr.match.bool.source.match(/\w+/g), function (e, t) { + var a = ft[t] || S.find.attr; + ft[t] = function (e, t, n) { + var r, + i, + o = t.toLowerCase(); + return ( + n || + ((i = ft[o]), (ft[o] = r), (r = null != a(e, t, n) ? o : null), (ft[o] = i)), + r + ); + }; + }); + var pt = /^(?:input|select|textarea|button)$/i, + dt = /^(?:a|area)$/i; + function ht(e) { + return (e.match(P) || []).join(' '); + } + function gt(e) { + return (e.getAttribute && e.getAttribute('class')) || ''; + } + function vt(e) { + return Array.isArray(e) ? e : ('string' == typeof e && e.match(P)) || []; + } + S.fn.extend({ + prop: function (e, t) { + return $(this, S.prop, e, t, 1 < arguments.length); + }, + removeProp: function (e) { + return this.each(function () { + delete this[S.propFix[e] || e]; + }); + }, + }), + S.extend({ + prop: function (e, t, n) { + var r, + i, + o = e.nodeType; + if (3 !== o && 8 !== o && 2 !== o) + return ( + (1 === o && S.isXMLDoc(e)) || ((t = S.propFix[t] || t), (i = S.propHooks[t])), + void 0 !== n + ? i && 'set' in i && void 0 !== (r = i.set(e, n, t)) + ? r + : (e[t] = n) + : i && 'get' in i && null !== (r = i.get(e, t)) + ? r + : e[t] + ); + }, + propHooks: { + tabIndex: { + get: function (e) { + var t = S.find.attr(e, 'tabindex'); + return t + ? parseInt(t, 10) + : pt.test(e.nodeName) || (dt.test(e.nodeName) && e.href) + ? 0 + : -1; + }, + }, + }, + propFix: { for: 'htmlFor', class: 'className' }, + }), + y.optSelected || + (S.propHooks.selected = { + get: function (e) { + var t = e.parentNode; + return t && t.parentNode && t.parentNode.selectedIndex, null; + }, + set: function (e) { + var t = e.parentNode; + t && (t.selectedIndex, t.parentNode && t.parentNode.selectedIndex); + }, + }), + S.each( + [ + 'tabIndex', + 'readOnly', + 'maxLength', + 'cellSpacing', + 'cellPadding', + 'rowSpan', + 'colSpan', + 'useMap', + 'frameBorder', + 'contentEditable', + ], + function () { + S.propFix[this.toLowerCase()] = this; + } + ), + S.fn.extend({ + addClass: function (t) { + var e, + n, + r, + i, + o, + a, + s, + u = 0; + if (m(t)) + return this.each(function (e) { + S(this).addClass(t.call(this, e, gt(this))); + }); + if ((e = vt(t)).length) + while ((n = this[u++])) + if (((i = gt(n)), (r = 1 === n.nodeType && ' ' + ht(i) + ' '))) { + a = 0; + while ((o = e[a++])) r.indexOf(' ' + o + ' ') < 0 && (r += o + ' '); + i !== (s = ht(r)) && n.setAttribute('class', s); + } + return this; + }, + removeClass: function (t) { + var e, + n, + r, + i, + o, + a, + s, + u = 0; + if (m(t)) + return this.each(function (e) { + S(this).removeClass(t.call(this, e, gt(this))); + }); + if (!arguments.length) return this.attr('class', ''); + if ((e = vt(t)).length) + while ((n = this[u++])) + if (((i = gt(n)), (r = 1 === n.nodeType && ' ' + ht(i) + ' '))) { + a = 0; + while ((o = e[a++])) + while (-1 < r.indexOf(' ' + o + ' ')) r = r.replace(' ' + o + ' ', ' '); + i !== (s = ht(r)) && n.setAttribute('class', s); + } + return this; + }, + toggleClass: function (i, t) { + var o = typeof i, + a = 'string' === o || Array.isArray(i); + return 'boolean' == typeof t && a + ? t + ? this.addClass(i) + : this.removeClass(i) + : m(i) + ? this.each(function (e) { + S(this).toggleClass(i.call(this, e, gt(this), t), t); + }) + : this.each(function () { + var e, t, n, r; + if (a) { + (t = 0), (n = S(this)), (r = vt(i)); + while ((e = r[t++])) n.hasClass(e) ? n.removeClass(e) : n.addClass(e); + } else (void 0 !== i && 'boolean' !== o) || ((e = gt(this)) && Y.set(this, '__className__', e), this.setAttribute && this.setAttribute('class', e || !1 === i ? '' : Y.get(this, '__className__') || '')); + }); + }, + hasClass: function (e) { + var t, + n, + r = 0; + t = ' ' + e + ' '; + while ((n = this[r++])) + if (1 === n.nodeType && -1 < (' ' + ht(gt(n)) + ' ').indexOf(t)) return !0; + return !1; + }, + }); + var yt = /\r/g; + S.fn.extend({ + val: function (n) { + var r, + e, + i, + t = this[0]; + return arguments.length + ? ((i = m(n)), + this.each(function (e) { + var t; + 1 === this.nodeType && + (null == (t = i ? n.call(this, e, S(this).val()) : n) + ? (t = '') + : 'number' == typeof t + ? (t += '') + : Array.isArray(t) && + (t = S.map(t, function (e) { + return null == e ? '' : e + ''; + })), + ((r = S.valHooks[this.type] || S.valHooks[this.nodeName.toLowerCase()]) && + 'set' in r && + void 0 !== r.set(this, t, 'value')) || + (this.value = t)); + })) + : t + ? (r = S.valHooks[t.type] || S.valHooks[t.nodeName.toLowerCase()]) && + 'get' in r && + void 0 !== (e = r.get(t, 'value')) + ? e + : 'string' == typeof (e = t.value) + ? e.replace(yt, '') + : null == e + ? '' + : e + : void 0; + }, + }), + S.extend({ + valHooks: { + option: { + get: function (e) { + var t = S.find.attr(e, 'value'); + return null != t ? t : ht(S.text(e)); + }, + }, + select: { + get: function (e) { + var t, + n, + r, + i = e.options, + o = e.selectedIndex, + a = 'select-one' === e.type, + s = a ? null : [], + u = a ? o + 1 : i.length; + for (r = o < 0 ? u : a ? o : 0; r < u; r++) + if ( + ((n = i[r]).selected || r === o) && + !n.disabled && + (!n.parentNode.disabled || !A(n.parentNode, 'optgroup')) + ) { + if (((t = S(n).val()), a)) return t; + s.push(t); + } + return s; + }, + set: function (e, t) { + var n, + r, + i = e.options, + o = S.makeArray(t), + a = i.length; + while (a--) + ((r = i[a]).selected = -1 < S.inArray(S.valHooks.option.get(r), o)) && + (n = !0); + return n || (e.selectedIndex = -1), o; + }, + }, + }, + }), + S.each(['radio', 'checkbox'], function () { + (S.valHooks[this] = { + set: function (e, t) { + if (Array.isArray(t)) return (e.checked = -1 < S.inArray(S(e).val(), t)); + }, + }), + y.checkOn || + (S.valHooks[this].get = function (e) { + return null === e.getAttribute('value') ? 'on' : e.value; + }); + }), + (y.focusin = 'onfocusin' in C); + var mt = /^(?:focusinfocus|focusoutblur)$/, + xt = function (e) { + e.stopPropagation(); + }; + S.extend(S.event, { + trigger: function (e, t, n, r) { + var i, + o, + a, + s, + u, + l, + c, + f, + p = [n || E], + d = v.call(e, 'type') ? e.type : e, + h = v.call(e, 'namespace') ? e.namespace.split('.') : []; + if ( + ((o = f = a = n = n || E), + 3 !== n.nodeType && + 8 !== n.nodeType && + !mt.test(d + S.event.triggered) && + (-1 < d.indexOf('.') && ((d = (h = d.split('.')).shift()), h.sort()), + (u = d.indexOf(':') < 0 && 'on' + d), + ((e = e[S.expando] + ? e + : new S.Event(d, 'object' == typeof e && e)).isTrigger = r ? 2 : 3), + (e.namespace = h.join('.')), + (e.rnamespace = e.namespace + ? new RegExp('(^|\\.)' + h.join('\\.(?:.*\\.|)') + '(\\.|$)') + : null), + (e.result = void 0), + e.target || (e.target = n), + (t = null == t ? [e] : S.makeArray(t, [e])), + (c = S.event.special[d] || {}), + r || !c.trigger || !1 !== c.trigger.apply(n, t))) + ) { + if (!r && !c.noBubble && !x(n)) { + for ( + s = c.delegateType || d, mt.test(s + d) || (o = o.parentNode); + o; + o = o.parentNode + ) + p.push(o), (a = o); + a === (n.ownerDocument || E) && p.push(a.defaultView || a.parentWindow || C); + } + i = 0; + while ((o = p[i++]) && !e.isPropagationStopped()) + (f = o), + (e.type = 1 < i ? s : c.bindType || d), + (l = + (Y.get(o, 'events') || Object.create(null))[e.type] && + Y.get(o, 'handle')) && l.apply(o, t), + (l = u && o[u]) && + l.apply && + V(o) && + ((e.result = l.apply(o, t)), !1 === e.result && e.preventDefault()); + return ( + (e.type = d), + r || + e.isDefaultPrevented() || + (c._default && !1 !== c._default.apply(p.pop(), t)) || + !V(n) || + (u && + m(n[d]) && + !x(n) && + ((a = n[u]) && (n[u] = null), + (S.event.triggered = d), + e.isPropagationStopped() && f.addEventListener(d, xt), + n[d](), + e.isPropagationStopped() && f.removeEventListener(d, xt), + (S.event.triggered = void 0), + a && (n[u] = a))), + e.result + ); + } + }, + simulate: function (e, t, n) { + var r = S.extend(new S.Event(), n, { type: e, isSimulated: !0 }); + S.event.trigger(r, null, t); + }, + }), + S.fn.extend({ + trigger: function (e, t) { + return this.each(function () { + S.event.trigger(e, t, this); + }); + }, + triggerHandler: function (e, t) { + var n = this[0]; + if (n) return S.event.trigger(e, t, n, !0); + }, + }), + y.focusin || + S.each({ focus: 'focusin', blur: 'focusout' }, function (n, r) { + var i = function (e) { + S.event.simulate(r, e.target, S.event.fix(e)); + }; + S.event.special[r] = { + setup: function () { + var e = this.ownerDocument || this.document || this, + t = Y.access(e, r); + t || e.addEventListener(n, i, !0), Y.access(e, r, (t || 0) + 1); + }, + teardown: function () { + var e = this.ownerDocument || this.document || this, + t = Y.access(e, r) - 1; + t ? Y.access(e, r, t) : (e.removeEventListener(n, i, !0), Y.remove(e, r)); + }, + }; + }); + var bt = C.location, + wt = { guid: Date.now() }, + Tt = /\?/; + S.parseXML = function (e) { + var t, n; + if (!e || 'string' != typeof e) return null; + try { + t = new C.DOMParser().parseFromString(e, 'text/xml'); + } catch (e) {} + return ( + (n = t && t.getElementsByTagName('parsererror')[0]), + (t && !n) || + S.error( + 'Invalid XML: ' + + (n + ? S.map(n.childNodes, function (e) { + return e.textContent; + }).join('\n') + : e) + ), + t + ); + }; + var Ct = /\[\]$/, + Et = /\r?\n/g, + St = /^(?:submit|button|image|reset|file)$/i, + kt = /^(?:input|select|textarea|keygen)/i; + function At(n, e, r, i) { + var t; + if (Array.isArray(e)) + S.each(e, function (e, t) { + r || Ct.test(n) + ? i(n, t) + : At(n + '[' + ('object' == typeof t && null != t ? e : '') + ']', t, r, i); + }); + else if (r || 'object' !== w(e)) i(n, e); + else for (t in e) At(n + '[' + t + ']', e[t], r, i); + } + (S.param = function (e, t) { + var n, + r = [], + i = function (e, t) { + var n = m(t) ? t() : t; + r[r.length] = + encodeURIComponent(e) + '=' + encodeURIComponent(null == n ? '' : n); + }; + if (null == e) return ''; + if (Array.isArray(e) || (e.jquery && !S.isPlainObject(e))) + S.each(e, function () { + i(this.name, this.value); + }); + else for (n in e) At(n, e[n], t, i); + return r.join('&'); + }), + S.fn.extend({ + serialize: function () { + return S.param(this.serializeArray()); + }, + serializeArray: function () { + return this.map(function () { + var e = S.prop(this, 'elements'); + return e ? S.makeArray(e) : this; + }) + .filter(function () { + var e = this.type; + return ( + this.name && + !S(this).is(':disabled') && + kt.test(this.nodeName) && + !St.test(e) && + (this.checked || !pe.test(e)) + ); + }) + .map(function (e, t) { + var n = S(this).val(); + return null == n + ? null + : Array.isArray(n) + ? S.map(n, function (e) { + return { name: t.name, value: e.replace(Et, '\r\n') }; + }) + : { name: t.name, value: n.replace(Et, '\r\n') }; + }) + .get(); + }, + }); + var Nt = /%20/g, + jt = /#.*$/, + Dt = /([?&])_=[^&]*/, + qt = /^(.*?):[ \t]*([^\r\n]*)$/gm, + Lt = /^(?:GET|HEAD)$/, + Ht = /^\/\//, + Ot = {}, + Pt = {}, + Rt = '*/'.concat('*'), + Mt = E.createElement('a'); + function It(o) { + return function (e, t) { + 'string' != typeof e && ((t = e), (e = '*')); + var n, + r = 0, + i = e.toLowerCase().match(P) || []; + if (m(t)) + while ((n = i[r++])) + '+' === n[0] + ? ((n = n.slice(1) || '*'), (o[n] = o[n] || []).unshift(t)) + : (o[n] = o[n] || []).push(t); + }; + } + function Wt(t, i, o, a) { + var s = {}, + u = t === Pt; + function l(e) { + var r; + return ( + (s[e] = !0), + S.each(t[e] || [], function (e, t) { + var n = t(i, o, a); + return 'string' != typeof n || u || s[n] + ? u + ? !(r = n) + : void 0 + : (i.dataTypes.unshift(n), l(n), !1); + }), + r + ); + } + return l(i.dataTypes[0]) || (!s['*'] && l('*')); + } + function Ft(e, t) { + var n, + r, + i = S.ajaxSettings.flatOptions || {}; + for (n in t) void 0 !== t[n] && ((i[n] ? e : r || (r = {}))[n] = t[n]); + return r && S.extend(!0, e, r), e; + } + (Mt.href = bt.href), + S.extend({ + active: 0, + lastModified: {}, + etag: {}, + ajaxSettings: { + url: bt.href, + type: 'GET', + isLocal: /^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test( + bt.protocol + ), + global: !0, + processData: !0, + async: !0, + contentType: 'application/x-www-form-urlencoded; charset=UTF-8', + accepts: { + '*': Rt, + text: 'text/plain', + html: 'text/html', + xml: 'application/xml, text/xml', + json: 'application/json, text/javascript', + }, + contents: { xml: /\bxml\b/, html: /\bhtml/, json: /\bjson\b/ }, + responseFields: { + xml: 'responseXML', + text: 'responseText', + json: 'responseJSON', + }, + converters: { + '* text': String, + 'text html': !0, + 'text json': JSON.parse, + 'text xml': S.parseXML, + }, + flatOptions: { url: !0, context: !0 }, + }, + ajaxSetup: function (e, t) { + return t ? Ft(Ft(e, S.ajaxSettings), t) : Ft(S.ajaxSettings, e); + }, + ajaxPrefilter: It(Ot), + ajaxTransport: It(Pt), + ajax: function (e, t) { + 'object' == typeof e && ((t = e), (e = void 0)), (t = t || {}); + var c, + f, + p, + n, + d, + r, + h, + g, + i, + o, + v = S.ajaxSetup({}, t), + y = v.context || v, + m = v.context && (y.nodeType || y.jquery) ? S(y) : S.event, + x = S.Deferred(), + b = S.Callbacks('once memory'), + w = v.statusCode || {}, + a = {}, + s = {}, + u = 'canceled', + T = { + readyState: 0, + getResponseHeader: function (e) { + var t; + if (h) { + if (!n) { + n = {}; + while ((t = qt.exec(p))) + n[t[1].toLowerCase() + ' '] = ( + n[t[1].toLowerCase() + ' '] || [] + ).concat(t[2]); + } + t = n[e.toLowerCase() + ' ']; + } + return null == t ? null : t.join(', '); + }, + getAllResponseHeaders: function () { + return h ? p : null; + }, + setRequestHeader: function (e, t) { + return ( + null == h && + ((e = s[e.toLowerCase()] = s[e.toLowerCase()] || e), (a[e] = t)), + this + ); + }, + overrideMimeType: function (e) { + return null == h && (v.mimeType = e), this; + }, + statusCode: function (e) { + var t; + if (e) + if (h) T.always(e[T.status]); + else for (t in e) w[t] = [w[t], e[t]]; + return this; + }, + abort: function (e) { + var t = e || u; + return c && c.abort(t), l(0, t), this; + }, + }; + if ( + (x.promise(T), + (v.url = ((e || v.url || bt.href) + '').replace(Ht, bt.protocol + '//')), + (v.type = t.method || t.type || v.method || v.type), + (v.dataTypes = (v.dataType || '*').toLowerCase().match(P) || ['']), + null == v.crossDomain) + ) { + r = E.createElement('a'); + try { + (r.href = v.url), + (r.href = r.href), + (v.crossDomain = + Mt.protocol + '//' + Mt.host != r.protocol + '//' + r.host); + } catch (e) { + v.crossDomain = !0; + } + } + if ( + (v.data && + v.processData && + 'string' != typeof v.data && + (v.data = S.param(v.data, v.traditional)), + Wt(Ot, v, t, T), + h) + ) + return T; + for (i in ((g = S.event && v.global) && + 0 == S.active++ && + S.event.trigger('ajaxStart'), + (v.type = v.type.toUpperCase()), + (v.hasContent = !Lt.test(v.type)), + (f = v.url.replace(jt, '')), + v.hasContent + ? v.data && + v.processData && + 0 === (v.contentType || '').indexOf('application/x-www-form-urlencoded') && + (v.data = v.data.replace(Nt, '+')) + : ((o = v.url.slice(f.length)), + v.data && + (v.processData || 'string' == typeof v.data) && + ((f += (Tt.test(f) ? '&' : '?') + v.data), delete v.data), + !1 === v.cache && + ((f = f.replace(Dt, '$1')), + (o = (Tt.test(f) ? '&' : '?') + '_=' + wt.guid++ + o)), + (v.url = f + o)), + v.ifModified && + (S.lastModified[f] && + T.setRequestHeader('If-Modified-Since', S.lastModified[f]), + S.etag[f] && T.setRequestHeader('If-None-Match', S.etag[f])), + ((v.data && v.hasContent && !1 !== v.contentType) || t.contentType) && + T.setRequestHeader('Content-Type', v.contentType), + T.setRequestHeader( + 'Accept', + v.dataTypes[0] && v.accepts[v.dataTypes[0]] + ? v.accepts[v.dataTypes[0]] + + ('*' !== v.dataTypes[0] ? ', ' + Rt + '; q=0.01' : '') + : v.accepts['*'] + ), + v.headers)) + T.setRequestHeader(i, v.headers[i]); + if (v.beforeSend && (!1 === v.beforeSend.call(y, T, v) || h)) return T.abort(); + if ( + ((u = 'abort'), + b.add(v.complete), + T.done(v.success), + T.fail(v.error), + (c = Wt(Pt, v, t, T))) + ) { + if (((T.readyState = 1), g && m.trigger('ajaxSend', [T, v]), h)) return T; + v.async && + 0 < v.timeout && + (d = C.setTimeout(function () { + T.abort('timeout'); + }, v.timeout)); + try { + (h = !1), c.send(a, l); + } catch (e) { + if (h) throw e; + l(-1, e); + } + } else l(-1, 'No Transport'); + function l(e, t, n, r) { + var i, + o, + a, + s, + u, + l = t; + h || + ((h = !0), + d && C.clearTimeout(d), + (c = void 0), + (p = r || ''), + (T.readyState = 0 < e ? 4 : 0), + (i = (200 <= e && e < 300) || 304 === e), + n && + (s = (function (e, t, n) { + var r, + i, + o, + a, + s = e.contents, + u = e.dataTypes; + while ('*' === u[0]) + u.shift(), + void 0 === r && + (r = e.mimeType || t.getResponseHeader('Content-Type')); + if (r) + for (i in s) + if (s[i] && s[i].test(r)) { + u.unshift(i); + break; + } + if (u[0] in n) o = u[0]; + else { + for (i in n) { + if (!u[0] || e.converters[i + ' ' + u[0]]) { + o = i; + break; + } + a || (a = i); + } + o = o || a; + } + if (o) return o !== u[0] && u.unshift(o), n[o]; + })(v, T, n)), + !i && + -1 < S.inArray('script', v.dataTypes) && + S.inArray('json', v.dataTypes) < 0 && + (v.converters['text script'] = function () {}), + (s = (function (e, t, n, r) { + var i, + o, + a, + s, + u, + l = {}, + c = e.dataTypes.slice(); + if (c[1]) for (a in e.converters) l[a.toLowerCase()] = e.converters[a]; + o = c.shift(); + while (o) + if ( + (e.responseFields[o] && (n[e.responseFields[o]] = t), + !u && r && e.dataFilter && (t = e.dataFilter(t, e.dataType)), + (u = o), + (o = c.shift())) + ) + if ('*' === o) o = u; + else if ('*' !== u && u !== o) { + if (!(a = l[u + ' ' + o] || l['* ' + o])) + for (i in l) + if ( + (s = i.split(' '))[1] === o && + (a = l[u + ' ' + s[0]] || l['* ' + s[0]]) + ) { + !0 === a + ? (a = l[i]) + : !0 !== l[i] && ((o = s[0]), c.unshift(s[1])); + break; + } + if (!0 !== a) + if (a && e['throws']) t = a(t); + else + try { + t = a(t); + } catch (e) { + return { + state: 'parsererror', + error: a ? e : 'No conversion from ' + u + ' to ' + o, + }; + } + } + return { state: 'success', data: t }; + })(v, s, T, i)), + i + ? (v.ifModified && + ((u = T.getResponseHeader('Last-Modified')) && (S.lastModified[f] = u), + (u = T.getResponseHeader('etag')) && (S.etag[f] = u)), + 204 === e || 'HEAD' === v.type + ? (l = 'nocontent') + : 304 === e + ? (l = 'notmodified') + : ((l = s.state), (o = s.data), (i = !(a = s.error)))) + : ((a = l), (!e && l) || ((l = 'error'), e < 0 && (e = 0))), + (T.status = e), + (T.statusText = (t || l) + ''), + i ? x.resolveWith(y, [o, l, T]) : x.rejectWith(y, [T, l, a]), + T.statusCode(w), + (w = void 0), + g && m.trigger(i ? 'ajaxSuccess' : 'ajaxError', [T, v, i ? o : a]), + b.fireWith(y, [T, l]), + g && + (m.trigger('ajaxComplete', [T, v]), + --S.active || S.event.trigger('ajaxStop'))); + } + return T; + }, + getJSON: function (e, t, n) { + return S.get(e, t, n, 'json'); + }, + getScript: function (e, t) { + return S.get(e, void 0, t, 'script'); + }, + }), + S.each(['get', 'post'], function (e, i) { + S[i] = function (e, t, n, r) { + return ( + m(t) && ((r = r || n), (n = t), (t = void 0)), + S.ajax( + S.extend( + { url: e, type: i, dataType: r, data: t, success: n }, + S.isPlainObject(e) && e + ) + ) + ); + }; + }), + S.ajaxPrefilter(function (e) { + var t; + for (t in e.headers) + 'content-type' === t.toLowerCase() && (e.contentType = e.headers[t] || ''); + }), + (S._evalUrl = function (e, t, n) { + return S.ajax({ + url: e, + type: 'GET', + dataType: 'script', + cache: !0, + async: !1, + global: !1, + converters: { 'text script': function () {} }, + dataFilter: function (e) { + S.globalEval(e, t, n); + }, + }); + }), + S.fn.extend({ + wrapAll: function (e) { + var t; + return ( + this[0] && + (m(e) && (e = e.call(this[0])), + (t = S(e, this[0].ownerDocument).eq(0).clone(!0)), + this[0].parentNode && t.insertBefore(this[0]), + t + .map(function () { + var e = this; + while (e.firstElementChild) e = e.firstElementChild; + return e; + }) + .append(this)), + this + ); + }, + wrapInner: function (n) { + return m(n) + ? this.each(function (e) { + S(this).wrapInner(n.call(this, e)); + }) + : this.each(function () { + var e = S(this), + t = e.contents(); + t.length ? t.wrapAll(n) : e.append(n); + }); + }, + wrap: function (t) { + var n = m(t); + return this.each(function (e) { + S(this).wrapAll(n ? t.call(this, e) : t); + }); + }, + unwrap: function (e) { + return ( + this.parent(e) + .not('body') + .each(function () { + S(this).replaceWith(this.childNodes); + }), + this + ); + }, + }), + (S.expr.pseudos.hidden = function (e) { + return !S.expr.pseudos.visible(e); + }), + (S.expr.pseudos.visible = function (e) { + return !!(e.offsetWidth || e.offsetHeight || e.getClientRects().length); + }), + (S.ajaxSettings.xhr = function () { + try { + return new C.XMLHttpRequest(); + } catch (e) {} + }); + var Bt = { 0: 200, 1223: 204 }, + $t = S.ajaxSettings.xhr(); + (y.cors = !!$t && 'withCredentials' in $t), + (y.ajax = $t = !!$t), + S.ajaxTransport(function (i) { + var o, a; + if (y.cors || ($t && !i.crossDomain)) + return { + send: function (e, t) { + var n, + r = i.xhr(); + if ((r.open(i.type, i.url, i.async, i.username, i.password), i.xhrFields)) + for (n in i.xhrFields) r[n] = i.xhrFields[n]; + for (n in (i.mimeType && r.overrideMimeType && r.overrideMimeType(i.mimeType), + i.crossDomain || + e['X-Requested-With'] || + (e['X-Requested-With'] = 'XMLHttpRequest'), + e)) + r.setRequestHeader(n, e[n]); + (o = function (e) { + return function () { + o && + ((o = a = r.onload = r.onerror = r.onabort = r.ontimeout = r.onreadystatechange = null), + 'abort' === e + ? r.abort() + : 'error' === e + ? 'number' != typeof r.status + ? t(0, 'error') + : t(r.status, r.statusText) + : t( + Bt[r.status] || r.status, + r.statusText, + 'text' !== (r.responseType || 'text') || + 'string' != typeof r.responseText + ? { binary: r.response } + : { text: r.responseText }, + r.getAllResponseHeaders() + )); + }; + }), + (r.onload = o()), + (a = r.onerror = r.ontimeout = o('error')), + void 0 !== r.onabort + ? (r.onabort = a) + : (r.onreadystatechange = function () { + 4 === r.readyState && + C.setTimeout(function () { + o && a(); + }); + }), + (o = o('abort')); + try { + r.send((i.hasContent && i.data) || null); + } catch (e) { + if (o) throw e; + } + }, + abort: function () { + o && o(); + }, + }; + }), + S.ajaxPrefilter(function (e) { + e.crossDomain && (e.contents.script = !1); + }), + S.ajaxSetup({ + accepts: { + script: + 'text/javascript, application/javascript, application/ecmascript, application/x-ecmascript', + }, + contents: { script: /\b(?:java|ecma)script\b/ }, + converters: { + 'text script': function (e) { + return S.globalEval(e), e; + }, + }, + }), + S.ajaxPrefilter('script', function (e) { + void 0 === e.cache && (e.cache = !1), e.crossDomain && (e.type = 'GET'); + }), + S.ajaxTransport('script', function (n) { + var r, i; + if (n.crossDomain || n.scriptAttrs) + return { + send: function (e, t) { + (r = S(' + + + diff --git a/ChromeExtension/popup/popup.js b/ChromeExtension/popup/popup.js new file mode 100644 index 0000000..55ded5b --- /dev/null +++ b/ChromeExtension/popup/popup.js @@ -0,0 +1,6 @@ +$("#togBtn").click(() => { + chrome.tabs.query({ currentWindow: true, active: true }, (tabs) => { + const activeTab = tabs[0]; + chrome.tabs.sendMessage(activeTab.id, { type: "TOGGLE_EXTENSION" }); + }); +}); diff --git a/ChromeExtension/styles/overview_page.css b/ChromeExtension/styles/overview_page.css new file mode 100644 index 0000000..244c178 --- /dev/null +++ b/ChromeExtension/styles/overview_page.css @@ -0,0 +1,1047 @@ +body { + font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif, + Apple Color Emoji, Segoe UI Emoji; + font-size: 14px; + line-height: 1.5; + margin: 0 !important; +} + +body, +html { + max-width: 100%; + overflow-x: hidden; +} + +.row { + justify-content: center; + flex-direction: row; + align-items: center; + margin-top: 20px; + display: flex; + -ms-flex-wrap: wrap; + flex-wrap: wrap; + margin-right: -5px; + margin-left: -5px; +} + +.row:first-of-type { + margin-top: 80px; +} + +.card { + width: 20%; + border-radius: 6px; + background-color: #fff; + border: 1px solid #e1e4e8; + display: flex; + margin-right: 20px; + flex-direction: column; + box-sizing: border-box; + padding-left: 8px; + padding-right: 8px; +} + +.card-title, +#list-title { + font-family: Roboto, sans-serif; + -moz-osx-font-smoothing: grayscale; + -webkit-font-smoothing: antialiased; + font-size: 14px; + line-height: 1.5; + font-weight: 500; + letter-spacing: 0.0125em; + text-decoration: inherit; + text-transform: inherit; +} + +.card-title a:hover { + text-decoration: underline; +} + +.card-title a { + color: #0366d6; + text-decoration: none; + font-weight: 600; +} + +.card-title-small { + font-size: 12px !important; +} + +.card-text-section { + padding-top: 18px; + padding-right: 16px; + padding-left: 16px; +} + +.main-text { + font-family: Roboto, sans-serif; + -moz-osx-font-smoothing: grayscale; + -webkit-font-smoothing: antialiased; + font-size: 12px; + line-height: 1.25rem; + font-weight: 400; + letter-spacing: 0.0178571429em; + text-decoration: inherit; + text-transform: inherit; + opacity: 0.6; +} + +.card-actions { + display: flex; + flex-direction: row; + align-items: center; + box-sizing: border-box; + min-height: 52px; + padding: 8px 8px 8px 16px; +} + +.card-language-section { + display: flex; + flex-direction: row; + padding: 8px; + margin-left: 10px; +} + +.card-language-section .top-language { + margin-left: 10px; +} + +.card-button { + box-sizing: border-box; +} + +.show { + display: block; +} + +.card-button .label { + cursor: pointer; + -moz-osx-font-smoothing: grayscale; + color: #fff; + background-color: #2ea44f; + border-color: rgba(27, 31, 35, 0.15); + border-radius: 6px; + box-shadow: 0 1px 0 rgba(27, 31, 35, 0.1), inset 0 1px 0 hsla(0, 0%, 100%, 0.03); + display: inline-block; + padding: 5px 16px; + font-size: 14px; + font-weight: 500; + line-height: 20px; + white-space: nowrap; + vertical-align: middle; + cursor: pointer; +} + +/* The Modal (background) */ +.modal { + display: none; + position: fixed; + z-index: 1; + padding-top: 100px; + left: 0; + top: 0; + width: 100%; + height: 100%; + overflow: auto; + background-color: rgb(0, 0, 0); /* Fallback color */ + background-color: rgba(0, 0, 0, 0.4); +} + +/* Modal Content */ +.modal-content { + background-color: #fefefe; + margin: auto; + padding: 20px; + border: 1px solid #888; + width: 80%; + height: 500px; + overflow-y: scroll; +} + +/* The Close Button */ +.close { + color: #aaaaaa; + float: right; + font-size: 28px; + font-weight: bold; +} + +.close:hover, +.close:focus { + color: #000; + text-decoration: none; + cursor: pointer; +} + +.message-title { + margin-top: 0px !important; + margin-bottom: 0px !important; + border-left: 1px solid #e1e4e8; + border-right: 1px solid #e1e4e8; + border-top: 1px solid #e1e4e8; + -webkit-font-smoothing: antialiased; + font-size: 0.875rem; + line-height: 1.25rem; + font-weight: 400; + letter-spacing: 0.0178571429em; + text-decoration: inherit; + text-transform: inherit; + padding: 8px 16px; +} + +.timeStamp { + display: block; + color: #aaaaaa; +} + +#username { + font-size: 32px; + text-align: center; + font-weight: bold; +} + +.repo-language-color { + width: 12px; + height: 12px; + border-radius: 50%; + margin-top: 4px; +} + +.text-gray { + color: #586069 !important; +} + +.octicon { + vertical-align: text-bottom; + display: inline-block; +} + +a:visited { + text-decoration: none; + color: #0366d6; +} + +/** Begin GitHub Layout Styles for nav bars **/ +* { + box-sizing: border-box; +} + +body { + font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif, + Apple Color Emoji, Segoe UI Emoji; + font-size: 14px; + line-height: 1.5; + color: #24292e; + background-color: #fff; +} + +.d-flex { + display: flex !important; +} + +.mt-4 { + margin-top: 24px !important; +} + +.width-full { + width: 100% !important; +} + +top-0 { + top: 0 !important; +} + +.border-bottom { + border-bottom: 1px solid #e1e4e8 !important; +} + +.container-xl { + max-width: 1280px; +} + +.container-lg, +.container-xl { + margin-right: auto; +} + +@media (min-width: 1012px) { + .gutter-lg { + margin-right: -16px; + margin-left: -16px; + } +} + +.gutter-condensed { + margin-right: -8px; + margin-left: -8px; +} + +.flex-shrink-0 { + flex-shrink: 0 !important; +} + +.UnderlineNav { + display: flex; + overflow-x: auto; + overflow-y: hidden; + box-shadow: inset 0 -1px 0 #e1e4e8; + justify-content: space-between; +} + +.UnderlineNav { + justify-content: center !important; +} + +.box-shadow-none { + box-shadow: none !important; +} + +.UnderlineNav-body { + display: flex; +} + +.UnderlineNav-item.selected, +.UnderlineNav-item[aria-current]:not([aria-current='false']), +.UnderlineNav-item[role='tab'][aria-selected='true'] { + font-weight: 600; + border-bottom-color: #f9826c; + outline: 1px dotted transparent; + outline-offset: -1px; +} + +.UnderlineNav-item { + padding: 8px 16px; + font-size: 14px; + line-height: 30px; + color: #1b1f23; + text-align: center; + white-space: nowrap; + background-color: initial; + border: 0; + border-bottom: 2px solid rgba(209, 213, 218, 0); + transition: border-bottom-color 0.36s ease-in; +} + +.UnderlineNav-item:focus, +.UnderlineNav-item:hover { + text-decoration-color: currentcolor; + border-bottom-color: rgb(60, 65, 67); + outline-color: transparent; +} + +.UnderlineNav-item:focus, +.UnderlineNav-item:hover { + text-decoration: none; + text-decoration-color: currentcolor; + border-bottom-color: #d1d5da; + outline: 1px dotted transparent; + outline-color: transparent; + outline-offset: -1px; + transition-timing-function: ease-out; + transition-duration: 0.12s; +} + +a { + color: #0366d6; + text-decoration: none; +} + +.Header, +.Header-item { + display: flex; + align-items: center; + flex-wrap: nowrap; +} + +.Header { + z-index: 32; + padding: 16px; + font-size: 14px; + line-height: 1.5; + color: hsla(0, 0%, 100%, 0.7); + background-color: #24292e; + margin-top: 0 !important; +} + +.Header-item { + margin-right: 16px; + align-self: stretch; +} + +.Header-link { + font-weight: 600; + color: #fff !important; + white-space: nowrap; +} + +@media (min-width: 768px) { + .d-md-none { + display: none !important; + } + + .header-search-current.header-search { + max-width: 272px; + } + + .flex-md-nowrap { + flex-wrap: nowrap !important; + } + + .d-md-flex { + display: flex !important; + } + + .py-md-0 { + padding-top: 0 !important; + padding-bottom: 0 !important; + } + + .flex-md-row { + flex-direction: row !important; + } + + .mr-md-3 { + margin-right: 16px !important; + } + + .col-md-3 { + width: 25%; + } + + .d-md-block { + display: block !important; + } + + .header-search-current.header-search:focus-within { + max-width: 544px; + } + + .header-search-current.header-search { + max-width: 272px !important; + } + + .flex-md-self-auto { + align-self: auto !important; + } + + .mt-md-0 { + margin-top: 0 !important; + } + + .flex-md-order-none { + order: inherit !important; + } + + .py-md-3 { + padding-top: 16px !important; + padding-bottom: 16px !important; + } +} + +@media (min-width: 1012px) { + .px-lg-5 { + padding-right: 32px !important; + } +} + +@media (min-width: 1012px) { + .pl-lg-5, + .px-lg-5 { + padding-left: 32px !important; + } +} + +@media (min-width: 768px) { + .px-md-4 { + padding-right: 24px !important; + } +} + +@media (min-width: 768px) { + .pl-md-4, + .px-md-4 { + padding-left: 24px !important; + } +} + +.Details:not(.Details--on) .Details-content--hidden-not-important { + display: none; +} + +.Header-item--full { + flex: auto; +} + +.header-search-current.header-search { + max-width: 100%; + transition: 0.2s ease-in-out; + transition-property: max-width, padding-bottom, padding-top; +} + +.avatar { + display: inline-block; + overflow: hidden; + line-height: 1; + vertical-align: middle; + border-radius: 6px; +} + +.avatar-user { + border-radius: 50% !important; +} + +img { + border-style: none; +} + +.header-nav-current-user { + padding-bottom: 0; + font-size: inherit; +} + +.dropdown-menu-sw { + right: 0; + left: auto; +} + +.dropdown-menu { + position: absolute; + top: 100%; + left: 0; + z-index: 100; + width: 160px; + padding-top: 4px; + padding-bottom: 4px; + margin-top: 2px; + list-style: none; + background-color: #fff; + background-clip: padding-box; + border: 1px solid #e1e4e8; + border-radius: 6px; + box-shadow: 0 8px 24px rgba(149, 157, 165, 0.2); +} + +.mt-n2 { + margin-top: -8px !important; +} + +.header-nav-current-user .user-profile-link { + color: #24292e; +} + +.dropdown-divider { + display: block; + height: 0; + margin: 8px 0; + border-top: 1px solid #e1e4e8; +} + +.dropdown-menu-sw:before { + top: -16px; + right: 9px; + left: auto; +} + +.dropdown-menu:before { + border: 8px solid transparent; + border-bottom-color: rgba(27, 31, 35, 0.15); +} + +.dropdown-menu:after, +.dropdown-menu:before { + position: absolute; + display: inline-block; + content: ''; +} + +.user-status-container { + word-break: break-word; + word-wrap: break-word; +} + +.rounded-1 { + border-radius: 6px !important; +} + +.d-none { + display: none !important; +} + +.f6 { + font-size: 12px !important; +} + +.text-gray-light { + color: #6a737d !important; +} + +.text-gray-dark { + color: #000 !important; +} + +a { + background-color: initial; +} + +svg:not(:root) { + overflow: hidden; +} + +.v-align-middle { + vertical-align: middle !important; +} + +form { + display: block; + margin-top: 0em; +} + +.header-search-current .header-search-wrapper { + display: table; + width: 100%; + max-width: 100%; + padding: 0; + font-size: inherit; + font-weight: 400; + color: #fff; + vertical-align: middle; + background-color: hsla(0, 0%, 100%, 0.125) !important; + border: 0; + box-shadow: none; +} + +.input-sm { + min-height: 28px; + line-height: 20px; +} + +.position-relative { + position: relative !important; +} + +.flex-items-center { + align-items: center !important; +} + +.flex-justify-between { + justify-content: space-between !important; +} + +.form-control, +.form-select { + padding: 5px 12px; + font-size: 14px; + line-height: 20px; + color: #24292e; + vertical-align: middle; + background-color: #fff; + background-repeat: no-repeat; + background-position: right 8px center; + border: 1px solid #e1e4e8; + border-radius: 6px; + outline: none; + box-shadow: inset 0 1px 0 rgba(225, 228, 232, 0.2); +} + +.octicon-mark-github { + height: 32px; + width: 32px; + fill: #fff !important; +} + +.octicon-plus, +.octicon-bell { + fill: #fff !important; +} + +input { + -webkit-writing-mode: horizontal-tb !important; + writing-mode: horizontal-tb !important; + text-rendering: auto; + color: -internal-light-dark(black, white); + letter-spacing: normal; + word-spacing: normal; + text-transform: none; + text-indent: 0px; + text-shadow: none; + display: inline-block; + text-align: start; + appearance: textfield; + background-color: -internal-light-dark(rgb(255, 255, 255), rgb(59, 59, 59)); + -webkit-rtl-ordering: logical; + cursor: text; + margin: 0em; + font: 400 13.3333px Arial; + padding: 1px 2px; + border-width: 2px; + border-style: inset; + border-color: -internal-light-dark(rgb(118, 118, 118), rgb(195, 195, 195)); + border-image: initial; +} + +#username .octicon { + vertical-align: middle !important; + margin-right: 10px; +} + +.container-lg { + max-width: 1012px; +} + +.container-lg, +.container-xl { + margin-right: auto; + margin-left: auto; +} + +.mt-6 { + margin-top: 40px !important; +} + +.pb-2 { + padding-bottom: 8px !important; +} + +.pt-6 { + padding-top: 40px !important; +} + +.flex-justify-center { + justify-content: center !important; +} + +ol, +ul { + padding-left: 0; + margin-top: 0; + margin-bottom: 0; +} + +ul { + display: block; + list-style-type: disc; + margin-block-start: 1em; + margin-block-end: 1em; + margin-inline-start: 0px; + margin-inline-end: 0px; + padding-inline-start: 40px; +} + +.mr-3 { + margin-right: 16px !important; +} + +li { + display: list-item; + text-align: -webkit-match-parent; +} + +.list-style-none { + list-style: none !important; +} + +.footer-octicon { + color: #c6cbd1; +} + +@media (min-width: 1012px) { + .d-lg-block { + display: block !important; + } +} + +.flex-wrap { + flex-wrap: wrap !important; +} + +.border-top { + border-top: 1px solid #e1e4e8 !important; +} + +.border-gray-light { + border-color: #eaecef !important; +} + +.show-on-focus { + margin: 0; + clip: rect(1px, 1px, 1px, 1px); +} + +.show-on-focus, +.sr-only { + position: absolute; + width: 1px; + height: 1px; + overflow: hidden; +} + +.text-white { + color: #fff !important; +} + +.bg-blue { + background-color: #0366d6 !important; +} + +.progress-pjax-loader { + z-index: 99999; + height: 2px; + background: transparent; + opacity: 0; + transition: opacity 0.4s linear 0.4s; +} + +.Progress { + display: flex; + height: 8px; + overflow: hidden; + background-color: #e1e4e8; + border-radius: 6px; + outline: 1px solid transparent; +} + +.position-fixed { + position: fixed !important; +} + +.p-0 { + padding: 0 !important; +} + +.notification-indicator .mail-status { + position: absolute; + top: -6px; + left: 6px; + z-index: 2; + display: none; + width: 14px; + height: 14px; + color: #fff; + background-image: linear-gradient(#54a3ff, #006eed); + background-clip: padding-box; + border: 2px solid #24292e; + border-radius: 50%; +} + +.notification-indicator .mail-status.unread { + display: inline-block; +} + +.Box .section-focus .edit-section, +[data-catalyst], +auto-complete, +details-dialog, +details-menu, +file-attachment, +filter-input, +image-crop, +in-viewport, +include-fragment, +poll-include-fragment, +remote-input, +tab-container, +text-expander { + display: block; +} + +article, +aside, +details, +figcaption, +figure, +footer, +header, +main, +menu, +nav, +section { + display: block; +} + +.details-reset > summary { + list-style: none; +} + +details summary { + cursor: pointer; +} + +summary { + display: list-item; +} + +.dropdown-caret { + display: inline-block; + width: 0; + height: 0; + vertical-align: middle; + content: ''; + border-top-style: solid; + border-top-width: 4px; + border-right: 4px solid transparent; + border-bottom: 0 solid transparent; + border-left: 4px solid transparent; +} + +details:not([open]) > :not(summary) { + display: none !important; +} + +.mt-n2 { + margin-top: -8px !important; +} + +.dropdown-item { + display: block; + padding: 4px 8px 4px 16px; + overflow: hidden; + color: #24292e; + text-overflow: ellipsis; + white-space: nowrap; +} + +.mr-0 { + margin-right: 0 !important; +} + +.px-3 { + padding-right: 16px !important; +} + +.pl-3, +.px-3 { + padding-left: 16px !important; +} + +.p-3 { + padding: 16px !important; +} + +.d-block { + display: block !important; +} + +.header-nav-current-user .css-truncate-target { + max-width: 100%; +} + +.css-truncate.css-truncate-overflow, +.css-truncate .css-truncate-overflow, +.css-truncate.css-truncate-target, +.css-truncate .css-truncate-target { + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} + +b, +strong { + font-weight: 600; +} + +.user-status-container, +.user-status-container .team-mention, +.user-status-container .user-mention { + white-space: normal !important; +} + +details:not([open]) > :not(summary) { + display: none !important; +} + +.dropdown-menu-sw { + right: 0; + left: auto; +} + +.dropdown-item.btn-link, +.dropdown-signout { + width: 100%; + text-align: left; +} + +.feature-preview-details .feature-preview-indicator { + top: 9px; + right: 10px; + left: inherit; + width: 10px; + height: 10px; + border: 0; +} + +.feature-preview-indicator { + position: absolute; + top: 0; + left: 13px; + z-index: 2; + width: 14px; + height: 14px; + color: #fff; + background-image: linear-gradient(#54a3ff, #006eed); + background-clip: padding-box; + border: 2px solid #24292e; + border-radius: 50%; +} + +.btn-link { + display: inline-block; + padding: 0; + font-size: inherit; + color: #0366d6; + text-decoration: none; + white-space: nowrap; + cursor: pointer; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + background-color: initial; + border: 0; + -webkit-appearance: none; + -moz-appearance: none; + appearance: none; +} + +.header-search-current .header-search-input { + display: table-cell; + width: 100%; + padding-top: 0; + padding-bottom: 0; + font-size: inherit; + color: inherit; + background: none; + border: 0; + box-shadow: none; +} + +#display-none-before::before { + content: none !important; +} + +#repo-name { + text-align: center; + font-size: 20px !important; +} + +.avatar-user { + border-radius: 50% !important; +} + +.message-title:last-of-type { + border-bottom: 1px solid #e1e4e8; +} + +.Counter { + display: inline-block; + min-width: 20px; + padding: 0 6px; + font-size: 12px; + font-weight: 500; + line-height: 18px; + color: #24292e; + text-align: center; + background-color: rgba(209, 213, 218, 0.5); + border: 1px solid transparent; + border-radius: 2em; +} diff --git a/styles.css b/ChromeExtension/styles/styles.css similarity index 55% rename from styles.css rename to ChromeExtension/styles/styles.css index 0231817..6898b36 100644 --- a/styles.css +++ b/ChromeExtension/styles/styles.css @@ -1,3 +1,7 @@ +.display-none { + display: none !important; +} + /** Progress bar styles **/ .container { width: 100% !important; @@ -35,13 +39,13 @@ text-align: center; margin: 0 auto 10px auto; border-radius: 50%; - background-color: white; + background-color: #ffffff; } .progressbar li:after { width: 100%; height: 2px; - content: ''; + content: ""; position: absolute; background-color: #b8b8b8; top: 15px; @@ -49,6 +53,11 @@ z-index: -1; } +.progressbar .dark-mode-step:before { + background-color: hsla(212, 12%, 18%, 1); + color: #ffffff !important; +} + .progressbar li:first-child { margin-left: 0; } @@ -58,31 +67,41 @@ } .progressbar li.partial { - color: #c4c400; - font-weight: bold; + color: var(--color-text-primary); font-size: 16px; + text-transform: capitalize; } -.progressbar li.partial:before { - border-color: #ffeeba; +.progressbar li.partial:before, +.dark-mode-step:before { + color: var(--color-alert-warn-text); + background-color: rgb(13, 110, 253); + border-color: rgb(13, 110, 253); + color: #000 !important; } .progressbar li.completed:before { - content: '\2713' !important; - background-color: #d4edda !important; - border-color: #55b776; + content: "\2713" !important; + color: #000 !important; + background-color: var(--color-checks-donut-success) !important; + border-color: var(--color-checks-donut-success); } .progressbar li.completed { font-size: 12px !important; - color: green; + color: var(--color-text-primary); + text-transform: capitalize; } .progressbar li.completed + li:after { - background-color: #55b776; + background-color: var(--color-checks-donut-success); } /** Override GitHub styles **/ +.overflow-visible { + overflow: visible !important; +} + .commit-form .input-block { width: 60% !important; display: inline-block !important; @@ -96,6 +115,14 @@ z-index: -1; } +.toggleBtn { + z-index: 999; +} + +.UnderlineNav { + justify-content: center !important; +} + /** Icon tooltip styles **/ .helpIcon { position: relative; @@ -113,7 +140,6 @@ border-radius: 6px; padding: 5px; font-size: 14px !important; - /* Position the tooltip */ position: absolute; z-index: 10; bottom: 150%; @@ -121,6 +147,17 @@ margin-left: -60px; } +.darkmode-icon .helpIconCircle, +.darkmode-icon .helpIconText { + color: var(--color-btn-text) !important; + background: rgb(13, 110, 253) !important; + border-color: rgb(13, 110, 253) !important; +} + +.darkmode-icon .helpIconText:before { + border-top: 5px solid rgb(13, 110, 253) !important; +} + .helpIcon:hover .helpIconText { visibility: visible; } @@ -130,7 +167,7 @@ } .helpIconText:before { - content: ''; + content: ""; display: block; width: 0; height: 0; @@ -146,83 +183,55 @@ background: rgba(0, 0, 0, 0.3); padding: 5px 12px; border-radius: 50px; - font-size: 20px; + font-size: 15px; text-decoration: none; color: white; } -/** Success Message Styles **/ -.successRibbon { - width: 100%; - color: #155724; - background-color: #d4edda; - border-color: #c3e6cb; - padding: 0.75rem 1.25rem; - margin-bottom: 1rem; - height: 50px; +.closeButton { + background: none !important; + color: black; } -/** Profile card styles **/ -.front, -.back { - box-sizing: border-box; - padding: 2rem; - border-radius: 4px; - box-shadow: 0 1rem 2rem rgba(0, 0, 0, 0.25); - - font-family: BlinkMacSystemFont, 'Segoe UI', sans-serif; - font-size: 2rem; - color: #fff; - text-transform: uppercase; - text-align: center; -} - -.front, -.back { - position: absolute; - top: 0; - left: 0; - backface-visibility: hidden; - transition: transform 0.8s ease; -} -.back { - transform: rotateY(180deg); - width: 100%; - height: fit-content; - z-index: 997; - display: block; +.closeButton:hover { + border: 1px solid black; } -.card-container:hover .front { - transform: rotateY(-180deg); -} - -.back.hovered { - -webkit-transform: rotate(360deg); - -moz-transform: rotate(360deg); - -o-transform: rotate(360deg); - transform: rotate(360deg); - background-color: #fff; +.label-margin-right { + display: inline-block; + margin-right: 20px; } -.hidden { - visibility: hidden; +/** Success Message Styles **/ +.successRibbon { + width: 100%; + color: #000; + background-color: var(--color-checks-donut-success); + border-color: var(--color-checks-donut-success); + padding: 0.75rem 1.25rem; + margin-bottom: 1rem; + height: 50px; } -.card-container { - perspective: 75rem; +/* New Navbar option styles */ +#houseImage { + width: 16px; + height: 16px; + opacity: 0.5; + margin-right: 6px; } -.graph { - width: 50% !important; - height: 50% !important; - padding: 20px; +#homePage, +#codeLink { + color: var(--color-underlinenav-text) !important; } -.graph-tooltip { - cursor: pointer; +.selected { + color: var(--color-underlinenav-text-active) !important; + border-bottom-color: #f9826c !important; } -.hiddenDisplay { - display: none; +.repoNavButton { + border-bottom-color: none !important; + color: var(--color-underlinenav-text) !important; } diff --git a/README.md b/README.md index 88275bb..4a765cd 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,6 @@ # ResearchPlugin + Chrome extension to add tooltips on GitHub pages when creating pull requests, or creating an issue repoort in any repository to help newcomers contribute to open source projects. -This extension is written in Javascript, and uses the GitHub API to mine data about a user in JSON format to display the user's skill set on their profile page. \ No newline at end of file +This extension is written in Javascript, and uses the GitHub API to mine data about a user in JSON format to display the user's skill set on their profile page. + diff --git a/ResearchPlugin.zip b/ResearchPlugin.zip new file mode 100644 index 0000000..d6c2b14 Binary files /dev/null and b/ResearchPlugin.zip differ diff --git a/background.js b/background.js deleted file mode 100644 index e9ddcfb..0000000 --- a/background.js +++ /dev/null @@ -1,11 +0,0 @@ -chrome.storage.onChanged.addListener(function(changes, areaName){ - chrome.storage.local.get('iconStatus', function(status){ - let iconStatus = status.iconStatus; - - if(iconStatus) { - document.getElementById('iconBtn').checked = true; - } else { - document.getElementById('iconBtn').checked = false; - } - }); -}); \ No newline at end of file diff --git a/content.js b/content.js deleted file mode 100644 index 6167e59..0000000 --- a/content.js +++ /dev/null @@ -1,1009 +0,0 @@ -const NOT_FOUND = -1; - -class ToolTipIcon { - constructor(toolTipElement, toolTipClass, toolTipText, gitHubElement) { - this.toolTipElement = toolTipElement; - this.toolTipClass = toolTipClass; - this.toolTipText = toolTipText; - this.gitHubElement = gitHubElement; - } - - createIcon() { - const toolTipContainer = document.createElement('div'); - toolTipContainer.className = this.toolTipClass; - - const circleIcon = document.createElement('span'); - circleIcon.className = 'helpIconCircle'; - circleIcon.innerHTML = '?'; - - const toolTip = document.createElement('span'); - toolTip.className = 'helpIconText'; - toolTip.innerHTML = this.toolTipText; - - toolTipContainer.appendChild(circleIcon); - toolTipContainer.appendChild(toolTip); - - this.toolTipElement = toolTipContainer; - } -} - -/** - * Function name: checkURL - * Checks the windows current URL for keywords to determine which tooltips - * to display - */ -function checkURL() { - // check if the user wants to edit a file that they are not an owner of - if (checkIsEditingForkedFile()) { - addForkToolTips(); - } - // if the user is editing a markdown file - else if ( - window.location.href.indexOf('.md') !== NOT_FOUND && - window.location.href.indexOf('edit') !== NOT_FOUND - ) { - addReadMeToolTips(); - } - // if the user is reviewing a pull request - else if (window.location.href.indexOf('compare') !== NOT_FOUND) { - addProposeChangesToolTips(); - } else if ( - window.location.href.indexOf('pull') !== NOT_FOUND && - window.location.href.indexOf('quick_pull') === NOT_FOUND - ) { - addReviewPullRequestTips(); - } - // if the user is opening a pull request - else if (document.getElementsByClassName('h-card').length !== 0) { - createProfileCard(); - } - // if the user is creating a new issue - else if ( - window.location.href.indexOf('issues') !== NOT_FOUND && - window.location.href.indexOf('new') !== NOT_FOUND - ) { - addReportIssueTips(); - } else if ( - window.location.href.indexOf('issues') !== NOT_FOUND && - window.location.href.indexOf('new') === NOT_FOUND - ) { - addReviewIssueTips(); - } else { - // do nothing - } -} - -checkURL(); - -/** - * Function name: checkIsEditingForkedFile - * Checks if the user is viewing a file that they do not own - */ -function checkIsEditingForkedFile() { - try { - // check if there is a pencil icon with this aria label - return ( - document.getElementsByClassName('tooltipped')[2].getAttribute('aria-label') === - 'Edit the file in your fork of this project' - ); - } catch (error) { - return false; - } -} - -/** - * Function name: addProgressBar - * Adds progressBar above forms in GitHub pages to let user how far they are - * in editing files - * @param currentStep current step in process - * @param totalSteps the amount of steps in process to determine overall progress - * @param rootElement className of GitHub HTML element that the progress bar - * will be added to - */ -function addProgressBar(currentStep, totalSteps, rootElement, stepsList) { - // create the progress bar element - const progressBarContainer = document.createElement('div'); - progressBarContainer.className = 'container'; - - const progressBar = document.createElement('div'); - progressBar.className = 'progressbar'; - - const itemList = document.createElement('ul'); - - let index = 1; - - for (index = 1; index <= stepsList.length; index += 1) { - const listItem = document.createElement('li'); - listItem.innerHTML = stepsList[index - 1]; - - if (currentStep === totalSteps) { - listItem.className = 'completed'; - } else if (index === currentStep) { - listItem.className = 'partial'; - } - // if the user has already completed a step - else if (index < currentStep) { - listItem.className = 'partial completed'; - } - itemList.appendChild(listItem); - } - - progressBar.appendChild(itemList); - - progressBarContainer.appendChild(progressBar); - - $(progressBarContainer).insertBefore(rootElement); - - if (isProcessCompleted()) { - createSuccessRibbon(); - } -} - -/** - * Function name: isComplete - * Checks if issue/ pull request was succesfully created and is open in the repo - */ -function isProcessCompleted() { - let status = ''; - try { - status = document.getElementsByClassName('State')[0].getAttribute('title'); - } catch (error) { - return false; - } - return status === 'Status: Open'; -} - -/** - * Function name: createSuccessRibbon - * Creates ribbon above progress bar to inform the user that the process is successful - */ -function createSuccessRibbon() { - let processType = ''; - - if (window.location.href.indexOf('issues') != NOT_FOUND) { - processType = 'issue'; - } else { - processType = 'pull request'; - } - - const successRibbonContainer = document.createElement('div'); - successRibbonContainer.className = 'successRibbon'; - - const ribbonMessage = document.createTextNode( - `The ${processType} was created successfully and will be reviewed shortly` - ); - - successRibbonContainer.appendChild(ribbonMessage); - - $(successRibbonContainer).insertBefore('.container'); -} - -/** - * Function name: addReadMeToolTips - * Adds tooltips to webpage when editing markdown files - * First step in editing markdown files - */ -function addReadMeToolTips() { - const steps = ['Edit File', 'Confirm Pull Request', 'Pull Request Opened']; - - // progress bar above editor - addProgressBar(1, 3, '.js-blob-form', steps); - - // icon to right of file name input - const fileNameChangeText = - 'This is the file name, changing it will create a new file with the new name'; - - const breadCrumbDiv = '.d-md-inline-block'; - - const fileNameChangeIcon = new ToolTipIcon('H4', 'helpIcon', fileNameChangeText, breadCrumbDiv); - - fileNameChangeIcon.createIcon(); - - $(fileNameChangeIcon.toolTipElement).insertAfter(fileNameChangeIcon.gitHubElement); - - // banner above commit message input - const commitTitleText = - 'This is the title. Give a brief description of the change. Be short and objective.'; - - const inputTitleLabel = document.createElement('h3'); - inputTitleLabel.innerHTML = 'Insert a title here'; - inputTitleLabel.style.display = 'inline-block'; - inputTitleLabel.style.marginRight = '20px'; - - $(inputTitleLabel).insertBefore('#commit-summary-input'); - - const commitMessageIcon = new ToolTipIcon( - 'H4', - 'helpIcon', - commitTitleText, - '#commit-summary-input' - ); - - commitMessageIcon.createIcon(); - - $(commitMessageIcon.toolTipElement).insertAfter('#commit-summary-input'); - - const descriptionText = - 'Add a more detailed description if needed. Here you can present your arguments and reasoning that lead to change.'; - - const inputDescriptionLabel = document.createElement('h3'); - inputDescriptionLabel.innerHTML = 'Insert a
description here'; - inputDescriptionLabel.style.display = 'inline-block'; - inputDescriptionLabel.style.marginRight = '22px'; - - $(inputDescriptionLabel).insertBefore('#commit-description-textarea'); - - const extendedDescIcon = new ToolTipIcon( - 'H4', - 'helpIcon', - descriptionText, - '#commit-description-textarea' - ); - - extendedDescIcon.createIcon(); - - $(extendedDescIcon.toolTipElement).insertAfter(extendedDescIcon.gitHubElement); - - const commitChangesDirectlyText = - 'By clicking the Commit Changes button the changes will automatically be pushed to the repo'; - - const submitChangesIcon = new ToolTipIcon( - 'H4', - 'helpIcon', - commitChangesDirectlyText, - '#submit-file' - ); - - submitChangesIcon.createIcon(); - - submitChangesIcon.toolTipElement.style.marginRight = '20px'; - - $(submitChangesIcon.toolTipElement).insertBefore(submitChangesIcon.gitHubElement); -} - -// On pull request step 1, toggle icon text to help inform user -let onDirectPull = true; -let iconText = ''; - -const pullChangesText = - 'By clicking the Propose changes button you will start the submission process. You will have the chance to check your changes before finalizing it.'; - -$('input[name="commit-choice"]').click(() => { - document.getElementsByClassName('helpIcon')[3].remove(); - - if (onDirectPull) { - iconText = pullChangesText; - onDirectPull = false; - } else { - iconText = - 'By clicking the Commit Changes button the changes will be directly pushed to the repo'; - onDirectPull = true; - } - - const submitChangesIcon = new ToolTipIcon('H4', 'helpIcon', iconText, '#submit-file'); - - submitChangesIcon.createIcon(); - - submitChangesIcon.toolTipElement.style.marginRight = '20px'; - - $(submitChangesIcon.toolTipElement).insertBefore(submitChangesIcon.gitHubElement); -}); - -/** - * Function name: addProposeChangesToolTips - * Adds tooltips to webpage when confirming a change to file - * Second step in editing markdown files - */ -function addProposeChangesToolTips() { - const steps = ['Edit File', 'Create Pull Request', 'Pull Request Opened']; - - addProgressBar(2, 3, '.repository-content', steps); - - $('#pull_request_body').attr( - 'placeholder', - 'You can add a more detailed description here if needed.' - ); - - try { - var branchName = document.getElementsByClassName('branch-name')[0].innerText; - } catch { - var isComparingBranch = true; - } - - let newHeaderText = `Finish the pull request submission below to allow others to accept the changes. These changes can be viewed later under the branch name: ' + - ${branchName}`; - - if (isComparingBranch) { - newHeaderText = - 'Finish the pull request submission below to allow others to accept the changes'; - - $('.gh-header-title').text('Create Pull Request'); - } - - $('.gh-header-meta').text(newHeaderText); - - let pullRequestTitle = document.getElementsByClassName('gh-header-title')[1]; - pullRequestTitle.innerHTML = 'Create pull request'; - - const branchContainerText = - 'This represents the origin and destination of your changes if you are not sure, leave it how it is, this is common for small changes.'; - - const topRibbon = document.getElementsByClassName('js-range-editor')[0]; - topRibbon.style.width = '93%'; - topRibbon.style.display = 'inline-block'; - - // ribbon above current current branch and new pull request branch - const currentBranchIcon = new ToolTipIcon( - 'H4', - 'helpIcon', - branchContainerText, - '.js-range-editor' - ); - - currentBranchIcon.createIcon(); - - $(currentBranchIcon.toolTipElement).insertAfter(currentBranchIcon.gitHubElement); - - // move button row to left side of editor - const buttonRow = document.getElementsByClassName('d-flex flex-justify-end m-2')[0]; - buttonRow.classList.remove('flex-justify-end'); - buttonRow.classList.add('flex-justify-start'); - - const confirmPullRequestText = - 'By clicking this button you will create the pull request to allow others to view your changes and accept them into the repository.'; - - const submitButtonClass = '.js-pull-request-button'; - - // icon next to create pull request button - const createPullRequestBtn = new ToolTipIcon( - 'H4', - 'helpIcon', - confirmPullRequestText, - submitButtonClass - ); - - createPullRequestBtn.createIcon(); - - $(createPullRequestBtn.toolTipElement).insertAfter(createPullRequestBtn.gitHubElement); - - const summaryText = - 'This shows the amount of commits in the pull request, the amount of files you changed in the pull request, how many comments were on the commits for the pull request and the ammount of people who worked together on this pull request.'; - - const summaryClass = '.overall-summary'; - - // override the container width and display to add icon - const numbersSummaryContainer = document.getElementsByClassName('overall-summary')[0]; - numbersSummaryContainer.style.width = '93%'; - numbersSummaryContainer.style.display = 'inline-block'; - - // icon above summary of changes and commits - const requestSummaryIcon = new ToolTipIcon('H4', 'helpIcon', summaryText, summaryClass); - - requestSummaryIcon.createIcon(); - - requestSummaryIcon.toolTipElement.style = 'float:right;'; - - $(requestSummaryIcon.toolTipElement).insertAfter(requestSummaryIcon.gitHubElement); - - const comparisonClass = '.details-collapse'; - - const changesText = - 'This shows the changes between the orginal file and your version. Green(+) represents lines added. Red(-) represents removed lines'; - - // icon above container for changes in current pull request - const comparisonIcon = new ToolTipIcon('H4', 'helpIcon', changesText, comparisonClass); - - comparisonIcon.createIcon(); - - const commitSummaryContainer = document.getElementsByClassName('details-collapse')[0]; - - commitSummaryContainer.style.width = '93%'; - commitSummaryContainer.style.display = 'inline-block'; - - $(comparisonIcon.toolTipElement).insertAfter(comparisonIcon.gitHubElement); -} - -/** - * Function name: addReviewPullRequestTips - * Adds tooltips to webpage when reviewing pull requests - * Third step in editing markdown files - */ -function addReviewPullRequestTips() { - const steps = ['Edit File', 'Confirm Pull Request', 'Pull Request Opened']; - - addProgressBar(3, 3, '.gh-header-show', steps); - - const titleTest = 'new'; // document.getElementsByClassName('js-issue-title')[0]; - - const branchContainerText = - 'This indicates that the pull request is open meaning someone will get to it soon.'; - - const pullRequestStatusIcon = new ToolTipIcon( - 'H4', - 'helpIcon', - branchContainerText, - '.js-clipboard-copy' - ); - - pullRequestStatusIcon.createIcon(); - - $(pullRequestStatusIcon.toolTipElement).insertAfter(pullRequestStatusIcon.gitHubElement); - - const requestButtonsText = - 'This will close the pull request meaning people cannot view this! Do not click close unless the request was solved.'; - - const requestButtonsClass = '.js-comment-and-button'; - - const closePullRequestIcon = new ToolTipIcon( - 'H4', - 'helpIcon', - requestButtonsText, - requestButtonsClass - ); - - closePullRequestIcon.createIcon(); - - $(closePullRequestIcon.toolTipElement).insertBefore(closePullRequestIcon.gitHubElement); - - closePullRequestIcon.toolTipElement.style.marginRight = '20px'; - - /* - var submitButtons = document.getElementsByClassName('d-flex flex-justify-end')[0]; - submitButtons.classList.remove('flex-justify-end'); - submitButtons.classList.add('flex-justify-start');*/ - - $('.js-quick-submit-alternative').click((event) => { - if (!Confirm(`Are you sure that you want to close the pull request: ${titleTest}?`)) { - event.preventDefault(); - } - }); -} - -/** - * Function name: addForkToolTips - * Edits tooltips when viewing a repository that you are not a contributor of - */ -function addForkToolTips() { - $('.tooltipped-nw:nth-child(2)').attr('aria-label', 'Edit Readme'); -} - -/** - * Function name: addIssueTips - * Adds tolltips to page when opening a new issue report - */ -function addReportIssueTips() { - const steps = ['Report Issue', 'confirm Issue Report', 'Issue Submitted']; - - // progress bar above editor - addProgressBar(1, 3, '.new_issue', steps); - - const submitButtonText = 'After clicking this, you will have a chance to update the issue report'; - - const submitButtonClass = '.flex-justify-end button:eq(0)'; - - const submitButtonIcon = new ToolTipIcon('H4', 'helpIcon', submitButtonText, submitButtonClass); - - submitButtonIcon.createIcon(); - - $(submitButtonIcon.toolTipElement).insertAfter(submitButtonIcon.gitHubElement); -} - -/** - * Function name: addIssueTips - * Adds tolltips to page when reviewing a new issue report - */ -function addReviewIssueTips() { - const issueTitle = document.getElementsByClassName('js-issue-title')[0].innerText; - - const steps = ['Report Issue', 'confirm Issue Report', 'Issue Submitted']; - - addProgressBar(3, 3, '.repository-content', steps); - - const buttonRow = document.getElementsByClassName('d-flex flex-justify-end')[0]; - buttonRow.classList.remove('flex-justify-end'); - buttonRow.classList.add('flex-justify-start'); - - const closeIssueIconText = - 'This will close the issue request meaning people cannot view this! Do not click close unless the request was solved. '; - - const submitButtonClass = '.flex-justify-end button:eq(0)'; - - const submitButtonIcon = new ToolTipIcon('H4', 'helpIcon', closeIssueIconText, submitButtonClass); - - submitButtonIcon.createIcon(); - - submitButtonIcon.toolTipElement.style.marginRight = '20px'; - - $(submitButtonIcon.toolTipElement).insertBefore(submitButtonIcon.gitHubElement); - - $('.js-quick-submit-alternative').click(function (event) { - if (!confirm(`Are you sure that you want to close the issue: ${issueTitle}?`)) { - event.preventDefault(); - } - }); -} - -/** - * function getCommits - * @param string username - GitHub username for API - * Uses GitHub API to view commit totals for user - */ -async function getCommits(repositories, username) { - const oAuthToken = ''; - - let repoObject = {}; - let ctx = document.getElementById('repositories'); - let skillGraphContainer = document.getElementById('skillGraph'); - const barColors = []; - - const headers = { - Authorization: 'Token ' + oAuthToken, - }; - - for (const repo of repositories) { - const commitUrl = `https://api.github.com/repos/${username}/${repo}/commits?page=1&per_page=25`; - - const commitResponse = await fetch(commitUrl, { - method: 'GET', - headers: headers, - }); - - let commitResult = await commitResponse.json(); - repoObject[repo] = commitResult.length; - - barColors.push(getRandomColor()); - } - - const labels = Object.keys(repoObject); - const data = Object.values(repoObject); - - labels.sort((a, b) => { - return repoObject[b] - repoObject[a]; - }); - - data.sort((a, b) => { - return b - a; - }); - - myBarChart = new Chart(skillGraphContainer, { - type: 'bar', - data: { - labels: labels, - datasets: [ - { - label: 'Commits', - backgroundColor: barColors, - data: data, - }, - ], - }, - options: { - responsive: false, - legend: { display: false }, - title: { - display: true, - text: `Commits per repository for: ${username}`, - }, - scales: { - yAxes: [ - { - ticks: { - beginAtZero: true, - max: 30, - stepSize: 1, - }, - }, - ], - xAxes: [ - { - ticks: { - fontSize: 8, - callback: function (value) { - if (value.length > 4) { - return value.substr(0, 4) + '...'; //truncate - } else { - return value; - } - }, - }, - }, - ], - }, - animation: { - duration: 1, - onProgress: function () { - var chartInstance = this.chart, - ctx = chartInstance.ctx; - - ctx.font = Chart.helpers.fontString( - Chart.defaults.global.defaultFontSize, - Chart.defaults.global.defaultFontStyle, - Chart.defaults.global.defaultFontFamily - ); - ctx.textAlign = 'center'; - ctx.textBaseline = 'bottom'; - - this.data.datasets.forEach(function (dataset, i) { - var meta = chartInstance.controller.getDatasetMeta(i); - meta.data.forEach(function (bar, index) { - if (dataset.data[index] > 0) { - var data = dataset.data[index]; - ctx.fillText(data, bar._model.x, bar._model.y); - } - }); - }); - }, - }, - }, - }); -} - -/** - * function getRepos - * @param string username - GitHub username for API - * Uses GitHub API to view programming languages for user - */ -async function getRepos(username) { - const oAuthToken = ''; - - const url = `https://api.github.com/users/${username}/repos`; - const response = await fetch(url, { - method: 'GET', - headers: { - Authorization: `Token ${oAuthToken}`, - }, - }); - - const result = await response.json(); - - const languages = []; - const repositoryNames = []; - let labels = {}; - let dataSet = {}; - const barColors = []; - result.forEach((index) => { - if (index.language != null) { - languages.push(index.language); - repositoryNames.push(index.name); - - barColors.push(getRandomColor()); - } - }); - - getCommits(repositoryNames, username); - - const repoGraphContainer = document.getElementById('myChart'); - - const repositoriesObject = {}; - - for (let index = 0; index < languages.length; index += 1) { - if (!repositoriesObject[languages[index]]) { - repositoriesObject[languages[index]] = 0; - } - repositoriesObject[languages[index]] += 1; - } - - labels = Object.keys(repositoriesObject); - dataSet = Object.values(repositoriesObject); - - // use b - a for desc order and a - b for asc order - labels.sort((a, b) => { - return repositoriesObject[b] - repositoriesObject[a]; - }); - - dataSet.sort((a, b) => { - return b - a; - }); - - myBarChart = new Chart(repoGraphContainer, { - type: 'bar', - data: { - labels: labels, - datasets: [ - { - label: 'Repositories', - backgroundColor: barColors, - data: dataSet, - }, - ], - }, - options: { - responsive: false, - legend: { display: false }, - title: { - display: true, - text: `Programming languge totals for ${username}'s repositories`, - }, - scales: { - yAxes: [ - { - ticks: { - beginAtZero: true, - stepSize: 1, - }, - }, - ], - }, - animation: { - duration: 1, - onProgress: function () { - var chartInstance = this.chart, - ctx = chartInstance.ctx; - - ctx.font = Chart.helpers.fontString( - Chart.defaults.global.defaultFontSize, - Chart.defaults.global.defaultFontStyle, - Chart.defaults.global.defaultFontFamily - ); - ctx.textAlign = 'center'; - ctx.textBaseline = 'bottom'; - - this.data.datasets.forEach(function (dataset, i) { - var meta = chartInstance.controller.getDatasetMeta(i); - meta.data.forEach(function (bar, index) { - if (dataset.data[index] > 0) { - var data = dataset.data[index]; - ctx.fillText(data, bar._model.x, bar._model.y); - } - }); - }); - }, - }, - }, - }); -} - -/** - * Function: createCardContainer - * Creates structure of profile overview - */ -function createCardContainer() { - const outerContainer = document.getElementsByClassName('graph-before-activity-overview')[0]; - - outerContainer.className += ' card-container'; - - const cardBack = document.createElement('div'); - cardBack.className = 'back'; - - const repoGraph = document.createElement('canvas'); - repoGraph.className = 'graph'; - repoGraph.style.borderRight = '1px solid black'; - repoGraph.style.borderBottom = '1px solid black'; - repoGraph.style.float = 'left'; - repoGraph.id = 'myChart'; - - const skillGraph = document.createElement('canvas'); - skillGraph.className = 'graph'; - skillGraph.style.borderBottom = '1px solid black'; - skillGraph.id = 'skillGraph'; - skillGraph.style.float = 'right'; - - const commitsGraph = document.createElement('canvas'); - commitsGraph.className = 'graph'; - commitsGraph.style.borderRight = '1px solid black'; - commitsGraph.style.float = 'left'; - commitsGraph.id = 'commitsGraph'; - - const languagesGraph = document.createElement('canvas'); - languagesGraph.className = 'graph'; - languagesGraph.id = 'languagesGraph'; - languagesGraph.style.float = 'right'; - - cardBack.appendChild(repoGraph); - cardBack.appendChild(skillGraph); - cardBack.appendChild(commitsGraph); - cardBack.appendChild(languagesGraph); - - outerContainer.appendChild(cardBack); -} - -/** - * Function name: createProfileCard - * Creates a 2x2 grid behind contribution graph on profile page with graphs - */ -function createProfileCard() { - const profileCardIconText = 'Click this tooltip to show more info about the user'; - const contributionGraphClass = '.js-calendar-graph'; - - const showGraphIcon = new ToolTipIcon( - 'H4', - 'helpIcon graph-tooltip', - profileCardIconText, - contributionGraphClass - ); - - const username = document.getElementsByClassName('vcard-username')[0].innerHTML; - - createCardContainer(); - - getRepos(username); - - getApis(username); - - showGraphIcon.createIcon(); - - $(showGraphIcon.toolTipElement).insertBefore(showGraphIcon.gitHubElement); - - $('.helpIcon').click(() => { - if ($('.helpIconCircle').text() === '?') { - $('.helpIconCircle').text('X'); - $('.helpIconText').addClass('removeText'); - } else { - $('.helpIconCircle').text('?'); - $('.helpIconText').removeClass('removeText'); - } - $('.back').toggleClass('hovered'); - $('#js-contribution-activity').toggleClass('hidden'); - $('#user-activity-overview').toggleClass('hidden'); - }); -} - -function getApis(username) { - const url = chrome.runtime.getURL('result.json'); - - fetch(url) - .then((response) => response.json()) // assuming file contains json - .then((json) => createApiGraph(json, username)); -} - -const colors = [ - '#3e95cd', - '#8e5ea2', - '#3cba9f', - '#e8c3b9', - '#c45850', - '#3e95cd', - '#8e5ea2', - '#3cba9f', - '#e8c3b9', - '#c45850', - '#3e95cd', - '#8e5ea2', - '#3cba9f', - '#e8c3b9', - '#c45850', -]; - -function manageProgressBar() { - $('.progressbar').toggleClass('hiddenDisplay'); -} - -function manageIcons() { - $('.helpIcon').toggleClass('hiddenDisplay'); - - /* - chrome.storage.local.get('iconStatus', function(status) { - let iconStatus = status.iconStatus; - - if(iconStatus) { - document.getElementById('iconBtn').checked = true; - } else { - document.getElementById('iconBtn').checked = false; - } - }); -*/ -} - -function manageRibbon() { - $('.successRibbon').toggleClass('hiddenDisplay'); -} - -chrome.runtime.onMessage.addListener((request, sender, sendResponse) => { - if (request.message === 'progress_bar') { - manageProgressBar(); - } else if (request.message === 'icon') { - manageIcons(); - } else if (request.message === 'ribbon') { - manageRibbon(); - } -}); - -/** - * Function name: createApiGraph - * @param {JSON} userData - * creates graph on user profile card about langauges and apis - */ -function createApiGraph(userData, username) { - const apiGraphContainer = document.getElementById('commitsGraph'); - - const apis = []; - const apiTotals = []; - - const languages = []; - - let total = 0; - - userData.Repos.forEach((index) => { - index.API.apis.forEach((api) => { - if (total < 10) { - apis.push(api.name); - apiTotals.push(api.count); - total += 1; - } - }); - - index.API.langs.forEach((language) => { - languages.push(language); - }); - }); - - myBarChart = new Chart(apiGraphContainer, { - type: 'bar', - data: { - labels: apis, - datasets: [ - { - label: 'Total: ', - backgroundColor: colors, - data: apiTotals, - }, - ], - }, - options: { - responsive: false, - legend: { display: false }, - title: { - display: true, - text: `Api Totals for ${username}`, - }, - scales: { - yAxes: [ - { - ticks: { - beginAtZero: true, - stepSize: 1, - }, - }, - ], - xAxes: [ - { - ticks: { - fontSize: 8, - callback: function (value) { - if (value.length > 4) { - return value.substr(0, 4) + '...'; //truncate - } else { - return value; - } - }, - }, - }, - ], - }, - animation: { - duration: 1, - onProgress: function () { - var chartInstance = this.chart, - ctx = chartInstance.ctx; - - ctx.font = Chart.helpers.fontString( - Chart.defaults.global.defaultFontSize, - Chart.defaults.global.defaultFontStyle, - Chart.defaults.global.defaultFontFamily - ); - ctx.textAlign = 'center'; - ctx.textBaseline = 'bottom'; - - this.data.datasets.forEach(function (dataset, i) { - var meta = chartInstance.controller.getDatasetMeta(i); - meta.data.forEach(function (bar, index) { - if (dataset.data[index] > 0) { - var data = dataset.data[index]; - ctx.fillText(data, bar._model.x, bar._model.y); - } - }); - }); - }, - }, - }, - }); -} - -function getRandomColor() { - var letters = '0123456789ABCDEF'.split(''); - var color = '#'; - for (var i = 0; i < 6; i++) { - color += letters[Math.floor(Math.random() * 16)]; - } - return color; -} diff --git a/index.html b/index.html deleted file mode 100644 index 67bcb79..0000000 --- a/index.html +++ /dev/null @@ -1,133 +0,0 @@ - - - - - - - -
-
-

GitHub Plugin Settings

-
-
- -
- -

Show Icons

-
- -
- -

Show Ribbons

-
- -
- -

Show Progress Bar

-
- - - - - diff --git a/jquery.min.js b/jquery.min.js deleted file mode 100644 index b1ae21d..0000000 --- a/jquery.min.js +++ /dev/null @@ -1,19 +0,0 @@ -/* - * jQuery JavaScript Library v1.3.2 - * http://jquery.com/ - * - * Copyright (c) 2009 John Resig - * Dual licensed under the MIT and GPL licenses. - * http://docs.jquery.com/License - * - * Date: 2009-02-19 17:34:21 -0500 (Thu, 19 Feb 2009) - * Revision: 6246 - */ -(function(){var l=this,g,y=l.jQuery,p=l.$,o=l.jQuery=l.$=function(E,F){return new o.fn.init(E,F)},D=/^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/,f=/^.[^:#\[\.,]*$/;o.fn=o.prototype={init:function(E,H){E=E||document;if(E.nodeType){this[0]=E;this.length=1;this.context=E;return this}if(typeof E==="string"){var G=D.exec(E);if(G&&(G[1]||!H)){if(G[1]){E=o.clean([G[1]],H)}else{var I=document.getElementById(G[3]);if(I&&I.id!=G[3]){return o().find(E)}var F=o(I||[]);F.context=document;F.selector=E;return F}}else{return o(H).find(E)}}else{if(o.isFunction(E)){return o(document).ready(E)}}if(E.selector&&E.context){this.selector=E.selector;this.context=E.context}return this.setArray(o.isArray(E)?E:o.makeArray(E))},selector:"",jquery:"1.3.2",size:function(){return this.length},get:function(E){return E===g?Array.prototype.slice.call(this):this[E]},pushStack:function(F,H,E){var G=o(F);G.prevObject=this;G.context=this.context;if(H==="find"){G.selector=this.selector+(this.selector?" ":"")+E}else{if(H){G.selector=this.selector+"."+H+"("+E+")"}}return G},setArray:function(E){this.length=0;Array.prototype.push.apply(this,E);return this},each:function(F,E){return o.each(this,F,E)},index:function(E){return o.inArray(E&&E.jquery?E[0]:E,this)},attr:function(F,H,G){var E=F;if(typeof F==="string"){if(H===g){return this[0]&&o[G||"attr"](this[0],F)}else{E={};E[F]=H}}return this.each(function(I){for(F in E){o.attr(G?this.style:this,F,o.prop(this,E[F],G,I,F))}})},css:function(E,F){if((E=="width"||E=="height")&&parseFloat(F)<0){F=g}return this.attr(E,F,"curCSS")},text:function(F){if(typeof F!=="object"&&F!=null){return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(F))}var E="";o.each(F||this,function(){o.each(this.childNodes,function(){if(this.nodeType!=8){E+=this.nodeType!=1?this.nodeValue:o.fn.text([this])}})});return E},wrapAll:function(E){if(this[0]){var F=o(E,this[0].ownerDocument).clone();if(this[0].parentNode){F.insertBefore(this[0])}F.map(function(){var G=this;while(G.firstChild){G=G.firstChild}return G}).append(this)}return this},wrapInner:function(E){return this.each(function(){o(this).contents().wrapAll(E)})},wrap:function(E){return this.each(function(){o(this).wrapAll(E)})},append:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.appendChild(E)}})},prepend:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.insertBefore(E,this.firstChild)}})},before:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this)})},after:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this.nextSibling)})},end:function(){return this.prevObject||o([])},push:[].push,sort:[].sort,splice:[].splice,find:function(E){if(this.length===1){var F=this.pushStack([],"find",E);F.length=0;o.find(E,this[0],F);return F}else{return this.pushStack(o.unique(o.map(this,function(G){return o.find(E,G)})),"find",E)}},clone:function(G){var E=this.map(function(){if(!o.support.noCloneEvent&&!o.isXMLDoc(this)){var I=this.outerHTML;if(!I){var J=this.ownerDocument.createElement("div");J.appendChild(this.cloneNode(true));I=J.innerHTML}return o.clean([I.replace(/ jQuery\d+="(?:\d+|null)"/g,"").replace(/^\s*/,"")])[0]}else{return this.cloneNode(true)}});if(G===true){var H=this.find("*").andSelf(),F=0;E.find("*").andSelf().each(function(){if(this.nodeName!==H[F].nodeName){return}var I=o.data(H[F],"events");for(var K in I){for(var J in I[K]){o.event.add(this,K,I[K][J],I[K][J].data)}}F++})}return E},filter:function(E){return this.pushStack(o.isFunction(E)&&o.grep(this,function(G,F){return E.call(G,F)})||o.multiFilter(E,o.grep(this,function(F){return F.nodeType===1})),"filter",E)},closest:function(E){var G=o.expr.match.POS.test(E)?o(E):null,F=0;return this.map(function(){var H=this;while(H&&H.ownerDocument){if(G?G.index(H)>-1:o(H).is(E)){o.data(H,"closest",F);return H}H=H.parentNode;F++}})},not:function(E){if(typeof E==="string"){if(f.test(E)){return this.pushStack(o.multiFilter(E,this,true),"not",E)}else{E=o.multiFilter(E,this)}}var F=E.length&&E[E.length-1]!==g&&!E.nodeType;return this.filter(function(){return F?o.inArray(this,E)<0:this!=E})},add:function(E){return this.pushStack(o.unique(o.merge(this.get(),typeof E==="string"?o(E):o.makeArray(E))))},is:function(E){return !!E&&o.multiFilter(E,this).length>0},hasClass:function(E){return !!E&&this.is("."+E)},val:function(K){if(K===g){var E=this[0];if(E){if(o.nodeName(E,"option")){return(E.attributes.value||{}).specified?E.value:E.text}if(o.nodeName(E,"select")){var I=E.selectedIndex,L=[],M=E.options,H=E.type=="select-one";if(I<0){return null}for(var F=H?I:0,J=H?I+1:M.length;F=0||o.inArray(this.name,K)>=0)}else{if(o.nodeName(this,"select")){var N=o.makeArray(K);o("option",this).each(function(){this.selected=(o.inArray(this.value,N)>=0||o.inArray(this.text,N)>=0)});if(!N.length){this.selectedIndex=-1}}else{this.value=K}}})},html:function(E){return E===g?(this[0]?this[0].innerHTML.replace(/ jQuery\d+="(?:\d+|null)"/g,""):null):this.empty().append(E)},replaceWith:function(E){return this.after(E).remove()},eq:function(E){return this.slice(E,+E+1)},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments),"slice",Array.prototype.slice.call(arguments).join(","))},map:function(E){return this.pushStack(o.map(this,function(G,F){return E.call(G,F,G)}))},andSelf:function(){return this.add(this.prevObject)},domManip:function(J,M,L){if(this[0]){var I=(this[0].ownerDocument||this[0]).createDocumentFragment(),F=o.clean(J,(this[0].ownerDocument||this[0]),I),H=I.firstChild;if(H){for(var G=0,E=this.length;G1||G>0?I.cloneNode(true):I)}}if(F){o.each(F,z)}}return this;function K(N,O){return M&&o.nodeName(N,"table")&&o.nodeName(O,"tr")?(N.getElementsByTagName("tbody")[0]||N.appendChild(N.ownerDocument.createElement("tbody"))):N}}};o.fn.init.prototype=o.fn;function z(E,F){if(F.src){o.ajax({url:F.src,async:false,dataType:"script"})}else{o.globalEval(F.text||F.textContent||F.innerHTML||"")}if(F.parentNode){F.parentNode.removeChild(F)}}function e(){return +new Date}o.extend=o.fn.extend=function(){var J=arguments[0]||{},H=1,I=arguments.length,E=false,G;if(typeof J==="boolean"){E=J;J=arguments[1]||{};H=2}if(typeof J!=="object"&&!o.isFunction(J)){J={}}if(I==H){J=this;--H}for(;H-1}},swap:function(H,G,I){var E={};for(var F in G){E[F]=H.style[F];H.style[F]=G[F]}I.call(H);for(var F in G){H.style[F]=E[F]}},css:function(H,F,J,E){if(F=="width"||F=="height"){var L,G={position:"absolute",visibility:"hidden",display:"block"},K=F=="width"?["Left","Right"]:["Top","Bottom"];function I(){L=F=="width"?H.offsetWidth:H.offsetHeight;if(E==="border"){return}o.each(K,function(){if(!E){L-=parseFloat(o.curCSS(H,"padding"+this,true))||0}if(E==="margin"){L+=parseFloat(o.curCSS(H,"margin"+this,true))||0}else{L-=parseFloat(o.curCSS(H,"border"+this+"Width",true))||0}})}if(H.offsetWidth!==0){I()}else{o.swap(H,G,I)}return Math.max(0,Math.round(L))}return o.curCSS(H,F,J)},curCSS:function(I,F,G){var L,E=I.style;if(F=="opacity"&&!o.support.opacity){L=o.attr(E,"opacity");return L==""?"1":L}if(F.match(/float/i)){F=w}if(!G&&E&&E[F]){L=E[F]}else{if(q.getComputedStyle){if(F.match(/float/i)){F="float"}F=F.replace(/([A-Z])/g,"-$1").toLowerCase();var M=q.getComputedStyle(I,null);if(M){L=M.getPropertyValue(F)}if(F=="opacity"&&L==""){L="1"}}else{if(I.currentStyle){var J=F.replace(/\-(\w)/g,function(N,O){return O.toUpperCase()});L=I.currentStyle[F]||I.currentStyle[J];if(!/^\d+(px)?$/i.test(L)&&/^\d/.test(L)){var H=E.left,K=I.runtimeStyle.left;I.runtimeStyle.left=I.currentStyle.left;E.left=L||0;L=E.pixelLeft+"px";E.left=H;I.runtimeStyle.left=K}}}}return L},clean:function(F,K,I){K=K||document;if(typeof K.createElement==="undefined"){K=K.ownerDocument||K[0]&&K[0].ownerDocument||document}if(!I&&F.length===1&&typeof F[0]==="string"){var H=/^<(\w+)\s*\/?>$/.exec(F[0]);if(H){return[K.createElement(H[1])]}}var G=[],E=[],L=K.createElement("div");o.each(F,function(P,S){if(typeof S==="number"){S+=""}if(!S){return}if(typeof S==="string"){S=S.replace(/(<(\w+)[^>]*?)\/>/g,function(U,V,T){return T.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?U:V+">"});var O=S.replace(/^\s+/,"").substring(0,10).toLowerCase();var Q=!O.indexOf("",""]||!O.indexOf("",""]||O.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"","
"]||!O.indexOf("",""]||(!O.indexOf("",""]||!O.indexOf("",""]||!o.support.htmlSerialize&&[1,"div
","
"]||[0,"",""];L.innerHTML=Q[1]+S+Q[2];while(Q[0]--){L=L.lastChild}if(!o.support.tbody){var R=/"&&!R?L.childNodes:[];for(var M=N.length-1;M>=0;--M){if(o.nodeName(N[M],"tbody")&&!N[M].childNodes.length){N[M].parentNode.removeChild(N[M])}}}if(!o.support.leadingWhitespace&&/^\s/.test(S)){L.insertBefore(K.createTextNode(S.match(/^\s*/)[0]),L.firstChild)}S=o.makeArray(L.childNodes)}if(S.nodeType){G.push(S)}else{G=o.merge(G,S)}});if(I){for(var J=0;G[J];J++){if(o.nodeName(G[J],"script")&&(!G[J].type||G[J].type.toLowerCase()==="text/javascript")){E.push(G[J].parentNode?G[J].parentNode.removeChild(G[J]):G[J])}else{if(G[J].nodeType===1){G.splice.apply(G,[J+1,0].concat(o.makeArray(G[J].getElementsByTagName("script"))))}I.appendChild(G[J])}}return E}return G},attr:function(J,G,K){if(!J||J.nodeType==3||J.nodeType==8){return g}var H=!o.isXMLDoc(J),L=K!==g;G=H&&o.props[G]||G;if(J.tagName){var F=/href|src|style/.test(G);if(G=="selected"&&J.parentNode){J.parentNode.selectedIndex}if(G in J&&H&&!F){if(L){if(G=="type"&&o.nodeName(J,"input")&&J.parentNode){throw"type property can't be changed"}J[G]=K}if(o.nodeName(J,"form")&&J.getAttributeNode(G)){return J.getAttributeNode(G).nodeValue}if(G=="tabIndex"){var I=J.getAttributeNode("tabIndex");return I&&I.specified?I.value:J.nodeName.match(/(button|input|object|select|textarea)/i)?0:J.nodeName.match(/^(a|area)$/i)&&J.href?0:g}return J[G]}if(!o.support.style&&H&&G=="style"){return o.attr(J.style,"cssText",K)}if(L){J.setAttribute(G,""+K)}var E=!o.support.hrefNormalized&&H&&F?J.getAttribute(G,2):J.getAttribute(G);return E===null?g:E}if(!o.support.opacity&&G=="opacity"){if(L){J.zoom=1;J.filter=(J.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(K)+""=="NaN"?"":"alpha(opacity="+K*100+")")}return J.filter&&J.filter.indexOf("opacity=")>=0?(parseFloat(J.filter.match(/opacity=([^)]*)/)[1])/100)+"":""}G=G.replace(/-([a-z])/ig,function(M,N){return N.toUpperCase()});if(L){J[G]=K}return J[G]},trim:function(E){return(E||"").replace(/^\s+|\s+$/g,"")},makeArray:function(G){var E=[];if(G!=null){var F=G.length;if(F==null||typeof G==="string"||o.isFunction(G)||G.setInterval){E[0]=G}else{while(F){E[--F]=G[F]}}}return E},inArray:function(G,H){for(var E=0,F=H.length;E0?this.clone(true):this).get();o.fn[F].apply(o(L[K]),I);J=J.concat(I)}return this.pushStack(J,E,G)}});o.each({removeAttr:function(E){o.attr(this,E,"");if(this.nodeType==1){this.removeAttribute(E)}},addClass:function(E){o.className.add(this,E)},removeClass:function(E){o.className.remove(this,E)},toggleClass:function(F,E){if(typeof E!=="boolean"){E=!o.className.has(this,F)}o.className[E?"add":"remove"](this,F)},remove:function(E){if(!E||o.filter(E,[this]).length){o("*",this).add([this]).each(function(){o.event.remove(this);o.removeData(this)});if(this.parentNode){this.parentNode.removeChild(this)}}},empty:function(){o(this).children().remove();while(this.firstChild){this.removeChild(this.firstChild)}}},function(E,F){o.fn[E]=function(){return this.each(F,arguments)}});function j(E,F){return E[0]&&parseInt(o.curCSS(E[0],F,true),10)||0}var h="jQuery"+e(),v=0,A={};o.extend({cache:{},data:function(F,E,G){F=F==l?A:F;var H=F[h];if(!H){H=F[h]=++v}if(E&&!o.cache[H]){o.cache[H]={}}if(G!==g){o.cache[H][E]=G}return E?o.cache[H][E]:H},removeData:function(F,E){F=F==l?A:F;var H=F[h];if(E){if(o.cache[H]){delete o.cache[H][E];E="";for(E in o.cache[H]){break}if(!E){o.removeData(F)}}}else{try{delete F[h]}catch(G){if(F.removeAttribute){F.removeAttribute(h)}}delete o.cache[H]}},queue:function(F,E,H){if(F){E=(E||"fx")+"queue";var G=o.data(F,E);if(!G||o.isArray(H)){G=o.data(F,E,o.makeArray(H))}else{if(H){G.push(H)}}}return G},dequeue:function(H,G){var E=o.queue(H,G),F=E.shift();if(!G||G==="fx"){F=E[0]}if(F!==g){F.call(H)}}});o.fn.extend({data:function(E,G){var H=E.split(".");H[1]=H[1]?"."+H[1]:"";if(G===g){var F=this.triggerHandler("getData"+H[1]+"!",[H[0]]);if(F===g&&this.length){F=o.data(this[0],E)}return F===g&&H[1]?this.data(H[0]):F}else{return this.trigger("setData"+H[1]+"!",[H[0],G]).each(function(){o.data(this,E,G)})}},removeData:function(E){return this.each(function(){o.removeData(this,E)})},queue:function(E,F){if(typeof E!=="string"){F=E;E="fx"}if(F===g){return o.queue(this[0],E)}return this.each(function(){var G=o.queue(this,E,F);if(E=="fx"&&G.length==1){G[0].call(this)}})},dequeue:function(E){return this.each(function(){o.dequeue(this,E)})}}); -/* - * Sizzle CSS Selector Engine - v0.9.3 - * Copyright 2009, The Dojo Foundation - * Released under the MIT, BSD, and GPL Licenses. - * More information: http://sizzlejs.com/ - */ -(function(){var R=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?/g,L=0,H=Object.prototype.toString;var F=function(Y,U,ab,ac){ab=ab||[];U=U||document;if(U.nodeType!==1&&U.nodeType!==9){return[]}if(!Y||typeof Y!=="string"){return ab}var Z=[],W,af,ai,T,ad,V,X=true;R.lastIndex=0;while((W=R.exec(Y))!==null){Z.push(W[1]);if(W[2]){V=RegExp.rightContext;break}}if(Z.length>1&&M.exec(Y)){if(Z.length===2&&I.relative[Z[0]]){af=J(Z[0]+Z[1],U)}else{af=I.relative[Z[0]]?[U]:F(Z.shift(),U);while(Z.length){Y=Z.shift();if(I.relative[Y]){Y+=Z.shift()}af=J(Y,af)}}}else{var ae=ac?{expr:Z.pop(),set:E(ac)}:F.find(Z.pop(),Z.length===1&&U.parentNode?U.parentNode:U,Q(U));af=F.filter(ae.expr,ae.set);if(Z.length>0){ai=E(af)}else{X=false}while(Z.length){var ah=Z.pop(),ag=ah;if(!I.relative[ah]){ah=""}else{ag=Z.pop()}if(ag==null){ag=U}I.relative[ah](ai,ag,Q(U))}}if(!ai){ai=af}if(!ai){throw"Syntax error, unrecognized expression: "+(ah||Y)}if(H.call(ai)==="[object Array]"){if(!X){ab.push.apply(ab,ai)}else{if(U.nodeType===1){for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&(ai[aa]===true||ai[aa].nodeType===1&&K(U,ai[aa]))){ab.push(af[aa])}}}else{for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&ai[aa].nodeType===1){ab.push(af[aa])}}}}}else{E(ai,ab)}if(V){F(V,U,ab,ac);if(G){hasDuplicate=false;ab.sort(G);if(hasDuplicate){for(var aa=1;aa":function(Z,U,aa){var X=typeof U==="string";if(X&&!/\W/.test(U)){U=aa?U:U.toUpperCase();for(var V=0,T=Z.length;V=0)){if(!V){T.push(Y)}}else{if(V){U[X]=false}}}}return false},ID:function(T){return T[1].replace(/\\/g,"")},TAG:function(U,T){for(var V=0;T[V]===false;V++){}return T[V]&&Q(T[V])?U[1]:U[1].toUpperCase()},CHILD:function(T){if(T[1]=="nth"){var U=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(T[2]=="even"&&"2n"||T[2]=="odd"&&"2n+1"||!/\D/.test(T[2])&&"0n+"+T[2]||T[2]);T[2]=(U[1]+(U[2]||1))-0;T[3]=U[3]-0}T[0]=L++;return T},ATTR:function(X,U,V,T,Y,Z){var W=X[1].replace(/\\/g,"");if(!Z&&I.attrMap[W]){X[1]=I.attrMap[W]}if(X[2]==="~="){X[4]=" "+X[4]+" "}return X},PSEUDO:function(X,U,V,T,Y){if(X[1]==="not"){if(X[3].match(R).length>1||/^\w/.test(X[3])){X[3]=F(X[3],null,null,U)}else{var W=F.filter(X[3],U,V,true^Y);if(!V){T.push.apply(T,W)}return false}}else{if(I.match.POS.test(X[0])||I.match.CHILD.test(X[0])){return true}}return X},POS:function(T){T.unshift(true);return T}},filters:{enabled:function(T){return T.disabled===false&&T.type!=="hidden"},disabled:function(T){return T.disabled===true},checked:function(T){return T.checked===true},selected:function(T){T.parentNode.selectedIndex;return T.selected===true},parent:function(T){return !!T.firstChild},empty:function(T){return !T.firstChild},has:function(V,U,T){return !!F(T[3],V).length},header:function(T){return/h\d/i.test(T.nodeName)},text:function(T){return"text"===T.type},radio:function(T){return"radio"===T.type},checkbox:function(T){return"checkbox"===T.type},file:function(T){return"file"===T.type},password:function(T){return"password"===T.type},submit:function(T){return"submit"===T.type},image:function(T){return"image"===T.type},reset:function(T){return"reset"===T.type},button:function(T){return"button"===T.type||T.nodeName.toUpperCase()==="BUTTON"},input:function(T){return/input|select|textarea|button/i.test(T.nodeName)}},setFilters:{first:function(U,T){return T===0},last:function(V,U,T,W){return U===W.length-1},even:function(U,T){return T%2===0},odd:function(U,T){return T%2===1},lt:function(V,U,T){return UT[3]-0},nth:function(V,U,T){return T[3]-0==U},eq:function(V,U,T){return T[3]-0==U}},filter:{PSEUDO:function(Z,V,W,aa){var U=V[1],X=I.filters[U];if(X){return X(Z,W,V,aa)}else{if(U==="contains"){return(Z.textContent||Z.innerText||"").indexOf(V[3])>=0}else{if(U==="not"){var Y=V[3];for(var W=0,T=Y.length;W=0)}}},ID:function(U,T){return U.nodeType===1&&U.getAttribute("id")===T},TAG:function(U,T){return(T==="*"&&U.nodeType===1)||U.nodeName===T},CLASS:function(U,T){return(" "+(U.className||U.getAttribute("class"))+" ").indexOf(T)>-1},ATTR:function(Y,W){var V=W[1],T=I.attrHandle[V]?I.attrHandle[V](Y):Y[V]!=null?Y[V]:Y.getAttribute(V),Z=T+"",X=W[2],U=W[4];return T==null?X==="!=":X==="="?Z===U:X==="*="?Z.indexOf(U)>=0:X==="~="?(" "+Z+" ").indexOf(U)>=0:!U?Z&&T!==false:X==="!="?Z!=U:X==="^="?Z.indexOf(U)===0:X==="$="?Z.substr(Z.length-U.length)===U:X==="|="?Z===U||Z.substr(0,U.length+1)===U+"-":false},POS:function(X,U,V,Y){var T=U[2],W=I.setFilters[T];if(W){return W(X,V,U,Y)}}}};var M=I.match.POS;for(var O in I.match){I.match[O]=RegExp(I.match[O].source+/(?![^\[]*\])(?![^\(]*\))/.source)}var E=function(U,T){U=Array.prototype.slice.call(U);if(T){T.push.apply(T,U);return T}return U};try{Array.prototype.slice.call(document.documentElement.childNodes)}catch(N){E=function(X,W){var U=W||[];if(H.call(X)==="[object Array]"){Array.prototype.push.apply(U,X)}else{if(typeof X.length==="number"){for(var V=0,T=X.length;V";var T=document.documentElement;T.insertBefore(U,T.firstChild);if(!!document.getElementById(V)){I.find.ID=function(X,Y,Z){if(typeof Y.getElementById!=="undefined"&&!Z){var W=Y.getElementById(X[1]);return W?W.id===X[1]||typeof W.getAttributeNode!=="undefined"&&W.getAttributeNode("id").nodeValue===X[1]?[W]:g:[]}};I.filter.ID=function(Y,W){var X=typeof Y.getAttributeNode!=="undefined"&&Y.getAttributeNode("id");return Y.nodeType===1&&X&&X.nodeValue===W}}T.removeChild(U)})();(function(){var T=document.createElement("div");T.appendChild(document.createComment(""));if(T.getElementsByTagName("*").length>0){I.find.TAG=function(U,Y){var X=Y.getElementsByTagName(U[1]);if(U[1]==="*"){var W=[];for(var V=0;X[V];V++){if(X[V].nodeType===1){W.push(X[V])}}X=W}return X}}T.innerHTML="";if(T.firstChild&&typeof T.firstChild.getAttribute!=="undefined"&&T.firstChild.getAttribute("href")!=="#"){I.attrHandle.href=function(U){return U.getAttribute("href",2)}}})();if(document.querySelectorAll){(function(){var T=F,U=document.createElement("div");U.innerHTML="

";if(U.querySelectorAll&&U.querySelectorAll(".TEST").length===0){return}F=function(Y,X,V,W){X=X||document;if(!W&&X.nodeType===9&&!Q(X)){try{return E(X.querySelectorAll(Y),V)}catch(Z){}}return T(Y,X,V,W)};F.find=T.find;F.filter=T.filter;F.selectors=T.selectors;F.matches=T.matches})()}if(document.getElementsByClassName&&document.documentElement.getElementsByClassName){(function(){var T=document.createElement("div");T.innerHTML="
";if(T.getElementsByClassName("e").length===0){return}T.lastChild.className="e";if(T.getElementsByClassName("e").length===1){return}I.order.splice(1,0,"CLASS");I.find.CLASS=function(U,V,W){if(typeof V.getElementsByClassName!=="undefined"&&!W){return V.getElementsByClassName(U[1])}}})()}function P(U,Z,Y,ad,aa,ac){var ab=U=="previousSibling"&&!ac;for(var W=0,V=ad.length;W0){X=T;break}}}T=T[U]}ad[W]=X}}}var K=document.compareDocumentPosition?function(U,T){return U.compareDocumentPosition(T)&16}:function(U,T){return U!==T&&(U.contains?U.contains(T):true)};var Q=function(T){return T.nodeType===9&&T.documentElement.nodeName!=="HTML"||!!T.ownerDocument&&Q(T.ownerDocument)};var J=function(T,aa){var W=[],X="",Y,V=aa.nodeType?[aa]:aa;while((Y=I.match.PSEUDO.exec(T))){X+=Y[0];T=T.replace(I.match.PSEUDO,"")}T=I.relative[T]?T+"*":T;for(var Z=0,U=V.length;Z0||T.offsetHeight>0};F.selectors.filters.animated=function(T){return o.grep(o.timers,function(U){return T===U.elem}).length};o.multiFilter=function(V,T,U){if(U){V=":not("+V+")"}return F.matches(V,T)};o.dir=function(V,U){var T=[],W=V[U];while(W&&W!=document){if(W.nodeType==1){T.push(W)}W=W[U]}return T};o.nth=function(X,T,V,W){T=T||1;var U=0;for(;X;X=X[V]){if(X.nodeType==1&&++U==T){break}}return X};o.sibling=function(V,U){var T=[];for(;V;V=V.nextSibling){if(V.nodeType==1&&V!=U){T.push(V)}}return T};return;l.Sizzle=F})();o.event={add:function(I,F,H,K){if(I.nodeType==3||I.nodeType==8){return}if(I.setInterval&&I!=l){I=l}if(!H.guid){H.guid=this.guid++}if(K!==g){var G=H;H=this.proxy(G);H.data=K}var E=o.data(I,"events")||o.data(I,"events",{}),J=o.data(I,"handle")||o.data(I,"handle",function(){return typeof o!=="undefined"&&!o.event.triggered?o.event.handle.apply(arguments.callee.elem,arguments):g});J.elem=I;o.each(F.split(/\s+/),function(M,N){var O=N.split(".");N=O.shift();H.type=O.slice().sort().join(".");var L=E[N];if(o.event.specialAll[N]){o.event.specialAll[N].setup.call(I,K,O)}if(!L){L=E[N]={};if(!o.event.special[N]||o.event.special[N].setup.call(I,K,O)===false){if(I.addEventListener){I.addEventListener(N,J,false)}else{if(I.attachEvent){I.attachEvent("on"+N,J)}}}}L[H.guid]=H;o.event.global[N]=true});I=null},guid:1,global:{},remove:function(K,H,J){if(K.nodeType==3||K.nodeType==8){return}var G=o.data(K,"events"),F,E;if(G){if(H===g||(typeof H==="string"&&H.charAt(0)==".")){for(var I in G){this.remove(K,I+(H||""))}}else{if(H.type){J=H.handler;H=H.type}o.each(H.split(/\s+/),function(M,O){var Q=O.split(".");O=Q.shift();var N=RegExp("(^|\\.)"+Q.slice().sort().join(".*\\.")+"(\\.|$)");if(G[O]){if(J){delete G[O][J.guid]}else{for(var P in G[O]){if(N.test(G[O][P].type)){delete G[O][P]}}}if(o.event.specialAll[O]){o.event.specialAll[O].teardown.call(K,Q)}for(F in G[O]){break}if(!F){if(!o.event.special[O]||o.event.special[O].teardown.call(K,Q)===false){if(K.removeEventListener){K.removeEventListener(O,o.data(K,"handle"),false)}else{if(K.detachEvent){K.detachEvent("on"+O,o.data(K,"handle"))}}}F=null;delete G[O]}}})}for(F in G){break}if(!F){var L=o.data(K,"handle");if(L){L.elem=null}o.removeData(K,"events");o.removeData(K,"handle")}}},trigger:function(I,K,H,E){var G=I.type||I;if(!E){I=typeof I==="object"?I[h]?I:o.extend(o.Event(G),I):o.Event(G);if(G.indexOf("!")>=0){I.type=G=G.slice(0,-1);I.exclusive=true}if(!H){I.stopPropagation();if(this.global[G]){o.each(o.cache,function(){if(this.events&&this.events[G]){o.event.trigger(I,K,this.handle.elem)}})}}if(!H||H.nodeType==3||H.nodeType==8){return g}I.result=g;I.target=H;K=o.makeArray(K);K.unshift(I)}I.currentTarget=H;var J=o.data(H,"handle");if(J){J.apply(H,K)}if((!H[G]||(o.nodeName(H,"a")&&G=="click"))&&H["on"+G]&&H["on"+G].apply(H,K)===false){I.result=false}if(!E&&H[G]&&!I.isDefaultPrevented()&&!(o.nodeName(H,"a")&&G=="click")){this.triggered=true;try{H[G]()}catch(L){}}this.triggered=false;if(!I.isPropagationStopped()){var F=H.parentNode||H.ownerDocument;if(F){o.event.trigger(I,K,F,true)}}},handle:function(K){var J,E;K=arguments[0]=o.event.fix(K||l.event);K.currentTarget=this;var L=K.type.split(".");K.type=L.shift();J=!L.length&&!K.exclusive;var I=RegExp("(^|\\.)"+L.slice().sort().join(".*\\.")+"(\\.|$)");E=(o.data(this,"events")||{})[K.type];for(var G in E){var H=E[G];if(J||I.test(H.type)){K.handler=H;K.data=H.data;var F=H.apply(this,arguments);if(F!==g){K.result=F;if(F===false){K.preventDefault();K.stopPropagation()}}if(K.isImmediatePropagationStopped()){break}}}},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(H){if(H[h]){return H}var F=H;H=o.Event(F);for(var G=this.props.length,J;G;){J=this.props[--G];H[J]=F[J]}if(!H.target){H.target=H.srcElement||document}if(H.target.nodeType==3){H.target=H.target.parentNode}if(!H.relatedTarget&&H.fromElement){H.relatedTarget=H.fromElement==H.target?H.toElement:H.fromElement}if(H.pageX==null&&H.clientX!=null){var I=document.documentElement,E=document.body;H.pageX=H.clientX+(I&&I.scrollLeft||E&&E.scrollLeft||0)-(I.clientLeft||0);H.pageY=H.clientY+(I&&I.scrollTop||E&&E.scrollTop||0)-(I.clientTop||0)}if(!H.which&&((H.charCode||H.charCode===0)?H.charCode:H.keyCode)){H.which=H.charCode||H.keyCode}if(!H.metaKey&&H.ctrlKey){H.metaKey=H.ctrlKey}if(!H.which&&H.button){H.which=(H.button&1?1:(H.button&2?3:(H.button&4?2:0)))}return H},proxy:function(F,E){E=E||function(){return F.apply(this,arguments)};E.guid=F.guid=F.guid||E.guid||this.guid++;return E},special:{ready:{setup:B,teardown:function(){}}},specialAll:{live:{setup:function(E,F){o.event.add(this,F[0],c)},teardown:function(G){if(G.length){var E=0,F=RegExp("(^|\\.)"+G[0]+"(\\.|$)");o.each((o.data(this,"events").live||{}),function(){if(F.test(this.type)){E++}});if(E<1){o.event.remove(this,G[0],c)}}}}}};o.Event=function(E){if(!this.preventDefault){return new o.Event(E)}if(E&&E.type){this.originalEvent=E;this.type=E.type}else{this.type=E}this.timeStamp=e();this[h]=true};function k(){return false}function u(){return true}o.Event.prototype={preventDefault:function(){this.isDefaultPrevented=u;var E=this.originalEvent;if(!E){return}if(E.preventDefault){E.preventDefault()}E.returnValue=false},stopPropagation:function(){this.isPropagationStopped=u;var E=this.originalEvent;if(!E){return}if(E.stopPropagation){E.stopPropagation()}E.cancelBubble=true},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=u;this.stopPropagation()},isDefaultPrevented:k,isPropagationStopped:k,isImmediatePropagationStopped:k};var a=function(F){var E=F.relatedTarget;while(E&&E!=this){try{E=E.parentNode}catch(G){E=this}}if(E!=this){F.type=F.data;o.event.handle.apply(this,arguments)}};o.each({mouseover:"mouseenter",mouseout:"mouseleave"},function(F,E){o.event.special[E]={setup:function(){o.event.add(this,F,a,E)},teardown:function(){o.event.remove(this,F,a)}}});o.fn.extend({bind:function(F,G,E){return F=="unload"?this.one(F,G,E):this.each(function(){o.event.add(this,F,E||G,E&&G)})},one:function(G,H,F){var E=o.event.proxy(F||H,function(I){o(this).unbind(I,E);return(F||H).apply(this,arguments)});return this.each(function(){o.event.add(this,G,E,F&&H)})},unbind:function(F,E){return this.each(function(){o.event.remove(this,F,E)})},trigger:function(E,F){return this.each(function(){o.event.trigger(E,F,this)})},triggerHandler:function(E,G){if(this[0]){var F=o.Event(E);F.preventDefault();F.stopPropagation();o.event.trigger(F,G,this[0]);return F.result}},toggle:function(G){var E=arguments,F=1;while(F=0){var E=G.slice(I,G.length);G=G.slice(0,I)}var H="GET";if(J){if(o.isFunction(J)){K=J;J=null}else{if(typeof J==="object"){J=o.param(J);H="POST"}}}var F=this;o.ajax({url:G,type:H,dataType:"html",data:J,complete:function(M,L){if(L=="success"||L=="notmodified"){F.html(E?o("
").append(M.responseText.replace(//g,"")).find(E):M.responseText)}if(K){F.each(K,[M.responseText,L,M])}}});return this},serialize:function(){return o.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?o.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password|search/i.test(this.type))}).map(function(E,F){var G=o(this).val();return G==null?null:o.isArray(G)?o.map(G,function(I,H){return{name:F.name,value:I}}):{name:F.name,value:G}}).get()}});o.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(E,F){o.fn[F]=function(G){return this.bind(F,G)}});var r=e();o.extend({get:function(E,G,H,F){if(o.isFunction(G)){H=G;G=null}return o.ajax({type:"GET",url:E,data:G,success:H,dataType:F})},getScript:function(E,F){return o.get(E,null,F,"script")},getJSON:function(E,F,G){return o.get(E,F,G,"json")},post:function(E,G,H,F){if(o.isFunction(G)){H=G;G={}}return o.ajax({type:"POST",url:E,data:G,success:H,dataType:F})},ajaxSetup:function(E){o.extend(o.ajaxSettings,E)},ajaxSettings:{url:location.href,global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:function(){return l.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest()},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(M){M=o.extend(true,M,o.extend(true,{},o.ajaxSettings,M));var W,F=/=\?(&|$)/g,R,V,G=M.type.toUpperCase();if(M.data&&M.processData&&typeof M.data!=="string"){M.data=o.param(M.data)}if(M.dataType=="jsonp"){if(G=="GET"){if(!M.url.match(F)){M.url+=(M.url.match(/\?/)?"&":"?")+(M.jsonp||"callback")+"=?"}}else{if(!M.data||!M.data.match(F)){M.data=(M.data?M.data+"&":"")+(M.jsonp||"callback")+"=?"}}M.dataType="json"}if(M.dataType=="json"&&(M.data&&M.data.match(F)||M.url.match(F))){W="jsonp"+r++;if(M.data){M.data=(M.data+"").replace(F,"="+W+"$1")}M.url=M.url.replace(F,"="+W+"$1");M.dataType="script";l[W]=function(X){V=X;I();L();l[W]=g;try{delete l[W]}catch(Y){}if(H){H.removeChild(T)}}}if(M.dataType=="script"&&M.cache==null){M.cache=false}if(M.cache===false&&G=="GET"){var E=e();var U=M.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+E+"$2");M.url=U+((U==M.url)?(M.url.match(/\?/)?"&":"?")+"_="+E:"")}if(M.data&&G=="GET"){M.url+=(M.url.match(/\?/)?"&":"?")+M.data;M.data=null}if(M.global&&!o.active++){o.event.trigger("ajaxStart")}var Q=/^(\w+:)?\/\/([^\/?#]+)/.exec(M.url);if(M.dataType=="script"&&G=="GET"&&Q&&(Q[1]&&Q[1]!=location.protocol||Q[2]!=location.host)){var H=document.getElementsByTagName("head")[0];var T=document.createElement("script");T.src=M.url;if(M.scriptCharset){T.charset=M.scriptCharset}if(!W){var O=false;T.onload=T.onreadystatechange=function(){if(!O&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){O=true;I();L();T.onload=T.onreadystatechange=null;H.removeChild(T)}}}H.appendChild(T);return g}var K=false;var J=M.xhr();if(M.username){J.open(G,M.url,M.async,M.username,M.password)}else{J.open(G,M.url,M.async)}try{if(M.data){J.setRequestHeader("Content-Type",M.contentType)}if(M.ifModified){J.setRequestHeader("If-Modified-Since",o.lastModified[M.url]||"Thu, 01 Jan 1970 00:00:00 GMT")}J.setRequestHeader("X-Requested-With","XMLHttpRequest");J.setRequestHeader("Accept",M.dataType&&M.accepts[M.dataType]?M.accepts[M.dataType]+", */*":M.accepts._default)}catch(S){}if(M.beforeSend&&M.beforeSend(J,M)===false){if(M.global&&!--o.active){o.event.trigger("ajaxStop")}J.abort();return false}if(M.global){o.event.trigger("ajaxSend",[J,M])}var N=function(X){if(J.readyState==0){if(P){clearInterval(P);P=null;if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}}else{if(!K&&J&&(J.readyState==4||X=="timeout")){K=true;if(P){clearInterval(P);P=null}R=X=="timeout"?"timeout":!o.httpSuccess(J)?"error":M.ifModified&&o.httpNotModified(J,M.url)?"notmodified":"success";if(R=="success"){try{V=o.httpData(J,M.dataType,M)}catch(Z){R="parsererror"}}if(R=="success"){var Y;try{Y=J.getResponseHeader("Last-Modified")}catch(Z){}if(M.ifModified&&Y){o.lastModified[M.url]=Y}if(!W){I()}}else{o.handleError(M,J,R)}L();if(X){J.abort()}if(M.async){J=null}}}};if(M.async){var P=setInterval(N,13);if(M.timeout>0){setTimeout(function(){if(J&&!K){N("timeout")}},M.timeout)}}try{J.send(M.data)}catch(S){o.handleError(M,J,null,S)}if(!M.async){N()}function I(){if(M.success){M.success(V,R)}if(M.global){o.event.trigger("ajaxSuccess",[J,M])}}function L(){if(M.complete){M.complete(J,R)}if(M.global){o.event.trigger("ajaxComplete",[J,M])}if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}return J},handleError:function(F,H,E,G){if(F.error){F.error(H,E,G)}if(F.global){o.event.trigger("ajaxError",[H,F,G])}},active:0,httpSuccess:function(F){try{return !F.status&&location.protocol=="file:"||(F.status>=200&&F.status<300)||F.status==304||F.status==1223}catch(E){}return false},httpNotModified:function(G,E){try{var H=G.getResponseHeader("Last-Modified");return G.status==304||H==o.lastModified[E]}catch(F){}return false},httpData:function(J,H,G){var F=J.getResponseHeader("content-type"),E=H=="xml"||!H&&F&&F.indexOf("xml")>=0,I=E?J.responseXML:J.responseText;if(E&&I.documentElement.tagName=="parsererror"){throw"parsererror"}if(G&&G.dataFilter){I=G.dataFilter(I,H)}if(typeof I==="string"){if(H=="script"){o.globalEval(I)}if(H=="json"){I=l["eval"]("("+I+")")}}return I},param:function(E){var G=[];function H(I,J){G[G.length]=encodeURIComponent(I)+"="+encodeURIComponent(J)}if(o.isArray(E)||E.jquery){o.each(E,function(){H(this.name,this.value)})}else{for(var F in E){if(o.isArray(E[F])){o.each(E[F],function(){H(F,this)})}else{H(F,o.isFunction(E[F])?E[F]():E[F])}}}return G.join("&").replace(/%20/g,"+")}});var m={},n,d=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];function t(F,E){var G={};o.each(d.concat.apply([],d.slice(0,E)),function(){G[this]=F});return G}o.fn.extend({show:function(J,L){if(J){return this.animate(t("show",3),J,L)}else{for(var H=0,F=this.length;H").appendTo("body");K=I.css("display");if(K==="none"){K="block"}I.remove();m[G]=K}o.data(this[H],"olddisplay",K)}}for(var H=0,F=this.length;H=0;H--){if(G[H].elem==this){if(E){G[H](true)}G.splice(H,1)}}});if(!E){this.dequeue()}return this}});o.each({slideDown:t("show",1),slideUp:t("hide",1),slideToggle:t("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(E,F){o.fn[E]=function(G,H){return this.animate(F,G,H)}});o.extend({speed:function(G,H,F){var E=typeof G==="object"?G:{complete:F||!F&&H||o.isFunction(G)&&G,duration:G,easing:F&&H||H&&!o.isFunction(H)&&H};E.duration=o.fx.off?0:typeof E.duration==="number"?E.duration:o.fx.speeds[E.duration]||o.fx.speeds._default;E.old=E.complete;E.complete=function(){if(E.queue!==false){o(this).dequeue()}if(o.isFunction(E.old)){E.old.call(this)}};return E},easing:{linear:function(G,H,E,F){return E+F*G},swing:function(G,H,E,F){return((-Math.cos(G*Math.PI)/2)+0.5)*F+E}},timers:[],fx:function(F,E,G){this.options=E;this.elem=F;this.prop=G;if(!E.orig){E.orig={}}}});o.fx.prototype={update:function(){if(this.options.step){this.options.step.call(this.elem,this.now,this)}(o.fx.step[this.prop]||o.fx.step._default)(this);if((this.prop=="height"||this.prop=="width")&&this.elem.style){this.elem.style.display="block"}},cur:function(F){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null)){return this.elem[this.prop]}var E=parseFloat(o.css(this.elem,this.prop,F));return E&&E>-10000?E:parseFloat(o.curCSS(this.elem,this.prop))||0},custom:function(I,H,G){this.startTime=e();this.start=I;this.end=H;this.unit=G||this.unit||"px";this.now=this.start;this.pos=this.state=0;var E=this;function F(J){return E.step(J)}F.elem=this.elem;if(F()&&o.timers.push(F)&&!n){n=setInterval(function(){var K=o.timers;for(var J=0;J=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var E=true;for(var F in this.options.curAnim){if(this.options.curAnim[F]!==true){E=false}}if(E){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(o.css(this.elem,"display")=="none"){this.elem.style.display="block"}}if(this.options.hide){o(this.elem).hide()}if(this.options.hide||this.options.show){for(var I in this.options.curAnim){o.attr(this.elem.style,I,this.options.orig[I])}}this.options.complete.call(this.elem)}return false}else{var J=G-this.startTime;this.state=J/this.options.duration;this.pos=o.easing[this.options.easing||(o.easing.swing?"swing":"linear")](this.state,J,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update()}return true}};o.extend(o.fx,{speeds:{slow:600,fast:200,_default:400},step:{opacity:function(E){o.attr(E.elem.style,"opacity",E.now)},_default:function(E){if(E.elem.style&&E.elem.style[E.prop]!=null){E.elem.style[E.prop]=E.now+E.unit}else{E.elem[E.prop]=E.now}}}});if(document.documentElement.getBoundingClientRect){o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}var G=this[0].getBoundingClientRect(),J=this[0].ownerDocument,F=J.body,E=J.documentElement,L=E.clientTop||F.clientTop||0,K=E.clientLeft||F.clientLeft||0,I=G.top+(self.pageYOffset||o.boxModel&&E.scrollTop||F.scrollTop)-L,H=G.left+(self.pageXOffset||o.boxModel&&E.scrollLeft||F.scrollLeft)-K;return{top:I,left:H}}}else{o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}o.offset.initialized||o.offset.initialize();var J=this[0],G=J.offsetParent,F=J,O=J.ownerDocument,M,H=O.documentElement,K=O.body,L=O.defaultView,E=L.getComputedStyle(J,null),N=J.offsetTop,I=J.offsetLeft;while((J=J.parentNode)&&J!==K&&J!==H){M=L.getComputedStyle(J,null);N-=J.scrollTop,I-=J.scrollLeft;if(J===G){N+=J.offsetTop,I+=J.offsetLeft;if(o.offset.doesNotAddBorder&&!(o.offset.doesAddBorderForTableAndCells&&/^t(able|d|h)$/i.test(J.tagName))){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}F=G,G=J.offsetParent}if(o.offset.subtractsBorderForOverflowNotVisible&&M.overflow!=="visible"){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}E=M}if(E.position==="relative"||E.position==="static"){N+=K.offsetTop,I+=K.offsetLeft}if(E.position==="fixed"){N+=Math.max(H.scrollTop,K.scrollTop),I+=Math.max(H.scrollLeft,K.scrollLeft)}return{top:N,left:I}}}o.offset={initialize:function(){if(this.initialized){return}var L=document.body,F=document.createElement("div"),H,G,N,I,M,E,J=L.style.marginTop,K='
';M={position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"};for(E in M){F.style[E]=M[E]}F.innerHTML=K;L.insertBefore(F,L.firstChild);H=F.firstChild,G=H.firstChild,I=H.nextSibling.firstChild.firstChild;this.doesNotAddBorder=(G.offsetTop!==5);this.doesAddBorderForTableAndCells=(I.offsetTop===5);H.style.overflow="hidden",H.style.position="relative";this.subtractsBorderForOverflowNotVisible=(G.offsetTop===-5);L.style.marginTop="1px";this.doesNotIncludeMarginInBodyOffset=(L.offsetTop===0);L.style.marginTop=J;L.removeChild(F);this.initialized=true},bodyOffset:function(E){o.offset.initialized||o.offset.initialize();var G=E.offsetTop,F=E.offsetLeft;if(o.offset.doesNotIncludeMarginInBodyOffset){G+=parseInt(o.curCSS(E,"marginTop",true),10)||0,F+=parseInt(o.curCSS(E,"marginLeft",true),10)||0}return{top:G,left:F}}};o.fn.extend({position:function(){var I=0,H=0,F;if(this[0]){var G=this.offsetParent(),J=this.offset(),E=/^body|html$/i.test(G[0].tagName)?{top:0,left:0}:G.offset();J.top-=j(this,"marginTop");J.left-=j(this,"marginLeft");E.top+=j(G,"borderTopWidth");E.left+=j(G,"borderLeftWidth");F={top:J.top-E.top,left:J.left-E.left}}return F},offsetParent:function(){var E=this[0].offsetParent||document.body;while(E&&(!/^body|html$/i.test(E.tagName)&&o.css(E,"position")=="static")){E=E.offsetParent}return o(E)}});o.each(["Left","Top"],function(F,E){var G="scroll"+E;o.fn[G]=function(H){if(!this[0]){return null}return H!==g?this.each(function(){this==l||this==document?l.scrollTo(!F?H:o(l).scrollLeft(),F?H:o(l).scrollTop()):this[G]=H}):this[0]==l||this[0]==document?self[F?"pageYOffset":"pageXOffset"]||o.boxModel&&document.documentElement[G]||document.body[G]:this[0][G]}});o.each(["Height","Width"],function(I,G){var E=I?"Left":"Top",H=I?"Right":"Bottom",F=G.toLowerCase();o.fn["inner"+G]=function(){return this[0]?o.css(this[0],F,false,"padding"):null};o.fn["outer"+G]=function(K){return this[0]?o.css(this[0],F,false,K?"margin":"border"):null};var J=G.toLowerCase();o.fn[J]=function(K){return this[0]==l?document.compatMode=="CSS1Compat"&&document.documentElement["client"+G]||document.body["client"+G]:this[0]==document?Math.max(document.documentElement["client"+G],document.body["scroll"+G],document.documentElement["scroll"+G],document.body["offset"+G],document.documentElement["offset"+G]):K===g?(this.length?o.css(this[0],J):null):this.css(J,typeof K==="string"?K:K+"px")}})})(); \ No newline at end of file diff --git a/manifest.json b/manifest.json deleted file mode 100644 index 2642d78..0000000 --- a/manifest.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "name": "GitHub Tool Tips", - "version": "1", - "manifest_version": 2, - "content_security_policy": "script-src 'self' 'sha256-h2wfw88s1v0G6TfLu2lTGsvk/fO+++3RvfDN1K262w8='; object-src 'self'", - "description": "Helps newcomers navigate GitHub and successfully contribute to open source projects.", - "browser_action": { - "name": "GitHub Plugin Development", - "icons": ["icon.png"], - "default_icon": "outline.png", - "default_popup": "index.html" - }, - - "content_scripts": [ - { - "matches": ["https://github.com/*"], - "css": ["styles.css"], - "js": ["jquery.min.js", "Chart.bundle.js", "content.js"], - "run_at": "document_end" - } - ], - "web_accessible_resources": ["*.json"], - "permissions": ["tabs", "storage"] -} diff --git a/popup.js b/popup.js deleted file mode 100644 index 97ef2dd..0000000 --- a/popup.js +++ /dev/null @@ -1,56 +0,0 @@ - function progressBarPopUp() { - chrome.tabs.query({currentWindow: true, active: true}, function (tabs){ - var activeTab = tabs[0]; - chrome.tabs.sendMessage(activeTab.id, {"message": "progress_bar"}); - - }); -} - -function iconPopUp() { - chrome.tabs.query({currentWindow: true, active: true}, function (tabs){ - var activeTab = tabs[0]; - chrome.tabs.sendMessage(activeTab.id, {"message": "icon"}); - - if(document.getElementById("iconBtn").checked ) { - chrome.storage.local.set({'iconStatus': true}); - } - else { - chrome.storage.local.set({'iconStatus': false}); - } - }); -} - -function ribbonPopUp() { - chrome.tabs.query({currentWindow: true, active: true}, function (tabs){ - var activeTab = tabs[0]; - chrome.tabs.sendMessage(activeTab.id, {"message": "ribbon"}); - - }); -} - -document.addEventListener("DOMContentLoaded", function() { - - chrome.storage.local.get('iconStatus', function(status){ - var switchStatus = status.iconStatus; - - if(switchStatus) { - document.getElementById('iconBtn').checked = true; - } else { - document.getElementById('iconBtn').checked = false; - } - - console.log( document.getElementsByClassName('helpIcon')[0].style.display ); - if( document.getElementsByClassName('helpIcon')[0].style.display == 'inline-block' && switchStatus ) { - document.getElementById('iconBtn').checked = true; - } - }); - - - document.getElementById('iconBtn').addEventListener("change", iconPopUp); - - document.getElementById('ribbonBtn').addEventListener("change", ribbonPopUp); - - document.getElementById('progressBarBtn').addEventListener("change", progressBarPopUp); - -}); - diff --git a/result.json b/result.json deleted file mode 100644 index 24d720c..0000000 --- a/result.json +++ /dev/null @@ -1,682 +0,0 @@ -{ - "Name": "DanielRustrum", - "Repos": [{ - "Owner": "DanielRustrum", - "Name": "Dictionary-to-XML", - "API": { - "apis": [{ - "name": " classes;", - "count": 1 - }, { - "name": " wrapper;", - "count": 2 - }], - "langs": ["Java"] - } - }, { - "Owner": "DanielRustrum", - "Name": "earthquake", - "API": { - "apis": [], - "langs": [] - } - }, { - "Owner": "DanielRustrum", - "Name": "GUIToDB", - "API": { - "apis": [{ - "name": " exception;", - "count": 3 - }, { - "name": " result;", - "count": 3 - }], - "langs": ["Java"] - } - }, { - "Owner": "DanielRustrum", - "Name": "Linux-Batch-Commands", - "API": { - "apis": [{ - "name": " java.awt.event.ActionListener;", - "count": 1 - }, { - "name": " java.util.ArrayList;", - "count": 1 - }, { - "name": " false;", - "count": 1 - }, { - "name": " logic;", - "count": 2 - }, { - "name": " enrollButton;", - "count": 1 - }, { - "name": " true;", - "count": 1 - }, { - "name": " java.awt.event.ActionListener;", - "count": 1 - }, { - "name": " java.util.ArrayList;", - "count": 1 - }, { - "name": " false;", - "count": 1 - }, { - "name": " logic;", - "count": 2 - }, { - "name": " enrollButton;", - "count": 1 - }, { - "name": " true;", - "count": 1 - }, { - "name": " exception;", - "count": 3 - }, { - "name": " result;", - "count": 3 - }], - "langs": ["Java", "Java"] - } - }, { - "Owner": "DanielRustrum", - "Name": "Password-Generator", - "API": { - "apis": [{ - "name": " guiForm;", - "count": 1 - }, { - "name": " com.mysql.cj.xdevapi.InsertStatement;", - "count": 1 - }, { - "name": " javax.swing.plaf.nimbus.State;", - "count": 1 - }, { - "name": " javax.swing.plaf.synth.SynthScrollBarUI;", - "count": 1 - }, { - "name": " java.sql.DriverManager;", - "count": 1 - }, { - "name": " studentID;", - "count": 2 - }, { - "name": " true;", - "count": 2 - }, { - "name": " false;", - "count": 2 - }, { - "name": " guiForm;", - "count": 1 - }, { - "name": " com.mysql.cj.xdevapi.InsertStatement;", - "count": 1 - }, { - "name": " javax.swing.plaf.nimbus.State;", - "count": 1 - }, { - "name": " javax.swing.plaf.synth.SynthScrollBarUI;", - "count": 1 - }, { - "name": " java.sql.DriverManager;", - "count": 1 - }, { - "name": " studentID;", - "count": 2 - }, { - "name": " true;", - "count": 2 - }, { - "name": " false;", - "count": 2 - }, { - "name": " guiForm;", - "count": 1 - }, { - "name": " com.mysql.cj.xdevapi.InsertStatement;", - "count": 1 - }, { - "name": " javax.swing.plaf.nimbus.State;", - "count": 1 - }, { - "name": " javax.swing.plaf.synth.SynthScrollBarUI;", - "count": 1 - }, { - "name": " java.sql.DriverManager;", - "count": 1 - }, { - "name": " studentID;", - "count": 2 - }, { - "name": " true;", - "count": 2 - }, { - "name": " false;", - "count": 2 - }, { - "name": " firstNameLabel;", - "count": 1 - }, { - "name": " lastNameLabel;", - "count": 1 - }, { - "name": " removeClassButton;", - "count": 1 - }, { - "name": " statusMessage;", - "count": 1 - }, { - "name": " guiForm;", - "count": 2 - }, { - "name": " com.mysql.cj.xdevapi.InsertStatement;", - "count": 1 - }, { - "name": " javax.swing.plaf.nimbus.State;", - "count": 1 - }, { - "name": " javax.swing.plaf.synth.SynthScrollBarUI;", - "count": 1 - }, { - "name": " java.sql.DriverManager;", - "count": 1 - }, { - "name": " studentID;", - "count": 2 - }, { - "name": " true;", - "count": 2 - }, { - "name": " false;", - "count": 2 - }, { - "name": " firstNameLabel;", - "count": 1 - }, { - "name": " lastNameLabel;", - "count": 1 - }, { - "name": " removeClassButton;", - "count": 1 - }, { - "name": " statusMessage;", - "count": 1 - }, { - "name": " java.sql.SQLException;", - "count": 1 - }], - "langs": ["Java", "Java", "Java", "Java"] - } - }, { - "Owner": "DanielRustrum", - "Name": "Quick-Database", - "API": { - "apis": [{ - "name": " guiForm;", - "count": 1 - }, { - "name": " java.sql.SQLException;", - "count": 1 - }], - "langs": ["Java"] - } - }, { - "Owner": "DanielRustrum", - "Name": "Quick-Rest", - "API": { - "apis": [{ - "name": " guiForm;", - "count": 1 - }, { - "name": " java.awt.event.ActionEvent;", - "count": 1 - }, { - "name": " java.awt.event.ActionListener;", - "count": 1 - }, { - "name": " java.util.ArrayList;", - "count": 1 - }, { - "name": " false;", - "count": 1 - }, { - "name": " logic;", - "count": 1 - }, { - "name": " isAdmin;", - "count": 1 - }, { - "name": " addableClass;", - "count": 1 - }, { - "name": " wrapper;", - "count": 1 - }, { - "name": " enrollButton;", - "count": 1 - }, { - "name": " mainPanel;", - "count": 1 - }, { - "name": " firstNameLabel;", - "count": 1 - }, { - "name": " lastNameLabel;", - "count": 1 - }, { - "name": " removeClassButton;", - "count": 1 - }, { - "name": " connect;", - "count": 1 - }, { - "name": " guiForm;", - "count": 2 - }, { - "name": " java.awt.event.ActionEvent;", - "count": 1 - }, { - "name": " java.awt.event.ActionListener;", - "count": 1 - }, { - "name": " java.util.ArrayList;", - "count": 1 - }, { - "name": " false;", - "count": 1 - }, { - "name": " logic;", - "count": 1 - }, { - "name": " isAdmin;", - "count": 1 - }, { - "name": " addableClass;", - "count": 1 - }, { - "name": " wrapper;", - "count": 2 - }, { - "name": " enrollButton;", - "count": 1 - }, { - "name": " mainPanel;", - "count": 1 - }, { - "name": " firstNameLabel;", - "count": 1 - }, { - "name": " lastNameLabel;", - "count": 1 - }, { - "name": " removeClassButton;", - "count": 1 - }, { - "name": " connect;", - "count": 1 - }, { - "name": " classes;", - "count": 3 - }], - "langs": ["Java", "Java"] - } - }, { - "Owner": "DanielRustrum", - "Name": "Quick-Webhook", - "API": { - "apis": [{ - "name": " guiForm;", - "count": 1 - }, { - "name": " classes;", - "count": 2 - }, { - "name": " wrapper;", - "count": 1 - }, { - "name": " guiForm;", - "count": 1 - }, { - "name": " classes;", - "count": 2 - }, { - "name": " wrapper;", - "count": 1 - }, { - "name": " studentIdLabel;", - "count": 2 - }, { - "name": " classesLabel;", - "count": 2 - }, { - "name": " firstNameLabel;", - "count": 1 - }, { - "name": " lastNameLabel;", - "count": 1 - }, { - "name": " removeClassButton;", - "count": 1 - }, { - "name": " guiForm;", - "count": 1 - }, { - "name": " classes;", - "count": 6 - }, { - "name": " wrapper;", - "count": 2 - }, { - "name": " studentIdLabel;", - "count": 2 - }, { - "name": " classesLabel;", - "count": 2 - }, { - "name": " firstNameLabel;", - "count": 1 - }, { - "name": " lastNameLabel;", - "count": 1 - }, { - "name": " removeClassButton;", - "count": 1 - }], - "langs": ["Java", "Java", "Java"] - } - }, { - "Owner": "DanielRustrum", - "Name": "Remediation", - "API": { - "apis": [{ - "name": " guiForm;", - "count": 1 - }, { - "name": " classes;", - "count": 3 - }, { - "name": " wrapper;", - "count": 1 - }, { - "name": " guiForm;", - "count": 1 - }, { - "name": " classes;", - "count": 3 - }, { - "name": " wrapper;", - "count": 1 - }, { - "name": " guiForm;", - "count": 2 - }, { - "name": " classes;", - "count": 3 - }, { - "name": " wrapper;", - "count": 1 - }, { - "name": " java.awt.event.ActionEvent;", - "count": 1 - }, { - "name": " java.awt.event.ActionListener;", - "count": 1 - }, { - "name": " java.util.ArrayList;", - "count": 1 - }, { - "name": " false;", - "count": 1 - }, { - "name": " logic;", - "count": 1 - }, { - "name": " enrollButton;", - "count": 1 - }, { - "name": " mainPanel;", - "count": 1 - }, { - "name": " ClassBox;", - "count": 1 - }, { - "name": " FNameText;", - "count": 1 - }], - "langs": ["Java", "Java", "Java"] - } - }, { - "Owner": "DanielRustrum", - "Name": "Request-Files", - "API": { - "apis": [{ - "name": " classes;", - "count": 4 - }, { - "name": " wrapper;", - "count": 1 - }, { - "name": " classes;", - "count": 4 - }, { - "name": " wrapper;", - "count": 2 - }, { - "name": " false;", - "count": 1 - }, { - "name": " logic;", - "count": 1 - }, { - "name": " isAdmin;", - "count": 1 - }, { - "name": " addableClass;", - "count": 1 - }, { - "name": " enrollButton;", - "count": 1 - }, { - "name": " LNameText;", - "count": 1 - }, { - "name": " IdText;", - "count": 1 - }, { - "name": " firstNameLabel;", - "count": 1 - }, { - "name": " classesLabel;", - "count": 1 - }, { - "name": " studentIdLabel;", - "count": 1 - }, { - "name": " lastNameLabel;", - "count": 1 - }, { - "name": " removeClassButton;", - "count": 1 - }], - "langs": ["Java", "Java"] - } - }, { - "Owner": "DanielRustrum", - "Name": "software-engineering-class-project", - "API": { - "apis": [], - "langs": [] - } - }, { - "Owner": "DanielRustrum", - "Name": "Survival-Plus-Minecraft-Datapack", - "API": { - "apis": [{ - "name": " guiForm;", - "count": 1 - }, { - "name": " guiForm;", - "count": 2 - }, { - "name": " com.mysql.cj.xdevapi.InsertStatement;", - "count": 1 - }, { - "name": " javax.swing.plaf.nimbus.State;", - "count": 1 - }, { - "name": " java.sql.DriverManager;", - "count": 1 - }, { - "name": " connect;", - "count": 1 - }, { - "name": " classID;", - "count": 1 - }, { - "name": " className;", - "count": 1 - }, { - "name": " capacity;", - "count": 1 - }, { - "name": " queueNum;", - "count": 1 - }, { - "name": " studentAlreadyEnrolled;", - "count": 1 - }, { - "name": " studentID;", - "count": 1 - }, { - "name": " enrolledClass;", - "count": 1 - }, { - "name": " enrolledCap;", - "count": 1 - }, { - "name": " true;", - "count": 1 - }, { - "name": " false;", - "count": 1 - }, { - "name": " guiForm;", - "count": 3 - }, { - "name": " com.mysql.cj.xdevapi.InsertStatement;", - "count": 1 - }, { - "name": " javax.swing.plaf.nimbus.State;", - "count": 1 - }, { - "name": " java.sql.DriverManager;", - "count": 1 - }, { - "name": " connect;", - "count": 1 - }, { - "name": " classID;", - "count": 1 - }, { - "name": " className;", - "count": 1 - }, { - "name": " capacity;", - "count": 1 - }, { - "name": " queueNum;", - "count": 1 - }, { - "name": " studentAlreadyEnrolled;", - "count": 1 - }, { - "name": " studentID;", - "count": 1 - }, { - "name": " enrolledClass;", - "count": 1 - }, { - "name": " enrolledCap;", - "count": 1 - }, { - "name": " true;", - "count": 1 - }, { - "name": " false;", - "count": 1 - }, { - "name": " guiForm;", - "count": 3 - }, { - "name": " com.mysql.cj.xdevapi.InsertStatement;", - "count": 1 - }, { - "name": " javax.swing.plaf.nimbus.State;", - "count": 1 - }, { - "name": " java.sql.DriverManager;", - "count": 1 - }, { - "name": " connect;", - "count": 3 - }, { - "name": " classID;", - "count": 1 - }, { - "name": " className;", - "count": 1 - }, { - "name": " capacity;", - "count": 1 - }, { - "name": " queueNum;", - "count": 1 - }, { - "name": " studentAlreadyEnrolled;", - "count": 1 - }, { - "name": " studentID;", - "count": 1 - }, { - "name": " enrolledClass;", - "count": 1 - }, { - "name": " enrolledCap;", - "count": 1 - }, { - "name": " true;", - "count": 1 - }, { - "name": " false;", - "count": 2 - }, { - "name": " logic;", - "count": 1 - }, { - "name": " isAdmin;", - "count": 1 - }, { - "name": " addableClass;", - "count": 1 - }, { - "name": " wrapper;", - "count": 1 - }, { - "name": " enrollButton;", - "count": 1 - }, { - "name": " lastNameLabel;", - "count": 1 - }, { - "name": " removeClassButton;", - "count": 1 - }], - "langs": ["Java", "Java", "Java", "Java"] - } - }] -} \ No newline at end of file