feat(config): add news page and widget configuration

This commit is contained in:
Prad Nukala
2026-06-28 13:50:15 -04:00
parent f9f6e84969
commit c46e5fa1fa
14 changed files with 135 additions and 85 deletions
+16 -10
View File
@@ -1,7 +1,17 @@
server: server:
assets-path: /app/assets assets-path: /app/assets
branding:
custom-footer: |
<p>Powered by <a href="https://github.com/glanceapp/glance">Glance</a></p>
logo-url: /assets/logo.png
favicon-url: /assets/logo.png
app-name: "My Dashboard"
app-icon-url: "/assets/app-icon.png"
app-background-color: "#151519"
theme: theme:
custom-css-file: /assets/newspaper.css
background-color: 240 27 11 background-color: 240 27 11
contrast-multiplier: 1.5 contrast-multiplier: 1.5
primary-color: 321 100 71 primary-color: 321 100 71
@@ -9,14 +19,14 @@ theme:
negative-color: 360 100 71 negative-color: 360 100 71
pages: pages:
- name: Today - name: News
width: wide width: wide
head-widgets: head-widgets:
- $include: ./today/header.yml - $include: ./news/header.yml
columns: columns:
- $include: ./today/left.yml - $include: ./news/left.yml
- $include: ./today/main.yml - $include: ./news/main.yml
- $include: ./today/right.yml - $include: ./news/right.yml
- name: Finance - name: Finance
head-widgets: head-widgets:
@@ -32,11 +42,7 @@ pages:
- $include: ./developer/main.yml - $include: ./developer/main.yml
- $include: ./developer/right.yml - $include: ./developer/right.yml
- name: Movies - name: Media
columns: columns:
- $include: ./media/movies.yml - $include: ./media/movies.yml
- name: TV
columns:
- $include: ./media/tv.yml - $include: ./media/tv.yml
+21
View File
@@ -0,0 +1,21 @@
# Masthead + markets ticker — the newspaper banner
- type: html
source: |
<div class="masthead">
<div class="masthead-rule"></div>
<div class="masthead-title">The Daily Glance</div>
<div class="masthead-sub">Tech · Markets · Crypto</div>
<div class="masthead-rule"></div>
</div>
- type: markets
hide-header: true
markets:
- symbol: BTC-USD
name: Bitcoin
- symbol: ETH-USD
name: Ethereum
- symbol: MAGS
name: Mag7
- symbol: QQQ
name: Nasdaq
@@ -1,3 +1,4 @@
# Left rail — weather corner, work agenda, world clocks
- size: small - size: small
widgets: widgets:
- type: weather - type: weather
@@ -14,12 +15,3 @@
label: Singapore label: Singapore
- timezone: Europe/London - timezone: Europe/London
label: London label: London
- type: rss
title: Deals
limit: 10
collapse-after: 2
feeds:
- url: https://rss.app/feeds/rb0smDdeyhIkusel.xml
title: Crypto Fundraising
@@ -1,13 +1,16 @@
# Right rail — datebook, macro rates box, and the news wire
- size: small - size: small
widgets: widgets:
- type: to-do
- type: calendar - type: calendar
first-day-of-week: sunday first-day-of-week: sunday
- $include: ./widgets/ical-personal.yml - $include: ./widgets/ical-personal.yml
- $include: ./widgets/rates.yml
- type: rss - type: rss
title: Crypto title: The Wire
limit: 20 limit: 20
collapse-after: 5 collapse-after: 5
feeds: feeds:
- url: https://rss.app/feeds/wiGtpLZuOjLgKlC4.xml - url: https://rss.app/feeds/wiGtpLZuOjLgKlC4.xml
title: WatcherGuru title: Watcher Guru
- url: https://rss.app/feeds/rb0smDdeyhIkusel.xml
title: Crypto Fundraising
+51
View File
@@ -0,0 +1,51 @@
# Front page — newspaper sections as clean tabs.
# detailed-list gives the headline + blurb + section look of a printed page.
- type: group
widgets:
- type: rss
title: Front Page
style: detailed-list
limit: 15
collapse-after: 6
feeds:
- url: https://www.techmeme.com/feed.xml
title: Techmeme
- url: https://www.ft.com/technology?format=rss
title: Financial Times
- url: https://feeds.a.dj.com/rss/RSSMarketsMain.xml
title: Wall Street Journal
- type: rss
title: Tech
style: detailed-list
limit: 20
collapse-after: 6
feeds:
- url: https://www.techmeme.com/feed.xml
title: Techmeme
- url: https://terminaltrove.com/new.xml
title: Terminal Trove
- url: https://rss.app/feeds/_tBKt0Q2vzII4baWl.xml
title: Product Hunt
- type: rss
title: Markets
style: detailed-list
limit: 20
collapse-after: 6
feeds:
- url: https://feeds.a.dj.com/rss/RSSMarketsMain.xml
title: Wall Street Journal
- url: https://www.ft.com/technology?format=rss
title: Financial Times
- type: rss
title: Crypto
style: detailed-list
limit: 20
collapse-after: 6
feeds:
- url: https://rss.app/feeds/wiGtpLZuOjLgKlC4.xml
title: Watcher Guru
- url: https://rss.app/feeds/rb0smDdeyhIkusel.xml
title: Crypto Fundraising
+40
View File
@@ -0,0 +1,40 @@
# Macro rates box (St. Louis Fed / FRED). One shared template, three series.
# ponytail: template was copy-pasted 4x across the config — collapsed to one anchor.
define:
fred-template: &fred-template |
{{ $latest := .JSON.Float "observations.0.value" }}
{{ $previous := .JSON.Float "observations.1.value" }}
{{ $lastObserve := .JSON.String "observations.0.date" }}
{{ $change := sub $latest $previous }}
<div class="flex justify-between items-center gap-15">
<div class="min-width-0">
<a class="size-h3 block color-highlight" href="https://fred.stlouisfed.org/" target="_blank" rel="noreferrer">
{{ .JSON.String "observations.0.value" }}%
</a>
<div class="text-truncate">St. Louis Federal Reserve</div>
</div>
<div class="shrink-0">
<div class="size-h3 text-right {{ if lt $change 0.0 }}color-positive{{ else if gt $change 0.0 }}color-negative{{ end }}">
{{ printf "%+.2f" $change }}%
</div>
<div class="text-right" title="As of {{ $lastObserve }}" {{ $lastObserve | parseRelativeTime "DateOnly" }}></div>
</div>
</div>
- type: custom-api
title: Secured Financing Rate
cache: 12h
url: https://api.stlouisfed.org/fred/series/observations?series_id=SOFR&api_key=${FRED_API_KEY}&file_type=json&sort_order=desc&limit=2
template: *fred-template
- type: custom-api
title: Federal Funds Rate
cache: 12h
url: https://api.stlouisfed.org/fred/series/observations?series_id=FEDFUNDS&api_key=${FRED_API_KEY}&file_type=json&sort_order=desc&limit=2
template: *fred-template
- type: custom-api
title: Real GDP
cache: 12h
url: https://api.stlouisfed.org/fred/series/observations?series_id=A191RL1Q225SBEA&api_key=${FRED_API_KEY}&file_type=json&sort_order=desc&limit=2
template: *fred-template
-11
View File
@@ -1,11 +0,0 @@
- type: markets
hide-header: true
markets:
- symbol: BTC-USD
name: Bitcoin
- symbol: ETH-USD
name: Ethereum
- symbol: MAGS
name: Mag7
- symbol: QQQ
name: Nasdaq
-28
View File
@@ -1,28 +0,0 @@
- type: group
widgets:
- type: rss
title: Crypto
limit: 30
collapse-after: 13
feeds:
- url: https://rss.app/feeds/wiGtpLZuOjLgKlC4.xml
title: WatcherGuru
- type: rss
title: Deals
limit: 30
collapse-after: 13
feeds:
- url: https://rss.app/feeds/rb0smDdeyhIkusel.xml
title: Crypto Fundraising
- type: rss
title: Finance
limit: 30
collapse-after: 13
feeds:
- url: https://www.ft.com/technology?format=rss
title: Financial Times
- url: https://feeds.a.dj.com/rss/RSSMarketsMain.xml
title: Wall Street Journal
-24
View File
@@ -1,24 +0,0 @@
- type: group
widgets:
- type: rss
title: Techmeme
style: horizontal-cards
feeds:
- url: https://www.techmeme.com/feed.xml
title: TechMeme
- type: rss
title: ProductHunt
style: horizontal-cards
feeds:
- url: https://rss.app/feeds/_tBKt0Q2vzII4baWl.xml
title: ProductHunt
- type: rss
title: TerminalTrove
style: horizontal-cards
feeds:
- url: https://terminaltrove.com/new.xml
title: TerminalTrove