Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
de68963f40 | ||
|
|
476e42b919 | ||
|
|
f395e4c951 | ||
|
|
52b9439a14 | ||
|
|
3044db38bb |
@@ -19,10 +19,13 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Check out the repo
|
- name: Check out the repo
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
fetch-tags: true
|
||||||
|
|
||||||
- name: Save version info
|
- name: Save version info
|
||||||
run: |
|
run: |
|
||||||
git describe --tags > VERSION
|
git describe --tags --always > VERSION
|
||||||
|
|
||||||
- name: Log in to Docker Hub
|
- name: Log in to Docker Hub
|
||||||
uses: docker/login-action@v2
|
uses: docker/login-action@v2
|
||||||
@@ -42,7 +45,7 @@ jobs:
|
|||||||
uses: docker/metadata-action@v4
|
uses: docker/metadata-action@v4
|
||||||
with:
|
with:
|
||||||
images: |
|
images: |
|
||||||
justsong/message-pusher
|
zimonianhua/message-pusher
|
||||||
ghcr.io/${{ github.repository }}
|
ghcr.io/${{ github.repository }}
|
||||||
|
|
||||||
- name: Build and push Docker images
|
- name: Build and push Docker images
|
||||||
@@ -51,4 +54,4 @@ jobs:
|
|||||||
context: .
|
context: .
|
||||||
push: true
|
push: true
|
||||||
tags: ${{ steps.meta.outputs.tags }}
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
labels: ${{ steps.meta.outputs.labels }}
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
|
|||||||
@@ -19,10 +19,13 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Check out the repo
|
- name: Check out the repo
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
fetch-tags: true
|
||||||
|
|
||||||
- name: Save version info
|
- name: Save version info
|
||||||
run: |
|
run: |
|
||||||
git describe --tags > VERSION
|
git describe --tags --always > VERSION
|
||||||
|
|
||||||
- name: Set up QEMU
|
- name: Set up QEMU
|
||||||
uses: docker/setup-qemu-action@v2
|
uses: docker/setup-qemu-action@v2
|
||||||
@@ -48,7 +51,7 @@ jobs:
|
|||||||
uses: docker/metadata-action@v4
|
uses: docker/metadata-action@v4
|
||||||
with:
|
with:
|
||||||
images: |
|
images: |
|
||||||
justsong/message-pusher
|
zimonianhua/message-pusher
|
||||||
ghcr.io/${{ github.repository }}
|
ghcr.io/${{ github.repository }}
|
||||||
|
|
||||||
- name: Build and push Docker images
|
- name: Build and push Docker images
|
||||||
@@ -58,4 +61,4 @@ jobs:
|
|||||||
platforms: linux/amd64,linux/arm64
|
platforms: linux/amd64,linux/arm64
|
||||||
push: true
|
push: true
|
||||||
tags: ${{ steps.meta.outputs.tags }}
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
labels: ${{ steps.meta.outputs.labels }}
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
|
|||||||
@@ -16,14 +16,14 @@ jobs:
|
|||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
- uses: actions/setup-node@v3
|
- uses: actions/setup-node@v3
|
||||||
with:
|
with:
|
||||||
node-version: 16
|
node-version: 18
|
||||||
- name: Build Frontend
|
- name: Build Frontend
|
||||||
env:
|
env:
|
||||||
CI: ""
|
CI: ""
|
||||||
run: |
|
run: |
|
||||||
cd web
|
cd web
|
||||||
npm install
|
npm install
|
||||||
REACT_APP_VERSION=$(git describe --tags) npm run build
|
REACT_APP_VERSION=$(git describe --tags --always) npm run build
|
||||||
cd ..
|
cd ..
|
||||||
- name: Set up Go
|
- name: Set up Go
|
||||||
uses: actions/setup-go@v3
|
uses: actions/setup-go@v3
|
||||||
@@ -32,12 +32,12 @@ jobs:
|
|||||||
- name: Build Backend (amd64)
|
- name: Build Backend (amd64)
|
||||||
run: |
|
run: |
|
||||||
go mod download
|
go mod download
|
||||||
go build -ldflags "-s -w -X 'message-pusher/common.Version=$(git describe --tags)' -extldflags '-static'" -o message-pusher
|
go build -ldflags "-s -w -X 'message-pusher/common.Version=$(git describe --tags --always)' -extldflags '-static'" -o message-pusher
|
||||||
- name: Build Backend (arm64)
|
- name: Build Backend (arm64)
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install gcc-aarch64-linux-gnu
|
sudo apt-get install gcc-aarch64-linux-gnu
|
||||||
CC=aarch64-linux-gnu-gcc CGO_ENABLED=1 GOOS=linux GOARCH=arm64 go build -ldflags "-s -w -X 'message-pusher/common.Version=$(git describe --tags)' -extldflags '-static'" -o message-pusher-arm64
|
CC=aarch64-linux-gnu-gcc CGO_ENABLED=1 GOOS=linux GOARCH=arm64 go build -ldflags "-s -w -X 'message-pusher/common.Version=$(git describe --tags --always)' -extldflags '-static'" -o message-pusher-arm64
|
||||||
- name: Release
|
- name: Release
|
||||||
uses: softprops/action-gh-release@v1
|
uses: softprops/action-gh-release@v1
|
||||||
if: startsWith(github.ref, 'refs/tags/')
|
if: startsWith(github.ref, 'refs/tags/')
|
||||||
@@ -48,4 +48,4 @@ jobs:
|
|||||||
draft: true
|
draft: true
|
||||||
generate_release_notes: true
|
generate_release_notes: true
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|||||||
@@ -16,14 +16,14 @@ jobs:
|
|||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
- uses: actions/setup-node@v3
|
- uses: actions/setup-node@v3
|
||||||
with:
|
with:
|
||||||
node-version: 16
|
node-version: 18
|
||||||
- name: Build Frontend
|
- name: Build Frontend
|
||||||
env:
|
env:
|
||||||
CI: ""
|
CI: ""
|
||||||
run: |
|
run: |
|
||||||
cd web
|
cd web
|
||||||
npm install
|
npm install
|
||||||
REACT_APP_VERSION=$(git describe --tags) npm run build
|
REACT_APP_VERSION=$(git describe --tags --always) npm run build
|
||||||
cd ..
|
cd ..
|
||||||
- name: Set up Go
|
- name: Set up Go
|
||||||
uses: actions/setup-go@v3
|
uses: actions/setup-go@v3
|
||||||
@@ -32,7 +32,7 @@ jobs:
|
|||||||
- name: Build Backend
|
- name: Build Backend
|
||||||
run: |
|
run: |
|
||||||
go mod download
|
go mod download
|
||||||
go build -ldflags "-X 'message-pusher/common.Version=$(git describe --tags)'" -o message-pusher-macos
|
go build -ldflags "-X 'message-pusher/common.Version=$(git describe --tags --always)'" -o message-pusher-macos
|
||||||
- name: Release
|
- name: Release
|
||||||
uses: softprops/action-gh-release@v1
|
uses: softprops/action-gh-release@v1
|
||||||
if: startsWith(github.ref, 'refs/tags/')
|
if: startsWith(github.ref, 'refs/tags/')
|
||||||
|
|||||||
@@ -19,14 +19,14 @@ jobs:
|
|||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
- uses: actions/setup-node@v3
|
- uses: actions/setup-node@v3
|
||||||
with:
|
with:
|
||||||
node-version: 16
|
node-version: 18
|
||||||
- name: Build Frontend
|
- name: Build Frontend
|
||||||
env:
|
env:
|
||||||
CI: ""
|
CI: ""
|
||||||
run: |
|
run: |
|
||||||
cd web
|
cd web
|
||||||
npm install
|
npm install
|
||||||
REACT_APP_VERSION=$(git describe --tags) npm run build
|
REACT_APP_VERSION=$(git describe --tags --always) npm run build
|
||||||
cd ..
|
cd ..
|
||||||
- name: Set up Go
|
- name: Set up Go
|
||||||
uses: actions/setup-go@v3
|
uses: actions/setup-go@v3
|
||||||
@@ -35,7 +35,7 @@ jobs:
|
|||||||
- name: Build Backend
|
- name: Build Backend
|
||||||
run: |
|
run: |
|
||||||
go mod download
|
go mod download
|
||||||
go build -ldflags "-s -w -X 'message-pusher/common.Version=$(git describe --tags)'" -o message-pusher.exe
|
go build -ldflags "-s -w -X 'message-pusher/common.Version=$(git describe --tags --always)'" -o message-pusher.exe
|
||||||
- name: Release
|
- name: Release
|
||||||
uses: softprops/action-gh-release@v1
|
uses: softprops/action-gh-release@v1
|
||||||
if: startsWith(github.ref, 'refs/tags/')
|
if: startsWith(github.ref, 'refs/tags/')
|
||||||
@@ -44,4 +44,4 @@ jobs:
|
|||||||
draft: true
|
draft: true
|
||||||
generate_release_notes: true
|
generate_release_notes: true
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|||||||
+2
-1
@@ -1,8 +1,9 @@
|
|||||||
FROM node:16 as builder
|
FROM node:18 AS builder
|
||||||
|
|
||||||
WORKDIR /build
|
WORKDIR /build
|
||||||
COPY ./web .
|
COPY ./web .
|
||||||
COPY ./VERSION .
|
COPY ./VERSION .
|
||||||
|
RUN corepack enable && corepack prepare yarn@1.22.22 --activate
|
||||||
RUN yarn install
|
RUN yarn install
|
||||||
RUN REACT_APP_VERSION=$(cat VERSION) yarn build
|
RUN REACT_APP_VERSION=$(cat VERSION) yarn build
|
||||||
|
|
||||||
|
|||||||
+40
-5
@@ -26,7 +26,17 @@ func newHTTPClient(proxyAddress string, timeout time.Duration) (*http.Client, er
|
|||||||
func newHTTPTransport(proxyAddress string) (*http.Transport, error) {
|
func newHTTPTransport(proxyAddress string) (*http.Transport, error) {
|
||||||
base, ok := http.DefaultTransport.(*http.Transport)
|
base, ok := http.DefaultTransport.(*http.Transport)
|
||||||
if !ok {
|
if !ok {
|
||||||
return &http.Transport{}, nil
|
return &http.Transport{
|
||||||
|
DialContext: (&net.Dialer{
|
||||||
|
Timeout: 10 * time.Second,
|
||||||
|
KeepAlive: 30 * time.Second,
|
||||||
|
}).DialContext,
|
||||||
|
ForceAttemptHTTP2: true,
|
||||||
|
MaxIdleConns: 100,
|
||||||
|
IdleConnTimeout: 90 * time.Second,
|
||||||
|
TLSHandshakeTimeout: 10 * time.Second,
|
||||||
|
ExpectContinueTimeout: 1 * time.Second,
|
||||||
|
}, nil
|
||||||
}
|
}
|
||||||
transport := base.Clone()
|
transport := base.Clone()
|
||||||
proxyAddress = strings.TrimSpace(proxyAddress)
|
proxyAddress = strings.TrimSpace(proxyAddress)
|
||||||
@@ -46,15 +56,40 @@ func newHTTPTransport(proxyAddress string) (*http.Transport, error) {
|
|||||||
transport.Proxy = http.ProxyURL(u)
|
transport.Proxy = http.ProxyURL(u)
|
||||||
return transport, nil
|
return transport, nil
|
||||||
case "socks5", "socks5h":
|
case "socks5", "socks5h":
|
||||||
normalized := *u
|
var auth *proxy.Auth
|
||||||
normalized.Scheme = "socks5"
|
if u.User != nil {
|
||||||
dialer, err := proxy.FromURL(&normalized, proxy.Direct)
|
auth = &proxy.Auth{
|
||||||
|
User: u.User.Username(),
|
||||||
|
Password: "",
|
||||||
|
}
|
||||||
|
if password, ok := u.User.Password(); ok {
|
||||||
|
auth.Password = password
|
||||||
|
}
|
||||||
|
}
|
||||||
|
dialer, err := proxy.SOCKS5("tcp", u.Host, auth, &net.Dialer{
|
||||||
|
Timeout: 10 * time.Second,
|
||||||
|
KeepAlive: 30 * time.Second,
|
||||||
|
})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
transport.Proxy = nil
|
transport.Proxy = nil
|
||||||
transport.DialContext = func(ctx context.Context, network, addr string) (net.Conn, error) {
|
transport.DialContext = func(ctx context.Context, network, addr string) (net.Conn, error) {
|
||||||
return dialer.Dial(network, addr)
|
type dialResult struct {
|
||||||
|
conn net.Conn
|
||||||
|
err error
|
||||||
|
}
|
||||||
|
ch := make(chan dialResult, 1)
|
||||||
|
go func() {
|
||||||
|
conn, err := dialer.Dial(network, addr)
|
||||||
|
ch <- dialResult{conn: conn, err: err}
|
||||||
|
}()
|
||||||
|
select {
|
||||||
|
case <-ctx.Done():
|
||||||
|
return nil, ctx.Err()
|
||||||
|
case r := <-ch:
|
||||||
|
return r.conn, r.err
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return transport, nil
|
return transport, nil
|
||||||
default:
|
default:
|
||||||
|
|||||||
+1
-1
@@ -25,7 +25,7 @@ type telegramMessageResponse struct {
|
|||||||
|
|
||||||
func SendTelegramMessage(message *model.Message, user *model.User, channel_ *model.Channel) error {
|
func SendTelegramMessage(message *model.Message, user *model.User, channel_ *model.Channel) error {
|
||||||
// https://core.telegram.org/bots/api#sendmessage
|
// https://core.telegram.org/bots/api#sendmessage
|
||||||
client, err := newHTTPClient(channel_.URL, 10*time.Second)
|
client, err := newHTTPClient(channel_.URL, 30*time.Second)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ func (i *WeChatCorpAccountTokenStoreItem) Token() string {
|
|||||||
|
|
||||||
func (i *WeChatCorpAccountTokenStoreItem) Refresh() {
|
func (i *WeChatCorpAccountTokenStoreItem) Refresh() {
|
||||||
// https://work.weixin.qq.com/api/doc/90000/90135/91039
|
// https://work.weixin.qq.com/api/doc/90000/90135/91039
|
||||||
client, err := newHTTPClient(i.Proxy, 5*time.Second)
|
client, err := newHTTPClient(i.Proxy, 30*time.Second)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
common.SysError("failed to create http client: " + err.Error())
|
common.SysError("failed to create http client: " + err.Error())
|
||||||
return
|
return
|
||||||
@@ -159,7 +159,7 @@ func SendWeChatCorpMessage(message *model.Message, user *model.User, channel_ *m
|
|||||||
Proxy: proxyAddress,
|
Proxy: proxyAddress,
|
||||||
}
|
}
|
||||||
accessToken := TokenStoreGetToken(tokenItem.Key())
|
accessToken := TokenStoreGetToken(tokenItem.Key())
|
||||||
client, err := newHTTPClient(proxyAddress, 10*time.Second)
|
client, err := newHTTPClient(proxyAddress, 30*time.Second)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|||||||
+19
-18
@@ -7,25 +7,26 @@
|
|||||||
<title>{{.title}}</title>
|
<title>{{.title}}</title>
|
||||||
<meta name="description" content="{{.description}}">
|
<meta name="description" content="{{.description}}">
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body class="liquid-glass-container">
|
||||||
|
<div class="wrapper">
|
||||||
<div>
|
<!-- Liquid Glass Card -->
|
||||||
<div class="article-container" style="max-width: 960px">
|
<div class="liquid-glass" style="position: relative; overflow: hidden;">
|
||||||
<div class="columns is-desktop">
|
<!-- Edge Highlight Effect -->
|
||||||
<div class="column">
|
<div class="liquid-glass-highlight"></div>
|
||||||
<article id="article">
|
|
||||||
<h1 class="title is-3 is-4-mobile">{{.title}}</h1>
|
<article id="article">
|
||||||
<div class="info">
|
<h1 class="title">{{.title}}</h1>
|
||||||
<span class="line">发布于:<span class="tag is-light">{{.time}}</span></span>
|
<div class="info">
|
||||||
</div>
|
<span class="line">发布于:<span class="liquid-glass-pill">{{.time}}</span></span>
|
||||||
<blockquote>
|
</div>
|
||||||
{{.description | unescape}}
|
<blockquote>
|
||||||
</blockquote>
|
{{.description | unescape}}
|
||||||
|
</blockquote>
|
||||||
|
<div class="content-body">
|
||||||
{{.content | unescape}}
|
{{.content | unescape}}
|
||||||
</article>
|
</div>
|
||||||
</div>
|
</article>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+170
-346
@@ -1,399 +1,223 @@
|
|||||||
body {
|
/* Liquid Glass Global Styles */
|
||||||
font-family: Verdana, Candara, Arial, Helvetica, Microsoft YaHei, sans-serif;
|
|
||||||
line-height: 1.6;
|
/* 液态玻璃变量 */
|
||||||
margin: 0;
|
:root {
|
||||||
|
--liquid-glass-bg: rgba(255, 255, 255, 0.15);
|
||||||
|
--liquid-glass-bg-hover: rgba(255, 255, 255, 0.25);
|
||||||
|
--liquid-glass-border: rgba(255, 255, 255, 0.3);
|
||||||
|
--liquid-glass-ring: rgba(255, 255, 255, 0.2);
|
||||||
|
--liquid-glass-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
|
||||||
|
--liquid-glass-blur: 40px; /* backdrop-blur-2xl/3xl */
|
||||||
|
--liquid-glass-saturate: 1.5;
|
||||||
|
|
||||||
|
--text-primary: #ffffff;
|
||||||
|
--text-secondary: rgba(255, 255, 255, 0.8);
|
||||||
|
--link-color: #60a5fa; /* blue-400 */
|
||||||
|
--link-hover-color: #93c5fd; /* blue-300 */
|
||||||
}
|
}
|
||||||
|
|
||||||
nav {
|
/* 基础液态玻璃类 */
|
||||||
margin-bottom: 16px;
|
.liquid-glass {
|
||||||
|
background: var(--liquid-glass-bg);
|
||||||
|
backdrop-filter: blur(var(--liquid-glass-blur)) saturate(var(--liquid-glass-saturate));
|
||||||
|
-webkit-backdrop-filter: blur(var(--liquid-glass-blur)) saturate(var(--liquid-glass-saturate));
|
||||||
|
border: 1px solid var(--liquid-glass-border);
|
||||||
|
box-shadow:
|
||||||
|
var(--liquid-glass-shadow),
|
||||||
|
inset 0 1px 1px rgba(255, 255, 255, 0.25);
|
||||||
|
border-radius: 1.5rem; /* rounded-2xl */
|
||||||
|
transition: all 0.3s ease-out;
|
||||||
|
}
|
||||||
|
|
||||||
|
.liquid-glass:hover {
|
||||||
|
background: var(--liquid-glass-bg-hover);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 液态玻璃容器 - 渐变背景 (Blue-Purple) */
|
||||||
|
.liquid-glass-container {
|
||||||
|
background: linear-gradient(135deg, #2563eb 0%, #9333ea 50%, #ec4899 100%);
|
||||||
|
min-height: 100vh;
|
||||||
|
width: 100%;
|
||||||
|
position: relative;
|
||||||
|
overflow-x: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 边缘高光效果 */
|
||||||
|
.liquid-glass-highlight {
|
||||||
|
background-image: linear-gradient(
|
||||||
|
to bottom,
|
||||||
|
rgba(255, 255, 255, 0.15),
|
||||||
|
transparent 50%
|
||||||
|
);
|
||||||
|
pointer-events: none;
|
||||||
|
position: absolute;
|
||||||
|
inset: 0;
|
||||||
|
border-radius: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 胶囊标签样式 */
|
||||||
|
.liquid-glass-pill {
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.375rem;
|
||||||
|
padding: 0.375rem 1rem;
|
||||||
|
background: rgba(255, 255, 255, 0.2);
|
||||||
|
backdrop-filter: blur(16px) saturate(1.5);
|
||||||
|
-webkit-backdrop-filter: blur(16px) saturate(1.5);
|
||||||
|
border: 1px solid rgba(255, 255, 255, 0.3);
|
||||||
|
border-radius: 9999px;
|
||||||
|
font-size: 0.875rem;
|
||||||
|
font-weight: 500;
|
||||||
|
color: white;
|
||||||
|
box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.3);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* General Resets & Typography adapted for Liquid Glass */
|
||||||
|
body {
|
||||||
|
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif;
|
||||||
|
line-height: 1.6;
|
||||||
|
margin: 0;
|
||||||
|
color: var(--text-primary);
|
||||||
}
|
}
|
||||||
|
|
||||||
a {
|
a {
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
color: #007bff;
|
color: var(--link-color);
|
||||||
|
transition: color 0.2s;
|
||||||
}
|
}
|
||||||
|
|
||||||
a:hover {
|
a:hover {
|
||||||
|
color: var(--link-hover-color);
|
||||||
text-decoration: none !important;
|
text-decoration: none !important;
|
||||||
color: #007bff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.page-card-title a {
|
|
||||||
color: #368CCB;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.page-card-title a:hover {
|
|
||||||
color: #368CCB;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Layout */
|
||||||
.wrapper {
|
.wrapper {
|
||||||
max-width: 960px;
|
max-width: 960px;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
|
padding: 2rem 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
#page-container {
|
/* Article Styles */
|
||||||
position: relative;
|
|
||||||
min-height: 97vh;
|
|
||||||
}
|
|
||||||
|
|
||||||
#content-wrap {
|
|
||||||
padding-bottom: 4rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
#footer {
|
|
||||||
height: 4rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
#footer a {
|
|
||||||
/*color: black;*/
|
|
||||||
}
|
|
||||||
|
|
||||||
code {
|
|
||||||
font-family: Consolas, 'Courier New', monospace;
|
|
||||||
}
|
|
||||||
|
|
||||||
.page-card-list {
|
|
||||||
margin: 8px 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.page-card-title {
|
|
||||||
font-size: x-large;
|
|
||||||
font-weight: 500;
|
|
||||||
color: #000000;
|
|
||||||
text-decoration: none;
|
|
||||||
margin-bottom: 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.page-card-text {
|
|
||||||
margin-top: 16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.pagination {
|
|
||||||
margin: 16px 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.pagination a {
|
|
||||||
border: none;
|
|
||||||
overflow: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
.shadow {
|
|
||||||
box-shadow: 0 0.5em 1em -0.125em rgba(10, 10, 10, .1), 0 0 0 1px rgba(10, 10, 10, .02);
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-shadow {
|
|
||||||
box-shadow: 0 2px 3px rgba(26, 26, 26, .1);
|
|
||||||
}
|
|
||||||
|
|
||||||
.paginator div {
|
|
||||||
border: 2px solid #000;
|
|
||||||
cursor: pointer;
|
|
||||||
display: inline-block;
|
|
||||||
min-width: 100px;
|
|
||||||
text-align: center;
|
|
||||||
font-weight: bold;
|
|
||||||
padding: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.box article {
|
|
||||||
overflow-wrap: break-word;
|
|
||||||
/*font-size: larger;*/
|
|
||||||
word-break: break-word;
|
|
||||||
line-height: 1.6;
|
|
||||||
padding: 16px;
|
|
||||||
/*margin-bottom: 16px;*/
|
|
||||||
background-color: #ffffff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.toc-level-1 {
|
|
||||||
list-style-type: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.toc-level-2 {
|
|
||||||
list-style-type: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.toc-level-3 {
|
|
||||||
list-style-type: disc;
|
|
||||||
}
|
|
||||||
|
|
||||||
.toc-level-4 {
|
|
||||||
list-style-type: circle;
|
|
||||||
}
|
|
||||||
|
|
||||||
.toc-level-5 {
|
|
||||||
list-style-type: square;
|
|
||||||
}
|
|
||||||
|
|
||||||
.toc-level-6 {
|
|
||||||
list-style-type: square;
|
|
||||||
}
|
|
||||||
|
|
||||||
img {
|
|
||||||
max-width: 100%;
|
|
||||||
max-height: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.article-container {
|
|
||||||
margin: auto;
|
|
||||||
max-width: 960px;
|
|
||||||
padding: 16px 16px;
|
|
||||||
overflow-wrap: break-word;
|
|
||||||
word-break: break-word;
|
|
||||||
line-height: 1.6;
|
|
||||||
/*font-size: larger;*/
|
|
||||||
}
|
|
||||||
|
|
||||||
article {
|
article {
|
||||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
|
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
line-height: 1.5;
|
line-height: 1.6;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
color: #24292f;
|
color: var(--text-primary);
|
||||||
|
padding: 2rem;
|
||||||
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
article p, article blockquote, article ul, article ol, article dl, article table, article pre, article details {
|
article h1, article h2, article h3, article h4, article h5, article h6 {
|
||||||
margin-top: 0;
|
color: var(--text-primary);
|
||||||
margin-bottom: 16px;
|
margin-top: 1.5em;
|
||||||
}
|
margin-bottom: 0.5em;
|
||||||
|
|
||||||
article ul, article ol {
|
|
||||||
padding-left: 2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
article ul ul, article ul ol, article ol ol, article ol ul {
|
|
||||||
margin-top: 0;
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
article .tag {
|
|
||||||
font-family: Verdana, Candara, Arial, Helvetica, Microsoft YaHei, sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
article a {
|
|
||||||
color: #007bff;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
article a:hover {
|
|
||||||
color: #007bff;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
article h2,
|
|
||||||
article h3,
|
|
||||||
article h4,
|
|
||||||
article h5,
|
|
||||||
article h6 {
|
|
||||||
margin-top: 24px;
|
|
||||||
margin-bottom: 16px;
|
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
line-height: 1.5;
|
|
||||||
margin-block-start: 1em;
|
|
||||||
margin-block-end: 0.2em;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
article h1 {
|
article h1 { font-size: 2.25em; line-height: 1.2; }
|
||||||
font-size: 2em
|
article h2 { font-size: 1.75em; padding-bottom: 0.3em; border-bottom: 1px solid rgba(255,255,255,0.2); }
|
||||||
}
|
article h3 { font-size: 1.5em; }
|
||||||
|
|
||||||
article h2 {
|
.info {
|
||||||
padding-bottom: 0.3em;
|
font-size: 0.9rem;
|
||||||
font-size: 1.5em;
|
color: var(--text-secondary);
|
||||||
}
|
margin-bottom: 1.5rem;
|
||||||
|
display: flex;
|
||||||
article h3 {
|
align-items: center;
|
||||||
font-size: 1.25em
|
|
||||||
}
|
|
||||||
|
|
||||||
article h4 {
|
|
||||||
font-size: 1.25em;
|
|
||||||
}
|
|
||||||
|
|
||||||
article h5 {
|
|
||||||
font-size: 1.1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
article h6 {
|
|
||||||
font-size: 1em;
|
|
||||||
font-weight: bold
|
|
||||||
}
|
|
||||||
|
|
||||||
@media screen and (max-width: 960px) {
|
|
||||||
article h1 {
|
|
||||||
font-size: 1.5em
|
|
||||||
}
|
|
||||||
|
|
||||||
article h2 {
|
|
||||||
font-size: 1.35em
|
|
||||||
}
|
|
||||||
|
|
||||||
article h3 {
|
|
||||||
font-size: 1.3em
|
|
||||||
}
|
|
||||||
|
|
||||||
article h4 {
|
|
||||||
font-size: 1.2em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
article p {
|
|
||||||
margin-top: 0;
|
|
||||||
margin-bottom: 16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
article table {
|
|
||||||
margin: auto;
|
|
||||||
border-collapse: collapse;
|
|
||||||
border-spacing: 0;
|
|
||||||
vertical-align: middle;
|
|
||||||
text-align: left;
|
|
||||||
min-width: 66%;
|
|
||||||
}
|
|
||||||
|
|
||||||
article table td,
|
|
||||||
article table th {
|
|
||||||
padding: 5px 8px;
|
|
||||||
border: 1px solid #bbb;
|
|
||||||
}
|
|
||||||
|
|
||||||
article blockquote {
|
|
||||||
margin-left: 0;
|
|
||||||
padding: 0 1em;
|
|
||||||
border-left: 0.25em solid #ddd;
|
|
||||||
}
|
|
||||||
|
|
||||||
article ol ul {
|
|
||||||
list-style-type: circle;
|
|
||||||
}
|
|
||||||
|
|
||||||
article pre {
|
|
||||||
max-width: 960px;
|
|
||||||
display: block;
|
|
||||||
overflow: auto;
|
|
||||||
padding: 0;
|
|
||||||
margin-top: 12px;
|
|
||||||
margin-bottom: 12px;
|
|
||||||
border-radius: 6px;
|
|
||||||
}
|
|
||||||
|
|
||||||
article pre code {
|
|
||||||
font-size: 14px;
|
|
||||||
}
|
|
||||||
|
|
||||||
article ol {
|
|
||||||
text-decoration: none;
|
|
||||||
padding-inline-start: 40px;
|
|
||||||
margin-bottom: 1.25rem;
|
|
||||||
padding-left: 2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
article ul {
|
|
||||||
padding-left: 2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
article li + li {
|
|
||||||
margin-top: 0.25em;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Code Blocks */
|
||||||
code {
|
code {
|
||||||
font-family: "JetBrains Mono", "Cascadia Code", Consolas, Microsoft YaHei, monospace;
|
font-family: "JetBrains Mono", "Cascadia Code", Consolas, monospace;
|
||||||
|
font-size: 0.9em;
|
||||||
}
|
}
|
||||||
|
|
||||||
article code {
|
article code {
|
||||||
color: #24292f;
|
background: rgba(0, 0, 0, 0.2);
|
||||||
background-color: rgb(175 184 193 / 20%);
|
color: #e2e8f0;
|
||||||
padding: .065em .4em;
|
padding: 0.2em 0.4em;
|
||||||
border-radius: 6px;
|
border-radius: 0.375rem;
|
||||||
font-family: "JetBrains Mono", "Cascadia Code", Consolas, Microsoft YaHei, monospace;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
article .copyright {
|
article pre {
|
||||||
display: none;
|
background: rgba(0, 0, 0, 0.25);
|
||||||
}
|
padding: 1rem;
|
||||||
|
border-radius: 0.75rem;
|
||||||
.info {
|
|
||||||
font-size: 14px;
|
|
||||||
line-height: 28px;
|
|
||||||
text-align: left;
|
|
||||||
color: #738292;
|
|
||||||
margin-bottom: 24px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info a {
|
|
||||||
text-decoration: none;
|
|
||||||
color: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Code Page Style*/
|
|
||||||
.code-page {
|
|
||||||
margin-top: 32px;
|
|
||||||
padding-left: 16px;
|
|
||||||
padding-right: 16px;
|
|
||||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
|
|
||||||
}
|
|
||||||
|
|
||||||
.code-page code {
|
|
||||||
font-size: 16px;
|
|
||||||
width: 100%;
|
|
||||||
height: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.code-page pre {
|
|
||||||
margin-top: 2px;
|
|
||||||
overflow-x: auto;
|
overflow-x: auto;
|
||||||
|
margin: 1rem 0;
|
||||||
|
border: 1px solid rgba(255, 255, 255, 0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
article pre code {
|
||||||
|
background: transparent;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
font-size: 16px;
|
color: inherit;
|
||||||
background-color: rgba(0, 0, 0, 0);
|
font-size: 0.9em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.code-page .control-panel {
|
/* Blockquotes */
|
||||||
|
article blockquote {
|
||||||
|
margin: 1rem 0;
|
||||||
|
padding: 0.5rem 1rem;
|
||||||
|
border-left: 4px solid rgba(255, 255, 255, 0.4);
|
||||||
|
background: rgba(255, 255, 255, 0.05);
|
||||||
|
border-radius: 0 0.5rem 0.5rem 0;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Tables */
|
||||||
|
article table {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
border-collapse: collapse;
|
||||||
|
margin: 1rem 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#code-display {
|
article table th, article table td {
|
||||||
padding: 16px 24px;
|
border: 1px solid rgba(255, 255, 255, 0.2);
|
||||||
|
padding: 0.75rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.discuss h1 {
|
article table th {
|
||||||
font-size: 24px;
|
background: rgba(255, 255, 255, 0.1);
|
||||||
line-height: 36px;
|
font-weight: 600;
|
||||||
text-align: left;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.discuss .time {
|
/* Images */
|
||||||
font-size: 12px;
|
img {
|
||||||
line-height: 18px;
|
max-width: 100%;
|
||||||
text-align: left;
|
height: auto;
|
||||||
color: #738292;
|
border-radius: 0.75rem;
|
||||||
|
box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
|
||||||
}
|
}
|
||||||
|
|
||||||
.discuss .content {
|
/* Helpers */
|
||||||
font-size: 16px;
|
.shadow {
|
||||||
line-height: 24px;
|
box-shadow: var(--liquid-glass-shadow);
|
||||||
text-align: left;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.raw {
|
/* Specific elements from original CSS that might be needed */
|
||||||
padding: 16px;
|
.columns {
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
.column {
|
||||||
|
width: 100%;
|
||||||
|
max-width: 960px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.raw .raw-content {
|
/* Scrollbar customization for webkit */
|
||||||
overflow-y: hidden;
|
::-webkit-scrollbar {
|
||||||
overflow-x: scroll;
|
width: 8px;
|
||||||
|
height: 8px;
|
||||||
}
|
}
|
||||||
|
::-webkit-scrollbar-track {
|
||||||
.links {
|
background: rgba(255, 255, 255, 0.1);
|
||||||
margin: 16px;
|
|
||||||
}
|
}
|
||||||
|
::-webkit-scrollbar-thumb {
|
||||||
span.line {
|
background: rgba(255, 255, 255, 0.3);
|
||||||
display: inline-block;
|
border-radius: 4px;
|
||||||
|
}
|
||||||
|
::-webkit-scrollbar-thumb:hover {
|
||||||
|
background: rgba(255, 255, 255, 0.5);
|
||||||
}
|
}
|
||||||
|
|
||||||
.toc {
|
|
||||||
position: sticky;
|
|
||||||
top: 24px;
|
|
||||||
}
|
|
||||||
+1
-1
@@ -2,7 +2,7 @@ version: "3"
|
|||||||
|
|
||||||
services:
|
services:
|
||||||
message-pusher:
|
message-pusher:
|
||||||
image: justsong/message-pusher
|
image: zimonianhua/message-pusher
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
ports:
|
ports:
|
||||||
- 3000:3000
|
- 3000:3000
|
||||||
|
|||||||
Reference in New Issue
Block a user