@webority/mobile-ui 0.111.0 → 0.113.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/dist/canvas-kit/kit.js +1941 -1726
- package/dist/canvas-kit/manifest.json +47 -62
- package/dist/canvas-kit/release.json +6 -6
- package/lib/commonjs/components/Banner/Banner.js +1 -1
- package/lib/commonjs/components/ForceUpdateDialog/ForceUpdateDialog.js +1 -1
- package/lib/commonjs/components/KeyboardAwareScrollView/KeyboardAwareScrollView.js +1 -1
- package/lib/commonjs/components/Markdown/Markdown.js +1 -1
- package/lib/commonjs/components/MessageBubble/MessageBubble.js +1 -1
- package/lib/commonjs/components/NumberInput/NumberInput.js +1 -1
- package/lib/commonjs/components/Screen/Screen.js +1 -1
- package/lib/commonjs/components/SegmentedControl/SegmentedControl.js +1 -1
- package/lib/commonjs/components/Skeleton/Skeleton.js +1 -1
- package/lib/commonjs/components/Skeleton/SkeletonContent.js +1 -1
- package/lib/commonjs/components/Skeleton/SkeletonList.js +1 -1
- package/lib/commonjs/components/SortableList/SortableList.js +1 -1
- package/lib/commonjs/theme/tokens.generated.js +1 -1
- package/lib/module/components/Banner/Banner.js +1 -1
- package/lib/module/components/ForceUpdateDialog/ForceUpdateDialog.js +1 -1
- package/lib/module/components/KeyboardAwareScrollView/KeyboardAwareScrollView.js +1 -1
- package/lib/module/components/Markdown/Markdown.js +1 -1
- package/lib/module/components/MessageBubble/MessageBubble.js +1 -1
- package/lib/module/components/NumberInput/NumberInput.js +1 -1
- package/lib/module/components/Screen/Screen.js +1 -1
- package/lib/module/components/SegmentedControl/SegmentedControl.js +1 -1
- package/lib/module/components/Skeleton/Skeleton.js +1 -1
- package/lib/module/components/Skeleton/SkeletonContent.js +1 -1
- package/lib/module/components/Skeleton/SkeletonList.js +1 -1
- package/lib/module/components/SortableList/SortableList.js +1 -1
- package/lib/module/theme/tokens.generated.js +1 -1
- package/lib/typescript/commonjs/components/ForceUpdateDialog/ForceUpdateDialog.d.ts +2 -0
- package/lib/typescript/commonjs/components/KeyboardAwareScrollView/KeyboardAwareScrollView.d.ts +6 -4
- package/lib/typescript/commonjs/components/Markdown/Markdown.d.ts +17 -10
- package/lib/typescript/commonjs/components/NumberInput/NumberInput.d.ts +1 -1
- package/lib/typescript/commonjs/components/RichTextEditor/markdownActions.d.ts +2 -2
- package/lib/typescript/commonjs/components/Screen/Screen.d.ts +11 -1
- package/lib/typescript/commonjs/components/Skeleton/Skeleton.d.ts +0 -2
- package/lib/typescript/commonjs/components/Skeleton/SkeletonContent.d.ts +1 -3
- package/lib/typescript/commonjs/components/Skeleton/SkeletonList.d.ts +1 -3
- package/lib/typescript/commonjs/theme/tokens.generated.d.ts +6 -0
- package/lib/typescript/module/components/ForceUpdateDialog/ForceUpdateDialog.d.ts +2 -0
- package/lib/typescript/module/components/KeyboardAwareScrollView/KeyboardAwareScrollView.d.ts +6 -4
- package/lib/typescript/module/components/Markdown/Markdown.d.ts +17 -10
- package/lib/typescript/module/components/NumberInput/NumberInput.d.ts +1 -1
- package/lib/typescript/module/components/RichTextEditor/markdownActions.d.ts +2 -2
- package/lib/typescript/module/components/Screen/Screen.d.ts +11 -1
- package/lib/typescript/module/components/Skeleton/Skeleton.d.ts +0 -2
- package/lib/typescript/module/components/Skeleton/SkeletonContent.d.ts +1 -3
- package/lib/typescript/module/components/Skeleton/SkeletonList.d.ts +1 -3
- package/lib/typescript/module/theme/tokens.generated.d.ts +6 -0
- package/package.json +9 -6
- package/lib/commonjs/components/Markdown/parse.js +0 -1
- package/lib/module/components/Markdown/parse.js +0 -1
- package/lib/typescript/commonjs/components/Markdown/parse.d.ts +0 -63
- package/lib/typescript/module/components/Markdown/parse.d.ts +0 -63
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";export const COLOR_NAMES=["bg","bg-subtle","bg-muted","surface","surface-inverse","surface-dark","surface-dark-border","on-surface-dark","on-surface-dark-muted","text","text-body","text-muted","text-subtle","text-inverse","link","border","border-subtle","field-bg","field-border","field-border-focus","focus-ring","scrim","on-scrim","thumb","primary","primary-hover","primary-soft","primary-text","on-primary","primary-wash","primary-wash-strong","neutral","neutral-hover","neutral-text","on-neutral","success","success-soft","success-text","on-success","warning","warning-soft","warning-text","on-warning","danger","danger-soft","danger-border","danger-text","on-danger","info","info-soft","info-text","on-info","primary-pressed","on-neutral-strong","text-disabled","surface-pressed","surface-hover","surface-selected","surface-disabled","skeleton","skeleton-highlight","glass-fill","glass-border","on-glass","glass-badge","field-bg-focus","field-bg-disabled","field-border-error","field-label","field-text","field-text-disabled","field-placeholder","field-placeholder-disabled","field-icon","field-icon-focus","field-icon-disabled","field-caret","field-message","avatar-1","avatar-2","avatar-3","avatar-4","avatar-5","avatar-6","avatar-7","avatar-8"];export const SPACE_NAMES=["none","xxs","xs","sm","md","lg","xl","2xl","3xl","4xl"];export const RADIUS_NAMES=["none","sm","md","lg","xl","pill"];export const TEXT_NAMES=["xs","sm","base","lg","xl","2xl","3xl","4xl","5xl","6xl","7xl","8xl"];export const WEIGHT_NAMES=["normal","medium","semibold","bold"];export const LEADING_NAMES=["heading","body","display"];export const LETTER_SPACING_NAMES=["tight","normal","wide"];export const FONT_NAMES=["ui","display","mono"];export const SHADOW_NAMES=["card","elevated","popover","modal","drawer"];export const DURATION_NAMES=["instant","fast","default","slow","slower"];export const EASE_NAMES=["in-out","accelerate","decelerate","sharp"];export const SIZE_NAMES=["border"];export const COMPONENT_KINDS={field:{radius:"radius","padding-x":"space","padding-y":"space","min-height":"px",text:"text",icon:"px","label-text":"text","label-gap":"space","message-text":"text","message-gap":"space"},press:{opacity:"number"},disabled:{opacity:"number"},button:{"padding-x":"space","padding-y":"space","min-height":"px",text:"text",radius:"radius",icon:"px","badge-icon":"px"},input:{"multiline-min-height":"px"},"search-bar":{radius:"radius"},"empty-state":{icon:"px","illustration-size":"px","title-text":"text","description-text":"text","padding-y":"space","title-gap":"space","description-gap":"space"},"list-item":{"padding-y":"space","title-text":"text","subtitle-text":"text","min-height":"px"},badge:{text:"text","min-width":"px",height:"px","padding-x":"space","dot-size":"px","border-width":"px","anchor-offset":"px"},chip:{"padding-x":"space","padding-y":"space",text:"text","min-height":"px","close-size":"px","close-text":"text",gap:"space",icon:"px"},checkbox:{"box-size":"px","label-gap":"space"},radio:{outer:"px",inner:"px","label-gap":"space"},switch:{"track-width":"px","track-height":"px","thumb-size":"px",padding:"space"},"otp-input":{cell:"px",text:"text",radius:"radius",gap:"space"},"segmented-control":{height:"px",text:"text","padding-x":"space",icon:"px","track-padding":"space","underline-height":"px","pill-inset":"space"},tabs:{text:"text","padding-y":"space","padding-x":"space","scrollable-padding-x":"space",icon:"px","icon-gap":"space","track-padding":"space","underline-height":"px","pill-inset":"space","disabled-opacity":"number","badge-gap":"space"},slider:{"track-height":"px","thumb-diameter":"px"},"floating-action-button":{diameter:"px",icon:"px",text:"text","label-padding-x":"space","edge-offset":"space","bottom-offset":"space","secondary-gap":"space","stagger-ms":"ms"},dialog:{"icon-wrapper-size":"px","action-button-min-height":"px"},toast:{"icon-circle-size":"px","icon-glyph-text":"text","tint-bar-width":"px","action-min-height":"px"},banner:{"tint-bar-width":"px"}};export const lightTokens={mode:"light",colors:{bg:"#ffffff","bg-subtle":"#f8f8fb","bg-muted":"#f1f1f5",surface:"#ffffff","surface-inverse":"#0f0f1a","surface-dark":"#071437","surface-dark-border":"#2a3553","on-surface-dark":"#ffffff","on-surface-dark-muted":"#babdc7",text:"#252f4a","text-body":"#0f0f1a","text-muted":"#52525b","text-subtle":"#62626b","text-inverse":"#ffffff",link:"#5b5bd6",border:"#e5e5ec","border-subtle":"#efeff3","field-bg":"#f9fbfc","field-border":"#ebedf3","field-border-focus":"#bed2f9","focus-ring":"#5b5bd6",scrim:"#0f0f1a80","on-scrim":"#ffffff",thumb:"#ffffff",primary:"#5b5bd6","primary-hover":"#4f4fbf","primary-soft":"#eeeefc","primary-text":"#4f4fd3","on-primary":"#ffffff","primary-wash":"#5b5bd614","primary-wash-strong":"#5b5bd633",neutral:"#f4f4f8","neutral-hover":"#e9e9f0","neutral-text":"#52525b","on-neutral":"#0f0f1a",success:"#18864f","success-soft":"#e8faee","success-text":"#147042","on-success":"#ffffff",warning:"#f59e0b","warning-soft":"#fff8e6","warning-text":"#8f5c06","on-warning":"#0f0f1a",danger:"#e12c32","danger-soft":"#ffeaef","danger-border":"#e5484d","danger-text":"#bc1b20","on-danger":"#ffffff",info:"#1b6ef5","info-soft":"#e9f3ff","info-text":"#0958d9","on-info":"#ffffff","primary-pressed":"#4040a8","on-neutral-strong":"#ffffff","text-disabled":"#b4b4bb","surface-pressed":"#0f0f1a0f","surface-hover":"#0f0f1a0a","surface-selected":"#5b5bd61a","surface-disabled":"#f1f1f5",skeleton:"#ebedf3","skeleton-highlight":"#f5f6fa","glass-fill":"#ffffff47","glass-border":"#ffffff73","on-glass":"#0f0f1a","glass-badge":"#ffffff","field-bg-focus":"#ffffff","field-bg-disabled":"#f5f6fa","field-border-error":"#fdbfce","field-label":"#242f4a","field-text":"#252f4a","field-text-disabled":"#c4cada","field-placeholder":"#626d8b","field-placeholder-disabled":"#c4cada","field-icon":"#7a849f","field-icon-focus":"#4b5675","field-icon-disabled":"#c4cada","field-caret":"#5b8dee","field-message":"#d81736","avatar-1":"#5b5bd6","avatar-2":"#0a7979","avatar-3":"#a45a05","avatar-4":"#cd226e","avatar-5":"#2462eb","avatar-6":"#7c3aed","avatar-7":"#047c57","avatar-8":"#d42222"},space:{none:0,xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,"2xl":32,"3xl":48,"4xl":64},radius:{none:0,sm:6,md:10,lg:14,xl:20,pill:9999},text:{xs:{size:11},sm:{size:13},base:{size:15},lg:{size:17},xl:{size:20},"2xl":{size:24},"3xl":{size:30},"4xl":{size:36},"5xl":{size:45},"6xl":{size:57},"7xl":{size:64},"8xl":{size:72}},weight:{normal:"400",medium:"500",semibold:"600",bold:"700"},leading:{heading:1.2,body:1.4,display:1.2},"letter-spacing":{tight:-.2,normal:0,wide:.4},font:{ui:{},display:{},mono:{}},shadow:{card:{shadowColor:"#000000",shadowOffset:{width:0,height:2},shadowOpacity:.059,shadowRadius:4,elevation:2},elevated:{shadowColor:"#000000",shadowOffset:{width:0,height:4},shadowOpacity:.078,shadowRadius:8,elevation:4},popover:{shadowColor:"#000000",shadowOffset:{width:0,height:8},shadowOpacity:.102,shadowRadius:16,elevation:8},modal:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.141,shadowRadius:24,elevation:12},drawer:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.141,shadowRadius:24,elevation:12}},motion:{duration:{instant:80,fast:160,default:240,slow:360,slower:500},ease:{"in-out":[.4,0,.2,1],accelerate:[.4,0,1,1],decelerate:[0,0,.2,1],sharp:[.4,0,.6,1]}},size:{border:1},components:{field:{sm:{radius:"md","padding-x":"sm","padding-y":"sm","min-height":38,text:"sm",icon:14,"label-text":"xs","label-gap":"xs","message-text":"xs","message-gap":"xxs"},md:{radius:"md","padding-x":"md","padding-y":"md","min-height":44,text:"base",icon:16,"label-text":"sm","label-gap":"xs","message-text":"sm","message-gap":"xxs"},lg:{radius:"md","padding-x":"lg","padding-y":"lg","min-height":52,text:"lg",icon:18,"label-text":"base","label-gap":"xs","message-text":"base","message-gap":"xxs"}},press:{opacity:.85},disabled:{opacity:.55},button:{xs:{"padding-x":"sm","padding-y":"xs","min-height":28,text:"xs",radius:"md",icon:14,"badge-icon":11},sm:{"padding-x":"md","padding-y":"xs","min-height":34,text:"sm",radius:"md",icon:16,"badge-icon":16},md:{"padding-x":"lg","padding-y":"sm","min-height":44,text:"base",radius:"md",icon:18,"badge-icon":18},lg:{"padding-x":"xl","padding-y":"md","min-height":50,text:"lg",radius:"lg",icon:20,"badge-icon":20},xl:{"padding-x":"2xl","padding-y":"md","min-height":58,text:"xl",radius:"lg",icon:22,"badge-icon":22}},input:{sm:{"multiline-min-height":72},md:{"multiline-min-height":92},lg:{"multiline-min-height":110}},"search-bar":{sm:{radius:"pill"},md:{radius:"pill"},lg:{radius:"pill"}},"empty-state":{sm:{icon:48,"illustration-size":96,"title-text":"lg","description-text":"sm","padding-y":"lg","title-gap":"md","description-gap":"xs"},md:{icon:64,"illustration-size":160,"title-text":"xl","description-text":"base","padding-y":"xl","title-gap":"md","description-gap":"xs"},lg:{icon:80,"illustration-size":240,"title-text":"2xl","description-text":"lg","padding-y":"2xl","title-gap":"md","description-gap":"xs"}},"list-item":{sm:{"padding-y":"sm","title-text":"sm","subtitle-text":"xs","min-height":44},md:{"padding-y":"md","title-text":"base","subtitle-text":"sm","min-height":56},lg:{"padding-y":"lg","title-text":"lg","subtitle-text":"base","min-height":72}},badge:{sm:{text:"xs","min-width":16,height:16,"padding-x":"xs","dot-size":8},md:{text:"sm","min-width":20,height:20,"padding-x":"sm","dot-size":10},"border-width":1.5,"anchor-offset":4},chip:{sm:{"padding-x":"sm","padding-y":"xs",text:"xs","min-height":26,"close-size":16,"close-text":"xs",gap:"xs",icon:14},md:{"padding-x":"md","padding-y":"xs",text:"sm","min-height":32,"close-size":18,"close-text":"sm",gap:"sm",icon:16}},checkbox:{sm:{"box-size":16},md:{"box-size":20},lg:{"box-size":24},"label-gap":"sm"},radio:{sm:{outer:16,inner:8},md:{outer:20,inner:10},lg:{outer:24,inner:12},"label-gap":"sm"},switch:{sm:{"track-width":42,"track-height":26,"thumb-size":22,padding:"xxs"},md:{"track-width":51,"track-height":31,"thumb-size":27,padding:"xxs"},lg:{"track-width":60,"track-height":36,"thumb-size":32,padding:"xxs"}},"otp-input":{sm:{cell:36,text:"base",radius:"sm",gap:"sm"},md:{cell:48,text:"xl",radius:"md",gap:"sm"},lg:{cell:56,text:"2xl",radius:"lg",gap:"md"}},"segmented-control":{sm:{height:32,text:"sm","padding-x":"sm",icon:14},md:{height:40,text:"base","padding-x":"md",icon:16},lg:{height:48,text:"lg","padding-x":"lg",icon:18},"track-padding":"xs","underline-height":2,"pill-inset":"xs"},tabs:{sm:{text:"sm","padding-y":"sm","padding-x":"xs","scrollable-padding-x":"md",icon:16},md:{text:"base","padding-y":"md","padding-x":"sm","scrollable-padding-x":"lg",icon:18},lg:{text:"lg","padding-y":"lg","padding-x":"md","scrollable-padding-x":"xl",icon:20},"icon-gap":"xs","track-padding":"xs","underline-height":2,"pill-inset":"xs","disabled-opacity":.45,"badge-gap":"xs"},slider:{sm:{"track-height":4,"thumb-diameter":24},md:{"track-height":6,"thumb-diameter":28},lg:{"track-height":8,"thumb-diameter":32}},"floating-action-button":{sm:{diameter:40,icon:18,text:"sm","label-padding-x":"md"},md:{diameter:56,icon:22,text:"base","label-padding-x":"lg"},lg:{diameter:72,icon:28,text:"lg","label-padding-x":"xl"},"edge-offset":"xl","bottom-offset":"xl","secondary-gap":"lg","stagger-ms":50},dialog:{"icon-wrapper-size":48,"action-button-min-height":44},toast:{"icon-circle-size":28,"icon-glyph-text":"lg","tint-bar-width":0,"action-min-height":30},banner:{"tint-bar-width":0}}};export const darkTokens={mode:"dark",colors:{bg:"#0b0b12","bg-subtle":"#13131c","bg-muted":"#1c1c26",surface:"#1c1c26","surface-inverse":"#fafafa","surface-dark":"#071437","surface-dark-border":"#2a3553","on-surface-dark":"#ffffff","on-surface-dark-muted":"#babdc7",text:"#e2e2e2","text-body":"#fafafa","text-muted":"#b4b4bb","text-subtle":"#919199","text-inverse":"#0f0f1a",link:"#9292ee",border:"#27272f","border-subtle":"#1c1c26","field-bg":"#13131c","field-border":"#27272f","field-border-focus":"#3d5fb0","focus-ring":"#7c7ce8",scrim:"#000000a6","on-scrim":"#ffffff",thumb:"#ffffff",primary:"#7c7ce8","primary-hover":"#9292ee","primary-soft":"#1f1f3d","primary-text":"#8989ea","on-primary":"#0f0f1a","primary-wash":"#7c7ce814","primary-wash-strong":"#7c7ce833",neutral:"#1f1f26","neutral-hover":"#2a2a33","neutral-text":"#b4b4bb","on-neutral":"#fafafa",success:"#30c780","success-soft":"#04b4402e","success-text":"#30c780","on-success":"#0f0f1a",warning:"#fbbf24","warning-soft":"#dfa0002e","warning-text":"#fbbf24","on-warning":"#0f0f1a",danger:"#f87171","danger-soft":"#e826462e","danger-border":"#f87171","danger-text":"#f87171","on-danger":"#0f0f1a",info:"#60a5fa","info-soft":"#056ee92e","info-text":"#60a5fa","on-info":"#0f0f1a","primary-pressed":"#a8a8f2","on-neutral-strong":"#0f0f1a","text-disabled":"#52525b","surface-pressed":"#ffffff14","surface-hover":"#ffffff0d","surface-selected":"#7c7ce82e","surface-disabled":"#1c1c26",skeleton:"#1c1c26","skeleton-highlight":"#27272f","glass-fill":"#ffffff47","glass-border":"#ffffff73","on-glass":"#0f0f1a","glass-badge":"#ffffff","field-bg-focus":"#0b0b12","field-bg-disabled":"#1c1c26","field-border-error":"#8a2f42","field-label":"#e4e6ee","field-text":"#fafafa","field-text-disabled":"#52525b","field-placeholder":"#84848d","field-placeholder-disabled":"#52525b","field-icon":"#8b8b95","field-icon-focus":"#d4d4db","field-icon-disabled":"#52525b","field-caret":"#7c9ef0","field-message":"#f87171","avatar-1":"#8b8bee","avatar-2":"#2dd4bf","avatar-3":"#fcd34d","avatar-4":"#f472b6","avatar-5":"#60a5fa","avatar-6":"#a78bfa","avatar-7":"#34d399","avatar-8":"#f87171"},space:{none:0,xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,"2xl":32,"3xl":48,"4xl":64},radius:{none:0,sm:6,md:10,lg:14,xl:20,pill:9999},text:{xs:{size:11},sm:{size:13},base:{size:15},lg:{size:17},xl:{size:20},"2xl":{size:24},"3xl":{size:30},"4xl":{size:36},"5xl":{size:45},"6xl":{size:57},"7xl":{size:64},"8xl":{size:72}},weight:{normal:"400",medium:"500",semibold:"600",bold:"700"},leading:{heading:1.2,body:1.4,display:1.2},"letter-spacing":{tight:-.2,normal:0,wide:.4},font:{ui:{},display:{},mono:{}},shadow:{card:{shadowColor:"#000000",shadowOffset:{width:0,height:2},shadowOpacity:.4,shadowRadius:4,elevation:2},elevated:{shadowColor:"#000000",shadowOffset:{width:0,height:4},shadowOpacity:.502,shadowRadius:8,elevation:4},popover:{shadowColor:"#000000",shadowOffset:{width:0,height:8},shadowOpacity:.549,shadowRadius:16,elevation:8},modal:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.6,shadowRadius:24,elevation:12},drawer:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.6,shadowRadius:24,elevation:12}},motion:{duration:{instant:80,fast:160,default:240,slow:360,slower:500},ease:{"in-out":[.4,0,.2,1],accelerate:[.4,0,1,1],decelerate:[0,0,.2,1],sharp:[.4,0,.6,1]}},size:{border:1},components:{field:{sm:{radius:"md","padding-x":"sm","padding-y":"sm","min-height":38,text:"sm",icon:14,"label-text":"xs","label-gap":"xs","message-text":"xs","message-gap":"xxs"},md:{radius:"md","padding-x":"md","padding-y":"md","min-height":44,text:"base",icon:16,"label-text":"sm","label-gap":"xs","message-text":"sm","message-gap":"xxs"},lg:{radius:"md","padding-x":"lg","padding-y":"lg","min-height":52,text:"lg",icon:18,"label-text":"base","label-gap":"xs","message-text":"base","message-gap":"xxs"}},press:{opacity:.85},disabled:{opacity:.55},button:{xs:{"padding-x":"sm","padding-y":"xs","min-height":28,text:"xs",radius:"md",icon:14,"badge-icon":11},sm:{"padding-x":"md","padding-y":"xs","min-height":34,text:"sm",radius:"md",icon:16,"badge-icon":16},md:{"padding-x":"lg","padding-y":"sm","min-height":44,text:"base",radius:"md",icon:18,"badge-icon":18},lg:{"padding-x":"xl","padding-y":"md","min-height":50,text:"lg",radius:"lg",icon:20,"badge-icon":20},xl:{"padding-x":"2xl","padding-y":"md","min-height":58,text:"xl",radius:"lg",icon:22,"badge-icon":22}},input:{sm:{"multiline-min-height":72},md:{"multiline-min-height":92},lg:{"multiline-min-height":110}},"search-bar":{sm:{radius:"pill"},md:{radius:"pill"},lg:{radius:"pill"}},"empty-state":{sm:{icon:48,"illustration-size":96,"title-text":"lg","description-text":"sm","padding-y":"lg","title-gap":"md","description-gap":"xs"},md:{icon:64,"illustration-size":160,"title-text":"xl","description-text":"base","padding-y":"xl","title-gap":"md","description-gap":"xs"},lg:{icon:80,"illustration-size":240,"title-text":"2xl","description-text":"lg","padding-y":"2xl","title-gap":"md","description-gap":"xs"}},"list-item":{sm:{"padding-y":"sm","title-text":"sm","subtitle-text":"xs","min-height":44},md:{"padding-y":"md","title-text":"base","subtitle-text":"sm","min-height":56},lg:{"padding-y":"lg","title-text":"lg","subtitle-text":"base","min-height":72}},badge:{sm:{text:"xs","min-width":16,height:16,"padding-x":"xs","dot-size":8},md:{text:"sm","min-width":20,height:20,"padding-x":"sm","dot-size":10},"border-width":1.5,"anchor-offset":4},chip:{sm:{"padding-x":"sm","padding-y":"xs",text:"xs","min-height":26,"close-size":16,"close-text":"xs",gap:"xs",icon:14},md:{"padding-x":"md","padding-y":"xs",text:"sm","min-height":32,"close-size":18,"close-text":"sm",gap:"sm",icon:16}},checkbox:{sm:{"box-size":16},md:{"box-size":20},lg:{"box-size":24},"label-gap":"sm"},radio:{sm:{outer:16,inner:8},md:{outer:20,inner:10},lg:{outer:24,inner:12},"label-gap":"sm"},switch:{sm:{"track-width":42,"track-height":26,"thumb-size":22,padding:"xxs"},md:{"track-width":51,"track-height":31,"thumb-size":27,padding:"xxs"},lg:{"track-width":60,"track-height":36,"thumb-size":32,padding:"xxs"}},"otp-input":{sm:{cell:36,text:"base",radius:"sm",gap:"sm"},md:{cell:48,text:"xl",radius:"md",gap:"sm"},lg:{cell:56,text:"2xl",radius:"lg",gap:"md"}},"segmented-control":{sm:{height:32,text:"sm","padding-x":"sm",icon:14},md:{height:40,text:"base","padding-x":"md",icon:16},lg:{height:48,text:"lg","padding-x":"lg",icon:18},"track-padding":"xs","underline-height":2,"pill-inset":"xs"},tabs:{sm:{text:"sm","padding-y":"sm","padding-x":"xs","scrollable-padding-x":"md",icon:16},md:{text:"base","padding-y":"md","padding-x":"sm","scrollable-padding-x":"lg",icon:18},lg:{text:"lg","padding-y":"lg","padding-x":"md","scrollable-padding-x":"xl",icon:20},"icon-gap":"xs","track-padding":"xs","underline-height":2,"pill-inset":"xs","disabled-opacity":.45,"badge-gap":"xs"},slider:{sm:{"track-height":4,"thumb-diameter":24},md:{"track-height":6,"thumb-diameter":28},lg:{"track-height":8,"thumb-diameter":32}},"floating-action-button":{sm:{diameter:40,icon:18,text:"sm","label-padding-x":"md"},md:{diameter:56,icon:22,text:"base","label-padding-x":"lg"},lg:{diameter:72,icon:28,text:"lg","label-padding-x":"xl"},"edge-offset":"xl","bottom-offset":"xl","secondary-gap":"lg","stagger-ms":50},dialog:{"icon-wrapper-size":48,"action-button-min-height":44},toast:{"icon-circle-size":28,"icon-glyph-text":"lg","tint-bar-width":0,"action-min-height":30},banner:{"tint-bar-width":0}}};
|
|
1
|
+
"use strict";export const COLOR_NAMES=["bg","bg-subtle","bg-muted","surface","surface-inverse","surface-dark","surface-dark-border","on-surface-dark","on-surface-dark-muted","text","text-body","text-muted","text-subtle","text-inverse","link","border","border-subtle","field-bg","field-border","field-border-focus","focus-ring","scrim","on-scrim","thumb","primary","primary-hover","primary-soft","primary-text","on-primary","primary-wash","primary-wash-strong","neutral","neutral-hover","neutral-text","on-neutral","success","success-soft","success-text","on-success","warning","warning-soft","warning-text","on-warning","danger","danger-soft","danger-border","danger-text","on-danger","info","info-soft","info-text","on-info","primary-pressed","on-neutral-strong","text-disabled","surface-pressed","surface-hover","surface-selected","surface-disabled","skeleton","skeleton-highlight","glass-fill","glass-border","on-glass","glass-badge","field-bg-focus","field-bg-disabled","field-border-error","field-label","field-text","field-text-disabled","field-placeholder","field-placeholder-disabled","field-icon","field-icon-focus","field-icon-disabled","field-caret","field-message","avatar-1","avatar-2","avatar-3","avatar-4","avatar-5","avatar-6","avatar-7","avatar-8"];export const SPACE_NAMES=["none","xxs","xs","sm","md","lg","xl","2xl","3xl","4xl"];export const RADIUS_NAMES=["none","sm","md","lg","xl","pill"];export const TEXT_NAMES=["xs","sm","base","lg","xl","2xl","3xl","4xl","5xl","6xl","7xl","8xl"];export const WEIGHT_NAMES=["normal","medium","semibold","bold"];export const LEADING_NAMES=["heading","body","display"];export const LETTER_SPACING_NAMES=["tight","normal","wide"];export const FONT_NAMES=["ui","display","mono"];export const SHADOW_NAMES=["card","elevated","popover","modal","drawer"];export const DURATION_NAMES=["instant","fast","default","slow","slower"];export const EASE_NAMES=["in-out","accelerate","decelerate","sharp"];export const SIZE_NAMES=["border"];export const COMPONENT_KINDS={field:{radius:"radius","padding-x":"space","padding-y":"space","min-height":"px",text:"text",icon:"px","label-text":"text","label-gap":"space","message-text":"text","message-gap":"space"},press:{opacity:"number"},disabled:{opacity:"number"},button:{"padding-x":"space","padding-y":"space","min-height":"px",text:"text",radius:"radius",icon:"px","badge-icon":"px"},input:{"multiline-min-height":"px"},"search-bar":{radius:"radius"},"empty-state":{icon:"px","illustration-size":"px","title-text":"text","description-text":"text","padding-y":"space","title-gap":"space","description-gap":"space"},"list-item":{"padding-y":"space","title-text":"text","subtitle-text":"text","min-height":"px"},badge:{text:"text","min-width":"px",height:"px","padding-x":"space","dot-size":"px","border-width":"px","anchor-offset":"px"},chip:{"padding-x":"space","padding-y":"space",text:"text","min-height":"px","close-size":"px","close-text":"text",gap:"space",icon:"px"},checkbox:{"box-size":"px","label-gap":"space"},radio:{outer:"px",inner:"px","label-gap":"space"},switch:{"track-width":"px","track-height":"px","thumb-size":"px",padding:"space"},"otp-input":{cell:"px",text:"text",radius:"radius",gap:"space"},"segmented-control":{height:"px",text:"text","padding-x":"space",icon:"px","track-padding":"space","underline-height":"px","pill-inset":"space"},tabs:{text:"text","padding-y":"space","padding-x":"space","scrollable-padding-x":"space",icon:"px","icon-gap":"space","track-padding":"space","underline-height":"px","pill-inset":"space","disabled-opacity":"number","badge-gap":"space"},slider:{"track-height":"px","thumb-diameter":"px"},"floating-action-button":{diameter:"px",icon:"px",text:"text","label-padding-x":"space","edge-offset":"space","bottom-offset":"space","secondary-gap":"space","stagger-ms":"ms"},dialog:{"icon-wrapper-size":"px","action-button-min-height":"px"},toast:{"icon-circle-size":"px","icon-glyph-text":"text","tint-bar-width":"px","action-min-height":"px"},banner:{"tint-bar-width":"px"},screen:{gutter:"space"}};export const lightTokens={mode:"light",colors:{bg:"#ffffff","bg-subtle":"#f8f8fb","bg-muted":"#f1f1f5",surface:"#ffffff","surface-inverse":"#0f0f1a","surface-dark":"#071437","surface-dark-border":"#2a3553","on-surface-dark":"#ffffff","on-surface-dark-muted":"#babdc7",text:"#252f4a","text-body":"#0f0f1a","text-muted":"#52525b","text-subtle":"#62626b","text-inverse":"#ffffff",link:"#5b5bd6",border:"#e5e5ec","border-subtle":"#efeff3","field-bg":"#f9fbfc","field-border":"#ebedf3","field-border-focus":"#bed2f9","focus-ring":"#5b5bd6",scrim:"#0f0f1a80","on-scrim":"#ffffff",thumb:"#ffffff",primary:"#5b5bd6","primary-hover":"#4f4fbf","primary-soft":"#eeeefc","primary-text":"#4f4fd3","on-primary":"#ffffff","primary-wash":"#5b5bd614","primary-wash-strong":"#5b5bd633",neutral:"#f4f4f8","neutral-hover":"#e9e9f0","neutral-text":"#52525b","on-neutral":"#0f0f1a",success:"#18864f","success-soft":"#e8faee","success-text":"#147042","on-success":"#ffffff",warning:"#f59e0b","warning-soft":"#fff8e6","warning-text":"#8f5c06","on-warning":"#0f0f1a",danger:"#e12c32","danger-soft":"#ffeaef","danger-border":"#e5484d","danger-text":"#bc1b20","on-danger":"#ffffff",info:"#1b6ef5","info-soft":"#e9f3ff","info-text":"#0958d9","on-info":"#ffffff","primary-pressed":"#4040a8","on-neutral-strong":"#ffffff","text-disabled":"#b4b4bb","surface-pressed":"#0f0f1a0f","surface-hover":"#0f0f1a0a","surface-selected":"#5b5bd61a","surface-disabled":"#f1f1f5",skeleton:"#ebedf3","skeleton-highlight":"#f5f6fa","glass-fill":"#ffffff47","glass-border":"#ffffff73","on-glass":"#0f0f1a","glass-badge":"#ffffff","field-bg-focus":"#ffffff","field-bg-disabled":"#f5f6fa","field-border-error":"#fdbfce","field-label":"#242f4a","field-text":"#252f4a","field-text-disabled":"#7a8197","field-placeholder":"#626d8b","field-placeholder-disabled":"#7a8197","field-icon":"#7a849f","field-icon-focus":"#4b5675","field-icon-disabled":"#c4cada","field-caret":"#5b8dee","field-message":"#d81736","avatar-1":"#5b5bd6","avatar-2":"#0a7979","avatar-3":"#a45a05","avatar-4":"#cd226e","avatar-5":"#2462eb","avatar-6":"#7c3aed","avatar-7":"#047c57","avatar-8":"#d42222"},space:{none:0,xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,"2xl":32,"3xl":48,"4xl":64},radius:{none:0,sm:6,md:10,lg:14,xl:20,pill:9999},text:{xs:{size:11},sm:{size:13},base:{size:15},lg:{size:17},xl:{size:20},"2xl":{size:24},"3xl":{size:30},"4xl":{size:36},"5xl":{size:45},"6xl":{size:57},"7xl":{size:64},"8xl":{size:72}},weight:{normal:"400",medium:"500",semibold:"600",bold:"700"},leading:{heading:1.2,body:1.4,display:1.2},"letter-spacing":{tight:-.2,normal:0,wide:.4},font:{ui:{},display:{},mono:{}},shadow:{card:{shadowColor:"#000000",shadowOffset:{width:0,height:2},shadowOpacity:.059,shadowRadius:4,elevation:2},elevated:{shadowColor:"#000000",shadowOffset:{width:0,height:4},shadowOpacity:.078,shadowRadius:8,elevation:4},popover:{shadowColor:"#000000",shadowOffset:{width:0,height:8},shadowOpacity:.102,shadowRadius:16,elevation:8},modal:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.141,shadowRadius:24,elevation:12},drawer:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.141,shadowRadius:24,elevation:12}},motion:{duration:{instant:80,fast:160,default:240,slow:360,slower:500},ease:{"in-out":[.4,0,.2,1],accelerate:[.4,0,1,1],decelerate:[0,0,.2,1],sharp:[.4,0,.6,1]}},size:{border:1},components:{field:{sm:{radius:"md","padding-x":"sm","padding-y":"sm","min-height":38,text:"sm",icon:14,"label-text":"xs","label-gap":"xs","message-text":"xs","message-gap":"xxs"},md:{radius:"md","padding-x":"md","padding-y":"md","min-height":44,text:"base",icon:16,"label-text":"sm","label-gap":"xs","message-text":"sm","message-gap":"xxs"},lg:{radius:"md","padding-x":"lg","padding-y":"lg","min-height":52,text:"lg",icon:18,"label-text":"base","label-gap":"xs","message-text":"base","message-gap":"xxs"}},press:{opacity:.85},disabled:{opacity:.55},button:{xs:{"padding-x":"sm","padding-y":"xs","min-height":28,text:"xs",radius:"md",icon:14,"badge-icon":11},sm:{"padding-x":"md","padding-y":"xs","min-height":34,text:"sm",radius:"md",icon:16,"badge-icon":16},md:{"padding-x":"lg","padding-y":"sm","min-height":44,text:"base",radius:"md",icon:18,"badge-icon":18},lg:{"padding-x":"xl","padding-y":"md","min-height":50,text:"lg",radius:"lg",icon:20,"badge-icon":20},xl:{"padding-x":"2xl","padding-y":"md","min-height":58,text:"xl",radius:"lg",icon:22,"badge-icon":22}},input:{sm:{"multiline-min-height":72},md:{"multiline-min-height":92},lg:{"multiline-min-height":110}},"search-bar":{sm:{radius:"pill"},md:{radius:"pill"},lg:{radius:"pill"}},"empty-state":{sm:{icon:48,"illustration-size":96,"title-text":"lg","description-text":"sm","padding-y":"lg","title-gap":"md","description-gap":"xs"},md:{icon:64,"illustration-size":160,"title-text":"xl","description-text":"base","padding-y":"xl","title-gap":"md","description-gap":"xs"},lg:{icon:80,"illustration-size":240,"title-text":"2xl","description-text":"lg","padding-y":"2xl","title-gap":"md","description-gap":"xs"}},"list-item":{sm:{"padding-y":"sm","title-text":"sm","subtitle-text":"xs","min-height":44},md:{"padding-y":"md","title-text":"base","subtitle-text":"sm","min-height":56},lg:{"padding-y":"lg","title-text":"lg","subtitle-text":"base","min-height":72}},badge:{sm:{text:"xs","min-width":16,height:16,"padding-x":"xs","dot-size":8},md:{text:"sm","min-width":20,height:20,"padding-x":"sm","dot-size":10},"border-width":1.5,"anchor-offset":4},chip:{sm:{"padding-x":"sm","padding-y":"xs",text:"xs","min-height":26,"close-size":16,"close-text":"xs",gap:"xs",icon:14},md:{"padding-x":"md","padding-y":"xs",text:"sm","min-height":32,"close-size":18,"close-text":"sm",gap:"sm",icon:16}},checkbox:{sm:{"box-size":16},md:{"box-size":20},lg:{"box-size":24},"label-gap":"sm"},radio:{sm:{outer:16,inner:8},md:{outer:20,inner:10},lg:{outer:24,inner:12},"label-gap":"sm"},switch:{sm:{"track-width":42,"track-height":26,"thumb-size":22,padding:"xxs"},md:{"track-width":51,"track-height":31,"thumb-size":27,padding:"xxs"},lg:{"track-width":60,"track-height":36,"thumb-size":32,padding:"xxs"}},"otp-input":{sm:{cell:36,text:"base",radius:"sm",gap:"sm"},md:{cell:48,text:"xl",radius:"md",gap:"sm"},lg:{cell:56,text:"2xl",radius:"lg",gap:"md"}},"segmented-control":{sm:{height:32,text:"sm","padding-x":"sm",icon:14},md:{height:40,text:"base","padding-x":"md",icon:16},lg:{height:48,text:"lg","padding-x":"lg",icon:18},"track-padding":"xs","underline-height":2,"pill-inset":"xs"},tabs:{sm:{text:"sm","padding-y":"sm","padding-x":"xs","scrollable-padding-x":"md",icon:16},md:{text:"base","padding-y":"md","padding-x":"sm","scrollable-padding-x":"lg",icon:18},lg:{text:"lg","padding-y":"lg","padding-x":"md","scrollable-padding-x":"xl",icon:20},"icon-gap":"xs","track-padding":"xs","underline-height":2,"pill-inset":"xs","disabled-opacity":.45,"badge-gap":"xs"},slider:{sm:{"track-height":4,"thumb-diameter":24},md:{"track-height":6,"thumb-diameter":28},lg:{"track-height":8,"thumb-diameter":32}},"floating-action-button":{sm:{diameter:40,icon:18,text:"sm","label-padding-x":"md"},md:{diameter:56,icon:22,text:"base","label-padding-x":"lg"},lg:{diameter:72,icon:28,text:"lg","label-padding-x":"xl"},"edge-offset":"xl","bottom-offset":"xl","secondary-gap":"lg","stagger-ms":50},dialog:{"icon-wrapper-size":48,"action-button-min-height":44},toast:{"icon-circle-size":28,"icon-glyph-text":"lg","tint-bar-width":0,"action-min-height":30},banner:{"tint-bar-width":0},screen:{gutter:"lg"}}};export const darkTokens={mode:"dark",colors:{bg:"#0b0b12","bg-subtle":"#13131c","bg-muted":"#1c1c26",surface:"#1c1c26","surface-inverse":"#fafafa","surface-dark":"#071437","surface-dark-border":"#2a3553","on-surface-dark":"#ffffff","on-surface-dark-muted":"#babdc7",text:"#e2e2e2","text-body":"#fafafa","text-muted":"#b4b4bb","text-subtle":"#919199","text-inverse":"#0f0f1a",link:"#9292ee",border:"#27272f","border-subtle":"#1c1c26","field-bg":"#13131c","field-border":"#27272f","field-border-focus":"#3d5fb0","focus-ring":"#7c7ce8",scrim:"#000000a6","on-scrim":"#ffffff",thumb:"#ffffff",primary:"#7c7ce8","primary-hover":"#9292ee","primary-soft":"#1f1f3d","primary-text":"#8989ea","on-primary":"#0f0f1a","primary-wash":"#7c7ce814","primary-wash-strong":"#7c7ce833",neutral:"#1f1f26","neutral-hover":"#2a2a33","neutral-text":"#b4b4bb","on-neutral":"#fafafa",success:"#30c780","success-soft":"#04b4402e","success-text":"#30c780","on-success":"#0f0f1a",warning:"#fbbf24","warning-soft":"#dfa0002e","warning-text":"#fbbf24","on-warning":"#0f0f1a",danger:"#f87171","danger-soft":"#e826462e","danger-border":"#f87171","danger-text":"#f87171","on-danger":"#0f0f1a",info:"#60a5fa","info-soft":"#056ee92e","info-text":"#60a5fa","on-info":"#0f0f1a","primary-pressed":"#a8a8f2","on-neutral-strong":"#0f0f1a","text-disabled":"#52525b","surface-pressed":"#ffffff14","surface-hover":"#ffffff0d","surface-selected":"#7c7ce82e","surface-disabled":"#1c1c26",skeleton:"#1c1c26","skeleton-highlight":"#27272f","glass-fill":"#ffffff47","glass-border":"#ffffff73","on-glass":"#0f0f1a","glass-badge":"#ffffff","field-bg-focus":"#0b0b12","field-bg-disabled":"#1c1c26","field-border-error":"#8a2f42","field-label":"#e4e6ee","field-text":"#fafafa","field-text-disabled":"#71717a","field-placeholder":"#84848d","field-placeholder-disabled":"#71717a","field-icon":"#8b8b95","field-icon-focus":"#d4d4db","field-icon-disabled":"#52525b","field-caret":"#7c9ef0","field-message":"#f87171","avatar-1":"#8b8bee","avatar-2":"#2dd4bf","avatar-3":"#fcd34d","avatar-4":"#f472b6","avatar-5":"#60a5fa","avatar-6":"#a78bfa","avatar-7":"#34d399","avatar-8":"#f87171"},space:{none:0,xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,"2xl":32,"3xl":48,"4xl":64},radius:{none:0,sm:6,md:10,lg:14,xl:20,pill:9999},text:{xs:{size:11},sm:{size:13},base:{size:15},lg:{size:17},xl:{size:20},"2xl":{size:24},"3xl":{size:30},"4xl":{size:36},"5xl":{size:45},"6xl":{size:57},"7xl":{size:64},"8xl":{size:72}},weight:{normal:"400",medium:"500",semibold:"600",bold:"700"},leading:{heading:1.2,body:1.4,display:1.2},"letter-spacing":{tight:-.2,normal:0,wide:.4},font:{ui:{},display:{},mono:{}},shadow:{card:{shadowColor:"#000000",shadowOffset:{width:0,height:2},shadowOpacity:.4,shadowRadius:4,elevation:2},elevated:{shadowColor:"#000000",shadowOffset:{width:0,height:4},shadowOpacity:.502,shadowRadius:8,elevation:4},popover:{shadowColor:"#000000",shadowOffset:{width:0,height:8},shadowOpacity:.549,shadowRadius:16,elevation:8},modal:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.6,shadowRadius:24,elevation:12},drawer:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.6,shadowRadius:24,elevation:12}},motion:{duration:{instant:80,fast:160,default:240,slow:360,slower:500},ease:{"in-out":[.4,0,.2,1],accelerate:[.4,0,1,1],decelerate:[0,0,.2,1],sharp:[.4,0,.6,1]}},size:{border:1},components:{field:{sm:{radius:"md","padding-x":"sm","padding-y":"sm","min-height":38,text:"sm",icon:14,"label-text":"xs","label-gap":"xs","message-text":"xs","message-gap":"xxs"},md:{radius:"md","padding-x":"md","padding-y":"md","min-height":44,text:"base",icon:16,"label-text":"sm","label-gap":"xs","message-text":"sm","message-gap":"xxs"},lg:{radius:"md","padding-x":"lg","padding-y":"lg","min-height":52,text:"lg",icon:18,"label-text":"base","label-gap":"xs","message-text":"base","message-gap":"xxs"}},press:{opacity:.85},disabled:{opacity:.55},button:{xs:{"padding-x":"sm","padding-y":"xs","min-height":28,text:"xs",radius:"md",icon:14,"badge-icon":11},sm:{"padding-x":"md","padding-y":"xs","min-height":34,text:"sm",radius:"md",icon:16,"badge-icon":16},md:{"padding-x":"lg","padding-y":"sm","min-height":44,text:"base",radius:"md",icon:18,"badge-icon":18},lg:{"padding-x":"xl","padding-y":"md","min-height":50,text:"lg",radius:"lg",icon:20,"badge-icon":20},xl:{"padding-x":"2xl","padding-y":"md","min-height":58,text:"xl",radius:"lg",icon:22,"badge-icon":22}},input:{sm:{"multiline-min-height":72},md:{"multiline-min-height":92},lg:{"multiline-min-height":110}},"search-bar":{sm:{radius:"pill"},md:{radius:"pill"},lg:{radius:"pill"}},"empty-state":{sm:{icon:48,"illustration-size":96,"title-text":"lg","description-text":"sm","padding-y":"lg","title-gap":"md","description-gap":"xs"},md:{icon:64,"illustration-size":160,"title-text":"xl","description-text":"base","padding-y":"xl","title-gap":"md","description-gap":"xs"},lg:{icon:80,"illustration-size":240,"title-text":"2xl","description-text":"lg","padding-y":"2xl","title-gap":"md","description-gap":"xs"}},"list-item":{sm:{"padding-y":"sm","title-text":"sm","subtitle-text":"xs","min-height":44},md:{"padding-y":"md","title-text":"base","subtitle-text":"sm","min-height":56},lg:{"padding-y":"lg","title-text":"lg","subtitle-text":"base","min-height":72}},badge:{sm:{text:"xs","min-width":16,height:16,"padding-x":"xs","dot-size":8},md:{text:"sm","min-width":20,height:20,"padding-x":"sm","dot-size":10},"border-width":1.5,"anchor-offset":4},chip:{sm:{"padding-x":"sm","padding-y":"xs",text:"xs","min-height":26,"close-size":16,"close-text":"xs",gap:"xs",icon:14},md:{"padding-x":"md","padding-y":"xs",text:"sm","min-height":32,"close-size":18,"close-text":"sm",gap:"sm",icon:16}},checkbox:{sm:{"box-size":16},md:{"box-size":20},lg:{"box-size":24},"label-gap":"sm"},radio:{sm:{outer:16,inner:8},md:{outer:20,inner:10},lg:{outer:24,inner:12},"label-gap":"sm"},switch:{sm:{"track-width":42,"track-height":26,"thumb-size":22,padding:"xxs"},md:{"track-width":51,"track-height":31,"thumb-size":27,padding:"xxs"},lg:{"track-width":60,"track-height":36,"thumb-size":32,padding:"xxs"}},"otp-input":{sm:{cell:36,text:"base",radius:"sm",gap:"sm"},md:{cell:48,text:"xl",radius:"md",gap:"sm"},lg:{cell:56,text:"2xl",radius:"lg",gap:"md"}},"segmented-control":{sm:{height:32,text:"sm","padding-x":"sm",icon:14},md:{height:40,text:"base","padding-x":"md",icon:16},lg:{height:48,text:"lg","padding-x":"lg",icon:18},"track-padding":"xs","underline-height":2,"pill-inset":"xs"},tabs:{sm:{text:"sm","padding-y":"sm","padding-x":"xs","scrollable-padding-x":"md",icon:16},md:{text:"base","padding-y":"md","padding-x":"sm","scrollable-padding-x":"lg",icon:18},lg:{text:"lg","padding-y":"lg","padding-x":"md","scrollable-padding-x":"xl",icon:20},"icon-gap":"xs","track-padding":"xs","underline-height":2,"pill-inset":"xs","disabled-opacity":.45,"badge-gap":"xs"},slider:{sm:{"track-height":4,"thumb-diameter":24},md:{"track-height":6,"thumb-diameter":28},lg:{"track-height":8,"thumb-diameter":32}},"floating-action-button":{sm:{diameter:40,icon:18,text:"sm","label-padding-x":"md"},md:{diameter:56,icon:22,text:"base","label-padding-x":"lg"},lg:{diameter:72,icon:28,text:"lg","label-padding-x":"xl"},"edge-offset":"xl","bottom-offset":"xl","secondary-gap":"lg","stagger-ms":50},dialog:{"icon-wrapper-size":48,"action-button-min-height":44},toast:{"icon-circle-size":28,"icon-glyph-text":"lg","tint-bar-width":0,"action-min-height":30},banner:{"tint-bar-width":0},screen:{gutter:"lg"}}};
|
|
@@ -19,6 +19,8 @@ export interface ForceUpdateDialogProps {
|
|
|
19
19
|
mandatory?: boolean;
|
|
20
20
|
/** Optional override of the destination URL (defaults to the platform store). */
|
|
21
21
|
updateUrl?: string | null;
|
|
22
|
+
/** Address shown as a tappable link when the store cannot be opened. Nothing extra is shown without it. */
|
|
23
|
+
updateFallbackUrl?: string | null;
|
|
22
24
|
/** Per-call title override; wins over `labels.title`. */
|
|
23
25
|
title?: string;
|
|
24
26
|
/** Per-call message override; wins over `labels.message`. */
|
package/lib/typescript/commonjs/components/KeyboardAwareScrollView/KeyboardAwareScrollView.d.ts
CHANGED
|
@@ -12,7 +12,8 @@ export interface KeyboardAwareScrollViewProps extends ControllerScrollViewProps
|
|
|
12
12
|
/**
|
|
13
13
|
* A tap on empty space inside the content closes the keyboard and blurs the
|
|
14
14
|
* focused field. Taps that a field, button or any other pressable claims are
|
|
15
|
-
* left alone. Default false
|
|
15
|
+
* left alone. Default true; pass false for content that handles its own taps
|
|
16
|
+
* on empty space (a canvas, a map). Needed on Android edge-to-edge, where the
|
|
16
17
|
* ScrollView's own tap-out dismissal never fires because React Native sees no
|
|
17
18
|
* keyboard metrics.
|
|
18
19
|
*/
|
|
@@ -21,9 +22,10 @@ export interface KeyboardAwareScrollViewProps extends ControllerScrollViewProps
|
|
|
21
22
|
/**
|
|
22
23
|
* react-native-keyboard-controller's `KeyboardAwareScrollView` with the
|
|
23
24
|
* library's defaults: the focused field kept 24 above the keyboard, safe-area
|
|
24
|
-
* padding, a themed pull-to-refresh,
|
|
25
|
-
* keyboard open. The controller follows the keyboard
|
|
26
|
-
* thread, so nothing here listens to keyboard events.
|
|
25
|
+
* padding, a themed pull-to-refresh, a tap on empty space that closes the
|
|
26
|
+
* keyboard, and scrolls that keep it open. The controller follows the keyboard
|
|
27
|
+
* frame by frame on the UI thread, so nothing here listens to keyboard events.
|
|
28
|
+
* Needs the app's
|
|
27
29
|
* `KeyboardProvider` at the root.
|
|
28
30
|
*/
|
|
29
31
|
declare const KeyboardAwareScrollView: import("react").ForwardRefExoticComponent<KeyboardAwareScrollViewProps & import("react").RefAttributes<KeyboardAwareScrollViewRef>>;
|
|
@@ -1,9 +1,18 @@
|
|
|
1
|
+
import { type MarkdownHeadings, type MarkdownLinks } from "@webority/markdown-core";
|
|
1
2
|
import type React from "react";
|
|
2
3
|
import type { StyleProp, TextStyle, ViewStyle } from "react-native";
|
|
3
|
-
export interface MarkdownProps {
|
|
4
|
+
export interface MarkdownProps<T = string> {
|
|
4
5
|
/** The markdown source. An empty or missing string renders nothing. */
|
|
5
6
|
children?: string;
|
|
6
|
-
/**
|
|
7
|
+
/** `web` makes web and contact addresses pressable; `app` makes the links `resolveLink` maps pressable. Any other scheme is plain text. */
|
|
8
|
+
links?: MarkdownLinks;
|
|
9
|
+
/** `outline` sizes each heading by its level; `text` draws every heading as bold body text. */
|
|
10
|
+
headings?: MarkdownHeadings;
|
|
11
|
+
/** Maps an app link's address to what `onAppLinkPress` receives. Null leaves the link as plain text. */
|
|
12
|
+
resolveLink?: (href: string) => T | null | undefined;
|
|
13
|
+
/** Opens an app link. Without it, app links show as plain text. */
|
|
14
|
+
onAppLinkPress?: (target: T) => void;
|
|
15
|
+
/** Called instead of Linking.openURL when a web or contact link is pressed. */
|
|
7
16
|
onLinkPress?: (href: string) => void;
|
|
8
17
|
/**
|
|
9
18
|
* When true, renders the component as its authored skeleton placeholder shape.
|
|
@@ -17,13 +26,11 @@ export interface MarkdownProps {
|
|
|
17
26
|
testID?: string;
|
|
18
27
|
}
|
|
19
28
|
/**
|
|
20
|
-
* Renders
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* It exists because Expo has no markdown module and the alternative on npm has
|
|
24
|
-
* not shipped since 2022. What it covers is what our content contains: release
|
|
25
|
-
* notes, help text and descriptions written by people. Nested lists, tables and
|
|
26
|
-
* inline HTML are out of scope on purpose — see parse.ts.
|
|
29
|
+
* Renders the shared markdown grammar with the theme's own type scale and colours,
|
|
30
|
+
* with no dependency. Inline HTML is plain text.
|
|
27
31
|
*/
|
|
28
|
-
export declare
|
|
32
|
+
export declare function Markdown<T = string>({ children, links, headings, resolveLink, onAppLinkPress, onLinkPress, loading, style, textStyle, testID, }: MarkdownProps<T>): React.ReactElement | null;
|
|
33
|
+
export declare namespace Markdown {
|
|
34
|
+
var displayName: string;
|
|
35
|
+
}
|
|
29
36
|
//# sourceMappingURL=Markdown.d.ts.map
|
|
@@ -3,7 +3,7 @@ import type { StyleProp, TextInputProps, TextStyle, ViewStyle } from "react-nati
|
|
|
3
3
|
import type { Size } from "../../types/vocabulary";
|
|
4
4
|
import type { HapticType } from "../../utils";
|
|
5
5
|
export type NumberInputSize = Extract<Size, "sm" | "md" | "lg">;
|
|
6
|
-
export type NumberInputVariant = "inline" | "horizontal"
|
|
6
|
+
export type NumberInputVariant = "inline" | "horizontal";
|
|
7
7
|
export interface NumberInputLabels {
|
|
8
8
|
decrease: string;
|
|
9
9
|
increase: string;
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
* The text transforms behind the editor's toolbar, kept out of the component so
|
|
3
3
|
* the behaviour people actually notice — toggling bold OFF again, and where the
|
|
4
4
|
* caret lands when nothing is selected — can be tested as data, with no
|
|
5
|
-
* rendering involved.
|
|
5
|
+
* rendering involved.
|
|
6
6
|
*
|
|
7
7
|
* The output targets our own `<Markdown>` renderer, so the vocabulary is the
|
|
8
|
-
* subset
|
|
8
|
+
* subset the @webority/markdown-core grammar reads: `**`, `*`, `~~`, backtick, `[](…)`, `#`, `##`,
|
|
9
9
|
* `- `, `1. `, `> `. Nothing here emits anything that renderer would show as
|
|
10
10
|
* literal text.
|
|
11
11
|
*/
|
|
@@ -22,6 +22,10 @@ export interface ScreenListProps<ItemT> extends Omit<FlatListProps<ItemT>, "onSc
|
|
|
22
22
|
/** From usePagedList or pagingFromInfiniteQuery: the screen draws PagedListFooter and calls loadMore on end reached. */
|
|
23
23
|
paging?: PagedListPaging;
|
|
24
24
|
}
|
|
25
|
+
export interface FloatingActionSlotProps {
|
|
26
|
+
bottomOffset?: number;
|
|
27
|
+
size?: "sm" | "md" | "lg";
|
|
28
|
+
}
|
|
25
29
|
export interface ScreenProps<ItemT = unknown> {
|
|
26
30
|
title?: string;
|
|
27
31
|
subtitle?: string;
|
|
@@ -44,6 +48,10 @@ export interface ScreenProps<ItemT = unknown> {
|
|
|
44
48
|
edges?: SafeAreaEdge[];
|
|
45
49
|
/** Extra space under the content and the footer, for a tab bar drawn over the screen. Default 0. */
|
|
46
50
|
bottomInset?: number;
|
|
51
|
+
/** Side margin of the content from the theme's screen gutter (16). Default true in scroll and fixed modes, false in list mode, where rows carry their own padding. The footer always has it. */
|
|
52
|
+
gutter?: boolean;
|
|
53
|
+
/** A FloatingActionButton or FloatingActionButtonGroup. The screen draws it above the tab bar and the footer and leaves room under the content so the last row is never covered. */
|
|
54
|
+
floatingAction?: React.ReactElement<FloatingActionSlotProps>;
|
|
47
55
|
/** Default true. */
|
|
48
56
|
keyboardToolbar?: boolean;
|
|
49
57
|
scrollRef?: React.Ref<ScrollView | FlatList<ItemT>>;
|
|
@@ -54,7 +62,9 @@ export interface ScreenProps<ItemT = unknown> {
|
|
|
54
62
|
/**
|
|
55
63
|
* The page shell: safe area, app bar with a large title that collapses as the
|
|
56
64
|
* content scrolls, a keyboard-aware scroll view (or a virtualised list), pull to
|
|
57
|
-
* refresh, a pinned footer
|
|
65
|
+
* refresh, a pinned footer, a floating action button with room kept under the content
|
|
66
|
+
* and the keyboard toolbar. Content and footer sit inside the theme's screen gutter (16)
|
|
67
|
+
* unless `gutter` is false. The screen never navigates:
|
|
58
68
|
* it calls `onBack`; `NavigationScreen` from `@webority/mobile-ui/navigation` binds
|
|
59
69
|
* it to react-navigation and holds the unsaved-changes guard.
|
|
60
70
|
*/
|
|
@@ -57,8 +57,6 @@ export interface SkeletonProps {
|
|
|
57
57
|
radius?: SkeletonRadius;
|
|
58
58
|
/** Animation pattern. */
|
|
59
59
|
variant?: SkeletonVariant;
|
|
60
|
-
/** Sweep speed for shimmer. */
|
|
61
|
-
speed?: SkeletonSpeed;
|
|
62
60
|
/**
|
|
63
61
|
* Per-instance color override. Falls back to provider defaults, then theme.
|
|
64
62
|
* Use for one-off contrast adjustments (dark shimmer on a light banner);
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
import type { ComponentType, ReactNode } from "react";
|
|
49
49
|
import React from "react";
|
|
50
50
|
import type { StyleProp, ViewStyle } from "react-native";
|
|
51
|
-
import type { SkeletonLabels,
|
|
51
|
+
import type { SkeletonLabels, SkeletonVariant } from "./Skeleton";
|
|
52
52
|
import type { SkeletonColors } from "./SkeletonProvider";
|
|
53
53
|
/**
|
|
54
54
|
* Components that ship their own placeholder shape declare this static. The
|
|
@@ -72,8 +72,6 @@ export interface SkeletonContentProps {
|
|
|
72
72
|
placeholder?: ReactNode;
|
|
73
73
|
/** Animation style forwarded to walker-produced `<Skeleton>` blocks. */
|
|
74
74
|
variant?: SkeletonVariant;
|
|
75
|
-
/** Animation speed forwarded to walker-produced `<Skeleton>` blocks. */
|
|
76
|
-
speed?: SkeletonSpeed;
|
|
77
75
|
/**
|
|
78
76
|
* Repeat `placeholder` (or `children`, when no placeholder is provided)
|
|
79
77
|
* this many times while loading. Useful for list layouts where the
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ReactElement, ReactNode } from "react";
|
|
2
2
|
import type { FlatListProps, StyleProp, ViewStyle } from "react-native";
|
|
3
|
-
import type { SkeletonLabels,
|
|
3
|
+
import type { SkeletonLabels, SkeletonVariant } from "./Skeleton";
|
|
4
4
|
import type { SkeletonColors } from "./SkeletonProvider";
|
|
5
5
|
export interface SkeletonListProps<ItemT> extends Omit<FlatListProps<ItemT>, "data" | "renderItem"> {
|
|
6
6
|
/** Whether the list is in its initial loading state. */
|
|
@@ -18,8 +18,6 @@ export interface SkeletonListProps<ItemT> extends Omit<FlatListProps<ItemT>, "da
|
|
|
18
18
|
placeholderCount?: number;
|
|
19
19
|
/** Animation style — same as Skeleton. */
|
|
20
20
|
variant?: SkeletonVariant;
|
|
21
|
-
/** Animation speed — same as Skeleton. */
|
|
22
|
-
speed?: SkeletonSpeed;
|
|
23
21
|
/** Colour override forwarded to the placeholder skeletons. */
|
|
24
22
|
colors?: SkeletonColors;
|
|
25
23
|
/** Screen-reader copy for the placeholder state, merged over the English defaults. */
|
|
@@ -194,6 +194,9 @@ export interface ComponentTokens {
|
|
|
194
194
|
banner: {
|
|
195
195
|
"tint-bar-width": number;
|
|
196
196
|
};
|
|
197
|
+
screen: {
|
|
198
|
+
gutter: SpaceName;
|
|
199
|
+
};
|
|
197
200
|
}
|
|
198
201
|
export type ComponentName = keyof ComponentTokens;
|
|
199
202
|
type SizeKeysOf<C extends ComponentName> = Extract<keyof ComponentTokens[C], "xs" | "sm" | "md" | "lg" | "xl">;
|
|
@@ -336,6 +339,9 @@ export declare const COMPONENT_KINDS: {
|
|
|
336
339
|
readonly banner: {
|
|
337
340
|
readonly "tint-bar-width": "px";
|
|
338
341
|
};
|
|
342
|
+
readonly screen: {
|
|
343
|
+
readonly gutter: "space";
|
|
344
|
+
};
|
|
339
345
|
};
|
|
340
346
|
export interface TokenSet {
|
|
341
347
|
mode: "light" | "dark";
|
|
@@ -19,6 +19,8 @@ export interface ForceUpdateDialogProps {
|
|
|
19
19
|
mandatory?: boolean;
|
|
20
20
|
/** Optional override of the destination URL (defaults to the platform store). */
|
|
21
21
|
updateUrl?: string | null;
|
|
22
|
+
/** Address shown as a tappable link when the store cannot be opened. Nothing extra is shown without it. */
|
|
23
|
+
updateFallbackUrl?: string | null;
|
|
22
24
|
/** Per-call title override; wins over `labels.title`. */
|
|
23
25
|
title?: string;
|
|
24
26
|
/** Per-call message override; wins over `labels.message`. */
|
package/lib/typescript/module/components/KeyboardAwareScrollView/KeyboardAwareScrollView.d.ts
CHANGED
|
@@ -12,7 +12,8 @@ export interface KeyboardAwareScrollViewProps extends ControllerScrollViewProps
|
|
|
12
12
|
/**
|
|
13
13
|
* A tap on empty space inside the content closes the keyboard and blurs the
|
|
14
14
|
* focused field. Taps that a field, button or any other pressable claims are
|
|
15
|
-
* left alone. Default false
|
|
15
|
+
* left alone. Default true; pass false for content that handles its own taps
|
|
16
|
+
* on empty space (a canvas, a map). Needed on Android edge-to-edge, where the
|
|
16
17
|
* ScrollView's own tap-out dismissal never fires because React Native sees no
|
|
17
18
|
* keyboard metrics.
|
|
18
19
|
*/
|
|
@@ -21,9 +22,10 @@ export interface KeyboardAwareScrollViewProps extends ControllerScrollViewProps
|
|
|
21
22
|
/**
|
|
22
23
|
* react-native-keyboard-controller's `KeyboardAwareScrollView` with the
|
|
23
24
|
* library's defaults: the focused field kept 24 above the keyboard, safe-area
|
|
24
|
-
* padding, a themed pull-to-refresh,
|
|
25
|
-
* keyboard open. The controller follows the keyboard
|
|
26
|
-
* thread, so nothing here listens to keyboard events.
|
|
25
|
+
* padding, a themed pull-to-refresh, a tap on empty space that closes the
|
|
26
|
+
* keyboard, and scrolls that keep it open. The controller follows the keyboard
|
|
27
|
+
* frame by frame on the UI thread, so nothing here listens to keyboard events.
|
|
28
|
+
* Needs the app's
|
|
27
29
|
* `KeyboardProvider` at the root.
|
|
28
30
|
*/
|
|
29
31
|
declare const KeyboardAwareScrollView: import("react").ForwardRefExoticComponent<KeyboardAwareScrollViewProps & import("react").RefAttributes<KeyboardAwareScrollViewRef>>;
|
|
@@ -1,9 +1,18 @@
|
|
|
1
|
+
import { type MarkdownHeadings, type MarkdownLinks } from "@webority/markdown-core";
|
|
1
2
|
import type React from "react";
|
|
2
3
|
import type { StyleProp, TextStyle, ViewStyle } from "react-native";
|
|
3
|
-
export interface MarkdownProps {
|
|
4
|
+
export interface MarkdownProps<T = string> {
|
|
4
5
|
/** The markdown source. An empty or missing string renders nothing. */
|
|
5
6
|
children?: string;
|
|
6
|
-
/**
|
|
7
|
+
/** `web` makes web and contact addresses pressable; `app` makes the links `resolveLink` maps pressable. Any other scheme is plain text. */
|
|
8
|
+
links?: MarkdownLinks;
|
|
9
|
+
/** `outline` sizes each heading by its level; `text` draws every heading as bold body text. */
|
|
10
|
+
headings?: MarkdownHeadings;
|
|
11
|
+
/** Maps an app link's address to what `onAppLinkPress` receives. Null leaves the link as plain text. */
|
|
12
|
+
resolveLink?: (href: string) => T | null | undefined;
|
|
13
|
+
/** Opens an app link. Without it, app links show as plain text. */
|
|
14
|
+
onAppLinkPress?: (target: T) => void;
|
|
15
|
+
/** Called instead of Linking.openURL when a web or contact link is pressed. */
|
|
7
16
|
onLinkPress?: (href: string) => void;
|
|
8
17
|
/**
|
|
9
18
|
* When true, renders the component as its authored skeleton placeholder shape.
|
|
@@ -17,13 +26,11 @@ export interface MarkdownProps {
|
|
|
17
26
|
testID?: string;
|
|
18
27
|
}
|
|
19
28
|
/**
|
|
20
|
-
* Renders
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* It exists because Expo has no markdown module and the alternative on npm has
|
|
24
|
-
* not shipped since 2022. What it covers is what our content contains: release
|
|
25
|
-
* notes, help text and descriptions written by people. Nested lists, tables and
|
|
26
|
-
* inline HTML are out of scope on purpose — see parse.ts.
|
|
29
|
+
* Renders the shared markdown grammar with the theme's own type scale and colours,
|
|
30
|
+
* with no dependency. Inline HTML is plain text.
|
|
27
31
|
*/
|
|
28
|
-
export declare
|
|
32
|
+
export declare function Markdown<T = string>({ children, links, headings, resolveLink, onAppLinkPress, onLinkPress, loading, style, textStyle, testID, }: MarkdownProps<T>): React.ReactElement | null;
|
|
33
|
+
export declare namespace Markdown {
|
|
34
|
+
var displayName: string;
|
|
35
|
+
}
|
|
29
36
|
//# sourceMappingURL=Markdown.d.ts.map
|
|
@@ -3,7 +3,7 @@ import type { StyleProp, TextInputProps, TextStyle, ViewStyle } from "react-nati
|
|
|
3
3
|
import type { Size } from "../../types/vocabulary.js";
|
|
4
4
|
import type { HapticType } from "../../utils/index.js";
|
|
5
5
|
export type NumberInputSize = Extract<Size, "sm" | "md" | "lg">;
|
|
6
|
-
export type NumberInputVariant = "inline" | "horizontal"
|
|
6
|
+
export type NumberInputVariant = "inline" | "horizontal";
|
|
7
7
|
export interface NumberInputLabels {
|
|
8
8
|
decrease: string;
|
|
9
9
|
increase: string;
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
* The text transforms behind the editor's toolbar, kept out of the component so
|
|
3
3
|
* the behaviour people actually notice — toggling bold OFF again, and where the
|
|
4
4
|
* caret lands when nothing is selected — can be tested as data, with no
|
|
5
|
-
* rendering involved.
|
|
5
|
+
* rendering involved.
|
|
6
6
|
*
|
|
7
7
|
* The output targets our own `<Markdown>` renderer, so the vocabulary is the
|
|
8
|
-
* subset
|
|
8
|
+
* subset the @webority/markdown-core grammar reads: `**`, `*`, `~~`, backtick, `[](…)`, `#`, `##`,
|
|
9
9
|
* `- `, `1. `, `> `. Nothing here emits anything that renderer would show as
|
|
10
10
|
* literal text.
|
|
11
11
|
*/
|
|
@@ -22,6 +22,10 @@ export interface ScreenListProps<ItemT> extends Omit<FlatListProps<ItemT>, "onSc
|
|
|
22
22
|
/** From usePagedList or pagingFromInfiniteQuery: the screen draws PagedListFooter and calls loadMore on end reached. */
|
|
23
23
|
paging?: PagedListPaging;
|
|
24
24
|
}
|
|
25
|
+
export interface FloatingActionSlotProps {
|
|
26
|
+
bottomOffset?: number;
|
|
27
|
+
size?: "sm" | "md" | "lg";
|
|
28
|
+
}
|
|
25
29
|
export interface ScreenProps<ItemT = unknown> {
|
|
26
30
|
title?: string;
|
|
27
31
|
subtitle?: string;
|
|
@@ -44,6 +48,10 @@ export interface ScreenProps<ItemT = unknown> {
|
|
|
44
48
|
edges?: SafeAreaEdge[];
|
|
45
49
|
/** Extra space under the content and the footer, for a tab bar drawn over the screen. Default 0. */
|
|
46
50
|
bottomInset?: number;
|
|
51
|
+
/** Side margin of the content from the theme's screen gutter (16). Default true in scroll and fixed modes, false in list mode, where rows carry their own padding. The footer always has it. */
|
|
52
|
+
gutter?: boolean;
|
|
53
|
+
/** A FloatingActionButton or FloatingActionButtonGroup. The screen draws it above the tab bar and the footer and leaves room under the content so the last row is never covered. */
|
|
54
|
+
floatingAction?: React.ReactElement<FloatingActionSlotProps>;
|
|
47
55
|
/** Default true. */
|
|
48
56
|
keyboardToolbar?: boolean;
|
|
49
57
|
scrollRef?: React.Ref<ScrollView | FlatList<ItemT>>;
|
|
@@ -54,7 +62,9 @@ export interface ScreenProps<ItemT = unknown> {
|
|
|
54
62
|
/**
|
|
55
63
|
* The page shell: safe area, app bar with a large title that collapses as the
|
|
56
64
|
* content scrolls, a keyboard-aware scroll view (or a virtualised list), pull to
|
|
57
|
-
* refresh, a pinned footer
|
|
65
|
+
* refresh, a pinned footer, a floating action button with room kept under the content
|
|
66
|
+
* and the keyboard toolbar. Content and footer sit inside the theme's screen gutter (16)
|
|
67
|
+
* unless `gutter` is false. The screen never navigates:
|
|
58
68
|
* it calls `onBack`; `NavigationScreen` from `@webority/mobile-ui/navigation` binds
|
|
59
69
|
* it to react-navigation and holds the unsaved-changes guard.
|
|
60
70
|
*/
|
|
@@ -57,8 +57,6 @@ export interface SkeletonProps {
|
|
|
57
57
|
radius?: SkeletonRadius;
|
|
58
58
|
/** Animation pattern. */
|
|
59
59
|
variant?: SkeletonVariant;
|
|
60
|
-
/** Sweep speed for shimmer. */
|
|
61
|
-
speed?: SkeletonSpeed;
|
|
62
60
|
/**
|
|
63
61
|
* Per-instance color override. Falls back to provider defaults, then theme.
|
|
64
62
|
* Use for one-off contrast adjustments (dark shimmer on a light banner);
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
import type { ComponentType, ReactNode } from "react";
|
|
49
49
|
import React from "react";
|
|
50
50
|
import type { StyleProp, ViewStyle } from "react-native";
|
|
51
|
-
import type { SkeletonLabels,
|
|
51
|
+
import type { SkeletonLabels, SkeletonVariant } from "./Skeleton.js";
|
|
52
52
|
import type { SkeletonColors } from "./SkeletonProvider.js";
|
|
53
53
|
/**
|
|
54
54
|
* Components that ship their own placeholder shape declare this static. The
|
|
@@ -72,8 +72,6 @@ export interface SkeletonContentProps {
|
|
|
72
72
|
placeholder?: ReactNode;
|
|
73
73
|
/** Animation style forwarded to walker-produced `<Skeleton>` blocks. */
|
|
74
74
|
variant?: SkeletonVariant;
|
|
75
|
-
/** Animation speed forwarded to walker-produced `<Skeleton>` blocks. */
|
|
76
|
-
speed?: SkeletonSpeed;
|
|
77
75
|
/**
|
|
78
76
|
* Repeat `placeholder` (or `children`, when no placeholder is provided)
|
|
79
77
|
* this many times while loading. Useful for list layouts where the
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ReactElement, ReactNode } from "react";
|
|
2
2
|
import type { FlatListProps, StyleProp, ViewStyle } from "react-native";
|
|
3
|
-
import type { SkeletonLabels,
|
|
3
|
+
import type { SkeletonLabels, SkeletonVariant } from "./Skeleton.js";
|
|
4
4
|
import type { SkeletonColors } from "./SkeletonProvider.js";
|
|
5
5
|
export interface SkeletonListProps<ItemT> extends Omit<FlatListProps<ItemT>, "data" | "renderItem"> {
|
|
6
6
|
/** Whether the list is in its initial loading state. */
|
|
@@ -18,8 +18,6 @@ export interface SkeletonListProps<ItemT> extends Omit<FlatListProps<ItemT>, "da
|
|
|
18
18
|
placeholderCount?: number;
|
|
19
19
|
/** Animation style — same as Skeleton. */
|
|
20
20
|
variant?: SkeletonVariant;
|
|
21
|
-
/** Animation speed — same as Skeleton. */
|
|
22
|
-
speed?: SkeletonSpeed;
|
|
23
21
|
/** Colour override forwarded to the placeholder skeletons. */
|
|
24
22
|
colors?: SkeletonColors;
|
|
25
23
|
/** Screen-reader copy for the placeholder state, merged over the English defaults. */
|
|
@@ -194,6 +194,9 @@ export interface ComponentTokens {
|
|
|
194
194
|
banner: {
|
|
195
195
|
"tint-bar-width": number;
|
|
196
196
|
};
|
|
197
|
+
screen: {
|
|
198
|
+
gutter: SpaceName;
|
|
199
|
+
};
|
|
197
200
|
}
|
|
198
201
|
export type ComponentName = keyof ComponentTokens;
|
|
199
202
|
type SizeKeysOf<C extends ComponentName> = Extract<keyof ComponentTokens[C], "xs" | "sm" | "md" | "lg" | "xl">;
|
|
@@ -336,6 +339,9 @@ export declare const COMPONENT_KINDS: {
|
|
|
336
339
|
readonly banner: {
|
|
337
340
|
readonly "tint-bar-width": "px";
|
|
338
341
|
};
|
|
342
|
+
readonly screen: {
|
|
343
|
+
readonly gutter: "space";
|
|
344
|
+
};
|
|
339
345
|
};
|
|
340
346
|
export interface TokenSet {
|
|
341
347
|
mode: "light" | "dark";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webority/mobile-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.113.0",
|
|
4
4
|
"description": "Beautiful, animated, accessible React Native components, theme and form engine for Webority projects.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react-native",
|
|
@@ -84,6 +84,9 @@
|
|
|
84
84
|
"javaPackageName": "com.webority.mobileui.pdfrasterizer"
|
|
85
85
|
}
|
|
86
86
|
},
|
|
87
|
+
"dependencies": {
|
|
88
|
+
"@webority/markdown-core": "0.113.0"
|
|
89
|
+
},
|
|
87
90
|
"peerDependencies": {
|
|
88
91
|
"@react-navigation/bottom-tabs": ">=7.0.0",
|
|
89
92
|
"@react-navigation/native": ">=7.0.0",
|
|
@@ -100,8 +103,8 @@
|
|
|
100
103
|
"react-native-safe-area-context": ">=5.4.0",
|
|
101
104
|
"react-native-svg": ">=15.0.0",
|
|
102
105
|
"react-native-worklets": ">=0.10.0",
|
|
103
|
-
"@webority/canvas-kit": "0.
|
|
104
|
-
"@webority/mobile-core": "0.
|
|
106
|
+
"@webority/canvas-kit": "0.113.0",
|
|
107
|
+
"@webority/mobile-core": "0.113.0"
|
|
105
108
|
},
|
|
106
109
|
"peerDependenciesMeta": {
|
|
107
110
|
"@react-navigation/bottom-tabs": {
|
|
@@ -170,10 +173,10 @@
|
|
|
170
173
|
"react-test-renderer": "19.2.8",
|
|
171
174
|
"rimraf": "6.1.3",
|
|
172
175
|
"typescript": "5.9.3",
|
|
173
|
-
"@webority/canvas-kit": "0.
|
|
174
|
-
"@webority/mobile-core": "0.
|
|
176
|
+
"@webority/canvas-kit": "0.113.0",
|
|
177
|
+
"@webority/mobile-core": "0.113.0",
|
|
175
178
|
"@webority/mobile-dev": "0.0.0",
|
|
176
|
-
"@webority/tokens": "0.
|
|
179
|
+
"@webority/tokens": "0.113.0"
|
|
177
180
|
},
|
|
178
181
|
"scripts": {
|
|
179
182
|
"build": "bob build && node ../mobile-dev/scripts/minify-lib.mjs && node -e \"require('node:fs').rmSync('dist/canvas-kit',{recursive:true,force:true})\" && node ../canvas-kit/dist/cli.js build --config canvas-kit.json --out dist/canvas-kit",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.parseMarkdown=exports.parseInline=exports.markdownToPlainText=void 0;const INLINE_PATTERNS=[{re:/^`([^`]+)`/,build:e=>({type:"code",value:e[1]})},{re:/^\[([^\]]*)\]\(([^)\s]+)\)/,build:(e,n)=>({type:"link",href:e[2],children:n(e[1])})},{re:/^\*\*([\s\S]+?)\*\*/,build:(e,n)=>({type:"strong",children:n(e[1])})},{re:/^__([\s\S]+?)__/,build:(e,n)=>({type:"strong",children:n(e[1])})},{re:/^~~([\s\S]+?)~~/,build:(e,n)=>({type:"strike",children:n(e[1])})},{re:/^\*([^*\n]+)\*/,build:(e,n)=>({type:"em",children:n(e[1])})},{re:/^_([^_\n]+)_/,build:(e,n)=>({type:"em",children:n(e[1])})}],parseInline=e=>{const n=[];let t="",r=e;const flush=()=>{t&&(n.push({type:"text",value:t}),t="")};for(;r.length>0;){if(r.startsWith("\\")&&r.length>1){t+=r[1],r=r.slice(2);continue}let e=!1;for(const{re:t,build:s}of INLINE_PATTERNS){const i=t.exec(r);if(i){flush(),n.push(s(i,parseInline)),r=r.slice(i[0].length),e=!0;break}}e||(t+=r[0],r=r.slice(1))}return flush(),n};exports.parseInline=parseInline;const MAX_LIST_DEPTH=4,depthOf=e=>{const n=e.replace(/\t/g," ").length;return Math.min(Math.floor(n/2),4)},HEADING=/^(#{1,6})\s+(.*)$/,UNORDERED=/^(\s*)[-*+]\s+(.*)$/,ORDERED=/^(\s*)(\d+)[.)]\s+(.*)$/,QUOTE=/^\s*>\s?(.*)$/,RULE=/^\s*([-*_])\s*(?:\1\s*){2,}$/,FENCE=/^\s*```\s*(\S+)?\s*$/,parseMarkdown=e=>{const n=[],t=(e??"").replace(/\r\n?/g,"\n").split("\n");let r=[];const flushParagraph=()=>{r.length>0&&(n.push({type:"paragraph",children:parseInline(r.join(" ").trim())}),r=[])};for(let e=0;e<t.length;e++){const s=t[e],i=FENCE.exec(s);if(i){flushParagraph();const r=[];for(e++;e<t.length&&!FENCE.test(t[e]);)r.push(t[e]),e++;n.push({type:"codeBlock",value:r.join("\n"),language:i[1]});continue}if(""===s.trim()){flushParagraph();continue}if(RULE.test(s)){flushParagraph(),n.push({type:"rule"});continue}const l=HEADING.exec(s);if(l){flushParagraph(),n.push({type:"heading",level:l[1].length,children:parseInline(l[2])});continue}const o=ORDERED.exec(s);if(o){flushParagraph(),n.push({type:"listItem",ordered:!0,index:Number(o[2]),depth:depthOf(o[1]),children:parseInline(o[3])});continue}const p=UNORDERED.exec(s);if(p){flushParagraph(),n.push({type:"listItem",ordered:!1,index:0,depth:depthOf(p[1]),children:parseInline(p[2])});continue}const a=QUOTE.exec(s);a?(flushParagraph(),n.push({type:"quote",children:parseInline(a[1])})):r.push(s.trim())}return flushParagraph(),n};exports.parseMarkdown=parseMarkdown;const inlinePlainText=e=>e.map(e=>"text"===e.type||"code"===e.type?e.value:inlinePlainText(e.children)).join(""),markdownToPlainText=e=>parseMarkdown(e).map(e=>{switch(e.type){case"heading":case"paragraph":case"listItem":case"quote":return inlinePlainText(e.children);case"codeBlock":return e.value;default:return""}}).filter(Boolean).join(" ");exports.markdownToPlainText=markdownToPlainText;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const INLINE_PATTERNS=[{re:/^`([^`]+)`/,build:e=>({type:"code",value:e[1]})},{re:/^\[([^\]]*)\]\(([^)\s]+)\)/,build:(e,t)=>({type:"link",href:e[2],children:t(e[1])})},{re:/^\*\*([\s\S]+?)\*\*/,build:(e,t)=>({type:"strong",children:t(e[1])})},{re:/^__([\s\S]+?)__/,build:(e,t)=>({type:"strong",children:t(e[1])})},{re:/^~~([\s\S]+?)~~/,build:(e,t)=>({type:"strike",children:t(e[1])})},{re:/^\*([^*\n]+)\*/,build:(e,t)=>({type:"em",children:t(e[1])})},{re:/^_([^_\n]+)_/,build:(e,t)=>({type:"em",children:t(e[1])})}];export const parseInline=e=>{const t=[];let n="",i=e;const flush=()=>{n&&(t.push({type:"text",value:n}),n="")};for(;i.length>0;){if(i.startsWith("\\")&&i.length>1){n+=i[1],i=i.slice(2);continue}let e=!1;for(const{re:n,build:s}of INLINE_PATTERNS){const r=n.exec(i);if(r){flush(),t.push(s(r,parseInline)),i=i.slice(r[0].length),e=!0;break}}e||(n+=i[0],i=i.slice(1))}return flush(),t};const MAX_LIST_DEPTH=4,depthOf=e=>{const t=e.replace(/\t/g," ").length;return Math.min(Math.floor(t/2),4)},HEADING=/^(#{1,6})\s+(.*)$/,UNORDERED=/^(\s*)[-*+]\s+(.*)$/,ORDERED=/^(\s*)(\d+)[.)]\s+(.*)$/,QUOTE=/^\s*>\s?(.*)$/,RULE=/^\s*([-*_])\s*(?:\1\s*){2,}$/,FENCE=/^\s*```\s*(\S+)?\s*$/;export const parseMarkdown=e=>{const t=[],n=(e??"").replace(/\r\n?/g,"\n").split("\n");let i=[];const flushParagraph=()=>{i.length>0&&(t.push({type:"paragraph",children:parseInline(i.join(" ").trim())}),i=[])};for(let e=0;e<n.length;e++){const s=n[e],r=FENCE.exec(s);if(r){flushParagraph();const i=[];for(e++;e<n.length&&!FENCE.test(n[e]);)i.push(n[e]),e++;t.push({type:"codeBlock",value:i.join("\n"),language:r[1]});continue}if(""===s.trim()){flushParagraph();continue}if(RULE.test(s)){flushParagraph(),t.push({type:"rule"});continue}const l=HEADING.exec(s);if(l){flushParagraph(),t.push({type:"heading",level:l[1].length,children:parseInline(l[2])});continue}const c=ORDERED.exec(s);if(c){flushParagraph(),t.push({type:"listItem",ordered:!0,index:Number(c[2]),depth:depthOf(c[1]),children:parseInline(c[3])});continue}const o=UNORDERED.exec(s);if(o){flushParagraph(),t.push({type:"listItem",ordered:!1,index:0,depth:depthOf(o[1]),children:parseInline(o[2])});continue}const p=QUOTE.exec(s);p?(flushParagraph(),t.push({type:"quote",children:parseInline(p[1])})):i.push(s.trim())}return flushParagraph(),t};const inlinePlainText=e=>e.map(e=>"text"===e.type||"code"===e.type?e.value:inlinePlainText(e.children)).join("");export const markdownToPlainText=e=>parseMarkdown(e).map(e=>{switch(e.type){case"heading":case"paragraph":case"listItem":case"quote":return inlinePlainText(e.children);case"codeBlock":return e.value;default:return""}}).filter(Boolean).join(" ");
|