@webority/ui-react 0.132.0 → 0.134.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.
@@ -2,7 +2,7 @@
2
2
  "kind": "WeborityWeb",
3
3
  "library": {
4
4
  "name": "@webority/ui-react",
5
- "version": "0.132.0"
5
+ "version": "0.134.0"
6
6
  },
7
7
  "rendererProtocolVersion": 13,
8
8
  "platform": "Web",
@@ -13776,6 +13776,17 @@
13776
13776
  "description": "The full-screen dialog's name for screen readers.",
13777
13777
  "default": "Image viewer"
13778
13778
  },
13779
+ {
13780
+ "name": "layout",
13781
+ "type": "enum",
13782
+ "enum": [
13783
+ "gallery",
13784
+ "single"
13785
+ ],
13786
+ "required": false,
13787
+ "description": "gallery shows thumbnails; single shows each image at the container's full width, at its own shape.",
13788
+ "default": "gallery"
13789
+ },
13779
13790
  {
13780
13791
  "name": "openIndex",
13781
13792
  "type": "number",
@@ -13982,6 +13993,12 @@
13982
13993
  "marker": "AppMarkdown",
13983
13994
  "acceptsChildren": false,
13984
13995
  "props": [
13996
+ {
13997
+ "name": "base",
13998
+ "type": "string",
13999
+ "required": false,
14000
+ "description": "An https origin such as https://example.com that a relative link resolves against: /pricing opens https://example.com/pricing. Any other value (a path, a query, credentials, http) is ignored with a dev warning."
14001
+ },
13985
14002
  {
13986
14003
  "name": "className",
13987
14004
  "type": "string",
@@ -1,21 +1,21 @@
1
1
  {
2
2
  "name": "webority-web",
3
- "version": "0.132.0",
3
+ "version": "0.134.0",
4
4
  "platform": "Web",
5
5
  "kitModuleVersion": 2,
6
6
  "rendererProtocolVersion": 13,
7
7
  "library": {
8
8
  "name": "@webority/ui-react",
9
- "version": "0.132.0"
9
+ "version": "0.134.0"
10
10
  },
11
11
  "files": {
12
12
  "manifest.json": {
13
- "sha256": "1ab939dd724956b61547a58ecc18f71a02c5ee418b5602e1f101e6437e50005d",
14
- "bytes": 1004508
13
+ "sha256": "91531e8b00ff9b11e0ae1a82a121f0211b3a89f6ae2ab560b3ced1fb3a3d2d72",
14
+ "bytes": 1005189
15
15
  },
16
16
  "kit.js": {
17
- "sha256": "29422c4be30de831a002a427af2ea4b3c2515043daea83c0fa8ec0300713287e",
18
- "bytes": 11167028
17
+ "sha256": "e33f8be217022f1defba348234e2aefc7bfa514e85ce85ecc9be5838951677b1",
18
+ "bytes": 11171178
19
19
  },
20
20
  "kit.css": {
21
21
  "sha256": "13b14f71fb6ea024945f95cba617b4f1d49f44a65ba7c7ed05d2354805539ef6",
@@ -1 +1 @@
1
- import{splitMarkerProps as e}from"../lib/wuiMarker.js";import t from"./warnUnknownProps.js";import{useEffect as n,useRef as r}from"react";import{jsx as i}from"react/jsx-runtime";import"@webority/ui-elements/elements/lightbox";function a(a){let{marker:o,props:s}=e(`AppLightbox`,a),{items:c=[],download:l=!1,label:u,openIndex:d,onChange:f,onClose:p,className:m=``,...h}=s;t(`AppLightbox`,h);let g=r(null),_=r({onChange:f,onClose:p});return n(()=>{_.current={onChange:f,onClose:p}}),n(()=>{let e=g.current,t=e=>_.current.onChange?.(e.detail.index),n=()=>_.current.onClose?.();return e.addEventListener(`wui-lightbox:change`,t),e.addEventListener(`wui-lightbox:close`,n),()=>{e.removeEventListener(`wui-lightbox:change`,t),e.removeEventListener(`wui-lightbox:close`,n)}},[]),/* @__PURE__ */ i(`wui-lightbox`,{ref:g,class:[`wui-lightbox`,m].filter(Boolean).join(` `),download:l?``:void 0,label:u||void 0,"open-index":Number.isInteger(d)?d:void 0,...o,...h,children:c.map(e=>/* @__PURE__ */ i(`a`,{className:`wui-lightbox-item`,href:e.src,"data-caption":e.caption||void 0,"data-name":e.name||void 0,children:/* @__PURE__ */ i(`img`,{src:e.thumb||e.src,alt:e.alt??e.caption??``,loading:`lazy`})},e.key??e.src))})}export{a as default};
1
+ import{splitMarkerProps as e}from"../lib/wuiMarker.js";import t from"./warnInvalidValue.js";import n from"./warnUnknownProps.js";import{useEffect as r,useRef as i}from"react";import{jsx as a}from"react/jsx-runtime";import"@webority/ui-elements/elements/lightbox";var o=[`gallery`,`single`];function s(s){let{marker:c,props:l}=e(`AppLightbox`,s),{items:u=[],download:d=!1,label:f,layout:p=`gallery`,openIndex:m,onChange:h,onClose:g,className:_=``,...v}=l;n(`AppLightbox`,v),t(`AppLightbox`,`layout`,p,o);let y=i(null),b=i({onChange:h,onClose:g});return r(()=>{b.current={onChange:h,onClose:g}}),r(()=>{let e=y.current,t=e=>b.current.onChange?.(e.detail.index),n=()=>b.current.onClose?.();return e.addEventListener(`wui-lightbox:change`,t),e.addEventListener(`wui-lightbox:close`,n),()=>{e.removeEventListener(`wui-lightbox:change`,t),e.removeEventListener(`wui-lightbox:close`,n)}},[]),/* @__PURE__ */ a(`wui-lightbox`,{ref:y,class:[`wui-lightbox`,_].filter(Boolean).join(` `),download:d?``:void 0,label:f||void 0,layout:p===`single`?`single`:void 0,"open-index":Number.isInteger(m)?m:void 0,...c,...v,children:u.map(e=>/* @__PURE__ */ a(`a`,{className:`wui-lightbox-item`,href:e.src,"data-caption":e.caption||void 0,"data-name":e.name||void 0,children:/* @__PURE__ */ a(`img`,{src:e.thumb||e.src,alt:e.alt??e.caption??``,loading:`lazy`})},e.key??e.src))})}export{s as default};
@@ -1 +1 @@
1
- import{linkTarget as e,webRoute as t}from"../markdown-core/dist/links.js";import{parseInline as n}from"../markdown-core/dist/inline.js";import{parseMarkdown as r}from"../markdown-core/dist/parse.js";import{splitMarkerProps as i}from"../lib/wuiMarker.js";import a from"./AppChip.js";import o from"./AppCodeBlock.js";import s from"./AppLink.js";import c from"./warnInvalidValue.js";import l from"./warnUnknownProps.js";import{Fragment as u,useMemo as d}from"react";import{jsx as f,jsxs as p}from"react/jsx-runtime";import"@webority/ui-elements/elements/markdown";var m=[`text`,`json`,`js`,`cs`,`sql`,`bash`,`http`,`html`,`css`];function h(e){let{marker:t,props:n}=i(`AppMarkdown`,e),{value:a,className:o=``,linkComponent:s,resolveLink:u,isCitation:p,figureText:m,onOpenCitation:h,links:g=`web`,headings:_=`outline`,...v}=n;l(`AppMarkdown`,v),c(`AppMarkdown`,`links`,g,[`app`,`web`,`page`]),c(`AppMarkdown`,`headings`,_,[`outline`,`text`]);let y=d(()=>r(a),[a]),b={links:g,headings:_,resolveLink:u,linkComponent:s,isCitation:p,figureText:m,onOpenCitation:h};return/* @__PURE__ */ f(`wui-markdown`,{class:[`wui-markdown`,o].filter(Boolean).join(` `),...t,...v,children:y.map(e=>/* @__PURE__ */ f(C,{block:e,options:b},e.key))})}function g({token:n,options:r}){let i=/* @__PURE__ */ f(_,{tokens:n.children,options:r}),a=e(n.href,r.links,r.resolveLink,globalThis.location?.origin);if(a?.kind===`app`){let n=t(a.target);if(n)return/* @__PURE__ */ f(s,{href:n,linkComponent:r.linkComponent,animation:`static`,children:i});let o=a.target;if(r.links!==`page`||typeof o!=`string`||!/^https?:\/\//i.test(o))return i;let c=e(o,`web`,void 0,globalThis.location?.origin)?.kind===`web`;return/* @__PURE__ */ f(s,{href:o,external:c,animation:`static`,children:i})}return a?.kind===`page`?/* @__PURE__ */ f(s,{href:a.href,linkComponent:r.linkComponent,animation:`static`,children:i}):a?.kind===`web`?/* @__PURE__ */ f(s,{href:a.href,external:!0,animation:`static`,children:i}):a?.kind===`contact`?/* @__PURE__ */ f(s,{href:a.href,animation:`static`,children:i}):i}function _({tokens:e,options:t}){return e.map(e=>{switch(e.type){case`code`:return/* @__PURE__ */ f(`code`,{children:e.text},e.key);case`strong`:return/* @__PURE__ */ f(`strong`,{children:/* @__PURE__ */ f(_,{tokens:e.children,options:t})},e.key);case`em`:return/* @__PURE__ */ f(`em`,{children:/* @__PURE__ */ f(_,{tokens:e.children,options:t})},e.key);case`strike`:return/* @__PURE__ */ f(`del`,{children:/* @__PURE__ */ f(_,{tokens:e.children,options:t})},e.key);case`image`:return/* @__PURE__ */ p(u,{children:[`[`,/* @__PURE__ */ f(_,{tokens:e.children,options:t}),`]`]},e.key);case`link`:return/* @__PURE__ */ f(g,{token:e,options:t},e.key);case`citation`:return/* @__PURE__ */ f(a,{label:e.text,size:`sm`,tone:`primary`,variant:`outline`,"aria-label":e.text,className:`wui-markdown-citation`,onClick:t.onOpenCitation?()=>t.onOpenCitation(e.text):void 0},e.key);case`text`:return t.figureText?/* @__PURE__ */ f(u,{children:t.figureText(e.text).map((e,t)=>{if(e.kind===`text`)return e.text;let n=e.kind===`sub`?`sub`:`sup`;return/* @__PURE__ */ f(n,{children:e.text},t)})},e.key):/* @__PURE__ */ f(u,{children:e.text},e.key);default:return/* @__PURE__ */ f(u,{children:e.text},e.key)}})}function v({text:e,options:t}){return/* @__PURE__ */ f(_,{tokens:n(e,{isCitation:t.isCitation}),options:t})}function y({lines:e,options:t}){return e.map((e,n)=>/* @__PURE__ */ p(u,{children:[n>0&&/* @__PURE__ */ f(`br`,{}),/* @__PURE__ */ f(v,{text:e,options:t})]},n))}function b({block:e,options:t}){let n=e=>/* @__PURE__ */ f(v,{text:e,options:t});return/* @__PURE__ */ f(`div`,{className:`table-responsive`,children:/* @__PURE__ */ p(`table`,{className:`table`,children:[/* @__PURE__ */ f(`thead`,{children:/* @__PURE__ */ f(`tr`,{children:e.header.map((e,t)=>/* @__PURE__ */ f(`th`,{scope:`col`,children:n(e)},t))})}),/* @__PURE__ */ f(`tbody`,{children:e.rows.map((t,r)=>/* @__PURE__ */ f(`tr`,{children:e.header.map((e,r)=>/* @__PURE__ */ f(`td`,{children:n(t[r]??``)},r))},r))})]})})}function x(e,t,n){let{items:r}=e,{depth:i,ordered:a,number:o}=r[t],s=[],c=t;for(;c<r.length&&r[c].depth>=i;)if(r[c].depth>i){let t=x(e,c,n);s[s.length-1].nested=t.node,c=t.next}else s.push({item:r[c],index:c,nested:null}),c+=1;let l=s.map(({item:t,index:r,nested:i})=>/* @__PURE__ */ p(`li`,{children:[/* @__PURE__ */ f(v,{text:t.text,options:n}),i]},`${e.key}-${r}`));return{node:a?/* @__PURE__ */ f(`ol`,{start:a&&o!==1?o:void 0,children:l},`${e.key}-${t}`):/* @__PURE__ */ f(`ul`,{children:l},`${e.key}-${t}`),next:c}}function S(e,t){let n=[],r=0;for(;r<e.items.length;){let i=x(e,r,t);n.push(i.node),r=i.next}return n}function C({block:e,options:t}){switch(e.type){case`paragraph`:return/* @__PURE__ */ f(`p`,{children:/* @__PURE__ */ f(y,{lines:e.lines,options:t})});case`quote`:return/* @__PURE__ */ f(`blockquote`,{children:/* @__PURE__ */ f(y,{lines:e.lines,options:t})});case`heading`:{let n=/* @__PURE__ */ f(v,{text:e.text,options:t});return t.headings===`text`?/* @__PURE__ */ f(`p`,{className:`fw-semibold`,children:n}):/* @__PURE__ */ f(`h2`,{children:n})}case`list`:return S(e,t);case`table`:return/* @__PURE__ */ f(b,{block:e,options:t});case`code`:return/* @__PURE__ */ f(o,{code:e.text,language:m.includes(e.language)?e.language:`text`});case`rule`:return/* @__PURE__ */ f(`hr`,{});default:return null}}export{h as default};
1
+ import{linkBase as e,linkTarget as t,webRoute as n}from"../markdown-core/dist/links.js";import{parseInline as r}from"../markdown-core/dist/inline.js";import{parseMarkdown as i}from"../markdown-core/dist/parse.js";import{devWarn as a}from"../lib/devWarn.js";import{splitMarkerProps as o}from"../lib/wuiMarker.js";import s from"./AppChip.js";import c from"./AppCodeBlock.js";import l from"./AppLink.js";import u from"./warnInvalidValue.js";import d from"./warnUnknownProps.js";import{Fragment as f,useMemo as p}from"react";import{jsx as m,jsxs as h}from"react/jsx-runtime";import"@webority/ui-elements/elements/markdown";var g=[`text`,`json`,`js`,`cs`,`sql`,`bash`,`http`,`html`,`css`],_=/* @__PURE__ */ new Set,v=()=>{try{return process.env.NODE_ENV!==`production`}catch{return!0}};function y(e){v()&&!_.has(e)&&(_.add(e),a(`AppMarkdown ignores base="${e}": a base must be an https origin with no path, query, fragment or credentials.`))}function b(t){let{marker:n,props:r}=o(`AppMarkdown`,t),{value:a,className:s=``,linkComponent:c,resolveLink:l,isCitation:f,figureText:h,onOpenCitation:g,links:_=`web`,headings:v=`outline`,base:b,...x}=r;d(`AppMarkdown`,x),u(`AppMarkdown`,`links`,_,[`app`,`web`,`page`]),u(`AppMarkdown`,`headings`,v,[`outline`,`text`]);let S=b==null?null:e(b);b!=null&&S===null&&y(b);let C=p(()=>i(a),[a]),w={links:_,headings:v,resolveLink:l,linkComponent:c,isCitation:f,figureText:h,onOpenCitation:g,base:S};return/* @__PURE__ */ m(`wui-markdown`,{class:[`wui-markdown`,s].filter(Boolean).join(` `),...n,...x,children:C.map(e=>/* @__PURE__ */ m(O,{block:e,options:w},e.key))})}function x({token:e,options:r}){let i=/* @__PURE__ */ m(S,{tokens:e.children,options:r}),a=t(e.href,r.links,r.resolveLink,globalThis.location?.origin,r.base);if(a?.kind===`app`){let e=n(a.target);if(e)return/* @__PURE__ */ m(l,{href:e,linkComponent:r.linkComponent,animation:`static`,children:i});let o=a.target;if(r.links!==`page`||typeof o!=`string`||!/^https?:\/\//i.test(o))return i;let s=t(o,`web`,void 0,globalThis.location?.origin)?.kind===`web`;return/* @__PURE__ */ m(l,{href:o,external:s,animation:`static`,children:i})}return a?.kind===`page`?/* @__PURE__ */ m(l,{href:a.href,linkComponent:r.linkComponent,animation:`static`,children:i}):a?.kind===`web`?/* @__PURE__ */ m(l,{href:a.href,external:!0,animation:`static`,children:i}):a?.kind===`contact`?/* @__PURE__ */ m(l,{href:a.href,animation:`static`,children:i}):i}function S({tokens:e,options:t}){return e.map(e=>{switch(e.type){case`code`:return/* @__PURE__ */ m(`code`,{children:e.text},e.key);case`strong`:return/* @__PURE__ */ m(`strong`,{children:/* @__PURE__ */ m(S,{tokens:e.children,options:t})},e.key);case`em`:return/* @__PURE__ */ m(`em`,{children:/* @__PURE__ */ m(S,{tokens:e.children,options:t})},e.key);case`strike`:return/* @__PURE__ */ m(`del`,{children:/* @__PURE__ */ m(S,{tokens:e.children,options:t})},e.key);case`image`:return/* @__PURE__ */ h(f,{children:[`[`,/* @__PURE__ */ m(S,{tokens:e.children,options:t}),`]`]},e.key);case`link`:return/* @__PURE__ */ m(x,{token:e,options:t},e.key);case`citation`:return/* @__PURE__ */ m(s,{label:e.text,size:`sm`,tone:`primary`,variant:`outline`,"aria-label":e.text,className:`wui-markdown-citation`,onClick:t.onOpenCitation?()=>t.onOpenCitation(e.text):void 0},e.key);case`text`:return t.figureText?/* @__PURE__ */ m(f,{children:t.figureText(e.text).map((e,t)=>{if(e.kind===`text`)return e.text;let n=e.kind===`sub`?`sub`:`sup`;return/* @__PURE__ */ m(n,{children:e.text},t)})},e.key):/* @__PURE__ */ m(f,{children:e.text},e.key);default:return/* @__PURE__ */ m(f,{children:e.text},e.key)}})}function C({text:e,options:t}){return/* @__PURE__ */ m(S,{tokens:r(e,{isCitation:t.isCitation}),options:t})}function w({lines:e,options:t}){return e.map((e,n)=>/* @__PURE__ */ h(f,{children:[n>0&&/* @__PURE__ */ m(`br`,{}),/* @__PURE__ */ m(C,{text:e,options:t})]},n))}function T({block:e,options:t}){let n=e=>/* @__PURE__ */ m(C,{text:e,options:t});return/* @__PURE__ */ m(`div`,{className:`table-responsive`,children:/* @__PURE__ */ h(`table`,{className:`table`,children:[/* @__PURE__ */ m(`thead`,{children:/* @__PURE__ */ m(`tr`,{children:e.header.map((e,t)=>/* @__PURE__ */ m(`th`,{scope:`col`,children:n(e)},t))})}),/* @__PURE__ */ m(`tbody`,{children:e.rows.map((t,r)=>/* @__PURE__ */ m(`tr`,{children:e.header.map((e,r)=>/* @__PURE__ */ m(`td`,{children:n(t[r]??``)},r))},r))})]})})}function E(e,t,n){let{items:r}=e,{depth:i,ordered:a,number:o}=r[t],s=[],c=t;for(;c<r.length&&r[c].depth>=i;)if(r[c].depth>i){let t=E(e,c,n);s[s.length-1].nested=t.node,c=t.next}else s.push({item:r[c],index:c,nested:null}),c+=1;let l=s.map(({item:t,index:r,nested:i})=>/* @__PURE__ */ h(`li`,{children:[/* @__PURE__ */ m(C,{text:t.text,options:n}),i]},`${e.key}-${r}`));return{node:a?/* @__PURE__ */ m(`ol`,{start:a&&o!==1?o:void 0,children:l},`${e.key}-${t}`):/* @__PURE__ */ m(`ul`,{children:l},`${e.key}-${t}`),next:c}}function D(e,t){let n=[],r=0;for(;r<e.items.length;){let i=E(e,r,t);n.push(i.node),r=i.next}return n}function O({block:e,options:t}){switch(e.type){case`paragraph`:return/* @__PURE__ */ m(`p`,{children:/* @__PURE__ */ m(w,{lines:e.lines,options:t})});case`quote`:return/* @__PURE__ */ m(`blockquote`,{children:/* @__PURE__ */ m(w,{lines:e.lines,options:t})});case`heading`:{let n=/* @__PURE__ */ m(C,{text:e.text,options:t});return t.headings===`text`?/* @__PURE__ */ m(`p`,{className:`fw-semibold`,children:n}):/* @__PURE__ */ m(`h2`,{children:n})}case`list`:return D(e,t);case`table`:return/* @__PURE__ */ m(T,{block:e,options:t});case`code`:return/* @__PURE__ */ m(c,{code:e.text,language:g.includes(e.language)?e.language:`text`});case`rule`:return/* @__PURE__ */ m(`hr`,{});default:return null}}export{b as default};
@@ -2,7 +2,7 @@
2
2
  "format": "webority-guidance/1",
3
3
  "package": {
4
4
  "name": "@webority/ui-react",
5
- "version": "0.132.0"
5
+ "version": "0.134.0"
6
6
  },
7
7
  "components": [
8
8
  {
@@ -1 +1 @@
1
- var e=/^[a-z][a-z0-9+.-]*:[a-z0-9_-]+\/[a-z0-9_.~-]+$/i,t=/^https?:/i,n=/^(mailto|tel):/i,r=/^(?:\/(?![/\\])|#|\?|\.{1,2}\/)/;function i(i,o,s,c){if(s&&(o===`page`||e.test(i))){let e=s(i);if(e!=null)return{kind:`app`,target:e}}return o===`app`?null:r.test(i)?{kind:`page`,href:i}:o===`page`&&!(t.test(i)&&c&&a(i,c))?null:t.test(i)?{kind:c&&a(i,c)?`page`:`web`,href:i}:n.test(i)?{kind:`contact`,href:i}:null}function a(e,t){if(e.slice(0,t.length).toLowerCase()!==t.toLowerCase())return!1;let n=e[t.length];return n===void 0||n===`/`||n===`?`||n===`#`}function o(e){return typeof e!=`string`||!e.startsWith(`/`)||e[1]===`/`||e[1]===`\\`?null:e}export{i as linkTarget,o as webRoute};
1
+ var e=/^[a-z][a-z0-9+.-]*:[a-z0-9_-]+\/[a-z0-9_.~-]+$/i,t=/^https?:/i,n=/^(mailto|tel):/i,r=/^(?:\/(?![/\\])|#|\?|\.{1,2}\/)/,i=/^https:\/\/[^/?#@\\\s]+$/i,a=/^[a-z][a-z0-9+.-]*:/i;function o(e){if(typeof e!=`string`)return null;let t=e.endsWith(`/`)?e.slice(0,-1):e;return i.test(t)?t:null}function s(i,a,s,l,d){if(s&&(a===`page`||e.test(i))){let e=s(i);if(e!=null)return{kind:`app`,target:e}}if(a===`app`)return null;let f=d==null?null:o(d),p=f===null?i:c(i,f);return p===null?null:r.test(p)?{kind:`page`,href:p}:a===`page`&&!(t.test(p)&&l&&u(p,l))?null:t.test(p)?{kind:l&&u(p,l)?`page`:`web`,href:p}:n.test(p)?{kind:`contact`,href:p}:null}function c(e,t){if(a.test(e))return e;if(e.startsWith(`//`))return`https:${e}`;if(e===``)return null;let n=e.indexOf(`#`),r=n<0?``:e.slice(n),i=n<0?e:e.slice(0,n),o=i.indexOf(`?`),s=o<0?i:i.slice(0,o),c=o<0?``:i.slice(o);return s===``?`${t}${c}${r}`:`${t}${l(s.startsWith(`/`)?s:`/${s}`)}${c}${r}`}function l(e){let t=e.split(`/`),n=[];return t.forEach((e,r)=>{let i=r===t.length-1;e===`.`?i&&n.push(``):e===`..`?(n.length>1&&n.pop(),i&&n.push(``)):n.push(e)}),n.join(`/`)}function u(e,t){if(e.slice(0,t.length).toLowerCase()!==t.toLowerCase())return!1;let n=e[t.length];return n===void 0||n===`/`||n===`?`||n===`#`}function d(e){return typeof e!=`string`||!e.startsWith(`/`)||e[1]===`/`||e[1]===`\\`?null:e}export{o as linkBase,s as linkTarget,d as webRoute};
@@ -14,6 +14,7 @@ import "@webority/ui-elements/elements/lightbox";
14
14
  * @param {{ src: string, thumb?: string, alt?: string, caption?: string, name?: string, key?: string }[]} props.items
15
15
  * @param {boolean} [props.download]
16
16
  * @param {string} [props.label]
17
+ * @param {"gallery"|"single"} [props.layout] gallery shows thumbnails; single shows each image at the container's full width, at its own shape.
17
18
  * @param {number} [props.openIndex] Opens the viewer on this image, counted from 0.
18
19
  * @param {(index: number) => void} [props.onChange] Called with the position (from 0) of the
19
20
  * image shown, when the view opens and each time it changes.
@@ -40,6 +41,11 @@ export default function AppLightbox(props: {
40
41
  * @default "Image viewer"
41
42
  */
42
43
  label?: string;
44
+ /**
45
+ * gallery shows thumbnails; single shows each image at the container's full width, at its own shape.
46
+ * @default "gallery"
47
+ */
48
+ layout?: "gallery" | "single";
43
49
  /** Opens the viewer on this image, counted from 0. */
44
50
  openIndex?: number;
45
51
  onChange?: (index: number) => void;
@@ -18,6 +18,7 @@ import "@webority/ui-elements/elements/markdown";
18
18
  * @param {import('react').ElementType} [props.linkComponent] A router link. It receives `to` for an
19
19
  * in-app route. Without it an in-app route renders as a plain anchor.
20
20
  * @param {"app"|"web"|"page"} [props.links] "app" opens only routes from `resolveLink`; "web" (default) also opens web, mail and phone addresses; "page" also opens a relative address and a web address on this site, in the same tab, and asks `resolveLink` for every address; an absolute web address it returns opens in a new tab when it leaves this site.
21
+ * @param {string} [props.base] An https origin such as "https://example.com" that a relative link resolves against, so "/pricing" opens "https://example.com/pricing". Any other value is ignored with a dev warning.
21
22
  * @param {"outline"|"text"} [props.headings] "text" draws a heading as a bold line that stays out of the page outline; "outline" (default) draws an h2.
22
23
  * @param {string} [props.className]
23
24
  */
@@ -37,6 +38,8 @@ export default function AppMarkdown(props: {
37
38
  * @default "web"
38
39
  */
39
40
  links?: "app" | "web" | "page";
41
+ /** An https origin such as https://example.com that a relative link resolves against: /pricing opens https://example.com/pricing. Any other value (a path, a query, credentials, http) is ignored with a dev warning. */
42
+ base?: string;
40
43
  /**
41
44
  * Outline draws a heading as an h2 in the page outline. Text draws it as a bold line that stays out of the outline.
42
45
  * @default "outline"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webority/ui-react",
3
- "version": "0.132.0",
3
+ "version": "0.134.0",
4
4
  "description": "Webority shared React component library — App* primitives on react-bootstrap + the @webority/theme design system.",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "type": "module",
@@ -29,10 +29,10 @@
29
29
  },
30
30
  "sideEffects": false,
31
31
  "dependencies": {
32
- "@webority/markdown-core": "0.132.0",
33
- "@webority/theme": "0.132.0",
34
- "@webority/ui-elements": "0.132.0",
35
- "@webority/web-core": "0.132.0"
32
+ "@webority/markdown-core": "0.134.0",
33
+ "@webority/theme": "0.134.0",
34
+ "@webority/ui-elements": "0.134.0",
35
+ "@webority/web-core": "0.134.0"
36
36
  },
37
37
  "peerDependencies": {
38
38
  "@webority/analytics": "^0.35.0",
@@ -50,8 +50,8 @@
50
50
  "@vitejs/plugin-react": "^6.0.1",
51
51
  "@vitest/coverage-v8": "5.0.1",
52
52
  "@webority/analytics": "0.35.0",
53
- "@webority/canvas-kit": "0.132.0",
54
- "@webority/tokens": "0.132.0",
53
+ "@webority/canvas-kit": "0.134.0",
54
+ "@webority/tokens": "0.134.0",
55
55
  "bootstrap": "5.3.3",
56
56
  "jsdom": "30.1.1",
57
57
  "react": "^19.2.6",