efficient-web-builder 51.0.0 → 53.0.0
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 +66 -0
- package/dist/editor/components/ChatSettingsPanel.js +1 -1
- package/dist/editor/components/MediaUploadField.d.ts +7 -7
- package/dist/editor/components/MediaUploadField.js +1 -1
- package/dist/editor/components/PartSettingsPanel.js +1 -1
- package/dist/editor/components/PartTextBox.js +1 -1
- package/dist/editor/components/PreviewPartAnchors.js +1 -1
- package/dist/editor/components/PreviewPartStyleContext.d.ts +2 -2
- package/dist/editor/components/SectionTextPartBridge.js +1 -1
- package/dist/editor/components/SiteAccentField.js +1 -1
- package/dist/editor/components/SiteTextStylesField.d.ts +3 -2
- package/dist/editor/components/SiteTextStylesField.js +1 -1
- package/dist/editor/components/WebsiteSettingsPanel.js +1 -1
- package/dist/editor/components/storefront-editor.css +82 -64
- package/dist/editor/lib/animation/entrance-fields.js +1 -1
- package/dist/editor/lib/animation/hover-fields.js +1 -1
- package/dist/editor/lib/document/ColourControl.d.ts +11 -8
- package/dist/editor/lib/document/ColourControl.js +1 -1
- package/dist/editor/lib/document/blocks/general/Breadcrumb/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/ButtonBlock/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Cards/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Chart/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Contents/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Divider/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Flex/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Hero/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/HeroSingle/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/HeroSlide/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/ImageBlock/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/IntroBleed/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Logos/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Mockup/fields.js +2 -2
- package/dist/editor/lib/document/blocks/general/PostCard/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/SectionHeader/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Series/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/StatsParagraph/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Timeline/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/index.d.ts +2 -2
- package/dist/editor/lib/document/blocks/shared-fields.d.ts +5 -0
- package/dist/editor/lib/document/blocks/shared-fields.js +1 -1
- package/dist/editor/lib/document/box-fields.d.ts +23 -2
- package/dist/editor/lib/document/box-fields.js +1 -1
- package/dist/editor/lib/document/card-row-fields.js +1 -1
- package/dist/editor/lib/document/choice-pictures.d.ts +21 -0
- package/dist/editor/lib/document/choice-pictures.js +1 -0
- package/dist/editor/lib/document/controls.d.ts +33 -9
- package/dist/editor/lib/document/controls.js +1 -1
- package/dist/editor/lib/document/hidable-rows-drawn.d.ts +1 -0
- package/dist/editor/lib/document/hidable-rows-drawn.js +1 -1
- package/dist/editor/lib/document/overrides.js +1 -1
- package/dist/editor/lib/document/part-panel-rows.d.ts +1 -0
- package/dist/editor/lib/document/part-panel-rows.js +1 -1
- package/dist/editor/lib/document/passes/inspector.js +1 -1
- package/dist/editor/lib/document/separator-field.d.ts +9 -1
- package/dist/editor/lib/document/separator-field.js +1 -1
- package/dist/editor/lib/document/shape-picker.d.ts +37 -0
- package/dist/editor/lib/document/shape-picker.js +1 -0
- package/dist/editor/lib/document/show-for-field.d.ts +6 -0
- package/dist/editor/lib/document/show-for-field.js +1 -0
- package/dist/format/lib/animation/hover.d.ts +0 -2
- package/dist/format/lib/animation/hover.js +1 -1
- package/dist/format/lib/content/borders.d.ts +4 -2
- package/dist/format/lib/content/borders.js +1 -1
- package/dist/format/lib/content/box-layout.d.ts +21 -6
- package/dist/format/lib/content/box-layout.js +1 -1
- package/dist/format/lib/content/box-shape.d.ts +1 -5
- package/dist/format/lib/content/box-shape.js +1 -1
- package/dist/format/lib/content/box-show-for-choices.d.ts +9 -0
- package/dist/format/lib/content/box-show-for-choices.js +1 -0
- package/dist/format/lib/content/button-icon.d.ts +1 -1
- package/dist/format/lib/content/button-icon.js +1 -1
- package/dist/format/lib/content/card-state.d.ts +8 -0
- package/dist/format/lib/content/card-state.js +1 -0
- package/dist/format/lib/content/card-template.js +1 -1
- package/dist/format/lib/content/gallery-card-layout.d.ts +45 -1
- package/dist/format/lib/content/gallery-card-layout.js +1 -1
- package/dist/format/lib/content/image-aspect.d.ts +47 -0
- package/dist/format/lib/content/image-aspect.js +1 -0
- package/dist/format/lib/content/list-number.d.ts +11 -0
- package/dist/format/lib/content/list-number.js +1 -1
- package/dist/format/lib/content/phone-focus.d.ts +4 -1
- package/dist/format/lib/content/phone-focus.js +1 -1
- package/dist/format/lib/content/record-row.d.ts +14 -0
- package/dist/format/lib/content/record-row.js +1 -0
- package/dist/format/lib/content/record-types.d.ts +1 -1
- package/dist/format/lib/content/record-types.js +1 -1
- package/dist/format/lib/content/section-background.d.ts +10 -3
- package/dist/format/lib/content/section-background.js +1 -1
- package/dist/format/lib/content/section-height.d.ts +8 -0
- package/dist/format/lib/content/section-height.js +1 -1
- package/dist/format/lib/content/section-min-height.d.ts +17 -1
- package/dist/format/lib/content/section-min-height.js +1 -1
- package/dist/format/lib/content/section-sticky.d.ts +9 -0
- package/dist/format/lib/content/section-sticky.js +1 -1
- package/dist/format/lib/document/blocks/general/text-part-shapes.json +2 -2
- package/dist/format/lib/document/card-template-layers.d.ts +1 -1
- package/dist/format/lib/document/card-template-layers.js +1 -1
- package/dist/format/lib/document/media-manifest.json +5 -2
- package/dist/format/lib/document/mockup-variant-fields.d.ts +1 -0
- package/dist/format/lib/document/mockup-variant-fields.js +1 -1
- package/dist/format/lib/document/part-inks.d.ts +5 -10
- package/dist/format/lib/document/part-inks.js +1 -1
- package/dist/format/lib/document/passes/types.d.ts +1 -0
- package/dist/format/lib/document/section-catalog.js +2 -2
- package/dist/format/lib/document/section-descriptions.js +1 -1
- package/dist/format/lib/document/show-when-attach.d.ts +2 -1
- package/dist/format/lib/document/show-when-attach.js +1 -1
- package/dist/format/lib/editor-words-catalogue.d.ts +25 -14
- package/dist/format/lib/editor-words-catalogue.js +4 -4
- package/dist/format/lib/fonts.js +1 -1
- package/dist/format/lib/sections/divider-style.d.ts +4 -0
- package/dist/format/lib/sections/divider-style.js +1 -1
- package/dist/format/lib/sections/hero-single-to-hero.js +1 -1
- package/dist/format/lib/sections/section-presets.js +1 -1
- package/dist/format/lib/source-rules/editor-words.js +2 -2
- package/dist/format/lib/source-rules/mirrored-rows-agree.js +4 -4
- package/dist/format/lib/source-rules/panel-rows-use-the-shared-row.d.ts +4 -0
- package/dist/format/lib/source-rules/panel-rows-use-the-shared-row.js +37 -20
- package/dist/format/lib/source-rules/shape-rows-use-the-picker.d.ts +7 -0
- package/dist/format/lib/source-rules/shape-rows-use-the-picker.js +2 -0
- package/dist/format/lib/source-rules/support/part-slider-call-sites.d.ts +0 -1
- package/dist/format/lib/source-rules/support/part-slider-call-sites.js +6 -6
- package/dist/format/lib/text-styles/site-text-colours.d.ts +4 -0
- package/dist/format/lib/text-styles/site-text-colours.js +1 -0
- package/dist/format/lib/theme.d.ts +1 -0
- package/dist/format/lib/theme.js +3 -3
- package/dist/format/lib/word-styles.d.ts +0 -1
- package/dist/format/lib/word-styles.js +1 -1
- package/dist/render/components/Breadcrumb.d.ts +2 -1
- package/dist/render/components/Breadcrumb.js +1 -1
- package/dist/render/components/ButtonBlock.d.ts +1 -0
- package/dist/render/components/ButtonBlock.js +1 -1
- package/dist/render/components/CardRowContext.d.ts +6 -3
- package/dist/render/components/CardRowContext.js +1 -1
- package/dist/render/components/ContentsList.d.ts +4 -1
- package/dist/render/components/ContentsList.js +1 -1
- package/dist/render/components/CurrentRecord.d.ts +23 -0
- package/dist/render/components/CurrentRecord.js +1 -0
- package/dist/render/components/Flex.d.ts +3 -2
- package/dist/render/components/Flex.js +1 -1
- package/dist/render/components/HeroPictures.d.ts +2 -0
- package/dist/render/components/HeroPictures.js +1 -1
- package/dist/render/components/HeroPoster.d.ts +2 -1
- package/dist/render/components/HeroPoster.js +1 -1
- package/dist/render/components/HeroSection.d.ts +2 -1
- package/dist/render/components/HeroSection.js +1 -1
- package/dist/render/components/HeroSingle.d.ts +3 -1
- package/dist/render/components/HeroSingle.js +1 -1
- package/dist/render/components/HeroSlide.d.ts +3 -1
- package/dist/render/components/HeroSlide.js +1 -1
- package/dist/render/components/ImageBlock.d.ts +5 -3
- package/dist/render/components/ImageBlock.js +1 -1
- package/dist/render/components/InBoxContext.d.ts +3 -0
- package/dist/render/components/SiteGutterFrame.d.ts +1 -0
- package/dist/render/components/SiteGutterFrame.js +1 -1
- package/dist/render/components/goldPhrases.js +2 -2
- package/dist/render/lib/content/block-size.d.ts +3 -0
- package/dist/render/lib/content/block-size.js +1 -1
- package/dist/render/lib/content/box-shared-columns.js +1 -1
- package/dist/render/lib/content/box-show-for.d.ts +14 -0
- package/dist/render/lib/content/box-show-for.js +1 -0
- package/dist/render/lib/content/page-contents.d.ts +1 -0
- package/dist/render/lib/content/page-contents.js +1 -1
- package/dist/render/lib/content/picture-focus-rows.d.ts +13 -0
- package/dist/render/lib/content/picture-focus-rows.js +1 -0
- package/dist/render/lib/document/blocks/general/Breadcrumb/render.js +1 -1
- package/dist/render/lib/document/blocks/general/Cards/render.js +1 -1
- package/dist/render/lib/document/blocks/general/Contents/render.js +1 -1
- package/dist/render/lib/document/blocks/general/Flex/render.js +1 -1
- package/dist/render/lib/document/blocks/general/Hero/render.js +1 -1
- package/dist/render/lib/document/blocks/general/HeroSingle/render.js +1 -1
- package/dist/render/lib/document/blocks/general/HeroSlide/render.js +1 -1
- package/dist/render/lib/document/blocks/general/ImageBlock/render.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-row-parts.d.ts +2 -0
- package/dist/render/lib/document/blocks/general/section-to-box-row-parts.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-cards.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-stats.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-timeline.js +2 -2
- package/dist/render/lib/document/blocks/general/section-to-box-rows.js +1 -1
- package/dist/render/lib/document/part-styles.d.ts +21 -7
- package/dist/render/lib/document/part-styles.js +2 -2
- package/dist/render/lib/document/passes/block-size.js +1 -1
- package/dist/render/lib/document/passes/borders.js +1 -1
- package/dist/render/lib/document/passes/index.js +1 -1
- package/dist/render/lib/document/passes/section-height.js +1 -1
- package/dist/render/lib/document/passes/section-sticky.js +1 -1
- package/dist/render/lib/document/passes/show-for.d.ts +2 -0
- package/dist/render/lib/document/passes/show-for.js +1 -0
- package/dist/render/lib/document/show-when.d.ts +1 -1
- package/dist/render/lib/document/show-when.js +1 -1
- package/dist/render/lib/text-styles/site-text-styles.js +2 -2
- package/package.json +3 -3
- package/dist/editor/components/PartInkControl.d.ts +0 -7
- package/dist/editor/components/PartInkControl.js +0 -1
|
@@ -1,23 +1,40 @@
|
|
|
1
|
-
import{ruleChecks as
|
|
2
|
-
`),
|
|
3
|
-
`);
|
|
4
|
-
`).length+
|
|
5
|
-
`);
|
|
6
|
-
`);if(!
|
|
7
|
-
`);c.forEach((
|
|
8
|
-
`);/\blabel=/.test(
|
|
9
|
-
`)
|
|
10
|
-
`)
|
|
11
|
-
`)
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
${a.join(`
|
|
15
|
-
`)}`),e(`…and the ${t.builder} scan actually read rows (${f} call sites in ${n.length} files, at least ${h[t.builder]})`,f>=h[t.builder])}{const t=K(w);for(const l of c)e(`the exception still names a real row — ${l.label}`,(t[l.file]??[]).includes(l.label),`${l.file} no longer draws it`);const n={};for(const[l,y]of Object.entries(t)){const S=y.filter(L=>!c.some(j=>j.file===l&&j.label===L));S.length&&(n[l]=S)}const a=l=>l.slice().sort(),f=[];for(const[l,y]of Object.entries(n)){const S=I[l];if(!S){f.push(`${l} — hand-rolls ${y.length} row(s) and is not in PENDING`);continue}const L=a(y),j=a(S);(L.length!==j.length||L.some((P,W)=>P!==j[W]))&&f.push(`${l} — found [${L.join(" · ")}] but PENDING says [${j.join(" · ")}]`)}e("no NEW hand-rolled settings row",f.length===0,`
|
|
1
|
+
import{ruleChecks as T}from"./rule.js";import{builderModuleSpec as _}from"./support/ts-source.js";import{isRegistryPath as B,registryFiles as J}from"./support/registry-source.js";import{isDocumentPath as v}from"./support/document-folder.js";const N="lib/document/controls.tsx",E={},G={},j=["boxShareField","edgePad","placementField","CoordsField","textList","segmented","select","slider"],U=/sf-field-label|<Label>/,W=/<[A-Z][A-Za-z0-9]*Icon\s*\/>/,D=n=>n.startsWith("//")||n.startsWith("*")||n.startsWith("/*");function z(n,o){const e=n.indexOf("(",o);if(e===-1)return"";let h=0;const c=[];let d=e+1;for(let a=e;a<n.length;a+=1){const r=n[a];if(r==="("||r==="["||r==="{")h+=1;else if(r===")"||r==="]"||r==="}"){if(h-=1,h===0){c.push(n.slice(d,a));break}}else if(r===","&&h===1&&(c.push(n.slice(d,a)),d=a+1,c.length===2))break}return c[1]??""}function M(n,o){const e=new RegExp(`(?:^|[^.\\w])${o}\\s*(?:<[^()]*?>)?\\s*\\(|\\bcontrols\\.${o}\\s*(?:<[^()]*?>)?\\s*\\(`).exec(n);return e?e.index+e[0].length-1:n.indexOf("(")}function K(n,o){const e=n.slice(0,o);return e.includes("//")?!1:(e.match(/"/g)??[]).length%2===0&&(e.match(/`/g)??[]).length%2===0&&(e.match(/'/g)??[]).length%2===0}const P=_("lib/document/controls"),A=(n,o)=>new RegExp(`import \\{[^}]*\\b${o}\\b[^}]*\\} from "${P}"`).test(n)||new RegExp(`import \\* as controls from "${P}"`).test(n);function C(n,o,e){const h=new RegExp(`(^|[^.\\w])${o}\\s*(<[^()]*?>)?\\s*\\(|\\bcontrols\\.${o}\\s*(<[^()]*?>)?\\s*\\(`,"g"),c=new RegExp(`^(export )?function ${o}(<[^>]*>)?\\(`),d=[];let a=0;for(const r of n){const g=r.text.split(`
|
|
2
|
+
`),w=g.join(`
|
|
3
|
+
`);g.forEach((p,u)=>{const x=p.trim();if(D(x)||c.test(x))return;h.lastIndex=0;const I=h.exec(p);if(!I||!K(p,I.index))return;a+=1;const S=z(w,g.slice(0,u).join(`
|
|
4
|
+
`).length+M(p,o));W.test(S)||/<FieldGlyph\b/.test(S)||e.some(t=>t.test(S))||d.push(`${r.path}:${u+1} ${x.slice(0,80)}`)})}return{bare:d,total:a}}function H(n){const o={};for(const e of n){const h=e.text.split(`
|
|
5
|
+
`);h.forEach((c,d)=>{if(!/className="sf-field"/.test(c))return;const a=h.slice(d,d+9).join(`
|
|
6
|
+
`);if(!U.test(a))return;const r=a.match(/sf-field-label[^>]*>([^<{][^<]*)</),g=a.match(/sf-field-label[^>]*>\{([^}]*)\}/),w=a.match(/<Label>([^<{][^<]*)</),p=a.match(/<Label>\{([^}]*)\}/),u=I=>I.trim()==="label"?"{label}":"{...}",x=r?r[1].trim():g?u(g[1]):w?w[1].trim():p?u(p[1]):"{...}";(o[e.path]??=[]).push(x)})}return o}function Z(n){const o=[];let e=0;for(const h of n){const c=h.text.split(`
|
|
7
|
+
`);c.forEach((d,a)=>{if(!/<SettingsField\b/.test(d))return;const r=[];let g=!1;for(let p=a;p<Math.min(a+40,c.length)&&!g;p+=1){let u=c[p];if(u=u.replace(/\/\*[\s\S]*?\*\//g," "),/\/\*/.test(u)&&(u=u.slice(0,u.indexOf("/*"))),/^\s*\*/.test(c[p]))continue;const x=u.indexOf("//");x!==-1&&(u=u.slice(0,x)),r.push(u),u.includes(">")&&(g=!0)}const w=r.join(`
|
|
8
|
+
`);/\blabel=/.test(w)&&(e+=1,!/\bicon=/.test(w)&&o.push(`${h.path}:${a+1} ${d.trim().slice(0,80)}`))})}return{seen:e,bare:o}}const q=/\bcolorInput\(\s*["'`]([^"'`]*(?:background|fill|band)[^"'`]*)["'`]/gi;function F(n){let o=0;const e=new Set;for(const h of n){if(!/(^|\/)lib\/document\/blocks\/.*\/fields\.tsx?$/.test(h.path))continue;const c=h.text.split(`
|
|
9
|
+
`);c.forEach((d,a)=>{const r=/^\s+background:\s*(.*)$/.exec(d);r&&(o+=1,r[1].startsWith("backgroundField(")||e.add(`${h.path}:${a+1}`))});for(const d of h.text.matchAll(q)){const a=h.text.slice(0,d.index).split(`
|
|
10
|
+
`).length;/^\s*(\/\/|\*)/.test(c[a-1])||e.add(`${h.path}:${a}`)}}return{seen:o,off:[...e]}}function ee(n,o){const{check:e,report:h}=T("panel rows use the shared row"),c=o.exceptions??[],{floors:d}=o;{const t={path:"fixture.tsx",text:['import { slider, textList } from "@/lib/document/controls";','const a = { textList: () => controls.textList("Items", <ListIcon />, x) };','const b = slider("Thickness", 0, 10);','const c = slider("Gap", <GapIcon />, 0, 10);','// slider("In a comment", 0, 10) is not a row'].join(`
|
|
11
|
+
`)},s=C([t],"textList",[]),f=C([t],"slider",[]);e("the reader reads a namespaced call's own arguments, not the arrow's",s.total===1&&s.bare.length===0,JSON.stringify(s)),e("the reader flags a bare row whose neighbour has a glyph, and skips a comment",f.total===2&&f.bare.length===1&&f.bare[0].startsWith("fixture.tsx:3"),JSON.stringify(f));const b={path:"wrapped.tsx",text:['const a = { shape: withShowWhen(segmented("Shape", <SquareIcon />, opts), rule) };','const b = { size: withShowWhen(segmented("Size", opts), rule) };'].join(`
|
|
12
|
+
`)},i=C([b],"segmented",[]);e("the reader reads a wrapped call's own arguments: the glyphed row passes, the bare one is caught",i.total===2&&i.bare.length===1&&i.bare[0].startsWith("wrapped.tsx:2"),JSON.stringify(i))}const a=new Map(n.map(t=>[t.path,t])),r=n.find(t=>v(t.path,"controls.tsx"));e(o.writesBuilders?`read ${N}, where the builders are declared`:`${N} is not among this repository's files (it calls the builders, it does not declare them)`,!!r===o.writesBuilders);const g=J(n),w=o.holdsRegistry!==!1;e(w?`read this repository's share of the block registry (${g.length} files)`:`this repository holds no block registry, as it says (${g.length} registry files handed in)`,w?g.length>0:g.length===0);const p=n.filter(t=>/^components\/[^/]+\.tsx$/.test(t.path)),u=n.filter(t=>/^scripts\/[^/]+\.tsx$/.test(t.path)),x=[...g,...r?[r]:[],...p],I=t=>v(t.path,"controls.tsx");{const t=x.filter(i=>I(i)||A(i.text,"toggle")),s=t.filter(i=>I(i)||B(i.path));e("only the known files use the toggle builder",t.length===s.length&&(!o.writesBuilders||s.some(I))&&(!w||s.some(i=>B(i.path))),t.map(i=>i.path).join(" · "));const f=[];let b=0;for(const i of s)i.text.split(`
|
|
13
|
+
`).forEach((y,l)=>{const m=y.trim();D(m)||/classList\.toggle/.test(y)||/^export function toggle\(/.test(m)||/(^|[^.\w])toggle\(/.test(y)&&(b+=1,!(W.test(y)||/<FieldGlyph\b/.test(y))&&f.push(`${i.path}:${l+1} ${m.slice(0,80)}`))});e("every toggle() row carries a glyph",f.length===0,`
|
|
16
14
|
${f.join(`
|
|
17
|
-
`)}`)
|
|
15
|
+
`)}`),e(`…and there are rows to check (${b} toggle() call sites, at least ${d.toggle})`,b>=d.toggle,"the scan is reading nothing")}const S=[{builder:"textList",inControls:!1,accept:[/TICKER_ITEMS_ROW\.icon/],name:"every textList() row carries a glyph"},{builder:"segmented",inControls:!0,accept:[/\bnoGlyph\(/],name:"every segmented() row carries a glyph (or a ruled noGlyph)"},{builder:"select",inControls:!0,accept:[/\btextKindGlyph\(/,/\bnoGlyph\(/],name:"every select() row carries a glyph (or a ruled noGlyph)"},{builder:"slider",inControls:!0,accept:[/\bnoGlyph\(/],name:"every slider() row carries a glyph"}];for(const t of S){const s=[...g,...t.inControls&&r?[r]:[],...u].filter(i=>t.inControls&&I(i)||B(i.path)||A(i.text,t.builder)),{bare:f,total:b}=C(s,t.builder,t.accept);e(t.name,f.length===0,`
|
|
16
|
+
${f.join(`
|
|
17
|
+
`)}`),e(`…and the ${t.builder} scan actually read rows (${b} call sites in ${s.length} files, at least ${d[t.builder]})`,b>=d[t.builder])}{const t=H(x);for(const l of c)e(`the exception still names a real row — ${l.label}`,(t[l.file]??[]).includes(l.label),`${l.file} no longer draws it`);const s={};for(const[l,m]of Object.entries(t)){const k=m.filter(O=>!c.some($=>$.file===l&&$.label===O));k.length&&(s[l]=k)}const f=l=>l.slice().sort(),b=[];for(const[l,m]of Object.entries(s)){const k=E[l];if(!k){b.push(`${l} — hand-rolls ${m.length} row(s) and is not in PENDING`);continue}const O=f(m),$=f(k);(O.length!==$.length||O.some((R,L)=>R!==$[L]))&&b.push(`${l} — found [${O.join(" · ")}] but PENDING says [${$.join(" · ")}]`)}e("no NEW hand-rolled settings row",b.length===0,`
|
|
18
|
+
${b.join(`
|
|
19
|
+
`)}`);const i=Object.keys(E).filter(l=>!s[l]);e("no PENDING entry has outlived its subject",i.length===0,i.join(" · "));const y=Object.values(s).reduce((l,m)=>l+m.length,0);e("the hand-rolled rows are GONE — the count is zero",y===0,`${y}`),e("…and no file is left hand-rolling one",Object.keys(E).length===0,Object.keys(E).join(" · ")),e(`…and the rulings are exactly ${o.rulings} (a new one is argued in review, not added)`,c.length===o.rulings&&c.every(l=>l.why.trim().length>40),`${c.length}`),e("…and BlogSource is not among them, because its row is gone",!c.some(l=>l.file.endsWith("BlogSource.tsx")))}{const t=Object.values(G).reduce((s,f)=>s+f,0);if(e("every builder is finished — nothing left to count",t===0,`${t}`),e("…and the emptiness is because FOUR builders are done, not because the list was cleared",j.length===8&&["textList","segmented","select","slider"].every(s=>j.includes(s)),j.join(" · ")),e("…and a finished builder has left the list",j.every(s=>!(s in G)),j.join(" · ")),r){const s=Object.keys(G).filter(f=>!new RegExp(`(export )?function ${f}\\(`).test(r.text));e(`…and every builder it names is really declared in ${N}`,s.length===0,s.join(" · "))}}if(r){const t=r.text,s=t.indexOf("export function backgroundField("),f=s===-1?"":t.slice(s),b=f.slice(0,f.indexOf(`
|
|
20
|
+
}
|
|
21
|
+
`)),i=t.indexOf("function SectionBandColourRow("),y=i===-1?"":t.slice(i),l=y.slice(0,y.indexOf(`
|
|
18
22
|
}
|
|
19
|
-
`))
|
|
23
|
+
`)),m=F([{path:"lib/document/blocks/general/Fixture/fields.tsx",text:` fields: {
|
|
24
|
+
background: colorInput("Background color"),
|
|
25
|
+
},`}]);e("a block's `background:` row on another builder is refused",m.seen===1&&m.off.length===1);const k=F([{path:"lib/document/blocks/general/Fixture/fields.tsx",text:` fields: {
|
|
26
|
+
bandColor: colorInput("Band color"),
|
|
27
|
+
panelFill: colorInput(
|
|
28
|
+
"Panel fill",
|
|
29
|
+
),
|
|
30
|
+
tintColor: colorInput("Tint color"),
|
|
31
|
+
// old: colorInput("Background color"),
|
|
32
|
+
},`}]);e("a band or fill label on `colorInput` is refused under any key, a tint and a comment are not",k.off.length===2&&k.off[0].endsWith(":2")&&k.off[1].endsWith(":3"),JSON.stringify(k));const O=F([{path:"lib/document/blocks/general/Fixture/fields.ts",text:` fields: {
|
|
33
|
+
background: colorInput("Background color"),
|
|
34
|
+
},`}]);e("a block's `fields.ts` is read as well as its `fields.tsx`",O.seen===1&&O.off.length===1,JSON.stringify(O));const $=F(n);e(`the band row scan read every band section (${$.seen}, at least 5)`,$.seen>=5),e("every block's `background:` row is `backgroundField`",$.off.length===0,`
|
|
35
|
+
${$.off.join(`
|
|
36
|
+
`)}`),e("backgroundField is declared",s!==-1),e("backgroundField draws SectionBandColourRow",/<SectionBandColourRow\b/.test(b)),e("…which renders the shared InheritedColourRow",/<InheritedColourRow\b/.test(l)),e("…and hand-rolls no row of its own",l.length>0&&!/className="sf-field"/.test(l)),e("…and passes `BackgroundIcon`, not merely some glyph",/icon=\{<BackgroundIcon \/>\}/.test(l));const R=t.indexOf("export function cardImageBackgroundField("),L=R===-1?"":t.slice(R);e("…and cardImageBackgroundField still passes `GroundIcon`",/icon=\{<GroundIcon \/>\}/.test(L.slice(0,L.indexOf(`
|
|
20
37
|
}
|
|
21
|
-
`))))}{const{seen:t,bare:
|
|
22
|
-
${
|
|
23
|
-
`)}`)}return
|
|
38
|
+
`))))}{const{seen:t,bare:s}=Z(p);e(`the hand-rolled row scan read something (${t} hand-drawn SettingsField rows across ${p.length} files, at least ${d.handDrawn})`,t>=d.handDrawn),e("no hand-rolled SettingsField row goes without a glyph",s.length===0,`
|
|
39
|
+
${s.join(`
|
|
40
|
+
`)}`)}return h()}export{N as CONTROLS_FILE,F as bandRowsOffTheHouseRow,M as callParen,ee as panelRowsUseTheSharedRow,z as secondArg};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type * as TS from "typescript";
|
|
2
|
+
import { type RuleReport, type SourceFile } from "./rule.js";
|
|
3
|
+
export type ShapeRowsOptions = {
|
|
4
|
+
readonly selectRows: readonly string[];
|
|
5
|
+
readonly minFiles: number;
|
|
6
|
+
};
|
|
7
|
+
export declare function shapeRowsUseThePicker(ts: typeof TS, files: readonly SourceFile[], options: ShapeRowsOptions): RuleReport;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{isRuleSource as b,ruleChecks as S}from"./rule.js";const k=new Set(["Select","SettingsSelect","FieldSelect"]);function u(s,n){const i=s.createSourceFile(n.path,n.text,s.ScriptTarget.Latest,!0,s.ScriptKind.TSX),r=[],p=[],c=e=>i.getLineAndCharacterOfPosition(e.getStart(i)).line+1,d=e=>{let t=e;for(;t&&(s.isAsExpression(t)||s.isSatisfiesExpression(t)||s.isParenthesizedExpression(t));)t=t.expression;return t},a=e=>e?s.isStringLiteralLike(e)?e.text:e.getText(i):"(no label)",x=e=>e.name&&(s.isIdentifier(e.name)||s.isStringLiteralLike(e.name))?e.name.text:void 0,f=(e,t)=>{for(const o of e.properties)if(x(o)===t){if(s.isPropertyAssignment(o))return o.initializer;if(s.isShorthandPropertyAssignment(o))return o.name}},h=e=>{const t=e.parent;return s.isCallExpression(t)&&s.isIdentifier(t.expression)&&t.expression.text==="describedAs"&&t.arguments[1]===e},m=e=>{if(s.isCallExpression(e)){const t=e.arguments[0];(s.isIdentifier(e.expression)&&e.expression.text==="select"||s.isPropertyAccessExpression(e.expression)&&e.expression.name.text==="select")&&e.arguments.length>=2&&t&&!s.isObjectLiteralExpression(t)&&r.push(`${n.path}|${a(t)}`);const l=e.arguments[1];(e.expression.getText(i).endsWith("createElement")||s.isIdentifier(e.expression)&&e.expression.text==="h")&&t&&t.getText(i).replace(/<[\s\S]*>$/,"")==="IconPicker"&&l&&s.isObjectLiteralExpression(l)&&l.properties.some(y=>x(y)==="emptyValue")&&p.push(c(l))}if(s.isImportSpecifier(e)&&e.propertyName&&(e.propertyName.text==="select"||e.propertyName.text==="IconPicker")&&r.push(`${n.path}|alias ${e.name.text}`),s.isBindingElement(e)&&e.propertyName&&s.isIdentifier(e.propertyName)&&e.propertyName.text==="select"&&r.push(`${n.path}|alias ${e.name.getText(i)}`),(s.isJsxOpeningElement(e)||s.isJsxSelfClosingElement(e))&&k.has(e.tagName.getText(i))){const t=e.attributes.properties.find(l=>s.isJsxAttribute(l)&&l.name.getText(i)==="label"),o=t&&s.isJsxAttribute(t)?t.initializer:void 0;r.push(`${n.path}|<${e.tagName.getText(i)}> ${o?a(s.isJsxExpression(o)?o.expression:o):"(no label)"}`)}if(s.isObjectLiteralExpression(e))for(const t of["type","kind"]){const o=d(f(e,t));o&&s.isStringLiteralLike(o)&&o.text==="select"&&!h(e)&&r.push(`${n.path}|${a(f(e,"label"))}`)}s.isJsxAttribute(e)&&e.name.getText(i)==="emptyValue"&&e.parent.parent.tagName.getText(i)==="IconPicker"&&p.push(c(e)),s.isJsxSpreadAttribute(e)&&e.parent.parent.tagName.getText(i)==="IconPicker"&&p.push(c(e)),s.forEachChild(e,m)};return m(i),{selects:r,emptyValues:p}}function g(s){const n=new Map;for(const i of s)n.set(i,(n.get(i)??0)+1);return n}function A(s,n,i){const{check:r,report:p}=S("shape rows use the picker");{const e=['const a = select("Corner shape", icon, options);','const b = { type: "select", label: "Card shape", options };','const c = { type: "select" as const, label: LABEL, options };',"const d = select(item);",'const e = iconPickerRow("Corner shape", icon, options, "a");','const f = <IconPicker label="x" emptyValue="none" options={o} />;','const g = <IconPicker label="x" options={o} />;','const h = <Other emptyValue="none" />;','// select("A comment", icon) is not a use','const i = select(say("Said"), icon, options);',"const j = select(LABELS.x, icon, options);","const k = select(`A ${b}`, icon, options);",'const l = { "type": "select", label, options };',"const m = select({ index }, other);",'import { select as pick } from "x";','const n = createElement(IconPicker<V>, { label: "x", emptyValue: "none" });','const o = createElement(IconPicker, { label: "x" });','const p = rows.select("By a member", icon, options);',"const { select: q } = rows;",'const r = { type: "select" satisfies string, label: "Satisfied", options };','const s = { kind: "select", label: "A kind", options };','const t = <SettingsSelect label="Hand drawn" options={o} />;',"const u = <FieldSelect value={v} options={o} />;",'const v = <IconPicker label="x" {...rest} />;','import { IconPicker as Pick } from "x";','const w = describedAs(field, { type: "select", label: "Described" });',"const x = rows.select(item);"].join(`
|
|
2
|
+
`),t=u(s,{path:"f.tsx",text:e});r("R1 finds the builder and both field forms, and nothing else",JSON.stringify(t.selects)===JSON.stringify(["f.tsx|Corner shape","f.tsx|Card shape","f.tsx|LABEL",'f.tsx|say("Said")',"f.tsx|LABELS.x","f.tsx|`A ${b}`","f.tsx|label","f.tsx|alias pick","f.tsx|By a member","f.tsx|alias q","f.tsx|Satisfied","f.tsx|A kind","f.tsx|<SettingsSelect> Hand drawn","f.tsx|<FieldSelect> (no label)","f.tsx|alias Pick"]),JSON.stringify(t.selects)),r("R2 finds emptyValue on an IconPicker only, in both forms, and a spread",JSON.stringify(t.emptyValues)==="[6,16,24]",JSON.stringify(t.emptyValues))}const c=n.filter(e=>/\.tsx?$/.test(e.path)&&!e.path.endsWith(".d.ts")&&!b(e.path)),d=[],a=[];for(const e of c){const t=u(s,e);d.push(...t.selects),t.emptyValues.forEach(o=>a.push(`${e.path}:${o}`))}const x=g(d),f=g(i.selectRows),h=[...x].filter(([e,t])=>t>(f.get(e)??0)).map(([e])=>e).sort(),m=[...f].filter(([e,t])=>t>(x.get(e)??0)).map(([e])=>e);return r("R1 every select row is on the repository's list",h.length===0,`${h.join(", ")}: a row that picks between shapes uses iconPickerRow or shapePickerRow; a row that picks words joins the list`),r("R1 every name on the list is still a select row",m.length===0,`${m.join(", ")}: remove the entry`),r("R2 no IconPicker takes emptyValue",a.length===0,`${a.join(", ")}: use pickerNoneIcon, so the closed word has the size of every other`),r(`walked the source (${c.length} TS/TSX files, at least ${i.minFiles})`,c.length>=i.minFiles),p()}export{A as shapeRowsUseThePicker};
|
|
@@ -3,7 +3,6 @@ export interface SliderCallSite {
|
|
|
3
3
|
fields: string[];
|
|
4
4
|
line: number;
|
|
5
5
|
readoutOff: boolean;
|
|
6
|
-
labelFor(field: string): string;
|
|
7
6
|
}
|
|
8
7
|
export declare function readSliderCallSites(source: string): SliderCallSite[];
|
|
9
8
|
export declare const sliderFields: (sites: readonly SliderCallSite[]) => string[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
const
|
|
2
|
-
`;)e+=1;continue}if(
|
|
3
|
-
`&&(
|
|
4
|
-
`),e+=1;e+=2;continue}
|
|
1
|
+
const d="components/PartSettingsPanel.tsx";function p(n){let i="",e=0,s=null;for(;e<n.length;){const t=n[e],o=n[e+1];if(s){if(i+=t,t==="\\"){i+=o??"",e+=2;continue}t===s&&(s=null),e+=1;continue}if(t==='"'||t==="'"||t==="`"){s=t,i+=t,e+=1;continue}if(t==="/"&&o==="/"){for(;e<n.length&&n[e]!==`
|
|
2
|
+
`;)e+=1;continue}if(t==="/"&&o==="*"){for(e+=2;e<n.length&&!(n[e]==="*"&&n[e+1]==="/");)n[e]===`
|
|
3
|
+
`&&(i+=`
|
|
4
|
+
`),e+=1;e+=2;continue}i+=t,e+=1}return i}function c(n){throw new Error(n)}function u(n){const i=p(n),e=[];for(const s of i.matchAll(/<Slider[\s/>]/g)){const t=s.index??0,o=i.indexOf("/>",t);o===-1&&c(`${d}: a <Slider at offset ${t} is not self-closing. This reader reads a call site's props up to \`/>\`; a Slider with children needs a different reader.`);const h=i.slice(t,o),l=i.slice(0,t),r=/((?:\s*case\s+"[^"]+"\s*:)+)\s*return\s*\(\s*$/.exec(l),a=r?[...r[1].matchAll(/case\s+"([^"]+)"\s*:/g)].map(f=>f[1]):[];a.length===0&&c(`${d}: the <Slider at line ${l.split(`
|
|
5
5
|
`).length} is not returned DIRECTLY by a
|
|
6
6
|
\`case "…": return (\` branch, so this reader cannot say which field it draws.
|
|
7
7
|
|
|
@@ -13,5 +13,5 @@ const a="components/PartSettingsPanel.tsx";function w(t){let n="",e=0,o=null;for
|
|
|
13
13
|
is the wrapper, not the slot, and the row would look fixed while measuring the same 129px.
|
|
14
14
|
|
|
15
15
|
So a wrap needs a decision, not a wider selector — either unwrap it, or give the wrapper the
|
|
16
|
-
row and say why in \`components/storefront-editor.css\`. Card 66247.`),
|
|
17
|
-
`).length,readoutOff:/readout=\{false\}/.test(
|
|
16
|
+
row and say why in \`components/storefront-editor.css\`. Card 66247.`),e.push({fields:a,line:l.split(`
|
|
17
|
+
`).length,readoutOff:/readout=\{false\}/.test(h)})}return e}const w=n=>n.flatMap(i=>i.fields);export{d as PART_PANEL,u as readSliderCallSites,w as sliderFields};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { TextStyleColour, TextStyleColourNameOf } from "efficient-easel/text-styles";
|
|
2
|
+
import { type ThemeValue } from "../theme.js";
|
|
3
|
+
export declare function siteTextColours(theme: ThemeValue): TextStyleColour[];
|
|
4
|
+
export declare function siteTextColourNameOf(theme: ThemeValue): TextStyleColourNameOf;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{partColourName as m,partThemeColors as c}from"../document/part-inks.js";import{normalizeThemeColors as l,selectedThemeColors as i}from"../theme.js";const n="background";function a(r){const e=l(i(r));return c({main:e.accent,text:e.text,background:e.background,muted:e.muted}).map(o=>({key:o.name,name:o.label??o.name,value:o.value}))}function d(r){return a(r).filter(e=>e.key!==n)}function k(r){const e=a(r).filter(o=>o.key===n);return o=>{const t=m(o);return e.find(u=>u.key===t)?.value??t}}export{k as siteTextColourNameOf,d as siteTextColours};
|
|
@@ -69,6 +69,7 @@ export declare function siteButtonPaint(v?: ThemeValue | null): {
|
|
|
69
69
|
ink: string;
|
|
70
70
|
};
|
|
71
71
|
export declare function themePresetAccentVars(v?: ThemeValue | null): Record<string, string>;
|
|
72
|
+
export declare function surfaceTwoTone(preset: ThemeColors): string;
|
|
72
73
|
export declare function sectionBandTone(preset: ThemeColors): string;
|
|
73
74
|
export declare function bandPresetFor(preset: ThemeColors): ThemeColors;
|
|
74
75
|
export declare function bandPresetIndex(presets: readonly ThemeColors[], page: number): number;
|
package/dist/format/lib/theme.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import{contrastRatio as
|
|
1
|
+
import{contrastRatio as K,hexToRgb as h,parseHexColor as f,readableInk as j,relativeLuminance as V}from"efficient-shell/format";const Z="storefront-theme",Oe="sf:theme-mode",Le="sf:theme-switch",ke="hide",Pe="light",$e=!1,M=7,R=18;function q(e){return e>=M&&e<R}function Fe(e){const{mode:t,override:n,switchShown:r,hour:o}=e;return r&&(n==="light"||n==="dark")?n:t==="auto"?q(o)?"light":"dark":t==="light"?"light":"dark"}function Ge(e){const{mode:t,switchShown:n}=e;return`
|
|
2
2
|
try {
|
|
3
3
|
var mode = ${JSON.stringify(t)};
|
|
4
4
|
var shown = ${n?"true":"false"};
|
|
5
|
-
var override = localStorage.getItem(${JSON.stringify(
|
|
5
|
+
var override = localStorage.getItem(${JSON.stringify(Z)});
|
|
6
6
|
var theme;
|
|
7
7
|
if (shown && (override === 'light' || override === 'dark')) {
|
|
8
8
|
theme = override;
|
|
@@ -15,4 +15,4 @@ import{contrastRatio as X,hexToRgb as l,parseHexColor as h,readableInk as W,rela
|
|
|
15
15
|
if (theme === 'light') document.documentElement.setAttribute('data-theme', 'light');
|
|
16
16
|
else document.documentElement.removeAttribute('data-theme');
|
|
17
17
|
} catch (e) {}
|
|
18
|
-
`}const s={background:"#0a0a0a",surface:"#131313",line:"#2a2a2a",muted:"#9a9388"},Z=[{text:"#2e2e2e",accent:"#2e2e2e",background:"#ffffff",surface:"#f7f7f7",line:"#e0e0e0",muted:"#5c5c5c"},{text:"#f7f7f7",accent:"#f7f7f7",background:"#0a0a0a",surface:"#1b1b1b",line:"#363636",muted:"#a3a3a3"},{text:"#ffffff",accent:"#ffffff",background:"#2e2e2e",surface:"#3d3d3d",line:"#545454",muted:"#b0b0b0"},{text:"#0a0a0a",accent:"#0a0a0a",background:"#f7f7f7",surface:"#ffffff",line:"#d9d9d9",muted:"#5c5c5c"}],q={selected:0,themes:Z};function D(e){return!e||!Array.isArray(e.themes)||e.themes.length===0?{...q}:{selected:Math.min(Math.max(0,e.selected??0),e.themes.length-1),themes:e.themes}}function x(e,t,n){const r=l(e),o=l(t);if(r===null||o===null)return e;const c=(i,a)=>Math.max(0,Math.min(255,Math.round(i+(a-i)*n))).toString(16).padStart(2,"0");return`#${c(r.r,o.r)}${c(r.g,o.g)}${c(r.b,o.b)}`}const J={light:"#ffffff",dark:"#0a0a0a"},Ge=["light","dark"];function Ue(e,t){const n=J[t],r=t==="light"?"#ffffff":"#000000";return{text:n,accent:n,background:e,surface:x(e,r,.1),line:x(e,r,.22),muted:x(n,e,.35),brandInk:t}}function u(e){const t=D(e);return t.themes[t.selected]}function f(e){return{text:e.text,accent:e.accent,background:e.background||s.background,surface:e.surface||s.surface,line:e.line||s.line,muted:e.muted||s.muted}}function Ye(e){return{fill:f(e).background,accent:e.accent}}const Q=.4,v=4.5,ee=3,ze={good:"Good","large-only":"Large text only",hard:"Hard to read"};function Be(e){return e>=v?"good":e>=ee?"large-only":"hard"}const te=["#000000","#ffffff"];function d(e){return W(e,te)}const ne=[.25,.4,.55];function Xe(e){const t=l(e);return t===null?[]:ne.map(n=>"#"+[t.r,t.g,t.b].map(r=>Math.round(r*(1-n)).toString(16).padStart(2,"0")).join(""))}function We(e){const t=u(e),n={"--theme-fg":t.text},r=K(t.text);return(r===null||r>=Q)&&(n["--overlay-fg"]=t.text),n}const re=82;function p(e){return`color-mix(in srgb, ${e} ${re}%, #000)`}function Ke(e){const t=u(e);return{"--theme-accent":t.accent,"--theme-accent-2":p(t.accent),"--theme-accent-ink":d(t.accent)}}function _(e){const t=e?.button;return t&&h(t)===t.toLowerCase()?t.toLowerCase():null}function je(e){const t=u(e),n=_(t),r=H(t);if(n===null&&r===null)return{};const o={};return n!==null&&(o["--theme-btn"]=n,o["--theme-btn-2"]=p(n)),o["--theme-btn-ink"]=r??d(n),o}function H(e){const t=e?.buttonInk;return t&&h(t)===t.toLowerCase()?t.toLowerCase():null}function oe(e,t){return H(e)??d(_(e)??t)}function Ve(e){const t=u(e);return{fill:_(t)??t.accent.toLowerCase(),ink:oe(t,t.accent)}}function Ze(e){const t={};return D(e).themes.forEach((n,r)=>{const o=f(n);t[`--theme-preset-${r}-accent`]=o.accent,t[`--theme-preset-${r}-accent-2`]=p(o.accent),t[`--theme-preset-${r}-accent-ink`]=d(o.accent),t[`--theme-preset-${r}-bg`]=o.background,t[`--theme-preset-${r}-fg`]=o.text,t[`--theme-preset-${r}-surface`]=o.surface,t[`--theme-preset-${r}-surface-2`]=`color-mix(in srgb, ${o.surface} 60%, ${o.line})`,t[`--theme-preset-${r}-line`]=o.line,t[`--theme-preset-${r}-muted`]=o.muted}),t}const E=e=>{const t=e/255;return t<=.04045?t/12.92:((t+.055)/1.055)**2.4},S=e=>255*(e<=.0031308?12.92*e:1.055*e**(1/2.4)-.055);function N([e,t,n]){const[r,o,c]=[E(e),E(t),E(n)],i=Math.cbrt(.4122214708*r+.5363325363*o+.0514459929*c),a=Math.cbrt(.2119034982*r+.6806995451*o+.1073969566*c),m=Math.cbrt(.0883024619*r+.2817188376*o+.6299787005*c);return[.2104542553*i+.793617785*a-.0040720468*m,1.9779984951*i-2.428592205*a+.4505937099*m,.0259040371*i+.7827717662*a-.808675766*m]}function ce([e,t,n]){const r=(e+.3963377774*t+.2158037573*n)**3,o=(e-.1055613458*t-.0638541728*n)**3,c=(e-.0894841775*t-1.291485548*n)**3;return[S(4.0767416621*r-3.3077115913*o+.2309699292*c),S(-1.2684380046*r+2.6097574011*o-.3413193965*c),S(-.0041960863*r-.7034186147*o+1.707614701*c)]}const A=e=>{const t=l(e);return t===null?[0,0,0]:[t.r,t.g,t.b]},O=(e,t,n)=>[e[0]*n+t[0]*(1-n),e[1]*n+t[1]*(1-n),e[2]*n+t[2]*(1-n)],ie=e=>`#${e.map(t=>Math.max(0,Math.min(255,Math.round(t))).toString(16).padStart(2,"0")).join("")}`;function L(e){const t=f(e),n=O(A(t.surface),A(t.line),.6);return ie(ce(O(N(n),N(A(t.text)),.92)))}function qe(e){return{...e,background:L(e)}}function Je(e,t){const n=e[t];if(!n)return-1;const r=L(n);return e.findIndex((o,c)=>c!==t&&h(o.background??"")===r)}const Qe=["--theme-bg","--theme-surface","--theme-surface-2","--theme-line","--theme-muted"];function ve(e){const t=f(u(e)),n=`color-mix(in srgb, ${t.surface} 60%, ${t.line})`,r={"--theme-bg":t.background,"--theme-surface":t.surface,"--theme-line":t.line,"--theme-muted":t.muted};return(t.surface!==s.surface||t.line!==s.line)&&(r["--theme-surface-2"]=n),r}const se=["heading","body","label"],et={heading:"Headings",body:"Body",label:"Labels"};function tt(e){if(!e)return null;for(const t of se)if(e.includes(`--size-${t}`))return t;return/--size-heading(Large|Medium|Small)/.test(e)?"heading":null}const k=["headingLarge","headingMedium","headingSmall","accent","body","label"],nt={headingLarge:"heading",headingMedium:"heading",headingSmall:"heading",accent:"heading",body:"body",label:"label"},rt={headingLarge:null,headingMedium:null,headingSmall:null,accent:null,body:null,label:null},ae=8,ue=200;function le(e){if(typeof e!="number"||!Number.isFinite(e))return null;const t=Math.round(e);return t>=ae&&t<=ue?t:null}function he(e){const t={};for(const n of k)t[n]=le(e?.[n]);return t}function ot(e){const t=he(e),n={};for(const r of k){const o=t[r];o!==null&&(n[`--size-${r}`]=`${o}px`)}return n}const fe=["square","small","large"],de="small";function ge(e){return fe.includes(e??"")?e:de}function ct(e){return $(xe[ge(e)])}const T=0,me=40,xe={square:0,small:null,large:16},P={"--sf-card-radius":1,"--sf-button-radius":.5,"--site-radius":.5,"--site-radius-xs":.25,"--site-radius-sm":.5,"--site-radius-md":.75,"--site-radius-lg":1,"--site-radius-xl":1.25,"--site-radius-2xl":1.5,"--site-radius-3xl":2,"--site-radius-4xl":2.5};function b(e){if(e==null||typeof e=="string"&&e.trim()==="")return null;const t=typeof e=="string"?Number(e):e;return Number.isFinite(t)?Math.min(me,Math.max(T,Math.round(t))):null}function $(e){const t=b(e);return t===null?{}:Object.fromEntries(Object.entries(P).map(([n,r])=>{const o=t*r/16;return[n,o===0?"0":`${o}rem`]}))}function it(e){return(b(e)??T)*P["--sf-button-radius"]}function st(e){return $(b(e)??T)}const pe=["none","soft","lifted"],_e="soft",F="none",Ee=["tight","normal","roomy"],Se="normal",Ae="normal",Te=["none","lift","highlight"],be="lift",Ce="highlight",G="#141416";function U(e){return pe.includes(e??"")?e:_e}function Ie(e){return Ee.includes(e??"")?e:Se}function Y(e){return Te.includes(e??"")?e:be}function we(e){return e&&h(e)===e.toLowerCase()?e.toLowerCase():G}function at(e){const t=U(e);return t===F?void 0:t}function ut(e){const t=Ie(e);return t===Ae?void 0:t}function lt(e){const t=Y(e);return t===Ce?void 0:t}function ht(e,t,n){const r=we(t);return r===G?{}:U(e)!==F||Y(n)==="lift"?{"--sf-shadow-color":r}:{}}const ye=["normal","tight","compressed"],z="normal";function B(e){return ye.includes(e??"")?e:z}function ft(e){const t=B(e);return t===z?void 0:t}function dt(e){switch(B(e)){case"tight":return{lineHeight:.95,letterSpacing:-.01};case"compressed":return{lineHeight:.86,letterSpacing:-.01};default:return{}}}const gt=["authored","sentence"],mt={case:"authored",weight:null,weightStrong:null,italicStrong:null,maxPx:null,weight2:null,weight3:null,case2:"authored",case3:"authored"},C=100,I=900,Me=24,Re=200;function g(e,t,n){return typeof e!="number"||!Number.isFinite(e)?null:Math.round(Math.min(Math.max(e,t),n))}function w(e){const t=g(e?.weight,C,I),n=e?.case==="sentence"?"sentence":"authored",r=c=>c==null?t:g(c,C,I),o=c=>c==="sentence"?"sentence":c==="authored"?"authored":n;return{case:n,weight:t,weightStrong:g(e?.weightStrong,C,I),italicStrong:typeof e?.italicStrong=="boolean"?e.italicStrong:null,maxPx:g(e?.maxPx,Me,Re),weight2:r(e?.weight2),weight3:r(e?.weight3),case2:o(e?.case2),case3:o(e?.case3)}}function xt(e){const t=w(e),n={};return t.case==="sentence"&&(n["--sf-heading-case"]="none"),t.weight!==null&&(n["--sf-heading-weight"]=String(t.weight)),t.weightStrong!==null&&(n["--sf-heading-weight-strong"]=String(t.weightStrong)),t.maxPx!==null&&(n["--sf-heading-max"]=`${t.maxPx}px`),t.weight2!==null&&t.weight2!==t.weight&&(n["--sf-heading-2-weight"]=String(t.weight2)),t.weight3!==null&&t.weight3!==t.weight&&(n["--sf-heading-3-weight"]=String(t.weight3)),t.case2!==t.case&&(n["--sf-heading-2-case"]=t.case2==="sentence"?"none":"uppercase"),t.case3!==t.case&&(n["--sf-heading-3-case"]=t.case3==="sentence"?"none":"uppercase"),n}function pt(e){return w({case:e?.heading_case??void 0,weight:e?.heading_weight,weightStrong:e?.heading_weight_strong,italicStrong:e?.accent_italic,maxPx:e?.heading_max_px,weight2:e?.heading_2_weight??void 0,weight3:e?.heading_3_weight??void 0,case2:e?.heading_2_case??void 0,case3:e?.heading_3_case??void 0})}function _t(e){const t=w(e);return{heading_case:t.case,heading_weight:t.weight,heading_weight_strong:t.weightStrong,heading_max_px:t.maxPx,heading_2_weight:t.weight2,heading_3_weight:t.weight3,heading_2_case:t.case2,heading_3_case:t.case3}}const y="siteTheme";function De(e){const t=e;if(!t||typeof t!="object"||!Array.isArray(t.themes)||!t.themes.every(r=>!!r&&typeof r=="object"))return{};const n=typeof t.selected=="number"&&Number.isInteger(t.selected)&&t.selected>=0?t.selected:0;return{[y]:{selected:n,themes:t.themes}}}function Et(e){return De(e?.[y])[y]}export{ne as ACCENT_DARKEN_STEPS,Ge as BRAND_INKS,Ee as CARD_GAPS,pe as CARD_SHADOWS,me as CORNER_RADIUS_MAX,T as CORNER_RADIUS_MIN,fe as CORNER_STYLES,xe as CORNER_STYLE_TO_PX,Se as DEFAULT_CARD_GAP,_e as DEFAULT_CARD_SHADOW,de as DEFAULT_CORNER_STYLE,z as DEFAULT_HEADING_COMPRESSION,mt as DEFAULT_HEADING_TYPOGRAPHY,be as DEFAULT_HOVER_EFFECT,G as DEFAULT_SHADOW_COLOR,rt as DEFAULT_SIZES,s as DEFAULT_SURFACES,Pe as DEFAULT_SWITCH_SHOWN,Z as DEFAULT_THEMES,ke as DEFAULT_THEME_MODE,q as DEFAULT_THEME_VALUE,ze as GRADE_LABEL,gt as HEADING_CASES,ye as HEADING_COMPRESSIONS,Re as HEADING_MAX_PX_MAX,Me as HEADING_MAX_PX_MIN,I as HEADING_WEIGHT_MAX,C as HEADING_WEIGHT_MIN,Te as HOVER_EFFECTS,Ae as IDENTITY_CARD_GAP,F as IDENTITY_CARD_SHADOW,Ce as IDENTITY_HOVER_EFFECT,v as READABILITY_AA,ee as READABILITY_AA_LARGE,nt as SCALE_OF_STEP,y as SITE_THEME_KEY,k as SIZE_STEPS,ue as TEXT_SIZE_MAX,ae as TEXT_SIZE_MIN,R as THEME_DAY_END_HOUR,M as THEME_DAY_START_HOUR,Ne as THEME_MODE_KEY,j as THEME_STORAGE_KEY,Qe as THEME_SURFACE_KEYS,Le as THEME_SWITCH_HIDE,Oe as THEME_SWITCH_KEY,se as TYPE_GROUPS,et as TYPE_GROUP_LABELS,d as accentInk,qe as bandPresetFor,Je as bandPresetIndex,Ue as brandTheme,Fe as buildThemeBootScript,ut as cardGapAttr,at as cardShadowAttr,dt as compressionMetrics,X as contrastRatio,$ as cornerRadiusTokens,ct as cornerStyleTokens,Xe as darkerAccents,Be as gradeContrast,ft as headingCompressionAttr,pt as headingTypographyFromRow,xt as headingTypographyStyle,_t as headingTypographyToRow,lt as hoverEffectAttr,V as isDayHour,Ie as normalizeCardGap,U as normalizeCardShadow,b as normalizeCornerRadius,ge as normalizeCornerStyle,B as normalizeHeadingCompression,w as normalizeHeadingTypography,Y as normalizeHoverEffect,we as normalizeShadowColor,le as normalizeSize,he as normalizeSizes,D as normalizeTheme,f as normalizeThemeColors,$e as resolveTheme,oe as resolvedButtonInk,L as sectionBandTone,u as selectedThemeColors,ht as shadowColorTokens,Ve as siteButtonPaint,it as siteButtonRadiusPx,st as siteCornerRadiusTokens,De as siteThemeMetadata,Et as siteThemeOf,Ke as themeAccentStyle,_ as themeButtonColour,H as themeButtonInk,je as themeButtonStyle,We as themeColorStyle,Ze as themePresetAccentVars,ve as themeSurfaceStyle,Ye as themeSwatchColors,tt as typeScaleGroupOfClassName,ot as typeSizesStyle};
|
|
18
|
+
`}const s={background:"#0a0a0a",surface:"#131313",line:"#2a2a2a",muted:"#9a9388"},J=[{text:"#2e2e2e",accent:"#2e2e2e",background:"#ffffff",surface:"#f7f7f7",line:"#e0e0e0",muted:"#5c5c5c"},{text:"#f7f7f7",accent:"#f7f7f7",background:"#0a0a0a",surface:"#1b1b1b",line:"#363636",muted:"#a3a3a3"},{text:"#ffffff",accent:"#ffffff",background:"#2e2e2e",surface:"#3d3d3d",line:"#545454",muted:"#b0b0b0"},{text:"#0a0a0a",accent:"#0a0a0a",background:"#f7f7f7",surface:"#ffffff",line:"#d9d9d9",muted:"#5c5c5c"}],Q={selected:0,themes:J};function D(e){return!e||!Array.isArray(e.themes)||e.themes.length===0?{...Q}:{selected:Math.min(Math.max(0,e.selected??0),e.themes.length-1),themes:e.themes}}function x(e,t,n){const r=h(e),o=h(t);if(r===null||o===null)return e;const c=(i,a)=>Math.max(0,Math.min(255,Math.round(i+(a-i)*n))).toString(16).padStart(2,"0");return`#${c(r.r,o.r)}${c(r.g,o.g)}${c(r.b,o.b)}`}const v={light:"#ffffff",dark:"#0a0a0a"},Ue=["light","dark"];function Ye(e,t){const n=v[t],r=t==="light"?"#ffffff":"#000000";return{text:n,accent:n,background:e,surface:x(e,r,.1),line:x(e,r,.22),muted:x(n,e,.35),brandInk:t}}function u(e){const t=D(e);return t.themes[t.selected]}function l(e){return{text:e.text,accent:e.accent,background:e.background||s.background,surface:e.surface||s.surface,line:e.line||s.line,muted:e.muted||s.muted}}function ze(e){return{fill:l(e).background,accent:e.accent}}const ee=.4,te=4.5,ne=3,Be={good:"Good","large-only":"Large text only",hard:"Hard to read"};function Xe(e){return e>=te?"good":e>=ne?"large-only":"hard"}const re=["#000000","#ffffff"];function d(e){return j(e,re)}const oe=[.25,.4,.55];function We(e){const t=h(e);return t===null?[]:oe.map(n=>"#"+[t.r,t.g,t.b].map(r=>Math.round(r*(1-n)).toString(16).padStart(2,"0")).join(""))}function Ke(e){const t=u(e),n={"--theme-fg":t.text},r=V(t.text);return(r===null||r>=ee)&&(n["--overlay-fg"]=t.text),n}const ce=82;function p(e){return`color-mix(in srgb, ${e} ${ce}%, #000)`}function je(e){const t=u(e);return{"--theme-accent":t.accent,"--theme-accent-2":p(t.accent),"--theme-accent-ink":d(t.accent)}}function _(e){const t=e?.button;return t&&f(t)===t.toLowerCase()?t.toLowerCase():null}function Ve(e){const t=u(e),n=_(t),r=H(t);if(n===null&&r===null)return{};const o={};return n!==null&&(o["--theme-btn"]=n,o["--theme-btn-2"]=p(n)),o["--theme-btn-ink"]=r??d(n),o}function H(e){const t=e?.buttonInk;return t&&f(t)===t.toLowerCase()?t.toLowerCase():null}function ie(e,t){return H(e)??d(_(e)??t)}function Ze(e){const t=u(e);return{fill:_(t)??t.accent.toLowerCase(),ink:ie(t,t.accent)}}function qe(e){const t={};return D(e).themes.forEach((n,r)=>{const o=l(n);t[`--theme-preset-${r}-accent`]=o.accent,t[`--theme-preset-${r}-accent-2`]=p(o.accent),t[`--theme-preset-${r}-accent-ink`]=d(o.accent),t[`--theme-preset-${r}-bg`]=o.background,t[`--theme-preset-${r}-fg`]=o.text,t[`--theme-preset-${r}-surface`]=o.surface,t[`--theme-preset-${r}-surface-2`]=`color-mix(in srgb, ${o.surface} 60%, ${o.line})`,t[`--theme-preset-${r}-line`]=o.line,t[`--theme-preset-${r}-muted`]=o.muted}),t}const E=e=>{const t=e/255;return t<=.04045?t/12.92:((t+.055)/1.055)**2.4},S=e=>255*(e<=.0031308?12.92*e:1.055*e**(1/2.4)-.055);function N([e,t,n]){const[r,o,c]=[E(e),E(t),E(n)],i=Math.cbrt(.4122214708*r+.5363325363*o+.0514459929*c),a=Math.cbrt(.2119034982*r+.6806995451*o+.1073969566*c),m=Math.cbrt(.0883024619*r+.2817188376*o+.6299787005*c);return[.2104542553*i+.793617785*a-.0040720468*m,1.9779984951*i-2.428592205*a+.4505937099*m,.0259040371*i+.7827717662*a-.808675766*m]}function se([e,t,n]){const r=(e+.3963377774*t+.2158037573*n)**3,o=(e-.1055613458*t-.0638541728*n)**3,c=(e-.0894841775*t-1.291485548*n)**3;return[S(4.0767416621*r-3.3077115913*o+.2309699292*c),S(-1.2684380046*r+2.6097574011*o-.3413193965*c),S(-.0041960863*r-.7034186147*o+1.707614701*c)]}const A=e=>{const t=h(e);return t===null?[0,0,0]:[t.r,t.g,t.b]},O=(e,t,n)=>[e[0]*n+t[0]*(1-n),e[1]*n+t[1]*(1-n),e[2]*n+t[2]*(1-n)],L=e=>`#${e.map(t=>Math.max(0,Math.min(255,Math.round(t))).toString(16).padStart(2,"0")).join("")}`,k=e=>O(A(e.surface),A(e.line),.6);function Je(e){return L(k(l(e)))}function P(e){const t=l(e);return L(se(O(N(k(t)),N(A(t.text)),.92)))}function Qe(e){return{...e,background:P(e)}}function ve(e,t){const n=e[t];if(!n)return-1;const r=P(n);return e.findIndex((o,c)=>c!==t&&f(o.background??"")===r)}const et=["--theme-bg","--theme-surface","--theme-surface-2","--theme-line","--theme-muted"];function tt(e){const t=l(u(e)),n=`color-mix(in srgb, ${t.surface} 60%, ${t.line})`,r={"--theme-bg":t.background,"--theme-surface":t.surface,"--theme-line":t.line,"--theme-muted":t.muted};return(t.surface!==s.surface||t.line!==s.line)&&(r["--theme-surface-2"]=n),r}const ae=["heading","body","label"],nt={heading:"Headings",body:"Body",label:"Labels"};function rt(e){if(!e)return null;for(const t of ae)if(e.includes(`--size-${t}`))return t;return/--size-heading(Large|Medium|Small)/.test(e)?"heading":null}const $=["headingLarge","headingMedium","headingSmall","accent","body","label"],ot={headingLarge:"heading",headingMedium:"heading",headingSmall:"heading",accent:"heading",body:"body",label:"label"},ct={headingLarge:null,headingMedium:null,headingSmall:null,accent:null,body:null,label:null},ue=8,le=200;function he(e){if(typeof e!="number"||!Number.isFinite(e))return null;const t=Math.round(e);return t>=ue&&t<=le?t:null}function fe(e){const t={};for(const n of $)t[n]=he(e?.[n]);return t}function it(e){const t=fe(e),n={};for(const r of $){const o=t[r];o!==null&&(n[`--size-${r}`]=`${o}px`)}return n}const de=["square","small","large"],ge="small";function me(e){return de.includes(e??"")?e:ge}function st(e){return G(pe[me(e)])}const T=0,xe=40,pe={square:0,small:null,large:16},F={"--sf-card-radius":1,"--sf-button-radius":.5,"--site-radius":.5,"--site-radius-xs":.25,"--site-radius-sm":.5,"--site-radius-md":.75,"--site-radius-lg":1,"--site-radius-xl":1.25,"--site-radius-2xl":1.5,"--site-radius-3xl":2,"--site-radius-4xl":2.5};function b(e){if(e==null||typeof e=="string"&&e.trim()==="")return null;const t=typeof e=="string"?Number(e):e;return Number.isFinite(t)?Math.min(xe,Math.max(T,Math.round(t))):null}function G(e){const t=b(e);return t===null?{}:Object.fromEntries(Object.entries(F).map(([n,r])=>{const o=t*r/16;return[n,o===0?"0":`${o}rem`]}))}function at(e){return(b(e)??T)*F["--sf-button-radius"]}function ut(e){return G(b(e)??T)}const _e=["none","soft","lifted"],Ee="soft",U="none",Se=["tight","normal","roomy"],Ae="normal",Te="normal",be=["none","lift","highlight"],Ce="lift",we="highlight",Y="#141416";function z(e){return _e.includes(e??"")?e:Ee}function Ie(e){return Se.includes(e??"")?e:Ae}function B(e){return be.includes(e??"")?e:Ce}function ye(e){return e&&f(e)===e.toLowerCase()?e.toLowerCase():Y}function lt(e){const t=z(e);return t===U?void 0:t}function ht(e){const t=Ie(e);return t===Te?void 0:t}function ft(e){const t=B(e);return t===we?void 0:t}function dt(e,t,n){const r=ye(t);return r===Y?{}:z(e)!==U||B(n)==="lift"?{"--sf-shadow-color":r}:{}}const Me=["normal","tight","compressed"],X="normal";function W(e){return Me.includes(e??"")?e:X}function gt(e){const t=W(e);return t===X?void 0:t}function mt(e){switch(W(e)){case"tight":return{lineHeight:.95,letterSpacing:-.01};case"compressed":return{lineHeight:.86,letterSpacing:-.01};default:return{}}}const xt=["authored","sentence"],pt={case:"authored",weight:null,weightStrong:null,italicStrong:null,maxPx:null,weight2:null,weight3:null,case2:"authored",case3:"authored"},C=100,w=900,Re=24,De=200;function g(e,t,n){return typeof e!="number"||!Number.isFinite(e)?null:Math.round(Math.min(Math.max(e,t),n))}function I(e){const t=g(e?.weight,C,w),n=e?.case==="sentence"?"sentence":"authored",r=c=>c==null?t:g(c,C,w),o=c=>c==="sentence"?"sentence":c==="authored"?"authored":n;return{case:n,weight:t,weightStrong:g(e?.weightStrong,C,w),italicStrong:typeof e?.italicStrong=="boolean"?e.italicStrong:null,maxPx:g(e?.maxPx,Re,De),weight2:r(e?.weight2),weight3:r(e?.weight3),case2:o(e?.case2),case3:o(e?.case3)}}function _t(e){const t=I(e),n={};return t.case==="sentence"&&(n["--sf-heading-case"]="none"),t.weight!==null&&(n["--sf-heading-weight"]=String(t.weight)),t.weightStrong!==null&&(n["--sf-heading-weight-strong"]=String(t.weightStrong)),t.maxPx!==null&&(n["--sf-heading-max"]=`${t.maxPx}px`),t.weight2!==null&&t.weight2!==t.weight&&(n["--sf-heading-2-weight"]=String(t.weight2)),t.weight3!==null&&t.weight3!==t.weight&&(n["--sf-heading-3-weight"]=String(t.weight3)),t.case2!==t.case&&(n["--sf-heading-2-case"]=t.case2==="sentence"?"none":"uppercase"),t.case3!==t.case&&(n["--sf-heading-3-case"]=t.case3==="sentence"?"none":"uppercase"),n}function Et(e){return I({case:e?.heading_case??void 0,weight:e?.heading_weight,weightStrong:e?.heading_weight_strong,italicStrong:e?.accent_italic,maxPx:e?.heading_max_px,weight2:e?.heading_2_weight??void 0,weight3:e?.heading_3_weight??void 0,case2:e?.heading_2_case??void 0,case3:e?.heading_3_case??void 0})}function St(e){const t=I(e);return{heading_case:t.case,heading_weight:t.weight,heading_weight_strong:t.weightStrong,heading_max_px:t.maxPx,heading_2_weight:t.weight2,heading_3_weight:t.weight3,heading_2_case:t.case2,heading_3_case:t.case3}}const y="siteTheme";function He(e){const t=e;if(!t||typeof t!="object"||!Array.isArray(t.themes)||!t.themes.every(r=>!!r&&typeof r=="object"))return{};const n=typeof t.selected=="number"&&Number.isInteger(t.selected)&&t.selected>=0?t.selected:0;return{[y]:{selected:n,themes:t.themes}}}function At(e){return He(e?.[y])[y]}export{oe as ACCENT_DARKEN_STEPS,Ue as BRAND_INKS,Se as CARD_GAPS,_e as CARD_SHADOWS,xe as CORNER_RADIUS_MAX,T as CORNER_RADIUS_MIN,de as CORNER_STYLES,pe as CORNER_STYLE_TO_PX,Ae as DEFAULT_CARD_GAP,Ee as DEFAULT_CARD_SHADOW,ge as DEFAULT_CORNER_STYLE,X as DEFAULT_HEADING_COMPRESSION,pt as DEFAULT_HEADING_TYPOGRAPHY,Ce as DEFAULT_HOVER_EFFECT,Y as DEFAULT_SHADOW_COLOR,ct as DEFAULT_SIZES,s as DEFAULT_SURFACES,$e as DEFAULT_SWITCH_SHOWN,J as DEFAULT_THEMES,Pe as DEFAULT_THEME_MODE,Q as DEFAULT_THEME_VALUE,Be as GRADE_LABEL,xt as HEADING_CASES,Me as HEADING_COMPRESSIONS,De as HEADING_MAX_PX_MAX,Re as HEADING_MAX_PX_MIN,w as HEADING_WEIGHT_MAX,C as HEADING_WEIGHT_MIN,be as HOVER_EFFECTS,Te as IDENTITY_CARD_GAP,U as IDENTITY_CARD_SHADOW,we as IDENTITY_HOVER_EFFECT,te as READABILITY_AA,ne as READABILITY_AA_LARGE,ot as SCALE_OF_STEP,y as SITE_THEME_KEY,$ as SIZE_STEPS,le as TEXT_SIZE_MAX,ue as TEXT_SIZE_MIN,R as THEME_DAY_END_HOUR,M as THEME_DAY_START_HOUR,Oe as THEME_MODE_KEY,Z as THEME_STORAGE_KEY,et as THEME_SURFACE_KEYS,ke as THEME_SWITCH_HIDE,Le as THEME_SWITCH_KEY,ae as TYPE_GROUPS,nt as TYPE_GROUP_LABELS,d as accentInk,Qe as bandPresetFor,ve as bandPresetIndex,Ye as brandTheme,Ge as buildThemeBootScript,ht as cardGapAttr,lt as cardShadowAttr,mt as compressionMetrics,K as contrastRatio,G as cornerRadiusTokens,st as cornerStyleTokens,We as darkerAccents,Xe as gradeContrast,gt as headingCompressionAttr,Et as headingTypographyFromRow,_t as headingTypographyStyle,St as headingTypographyToRow,ft as hoverEffectAttr,q as isDayHour,Ie as normalizeCardGap,z as normalizeCardShadow,b as normalizeCornerRadius,me as normalizeCornerStyle,W as normalizeHeadingCompression,I as normalizeHeadingTypography,B as normalizeHoverEffect,ye as normalizeShadowColor,he as normalizeSize,fe as normalizeSizes,D as normalizeTheme,l as normalizeThemeColors,Fe as resolveTheme,ie as resolvedButtonInk,P as sectionBandTone,u as selectedThemeColors,dt as shadowColorTokens,Ze as siteButtonPaint,at as siteButtonRadiusPx,ut as siteCornerRadiusTokens,He as siteThemeMetadata,At as siteThemeOf,Je as surfaceTwoTone,je as themeAccentStyle,_ as themeButtonColour,H as themeButtonInk,Ve as themeButtonStyle,Ke as themeColorStyle,qe as themePresetAccentVars,tt as themeSurfaceStyle,ze as themeSwatchColors,rt as typeScaleGroupOfClassName,it as typeSizesStyle};
|
|
@@ -9,7 +9,6 @@ export declare const WORD_STYLE_BY_KIND: Readonly<Record<string, WordStyleName>>
|
|
|
9
9
|
export declare const WORD_STYLE_ATTR = "data-sf-ws";
|
|
10
10
|
export declare const WORD_STYLE_COLOURS: readonly ["accent", "text", "labels"];
|
|
11
11
|
export type WordStyleColour = (typeof WORD_STYLE_COLOURS)[number];
|
|
12
|
-
export declare const WORD_STYLE_COLOUR_LABELS: Record<WordStyleColour, string>;
|
|
13
12
|
export declare const COLOUR_TOKEN: Record<WordStyleColour, string>;
|
|
14
13
|
export interface WordStyleValue {
|
|
15
14
|
font?: string | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{FONT_OPTIONS as a}from"./fonts.js";const i=["highlight","strong","quiet"],
|
|
1
|
+
import{FONT_OPTIONS as a}from"./fonts.js";const i=["highlight","strong","quiet"],G={highlight:"Highlight",strong:"Bold",quiet:"Quiet"},T={highlight:{kind:"wordHighlight",delimiter:"@@"},strong:{kind:"wordStrong",delimiter:"++"},quiet:{kind:"wordQuiet",delimiter:"^^"}},N=Object.fromEntries(i.map(t=>[T[t].kind,t])),Y="data-sf-ws",g=["accent","text","labels"],E={accent:"var(--accent)",text:"var(--fg)",labels:"var(--fg-dim)"},O=80,h=120,m=100,L=900,R=.5,w=3,W=-.1,y=.5,D=3,s={font:null,size:null,weight:null,bold:null,italic:null,lineGap:null,textGap:null,colour:null},f={highlight:{...s},strong:{...s},quiet:{...s}};function _(t,e,o){return typeof t!="number"||!Number.isFinite(t)?null:Math.round(Math.min(Math.max(t,e),o))}function p(t,e,o){if(typeof t!="number"||!Number.isFinite(t))return null;const l=10**D;return Math.round(Math.min(Math.max(t,e),o)*l)/l}function d(t){return typeof t=="boolean"?t:null}function S(t){const e=typeof t?.font=="string"&&a.some(l=>l.key===t.font)?t.font:null,o=typeof t?.colour=="string"&&g.includes(t.colour)?t.colour:null;return{font:e,size:_(t?.size,O,h),weight:_(t?.weight,m,L),bold:d(t?.bold),italic:d(t?.italic),lineGap:p(t?.lineGap,R,w),textGap:p(t?.textGap,W,y),colour:o}}function c(t){const e={};for(const o of i)e[o]=t&&o in t&&t[o]?S(t[o]):{...f[o]};return e}function I(t,e){const o=S(e),l=f[t];return Object.keys(l).every(n=>o[n]===l[n])}function M(t){const e=c(t),o={};for(const l of i){const n=e[l],r=`--sf-ws-${l}`;if(n.font){const u=a.find(x=>x.key===n.font);u&&(o[`${r}-font`]=`var(${u.cssVar})`)}n.size!==null&&(o[`${r}-size`]=`${n.size/100}em`),n.weight!==null&&(o[`${r}-weight`]=String(n.weight)),n.bold!==null&&(o[`${r}-weight-bold`]=n.bold?"700":"400"),n.italic!==null&&(o[`${r}-style`]=n.italic?"italic":"normal"),n.lineGap!==null&&(o[`${r}-line`]=String(n.lineGap)),n.textGap!==null&&(o[`${r}-track`]=`${n.textGap}em`),n.colour!==null&&(o[`${r}-color`]=E[n.colour])}return o}function A(t){const e=t?.word_styles??void 0,o={};for(const l of i)e&&l in e&&(o[l]=e[l]??null);return c(o)}function $(t){return{word_styles:c(t)}}export{E as COLOUR_TOKEN,f as DEFAULT_WORD_STYLES,i as WORD_STYLES,Y as WORD_STYLE_ATTR,N as WORD_STYLE_BY_KIND,g as WORD_STYLE_COLOURS,D as WORD_STYLE_GAP_PRECISION,G as WORD_STYLE_LABELS,w as WORD_STYLE_LINE_GAP_MAX,R as WORD_STYLE_LINE_GAP_MIN,T as WORD_STYLE_MARKS,h as WORD_STYLE_SIZE_MAX,O as WORD_STYLE_SIZE_MIN,y as WORD_STYLE_TEXT_GAP_MAX,W as WORD_STYLE_TEXT_GAP_MIN,L as WORD_STYLE_WEIGHT_MAX,m as WORD_STYLE_WEIGHT_MIN,S as normalizeWordStyle,c as normalizeWordStyles,I as wordStyleIsDefault,M as wordStyleTokens,A as wordStylesFromRow,$ as wordStylesToRow};
|
|
@@ -4,7 +4,8 @@ export interface BreadcrumbItem {
|
|
|
4
4
|
}
|
|
5
5
|
export interface BreadcrumbProps {
|
|
6
6
|
items?: BreadcrumbItem[];
|
|
7
|
+
current?: string;
|
|
7
8
|
meta?: string;
|
|
8
9
|
editing?: boolean;
|
|
9
10
|
}
|
|
10
|
-
export default function Breadcrumb({ items, meta, editing }: BreadcrumbProps): import("react").JSX.Element | null;
|
|
11
|
+
export default function Breadcrumb({ items, current, meta, editing }: BreadcrumbProps): import("react").JSX.Element | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as r,jsxs as s,Fragment as
|
|
1
|
+
import{jsx as r,jsxs as s,Fragment as f}from"react/jsx-runtime";import{Fragment as x}from"react";import{SiteLink as h}from"../lib/site-runtime.js";import{renderChrome as c,renderGold as b}from"./goldPhrases.js";import{say as g}from"../../format/lib/editor-words.js";function u({items:p,current:l,meta:t,editing:d=!1}){const i=(p??[]).filter(e=>e?.label?.trim()),m=l?.trim()?[...i,{label:l}]:i,a=m.length>0?m:d?[{label:g("Breadcrumb")}]:[];return a.length===0&&!t?null:r("nav",{className:"border-b border-line px-[var(--sf-site-gutter,40px)] py-6 font-mono text-[length:var(--size-label,13px)] uppercase tracking-[0.2em] text-fg-dim max-view-tablet:px-[min(20px,var(--sf-site-gutter,40px))] max-view-tablet:py-4",children:s("div",{className:"mx-auto flex max-w-[var(--sf-content-cap,none)] items-center gap-4",children:[a.map((e,n)=>{const o=n===a.length-1;return s(x,{children:[n>0&&r("span",{className:"opacity-40",children:"/"}),e.href&&!o?r(h,{href:e.href,className:"hover:text-fg",children:c(e.label)}):r("span",{className:o?"text-fg":void 0,children:c(e.label)})]},n)}),t&&s(f,{children:[r("span",{className:"opacity-40",children:"·"}),r("span",{children:b(t)})]})]})})}export{u as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as a}from"react/jsx-runtime";import{buttonArrowShown as L}from"../../format/lib/content/button-arrow.js";import{buttonIconAtEnd as N,buttonIconSide as
|
|
1
|
+
import{jsx as a}from"react/jsx-runtime";import{buttonArrowShown as L}from"../../format/lib/content/button-arrow.js";import{buttonIconAtEnd as N,buttonIconSide as j,buttonWidthClass as _,storedButtonIcon as v}from"../../format/lib/content/button-icon.js";import{buttonCornersStyle as F,buttonPadAttrs as O,buttonPaint as R}from"../lib/content/button-look.js";import{ArrowLongRightIcon as $,ArrowRightIcon as G,ArrowUpRightIcon as U,BagIcon as E,CarIcon as K,CartIcon as Y,ChevronRightIcon as z,DownloadIcon as D,EmailIcon as H,ExternalIcon as J,LocationIcon as W,PlayIcon as q,SearchIcon as M,TagIcon as Q}from"efficient-shell/icons/efficient";import V from"./BlockFrame.js";import X from"./Btn.js";import{renderGold as Z}from"./goldPhrases.js";import{alignPhoneClass as b,BLOCK_ALIGN_JUSTIFY as oo}from"../../format/lib/content/block-align.js";const to="sf-button-block",no={"arrow-right":G,"arrow-long-right":$,"arrow-up-right":U,"chevron-right":z,external:J,cart:Y,bag:E,tag:Q,email:H,location:W,play:q,download:D,search:M,car:K};function ro(o){const{label:p,href:c,variant:i,align:t,alignPhone:l,contained:I,arrow:C,icon:y,iconPosition:s,widthFit:d,widthFitPhone:B,widthFitTablet:P,buttonColor:n,buttonTextColor:h,hrefRewrite:m}=o,r=v(y),u=r&&r!=="none"?no[r]:void 0,x=r===void 0?L(C)?{}:{arrow:null}:u?{arrow:a(u,{size:16}),...j(s)==="before"?{glyphBefore:!0}:{}}:{arrow:null},f=O(o),g=[_(d,B,P),f?.className??""].filter(Boolean).join(" "),A=g?{className:g}:{},S=N(s,d)?{spread:!0}:{},e=R(o),T=e?e.background==="transparent"?"ghost":"primary":i,w={...e??(n?i==="ghost"?{borderColor:n}:{background:n,borderColor:n}:{}),...h?{color:h}:{},...f?.style??{},...F(o)??{}},k=Object.keys(w).length?{style:w}:{};return a(V,{contained:I,className:`${to} py-4`,children:a("div",{className:`flex${t?` ${oo[t]}`:""}${b("justify",t,l)?` ${b("justify",t,l)}`:""}`,children:a(X,{href:c||"#",variant:T,...A,...S,...x,...k,...c&&m?{hrefRewrite:m}:{},children:Z(p)})})})}export{to as BUTTON_BLOCK_CLASS,ro as default};
|
|
@@ -1,19 +1,22 @@
|
|
|
1
1
|
import { type ReactNode } from "react";
|
|
2
2
|
import type { SlotComponent } from "efficient-easel/blocks";
|
|
3
|
+
import { type CardRowState } from "../../format/lib/content/card-state.js";
|
|
3
4
|
import type { SourceRow } from "../../format/lib/content/block-sources.js";
|
|
5
|
+
export type { CardRowState } from "../../format/lib/content/card-state.js";
|
|
4
6
|
export type CardRow = {
|
|
5
7
|
row: SourceRow;
|
|
6
8
|
index: number;
|
|
7
9
|
ownerType?: string;
|
|
8
10
|
item?: unknown;
|
|
9
11
|
nested?: boolean;
|
|
12
|
+
state?: CardRowState;
|
|
10
13
|
};
|
|
11
14
|
export declare const CardRowContext: import("react").Context<CardRow | null>;
|
|
12
15
|
export declare function useCardRow(): CardRow | null;
|
|
13
16
|
export declare function CardRowDrawn({ type, props, children, }: {
|
|
14
17
|
type: string;
|
|
15
18
|
props: Record<string, unknown>;
|
|
16
|
-
children: (drawn: Record<string, unknown>, at: CardRow | null) => ReactNode;
|
|
19
|
+
children: (drawn: Record<string, unknown>, at: CardRow | null, row: SourceRow | null) => ReactNode;
|
|
17
20
|
}): import("react").JSX.Element;
|
|
18
21
|
type CardTemplateRowsProps = {
|
|
19
22
|
ownerId: string;
|
|
@@ -21,9 +24,9 @@ type CardTemplateRowsProps = {
|
|
|
21
24
|
Template: SlotComponent | undefined;
|
|
22
25
|
rows: readonly SourceRow[];
|
|
23
26
|
items?: readonly unknown[];
|
|
27
|
+
states?: readonly (CardRowState | undefined)[];
|
|
24
28
|
fallback: ReactNode;
|
|
25
29
|
wrapCopy?: (copy: ReactNode, row: CardRow) => ReactNode;
|
|
26
30
|
children: (cards: ReactNode) => ReactNode;
|
|
27
31
|
};
|
|
28
|
-
export declare function CardTemplateRows({ ownerId, ownerType, Template, rows, items, fallback, wrapCopy, children }: CardTemplateRowsProps): import("react").JSX.Element;
|
|
29
|
-
export {};
|
|
32
|
+
export declare function CardTemplateRows({ ownerId, ownerType, Template, rows, items, states, fallback, wrapCopy, children }: CardTemplateRowsProps): import("react").JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{Fragment as
|
|
1
|
+
"use client";import{Fragment as c,jsx as r,jsxs as w}from"react/jsx-runtime";import{createContext as h,useContext as l}from"react";import{REPEAT_ATTRIBUTE as x,REPEAT_INDEX_ATTRIBUTE as P}from"efficient-easel/draw";import{CARD_TEMPLATE_SLOT as S,rowFilledProps as g}from"../../format/lib/content/card-template.js";import{CARD_STATE_LINE_CLASS as j,cardStateAttrs as D,cardStateValue as I}from"../../format/lib/content/card-state.js";import{usePageRecordRow as L}from"./CurrentRecord.js";const a=h(null);function b(){return l(a)}function k({type:u,props:i,children:t}){const e=l(a),d=L(),n=e?.row??d;return r(c,{children:t(g(u,i,n),e,n)})}function M({ownerId:u,ownerType:i,Template:t,rows:e,items:d,states:n,fallback:E,wrapCopy:m,children:T}){const _=l(a);if(!t||(t.blockCount??0)<=0)return r(c,{children:E});const f=_!==null,A=e.map((C,o)=>{const s=n?.[o],R={row:C,index:o,ownerType:i,item:d?.[o],nested:f,...s?{state:s}:null},p=r("div",{[x]:`${u}:${S}`,[P]:o,...D(s),children:I(s)?w(c,{children:[r(t,{}),r("span",{"aria-hidden":"true",className:j})]}):r(t,{})});return r(a.Provider,{value:R,children:m?m(p,R):p},o)});return r(c,{children:T(A)})}export{a as CardRowContext,k as CardRowDrawn,M as CardTemplateRows,b as useCardRow};
|
|
@@ -1,14 +1,17 @@
|
|
|
1
|
+
import { type ListNumberForm } from "../../format/lib/content/list-number.js";
|
|
1
2
|
import type { PartStyles } from "../lib/document/part-styles.js";
|
|
2
3
|
export interface ContentsEntry {
|
|
3
4
|
label: string;
|
|
4
5
|
anchor: string;
|
|
5
6
|
}
|
|
6
7
|
export declare const CONTENTS_STICKY_TOP = 120;
|
|
7
|
-
export default function ContentsList({ title, entries, stickyTop, sticky, editing, partStyles, }: {
|
|
8
|
+
export default function ContentsList({ title, entries, stickyTop, sticky, editing, partStyles, numberForm, hideClass, }: {
|
|
8
9
|
title?: string;
|
|
9
10
|
entries: readonly ContentsEntry[];
|
|
10
11
|
stickyTop: number;
|
|
11
12
|
sticky?: boolean;
|
|
12
13
|
editing?: boolean;
|
|
13
14
|
partStyles?: PartStyles;
|
|
15
|
+
numberForm?: ListNumberForm;
|
|
16
|
+
hideClass?: string;
|
|
14
17
|
}): import("react").JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as
|
|
1
|
+
import{jsx as s,jsxs as f}from"react/jsx-runtime";import{renderGold as x}from"./goldPhrases.js";import{LIST_NUMBER_FORM_DEFAULT as b,listNumberIn as d}from"../../format/lib/content/list-number.js";import{STICKY_ASIDE_TOP as N}from"../../format/lib/content/sticky-aside.js";import{SIZE_STEP_OF_ROLE as h}from"../../format/lib/fonts.js";import{CONTENTS_REGIONS as E}from"../../format/lib/sections/contents-text-regions.js";import{TEXT_REGION_ATTR as S,regionStyle as g,textRegionPartKey as y}from"../../format/lib/sections/text-regions.js";const u=(e,t)=>e?{[S]:t}:{},T=(e,t)=>g(e?.[y(t)]?.role,E[t],h),v=N;function O({title:e,entries:t,stickyTop:_,sticky:a=!0,editing:l=!1,partStyles:c,numberForm:m=b,hideClass:i=""}){const r=m==="plain";return f("aside",{className:`${a?"sticky ":""}flex flex-col self-start max-[900px]:static${i?` ${i}`:""}`,style:a?{top:_}:void 0,children:[e&&s("h4",{className:"mb-[18px] font-mono text-[length:var(--size-label,12px)] uppercase tracking-[0.3em] text-accent",children:x(e)}),t.map((n,o)=>{const p=s("span",{...u(l,"number"),style:T(c,"number"),className:"text-accent",children:d(m,o)});return f("a",{href:`#${n.anchor}`,className:`flex items-center ${r?"justify-start gap-1":"justify-between gap-3"} border-b border-line py-2.5 font-mono text-[length:var(--size-label,13px)] uppercase tracking-[0.18em] text-fg-dim transition-colors hover:text-fg${o===0?" border-t":""}`,children:[r&&p,s("span",{...u(l,"entry"),style:T(c,"entry"),children:x(n.label||"Section")}),!r&&p]},`${o}-${n.anchor}`)})]})}export{v as CONTENTS_STICKY_TOP,O as default};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { type ReactNode } from "react";
|
|
2
|
+
import type { SourceRow } from "../../format/lib/content/block-sources.js";
|
|
3
|
+
export interface RecordSchemaField {
|
|
4
|
+
key: string;
|
|
5
|
+
label: string;
|
|
6
|
+
kind: string;
|
|
7
|
+
}
|
|
8
|
+
export interface CurrentRecord<TValue = unknown> {
|
|
9
|
+
type: string;
|
|
10
|
+
key: string;
|
|
11
|
+
title: string;
|
|
12
|
+
fields: Readonly<Record<string, unknown>>;
|
|
13
|
+
value: TValue;
|
|
14
|
+
schema?: readonly RecordSchemaField[];
|
|
15
|
+
}
|
|
16
|
+
export declare function CurrentRecordProvider({ record, dateWords, children, }: {
|
|
17
|
+
record: CurrentRecord;
|
|
18
|
+
dateWords?: (iso: string) => string;
|
|
19
|
+
children: ReactNode;
|
|
20
|
+
}): import("react").JSX.Element;
|
|
21
|
+
export declare function useCurrentRecord(): CurrentRecord | null;
|
|
22
|
+
export declare function useCurrentRecordOf<TValue = unknown>(type: string): CurrentRecord<TValue> | null;
|
|
23
|
+
export declare function usePageRecordRow(): SourceRow | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{jsx as l}from"react/jsx-runtime";import{createContext as d,useContext as t,useMemo as n}from"react";import{recordRow as s}from"../../format/lib/content/record-row.js";import{PRODUCT_RECORD_TYPE as i}from"../../format/lib/content/record-types.js";const o=d(null);function C({record:r,dateWords:e,children:u}){const c=n(()=>({record:r,dateWords:e}),[r,e]);return l(o.Provider,{value:c,children:u})}function p(){return t(o)?.record??null}function P(r){const e=p();return e!==null&&e.type===r?e:null}function a(){const r=t(o);return n(()=>r&&r.record.type!==i?s(r.record,r.dateWords):null,[r])}export{C as CurrentRecordProvider,p as useCurrentRecord,P as useCurrentRecordOf,a as usePageRecordRow};
|
|
@@ -9,6 +9,7 @@ type AlignItems = "start" | "center" | "end" | "stretch";
|
|
|
9
9
|
interface FlexProps {
|
|
10
10
|
padV2?: boolean;
|
|
11
11
|
border?: unknown;
|
|
12
|
+
borderTablet?: unknown;
|
|
12
13
|
borderPhone?: unknown;
|
|
13
14
|
direction: Direction;
|
|
14
15
|
label?: string;
|
|
@@ -19,7 +20,7 @@ interface FlexProps {
|
|
|
19
20
|
justify: Justify;
|
|
20
21
|
align: AlignItems;
|
|
21
22
|
wrap: boolean;
|
|
22
|
-
share?:
|
|
23
|
+
share?: unknown;
|
|
23
24
|
sharePhone?: string;
|
|
24
25
|
shareTablet?: unknown;
|
|
25
26
|
wrapPhone?: unknown;
|
|
@@ -60,5 +61,5 @@ interface FlexProps {
|
|
|
60
61
|
mirrorCards?: unknown;
|
|
61
62
|
content: SlotComponent;
|
|
62
63
|
}
|
|
63
|
-
export default function Flex({ direction, label, tabShape, gap, gapPhone, gapTablet, justify, align, wrap, share, sharePhone, shareTablet, wrapPhone, phoneRow, columns, columnsTablet, separator, blockSpacing, bgImage, bgImagePhone, pictureHover, darken, darkenStyle, placement, padV2, border, borderPhone, pad, contained, fillHeight, shadow, loop, scrollDirection, loopSeconds, loopDelay, editing, fillColor, line, upcoming, link, boxShape, boxShapePhone, boxShapeTablet, jumpHighlight, anchor, sharedSides, boxId, mirrorCards, content: Content, }: FlexProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null | undefined;
|
|
64
|
+
export default function Flex({ direction, label, tabShape, gap, gapPhone, gapTablet, justify, align, wrap, share, sharePhone, shareTablet, wrapPhone, phoneRow, columns, columnsTablet, separator, blockSpacing, bgImage, bgImagePhone, pictureHover, darken, darkenStyle, placement, padV2, border, borderTablet, borderPhone, pad, contained, fillHeight, shadow, loop, scrollDirection, loopSeconds, loopDelay, editing, fillColor, line, upcoming, link, boxShape, boxShapePhone, boxShapeTablet, jumpHighlight, anchor, sharedSides, boxId, mirrorCards, content: Content, }: FlexProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null | undefined;
|
|
64
65
|
export {};
|