Skip to content

Commit

Permalink
fix web cdn
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaozhou26 committed Aug 18, 2024
1 parent edd5547 commit d539c23
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 39 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GHCR_PAT }}
with:
tag_name: v2.2.3
tag_name: v2.2.4
files: |
aurora-linux-amd64.tar.gz
aurora-linux-arm64.tar.gz
Expand Down
50 changes: 25 additions & 25 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,53 +4,53 @@ go 1.21

require (
github.com/EDDYCJY/fake-useragent v0.2.0
github.com/PuerkitoBio/goquery v1.9.1
github.com/PuerkitoBio/goquery v1.9.2
github.com/acheong08/endless v0.0.0-20230615162514-90545c7793fd
github.com/bogdanfinn/fhttp v0.5.27
github.com/bogdanfinn/fhttp v0.5.28
github.com/bogdanfinn/tls-client v1.7.2
github.com/gin-gonic/gin v1.9.1
github.com/go-resty/resty/v2 v2.12.0
github.com/gin-gonic/gin v1.10.0
github.com/go-resty/resty/v2 v2.14.0
github.com/google/uuid v1.6.0
github.com/gorilla/websocket v1.5.1
github.com/gorilla/websocket v1.5.3
github.com/joho/godotenv v1.5.1
github.com/pkoukk/tiktoken-go v0.1.6
github.com/pkoukk/tiktoken-go v0.1.7
github.com/xqdoo00o/funcaptcha v0.0.0-20240403090732-1b604d808f6c
golang.org/x/crypto v0.21.0
golang.org/x/crypto v0.26.0
)

require (
github.com/andybalholm/brotli v1.0.5 // indirect
github.com/andybalholm/brotli v1.1.0 // indirect
github.com/andybalholm/cascadia v1.3.2 // indirect
github.com/bogdanfinn/utls v1.6.1 // indirect
github.com/bytedance/sonic v1.10.1 // indirect
github.com/bytedance/sonic v1.12.1 // indirect
github.com/chenzhuoyu/base64x v0.0.0-20230717121745-296ad89f973d // indirect
github.com/chenzhuoyu/iasm v0.9.0 // indirect
github.com/cloudflare/circl v1.3.6 // indirect
github.com/dlclark/regexp2 v1.10.0 // indirect
github.com/gabriel-vasile/mimetype v1.4.2 // indirect
github.com/chenzhuoyu/iasm v0.9.1 // indirect
github.com/cloudflare/circl v1.3.9 // indirect
github.com/dlclark/regexp2 v1.11.4 // indirect
github.com/gabriel-vasile/mimetype v1.4.5 // indirect
github.com/gin-contrib/sse v0.1.0 // indirect
github.com/go-playground/locales v0.14.1 // indirect
github.com/go-playground/universal-translator v0.18.1 // indirect
github.com/go-playground/validator/v10 v10.15.4 // indirect
github.com/goccy/go-json v0.10.2 // indirect
github.com/go-playground/validator/v10 v10.22.0 // indirect
github.com/goccy/go-json v0.10.3 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/klauspost/compress v1.17.0 // indirect
github.com/klauspost/cpuid/v2 v2.2.5 // indirect
github.com/klauspost/cpuid/v2 v2.2.8 // indirect
github.com/kr/text v0.2.0 // indirect
github.com/leodido/go-urn v1.2.4 // indirect
github.com/mattn/go-isatty v0.0.19 // indirect
github.com/leodido/go-urn v1.4.0 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/pelletier/go-toml/v2 v2.1.0 // indirect
github.com/pelletier/go-toml/v2 v2.2.2 // indirect
github.com/quic-go/quic-go v0.37.4 // indirect
github.com/rogpeppe/go-internal v1.12.0 // indirect
github.com/tam7t/hpkp v0.0.0-20160821193359-2b70b4024ed5 // indirect
github.com/twitchyliquid64/golang-asm v0.15.1 // indirect
github.com/ugorji/go/codec v1.2.11 // indirect
golang.org/x/arch v0.5.0 // indirect
golang.org/x/net v0.22.0 // indirect
golang.org/x/sys v0.18.0 // indirect
golang.org/x/text v0.14.0 // indirect
google.golang.org/protobuf v1.31.0 // indirect
github.com/ugorji/go/codec v1.2.12 // indirect
golang.org/x/arch v0.9.0 // indirect
golang.org/x/net v0.28.0 // indirect
golang.org/x/sys v0.24.0 // indirect
golang.org/x/text v0.17.0 // indirect
google.golang.org/protobuf v1.34.2 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
30 changes: 17 additions & 13 deletions web/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3006,12 +3006,13 @@
</div>
</div>
</div>
<link crossorigin="anonymous" href="https://cdn.staticfile.org/github-markdown-css/5.3.0/github-markdown-light.min.css"
<link crossorigin="anonymous"
href="https://fastly.jsdelivr.net/npm/[email protected]/github-markdown-light.min.css" rel="stylesheet">
<link crossorigin="anonymous"
href="https://fastly.jsdelivr.net/gh/highlightjs/[email protected]/build/styles/github.min.css"
rel="stylesheet">
<link crossorigin="anonymous" href="https://cdn.staticfile.org/highlight.js/11.9.0/styles/github.min.css"
rel="stylesheet">
<link crossorigin="anonymous" href="https://cdn.staticfile.org/notyf/3.10.0/notyf.min.css" rel="stylesheet">
<script crossorigin="anonymous" src="https://cdn.staticfile.org/notyf/3.10.0/notyf.min.js"></script>
<link crossorigin="anonymous" href="https://fastly.jsdelivr.net/npm/[email protected]/notyf.min.css" rel="stylesheet">
<script crossorigin="anonymous" src="https://fastly.jsdelivr.net/npm/[email protected]/notyf.min.js"></script>
<script>
const notyf = new Notyf({
position: { x: "center", y: "top" },
Expand All @@ -3036,7 +3037,7 @@
const isMobile = navigator.userAgent.match(/iPhone|iPad|iPod|Android|BlackBerry|webOS/);
if (isMobile) {
const script = document.createElement("script");
script.src = "https://cdn.jsdelivr.net/gh/timruffles/[email protected]/release/index.min.js";
script.src = "https://fastly.jsdelivr.net/gh/timruffles/[email protected]/release/index.min.js";
script.crossOrigin = "anonymous";
script.defer = true;
script.onload = () => {
Expand All @@ -3046,7 +3047,7 @@
const link = document.createElement("link");
link.crossOrigin = "anonymous";
link.rel = "stylesheet";
link.href = "https://cdn.jsdelivr.net/gh/timruffles/[email protected]/release/default.css";
link.href = "https://fastly.jsdelivr.net/gh/timruffles/[email protected]/release/default.css";
document.body.appendChild(link);
}
let envAPIEndpoint, envAPIKey;
Expand Down Expand Up @@ -4355,9 +4356,11 @@
};
speechServiceEle.dispatchEvent(new Event("change"));
</script>
<script crossorigin="anonymous" src="https://cdn.staticfile.org/markdown-it/13.0.2/markdown-it.min.js"></script>
<script crossorigin="anonymous" src="https://cdn.staticfile.org/highlight.js/11.9.0/highlight.min.js"></script>
<script crossorigin="anonymous" src="https://cdn.staticfile.org/KaTeX/0.16.9/katex.min.js"></script>
<script crossorigin="anonymous"
src="https://fastly.jsdelivr.net/npm/[email protected]/dist/markdown-it.min.js"></script>
<script crossorigin="anonymous"
src="https://fastly.jsdelivr.net/gh/highlightjs/[email protected]/build/highlight.min.js"></script>
<script crossorigin="anonymous" src="https://fastly.jsdelivr.net/npm/[email protected]/dist/katex.min.js"></script>
<script>
// from [email protected]
function escapeHTML(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;")}function texmath(e,t){const n=texmath.mergeDelimiters(t&&t.delimiters),a=t&&t.outerSpace||!1,o=t&&t.katexOptions||{};o.throwOnError=o.throwOnError||!1,o.macros=o.macros||t&&t.macros,texmath.katex||(t&&"object"==typeof t.engine?texmath.katex=t.engine:"object"==typeof module?texmath.katex=require("katex"):texmath.katex={renderToString:()=>"No math renderer found."});for(const t of n.inline)a&&"outerSpace"in t&&(t.outerSpace=!0),e.inline.ruler.before("escape",t.name,texmath.inline(t)),e.renderer.rules[t.name]=(e,n)=>t.tmpl.replace(/\$1/,texmath.render(e[n].content,!!t.displayMode,o));for(const t of n.block)e.block.ruler.before("fence",t.name,texmath.block(t)),e.renderer.rules[t.name]=(e,n)=>t.tmpl.replace(/\$2/,escapeHTML(e[n].info)).replace(/\$1/,texmath.render(e[n].content,!0,o))}texmath.mergeDelimiters=function(e){const t=Array.isArray(e)?e:"string"==typeof e?[e]:["dollars"],n={inline:[],block:[]};for(const e of t)e in texmath.rules&&(n.inline.push(...texmath.rules[e].inline),n.block.push(...texmath.rules[e].block));return n},texmath.inline=e=>function(t,n){const a=t.pos,o=t.src,r=o.startsWith(e.tag,e.rex.lastIndex=a)&&(!e.pre||e.pre(o,e.outerSpace,a))&&e.rex.exec(o),s=!!r&&a<e.rex.lastIndex&&(!e.post||e.post(o,e.outerSpace,e.rex.lastIndex-1));if(s){if(!n){const n=t.push(e.name,"math",0);n.content=r[1],n.markup=e.tag}t.pos=e.rex.lastIndex}return s},texmath.block=e=>function(t,n,a,o){const r=t.bMarks[n]+t.tShift[n],s=t.src,m=s.startsWith(e.tag,e.rex.lastIndex=r)&&(!e.pre||e.pre(s,!1,r))&&e.rex.exec(s),l=!!m&&r<e.rex.lastIndex&&(!e.post||e.post(s,!1,e.rex.lastIndex-1));if(l&&!o){const o=e.rex.lastIndex-1;let r;for(r=n;r<a&&!(o>=t.bMarks[r]+t.tShift[r]&&o<=t.eMarks[r]);r++);const s=t.lineMax,l=t.parentType;t.lineMax=r,t.parentType="math","blockquote"===l&&(m[1]=m[1].replace(/(\n*?^(?:\s*>)+)/gm,""));let c=t.push(e.name,"math",0);c.block=!0,c.tag=e.tag,c.markup="",c.content=m[1],c.info=m[m.length-1],c.map=[n,r+1],t.parentType=l,t.lineMax=s,t.line=r+1}return l},texmath.render=function(e,t,n){let a;n.displayMode=t;try{a=texmath.katex.renderToString(e,n)}catch(t){a=escapeHTML(`${e}:${t.message}`)}return a},texmath.inlineRuleNames=["math_inline","math_inline_double"],texmath.blockRuleNames=["math_block","math_block_eqno"],texmath.$_pre=(e,t,n)=>{const a=n>0&&e[n-1].charCodeAt(0);return t?!a||32===a:!a||92!==a&&(a<48||a>57)},texmath.$_post=(e,t,n)=>{const a=e[n+1]&&e[n+1].charCodeAt(0);return t?!a||32===a||46===a||44===a||59===a:!a||a<48||a>57},texmath.rules={brackets:{inline:[{name:"math_inline",rex:/\\\((.+?)\\\)/gy,tmpl:"<eq>$1</eq>",tag:"\\("}],block:[{name:"math_block_eqno",rex:/\\\[(((?!\\\]|\\\[)[\s\S])+?)\\\]\s*?\(([^)$\r\n]+?)\)/gmy,tmpl:'<section class="eqno"><eqn>$1</eqn><span>($2)</span></section>',tag:"\\["},{name:"math_block",rex:/\\\[([\s\S]+?)\\\]/gmy,tmpl:"<section><eqn>$1</eqn></section>",tag:"\\["}]},doxygen:{inline:[{name:"math_inline",rex:/\\f\$(.+?)\\f\$/gy,tmpl:"<eq>$1</eq>",tag:"\\f$"}],block:[{name:"math_block_eqno",rex:/\\f\[([^]+?)\\f\]\s*?\(([^)\s]+?)\)/gmy,tmpl:'<section class="eqno"><eqn>$1</eqn><span>($2)</span></section>',tag:"\\f["},{name:"math_block",rex:/\\f\[([^]+?)\\f\]/gmy,tmpl:"<section><eqn>$1</eqn></section>",tag:"\\f["}]},gitlab:{inline:[{name:"math_inline",rex:/\$`(.+?)`\$/gy,tmpl:"<eq>$1</eq>",tag:"$`"}],block:[{name:"math_block_eqno",rex:/`{3}math\s*([^`]+?)\s*?`{3}\s*\(([^)\r\n]+?)\)/gm,tmpl:'<section class="eqno"><eqn>$1</eqn><span>($2)</span></section>',tag:"```math"},{name:"math_block",rex:/`{3}math\s*([^`]*?)\s*`{3}/gm,tmpl:"<section><eqn>$1</eqn></section>",tag:"```math"}]},julia:{inline:[{name:"math_inline",rex:/`{2}([^`]+?)`{2}/gy,tmpl:"<eq>$1</eq>",tag:"``"},{name:"math_inline",rex:/\$((?:\S?)|(?:\S.*?\S))\$/gy,tmpl:"<eq>$1</eq>",tag:"$",spaceEnclosed:!1,pre:texmath.$_pre,post:texmath.$_post}],block:[{name:"math_block_eqno",rex:/`{3}math\s+?([^`]+?)\s+?`{3}\s*?\(([^)$\r\n]+?)\)/gmy,tmpl:'<section class="eqno"><eqn>$1</eqn><span>($2)</span></section>',tag:"```math"},{name:"math_block",rex:/`{3}math\s+?([^`]+?)\s+?`{3}/gmy,tmpl:"<section><eqn>$1</eqn></section>",tag:"```math"}]},kramdown:{inline:[{name:"math_inline",rex:/\${2}(.+?)\${2}/gy,tmpl:"<eq>$1</eq>",tag:"$$"}],block:[{name:"math_block_eqno",rex:/\${2}([^$]+?)\${2}\s*?\(([^)\s]+?)\)/gmy,tmpl:'<section class="eqno"><eqn>$1</eqn><span>($2)</span></section>',tag:"$$"},{name:"math_block",rex:/\${2}([^$]+?)\${2}/gmy,tmpl:"<section><eqn>$1</eqn></section>",tag:"$$"}]},beg_end:{inline:[],block:[{name:"math_block",rex:/(\\(?:begin)\{([a-z]+)\}[\s\S]+?\\(?:end)\{\2\})/gmy,tmpl:"<section><eqn>$1</eqn></section>",tag:"\\"}]},dollars:{inline:[{name:"math_inline_double",rex:/\${2}([^$]*?[^\\])\${2}/gy,tmpl:"<section><eqn>$1</eqn></section>",tag:"$$",displayMode:!0,pre:texmath.$_pre,post:texmath.$_post},{name:"math_inline",rex:/\$((?:[^\s\\])|(?:\S.*?[^\s\\]))\$/gy,tmpl:"<eq>$1</eq>",tag:"$",outerSpace:!1,pre:texmath.$_pre,post:texmath.$_post}],block:[{name:"math_block_eqno",rex:/\${2}([^$]*?[^\\])\${2}\s*?\(([^)\s]+?)\)/gmy,tmpl:'<section class="eqno"><eqn>$1</eqn><span>($2)</span></section>',tag:"$$"},{name:"math_block",rex:/\${2}([^$]*?[^\\])\${2}/gmy,tmpl:"<section><eqn>$1</eqn></section>",tag:"$$"}]}};
Expand Down Expand Up @@ -6957,7 +6960,8 @@
}
}
</script>
<link crossorigin="anonymous" href="//cdn.staticfile.org/KaTeX/0.16.9/katex.min.css" rel="stylesheet">
<link crossorigin="anonymous" href="https://fastly.jsdelivr.net/npm/[email protected]/dist/katex.min.css"
rel="stylesheet">
<script defer>
let downRoleController = new AbortController();
const loadPrompt = () => {
Expand All @@ -6968,7 +6972,7 @@
}, 10000);
preEle.options.length = 5;
if (locale === "zh") {
fetch("https://cdn.jsdelivr.net/gh/PlexPt/awesome-chatgpt-prompts-zh/prompts-zh.json", {
fetch("https://fastly.jsdelivr.net/gh/PlexPt/awesome-chatgpt-prompts-zh/prompts-zh.json", {
signal: downRoleController.signal
}).then(async (response) => {
let res = await response.json();
Expand All @@ -6982,7 +6986,7 @@
}
}).catch(e => { })
} else {
fetch("https://cdn.jsdelivr.net/gh/f/awesome-chatgpt-prompts/prompts.csv", {
fetch("https://fastly.jsdelivr.net/gh/f/awesome-chatgpt-prompts/prompts.csv", {
signal: downRoleController.signal
}).then(async (response) => {
let res = await response.text();
Expand Down

0 comments on commit d539c23

Please sign in to comment.