battlefleet updated
This commit is contained in:
@@ -18,6 +18,8 @@ struct CustomStory: ArticlePage {
|
||||
Text(article.title)
|
||||
.font(.title1)
|
||||
|
||||
Text(article.text)
|
||||
|
||||
if let tagLinks = article.tagLinks() {
|
||||
HStack(spacing: .xSmall) {
|
||||
ForEach(tagLinks) { link in
|
||||
@@ -26,6 +28,5 @@ struct CustomStory: ArticlePage {
|
||||
}
|
||||
}
|
||||
|
||||
Text(article.text)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -19,15 +19,21 @@ struct Story: ArticlePage {
|
||||
.cornerRadius(20)
|
||||
.frame(maxHeight: 300)
|
||||
}
|
||||
|
||||
if let tags = article.tags {
|
||||
Section {
|
||||
Text("Tagged with: \(tags.joined(separator: ", "))")
|
||||
|
||||
Text("\(article.estimatedWordCount) words; \(article.estimatedReadingMinutes) minutes to read.")
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Text(article.text)
|
||||
Divider()
|
||||
Group {
|
||||
HStack {
|
||||
if let tags = article.tags {
|
||||
Text("Tags: \(tags.joined(separator: ", "))")
|
||||
}
|
||||
Spacer()
|
||||
Text("Length: \(article.estimatedWordCount) words/\(article.estimatedReadingMinutes) minutes to read.")
|
||||
|
||||
}
|
||||
Text("Published: \(article.date)")
|
||||
.horizontalAlignment(.center)
|
||||
}
|
||||
.foregroundStyle(.gray)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
//
|
||||
// Footer.swift
|
||||
// IgniteStarter
|
||||
//
|
||||
// Created by Rory on 5/8/26.
|
||||
//
|
||||
import Ignite
|
||||
|
||||
struct Footer: HTML {
|
||||
var body: some HTML {
|
||||
|
||||
HStack {
|
||||
IgniteFooterAlt()
|
||||
Spacer()
|
||||
SocialFooter()
|
||||
Spacer()
|
||||
VersionInfo()
|
||||
}
|
||||
.margin(.top, .xLarge)
|
||||
}
|
||||
}
|
||||
@@ -4,7 +4,7 @@ struct Logo: HTML {
|
||||
private var barTitle: String
|
||||
private var underTitle: String
|
||||
|
||||
init(barTitle: String = "Hinnen", underTitle: String = "Underground") {
|
||||
init(barTitle: String = "", underTitle: String = "") {
|
||||
self.barTitle = barTitle
|
||||
self.underTitle = underTitle
|
||||
}
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
//
|
||||
// Robots.swift
|
||||
// IgniteSamples
|
||||
// https://www.github.com/twostraws/Ignite
|
||||
// See LICENSE for license information.
|
||||
//
|
||||
|
||||
import Foundation
|
||||
import Ignite
|
||||
|
||||
/// An example custom robots.txt configuration file, blocking certain paths
|
||||
/// from Google and Bing, and everything from ChatGPT.
|
||||
struct Robots: RobotsConfiguration {
|
||||
var disallowRules: [DisallowRule]
|
||||
|
||||
init() {
|
||||
let paths = [
|
||||
"/wp-admin"
|
||||
]
|
||||
|
||||
disallowRules = [
|
||||
DisallowRule(robot: .google, paths: paths),
|
||||
DisallowRule(robot: .bing, paths: paths),
|
||||
DisallowRule(robot: .chatGPT)
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -3,15 +3,9 @@ import Ignite
|
||||
struct MainLayout: Layout {
|
||||
var body: some Document {
|
||||
Body {
|
||||
content
|
||||
HStack {
|
||||
IgniteFooterAlt()
|
||||
Spacer()
|
||||
SocialFooter()
|
||||
Spacer()
|
||||
VersionInfo()
|
||||
VStack(alignment: .center) {
|
||||
content
|
||||
}
|
||||
.margin(.top, .xLarge)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,26 +1,37 @@
|
||||
import Ignite
|
||||
import Foundation
|
||||
|
||||
struct Battlefleet: StaticPage {
|
||||
@Environment(\.articles) var articles
|
||||
var path = "/battlefleet"
|
||||
let title: String
|
||||
let subtitle: String
|
||||
|
||||
init() {
|
||||
self.title = "Battlefleet: Subsector Scarus"
|
||||
self.title = "Battlefleet:"
|
||||
self.subtitle = "Subsector Scarus"
|
||||
}
|
||||
|
||||
var body: some HTML {
|
||||
VStack {
|
||||
Logo(barTitle: String(title.split(separator: " ").first ?? ""), underTitle: "Subsector Scarus")
|
||||
Logo(barTitle: title, underTitle: subtitle)
|
||||
.horizontalAlignment(.center)
|
||||
Link("Battlefleet Gothic Remastered Digital Rules", target: "/epubs/BattlefleetGothicDigitalRemaster.epub")
|
||||
Link("Rebels List", target: "article/rebels")
|
||||
Link("About Subsector Scarus", target: "article/scarus")
|
||||
Text("Battlefleet Obscuras: Sector Scarus")
|
||||
Text("Prince Magos Charlemange: Rebel")
|
||||
Text("Prince CuCulain: Eldar Pirates")
|
||||
Text("Chaos Raiders: Thousand Sons")
|
||||
Text("Archeo Xenos: Necrons")
|
||||
Text("Commonwealth: T'au")
|
||||
VStack {
|
||||
Link("Battlefleet Gothic Remastered Digital Rules", target: "/epubs/BattlefleetGothicDigitalRemaster.epub")
|
||||
Text(markdown: "The _Battlefleet: Gothic_ rules formatted for epub.")
|
||||
}
|
||||
.margin(.bottom, .medium)
|
||||
VStack {
|
||||
ForEach(articles.typed("battlefleet").reversed()) { article in
|
||||
Group {
|
||||
Link(article)
|
||||
Text(article.metadata["description"] as? String ?? "")
|
||||
.margin(.bottom, .medium)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
SocialFooter()
|
||||
.margin(.top, .large)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,8 +6,11 @@ struct Home: StaticPage {
|
||||
let buttonHeight = 70
|
||||
|
||||
var body: some HTML {
|
||||
let midtitle = String(title.split(separator: " ").first ?? "")
|
||||
let underTitle = String(title.split(separator: " ").last ?? "")
|
||||
VStack{
|
||||
Logo()
|
||||
Logo(barTitle: midtitle, underTitle: underTitle)
|
||||
.margin(.top, .medium)
|
||||
.horizontalAlignment(.center)
|
||||
Grid(alignment: .center, spacing: 4) {
|
||||
Button(name: "Rory", link: "https://rory.hinnen.us")
|
||||
@@ -24,6 +27,7 @@ struct Home: StaticPage {
|
||||
Button(name: "Battlefleet: Sector Scarus", link: "/battlefleet/")
|
||||
}
|
||||
.margin(.top, .xLarge)
|
||||
Footer()
|
||||
}
|
||||
.horizontalAlignment(.center)
|
||||
Mastodon()
|
||||
|
||||
@@ -12,7 +12,11 @@ struct Theatre: StaticPage {
|
||||
VStack {
|
||||
Logo(barTitle: "Bel Aire", underTitle: "Backyard Theatre")
|
||||
.horizontalAlignment(.center)
|
||||
Text(markdown: """
|
||||
Group {
|
||||
Image("images/SoundOfMusic.jpeg")
|
||||
.frame(width: 300)
|
||||
.style(.float(.self, .left))
|
||||
Text(markdown: """
|
||||
I *love* movies.
|
||||
|
||||
From my very first experiences in a theatre, to hot summer nights at the drive-in, I have always been in love with movies.
|
||||
@@ -25,6 +29,7 @@ As my site is being rebuilt, you'll have to satisfy yourself with just that stor
|
||||
|
||||
*Soon.*
|
||||
""")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -30,6 +30,9 @@ struct Hinnen: Site {
|
||||
|
||||
var favicon: URL? { URL(static: "/favicon/favicon.ico") }
|
||||
|
||||
var robotsConfiguration = Robots()
|
||||
var feedConfiguration = FeedConfiguration(mode: .full, contentCount: 20, image: .init(url: "https://www.example.com/images/icon32.png", width: 32, height: 32))
|
||||
|
||||
var staticPages: [any StaticPage] {
|
||||
Battlefleet()
|
||||
Library()
|
||||
|
||||
Reference in New Issue
Block a user