domma-cms 1.21.0 → 1.22.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/admin/css/site-settings.css +1 -0
- package/admin/js/app.js +3 -3
- package/admin/js/lib/context-menu-action-help.js +1 -1
- package/admin/js/lib/effects-builder.js +2 -2
- package/admin/js/lib/favicon-generator.js +1 -1
- package/admin/js/lib/font-picker.js +22 -0
- package/admin/js/lib/scribe-composer.js +1 -1
- package/admin/js/lib/shortcode-form.js +3 -3
- package/admin/js/lib/site-search-section.js +1 -1
- package/admin/js/lib/site-settings-arrange.js +3 -3
- package/admin/js/templates/appearance.html +243 -0
- package/admin/js/templates/docs/usage-site-settings.html +11 -22
- package/admin/js/templates/footer.html +145 -0
- package/admin/js/templates/menu-editor.html +42 -2
- package/admin/js/templates/search.html +14 -15
- package/admin/js/templates/settings.html +5 -436
- package/admin/js/views/appearance.js +1 -0
- package/admin/js/views/footer.js +1 -0
- package/admin/js/views/index.js +1 -1
- package/admin/js/views/menu-editor.js +20 -20
- package/admin/js/views/page-editor.js +10 -10
- package/admin/js/views/search.js +2 -2
- package/admin/js/views/settings.js +3 -3
- package/admin/js/views/theme.js +4 -4
- package/docs/screenshots/font-picker-desktop.png +0 -0
- package/docs/screenshots/font-picker-mobile.png +0 -0
- package/package.json +1 -1
- package/server/server.js +5 -2
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export const TAB_FIELDS={general:["title","tagline","siteUrl","adminHome","spacerSize","bodyClass"],branding:["brandEnabled","brandText","brandLogo","brandIcon","brandUrl","adminBrandEnabled","adminBrandTitle","adminBrandLogo","adminBrandIcon"],favicon:["favicon"],footer:["footerCopyright","footerLayout","footerBlurb","footerBlocks","footerClass","footerSocialClass","footerLook","footerCtaText","footerCtaHighlight","footerCtaUrl","footerCtaSub","footerWatermark","footerStatus","footerFacts","footerTagline","footerEmail","footerAddress","footerGradFrom","footerGradTo","socialTwitter","socialFacebook","socialInstagram","socialLinkedin","socialGithub","socialYoutube"],email:["smtpHost","smtpPort","smtpUser","smtpPass","smtpSecure","smtpInsecureTLS","smtpFromAddress","smtpFromName"],pageNavigation:["bttEnabled","bttSmooth","bttLabel","bttThreshold","bttPosition","bttOffset","bttBottomOffset","gtbEnabled","gtbSmooth","gtbLabel","gtbThreshold","gtbPosition","gtbOffset","gtbBottomOffset"],cookies:["ccEnabled","ccMessage","ccAcceptAll","ccRejectAll","ccCustomize","ccSavePrefs","ccPrivacyText","ccPrivacyUrl","ccCookieText","ccCookieUrl","ccPosition","ccLayout","ccTheme","ccShowFunctional","ccShowAnalytics","ccShowMarketing","ccVersion","ccSettingsLink","ccSettingsLinkText"],breadcrumbs:["bcEnabled","bcHomeLabel","bcPosition","bcOffsetX","bcOffsetY"],motion:["mtEnabled","mtLabel","mtDefault","mtControl","mtPlacement","mtTriggerStyle","mtPosition","mtOffsetX","mtOffsetY","mtIconSize","mtIconRadius","mtClass"]},SECRET_FIELDS=["smtpPass"],BREADCRUMB_POSITIONS=["TL","TR","BL","BR"],MOTION_PLACEMENTS=["footer","floating","navbar"],MOTION_LABEL="Reduce motion";const d=["system","off","on"],c=(t,r,n,
|
|
2
|
-
`):"",footerTagline:
|
|
3
|
-
`).map(i=>i.trim()).filter(Boolean).slice(0,FOOTER_FACTS_MAX),tagline:
|
|
1
|
+
export const TAB_FIELDS={general:["title","tagline","siteUrl","adminHome","spacerSize","bodyClass"],branding:["brandEnabled","brandText","brandLogo","brandIcon","brandUrl","adminBrandEnabled","adminBrandTitle","adminBrandLogo","adminBrandIcon"],favicon:["favicon"],footer:["footerCopyright","footerLayout","footerBlurb","footerBlocks","footerClass","footerSocialClass","footerLook","footerCtaText","footerCtaHighlight","footerCtaUrl","footerCtaSub","footerWatermark","footerStatus","footerFacts","footerTagline","footerEmail","footerAddress","footerGradFrom","footerGradTo","socialTwitter","socialFacebook","socialInstagram","socialLinkedin","socialGithub","socialYoutube"],email:["smtpHost","smtpPort","smtpUser","smtpPass","smtpSecure","smtpInsecureTLS","smtpFromAddress","smtpFromName"],pageNavigation:["bttEnabled","bttSmooth","bttLabel","bttThreshold","bttPosition","bttOffset","bttBottomOffset","gtbEnabled","gtbSmooth","gtbLabel","gtbThreshold","gtbPosition","gtbOffset","gtbBottomOffset"],cookies:["ccEnabled","ccMessage","ccAcceptAll","ccRejectAll","ccCustomize","ccSavePrefs","ccPrivacyText","ccPrivacyUrl","ccCookieText","ccCookieUrl","ccPosition","ccLayout","ccTheme","ccShowFunctional","ccShowAnalytics","ccShowMarketing","ccVersion","ccSettingsLink","ccSettingsLinkText"],breadcrumbs:["bcEnabled","bcHomeLabel","bcPosition","bcOffsetX","bcOffsetY"],motion:["mtEnabled","mtLabel","mtDefault","mtControl","mtPlacement","mtTriggerStyle","mtPosition","mtOffsetX","mtOffsetY","mtIconSize","mtIconRadius","mtClass"]},SECRET_FIELDS=["smtpPass"],BREADCRUMB_POSITIONS=["TL","TR","BL","BR"],MOTION_PLACEMENTS=["footer","floating","navbar"],MOTION_LABEL="Reduce motion";const d=["system","off","on"],c=(t,r,n,o)=>{const a=Number.parseInt(t,10);return Number.isFinite(a)?Math.min(o,Math.max(n,a)):r};export function motionFromSettings(t={}){const r=t.motion&&typeof t.motion=="object"?t.motion:{},n=t.footer||{},o=m=>r[m]!==void 0&&r[m]!==null,a=o("default")?r.default:n.motionDefault,i=o("control")?r.control:n.motionControl,l=c(r.iconSize,52,32,96);return{mtEnabled:(o("enabled")?r.enabled:n.showMotionToggle)!==!1,mtLabel:typeof r.label=="string"&&r.label.trim()?r.label.trim():MOTION_LABEL,mtDefault:d.includes(a)?a:"system",mtControl:i==="checkbox"?"checkbox":"switch",mtPlacement:MOTION_PLACEMENTS.includes(r.placement)?r.placement:"footer",mtTriggerStyle:r.triggerStyle==="icon-text"?"icon-text":"icon",mtPosition:BREADCRUMB_POSITIONS.includes(r.position)?r.position:"BL",mtOffsetX:e(c(r.offsetX,32,0,500)),mtOffsetY:e(c(r.offsetY,32,0,500)),mtIconSize:e(l),mtIconRadius:e(c(r.iconRadius,26,0,Math.floor(l/2))),mtClass:e(r.class)}}export function motionFromForm(t){const r=c(t.mtIconSize,52,32,96);return{enabled:t.mtEnabled===!0,default:d.includes(t.mtDefault)?t.mtDefault:"system",placement:MOTION_PLACEMENTS.includes(t.mtPlacement)?t.mtPlacement:"footer",control:t.mtControl==="checkbox"?"checkbox":"switch",triggerStyle:t.mtTriggerStyle==="icon-text"?"icon-text":"icon",label:e(t.mtLabel).trim().replace(/\s+/g," ").slice(0,40)||MOTION_LABEL,position:BREADCRUMB_POSITIONS.includes(t.mtPosition)?t.mtPosition:"BL",offsetX:c(t.mtOffsetX,32,0,500),offsetY:c(t.mtOffsetY,32,0,500),iconSize:r,iconRadius:c(t.mtIconRadius,26,0,Math.floor(r/2)),class:e(t.mtClass).trim()}}export function footerBlockNames(t){return[...new Set(String(t??"").split(/[\s,]+/).map(r=>r.trim().toLowerCase()).filter(Boolean))]}export function gaIdError(t){const r=e(t).trim();return!r||/^G-[A-Z0-9]{4,20}$/i.test(r)?"":"A measurement ID looks like G-XXXXXXXXXX (Google Analytics > Admin > Data streams)."}export const FOOTER_LAYOUTS=["auto","columns","row"],FOOTER_LOOKS=["","showcase"],FOOTER_FACTS_MAX=4;const p=/^(\/|#|https?:\/\/|mailto:)/,g=/^#[0-9a-f]{6}$/i;export function footerShowcaseErrors(t){const r=[],n=e(t.footerCtaUrl).trim();n&&!p.test(n)&&r.push("The footer call to action link must start with /, #, https:// or mailto: (Footer tool).");for(const[o,a]of[["from",t.footerGradFrom],["to",t.footerGradTo]]){const i=e(a).trim();i&&!g.test(i)&&r.push(`The footer gradient "${o}" colour must look like #f26b3a (Footer tool).`)}return r}const e=(t,r="")=>t==null?r:String(t),s=(t,r)=>{const n=Number.parseInt(t,10);return Number.isFinite(n)?n:r};export function homeValue(t){return/^\/[A-Za-z0-9\-_/]*$/.test(t||"")&&String(t).replace(/\/+$/,"")||"/"}export function formFromSettings(t={}){const r=t.backToTop||{},n=t.goToBottom||{},o=t.cookieConsent||{},a=t.breadcrumbs||{};return{title:e(t.title),tagline:e(t.tagline),siteUrl:e(t.baseUrl),adminHome:homeValue(t.adminHome),spacerSize:e(t.layoutOptions?.spacerSize??40),bodyClass:e(t.bodyClass),brandEnabled:t.brand?.enabled!==!1,brandText:e(t.brand?.text),brandLogo:e(t.brand?.logo),brandIcon:e(t.brand?.icon),brandUrl:e(t.brand?.url,"/"),favicon:e(t.favicon),adminBrandEnabled:t.adminBrand?.enabled!==!1,adminBrandTitle:e(t.adminBrand?.title),adminBrandLogo:e(t.adminBrand?.logo),adminBrandIcon:e(t.adminBrand?.icon),footerCopyright:e(t.footer?.copyright),footerLayout:FOOTER_LAYOUTS.includes(t.footer?.layout)?t.footer.layout:"auto",footerBlurb:e(t.footer?.blurb),footerBlocks:Array.isArray(t.footer?.blocks)?t.footer.blocks.filter(i=>typeof i=="string").join(", "):"",footerClass:e(t.footer?.class),footerSocialClass:e(t.footer?.socialClass),footerLook:FOOTER_LOOKS.includes(t.footer?.look)?t.footer.look:"",footerCtaText:e(t.footer?.cta?.text),footerCtaHighlight:e(t.footer?.cta?.highlight),footerCtaUrl:e(t.footer?.cta?.url),footerCtaSub:e(t.footer?.cta?.sub),footerWatermark:e(t.footer?.watermark),footerStatus:e(t.footer?.status),footerFacts:Array.isArray(t.footer?.facts)?t.footer.facts.filter(i=>typeof i=="string").join(`
|
|
2
|
+
`):"",footerTagline:e(t.footer?.tagline),footerEmail:e(t.footer?.email),footerAddress:e(t.footer?.address),footerGradFrom:e(t.footer?.gradient?.from),footerGradTo:e(t.footer?.gradient?.to),socialTwitter:e(t.social?.twitter),socialFacebook:e(t.social?.facebook),socialInstagram:e(t.social?.instagram),socialLinkedin:e(t.social?.linkedin),socialGithub:e(t.social?.github),socialYoutube:e(t.social?.youtube),smtpHost:e(t.smtp?.host),smtpPort:e(t.smtp?.port||587),smtpUser:e(t.smtp?.user),smtpPass:"",smtpSecure:t.smtp?.secure===!0,smtpInsecureTLS:t.smtp?.allowInsecureTLS===!0,smtpFromAddress:e(t.smtp?.fromAddress),smtpFromName:e(t.smtp?.fromName),bttEnabled:r.enabled!==!1,bttSmooth:r.smooth!==!1,bttLabel:e(r.label),bttThreshold:e(r.scrollThreshold??300),bttPosition:e(r.position,"bottom-right"),bttOffset:e(r.offset??32),bttBottomOffset:e(r.bottomOffset??r.offset??32),gtbEnabled:n.enabled===!0,gtbSmooth:n.smooth!==!1,gtbLabel:e(n.label),gtbThreshold:e(n.scrollThreshold??300),gtbPosition:e(n.position,"bottom-right"),gtbOffset:e(n.offset??32),gtbBottomOffset:e(n.bottomOffset??n.offset??32),ccEnabled:o.enabled!==!1,ccMessage:e(o.message),ccAcceptAll:e(o.acceptAllText,"Accept All"),ccRejectAll:e(o.rejectAllText,"Reject All"),ccCustomize:e(o.customizeText,"Customize"),ccSavePrefs:e(o.savePreferencesText,"Save Preferences"),ccPrivacyText:e(o.privacyPolicyText,"Privacy Policy"),ccPrivacyUrl:e(o.privacyPolicyUrl),ccCookieText:e(o.cookiePolicyText,"Cookie Policy"),ccCookieUrl:e(o.cookiePolicyUrl),ccPosition:e(o.position,"bottom"),ccLayout:e(o.layout,"bar"),ccTheme:e(o.theme,"dark"),ccShowFunctional:o.showFunctional!==!1,ccShowAnalytics:o.showAnalytics!==!1,ccShowMarketing:o.showMarketing!==!1,ccVersion:e(o.consentVersion,"1.0"),ccSettingsLink:o.showSettingsLink!==!1,ccSettingsLinkText:e(o.settingsLinkText,"Cookie settings"),bcEnabled:a.enabled===!0,bcHomeLabel:e(a.homeLabel,"Home"),bcPosition:BREADCRUMB_POSITIONS.includes(a.position)?a.position:"TL",bcOffsetX:e(a.offsetX??8),bcOffsetY:e(a.offsetY??8),...motionFromSettings(t)}}export function payloadFromForm(t,r={},{adminHomeReady:n=!0}={}){const o=i=>e(i).trim(),a=motionFromForm(t);return{title:o(t.title),tagline:o(t.tagline),baseUrl:o(t.siteUrl).replace(/\/+$/,""),...n&&{adminHome:o(t.adminHome)||"/"},layoutOptions:{spacerSize:s(t.spacerSize,40)||40},bodyClass:o(t.bodyClass),brand:{...r.brand,enabled:t.brandEnabled!==!1,text:o(t.brandText),logo:o(t.brandLogo),icon:o(t.brandIcon),url:o(t.brandUrl)||"/"},favicon:o(t.favicon),adminBrand:{...r.adminBrand,enabled:t.adminBrandEnabled!==!1,title:o(t.adminBrandTitle),logo:o(t.adminBrandLogo),icon:o(t.adminBrandIcon)},footer:{copyright:o(t.footerCopyright),layout:FOOTER_LAYOUTS.includes(t.footerLayout)?t.footerLayout:"auto",blurb:o(t.footerBlurb),blocks:footerBlockNames(t.footerBlocks),links:r.footer?.links||[],showMotionToggle:a.enabled,motionDefault:a.default,motionControl:a.control,class:o(t.footerClass),socialClass:o(t.footerSocialClass),look:FOOTER_LOOKS.includes(t.footerLook)?t.footerLook:"",cta:{text:o(t.footerCtaText),highlight:o(t.footerCtaHighlight),url:o(t.footerCtaUrl),sub:o(t.footerCtaSub)},watermark:o(t.footerWatermark),status:o(t.footerStatus),facts:String(t.footerFacts??"").split(`
|
|
3
|
+
`).map(i=>i.trim()).filter(Boolean).slice(0,FOOTER_FACTS_MAX),tagline:o(t.footerTagline),email:o(t.footerEmail),address:o(t.footerAddress),gradient:{from:o(t.footerGradFrom),to:o(t.footerGradTo)}},social:{twitter:o(t.socialTwitter),facebook:o(t.socialFacebook),instagram:o(t.socialInstagram),linkedin:o(t.socialLinkedin),github:o(t.socialGithub),youtube:o(t.socialYoutube)},smtp:{host:o(t.smtpHost),port:s(t.smtpPort,587)||587,user:o(t.smtpUser),pass:e(t.smtpPass),secure:t.smtpSecure===!0,allowInsecureTLS:t.smtpInsecureTLS===!0,fromAddress:o(t.smtpFromAddress),fromName:o(t.smtpFromName)},backToTop:{enabled:t.bttEnabled===!0,scrollThreshold:s(t.bttThreshold,300),position:e(t.bttPosition)||"bottom-right",offset:s(t.bttOffset,32),bottomOffset:s(t.bttBottomOffset,32),label:o(t.bttLabel),smooth:t.bttSmooth===!0},goToBottom:{enabled:t.gtbEnabled===!0,scrollThreshold:s(t.gtbThreshold,300),position:e(t.gtbPosition)||"bottom-right",offset:s(t.gtbOffset,32),bottomOffset:s(t.gtbBottomOffset,32),label:o(t.gtbLabel),smooth:t.gtbSmooth===!0},cookieConsent:{enabled:t.ccEnabled===!0,message:o(t.ccMessage),acceptAllText:o(t.ccAcceptAll),rejectAllText:o(t.ccRejectAll),customizeText:o(t.ccCustomize),savePreferencesText:o(t.ccSavePrefs),privacyPolicyText:o(t.ccPrivacyText),privacyPolicyUrl:o(t.ccPrivacyUrl),cookiePolicyText:o(t.ccCookieText),cookiePolicyUrl:o(t.ccCookieUrl),position:e(t.ccPosition)||"bottom",layout:e(t.ccLayout)||"bar",theme:e(t.ccTheme)||"dark",showFunctional:t.ccShowFunctional===!0,showAnalytics:t.ccShowAnalytics===!0,showMarketing:t.ccShowMarketing===!0,consentVersion:o(t.ccVersion)||"1.0",showSettingsLink:t.ccSettingsLink===!0,settingsLinkText:o(t.ccSettingsLinkText)||"Cookie settings"},breadcrumbs:{enabled:t.bcEnabled===!0,homeLabel:o(t.bcHomeLabel)||"Home",position:BREADCRUMB_POSITIONS.includes(t.bcPosition)?t.bcPosition:"TL",offsetX:s(t.bcOffsetX,8),offsetY:s(t.bcOffsetY,8)},motion:a}}export function siteUrlError(t){const r=e(t).trim().replace(/\/+$/,"");return r?/^https?:\/\//i.test(r)?/^https?:\/\/([a-z0-9.\-]+|\[[0-9a-f:.]+\])(:\d{1,5})?$/i.test(r)?"":"Just the address, like https://example.com - no page path after it.":"Start with https:// (or http://).":""}const b=t=>typeof t=="boolean"?t:e(t);export function snapshot(t){return JSON.stringify(Object.keys(t).sort().map(r=>[r,b(t[r])]))}export function changedTabs(t,r){const n=[];for(const[o,a]of Object.entries(TAB_FIELDS))a.some(i=>b(t[i])!==b(r[i]))&&n.push(o);return n}export function draftOf(t){return Object.fromEntries(Object.entries(t).filter(([r])=>!SECRET_FIELDS.includes(r)))}const h={footerMotionToggle:"mtEnabled",footerMotionDefault:"mtDefault",footerMotionControl:"mtControl"};export function formFromDraft(t,r={}){const n={...r};for(const[a,i]of Object.entries(h))a in n&&!(i in n)&&(n[i]=n[a]),delete n[a];const o={...t};for(const[a,i]of Object.entries(n))a in o&&!SECRET_FIELDS.includes(a)&&(o[a]=i);return o}export function settingsProblems(t,r={}){const n=[];return e(t.smtpHost).trim()?e(t.smtpFromAddress).trim()||n.push({tone:"warn",tab:"email",text:"No From address - mail has no sender and many servers refuse it."}):n.push({tone:"danger",tab:"email",text:"No SMTP host - mail goes to a throwaway test inbox and reaches no one (password resets, form notifications)."}),(t.ccEnabled===!0||e(r.googleAnalytics?.measurementId).trim())&&!e(t.ccPrivacyUrl).trim()&&n.push({tone:"warn",tab:"cookies",text:"The cookie banner is on but links to no privacy policy."}),n}export function describeCacheKey(t){const r=/^page:(.*?):m\d+:role([^:]*):/.exec(String(t||""));return r?{path:r[1]||"/",role:r[2]||"anon",page:!0}:{path:String(t||""),role:"",page:!1}}export function expiresIn(t,r=Date.now()){if(t==null)return"no expiry";const n=t-r;return n<=0?"expired":n<6e4?`${Math.round(n/1e3)}s`:n<36e5?`${Math.round(n/6e4)}m`:`${Math.round(n/36e5)}h`}export function footerForm(t={}){const r=formFromSettings(t);return Object.fromEntries(TAB_FIELDS.footer.map(n=>[n,r[n]]))}export function footerPayload(t){const{footer:r,social:n}=payloadFromForm(t);return delete r.links,delete r.showMotionToggle,delete r.motionDefault,delete r.motionControl,{footer:r,social:n}}export function siteSettingsForm(t={}){return Object.fromEntries(Object.entries(formFromSettings(t)).filter(([r])=>!TAB_FIELDS.footer.includes(r)&&!u.includes(r)))}export function siteSettingsPayload(...t){const{footer:r,social:n,favicon:o,backToTop:a,goToBottom:i,breadcrumbs:l,motion:m,...f}=payloadFromForm(...t);return f}export const APPEARANCE_TABS=["favicon","pageNavigation","breadcrumbs","motion","search"];const u=APPEARANCE_TABS.flatMap(t=>TAB_FIELDS[t]||[]);export function appearanceForm(t={}){const r=formFromSettings(t);return Object.fromEntries(u.map(n=>[n,r[n]]))}export function appearancePayload(t){const{favicon:r,backToTop:n,goToBottom:o,breadcrumbs:a,motion:i}=payloadFromForm(t);return{favicon:r,backToTop:n,goToBottom:o,breadcrumbs:a,motion:i}}
|
|
@@ -0,0 +1,243 @@
|
|
|
1
|
+
<div class="stx">
|
|
2
|
+
<div class="stx-alert is-bad" data-bind-hidden="!errorText.value">
|
|
3
|
+
<span data-icon="x-circle" data-icon-size="16"></span>
|
|
4
|
+
<span><strong>Not saved.</strong> <span data-bind-text="errorText.value"></span></span></div>
|
|
5
|
+
<p class="stx-alert is-dirty" data-bind-hidden="!dirty.value">
|
|
6
|
+
<span data-icon="edit-3" data-icon-size="16"></span>
|
|
7
|
+
<span>Unsaved changes - Save (Ctrl+S) to apply them. Leave and they are kept as a draft for next time.</span>
|
|
8
|
+
<span class="stx-spacer"></span>
|
|
9
|
+
<button type="button" class="btn btn-sm btn-ghost" data-on-click="discard">Discard</button>
|
|
10
|
+
<button type="button" class="btn btn-sm btn-primary" data-on-click="save" data-bind-disabled="saving.value">Save</button></p>
|
|
11
|
+
|
|
12
|
+
<div class="tabs stx-tabs">
|
|
13
|
+
<div class="tab-list">
|
|
14
|
+
<button type="button" class="tab-item active"><span data-icon="image" data-icon-size="16" aria-hidden="true"></span>Favicon <i class="stx-dot" data-bind-hidden="!tabs.value.favicon" title="Changed"></i></button>
|
|
15
|
+
<button type="button" class="tab-item"><span data-icon="move" data-icon-size="16" aria-hidden="true"></span>Navigation <i class="stx-dot" data-bind-hidden="!tabs.value.pageNavigation" title="Changed"></i></button>
|
|
16
|
+
<button type="button" class="tab-item"><span data-icon="chevrons-right" data-icon-size="16" aria-hidden="true"></span>Breadcrumbs <i class="stx-dot" data-bind-hidden="!tabs.value.breadcrumbs" title="Changed"></i></button>
|
|
17
|
+
<button type="button" class="tab-item"><span data-icon="pause" data-icon-size="16" aria-hidden="true"></span>Reduced Motion <i class="stx-dot" data-bind-hidden="!tabs.value.motion" title="Changed"></i></button>
|
|
18
|
+
<button type="button" class="tab-item" data-site-search-tab><span data-icon="search" data-icon-size="16" aria-hidden="true"></span>Search <i class="stx-dot" data-site-search-dirty hidden title="Changed"></i></button>
|
|
19
|
+
</div>
|
|
20
|
+
<!-- Favicon -->
|
|
21
|
+
<div class="tab-panel active">
|
|
22
|
+
<div class="stx-card-columns">
|
|
23
|
+
<div class="stx-card dm-settings-section"><div class="stx-card-title dm-settings-section-title"><span data-icon="image" data-icon-size="16" aria-hidden="true"></span>Generate favicon.ico</div>
|
|
24
|
+
<p>Choose or upload an image. Generate a single ICO file with 16, 32, 48 and 256 pixel icons. Images keep their proportions with transparent padding.</p>
|
|
25
|
+
<label class="form-label" for="stx-favicon-source">Source image</label>
|
|
26
|
+
<input id="stx-favicon-source" class="form-input" type="text" placeholder="/media/logo.png" data-model="faviconSource.value">
|
|
27
|
+
<button type="button" class="btn btn-secondary" data-on-click="chooseFaviconSource" data-bind-disabled="faviconGenerating.value">Choose or upload image</button>
|
|
28
|
+
<button type="button" class="btn btn-primary" data-on-click="generateFavicon" data-bind-disabled="faviconGenerating.value || !faviconSource.value">Generate favicon.ico</button>
|
|
29
|
+
<p class="text-danger" data-bind-text="faviconError.value" data-bind-hidden="!faviconError.value"></p>
|
|
30
|
+
<p data-bind-hidden="!faviconGenerated.value">Generated. Save Site Settings to apply it. <a data-bind-href="faviconGenerated.value" download="favicon.ico">Download favicon.ico</a></p>
|
|
31
|
+
</div>
|
|
32
|
+
<div class="stx-card dm-settings-section"><div class="stx-card-title dm-settings-section-title"><span data-icon="image" data-icon-size="16" aria-hidden="true"></span>Browser icon</div>
|
|
33
|
+
<div><label class="form-label" for="stx-favicon">Browser icon (favicon)</label>
|
|
34
|
+
<input id="stx-favicon" type="text" class="form-input" placeholder="/media/favicon.png" data-model="favicon.value">
|
|
35
|
+
<button type="button" class="btn btn-sm btn-ghost" data-on-click="pickBrandImage('favicon')">Choose or upload image</button>
|
|
36
|
+
<button type="button" class="btn btn-sm btn-ghost" data-on-click="clearBrandImage('favicon')">Remove</button>
|
|
37
|
+
<img data-bind-src="favicon.value" data-bind-hidden="!favicon.value" alt="Browser icon (favicon) preview" style="display:block;max-width:180px;max-height:80px;object-fit:contain;margin-top:.75rem;">
|
|
38
|
+
</div>
|
|
39
|
+
<p class="text-muted">Save to apply the browser icon. Leave it empty to use the public logo.</p>
|
|
40
|
+
</div>
|
|
41
|
+
</div>
|
|
42
|
+
</div>
|
|
43
|
+
|
|
44
|
+
<!-- Page navigation -->
|
|
45
|
+
<div class="tab-panel">
|
|
46
|
+
<div class="stx-card-columns">
|
|
47
|
+
<div class="stx-card dm-settings-section">
|
|
48
|
+
<div class="stx-card-title dm-settings-section-title"><span class="stx-scroll-icon" data-icon="arrow-up"></span>Back to top
|
|
49
|
+
<span data-help="A button that appears once a visitor has scrolled down, and takes them back to the top of the page."></span></div>
|
|
50
|
+
<div class="stx-grid">
|
|
51
|
+
<div class="stx-setting"><label class="form-label" for="stx-btt-on">Show the button</label>
|
|
52
|
+
<input id="stx-btt-on" type="checkbox" class="form-switch" data-model="bttEnabled.value"></div>
|
|
53
|
+
<div class="stx-setting"><label class="form-label" for="stx-btt-smooth">Smooth scroll</label>
|
|
54
|
+
<input id="stx-btt-smooth" type="checkbox" class="form-switch" data-model="bttSmooth.value"></div>
|
|
55
|
+
<div class="stx-wide">
|
|
56
|
+
<label class="form-label" for="stx-btt-label">Label <small class="stx-muted">(optional - empty is icon-only)</small></label>
|
|
57
|
+
<input id="stx-btt-label" type="text" class="form-input" placeholder="Back to top" data-model="bttLabel.value">
|
|
58
|
+
</div>
|
|
59
|
+
<div>
|
|
60
|
+
<label class="form-label" for="stx-btt-thr">Appears after (px)
|
|
61
|
+
<span data-help="How far a visitor has to scroll down before the button shows."></span></label>
|
|
62
|
+
<input id="stx-btt-thr" type="number" class="form-input" placeholder="300" data-model="bttThreshold.value">
|
|
63
|
+
</div>
|
|
64
|
+
<div>
|
|
65
|
+
<label class="form-label" for="stx-btt-pos">Position</label>
|
|
66
|
+
<select id="stx-btt-pos" class="form-select" data-model="bttPosition.value">
|
|
67
|
+
<option value="bottom-right">Bottom right</option>
|
|
68
|
+
<option value="bottom-left">Bottom left</option>
|
|
69
|
+
</select>
|
|
70
|
+
</div>
|
|
71
|
+
<div>
|
|
72
|
+
<label class="form-label" for="stx-btt-off">Side offset (px)</label>
|
|
73
|
+
<input id="stx-btt-off" type="number" class="form-input" placeholder="32" data-model="bttOffset.value">
|
|
74
|
+
</div>
|
|
75
|
+
<div>
|
|
76
|
+
<label class="form-label" for="stx-btt-boff">Bottom offset (px)</label>
|
|
77
|
+
<input id="stx-btt-boff" type="number" class="form-input" placeholder="32" data-model="bttBottomOffset.value">
|
|
78
|
+
</div>
|
|
79
|
+
</div>
|
|
80
|
+
</div>
|
|
81
|
+
<div class="stx-card dm-settings-section">
|
|
82
|
+
<div class="stx-card-title dm-settings-section-title"><span class="stx-scroll-icon" data-icon="arrow-down"></span>Go to bottom
|
|
83
|
+
<span data-help="A matching down-arrow button that takes visitors to the bottom of the page. It hides when they are already near the bottom."></span></div>
|
|
84
|
+
<div class="stx-grid">
|
|
85
|
+
<div class="stx-setting"><label class="form-label" for="stx-gtb-on">Show the button</label>
|
|
86
|
+
<input id="stx-gtb-on" type="checkbox" class="form-switch" data-model="gtbEnabled.value"></div>
|
|
87
|
+
<div class="stx-setting"><label class="form-label" for="stx-gtb-smooth">Smooth scroll</label>
|
|
88
|
+
<input id="stx-gtb-smooth" type="checkbox" class="form-switch" data-model="gtbSmooth.value"></div>
|
|
89
|
+
<div class="stx-wide">
|
|
90
|
+
<label class="form-label" for="stx-gtb-label">Label <small class="stx-muted">(optional - empty is icon-only)</small></label>
|
|
91
|
+
<input id="stx-gtb-label" type="text" class="form-input" placeholder="Go to bottom" data-model="gtbLabel.value">
|
|
92
|
+
</div>
|
|
93
|
+
<div>
|
|
94
|
+
<label class="form-label" for="stx-gtb-thr">Hide near bottom (px)
|
|
95
|
+
<span data-help="How close to the bottom the visitor must be before this button hides."></span></label>
|
|
96
|
+
<input id="stx-gtb-thr" type="number" class="form-input" placeholder="300" data-model="gtbThreshold.value">
|
|
97
|
+
</div>
|
|
98
|
+
<div>
|
|
99
|
+
<label class="form-label" for="stx-gtb-pos">Position</label>
|
|
100
|
+
<select id="stx-gtb-pos" class="form-select" data-model="gtbPosition.value">
|
|
101
|
+
<option value="bottom-right">Bottom right</option>
|
|
102
|
+
<option value="bottom-left">Bottom left</option>
|
|
103
|
+
</select>
|
|
104
|
+
</div>
|
|
105
|
+
<div>
|
|
106
|
+
<label class="form-label" for="stx-gtb-off">Side offset (px)</label>
|
|
107
|
+
<input id="stx-gtb-off" type="number" class="form-input" placeholder="32" data-model="gtbOffset.value">
|
|
108
|
+
</div>
|
|
109
|
+
<div>
|
|
110
|
+
<label class="form-label" for="stx-gtb-boff">Bottom offset (px)</label>
|
|
111
|
+
<input id="stx-gtb-boff" type="number" class="form-input" placeholder="32" data-model="gtbBottomOffset.value">
|
|
112
|
+
</div>
|
|
113
|
+
</div>
|
|
114
|
+
</div>
|
|
115
|
+
</div>
|
|
116
|
+
</div>
|
|
117
|
+
|
|
118
|
+
<!-- Breadcrumbs -->
|
|
119
|
+
<div class="tab-panel">
|
|
120
|
+
<div class="stx-card-columns">
|
|
121
|
+
<div class="stx-card dm-settings-section">
|
|
122
|
+
<div class="stx-card-title dm-settings-section-title"><span data-icon="chevron-right" data-icon-size="16" aria-hidden="true"></span>Breadcrumb trail
|
|
123
|
+
<span data-help-title="Breadcrumbs" data-help="A small frosted pill fixed to a corner of every public page, showing where the page sits (Home › Services › Web). A page can switch it off with “Show Breadcrumbs” in the page editor."></span></div>
|
|
124
|
+
<div class="stx-grid">
|
|
125
|
+
<div class="stx-wide stx-setting"><label class="form-label" for="stx-bc-on">Show breadcrumbs</label>
|
|
126
|
+
<input id="stx-bc-on" type="checkbox" class="form-switch" data-model="bcEnabled.value"></div>
|
|
127
|
+
<div class="stx-wide"><label class="form-label" for="stx-bc-home">Home label</label>
|
|
128
|
+
<input id="stx-bc-home" type="text" class="form-input" placeholder="Home" data-model="bcHomeLabel.value"></div>
|
|
129
|
+
</div>
|
|
130
|
+
<p class="stx-hint">Shows the path from Home to the current page. Individual pages can hide their trail in the page editor.</p>
|
|
131
|
+
</div>
|
|
132
|
+
<div class="stx-card dm-settings-section">
|
|
133
|
+
<div class="stx-card-title dm-settings-section-title"><span data-icon="layout" data-icon-size="16" aria-hidden="true"></span>Placement</div>
|
|
134
|
+
<div class="stx-grid">
|
|
135
|
+
<div class="stx-wide">
|
|
136
|
+
<span class="form-label">Corner</span>
|
|
137
|
+
<div class="stx-corners" role="group" aria-label="Corner">
|
|
138
|
+
<button type="button" data-on-click="corner('TL')" data-bind-class="bcPosition.value === 'TL' && 'is-on'">↖ Top left</button>
|
|
139
|
+
<button type="button" data-on-click="corner('TR')" data-bind-class="bcPosition.value === 'TR' && 'is-on'">Top right ↗</button>
|
|
140
|
+
<button type="button" data-on-click="corner('BL')" data-bind-class="bcPosition.value === 'BL' && 'is-on'">↙ Bottom left</button>
|
|
141
|
+
<button type="button" data-on-click="corner('BR')" data-bind-class="bcPosition.value === 'BR' && 'is-on'">Bottom right ↘</button>
|
|
142
|
+
</div>
|
|
143
|
+
</div>
|
|
144
|
+
<div class="stx-pair stx-wide">
|
|
145
|
+
<div><label class="form-label" for="stx-bc-x">From the side (px)</label>
|
|
146
|
+
<input id="stx-bc-x" type="number" class="form-input" min="0" max="500" placeholder="8" data-model="bcOffsetX.value"></div>
|
|
147
|
+
<div><label class="form-label" for="stx-bc-y">From the top/bottom (px)</label>
|
|
148
|
+
<input id="stx-bc-y" type="number" class="form-input" min="0" max="500" placeholder="8" data-model="bcOffsetY.value"></div>
|
|
149
|
+
</div>
|
|
150
|
+
</div>
|
|
151
|
+
</div>
|
|
152
|
+
</div>
|
|
153
|
+
</div>
|
|
154
|
+
|
|
155
|
+
<!-- Reduce motion -->
|
|
156
|
+
<div class="tab-panel">
|
|
157
|
+
<div class="stx-card-columns">
|
|
158
|
+
<div class="stx-card dm-settings-section">
|
|
159
|
+
<div class="stx-card-title dm-settings-section-title"><span data-icon="pause" data-icon-size="16" aria-hidden="true"></span>The control
|
|
160
|
+
<span data-help-title="Reduce motion" data-help="An accessibility control that lets visitors turn animations off. Turning it off only hides the control - visitors who already chose it, and anyone whose browser asks for reduced motion, still get a calmer site."></span></div>
|
|
161
|
+
<div class="stx-grid">
|
|
162
|
+
<div class="stx-wide stx-setting"><label class="form-label" for="stx-mt-on">Show it</label>
|
|
163
|
+
<input id="stx-mt-on" type="checkbox" class="form-switch" data-model="mtEnabled.value"></div>
|
|
164
|
+
<div class="stx-wide"><label class="form-label" for="stx-mt-label">Label
|
|
165
|
+
<span data-help="The words on the control, and what a screen reader announces. Up to 40 characters."></span></label>
|
|
166
|
+
<input id="stx-mt-label" type="text" class="form-input" maxlength="40" placeholder="Reduce motion" data-model="mtLabel.value"></div>
|
|
167
|
+
<div class="stx-wide stx-setting">
|
|
168
|
+
<label class="form-label" for="stx-motion-default">Reduced motion for new visitors
|
|
169
|
+
<span data-help="What a visitor who has not used the control gets. Follow their device honours the system setting (the accessible default). Off shows every animation until they ask for less; On starts calm. A visitor's own choice always wins."></span></label>
|
|
170
|
+
<select id="stx-motion-default" class="form-input" data-model="mtDefault.value">
|
|
171
|
+
<option value="system">Follow their device</option>
|
|
172
|
+
<option value="off">Off - full motion</option>
|
|
173
|
+
<option value="on">On - calm</option>
|
|
174
|
+
</select>
|
|
175
|
+
</div>
|
|
176
|
+
<div class="stx-wide stx-setting" data-bind-hidden="mtPlacement.value !== 'footer'">
|
|
177
|
+
<label class="form-label" for="stx-motion-control">Footer style
|
|
178
|
+
<span data-help="How the Reduce motion control looks in the footer."></span></label>
|
|
179
|
+
<select id="stx-motion-control" class="form-input" data-model="mtControl.value">
|
|
180
|
+
<option value="switch">A switch</option>
|
|
181
|
+
<option value="checkbox">A checkbox</option>
|
|
182
|
+
</select>
|
|
183
|
+
</div>
|
|
184
|
+
<div class="stx-wide">
|
|
185
|
+
<label class="form-label" for="stx-mt-class">CSS classes
|
|
186
|
+
<span data-help="Your own class names, separated by spaces, added to the control wherever it sits. Style them in Custom CSS."></span></label>
|
|
187
|
+
<input id="stx-mt-class" type="text" class="form-input" placeholder="motion-quiet" autocomplete="off" spellcheck="false" data-model="mtClass.value">
|
|
188
|
+
</div>
|
|
189
|
+
</div>
|
|
190
|
+
</div>
|
|
191
|
+
<div class="stx-card dm-settings-section">
|
|
192
|
+
<div class="stx-card-title dm-settings-section-title"><span data-icon="layout" data-icon-size="16" aria-hidden="true"></span>Placement
|
|
193
|
+
<span data-help-title="Placement" data-help="Footer puts it at the foot of every page, as it always was. Floating button is a disc fixed to a corner of the window, kept clear of Search, Back to top and the theme switcher. Navbar adds it at the end of the navbar - on a page with no navbar, or on a phone when the navbar shows only its menu button, it floats instead."></span></div>
|
|
194
|
+
<div class="stx-grid">
|
|
195
|
+
<div class="stx-wide">
|
|
196
|
+
<span class="form-label">Where it goes</span>
|
|
197
|
+
<div class="stx-segments" role="group" aria-label="Where it goes">
|
|
198
|
+
<button type="button" data-on-click="motionPlacement('footer')" data-bind-class="mtPlacement.value === 'footer' && 'is-on'">Footer</button>
|
|
199
|
+
<button type="button" data-on-click="motionPlacement('floating')" data-bind-class="mtPlacement.value === 'floating' && 'is-on'">Floating button</button>
|
|
200
|
+
<button type="button" data-on-click="motionPlacement('navbar')" data-bind-class="mtPlacement.value === 'navbar' && 'is-on'">Navbar</button>
|
|
201
|
+
</div>
|
|
202
|
+
</div>
|
|
203
|
+
<div class="stx-setting stx-wide" data-bind-hidden="mtPlacement.value === 'footer'">
|
|
204
|
+
<label class="form-label" for="stx-mt-style">Button
|
|
205
|
+
<span data-help="An icon on its own (the label is still read out by screen readers), or the icon with the label beside it."></span></label>
|
|
206
|
+
<select id="stx-mt-style" class="form-input" data-model="mtTriggerStyle.value">
|
|
207
|
+
<option value="icon">Icon</option>
|
|
208
|
+
<option value="icon-text">Icon and label</option>
|
|
209
|
+
</select>
|
|
210
|
+
</div>
|
|
211
|
+
<div class="stx-wide" data-bind-hidden="mtPlacement.value !== 'floating'">
|
|
212
|
+
<span class="form-label">Corner</span>
|
|
213
|
+
<div class="stx-corners" role="group" aria-label="Corner">
|
|
214
|
+
<button type="button" data-on-click="motionCorner('TL')" data-bind-class="mtPosition.value === 'TL' && 'is-on'">↖ Top left</button>
|
|
215
|
+
<button type="button" data-on-click="motionCorner('TR')" data-bind-class="mtPosition.value === 'TR' && 'is-on'">Top right ↗</button>
|
|
216
|
+
<button type="button" data-on-click="motionCorner('BL')" data-bind-class="mtPosition.value === 'BL' && 'is-on'">↙ Bottom left</button>
|
|
217
|
+
<button type="button" data-on-click="motionCorner('BR')" data-bind-class="mtPosition.value === 'BR' && 'is-on'">Bottom right ↘</button>
|
|
218
|
+
</div>
|
|
219
|
+
</div>
|
|
220
|
+
<div class="stx-pair stx-wide" data-bind-hidden="mtPlacement.value !== 'floating'">
|
|
221
|
+
<div><label class="form-label" for="stx-mt-x">From the side (px)</label>
|
|
222
|
+
<input id="stx-mt-x" type="number" class="form-input" min="0" max="500" placeholder="32" data-model="mtOffsetX.value"></div>
|
|
223
|
+
<div><label class="form-label" for="stx-mt-y">From the top/bottom (px)</label>
|
|
224
|
+
<input id="stx-mt-y" type="number" class="form-input" min="0" max="500" placeholder="32" data-model="mtOffsetY.value"></div>
|
|
225
|
+
</div>
|
|
226
|
+
<div class="stx-pair stx-wide" data-bind-hidden="mtPlacement.value !== 'floating' || mtTriggerStyle.value !== 'icon'">
|
|
227
|
+
<div><label class="form-label" for="stx-mt-size">Size <span class="stx-readout" data-bind-text="mtSizeText.value"></span>
|
|
228
|
+
<span data-help="How big the disc is (32-96 px). The glyph inside scales with it. 44 px and up is comfortable to tap on a phone."></span></label>
|
|
229
|
+
<input id="stx-mt-size" type="range" min="32" max="96" step="2" data-model="mtIconSize.value"></div>
|
|
230
|
+
<div><label class="form-label" for="stx-mt-radius">Corners <span class="stx-readout" data-bind-text="mtRadiusText.value"></span>
|
|
231
|
+
<span data-help="0 is a square; the top of the range is a circle, and it is always half the size - so it moves when the size does."></span></label>
|
|
232
|
+
<input id="stx-mt-radius" type="range" min="0" step="1" data-model="mtIconRadius.value"></div>
|
|
233
|
+
</div>
|
|
234
|
+
</div>
|
|
235
|
+
<p class="stx-hint" data-bind-hidden="mtPlacement.value !== 'floating'">If Search, Back to top or the theme switcher sits in the same corner, the disc stacks clear of it, further from the edge.</p>
|
|
236
|
+
</div>
|
|
237
|
+
</div>
|
|
238
|
+
</div>
|
|
239
|
+
|
|
240
|
+
<div class="tab-panel" data-site-search-panel><p role="status">Open Search to load its settings.</p></div>
|
|
241
|
+
</div>
|
|
242
|
+
</div>
|
|
243
|
+
<link rel="stylesheet" href="/admin/css/site-settings.css">
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
<strong>SEO</strong> tool's settings. The Google Analytics measurement ID is in
|
|
16
16
|
<strong>Analytics</strong> settings. Cookie consent stays here.</p>
|
|
17
17
|
|
|
18
|
-
<p>Public site search is configured in
|
|
18
|
+
<p>Public site search is configured in <a href="#/appearance?tab=search">Appearance > Search</a>, including its trigger,
|
|
19
19
|
position and query preview. Existing Search links open that tab.</p>
|
|
20
20
|
|
|
21
21
|
<table class="table table-sm">
|
|
@@ -43,29 +43,12 @@
|
|
|
43
43
|
takes priority over the admin icon.</td>
|
|
44
44
|
</tr>
|
|
45
45
|
<tr>
|
|
46
|
-
<td>
|
|
47
|
-
<td>Copyright text, layout, blurb, footer blocks and social links.
|
|
48
|
-
Footer links are menus - see <a href="#/docs/usage/navigation">Navigation</a>.
|
|
49
|
-
The <a href="#showcase-footer">Showcase footer</a> card adds a big call to action and more.</td>
|
|
50
|
-
</tr>
|
|
51
|
-
<tr>
|
|
52
|
-
<td>Reduce motion</td>
|
|
53
|
-
<td>The accessibility control that lets visitors turn animations off: whether it is shown,
|
|
54
|
-
its label, and what a visitor who has not chosen gets (follow their device, full motion,
|
|
55
|
-
or calm). <strong>Placement</strong> puts it in the footer (a switch or a checkbox), as a
|
|
56
|
-
floating button in a corner you pick - with its size, corners and distance from the
|
|
57
|
-
edges - or at the end of the navbar (floating where there is no navbar, or on a phone
|
|
58
|
-
when the navbar shows only its menu button). A floating button sharing a corner with Search,
|
|
59
|
-
Back to top or the theme switcher stacks clear of it. Hiding the control does not take
|
|
60
|
-
the choice away from visitors who already made it.</td>
|
|
61
|
-
</tr>
|
|
62
|
-
<tr>
|
|
63
|
-
<td>Email</td>
|
|
46
|
+
<td>SMTP</td>
|
|
64
47
|
<td>The SMTP server the site sends mail through (form notifications, password resets,
|
|
65
48
|
action emails). Without it, "Forgot your password?" cannot send a link.</td>
|
|
66
49
|
</tr>
|
|
67
50
|
<tr>
|
|
68
|
-
<td>
|
|
51
|
+
<td>Cookie consent</td>
|
|
69
52
|
<td>Switch each on or off and set its wording and position.</td>
|
|
70
53
|
</tr>
|
|
71
54
|
<tr>
|
|
@@ -84,8 +67,14 @@
|
|
|
84
67
|
</tbody>
|
|
85
68
|
</table>
|
|
86
69
|
|
|
87
|
-
<h3
|
|
88
|
-
<p>
|
|
70
|
+
<h3>Appearance</h3>
|
|
71
|
+
<p><a href="#/appearance">Content > Appearance</a> is an innate tool with Favicon,
|
|
72
|
+
Navigation (Back to top and Go to bottom), Breadcrumbs, Reduced Motion and Search tabs.
|
|
73
|
+
Appearance has its own save and draft handling. Site Settings retains General, Branding,
|
|
74
|
+
SMTP (previously Email), Cookie consent and Cache.</p>
|
|
75
|
+
<h3 id="showcase-footer">Footer tool</h3>
|
|
76
|
+
<p><a href="#/footer">Content > Footer</a> is an innate tool. It manages copyright, layout, footer blocks, Showcase options and social links, with its own Save action. Footer menus stay in <a href="#/menus">Site menus</a>; Reduced Motion lives in Appearance.</p>
|
|
77
|
+
<p>In the <strong>Footer</strong> tool, the <strong>Showcase footer</strong> card finishes every page
|
|
89
78
|
with a flourish. Each part appears only when you give it words, and they work with the Columns
|
|
90
79
|
layout (Showcase always uses it).</p>
|
|
91
80
|
<ul>
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
<div class="stx">
|
|
2
|
+
<div class="stx-alert is-bad" data-bind-hidden="!errorText.value">
|
|
3
|
+
<span data-icon="x-circle" data-icon-size="16"></span>
|
|
4
|
+
<span><strong>Not saved.</strong> <span data-bind-text="errorText.value"></span></span></div>
|
|
5
|
+
<p class="stx-alert is-dirty" data-bind-hidden="!dirty.value">
|
|
6
|
+
<span data-icon="edit-3" data-icon-size="16"></span>
|
|
7
|
+
<span>Unsaved changes - Save (Ctrl+S) to apply them. Leave and they are kept as a draft for next time.</span>
|
|
8
|
+
<span class="stx-spacer"></span>
|
|
9
|
+
<button type="button" class="btn btn-sm btn-ghost" data-on-click="discard">Discard</button>
|
|
10
|
+
<button type="button" class="btn btn-sm btn-primary" data-on-click="save" data-bind-disabled="saving.value">Save</button></p>
|
|
11
|
+
|
|
12
|
+
<p>Manage your site footer. <a href="#/menus">Edit footer menus</a> or <a href="#/settings">edit site branding</a>.</p>
|
|
13
|
+
<!-- Footer -->
|
|
14
|
+
<div>
|
|
15
|
+
<div class="stx-card-columns">
|
|
16
|
+
<div class="stx-card dm-settings-section">
|
|
17
|
+
<div class="stx-card-title dm-settings-section-title"><span data-icon="panel-bottom" data-icon-size="16" aria-hidden="true"></span>Footer</div>
|
|
18
|
+
<div class="stx-grid">
|
|
19
|
+
<div class="stx-wide">
|
|
20
|
+
<label class="form-label" for="stx-footer-copy">Copyright text</label>
|
|
21
|
+
<input id="stx-footer-copy" type="text" class="form-input" placeholder="© 2026 My Site" data-model="footerCopyright.value">
|
|
22
|
+
</div>
|
|
23
|
+
<div class="stx-setting">
|
|
24
|
+
<label class="form-label" for="stx-footer-layout">Layout
|
|
25
|
+
<span data-help-title="Footer layout" data-help="Columns puts your brand, the blurb and the social links beside one column per group of the footer menu, with copyright, legal links and the motion control in a bar beneath. One row puts everything on a single line. Automatic uses columns when the footer menu has groups (made with sub-items in Menus) and one row when it does not."></span></label>
|
|
26
|
+
<select id="stx-footer-layout" class="form-input" data-model="footerLayout.value">
|
|
27
|
+
<option value="auto">Automatic</option>
|
|
28
|
+
<option value="columns">Columns</option>
|
|
29
|
+
<option value="row">One row</option>
|
|
30
|
+
</select>
|
|
31
|
+
</div>
|
|
32
|
+
<div class="stx-wide">
|
|
33
|
+
<label class="form-label" for="stx-footer-blurb">Blurb
|
|
34
|
+
<span data-help="A sentence or two under your brand in the columns layout - what the site is, in plain words. Leave it empty for none."></span></label>
|
|
35
|
+
<textarea id="stx-footer-blurb" class="form-input" rows="2" maxlength="300" placeholder="What your site is about, in a sentence." data-model="footerBlurb.value"></textarea>
|
|
36
|
+
</div>
|
|
37
|
+
<div class="stx-wide">
|
|
38
|
+
<label class="form-label" for="stx-footer-blocks">Footer blocks
|
|
39
|
+
<span data-help="Blocks (Content › Blocks) shown side by side at the top of the footer on every page, by name, in order - for example wp-footer-1, wp-footer-2. Import from WordPress puts a site's footer widget areas here. Leave it empty for none; a name that is not a block is left out."></span></label>
|
|
40
|
+
<input id="stx-footer-blocks" type="text" class="form-input" maxlength="400" placeholder="wp-footer-1, wp-footer-2" data-model="footerBlocks.value">
|
|
41
|
+
</div>
|
|
42
|
+
<p class="stx-wide stx-hint">Manage the accessibility control in Appearance:
|
|
43
|
+
<a href="#/appearance?tab=motion">Reduced Motion</a>.</p>
|
|
44
|
+
<div>
|
|
45
|
+
<label class="form-label" for="stx-footer-class">Footer CSS classes
|
|
46
|
+
<span data-help-title="Footer CSS classes" data-help="Your own class names, separated by spaces, added to the site footer. Style them in Custom CSS. The footer's menus take classes of their own in Menus."></span></label>
|
|
47
|
+
<input id="stx-footer-class" type="text" class="form-input" placeholder="footer-dark" autocomplete="off" spellcheck="false" data-model="footerClass.value">
|
|
48
|
+
</div>
|
|
49
|
+
<div>
|
|
50
|
+
<label class="form-label" for="stx-social-class">Social icon CSS classes
|
|
51
|
+
<span data-help-title="Social icon CSS classes" data-help="Your own class names, separated by spaces, added to every social media icon link in the footer."></span></label>
|
|
52
|
+
<input id="stx-social-class" type="text" class="form-input" placeholder="social-round" autocomplete="off" spellcheck="false" data-model="footerSocialClass.value">
|
|
53
|
+
</div>
|
|
54
|
+
</div>
|
|
55
|
+
</div>
|
|
56
|
+
<div class="stx-card dm-settings-section">
|
|
57
|
+
<div class="stx-card-title dm-settings-section-title"><span data-icon="star" data-icon-size="16" aria-hidden="true"></span>Showcase footer
|
|
58
|
+
<span data-help-title="Showcase footer" data-help="A footer that finishes the page with a flourish: a big call to action with a few words in a colour gradient, your contact details under the brand, a row of short facts, a tagline, and your name drawn huge and faint behind it all. Each part shows only when it has words. The Showcase look adds a glowing line along the top and more room; it always uses the columns layout."></span></div>
|
|
59
|
+
<div class="stx-grid">
|
|
60
|
+
<div class="stx-setting">
|
|
61
|
+
<label class="form-label" for="stx-footer-look">Look</label>
|
|
62
|
+
<select id="stx-footer-look" class="form-input" data-model="footerLook.value">
|
|
63
|
+
<option value="">Standard</option>
|
|
64
|
+
<option value="showcase">Showcase</option>
|
|
65
|
+
</select>
|
|
66
|
+
</div>
|
|
67
|
+
<div class="stx-setting">
|
|
68
|
+
<label class="form-label" for="stx-footer-wm">Name in the background
|
|
69
|
+
<span data-help="Drawn very large and faint behind the footer, drifting sideways as the page scrolls (still for visitors who ask for reduced motion). Usually your site's name. Leave it empty for none."></span></label>
|
|
70
|
+
<input id="stx-footer-wm" type="text" class="form-input" maxlength="24" placeholder="ACME" data-model="footerWatermark.value">
|
|
71
|
+
</div>
|
|
72
|
+
<div>
|
|
73
|
+
<label class="form-label" for="stx-footer-cta">Call to action
|
|
74
|
+
<span data-help="The big line at the top of the footer, for example Join. The next field is drawn in the gradient straight after it."></span></label>
|
|
75
|
+
<input id="stx-footer-cta" type="text" class="form-input" maxlength="40" placeholder="Join" data-model="footerCtaText.value">
|
|
76
|
+
</div>
|
|
77
|
+
<div>
|
|
78
|
+
<label class="form-label" for="stx-footer-cta-hl">…in the gradient</label>
|
|
79
|
+
<input id="stx-footer-cta-hl" type="text" class="form-input" maxlength="40" placeholder="early access." data-model="footerCtaHighlight.value">
|
|
80
|
+
</div>
|
|
81
|
+
<div>
|
|
82
|
+
<label class="form-label" for="stx-footer-cta-url">Call to action link</label>
|
|
83
|
+
<input id="stx-footer-cta-url" type="text" class="form-input" maxlength="500" placeholder="/contact" data-model="footerCtaUrl.value">
|
|
84
|
+
</div>
|
|
85
|
+
<div>
|
|
86
|
+
<label class="form-label" for="stx-footer-cta-sub">Line under it</label>
|
|
87
|
+
<input id="stx-footer-cta-sub" type="text" class="form-input" maxlength="160" placeholder="A reply within one working day" data-model="footerCtaSub.value">
|
|
88
|
+
</div>
|
|
89
|
+
<div>
|
|
90
|
+
<label class="form-label" for="stx-footer-email">Email under the brand</label>
|
|
91
|
+
<input id="stx-footer-email" type="email" class="form-input" maxlength="120" placeholder="hello@example.com" data-model="footerEmail.value">
|
|
92
|
+
</div>
|
|
93
|
+
<div>
|
|
94
|
+
<label class="form-label" for="stx-footer-address">Address under the brand</label>
|
|
95
|
+
<input id="stx-footer-address" type="text" class="form-input" maxlength="120" placeholder="Leeds, West Yorkshire" data-model="footerAddress.value">
|
|
96
|
+
</div>
|
|
97
|
+
<div>
|
|
98
|
+
<label class="form-label" for="stx-footer-status">Status
|
|
99
|
+
<span data-help="A short line with a small green dot, at the start of the facts row - for example All systems running."></span></label>
|
|
100
|
+
<input id="stx-footer-status" type="text" class="form-input" maxlength="60" placeholder="All systems running" data-model="footerStatus.value">
|
|
101
|
+
</div>
|
|
102
|
+
<div>
|
|
103
|
+
<label class="form-label" for="stx-footer-tagline">Tagline
|
|
104
|
+
<span data-help="Words at the right of the bottom bar, opposite the copyright."></span></label>
|
|
105
|
+
<input id="stx-footer-tagline" type="text" class="form-input" maxlength="80" placeholder="Websites. Hosting. Support." data-model="footerTagline.value">
|
|
106
|
+
</div>
|
|
107
|
+
<div class="stx-wide">
|
|
108
|
+
<label class="form-label" for="stx-footer-facts">Facts
|
|
109
|
+
<span data-help="Short facts in a row above the bottom bar, one per line, up to four - a town, opening hours, a promise."></span></label>
|
|
110
|
+
<textarea id="stx-footer-facts" class="form-input" rows="3" placeholder="Leeds, UK Open 9 to 5" data-model="footerFacts.value"></textarea>
|
|
111
|
+
</div>
|
|
112
|
+
<div>
|
|
113
|
+
<label class="form-label" for="stx-footer-grad-from">Gradient from
|
|
114
|
+
<span data-help="The colours of the gradient words and the line along the top, as #rrggbb. Leave them empty for your theme's colour."></span></label>
|
|
115
|
+
<input id="stx-footer-grad-from" type="text" class="form-input" maxlength="7" placeholder="#f26b3a" data-model="footerGradFrom.value">
|
|
116
|
+
</div>
|
|
117
|
+
<div>
|
|
118
|
+
<label class="form-label" for="stx-footer-grad-to">Gradient to</label>
|
|
119
|
+
<input id="stx-footer-grad-to" type="text" class="form-input" maxlength="7" placeholder="#8b5cf6" data-model="footerGradTo.value">
|
|
120
|
+
</div>
|
|
121
|
+
</div>
|
|
122
|
+
</div>
|
|
123
|
+
<div class="stx-card dm-settings-section">
|
|
124
|
+
<div class="stx-card-title dm-settings-section-title"><span data-icon="share-2" data-icon-size="16" aria-hidden="true"></span>Social media icons
|
|
125
|
+
<span data-help="The full address of each profile - its icon then shows in the footer. Leave one empty to hide its icon."></span></div>
|
|
126
|
+
<div class="stx-grid">
|
|
127
|
+
<div><label class="form-label" for="stx-s-tw">X / Twitter</label>
|
|
128
|
+
<input id="stx-s-tw" type="url" class="form-input" placeholder="https://x.com/yourhandle" data-model="socialTwitter.value"></div>
|
|
129
|
+
<div><label class="form-label" for="stx-s-fb">Facebook</label>
|
|
130
|
+
<input id="stx-s-fb" type="url" class="form-input" placeholder="https://facebook.com/yourpage" data-model="socialFacebook.value"></div>
|
|
131
|
+
<div><label class="form-label" for="stx-s-ig">Instagram</label>
|
|
132
|
+
<input id="stx-s-ig" type="url" class="form-input" placeholder="https://instagram.com/yourhandle" data-model="socialInstagram.value"></div>
|
|
133
|
+
<div><label class="form-label" for="stx-s-li">LinkedIn</label>
|
|
134
|
+
<input id="stx-s-li" type="url" class="form-input" placeholder="https://linkedin.com/company/yourcompany" data-model="socialLinkedin.value"></div>
|
|
135
|
+
<div><label class="form-label" for="stx-s-gh">GitHub</label>
|
|
136
|
+
<input id="stx-s-gh" type="url" class="form-input" placeholder="https://github.com/yourorg" data-model="socialGithub.value"></div>
|
|
137
|
+
<div><label class="form-label" for="stx-s-yt">YouTube</label>
|
|
138
|
+
<input id="stx-s-yt" type="url" class="form-input" placeholder="https://youtube.com/@yourchannel" data-model="socialYoutube.value"></div>
|
|
139
|
+
</div>
|
|
140
|
+
</div>
|
|
141
|
+
</div>
|
|
142
|
+
</div>
|
|
143
|
+
|
|
144
|
+
</div>
|
|
145
|
+
<link rel="stylesheet" href="/admin/css/site-settings.css">
|