Make welcome email editable in admin and skip admin notice for newsletter signups
This commit is contained in:
@@ -203,6 +203,24 @@ const FIELDS: Array<{ key: StringField; label: string; multiline?: boolean; sect
|
||||
{ key: 'platformAmazonUrl', label: 'Platform — Amazon Music URL', section: 'global' },
|
||||
{ key: 'platformFacebookUrl', label: 'Platform — Facebook URL', section: 'global' },
|
||||
{ key: 'platformCreatorUrl', label: 'Platform — Creator Profile URL', section: 'global' },
|
||||
{ key: 'welcomeEmailSubject', label: 'Welcome Email — Subject', section: 'global' },
|
||||
{ key: 'welcomeEmailGreetingPrefix', label: 'Welcome Email — Greeting Prefix', section: 'global' },
|
||||
{ key: 'welcomeEmailIntro', label: 'Welcome Email — Intro Paragraph', multiline: true, section: 'global' },
|
||||
{ key: 'welcomeEmailCurrentSeries', label: 'Welcome Email — Current Series Paragraph', multiline: true, section: 'global' },
|
||||
{ key: 'welcomeEmailStartHereTitle', label: 'Welcome Email — Start Here Title', section: 'global' },
|
||||
{ key: 'welcomeEmailStartHereSummary', label: 'Welcome Email — Start Here Summary', multiline: true, section: 'global' },
|
||||
{ key: 'welcomeEmailStartHereUrl', label: 'Welcome Email — Start Here URL', section: 'global' },
|
||||
{ key: 'welcomeEmailSpotifyUrl', label: 'Welcome Email — Spotify URL', section: 'global' },
|
||||
{ key: 'welcomeEmailAppleUrl', label: 'Welcome Email — Apple URL', section: 'global' },
|
||||
{ key: 'welcomeEmailAmazonUrl', label: 'Welcome Email — Amazon URL', section: 'global' },
|
||||
{ key: 'welcomeEmailWebsiteUrl', label: 'Welcome Email — Website URL', section: 'global' },
|
||||
{ key: 'welcomeEmailImageUrl', label: 'Welcome Email — Image URL', section: 'global' },
|
||||
{ key: 'welcomeEmailWhatToExpect1', label: 'Welcome Email — What to Expect 1', multiline: true, section: 'global' },
|
||||
{ key: 'welcomeEmailWhatToExpect2', label: 'Welcome Email — What to Expect 2', multiline: true, section: 'global' },
|
||||
{ key: 'welcomeEmailWhatToExpect3', label: 'Welcome Email — What to Expect 3', multiline: true, section: 'global' },
|
||||
{ key: 'welcomeEmailScripture', label: 'Welcome Email — Scripture Text', multiline: true, section: 'global' },
|
||||
{ key: 'welcomeEmailScriptureRef', label: 'Welcome Email — Scripture Reference', section: 'global' },
|
||||
{ key: 'welcomeEmailSignoff', label: 'Welcome Email — Signoff HTML', multiline: true, section: 'global' },
|
||||
]
|
||||
|
||||
export default function AdminPage({ content, onSave, onLogout }: Props) {
|
||||
@@ -1949,6 +1967,16 @@ export default function AdminPage({ content, onSave, onLogout }: Props) {
|
||||
</div>
|
||||
))}
|
||||
|
||||
<div className="admin-panel-subhead"><h3>Welcome Email</h3></div>
|
||||
{FIELDS.filter(f => f.section === 'global' && f.key.startsWith('welcomeEmail')).map(({ key, label, multiline }) => (
|
||||
<div className="admin-field" key={key}>
|
||||
<label htmlFor={`field-${key}`}>{label}</label>
|
||||
{multiline
|
||||
? <textarea id={`field-${key}`} value={form[key] as string} onChange={e => handleChange(key, e.target.value)} rows={3} />
|
||||
: <input id={`field-${key}`} type="text" value={form[key] as string} onChange={e => handleChange(key, e.target.value)} />}
|
||||
</div>
|
||||
))}
|
||||
|
||||
{renderSaveStatus()}
|
||||
</section>
|
||||
)}
|
||||
|
||||
@@ -160,6 +160,25 @@ export interface SiteContent {
|
||||
platformAmazonUrl: string
|
||||
platformFacebookUrl: string
|
||||
platformCreatorUrl: string
|
||||
// ── Welcome Email ──
|
||||
welcomeEmailSubject: string
|
||||
welcomeEmailGreetingPrefix: string
|
||||
welcomeEmailIntro: string
|
||||
welcomeEmailCurrentSeries: string
|
||||
welcomeEmailStartHereTitle: string
|
||||
welcomeEmailStartHereSummary: string
|
||||
welcomeEmailStartHereUrl: string
|
||||
welcomeEmailSpotifyUrl: string
|
||||
welcomeEmailAppleUrl: string
|
||||
welcomeEmailAmazonUrl: string
|
||||
welcomeEmailWebsiteUrl: string
|
||||
welcomeEmailImageUrl: string
|
||||
welcomeEmailWhatToExpect1: string
|
||||
welcomeEmailWhatToExpect2: string
|
||||
welcomeEmailWhatToExpect3: string
|
||||
welcomeEmailScripture: string
|
||||
welcomeEmailScriptureRef: string
|
||||
welcomeEmailSignoff: string
|
||||
// ── Header ──
|
||||
headerFollowLabel: string
|
||||
// ── Cookie banner ──
|
||||
@@ -253,6 +272,24 @@ export const DEFAULTS: SiteContent = {
|
||||
platformAmazonUrl: '/amazon',
|
||||
platformFacebookUrl: 'https://facebook.com/versebyversewithnate',
|
||||
platformCreatorUrl: 'https://creators.spotify.com/pod/profile/nmemmert/',
|
||||
welcomeEmailSubject: 'Welcome to Verse by Verse with Nate',
|
||||
welcomeEmailGreetingPrefix: 'Glad you\'re here',
|
||||
welcomeEmailIntro: 'Thanks for subscribing to Verse by Verse with Nate - a Bible teaching podcast where we slow down, dig into the text, and pull out the nuggets God has for us word by word.',
|
||||
welcomeEmailCurrentSeries: 'Right now we\'re working through the book of Titus - a short letter packed with practical wisdom about grace, godliness, and what the Christian life looks like when it\'s rooted in sound doctrine.',
|
||||
welcomeEmailStartHereTitle: 'Episode 1 - Introduction to Titus',
|
||||
welcomeEmailStartHereSummary: 'Who wrote it, who received it, and why it still matters.',
|
||||
welcomeEmailStartHereUrl: '/start-here',
|
||||
welcomeEmailSpotifyUrl: '/spotify',
|
||||
welcomeEmailAppleUrl: '/apple',
|
||||
welcomeEmailAmazonUrl: '/amazon',
|
||||
welcomeEmailWebsiteUrl: 'https://versebyversewithnate.us',
|
||||
welcomeEmailImageUrl: '/images/podcast-art.jpeg',
|
||||
welcomeEmailWhatToExpect1: 'Verse-by-verse teaching - we go slow and let the text speak for itself.',
|
||||
welcomeEmailWhatToExpect2: 'Greek word studies - the kind that open up meaning without being a lecture.',
|
||||
welcomeEmailWhatToExpect3: 'New episodes + study notes delivered right to your inbox.',
|
||||
welcomeEmailScripture: 'For the grace of God has appeared, bringing salvation to all people.',
|
||||
welcomeEmailScriptureRef: 'Titus 2:11 - BSB',
|
||||
welcomeEmailSignoff: 'Grace and peace,\nNate',
|
||||
headerFollowLabel: 'Follow on Spotify',
|
||||
cookieBannerText: 'We use optional analytics cookies to measure visits and location trends for site improvement.',
|
||||
customLinks: [],
|
||||
|
||||
Reference in New Issue
Block a user