Compare commits
2 Commits
master
...
for-replit
Author | SHA1 | Date |
---|---|---|
Jad | 814b1e347c | |
Jad | 0c0e368222 |
|
@ -0,0 +1,77 @@
|
||||||
|
|
||||||
|
hidden = [".config", "package-lock.json"]
|
||||||
|
run = "npm run start"
|
||||||
|
|
||||||
|
[[hints]]
|
||||||
|
regex = "Error \\[ERR_REQUIRE_ESM\\]"
|
||||||
|
message = "We see that you are using require(...) inside your code. We currently do not support this syntax. Please use 'import' instead when using external modules. (https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/import)"
|
||||||
|
|
||||||
|
[nix]
|
||||||
|
channel = "stable-22_11"
|
||||||
|
|
||||||
|
[env]
|
||||||
|
XDG_CONFIG_HOME = "/home/runner/.config"
|
||||||
|
PATH = "/home/runner/$REPL_SLUG/.config/npm/node_global/bin:/home/runner/$REPL_SLUG/node_modules/.bin"
|
||||||
|
npm_config_prefix = "/home/runner/$REPL_SLUG/.config/npm/node_global"
|
||||||
|
|
||||||
|
[gitHubImport]
|
||||||
|
requiredFiles = [".replit", "replit.nix", ".config", "package.json", "package-lock.json"]
|
||||||
|
|
||||||
|
[packager]
|
||||||
|
language = "nodejs"
|
||||||
|
|
||||||
|
[packager.features]
|
||||||
|
packageSearch = true
|
||||||
|
guessImports = true
|
||||||
|
enabledForHosting = false
|
||||||
|
|
||||||
|
[unitTest]
|
||||||
|
language = "nodejs"
|
||||||
|
|
||||||
|
[debugger]
|
||||||
|
support = true
|
||||||
|
|
||||||
|
[debugger.interactive]
|
||||||
|
transport = "localhost:0"
|
||||||
|
startCommand = [ "dap-node" ]
|
||||||
|
|
||||||
|
[debugger.interactive.initializeMessage]
|
||||||
|
command = "initialize"
|
||||||
|
type = "request"
|
||||||
|
|
||||||
|
[debugger.interactive.initializeMessage.arguments]
|
||||||
|
clientID = "replit"
|
||||||
|
clientName = "replit.com"
|
||||||
|
columnsStartAt1 = true
|
||||||
|
linesStartAt1 = true
|
||||||
|
locale = "en-us"
|
||||||
|
pathFormat = "path"
|
||||||
|
supportsInvalidatedEvent = true
|
||||||
|
supportsProgressReporting = true
|
||||||
|
supportsRunInTerminalRequest = true
|
||||||
|
supportsVariablePaging = true
|
||||||
|
supportsVariableType = true
|
||||||
|
|
||||||
|
[debugger.interactive.launchMessage]
|
||||||
|
command = "launch"
|
||||||
|
type = "request"
|
||||||
|
|
||||||
|
[debugger.interactive.launchMessage.arguments]
|
||||||
|
args = []
|
||||||
|
console = "externalTerminal"
|
||||||
|
cwd = "."
|
||||||
|
environment = []
|
||||||
|
pauseForSourceMap = false
|
||||||
|
program = "./index.js"
|
||||||
|
request = "launch"
|
||||||
|
sourceMaps = true
|
||||||
|
stopOnEntry = false
|
||||||
|
type = "pwa-node"
|
||||||
|
|
||||||
|
[languages]
|
||||||
|
|
||||||
|
[languages.javascript]
|
||||||
|
pattern = "**/{*.js,*.jsx,*.ts,*.tsx}"
|
||||||
|
|
||||||
|
[languages.javascript.languageServer]
|
||||||
|
start = "typescript-language-server --stdio"
|
11
Dockerfile
|
@ -1,11 +0,0 @@
|
||||||
FROM node:14
|
|
||||||
|
|
||||||
WORKDIR /app
|
|
||||||
|
|
||||||
COPY . .
|
|
||||||
|
|
||||||
RUN yarn install
|
|
||||||
|
|
||||||
EXPOSE 3000
|
|
||||||
|
|
||||||
CMD ["yarn", "start"]
|
|
|
@ -1,6 +1,8 @@
|
||||||
# Moe-Counter
|
# Moe-Counter
|
||||||
|
|
||||||
![Moe-Counter](https://count.ayaya.beauty/get/@Moe-counter-git.zzls)
|
多种风格可选的萌萌计数器
|
||||||
|
|
||||||
|
![Moe-Counter](https://count.getloli.com/get/@Moe-counter.github)
|
||||||
|
|
||||||
<details>
|
<details>
|
||||||
<summary>More theme</summary>
|
<summary>More theme</summary>
|
||||||
|
@ -40,13 +42,12 @@ $ yarn install
|
||||||
$ yarn start
|
$ yarn start
|
||||||
```
|
```
|
||||||
|
|
||||||
### Configuration
|
### Confignation
|
||||||
|
|
||||||
`config.yml`
|
`config.yml`
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
app:
|
app:
|
||||||
# site: https://count.getloli.com # your website
|
|
||||||
port: 3000
|
port: 3000
|
||||||
|
|
||||||
db:
|
db:
|
||||||
|
|
|
@ -1,21 +0,0 @@
|
||||||
body {
|
|
||||||
background-color: #111111;
|
|
||||||
}
|
|
||||||
|
|
||||||
h1, h2, h3, h4, h5, h6 {
|
|
||||||
color: #FFFFFF;
|
|
||||||
}
|
|
||||||
|
|
||||||
a:link {
|
|
||||||
color: rgb(223, 131, 223);
|
|
||||||
}
|
|
||||||
|
|
||||||
a:visited {
|
|
||||||
color: rgb(223, 131, 223);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
code, input, select, button {
|
|
||||||
background: #2c2c2c;
|
|
||||||
color: #FFF;
|
|
||||||
}
|
|
|
@ -1,2 +0,0 @@
|
||||||
@charset "UTF-8";body{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;line-height:1.4;max-width:800px;margin:20px auto;padding:0 10px;color:#363636;background:#fff;text-rendering:optimizeLegibility}button,input,textarea{transition:background-color .1s linear,border-color .1s linear,color .1s linear,box-shadow .1s linear,transform .1s ease}h1{font-size:2.2em;margin-top:0}h1,h2,h3,h4,h5,h6{margin-bottom:12px}h1,h2,h3,h4,h5,h6,strong{color:#000}b,h1,h2,h3,h4,h5,h6,strong,th{font-weight:600}blockquote{border-left:4px solid rgba(0,150,191,.67);margin:1.5em 0;padding:.5em 1em;font-style:italic}blockquote>footer{margin-top:10px;font-style:normal}address,blockquote cite{font-style:normal}a[href^=mailto]:before{content:"📧 "}a[href^=tel]:before{content:"📞 "}a[href^=sms]:before{content:"💬 "}button,input[type=button],input[type=checkbox],input[type=submit]{cursor:pointer}input:not([type=checkbox]):not([type=radio]),select{display:block}button,input,select,textarea{color:#000;background-color:#efefef;font-family:inherit;font-size:inherit;margin-right:6px;margin-bottom:6px;padding:10px;border:none;border-radius:6px;outline:none}button,input:not([type=checkbox]):not([type=radio]),select,textarea{-webkit-appearance:none}textarea{margin-right:0;width:100%;box-sizing:border-box;resize:vertical}button,input[type=button],input[type=submit]{padding-right:30px;padding-left:30px}button:hover,input[type=button]:hover,input[type=submit]:hover{background:#ddd}button:focus,input:focus,select:focus,textarea:focus{box-shadow:0 0 0 2px rgba(0,150,191,.67)}button:active,input[type=button]:active,input[type=checkbox]:active,input[type=radio]:active,input[type=submit]:active{transform:translateY(2px)}button:disabled,input:disabled,select:disabled,textarea:disabled{cursor:not-allowed;opacity:.5}::-webkit-input-placeholder{color:#949494}:-ms-input-placeholder{color:#949494}::-ms-input-placeholder{color:#949494}::placeholder{color:#949494}a{text-decoration:none;color:#0076d1}a:hover{text-decoration:underline}code,kbd{background:#efefef;color:#000;padding:5px;border-radius:6px}pre>code{padding:10px;display:block;overflow-x:auto}img{max-width:100%}hr{border:none;border-top:1px solid #dbdbdb}table{border-collapse:collapse;margin-bottom:10px;width:100%}td,th{padding:6px;text-align:left}th{border-bottom:1px solid #dbdbdb}tbody tr:nth-child(2n){background-color:#efefef}::-webkit-scrollbar{height:10px;width:10px}::-webkit-scrollbar-track{background:#efefef;border-radius:6px}::-webkit-scrollbar-thumb{background:#d5d5d5;border-radius:6px}::-webkit-scrollbar-thumb:hover{background:#c4c4c4}
|
|
||||||
/*# sourceMappingURL=light.min.css.map */
|
|
Before Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 680 B |
Before Width: | Height: | Size: 769 B |
Before Width: | Height: | Size: 855 B |
Before Width: | Height: | Size: 775 B |
Before Width: | Height: | Size: 819 B |
Before Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 795 B |
Before Width: | Height: | Size: 1012 B |
Before Width: | Height: | Size: 913 B |
Before Width: | Height: | Size: 826 B |
|
@ -1,5 +1,4 @@
|
||||||
app:
|
app:
|
||||||
# site: https://count.getloli.com # your website
|
|
||||||
port: 3000
|
port: 3000
|
||||||
|
|
||||||
db:
|
db:
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
version: '3'
|
|
||||||
services:
|
|
||||||
moe-counter:
|
|
||||||
build: .
|
|
||||||
ports:
|
|
||||||
- "3000:3000"
|
|
3
index.js
|
@ -17,8 +17,7 @@ app.use(compression())
|
||||||
app.set('view engine', 'pug')
|
app.set('view engine', 'pug')
|
||||||
|
|
||||||
app.get('/', (req, res) => {
|
app.get('/', (req, res) => {
|
||||||
const site = config.app.site || `${req.protocol}://${req.get('host')}`
|
res.render('index')
|
||||||
res.render('index', { site })
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// get the image
|
// get the image
|
||||||
|
|
|
@ -0,0 +1,8 @@
|
||||||
|
{ pkgs }: {
|
||||||
|
deps = [
|
||||||
|
pkgs.nodejs-18_x
|
||||||
|
pkgs.nodePackages.typescript-language-server
|
||||||
|
pkgs.yarn
|
||||||
|
pkgs.replitPackages.jest
|
||||||
|
];
|
||||||
|
}
|
|
@ -3,78 +3,83 @@ html
|
||||||
title='Moe Counter!'
|
title='Moe Counter!'
|
||||||
meta(name='viewport', content='width=device-width, initial-scale=1')
|
meta(name='viewport', content='width=device-width, initial-scale=1')
|
||||||
link(rel='icon', type='image/png', href='favicon.png')
|
link(rel='icon', type='image/png', href='favicon.png')
|
||||||
link(rel='stylesheet', href='./light.min.css')
|
link(rel='stylesheet', href='https://cdn.jsdelivr.net/gh/kognise/water.css@latest/dist/light.min.css')
|
||||||
link(rel='stylesheet', href='./custom.css')
|
link(rel='stylesheet', href='style.css')
|
||||||
|
<!-- Global site tag (gtag.js) - Google Analytics -->
|
||||||
// GOODBYE GOOGLE SHIT
|
script(async, src='https://www.googletagmanager.com/gtag/js?id=G-2RLWN5JXRL')
|
||||||
|
script.
|
||||||
|
window.dataLayer = window.dataLayer || [];
|
||||||
|
function gtag(){dataLayer.push(arguments);}
|
||||||
|
gtag('js', new Date());
|
||||||
|
|
||||||
|
gtag('config', 'G-2RLWN5JXRL');
|
||||||
|
|
||||||
|
function _evt_push(type, category, label){
|
||||||
|
gtag('event', type, {
|
||||||
|
'event_category' : category,
|
||||||
|
'event_label' : label
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
body
|
body
|
||||||
h3 How to use:
|
h3 How to use:
|
||||||
|
|
||||||
h5 SVG address
|
h5 SVG address
|
||||||
code #{site}/get/@:name
|
code https://count.getloli.com/get/@:name
|
||||||
|
|
||||||
h5 Img tag
|
h5 Img tag
|
||||||
code <img src="#{site}/get/@:name" alt=":name" />
|
code <img src="https://count.getloli.com/get/@:name" alt=":name" />
|
||||||
|
|
||||||
h5 Markdown
|
h5 Markdown
|
||||||
code ![:name](#{site}/get/@:name)
|
code ![:name](https://count.getloli.com/get/@:name)
|
||||||
|
|
||||||
h3 eg:
|
h3 eg:
|
||||||
<img src="#{site}/get/@index" alt="Moe Count!" />
|
<img src="https://count.getloli.com/get/@index" alt="Moe Count!" />
|
||||||
|
|
||||||
i(style='color: #FFFFFF') Data can access by anyone, please
|
i Data can access by anyone, please
|
||||||
| <span style="color: #ff4500;"> DO NOT</span>
|
| <span style="color: #ff4500;"> DO NOT</span>
|
||||||
| enter personal information
|
| enter personal information
|
||||||
|
|
||||||
details
|
details
|
||||||
summary(style='display: inline-block;', onclick='_evt_push("click", "normal", "more_theme")')
|
summary(style='display: inline-block;', onclick='_evt_push("click", "normal", "more_theme")')
|
||||||
h3(style='display: inline-block; cursor: pointer;') More themes
|
h3(style='display: inline-block; cursor: pointer;') More theme
|
||||||
p(style='margin: 0;') Just use the query parameters <code>theme</code>, like this: <code>#{site}/get/@:name?theme=moebooru</code>
|
p(style='margin: 0;') Just use the query parameters <code>theme</code>, like this: <code>https://count.getloli.com/get/@:name?theme=moebooru</code>
|
||||||
h5 asoul
|
h5 asoul
|
||||||
img(src='#{site}/get/@demo?theme=asoul', alt='A-SOUL')
|
img(src='https://count.getloli.com/get/@demo?theme=asoul', alt='A-SOUL')
|
||||||
h5 moebooru
|
h5 moebooru
|
||||||
img(src='#{site}/get/@demo?theme=moebooru', alt='Moebooru')
|
img(src='https://count.getloli.com/get/@demo?theme=moebooru', alt='Moebooru')
|
||||||
h5 moebooru-h
|
|
||||||
img(src='#{site}/get/@demo?theme=moebooru-h', alt='Moebooru-Hentai')
|
|
||||||
h5 rule34
|
h5 rule34
|
||||||
img(src='#{site}/get/@demo?theme=rule34', alt='Rule34')
|
img(src='https://count.getloli.com/get/@demo?theme=rule34', alt='Rule34')
|
||||||
h5 gelbooru
|
h5 gelbooru
|
||||||
img(src='#{site}/get/@demo?theme=gelbooru', alt='Gelbooru')
|
img(src='https://count.getloli.com/get/@demo?theme=gelbooru', alt='Gelbooru')
|
||||||
h5 gelbooru-h
|
|
||||||
img(src='#{site}/get/@demo?theme=gelbooru-h', alt='Gelbooru-Hentai')
|
|
||||||
|
|
||||||
// h3 Credits
|
h3 Credits
|
||||||
// ul
|
ul
|
||||||
// li
|
li
|
||||||
// a(href='https://repl.it/', target='_blank', rel='nofollow') repl.it
|
a(href='https://repl.it/', target='_blank', rel='nofollow') repl.it
|
||||||
// li
|
li
|
||||||
// a(href='https://space.bilibili.com/703007996', target='_blank', title='A-SOUL_Official') A-SOUL
|
a(href='https://space.bilibili.com/703007996', target='_blank', title='A-SOUL_Official') A-SOUL
|
||||||
// li
|
li
|
||||||
// a(href='https://github.com/moebooru/moebooru', target='_blank', rel='nofollow') moebooru
|
a(href='https://github.com/moebooru/moebooru', target='_blank', rel='nofollow') moebooru
|
||||||
// li
|
li
|
||||||
// a(href='javascript:alert("!!! NSFW LINK !!!\\nPlease enter the url manually")') rule34.xxx
|
a(href='javascript:alert("!!! NSFW LINK !!!\\nPlease enter the url manually")') rule34.xxx
|
||||||
// | NSFW
|
| NSFW
|
||||||
// li
|
li
|
||||||
// a(href='javascript:alert("!!! NSFW LINK !!!\\nPlease enter the url manually")') gelbooru.com
|
a(href='javascript:alert("!!! NSFW LINK !!!\\nPlease enter the url manually")') gelbooru.com
|
||||||
// | NSFW
|
| NSFW
|
||||||
// li
|
li
|
||||||
// a(href='https://icons8.com/icons/set/star', target='_blank', rel='nofollow') Icons8
|
a(href='https://icons8.com/icons/set/star', target='_blank', rel='nofollow') Icons8
|
||||||
|
|
||||||
h3 Tool
|
h3 Tool
|
||||||
.tool
|
.tool
|
||||||
code #{site}/get/@
|
code https://count.getloli.com/get/@
|
||||||
input#name(type='text', placeholder=':name', style='display: inline-block; width: 80px; height: 1.4em; line-height: 1.4em; margin: 0 4px; vertical-align: middle;')
|
input#name(type='text', placeholder=':name', style='display: inline-block; width: 80px; height: 1.4em; line-height: 1.4em; margin: 0 4px; vertical-align: middle;')
|
||||||
code ?theme=
|
code ?theme=
|
||||||
select#theme(style='display: inline-block; height: 1.6em; line-height: 1.6em; font-size: 14px; margin: 0 4px; padding: 0 4px; vertical-align: middle;')
|
select#theme(style='display: inline-block; height: 1.6em; line-height: 1.6em; font-size: 14px; margin: 0 4px; padding: 0 4px; vertical-align: middle;')
|
||||||
option(value='asoul') asoul
|
option(value='asoul') asoul
|
||||||
option(value='moebooru') moebooru
|
option(value='moebooru') moebooru
|
||||||
option(value='moebooru-h') moebooru-h
|
|
||||||
option(value='rule34') rule34
|
option(value='rule34') rule34
|
||||||
option(value='gelbooru') gelbooru
|
option(value='gelbooru') gelbooru
|
||||||
option(value='gelbooru-h') gelbooru-h
|
|
||||||
button#get(style='margin: 10px 0;', onclick='_evt_push("click", "normal", "get_counter")') Get
|
button#get(style='margin: 10px 0;', onclick='_evt_push("click", "normal", "get_counter")') Get
|
||||||
img#result(style='display: block;')
|
img#result(style='display: block;')
|
||||||
|
|
||||||
|
@ -92,10 +97,10 @@ html
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
img.src = '#{site}/get/@' + text + '?theme=' + theme
|
img.src = 'https://count.getloli.com/get/@' + text + '?theme=' + theme
|
||||||
})
|
})
|
||||||
|
|
||||||
|
iframe(src="https://chat.getloli.com/room/@Moe-counter?title=%E8%90%8C%E8%90%8C%E8%AE%A1%E6%95%B0%E5%99%A8%E7%9A%84%E7%95%99%E8%A8%80%E6%9D%BF", scrolling="no", frameborder="0", height="70%", width="26%", style="position: fixed;top: 2%;right: 5%;")
|
||||||
|
|
||||||
p.copy
|
p.copy
|
||||||
a(href='https://github.com/journey-ad/Moe-Counter', target='_blank', onclick='_evt_push("click", "normal", "go_github")') source code
|
a(href='https://github.com/journey-ad/Moe-Counter', target='_blank', onclick='_evt_push("click", "normal", "go_github")') source code
|
||||||
p.copy
|
|
||||||
a(href='https://git.zzls.xyz/Fijxu/Moe-Counter', target='_blank', onclick='_evt_push("click", "normal", "go_github")') Modified source code
|
|