Repository: yang991178/fluent-reader
Branch: master
Commit: feb64294682e
Files: 131
Total size: 1.1 MB
Directory structure:
gitextract_ma5b55aq/
├── .gitattributes
├── .github/
│ ├── FUNDING.yml
│ ├── ISSUE_TEMPLATE/
│ │ ├── bug_report.md
│ │ └── feature_request.md
│ └── workflows/
│ ├── release-linux.yml
│ └── release-main.yml
├── .gitignore
├── .prettierignore
├── .prettierrc.yml
├── .vscode/
│ └── launch.json
├── LICENSE
├── README.md
├── build/
│ ├── entitlements.mas.inherit.plist
│ ├── entitlements.mas.loginhelper.plist
│ ├── entitlements.mas.plist
│ ├── icon.icns
│ └── resignAndPackage.sh
├── dist/
│ ├── article/
│ │ ├── article.css
│ │ ├── article.html
│ │ ├── article.js
│ │ └── mercury.web.js
│ ├── fontlist
│ ├── fonts.vbs
│ ├── index.css
│ └── styles/
│ ├── cards.css
│ ├── dark.css
│ ├── feeds.css
│ ├── global.css
│ ├── main.css
│ └── scroll.css
├── docs/
│ ├── index.html
│ └── styles.css
├── electron-builder-mas.yml
├── electron-builder.yml
├── package.json
├── src/
│ ├── bridges/
│ │ ├── settings.ts
│ │ └── utils.ts
│ ├── components/
│ │ ├── article.tsx
│ │ ├── cards/
│ │ │ ├── card.tsx
│ │ │ ├── compact-card.tsx
│ │ │ ├── default-card.tsx
│ │ │ ├── highlights.tsx
│ │ │ ├── info.tsx
│ │ │ ├── list-card.tsx
│ │ │ └── magazine-card.tsx
│ │ ├── context-menu.tsx
│ │ ├── feeds/
│ │ │ ├── cards-feed.tsx
│ │ │ ├── feed.tsx
│ │ │ └── list-feed.tsx
│ │ ├── log-menu.tsx
│ │ ├── menu.tsx
│ │ ├── nav.tsx
│ │ ├── page.tsx
│ │ ├── root.tsx
│ │ ├── settings/
│ │ │ ├── about.tsx
│ │ │ ├── app.tsx
│ │ │ ├── groups.tsx
│ │ │ ├── rules.tsx
│ │ │ ├── service.tsx
│ │ │ ├── services/
│ │ │ │ ├── feedbin.tsx
│ │ │ │ ├── fever.tsx
│ │ │ │ ├── greader.tsx
│ │ │ │ ├── inoreader.tsx
│ │ │ │ ├── lite-exporter.tsx
│ │ │ │ ├── miniflux.tsx
│ │ │ │ └── nextcloud.tsx
│ │ │ └── sources.tsx
│ │ ├── settings.tsx
│ │ └── utils/
│ │ ├── ResizeObserver.d.ts
│ │ ├── article-search.tsx
│ │ ├── danger-button.tsx
│ │ └── time.tsx
│ ├── containers/
│ │ ├── article-container.tsx
│ │ ├── feed-container.tsx
│ │ ├── menu-container.tsx
│ │ ├── page-container.tsx
│ │ ├── settings/
│ │ │ ├── app-container.tsx
│ │ │ ├── groups-container.tsx
│ │ │ ├── rules-container.tsx
│ │ │ ├── service-container.tsx
│ │ │ └── sources-container.tsx
│ │ └── settings-container.tsx
│ ├── electron.ts
│ ├── index.html
│ ├── index.tsx
│ ├── main/
│ │ ├── settings.ts
│ │ ├── touchbar.ts
│ │ ├── update-scripts.ts
│ │ ├── utils.ts
│ │ └── window.ts
│ ├── preload.ts
│ ├── schema-types.ts
│ └── scripts/
│ ├── db.ts
│ ├── i18n/
│ │ ├── README.md
│ │ ├── _locales.ts
│ │ ├── cs.json
│ │ ├── de.json
│ │ ├── en-US.json
│ │ ├── es.json
│ │ ├── fi-FI.json
│ │ ├── fr-FR.json
│ │ ├── it.json
│ │ ├── ja.json
│ │ ├── ko.json
│ │ ├── nl.json
│ │ ├── pt-BR.json
│ │ ├── pt-PT.json
│ │ ├── ru.json
│ │ ├── sv.json
│ │ ├── tr.json
│ │ ├── uk.json
│ │ ├── zh-CN.json
│ │ └── zh-TW.json
│ ├── models/
│ │ ├── app.ts
│ │ ├── feed.ts
│ │ ├── group.ts
│ │ ├── item.ts
│ │ ├── page.ts
│ │ ├── rule.ts
│ │ ├── service.ts
│ │ ├── services/
│ │ │ ├── feedbin.ts
│ │ │ ├── fever.ts
│ │ │ ├── greader.ts
│ │ │ ├── miniflux.ts
│ │ │ └── nextcloud.ts
│ │ └── source.ts
│ ├── reducer.ts
│ ├── settings.ts
│ └── utils.ts
├── tsconfig.json
└── webpack.config.js
================================================
FILE CONTENTS
================================================
================================================
FILE: .gitattributes
================================================
dist/article/article.js text eol=lf
dist/article/mercury.web.js text eol=lf
================================================
FILE: .github/FUNDING.yml
================================================
# These are supported funding model platforms
github: ["yang991178"] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # "fluent-reader"
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
custom:
[
"https://www.paypal.me/yang991178",
"https://hyliu.me/fluent-reader/imgs/alipay.jpg",
]
================================================
FILE: .github/ISSUE_TEMPLATE/bug_report.md
================================================
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''
---
**Describe the bug**
A clear and concise description of what the bug is.
**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
**Expected behavior**
A clear and concise description of what you expected to happen.
**Screenshots**
If applicable, add screenshots to help explain your problem.
**Platform (please complete the following information):**
- OS: [e.g. Windows 10 2004]
- Version [e.g. 0.6.1]
**Additional context**
Add any other context about the problem here.
================================================
FILE: .github/ISSUE_TEMPLATE/feature_request.md
================================================
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''
---
**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
**Describe the solution you'd like**
A clear and concise description of what you want to happen.
**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.
**Additional context**
Add any other context or screenshots about the feature request here.
================================================
FILE: .github/workflows/release-linux.yml
================================================
name: CI/CD Release Linux
on:
release:
types:
- published
jobs:
release-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Build and package the app
run: |
npm install
npm run build
npm run package-linux
- name: Get app version
id: package-version
uses: martinbeentjes/npm-get-version-action@master
- name: Get release
id: get_release
uses: bruceadams/get-release@v1.2.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Upload AppImage to release assets
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.get_release.outputs.upload_url }}
asset_path: ./bin/linux/x64/Fluent Reader-${{ steps.package-version.outputs.current-version }}.AppImage
asset_name: Fluent.Reader.${{ steps.package-version.outputs.current-version }}.AppImage
asset_content_type: application/octet-stream
================================================
FILE: .github/workflows/release-main.yml
================================================
name: CI/CD Release
on:
push:
tags:
- "v*"
jobs:
release:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- name: Build and package the app
run: |
npm install
npm run build
npm run package-win-ci
- name: Get app version
id: package-version
run: |
PACKAGE_VERSION=$(cat package.json | grep version | head -1 | awk -F: '{ print $2 }' | sed 's/[",]//g' | tr -d '[[:space:]]')
echo ::set-output name=current-version::$PACKAGE_VERSION
shell: bash
- name: Create release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Fluent Reader v${{ steps.package-version.outputs.current-version }}
draft: true
prerelease: false
- name: Upload x64 exe to release assets
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./bin/win32/x64/Fluent Reader Setup ${{ steps.package-version.outputs.current-version }}.exe
asset_name: Fluent.Reader.Setup.${{ steps.package-version.outputs.current-version }}.x64.exe
asset_content_type: application/vnd.microsoft.portable-executable
- name: Upload x86 exe to release assets
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./bin/win32/ia32/Fluent Reader Setup ${{ steps.package-version.outputs.current-version }}.exe
asset_name: Fluent.Reader.Setup.${{ steps.package-version.outputs.current-version }}.x86.exe
asset_content_type: application/vnd.microsoft.portable-executable
- name: Upload x64 zip to release assets
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./bin/win32/x64/Fluent Reader-${{ steps.package-version.outputs.current-version }}-win.zip
asset_name: Fluent.Reader.Unpacked.${{ steps.package-version.outputs.current-version }}.x64.zip
asset_content_type: application/zip
- name: Upload x86 zip to release assets
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./bin/win32/ia32/Fluent Reader-${{ steps.package-version.outputs.current-version }}-ia32-win.zip
asset_name: Fluent.Reader.Unpacked.${{ steps.package-version.outputs.current-version }}.x86.zip
asset_content_type: application/zip
================================================
FILE: .gitignore
================================================
node_modules
dist/*.js
dist/*.js.map
dist/*.html
dist/*.LICENSE.txt
bin/*
.DS_Store
*.provisionprofile
*.lock
================================================
FILE: .prettierignore
================================================
node_modules
dist/**/*.js
dist/**/*.js.map
bin/*
.DS_Store
*.provisionprofile
*.lock
*.html
*.md
*.json
!src/**/*.json
================================================
FILE: .prettierrc.yml
================================================
tabWidth: 4
semi: false
jsxBracketSameLine: true
arrowParens: "avoid"
quoteProps: "consistent"
================================================
FILE: .vscode/launch.json
================================================
{
"version": "0.2.0",
"configurations": [
{
"name": "Debug Main Process",
"type": "node",
"request": "launch",
"cwd": "${workspaceRoot}",
"runtimeExecutable": "${workspaceRoot}/node_modules/.bin/electron",
"windows": {
"runtimeExecutable": "${workspaceRoot}/node_modules/.bin/electron.cmd"
},
"program": "${workspaceRoot}/dist/electron.js",
"args" : ["."],
"outputCapture": "std",
"sourceMaps": true
}
]
}
================================================
FILE: LICENSE
================================================
BSD 3-Clause License
Copyright (c) 2020, Haoyuan Liu
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Neither the name of the copyright holder nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
================================================
FILE: README.md
================================================
Fluent Reader
A modern desktop RSS reader
## Download
For Windows 10 users, the recommended way of installation is through [Microsoft Store](https://www.microsoft.com/store/apps/9P71FC94LRH8?cid=github).
This enables auto-update and experimental ARM64 support.
macOS users can also get Fluent Reader from the [Mac App Store](https://apps.apple.com/app/id1520907427).
If you are using Linux or an older version of Windows, you can [get Fluent Reader from GitHub releases](https://github.com/yang991178/fluent-reader/releases).
### Mobile App
The repo of the mobile version of this app [can be found here](https://github.com/yang991178/fluent-reader-lite).
## Features
- A modern UI inspired by Fluent Design System with full dark mode support.
- Read locally or sync with self-hosted services compatible with Fever or Google Reader API.
- Sync with RSS Services including Inoreader, Feedbin, The Old Reader, BazQux Reader, and more.
- Importing or exporting OPML files, full application data backup & restoration.
- Read the full content with the built-in article view or load webpages by default.
- Search for articles with regular expressions or filter by read status.
- Organize your subscriptions with folder-like groupings.
- Single-key [keyboard shortcuts](https://github.com/yang991178/fluent-reader/wiki/Support#keyboard-shortcuts).
- Hide, mark as read, or star articles automatically as they arrive with regular expression rules.
- Fetch articles in the background and send push notifications.
Support for other RSS services are [under fundraising](https://github.com/yang991178/fluent-reader/issues/23).
## Development
### Contribute
Help make Fluent Reader better by reporting bugs or opening feature requests through [GitHub issues](https://github.com/yang991178/fluent-reader/issues).
You can also help internationalize the app by providing [translations into additional languages](https://github.com/yang991178/fluent-reader/tree/master/src/scripts/i18n).
Refer to the repo of [react-intl-universal](https://github.com/alibaba/react-intl-universal) to get started on internationalization.
If you enjoy using this app, consider supporting its development by donating through [GitHub Sponsors](https://github.com/sponsors/yang991178), [Paypal](https://www.paypal.me/yang991178), or [Alipay](https://hyliu.me/fluent-reader/imgs/alipay.jpg).
### Build from source
```bash
# Install dependencies
npm install
# Compile ts & dependencies
npm run build
# Start the application
npm run electron
# Generate certificate for signature
electron-builder create-self-signed-cert
# Package the app for Windows
npm run package-win
```
### Developed with
- [Electron](https://github.com/electron/electron)
- [React](https://github.com/facebook/react)
- [Redux](https://github.com/reduxjs/redux)
- [Fluent UI](https://github.com/microsoft/fluentui)
- [Lovefield](https://github.com/google/lovefield)
- [Mercury Parser](https://github.com/postlight/mercury-parser)
### License
BSD
================================================
FILE: build/entitlements.mas.inherit.plist
================================================
com.apple.security.app-sandbox
com.apple.security.inherit
com.apple.security.cs.allow-jit
com.apple.security.cs.allow-unsigned-executable-memory
================================================
FILE: build/entitlements.mas.loginhelper.plist
================================================
com.apple.security.app-sandbox
================================================
FILE: build/entitlements.mas.plist
================================================
com.apple.security.app-sandbox
com.apple.security.application-groups
EM8VE646TZ.DevHYLiu.FluentReader
com.apple.security.network.client
com.apple.security.files.user-selected.read-write
com.apple.security.files.user-selected.read-only
com.apple.security.cs.allow-jit
com.apple.security.cs.allow-unsigned-executable-memory
com.apple.security.cs.allow-dyld-environment-variables
================================================
FILE: build/resignAndPackage.sh
================================================
# Name of your app.
APP="Fluent Reader"
# Your Certificate name.
CERT="Jieyu Yan (EM8VE646TZ)"
# The path of your app to sign.
APP_PATH="bin/darwin/universal/mas-universal/Fluent Reader.app"
# The path to the location you want to put the signed package.
RESULT_PATH="bin/$APP-mac_store.pkg"
# The name of certificates you requested.
APP_KEY="Apple Distribution: $CERT"
INSTALLER_KEY="3rd Party Mac Developer Installer: $CERT"
# The path of your plist files.
PARENT_PLIST="build/entitlements.mas.plist"
CHILD_PLIST="build/entitlements.mas.inherit.plist"
LOGINHELPER_PLIST="build/entitlements.mas.loginhelper.plist"
FRAMEWORKS_PATH="$APP_PATH/Contents/Frameworks"
# Build universal binary for font-list
# FONTLIST_PATH="node_modules/font-list/libs/darwin/fontlist.m"
# clang -arch arm64 -arch x86_64 "$FONTLIST_PATH" -fmodules -o "dist/fontlist"
# Build the MAS app
CSC_IDENTITY_AUTO_DISCOVERY=false npx electron-builder -c electron-builder-mas.yml --mac mas:universal
# Add ElectronTeamID to Info.plist
sed -i '' -e 's/<\/dict>/ElectronTeamID<\/key>EM8VE646TZ<\/string><\/dict>/g' "bin/darwin/universal/mas-universal/Fluent Reader.app/Contents/Info.plist"
printf "......................\nresignAndPackage start\n\n"
codesign --deep --force --verify --verbose=4 --timestamp --options runtime --entitlements "$CHILD_PLIST" -s "$APP_KEY" "$APP_PATH/Contents/Resources/app.asar.unpacked/dist/fontlist"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Electron Framework"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Libraries/libEGL.dylib"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Libraries/libGLESv2.dylib"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Libraries/libswiftshader_libEGL.dylib"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Libraries/libswiftshader_libGLESv2.dylib"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Libraries/libvk_swiftshader.dylib"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Libraries/libffmpeg.dylib"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Libraries/libffmpeg.dylib"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper.app/Contents/MacOS/$APP Helper"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper.app/"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper (GPU).app/Contents/MacOS/$APP Helper (GPU)"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper (GPU).app/"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper (Renderer).app/Contents/MacOS/$APP Helper (Renderer)"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper (Renderer).app/"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper (Plugin).app/Contents/MacOS/$APP Helper (Plugin)"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper (Plugin).app/"
codesign -s "$APP_KEY" -f --entitlements "$LOGINHELPER_PLIST" "$APP_PATH/Contents/Library/LoginItems/$APP Login Helper.app/Contents/MacOS/$APP Login Helper"
codesign -s "$APP_KEY" -f --entitlements "$LOGINHELPER_PLIST" "$APP_PATH/Contents/Library/LoginItems/$APP Login Helper.app/"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$APP_PATH/Contents/MacOS/$APP"
codesign -s "$APP_KEY" -f --entitlements "$PARENT_PLIST" "$APP_PATH"
productbuild --component "$APP_PATH" /Applications --sign "$INSTALLER_KEY" "$RESULT_PATH"
printf "\nresignAndPackage end\n......................\n"
================================================
FILE: dist/article/article.css
================================================
@import "../styles/scroll.css";
html,
body {
margin: 0;
font-family: "Segoe UI", "Source Han Sans Regular", sans-serif;
}
body {
padding: 12px 96px 32px;
overflow: hidden scroll;
}
body.rtl {
direction: rtl;
}
body.vertical {
padding: 32px;
padding-right: 96px;
writing-mode: vertical-rl;
overflow: scroll hidden;
}
:root {
--gray: #484644;
--primary: #0078d4;
--primary-alt: #004578;
}
@media (prefers-color-scheme: dark) {
:root {
color: #f8f8f8;
--gray: #a19f9d;
--primary: #4ba0e1;
--primary-alt: #65aee6;
}
}
h1,
h2,
h3,
h4,
h5,
h6,
b,
strong {
font-weight: 600;
}
a {
color: var(--primary);
text-decoration: none;
}
a:hover,
a:active {
color: var(--primary-alt);
text-decoration: underline;
}
@keyframes fadeIn {
0% {
opacity: 0;
transform: translateY(10px);
}
100% {
opacity: 1;
transform: translateY(0);
}
}
#main {
max-width: 700px;
margin: 0 auto;
display: none;
}
body.vertical #main {
max-width: unset;
max-height: 700px;
margin: auto 0;
}
#main.show {
display: block;
animation-name: fadeIn;
animation-duration: 0.367s;
animation-timing-function: cubic-bezier(0.1, 0.9, 0.2, 1);
animation-fill-mode: both;
}
#main > p.title {
font-size: 1.25rem;
line-height: 1.75rem;
font-weight: 600;
margin-block-end: 0;
}
#main > p.date {
color: var(--gray);
font-size: 0.875rem;
}
article {
line-height: 1.6;
}
body.vertical article {
line-height: 1.5;
}
body.vertical article p {
text-indent: 2rem;
}
article * {
max-width: 100%;
}
article img {
height: auto;
}
body.vertical article img {
max-height: 75%;
}
article figure {
margin: 16px 0;
text-align: center;
}
article figure figcaption {
font-size: 0.875rem;
color: var(--gray);
-webkit-user-modify: read-only;
}
article iframe {
width: 100%;
}
article code {
font-family: Monaco, Consolas, monospace;
font-size: 0.875rem;
line-height: 1;
}
article pre {
word-break: normal;
overflow-wrap: normal;
white-space: pre-wrap;
}
article blockquote {
border-left: 2px solid var(--gray);
margin: 1em 0;
padding: 0 40px;
}
================================================
FILE: dist/article/article.html
================================================
Article
================================================
FILE: dist/article/article.js
================================================
function get(name) {
if (name = (new RegExp('[?&]' + encodeURIComponent(name) + '=([^&]*)')).exec(location.search))
return decodeURIComponent(name[1]);
}
let dir = get("d")
if (dir === "1") {
document.body.classList.add("rtl")
} else if (dir === "2") {
document.body.classList.add("vertical")
document.body.addEventListener("wheel", (evt) => {
document.scrollingElement.scrollLeft -= evt.deltaY;
});
}
async function getArticle(url) {
let article = get("a")
if (get("m") === "1") {
return (await Mercury.parse(url, {html: article})).content || ""
} else {
return article
}
}
document.documentElement.style.fontSize = get("s") + "px"
let font = get("f")
if (font) document.body.style.fontFamily = `"${font}"`
let url = get("u")
getArticle(url).then(article => {
let domParser = new DOMParser()
let dom = domParser.parseFromString(get("h"), "text/html")
dom.getElementsByTagName("article")[0].innerHTML = article
let baseEl = dom.createElement('base')
baseEl.setAttribute('href', url.split("/").slice(0, 3).join("/"))
dom.head.append(baseEl)
for (let s of dom.getElementsByTagName("script")) {
s.parentNode.removeChild(s)
}
for (let e of dom.querySelectorAll("*[src]")) {
e.src = e.src
}
for (let e of dom.querySelectorAll("*[href]")) {
e.href = e.href
}
let main = document.getElementById("main")
main.innerHTML = dom.body.innerHTML
main.classList.add("show")
})
================================================
FILE: dist/article/mercury.web.js
================================================
var Mercury=function(){"use strict";function $n(){throw new Error("Dynamic requires are not currently supported by rollup-plugin-commonjs")}function e(e,t){return e(t={exports:{}},t.exports),t.exports}var t=e(function(O){!function(e){var u,t=Object.prototype,c=t.hasOwnProperty,n="function"==typeof Symbol?Symbol:{},a=n.iterator||"@@iterator",r=n.asyncIterator||"@@asyncIterator",i=n.toStringTag||"@@toStringTag",o=e.regeneratorRuntime;if(o)O.exports=o;else{(o=e.regeneratorRuntime=O.exports).wrap=y;var f="suspendedStart",h="suspendedYield",d="executing",p="completed",m={},s={};s[a]=function(){return this};var l=Object.getPrototypeOf,g=l&&l(l(C([])));g&&g!==t&&c.call(g,a)&&(s=g);var v=A.prototype=b.prototype=Object.create(s);w.prototype=v.constructor=A,A.constructor=w,A[i]=w.displayName="GeneratorFunction",o.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===w||"GeneratorFunction"===(t.displayName||t.name))},o.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,A):(e.__proto__=A,i in e||(e[i]="GeneratorFunction")),e.prototype=Object.create(v),e},o.awrap=function(e){return{__await:e}},x(k.prototype),k.prototype[r]=function(){return this},o.AsyncIterator=k,o.async=function(e,t,n,r){var a=new k(y(e,t,n,r));return o.isGeneratorFunction(t)?a:a.next().then(function(e){return e.done?e.value:a.next()})},x(v),v[i]="Generator",v[a]=function(){return this},v.toString=function(){return"[object Generator]"},o.keys=function(n){var r=[];for(var e in n)r.push(e);return r.reverse(),function e(){for(;r.length;){var t=r.pop();if(t in n)return e.value=t,e.done=!1,e}return e.done=!0,e}},o.values=C,T.prototype={constructor:T,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=u,this.done=!1,this.delegate=null,this.method="next",this.arg=u,this.tryEntries.forEach(M),!e)for(var t in this)"t"===t.charAt(0)&&c.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=u)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(n){if(this.done)throw n;var r=this;function e(e,t){return i.type="throw",i.arg=n,r.next=e,t&&(r.method="next",r.arg=u),!!t}for(var t=this.tryEntries.length-1;0<=t;--t){var a=this.tryEntries[t],i=a.completion;if("root"===a.tryLoc)return e("end");if(a.tryLoc<=this.prev){var o=c.call(a,"catchLoc"),s=c.call(a,"finallyLoc");if(o&&s){if(this.preva;)m(r,n=t[a++])&&(~le(i,n)||i.push(n));return i},de="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(","),pe=Object.keys||function(e){return he(e,de)},me={f:Object.getOwnPropertySymbols},ge=Array.isArray||function(e){return"Array"==s(e)},ve=v?Object.defineProperties:function(e,t){D(e);for(var n,r=pe(t),a=r.length,i=0;idocument.F=Object<\/script>"),e.close(),xe=e.F;n--;)delete xe[Ae][de[n]];return xe()},ke=Object.create||function(e,t){var n;return null!==e?(we[Ae]=D(e),n=new we,we[Ae]=null,n[be]=e):n=xe(),void 0===t?n:ve(n,t)},Ee=de.concat("length","prototype"),Se={f:Object.getOwnPropertyNames||function(e){return he(e,Ee)}},Me=Se.f,Te={}.toString,Ce="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],De={f:function(e){return Ce&&"[object Window]"==Te.call(e)?function(e){try{return Me(e)}catch(e){return Ce.slice()}}(e):Me(c(e))}},Oe=U.KEY,je=E.f,Ne=j.f,ze=De.f,Pe=y.Symbol,Le=y.JSON,Re=Le&&Le.stringify,Ye="prototype",We=V("_hidden"),qe=V("toPrimitive"),Ie={}.propertyIsEnumerable,He=$("symbol-registry"),Fe=$("symbols"),Be=$("op-symbols"),Ge=Object[Ye],Ue="function"==typeof Pe,$e=y.QObject,Ve=!$e||!$e[Ye]||!$e[Ye].findChild,Je=v&&g(function(){return 7!=ke(Ne({},"a",{get:function(){return Ne(this,"a",{value:7}).a}})).a})?function(e,t,n){var r=je(Ge,t);r&&delete Ge[t],Ne(e,t,n),r&&e!==Ge&&Ne(Ge,t,r)}:Ne,Ke=function(e){var t=Fe[e]=ke(Pe[Ye]);return t._k=e,t},Xe=Ue&&"symbol"==typeof Pe.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof Pe},Ze=function(e,t,n){return e===Ge&&Ze(Be,t,n),D(e),t=f(t,!0),D(n),m(Fe,t)?(n.enumerable?(m(e,We)&&e[We][t]&&(e[We][t]=!1),n=ke(n,{enumerable:A(0,!1)})):(m(e,We)||Ne(e,We,A(1,{})),e[We][t]=!0),Je(e,t,n)):Ne(e,t,n)},Qe=function(e,t){D(e);for(var n,r=function(e){var t=pe(e),n=me.f;if(n)for(var r,a=n(e),i=d.f,o=0;a.length>o;)i.call(e,r=a[o++])&&t.push(r);return t}(t=c(t)),a=0,i=r.length;aa;)m(Fe,t=n[a++])||t==We||t==Oe||r.push(t);return r},rt=function(e){for(var t,n=e===Ge,r=ze(n?Be:c(e)),a=[],i=0;r.length>i;)!m(Fe,t=r[i++])||n&&!m(Ge,t)||a.push(Fe[t]);return a};Ue||(H((Pe=function(){if(this instanceof Pe)throw TypeError("Symbol is not a constructor!");var t=G(0it;)V(at[it++]);for(var ot=pe(V.store),st=0;ot.length>st;)ee(ot[st++]);L(L.S+L.F*!Ue,"Symbol",{for:function(e){return m(He,e+="")?He[e]:He[e]=Pe(e)},keyFor:function(e){if(!Xe(e))throw TypeError(e+" is not a symbol!");for(var t in He)if(He[t]===e)return t},useSetter:function(){Ve=!0},useSimple:function(){Ve=!1}}),L(L.S+L.F*!Ue,"Object",{create:function(e,t){return void 0===t?ke(e):Qe(ke(e),t)},defineProperty:Ze,defineProperties:Qe,getOwnPropertyDescriptor:tt,getOwnPropertyNames:nt,getOwnPropertySymbols:rt}),Le&&L(L.S+L.F*(!Ue||g(function(){var e=Pe();return"[null]"!=Re([e])||"{}"!=Re({a:e})||"{}"!=Re(Object(e))})),"JSON",{stringify:function(e){for(var t,n,r=[e],a=1;arguments.length>a;)r.push(arguments[a++]);if(n=t=r[1],(l(t)||void 0!==e)&&!Xe(e))return ge(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!Xe(t))return t}),r[1]=t,Re.apply(Le,r)}}),Pe[Ye][qe]||N(Pe[Ye],qe,Pe[Ye].valueOf),X(Pe,"Symbol"),X(Math,"Math",!0),X(y.JSON,"JSON",!0);var ut=M.Object.getOwnPropertySymbols,ct=function(e){return Object(u(e))};R("keys",function(){return function(e){return pe(ct(e))}});var lt=M.Object.keys;L(L.S+L.F*!v,"Object",{defineProperty:j.f});var ft=M.Object,ht=function(e,t,n){return ft.defineProperty(e,t,n)};var dt=function(e,t,n){return t in e?ht(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e};var pt=function(t){for(var e=1;e=t.length?{value:void 0,done:!0}:(e=Tt(t,n),this._i+=e.length,{value:e,done:!1})});var Ct=function(e,t){return{value:t,done:!!e}};Mt(Array,"Array",function(e,t){this._t=c(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,Ct(1)):Ct(0,"keys"==t?n:"values"==t?e[n]:[n,e[n]])},"values");vt.Arguments=vt.Array;for(var Dt=V("toStringTag"),Ot="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),jt=0;jtn;)t.push(arguments[n++]);return an[++rn]=function(){!function(e,t,n){var r=void 0===n;switch(t.length){case 0:return r?e():e.call(n);case 1:return r?e(t[0]):e.call(n,t[0]);case 2:return r?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}e.apply(n,t)}("function"==typeof e?e:Function(e),t)},Lt(rn),rn},en=function(e){delete an[e]},"process"==s(Zt)?Lt=function(e){Zt.nextTick(C(sn,e,1))}:nn&&nn.now?Lt=function(e){nn.now(C(sn,e,1))}:tn?(Yt=(Rt=new tn).port2,Rt.port1.onmessage=un,Lt=C(Yt.postMessage,Yt,1)):y.addEventListener&&"function"==typeof postMessage&&!y.importScripts?(Lt=function(e){y.postMessage(e+"","*")},y.addEventListener("message",un,!1)):Lt=on in w("script")?function(e){_e.appendChild(w("script"))[on]=function(){_e.removeChild(this),sn.call(e)}}:function(e){setTimeout(C(sn,e,1),0)});var cn={set:Qt,clear:en},ln=cn.set,fn=y.MutationObserver||y.WebKitMutationObserver,hn=y.process,dn=y.Promise,pn="process"==s(hn);function mn(e){var n,r;this.promise=new e(function(e,t){if(void 0!==n||void 0!==r)throw TypeError("Bad Promise constructor");n=e,r=t}),this.resolve=T(n),this.reject=T(r)}var gn={f:function(e){return new mn(e)}},vn=function(e){try{return{e:!1,v:e()}}catch(e){return{e:!0,v:e}}},yn=y.navigator,_n=yn&&yn.userAgent||"",bn=function(e,t){if(D(e),l(t)&&t.constructor===e)return t;var n=gn.f(e);return(0,n.resolve)(t),n.promise},wn=function(e,t,n){for(var r in t)n&&e[r]?e[r]=t[r]:N(e,r,t[r]);return e},An=V("species"),xn=function(e){var t="function"==typeof M[e]?M[e]:y[e];v&&t&&!t[An]&&j.f(t,An,{configurable:!0,get:function(){return this}})},kn=V("iterator"),En=!1;try{[7][kn]().return=function(){En=!0}}catch(e){}var Sn,Mn,Tn,Cn,Dn=function(e,t){if(!t&&!En)return!1;var n=!1;try{var r=[7],a=r[kn]();a.next=function(){return{done:n=!0}},r[kn]=function(){return a},e(r)}catch(e){}return n},On=cn.set,jn=function(){var n,r,a,e=function(){var e,t;for(pn&&(e=hn.domain)&&e.exit();n;){t=n.fn,n=n.next;try{t()}catch(e){throw n?a():r=void 0,e}}r=void 0,e&&e.enter()};if(pn)a=function(){hn.nextTick(e)};else if(!fn||y.navigator&&y.navigator.standalone)if(dn&&dn.resolve){var t=dn.resolve(void 0);a=function(){t.then(e)}}else a=function(){ln.call(y,e)};else{var i=!0,o=document.createTextNode("");new fn(e).observe(o,{characterData:!0}),a=function(){o.data=i=!i}}return function(e){var t={fn:e,next:void 0};r&&(r.next=t),n||(n=t,a()),r=t}}(),Nn="Promise",zn=y.TypeError,Pn=y.process,Ln=Pn&&Pn.versions,Rn=Ln&&Ln.v8||"",Yn=y[Nn],Wn="process"==It(Pn),qn=function(){},In=Mn=gn.f,Hn=!!function(){try{var e=Yn.resolve(1),t=(e.constructor={})[V("species")]=function(e){e(qn,qn)};return(Wn||"function"==typeof PromiseRejectionEvent)&&e.then(qn)instanceof t&&0!==Rn.indexOf("6.6")&&-1===_n.indexOf("Chrome/66")}catch(e){}}(),Fn=function(e){var t;return!(!l(e)||"function"!=typeof(t=e.then))&&t},Bn=function(l,n){if(!l._n){l._n=!0;var r=l._c;jn(function(){for(var u=l._v,c=1==l._s,e=0,t=function(e){var t,n,r,a=c?e.ok:e.fail,i=e.resolve,o=e.reject,s=e.domain;try{a?(c||(2==l._h&&Vn(l),l._h=1),!0===a?t=u:(s&&s.enter(),t=a(u),s&&(s.exit(),r=!0)),t===e.promise?o(zn("Promise-chain cycle")):(n=Fn(t))?n.call(t,i,o):i(t)):o(u)}catch(e){s&&!r&&s.exit(),o(e)}};r.length>e;)t(r[e++]);l._c=[],l._n=!1,n&&!l._h&&Gn(l)})}},Gn=function(i){On.call(y,function(){var e,t,n,r=i._v,a=Un(i);if(a&&(e=vn(function(){Wn?Pn.emit("unhandledRejection",r,i):(t=y.onunhandledrejection)?t({promise:i,reason:r}):(n=y.console)&&n.error&&n.error("Unhandled promise rejection",r)}),i._h=Wn||Un(i)?2:1),i._a=void 0,a&&e.e)throw e.v})},Un=function(e){return 1!==e._h&&0===(e._a||e._c).length},Vn=function(t){On.call(y,function(){var e;Wn?Pn.emit("rejectionHandled",t):(e=y.onrejectionhandled)&&e({promise:t,reason:t._v})})},Jn=function(e){var t=this;t._d||(t._d=!0,(t=t._w||t)._v=e,t._s=2,t._a||(t._a=t._c.slice()),Bn(t,!0))},Kn=function(e){var n,r=this;if(!r._d){r._d=!0,r=r._w||r;try{if(r===e)throw zn("Promise can't be resolved itself");(n=Fn(e))?jn(function(){var t={_w:r,_d:!1};try{n.call(e,C(Kn,t,1),C(Jn,t,1))}catch(e){Jn.call(t,e)}}):(r._v=e,r._s=1,Bn(r,!1))}catch(e){Jn.call({_w:r,_d:!1},e)}}};Hn||(Yn=function(e){Ht(this,Yn,Nn,"_h"),T(e),Sn.call(this);try{e(C(Kn,this,1),C(Jn,this,1))}catch(e){Jn.call(this,e)}},(Sn=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=wn(Yn.prototype,{then:function(e,t){var n=In(Xt(this,Yn));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=Wn?Pn.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&Bn(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),Tn=function(){var e=new Sn;this.promise=e,this.resolve=C(Kn,e,1),this.reject=C(Jn,e,1)},gn.f=In=function(e){return e===Yn||e===Cn?new Tn(e):Mn(e)}),L(L.G+L.W+L.F*!Hn,{Promise:Yn}),X(Yn,Nn),xn(Nn),Cn=M[Nn],L(L.S+L.F*!Hn,Nn,{reject:function(e){var t=In(this);return(0,t.reject)(e),t.promise}}),L(L.S+!0*L.F,Nn,{resolve:function(e){return bn(this===Cn?Yn:this,e)}}),L(L.S+L.F*!(Hn&&Dn(function(e){Yn.all(e).catch(qn)})),Nn,{all:function(e){var o=this,t=In(o),s=t.resolve,u=t.reject,n=vn(function(){var r=[],a=0,i=1;Jt(e,!1,function(e){var t=a++,n=!1;r.push(void 0),i++,o.resolve(e).then(function(e){n||(n=!0,r[t]=e,--i||s(r))},u)}),--i||s(r)});return n.e&&u(n.v),t.promise},race:function(e){var t=this,n=In(t),r=n.reject,a=vn(function(){Jt(e,!1,function(e){t.resolve(e).then(n.resolve,r)})});return a.e&&r(a.v),n.promise}}),L(L.P+L.R,"Promise",{finally:function(t){var n=Xt(this,M.Promise||y.Promise),e="function"==typeof t;return this.then(e?function(e){return bn(n,t()).then(function(){return e})}:t,e?function(e){return bn(n,t()).then(function(){throw e})}:t)}}),L(L.S,"Promise",{try:function(e){var t=gn.f(this),n=vn(e);return(n.e?t.reject:t.resolve)(n.v),t.promise}});var Xn=M.Promise;function Zn(e,t,n,r,a,i,o){try{var s=e[i](o),u=s.value}catch(e){return void n(e)}s.done?t(u):Xn.resolve(u).then(r,a)}var Qn=function(s){return function(){var e=this,o=arguments;return new Xn(function(t,n){var r=s.apply(e,o);function a(e){Zn(r,t,n,a,i,"next",e)}function i(e){Zn(r,t,n,a,i,"throw",e)}a(void 0)})}},er="undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},tr=e(function(O,j){!function(e){var t=j&&!j.nodeType&&j,n=O&&!O.nodeType&&O,r="object"==typeof er&&er;r.global!==r&&r.window!==r&&r.self!==r||(e=r);var a,i,v=2147483647,y=36,_=1,b=26,o=38,s=700,w=72,A=128,x="-",u=/^xn--/,c=/[^\x20-\x7E]/,l=/[\x2E\u3002\uFF0E\uFF61]/g,f={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},h=y-_,k=Math.floor,E=String.fromCharCode;function S(e){throw RangeError(f[e])}function d(e,t){for(var n=e.length,r=[];n--;)r[n]=t(e[n]);return r}function p(e,t){var n=e.split("@"),r="";return 1>>10&1023|55296),e=56320|1023&e),t+=E(e)}).join("")}function C(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function D(e,t,n){var r=0;for(e=n?k(e/s):e>>1,e+=k(e/t);h*b>>1k((v-p)/o))&&S("overflow"),p+=u*o,!(u<(c=s<=g?_:g+b<=s?b:s-g));s+=y)o>k(v/(l=y-c))&&S("overflow"),o*=l;g=D(p-i,t=h.length+1,0==i),k(p/t)>v-m&&S("overflow"),m+=k(p/t),p%=t,h.splice(p++,0,m)}return T(h)}function g(e){var t,n,r,a,i,o,s,u,c,l,f,h,d,p,m,g=[];for(h=(e=M(e)).length,t=A,i=w,o=n=0;ok((v-n)/(d=r+1))&&S("overflow"),n+=(s-t)*d,t=s,o=0;ov&&S("overflow"),f==t){for(u=n,c=y;!(u<(l=c<=i?_:i+b<=c?b:c-i));c+=y)m=u-l,p=y-l,g.push(E(C(l+m%p,0))),u=k(m/p);g.push(E(C(u,0))),i=D(n,d,r==a),n=0,++r}++n,++t}return g.join("")}if(a={version:"1.3.2",ucs2:{decode:M,encode:T},decode:m,encode:g,toASCII:function(e){return p(e,function(e){return c.test(e)?"xn--"+g(e):e})},toUnicode:function(e){return p(e,function(e){return u.test(e)?m(e.slice(4).toLowerCase()):e})}},t&&n)if(O.exports==t)n.exports=a;else for(i in a)a.hasOwnProperty(i)&&(t[i]=a[i]);else e.punycode=a}(this)}),nr={isString:function(e){return"string"==typeof e},isObject:function(e){return"object"==typeof e&&null!==e},isNull:function(e){return null===e},isNullOrUndefined:function(e){return null==e}};var rr=function(e,t,n,r){t=t||"&",n=n||"=";var a={};if("string"!=typeof e||0===e.length)return a;var i=/\+/g;e=e.split(t);var o=1e3;r&&"number"==typeof r.maxKeys&&(o=r.maxKeys);var s,u,c=e.length;0",'"',"`"," ","\r","\n","\t"]),vr=["'"].concat(gr),yr=["%","/","?",";","#"].concat(vr),_r=["/","?","#"],br=/^[+a-z0-9A-Z_-]{0,63}$/,wr=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,Ar={javascript:!0,"javascript:":!0},xr={javascript:!0,"javascript:":!0},kr={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};function Er(e,t,n){if(e&&nr.isObject(e)&&e instanceof hr)return e;var r=new hr;return r.parse(e,t,n),r}hr.prototype.parse=function(e,t,n){if(!nr.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var r=e.indexOf("?"),a=-1!==r&&r+~]|"+R+")"+R+"*"),G=new RegExp(R+"|>"),U=new RegExp(q),$=new RegExp("^"+Y+"$"),V={ID:new RegExp("^#("+Y+")"),CLASS:new RegExp("^\\.("+Y+")"),TAG:new RegExp("^("+Y+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+q),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+R+"*(even|odd|(([+-]|)(\\d*)n|)"+R+"*(?:([+-]|)"+R+"*(\\d+)|))"+R+"*\\)|)","i"),bool:new RegExp("^(?:"+L+")$","i"),needsContext:new RegExp("^"+R+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+R+"*((?:-\\d)?\\d*)"+R+"*\\)|)(?=[^-]|$)","i")},J=/HTML$/i,K=/^(?:input|select|textarea|button)$/i,X=/^h\d$/i,Z=/^[^{]+\{\s*\[native \w/,Q=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\([\\da-f]{1,6}"+R+"?|("+R+")|.)","ig"),ne=function(e,t,n){var r="0x"+t-65536;return r!=r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ae=function(e,t){return t?"\0"===e?"�":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},ie=function(){A()},oe=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{N.apply(t=z.call(y.childNodes),y.childNodes),t[y.childNodes.length].nodeType}catch(e){N={apply:t.length?function(e,t){j.apply(e,z.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}function se(e,t,n,r){var a,i,o,s,u,c,l,f=t&&t.ownerDocument,h=t?t.nodeType:9;if(n=n||[],"string"!=typeof e||!e||1!==h&&9!==h&&11!==h)return n;if(!r&&((t?t.ownerDocument||t:y)!==x&&A(t),t=t||x,k)){if(11!==h&&(u=Q.exec(e)))if(a=u[1]){if(9===h){if(!(o=t.getElementById(a)))return n;if(o.id===a)return n.push(o),n}else if(f&&(o=f.getElementById(a))&&v(t,o)&&o.id===a)return n.push(o),n}else{if(u[2])return N.apply(n,t.getElementsByTagName(e)),n;if((a=u[3])&&d.getElementsByClassName&&t.getElementsByClassName)return N.apply(n,t.getElementsByClassName(a)),n}if(d.qsa&&!T[e+" "]&&(!g||!g.test(e))&&(1!==h||"object"!==t.nodeName.toLowerCase())){if(l=e,f=t,1===h&&G.test(e)){for((s=t.getAttribute("id"))?s=s.replace(re,ae):t.setAttribute("id",s=E),i=(c=p(e)).length;i--;)c[i]="#"+s+" "+_e(c[i]);l=c.join(","),f=ee.test(e)&&ve(t.parentNode)||t}try{return N.apply(n,f.querySelectorAll(l)),n}catch(t){T(e,!0)}finally{s===E&&t.removeAttribute("id")}}}return m(e.replace(H,"$1"),t,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 ce(e){return e[E]=!0,e}function le(e){var t=x.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){for(var n=e.split("|"),r=n.length;r--;)b.attrHandle[n[r]]=t}function he(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)for(;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 pe(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function me(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&&oe(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ge(o){return ce(function(i){return i=+i,ce(function(e,t){for(var n,r=o([],e.length,i),a=r.length;a--;)e[n=r[a]]&&(e[n]=!(t[n]=e[n]))})})}function ve(e){return e&&void 0!==e.getElementsByTagName&&e}for(e in d=se.support={},a=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!J.test(t||n&&n.nodeName||"HTML")},A=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:y;return r!==x&&9===r.nodeType&&r.documentElement&&(o=(x=r).documentElement,k=!a(x),y!==x&&(n=x.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",ie,!1):n.attachEvent&&n.attachEvent("onunload",ie)),d.attributes=le(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=le(function(e){return e.appendChild(x.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=Z.test(x.getElementsByClassName),d.getById=le(function(e){return o.appendChild(e).id=E,!x.getElementsByName||!x.getElementsByName(E).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(void 0!==t.getElementById&&k){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t=void 0!==e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if(void 0!==t.getElementById&&k){var n,r,a,i=t.getElementById(e);if(i){if((n=i.getAttributeNode("id"))&&n.value===e)return[i];for(a=t.getElementsByName(e),r=0;i=a[r++];)if((n=i.getAttributeNode("id"))&&n.value===e)return[i]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return void 0!==t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],a=0,i=t.getElementsByTagName(e);if("*"!==e)return i;for(;n=i[a++];)1===n.nodeType&&r.push(n);return r},b.find.CLASS=d.getElementsByClassName&&function(e,t){if(void 0!==t.getElementsByClassName&&k)return t.getElementsByClassName(e)},s=[],g=[],(d.qsa=Z.test(x.querySelectorAll))&&(le(function(e){o.appendChild(e).innerHTML=" ",e.querySelectorAll("[msallowcapture^='']").length&&g.push("[*^$]="+R+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||g.push("\\["+R+"*(?:value|"+L+")"),e.querySelectorAll("[id~="+E+"-]").length||g.push("~="),e.querySelectorAll(":checked").length||g.push(":checked"),e.querySelectorAll("a#"+E+"+*").length||g.push(".#.+[+~]")}),le(function(e){e.innerHTML=" ";var t=x.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&g.push("name"+R+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&g.push(":enabled",":disabled"),o.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&g.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),g.push(",.*:")})),(d.matchesSelector=Z.test(l=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&le(function(e){d.disconnectedMatch=l.call(e,"*"),l.call(e,"[s!='']:x"),s.push("!=",q)}),g=g.length&&new RegExp(g.join("|")),s=s.length&&new RegExp(s.join("|")),t=Z.test(o.compareDocumentPosition),v=t||Z.test(o.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)for(;t=t.parentNode;)if(t===e)return!0;return!1},C=t?function(e,t){if(e===t)return c=!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===x||e.ownerDocument===y&&v(y,e)?-1:t===x||t.ownerDocument===y&&v(y,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return c=!0,0;var n,r=0,a=e.parentNode,i=t.parentNode,o=[e],s=[t];if(!a||!i)return e===x?-1:t===x?1:a?-1:i?1:u?P(u,e)-P(u,t):0;if(a===i)return he(e,t);for(n=e;n=n.parentNode;)o.unshift(n);for(n=t;n=n.parentNode;)s.unshift(n);for(;o[r]===s[r];)r++;return r?he(o[r],s[r]):o[r]===y?-1:s[r]===y?1:0}),x},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if((e.ownerDocument||e)!==x&&A(e),d.matchesSelector&&k&&!T[t+" "]&&(!s||!s.test(t))&&(!g||!g.test(t)))try{var n=l.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){T(t,!0)}return 0":{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 V.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&U.test(n)&&(t=p(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=h[e+" "];return t||(t=new RegExp("(^|"+R+")"+e+"("+R+"|$)"))&&h(e,function(e){return t.test("string"==typeof e.className&&e.className||void 0!==e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,a){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===a:"!="===r?t!==a:"^="===r?a&&0===t.indexOf(a):"*="===r?a&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function C(e,n,r){return y(n)?E.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?E.grep(e,function(e){return e===n!==r}):"string"!=typeof n?E.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(E.fn.init=function(e,t,n){var r,a;if(!e)return this;if(n=n||D,"string"!=typeof e)return e.nodeType?(this[0]=e,this.length=1,this):y(e)?void 0!==n.ready?n.ready(e):e(E):E.makeArray(e,this);if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:O.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 E?t[0]:t,E.merge(this,E.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:k,!0)),T.test(r[1])&&E.isPlainObject(t))for(r in t)y(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(a=k.getElementById(r[2]))&&(this[0]=a,this.length=1),this}).prototype=E.fn,D=E(k);var j=/^(?:parents|prev(?:Until|All))/,N={children:!0,contents:!0,next:!0,prev:!0};function z(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}E.fn.extend({has:function(e){var t=E(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,de=/^$|^module$|\/(?:java|ecma)script/i,pe={option:[1,""," "],thead:[1,""],col:[2,""],tr:[2,""],td:[3,""],_default:[0,"",""]};function me(e,t){var n;return n=void 0!==e.getElementsByTagName?e.getElementsByTagName(t||"*"):void 0!==e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&M(e,t)?E.merge([e],n):n}function ge(e,t){for(var n=0,r=e.length;nx",v.noCloneChecked=!!ve.cloneNode(!0).lastChild.defaultValue;var we=/^key/,Ae=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,xe=/^([^.]*)(?:\.(.+)|)/;function ke(){return!0}function Ee(){return!1}function Se(e,t){return e===function(){try{return k.activeElement}catch(e){}}()==("focus"===t)}function Me(e,t,n,r,a,i){var o,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)Me(e,s,n,r,t[s],i);return e}if(null==r&&null==a?(a=n,r=n=void 0):null==a&&("string"==typeof n?(a=r,r=void 0):(a=r,r=n,n=void 0)),!1===a)a=Ee;else if(!a)return e;return 1===i&&(o=a,(a=function(e){return E().off(e),o.apply(this,arguments)}).guid=o.guid||(o.guid=E.guid++)),e.each(function(){E.event.add(this,t,a,r,n)})}function Te(e,a,i){i?(J.set(e,a,!1),E.event.add(e,a,{namespace:!1,handler:function(e){var t,n,r=J.get(this,a);if(1&e.isTrigger&&this[a]){if(r.length)(E.event.special[a]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),J.set(this,a,r),t=i(this,a),this[a](),r!==(n=J.get(this,a))||t?J.set(this,a,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(J.set(this,a,{value:E.event.trigger(E.extend(r[0],E.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===J.get(e,a)&&E.event.add(e,a,ke)}E.event={global:{},add:function(t,e,n,r,a){var i,o,s,u,c,l,f,h,d,p,m,g=J.get(t);if(g)for(n.handler&&(n=(i=n).handler,a=i.selector),a&&E.find.matchesSelector(re,a),n.guid||(n.guid=E.guid++),(u=g.events)||(u=g.events={}),(o=g.handle)||(o=g.handle=function(e){return void 0!==E&&E.event.triggered!==e.type?E.event.dispatch.apply(t,arguments):void 0}),c=(e=(e||"").match(P)||[""]).length;c--;)d=m=(s=xe.exec(e[c])||[])[1],p=(s[2]||"").split(".").sort(),d&&(f=E.event.special[d]||{},d=(a?f.delegateType:f.bindType)||d,f=E.event.special[d]||{},l=E.extend({type:d,origType:m,data:r,handler:n,guid:n.guid,selector:a,needsContext:a&&E.expr.match.needsContext.test(a),namespace:p.join(".")},i),(h=u[d])||((h=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,p,o)||t.addEventListener&&t.addEventListener(d,o)),f.add&&(f.add.call(t,l),l.handler.guid||(l.handler.guid=n.guid)),a?h.splice(h.delegateCount++,0,l):h.push(l),E.event.global[d]=!0)},remove:function(e,t,n,r,a){var i,o,s,u,c,l,f,h,d,p,m,g=J.hasData(e)&&J.get(e);if(g&&(u=g.events)){for(c=(t=(t||"").match(P)||[""]).length;c--;)if(d=m=(s=xe.exec(t[c])||[])[1],p=(s[2]||"").split(".").sort(),d){for(f=E.event.special[d]||{},h=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),o=i=h.length;i--;)l=h[i],!a&&m!==l.origType||n&&n.guid!==l.guid||s&&!s.test(l.namespace)||r&&r!==l.selector&&("**"!==r||!l.selector)||(h.splice(i,1),l.selector&&h.delegateCount--,f.remove&&f.remove.call(e,l));o&&!h.length&&(f.teardown&&!1!==f.teardown.call(e,p,g.handle)||E.removeEvent(e,d,g.handle),delete u[d])}else for(d in u)E.event.remove(e,d+t[c],n,r,!0);E.isEmptyObject(u)&&J.remove(e,"handle events")}},dispatch:function(e){var t,n,r,a,i,o,s=E.event.fix(e),u=new Array(arguments.length),c=(J.get(this,"events")||{})[s.type]||[],l=E.event.special[s.type]||{};for(u[0]=s,t=1;t\x20\t\r\n\f]*)[^>]*)\/>/gi,De=/