Private
Public Access
Implements OPML parsing with defusedxml (untrusted upload, XXE risk) and export with the stdlib's plain ElementTree (trusted, app-generated output). Nesting deeper than one level flattens into its nearest enclosing folder, matching the app's flat-folder model. Import reuses existing Feed/Subscription rows via get_or_create, so re-importing the same file is idempotent and cross-user Feed dedup is preserved. Large imports (>50 entries) dispatch to a Celery task instead of blocking the request; newly imported feeds aren't fetched immediately since they have no last_fetched_at, so the next poll_due_feeds beat cycle picks them up naturally. Adds a Subscriptions page (replacing the standalone "Add feed" link in nav) listing current subscriptions with unsubscribe, plus Import/ Export OPML actions. Verified live: imported a 2-feed/1-folder OPML file against the running dev server (via an authenticated session, since this browser tool has no file-picker automation), confirmed the resulting subscriptions and folder in the UI, exported and inspected the resulting OPML structure, and unsubscribed from one feed. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
287 lines
4.2 KiB
CSS
287 lines
4.2 KiB
CSS
:root {
|
|
color-scheme: light dark;
|
|
font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
|
|
}
|
|
|
|
body {
|
|
margin: 0;
|
|
padding: 1rem;
|
|
max-width: 48rem;
|
|
margin-inline: auto;
|
|
}
|
|
|
|
.messages {
|
|
list-style: none;
|
|
padding: 0;
|
|
}
|
|
|
|
.message {
|
|
padding: 0.5rem 0.75rem;
|
|
border-radius: 0.375rem;
|
|
margin-bottom: 0.5rem;
|
|
}
|
|
|
|
.message-success { background: #d1fae5; color: #065f46; }
|
|
.message-error { background: #fee2e2; color: #991b1b; }
|
|
.message-warning { background: #fef3c7; color: #92400e; }
|
|
.message-info { background: #dbeafe; color: #1e40af; }
|
|
|
|
form p {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 0.25rem;
|
|
}
|
|
|
|
input, button {
|
|
font-size: 1rem;
|
|
padding: 0.5rem;
|
|
}
|
|
|
|
.stream-header {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
flex-wrap: wrap;
|
|
gap: 0.5rem;
|
|
}
|
|
|
|
.top-nav a {
|
|
margin-left: 1rem;
|
|
}
|
|
|
|
.filter-tabs {
|
|
display: flex;
|
|
gap: 0.5rem;
|
|
margin: 1rem 0;
|
|
border-bottom: 1px solid #ddd;
|
|
}
|
|
|
|
.filter-tabs a {
|
|
padding: 0.5rem 0.75rem;
|
|
text-decoration: none;
|
|
color: inherit;
|
|
border-bottom: 2px solid transparent;
|
|
}
|
|
|
|
.filter-tabs a.active {
|
|
border-bottom-color: currentColor;
|
|
font-weight: 600;
|
|
}
|
|
|
|
.article-list {
|
|
list-style: none;
|
|
padding: 0;
|
|
margin: 0;
|
|
}
|
|
|
|
.article-row {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
gap: 0.75rem;
|
|
padding: 0.75rem 0;
|
|
border-bottom: 1px solid #eee;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.article-row.is-read .article-title {
|
|
opacity: 0.55;
|
|
}
|
|
|
|
.article-row-main {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 0.15rem;
|
|
min-width: 0;
|
|
flex: 1;
|
|
}
|
|
|
|
.article-title {
|
|
font-weight: 600;
|
|
text-decoration: none;
|
|
color: inherit;
|
|
}
|
|
|
|
.article-meta {
|
|
font-size: 0.85rem;
|
|
opacity: 0.65;
|
|
}
|
|
|
|
.article-actions {
|
|
display: flex;
|
|
gap: 0.35rem;
|
|
flex-wrap: nowrap;
|
|
}
|
|
|
|
.icon-btn {
|
|
background: none;
|
|
border: 1px solid #ccc;
|
|
border-radius: 0.375rem;
|
|
cursor: pointer;
|
|
padding: 0.35rem 0.6rem;
|
|
font-size: 0.9rem;
|
|
}
|
|
|
|
.icon-btn.active {
|
|
background: #fde68a;
|
|
border-color: #f59e0b;
|
|
}
|
|
|
|
.pagination {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
margin: 1rem 0;
|
|
}
|
|
|
|
.empty-state {
|
|
opacity: 0.6;
|
|
padding: 2rem 0;
|
|
text-align: center;
|
|
}
|
|
|
|
.tag-tabs {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
gap: 0.4rem;
|
|
margin-bottom: 1rem;
|
|
}
|
|
|
|
.tag-pill {
|
|
--tag-color: #6b7280;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 0.3rem;
|
|
padding: 0.2rem 0.6rem;
|
|
border-radius: 999px;
|
|
border: 1px solid var(--tag-color);
|
|
color: var(--tag-color);
|
|
text-decoration: none;
|
|
font-size: 0.85rem;
|
|
}
|
|
|
|
.tag-pill.active {
|
|
background: var(--tag-color);
|
|
color: #111;
|
|
}
|
|
|
|
.tag-remove {
|
|
background: none;
|
|
border: none;
|
|
color: inherit;
|
|
cursor: pointer;
|
|
padding: 0;
|
|
font-size: 1rem;
|
|
line-height: 1;
|
|
}
|
|
|
|
.article-tags {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
align-items: center;
|
|
gap: 0.4rem;
|
|
margin: 1rem 0;
|
|
}
|
|
|
|
.add-tag-form {
|
|
display: inline-flex;
|
|
gap: 0.3rem;
|
|
}
|
|
|
|
.add-tag-form input {
|
|
padding: 0.25rem 0.5rem;
|
|
font-size: 0.85rem;
|
|
width: 8rem;
|
|
}
|
|
|
|
.tag-manage-list {
|
|
list-style: none;
|
|
padding: 0;
|
|
}
|
|
|
|
.tag-manage-list li {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 0.75rem;
|
|
padding: 0.5rem 0;
|
|
border-bottom: 1px solid #eee;
|
|
}
|
|
|
|
.inline-form {
|
|
display: inline;
|
|
}
|
|
|
|
.rule-list {
|
|
list-style: none;
|
|
padding: 0;
|
|
}
|
|
|
|
.rule-row {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
gap: 1rem;
|
|
padding: 0.75rem 0;
|
|
border-bottom: 1px solid #eee;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.rule-row.is-disabled {
|
|
opacity: 0.5;
|
|
}
|
|
|
|
.rule-summary {
|
|
font-size: 0.85rem;
|
|
opacity: 0.75;
|
|
}
|
|
|
|
.rule-actions {
|
|
display: flex;
|
|
gap: 0.35rem;
|
|
}
|
|
|
|
.search-form {
|
|
display: flex;
|
|
gap: 0.5rem;
|
|
margin: 1rem 0;
|
|
}
|
|
|
|
.subscription-list {
|
|
list-style: none;
|
|
padding: 0;
|
|
}
|
|
|
|
.subscription-row {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
gap: 1rem;
|
|
padding: 0.5rem 0;
|
|
border-bottom: 1px solid #eee;
|
|
}
|
|
|
|
.search-form input {
|
|
flex: 1;
|
|
}
|
|
|
|
.article-content {
|
|
line-height: 1.6;
|
|
margin-top: 1rem;
|
|
overflow-wrap: break-word;
|
|
word-break: break-word;
|
|
}
|
|
|
|
.article-content a {
|
|
overflow-wrap: anywhere;
|
|
}
|
|
|
|
.article-content img {
|
|
max-width: 100%;
|
|
}
|
|
|
|
@media (max-width: 480px) {
|
|
.article-row {
|
|
flex-direction: column;
|
|
align-items: flex-start;
|
|
}
|
|
}
|