slice-machine-ui 2.7.2-beta.2 → 2.8.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.
Files changed (75) hide show
  1. package/out/404.html +1 -1
  2. package/out/_next/static/NHNPoIm5ZybAGepO-LVh5/_buildManifest.js +1 -0
  3. package/out/_next/static/chunks/{150-84da9b485587e8c4.js → 150-96a0c443c430ec4b.js} +1 -1
  4. package/out/_next/static/chunks/18539003-9b393c900c89e552.js +22 -0
  5. package/out/_next/static/chunks/372-cfee53700e416e09.js +1 -0
  6. package/out/_next/static/chunks/441-76bd8e7cf8cc22da.js +12 -0
  7. package/out/_next/static/chunks/588-d017e0fe2a651a87.js +1 -0
  8. package/out/_next/static/chunks/{918-38ab72e6ee071fec.js → 591-a272f15a4bf9830a.js} +2 -2
  9. package/out/_next/static/chunks/{479-6205c85aa978fc0b.js → 627-092c9e4c99442c08.js} +2 -2
  10. package/out/_next/static/chunks/750-aa35f21031ee1f96.js +1 -0
  11. package/out/_next/static/chunks/{772-58d0c8f8ae1c6791.js → 772-db5f72095641ec1d.js} +1 -1
  12. package/out/_next/static/chunks/{882-1ccb9dbd9bd4734b.js → 882-32959ffa63fa455c.js} +1 -1
  13. package/out/_next/static/chunks/pages/{_app-8405076cd58a41f0.js → _app-51bef5d3c62d085e.js} +156 -154
  14. package/out/_next/static/chunks/pages/{changelog-f9055af0d38a0c24.js → changelog-86f30b15d852e710.js} +1 -1
  15. package/out/_next/static/chunks/pages/changes-6c05ef623617785e.js +1 -0
  16. package/out/_next/static/chunks/pages/custom-types/{[customTypeId]-2eb64c9ea82fcd0a.js → [customTypeId]-fd2416081ef2ffca.js} +1 -1
  17. package/out/_next/static/chunks/pages/{custom-types-ddc20cfdd8049c04.js → custom-types-5de2dd7b9b93236e.js} +1 -1
  18. package/out/_next/static/chunks/pages/{index-17f953c11b46cb20.js → index-2d7f95201a656c12.js} +1 -1
  19. package/out/_next/static/chunks/pages/{labs-867606e5aff179cd.js → labs-81cf5c5f09fa0bda.js} +1 -1
  20. package/out/_next/static/chunks/pages/page-types/{[pageTypeId]-e5a5e6b345081e0a.js → [pageTypeId]-59e143620505f73f.js} +1 -1
  21. package/out/_next/static/chunks/pages/settings-80e0d6f1c79282d3.js +1 -0
  22. package/out/_next/static/chunks/pages/slices/[lib]/[sliceName]/[variation]/{simulator-783b6577bd4e3728.js → simulator-908e779f6d24760d.js} +1 -1
  23. package/out/_next/static/chunks/pages/slices/[lib]/[sliceName]/[variation]-0b6162eb591ee324.js +1 -0
  24. package/out/_next/static/chunks/pages/{slices-0f6e50acfb5957ed.js → slices-317ec2bd3451566e.js} +1 -1
  25. package/out/_next/static/css/{22103e0fe77e9b53.css → 4e475d945cf8a890.css} +1 -1
  26. package/out/_next/static/css/850c81be38195a0f.css +1 -0
  27. package/out/_next/static/css/{00e9fba6d8022425.css → 9d17b7d9f44c5c5d.css} +1 -1
  28. package/out/_next/static/css/{cc20f7c46912c5dc.css → e5c7f63f02ff4d0f.css} +1 -1
  29. package/out/_next/static/css/{7f2ebc8f03a13272.css → e5f781f20e24a5ea.css} +1 -1
  30. package/out/changelog.html +1 -1
  31. package/out/changes.html +1 -1
  32. package/out/custom-types/[customTypeId].html +1 -1
  33. package/out/custom-types.html +1 -1
  34. package/out/index.html +1 -1
  35. package/out/labs.html +1 -1
  36. package/out/page-types/[pageTypeId].html +1 -1
  37. package/out/settings.html +1 -1
  38. package/out/slices/[lib]/[sliceName]/[variation]/simulator.html +1 -1
  39. package/out/slices/[lib]/[sliceName]/[variation].html +1 -1
  40. package/out/slices.html +1 -1
  41. package/package.json +9 -10
  42. package/src/components/BlankSlate/BlankSlate.module.css +0 -10
  43. package/src/components/BlankSlate/BlankSlate.module.css.d.ts +0 -1
  44. package/src/components/BlankSlate/BlankSlate.tsx +2 -2
  45. package/src/components/Breadcrumb/Breadcrumb.module.css +0 -4
  46. package/src/components/Breadcrumb/Breadcrumb.module.css.d.ts +0 -1
  47. package/src/components/Breadcrumb/Breadcrumb.tsx +1 -2
  48. package/src/components/ContentTabs/ContentTabs.tsx +2 -1
  49. package/src/components/FieldSet/FieldSet.module.css +0 -8
  50. package/src/components/FieldSet/FieldSet.module.css.d.ts +0 -2
  51. package/src/components/FieldSet/FieldSet.tsx +2 -7
  52. package/src/components/SideNav/SideNavEnvironmentSelector.tsx +2 -1
  53. package/src/features/builder/AddFieldDropdown.tsx +1 -1
  54. package/src/features/documentation/MarkdownRenderer/index.tsx +4 -2
  55. package/src/features/onboarding/OnboardingProgressStepper.tsx +2 -1
  56. package/src/features/sync/components/AutoSyncStatusIndicator.tsx +5 -1
  57. package/src/legacy/lib/builders/CustomTypeBuilder/TabZone/index.tsx +3 -0
  58. package/src/legacy/lib/builders/SliceBuilder/FieldZones/index.tsx +3 -0
  59. package/src/legacy/lib/models/common/widgets/Group/ListItem/index.jsx +3 -0
  60. package/src/legacy/lib/models/common/widgets/Link/Form.jsx +43 -3
  61. package/src/legacy/lib/models/common/widgets/Link/components.tsx +56 -0
  62. package/src/legacy/lib/models/common/widgets/Link/index.ts +8 -3
  63. package/src/legacy/lib/models/common/widgets/LinkToMedia/Form.jsx +14 -1
  64. package/src/legacy/lib/models/common/widgets/LinkToMedia/index.ts +1 -0
  65. package/out/_next/static/E30Hv5Nt7vNi3zj5fcpLn/_buildManifest.js +0 -1
  66. package/out/_next/static/chunks/18539003-080f6b8eec027936.js +0 -22
  67. package/out/_next/static/chunks/372-a86e2c479a721702.js +0 -1
  68. package/out/_next/static/chunks/441-126d623f1b578785.js +0 -12
  69. package/out/_next/static/chunks/50-586dc7ab5e584e76.js +0 -1
  70. package/out/_next/static/chunks/764-e040bcebe6027fea.js +0 -1
  71. package/out/_next/static/chunks/pages/changes-72a49635f1ee5057.js +0 -1
  72. package/out/_next/static/chunks/pages/settings-0edb6f6c78439c20.js +0 -1
  73. package/out/_next/static/chunks/pages/slices/[lib]/[sliceName]/[variation]-68074c174d83cf1e.js +0 -1
  74. package/out/_next/static/css/34067e4b880866ca.css +0 -1
  75. /package/out/_next/static/{E30Hv5Nt7vNi3zj5fcpLn → NHNPoIm5ZybAGepO-LVh5}/_ssgManifest.js +0 -0
@@ -0,0 +1 @@
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[372],{28574:function(e,t,n){"use strict";n.d(t,{R$:function(){return s},Qj:function(){return f},T9:function(){return u},nf:function(){return m},u2:function(){return c},_T:function(){return d}});var r=n(52322),o=n(38392),i=n(6277),l=n(43217),a=n.n(l);let s=e=>{let{backgroundImage:t,style:n,...o}=e,l=void 0!==t;return(0,r.jsx)("article",{...o,className:(0,i.W)(a().root,{[a().withBackground]:l}),style:{backgroundImage:l?"url(".concat(t,")"):void 0,...n}})},c=e=>(0,r.jsx)("div",{...e,className:a().image}),u=e=>(0,r.jsx)("div",{...e,className:a().content}),d=e=>(0,r.jsx)(o.xv,{...e,variant:"h3"}),m=e=>(0,r.jsx)(o.xv,{...e,color:"grey11"}),f=e=>(0,r.jsx)("div",{...e,className:a().actions,color:"grey"})},93216:function(e,t,n){"use strict";n.d(t,{AK:function(){return v},E3:function(){return m},EN:function(){return f},F$:function(){return y},H8:function(){return S},HO:function(){return h},L4:function(){return g},N3:function(){return c},Tr:function(){return d},Ue:function(){return I},eK:function(){return k},gR:function(){return b},j5:function(){return s},mf:function(){return p},vB:function(){return x},xS:function(){return j},y6:function(){return i}});var r=n(98863),o=n(88866);function i(e){var t;return null!==(t=e.format)&&void 0!==t?t:"custom"}function l(e){return Object.entries(e.json)}function a(e){return l(e).find(e=>{let[t,n]=e;return Object.values(n).some(e=>"UID"===e.type)})}function s(e){var t;let[n,r]=null!==(t=a(e))&&void 0!==t?t:[];return Object.entries(null!=r?r:{}).find(e=>{let[t,n]=e;return"UID"===n.type})}function c(e){var t,n;return null!==(n=null==e?void 0:null===(t=e.config)||void 0===t?void 0:t.label)&&void 0!==n?n:void 0}function u(e,t){let n=e.json[t];if(void 0!==n)return Object.entries(n).find(e=>{let[t,n]=e;return n.type===o.SlicesFieldType})}function d(e,t){if(function(e,t){var n;let r=u(e,t),[o,i]=null!=r?r:[];return null!==(n=null==i?void 0:i.config)&&void 0!==n?n:void 0}(e,t))return e;let n=function(e,t){let n;let r=l(e),i=r.findIndex(e=>{let[n]=e;return n===t}),a=r.flatMap(e=>{let[t,n]=e;return Object.keys(n).filter(e=>n[e].type===o.SlicesFieldType)}),s=i;do n="slices".concat(0!==s?s.toString():""),s++;while(a.includes(n));return n}(e,t);return{...e,json:{...e.json,[t]:{...e.json[t],[n]:{type:o.SlicesFieldType,fieldset:"Slice Zone"}}}}}function m(e,t){let n=e.json[t];if(void 0===n)return e;let i=Object.keys(n).find(e=>n[e].type===o.SlicesFieldType);if(void 0===i)return e;let l=(0,r.ud)(n,i);return{...e,json:{...e.json,[t]:l}}}function f(e){var t,n;let{customType:i,sectionId:l,sliceId:a}=e,s=i.json[l];if(void 0===s)return i;let c=Object.keys(s).find(e=>s[e].type===o.SlicesFieldType);if(void 0===c)return i;let u=s[c];if(u.type!==o.SlicesFieldType)return i;let d=(0,r.ud)(null!==(n=null===(t=u.config)||void 0===t?void 0:t.choices)&&void 0!==n?n:{},a);return{...i,json:{...i.json,[l]:{...s,[c]:{...u,config:{...u.config,choices:d}}}}}}function p(e){let t={...e,format:"page"},n=l(e)[0];if(n){let[e]=n;t=d(t,e)}return t}function x(e,t){return{...e,json:{...e.json,[t]:{}}}}function y(e,t){let n=(0,r.ud)(e.json,t);return{...e,json:n}}function h(e,t,n){if(t===n)return e;let r=Object.keys(e.json).reduce((r,o)=>(o===t?r[n]=e.json[o]:r[o]=e.json[o],r),{});return{...e,json:r}}function j(e){let{customType:t,sectionId:n,newField:r,newFieldId:i}=e,l=t.json[n],a=u(t,n),s={...Object.fromEntries(Object.entries(l).filter(e=>{let[t,n]=e;return n.type!==o.SlicesFieldType})),[i]:r};if(void 0!==a){let[e,t]=a;s[e]=t}return _({customType:t,sectionId:n,updatedSection:s})}function v(e){let{customType:t,sectionId:n,fieldId:o}=e,i=(0,r.ud)(t.json[n],o);return _({customType:t,sectionId:n,updatedSection:i})}function g(e){let{customType:t,sectionId:n,previousFieldId:r,newFieldId:o,newField:i}=e,l=C({fields:t.json[n],previousFieldId:r,newFieldId:o,newField:i});return _({customType:t,sectionId:n,updatedSection:l})}function b(e){let{customType:t,sectionId:n,sourceIndex:r,destinationIndex:i}=e,l=t.json[n],a=u(t,n),s=function(e){let{fields:t,sourceIndex:n,destinationIndex:r}=e,o=Object.entries(t),[i]=o.splice(n,1);return o.splice(r,0,i),Object.fromEntries(o)}({fields:Object.fromEntries(Object.entries(l).filter(e=>{let[t,n]=e;return n.type!==o.SlicesFieldType})),sourceIndex:r,destinationIndex:i});if(void 0!==a){let[e,t]=a;s[e]=t}return _({customType:t,sectionId:n,updatedSection:s})}function S(e,t){let n=l(t)[0],[r]=null!=n?n:[];return void 0===r?t:j({customType:t,sectionId:r,newField:{type:"UID",config:{label:e}},newFieldId:"uid"})}function k(e,t){var n,r;let[o]=null!==(n=a(t))&&void 0!==n?n:[],[i,l]=null!==(r=s(t))&&void 0!==r?r:[];if(!l||void 0===i||void 0===o)return t;let c=C({fields:t.json[o],previousFieldId:i,newFieldId:i,newField:{...l,config:{...l.config,label:e}}});return _({customType:t,sectionId:o,updatedSection:c})}function _(e){let{customType:t,sectionId:n,updatedSection:r}=e;return{...t,json:{...t.json,[n]:r}}}function C(e){let{fields:t,previousFieldId:n,newFieldId:r,newField:o}=e;return Object.entries(t).reduce((e,t)=>{let[i,l]=t;return i===n?e[r]=o:i!==r&&(e[i]=l),e},{})}function I(e){let{id:t,label:n,repeatable:r,format:o}=e,i=!1===r&&"page"===o?{...T,...B}:!1===r?w:"page"===o?{...F,...B}:O;return{format:o,id:t,json:i,label:n,repeatable:r,status:!0}}let w={Main:{}},T={Main:{slices:{config:{choices:{}},fieldset:"Slice Zone",type:"Slices"}}},O={Main:{uid:{type:"UID",config:{label:"UID"}}}},F={Main:{...O.Main,...T.Main}},B={"SEO & Metadata":{meta_title:{config:{label:"Meta Title",placeholder:"A title of the page used for social media and search engines"},type:"Text"},meta_description:{config:{label:"Meta Description",placeholder:"A brief summary of the page"},type:"Text"},meta_image:{config:{constraint:{height:1260,width:2400},label:"Meta Image",thumbnails:[]},type:"Image"}}}},64910:function(e,t,n){"use strict";n.d(t,{_:function(){return F}});var r=n(52322),o=n(38392),i=n(5632),l=n(2784),a=n(65186),s=n(59326),c=n(75289),u=n(88932),d=n(70647),m=n(77507);async function f(e){let{customType:t,onSuccess:n}=e,r=m.$[t.format];try{let{errors:e}=await d.j.customTypes.deleteCustomType({id:t.id});if(e.length>0)throw e;n(),u.Am.success("".concat(r.name({start:!0,plural:!1})," deleted"))}catch(t){let e="Internal Error: ".concat(r.name({start:!0,plural:!1})," could not be deleted");console.error(e,t),u.Am.error(e)}}var p=n(47861),x=n(76805),y=n(11104),h=n(41067);let j=e=>{let{customType:t,format:n,onClose:o,onDeleteCustomTypeSuccess:i}=e,u=m.$[n],[d,j]=(0,l.useState)(!1),{deleteCustomTypeSuccess:v}=(0,h.Z)(),g=async()=>{j(!0),await f({customType:t,onSuccess:()=>v(t.id)}),i()},{theme:b}=(0,s.B7)();return(0,r.jsx)(y.Z,{isOpen:!0,shouldCloseOnOverlayClick:!0,style:{content:{maxWidth:612}},onRequestClose:()=>o(),children:(0,r.jsx)(x.Z,{bodySx:{p:0,bg:"white",position:"relative",height:"100%",padding:16},footerSx:{position:"sticky",bottom:0,p:0},sx:{border:"none",overflow:"hidden"},borderFooter:!0,Header:()=>{var e;return(0,r.jsxs)(c.kC,{sx:{position:"sticky",top:0,zIndex:1,p:"16px",alignItems:"center",justifyContent:"space-between",borderBottom:e=>{var t;return"1px solid ".concat(String(null===(t=e.colors)||void 0===t?void 0:t.borders))}},children:[(0,r.jsxs)(c.kC,{sx:{alignItems:"center"},children:[(0,r.jsx)(a.$vK,{size:20,color:null===(e=b.colors)||void 0===e?void 0:e.greyIcon}),(0,r.jsxs)(c.X6,{sx:{fontSize:"14px",fontWeight:"bold",ml:1},children:["Delete"," ",u.name({start:!1,plural:!1})]})]}),(0,r.jsx)(c.x8,{type:"button",onClick:()=>o()})]})},Footer:()=>(0,r.jsxs)(c.kC,{sx:{justifyContent:"flex-end",height:64,alignItems:"center",paddingRight:16,borderTop:e=>{var t;return"1px solid ".concat(String(null===(t=e.colors)||void 0===t?void 0:t.darkBorders))},backgroundColor:"gray"},children:[(0,r.jsx)(p.z,{label:"Cancel",variant:"secondary",onClick:()=>o(),sx:{mr:"10px",fontWeight:"bold",color:"grey12",borderRadius:6}}),void 0!==t&&(0,r.jsx)(p.z,{label:"Delete",variant:"danger",isLoading:d,onClick:()=>void g(),sx:{minHeight:39,minWidth:78}})]}),children:(0,r.jsxs)("div",{children:["This action will immediately make the following change:",(0,r.jsx)("ul",{children:(0,r.jsxs)("li",{children:["Delete the"," ",(0,r.jsxs)(c.xv,{sx:{fontWeight:"bold"},children:["customtypes/",null==t?void 0:t.id,"/"]})," ","directory."]})}),"The next time you push your changes to Prismic, the following change will happen:",(0,r.jsx)("ul",{children:(0,r.jsxs)("li",{children:["Remove the"," ",u.name({start:!1,plural:!1})," and any associated Documents from your repository."]})})]})})})};var v=n(56580);async function g(e){let{model:t,newLabel:n,onSuccess:r}=e,o=m.$[t.format];try{let e={...t,label:n},{errors:i}=await d.j.customTypes.renameCustomType({model:e});if(i.length>0)throw i;r(e),u.Am.success("".concat(o.name({start:!0,plural:!1})," renamed"))}catch(t){let e="Internal Error: ".concat(o.name({start:!0,plural:!1})," could not be renamed");console.error(e,t),u.Am.error(e)}}var b=n(80546),S=n(40572),k=n(1490),_=n(28801);let C=e=>{var t,n;let{isChangesLocal:o,customType:i,format:a,onClose:s,setLocalCustomType:u}=e,d=null!==(t=null==i?void 0:i.label)&&void 0!==t?t:"",f=null!==(n=null==i?void 0:i.id)&&void 0!==n?n:"",{renameCustomTypeSuccess:p}=(0,h.Z)(),{syncChanges:x}=(0,b.g)(),[y,j]=(0,l.useState)(!1),C=async e=>{j(!0),o&&u?u({...i,label:e.customTypeName}):await g({model:i,newLabel:e.customTypeName,onSuccess:e=>{p(e),x()}}),j(!1),s()},{customTypeLabels:I}=(0,v.v9)(e=>({customTypeLabels:(0,S.YS)(e)})),w=m.$[a];return(0,r.jsx)(k.Z,{isOpen:!0,testId:"rename-custom-type-modal",widthInPx:"530px",formId:"rename-custom-type-modal-".concat(f),buttonLabel:"Rename",close:s,onSubmit:e=>void C(e),initialValues:{customTypeName:d},isLoading:y,content:{title:"Rename a ".concat(w.name({start:!1,plural:!1}))},validate:e=>{let{customTypeName:t}=e,n={};return t&&t.length||(n.customTypeName="Cannot be empty."),void 0!=n.customTypeName&&I.includes(t)&&d!==t&&(n.customTypeName="".concat(w.name({start:!0,plural:!1})," name is already taken.")),Object.keys(n).length>0?n:void 0},children:e=>{let{errors:t}=e;return(0,r.jsx)(c.xu,{children:(0,r.jsx)(_.W,{name:"customTypeName",label:"".concat(w.name({start:!0,plural:!1})," Name"),placeholder:"A display name for the ".concat(w.name({start:!1,plural:!1})),error:t.customTypeName,testId:"custom-type-name-input"})})}})};var I=n(93188),w=n(93216);async function T(e,t){let n=m.$[e.format];try{let r=(0,w.mf)(e),{errors:o}=await (0,I.KA)(r);if(o.length>0)throw o;t(r),u.Am.success("".concat(n.name({start:!0,plural:!1})," converted to page type"))}catch(t){let e="Internal Error: ".concat(n.name({start:!0,plural:!1})," not converted to page type");console.error(e,t),u.Am.error(e)}}var O=n(63447);let F=e=>{let{format:t,customType:n,isChangesLocal:a,setLocalCustomType:s}=e,c=(0,i.useRouter)(),{saveCustomTypeSuccess:u}=(0,h.Z)(),[d,m]=(0,l.useState)(!1),[f,p]=(0,l.useState)(!1),[x,y]=(0,l.useState)(!1),v=async()=>{y(!0),await T(n,u);let e=O.cd.custom.getBuilderPagePathname(n.id);if(c.asPath===e){let e=O.cd.page.getBuilderPagePathname(n.id);c.replace(e),y(!1)}else y(!1)};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(o.h_,{modal:!0,children:[(0,r.jsx)(o.$F,{disabled:x,children:(0,r.jsx)(o.hU,{color:"grey","data-testid":"editDropdown",hiddenLabel:"Custom type actions",icon:"moreVert",loading:x,variant:"solid"})}),(0,r.jsxs)(o.AW,{align:"end",children:[(0,r.jsx)(o.Xi,{startIcon:(0,r.jsx)(o.I5,{name:"edit"}),onSelect:()=>{p(!0)},children:"Rename"}),"custom"===t&&!a&&(0,r.jsx)(o.Xi,{startIcon:(0,r.jsx)(o.I5,{name:"driveFileMove"}),onSelect:()=>void v(),children:"Convert to page type"}),(0,r.jsx)(o.Xi,{color:"tomato",startIcon:(0,r.jsx)(o.I5,{name:"delete"}),onSelect:()=>{m(!0)},children:"Remove"})]})]}),d?(0,r.jsx)(j,{format:t,customType:n,onClose:()=>m(!1),onDeleteCustomTypeSuccess:()=>{var e;let{tablePagePathname:t}=O.cd[null!==(e=n.format)&&void 0!==e?e:"custom"];c.asPath!==t?c.replace(t):m(!1)}}):null,f?(0,r.jsx)(C,{format:t,customType:n,isChangesLocal:a,onClose:()=>p(!1),setLocalCustomType:s}):null]})}},47861:function(e,t,n){"use strict";n.d(t,{z:function(){return s}});var r=n(52322),o=n(2784),i=n(75289);let l=(e,t)=>e?"".concat(e,"-").concat(t):"",a=e=>{switch(e){case"white":case"secondaryMedium":case"secondarySmall":case"secondary":return"#1A1523";default:return"grey01"}},s=(0,o.forwardRef)((e,t)=>{let{label:n,Icon:o,type:s,form:c,isLoading:u=!1,disabled:d=!1,onClick:m,sx:f={},iconSize:p=16,iconFill:x,variant:y="primary",...h}=e;return(0,r.jsx)(i.zx,{ref:t,sx:{...f,display:"flex",alignItems:"center",justifyContent:"center",gap:"8px",...u?{cursor:"wait !important"}:{}},type:s,form:c,disabled:d||u,onClick:u?void 0:m,variant:y,...h,children:u?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(i.$j,{size:p,color:a(y),"data-testid":l(h["data-testid"],"spinner")}),o&&n]}):(0,r.jsxs)(r.Fragment,{children:[o&&(0,r.jsx)(o,{size:p,fill:x,"data-testid":l(h["data-testid"],"icon")}),n]})})})},28801:function(e,t,n){"use strict";n.d(t,{W:function(){return l}});var r=n(52322),o=n(63397);n(2784);var i=n(75289);let l=e=>{let{name:t,label:n,placeholder:l,error:a,testId:s,onChange:c}=e;return(0,r.jsxs)(i.xu,{mb:3,children:[(0,r.jsx)(i.__,{htmlFor:t,mb:2,children:n}),(0,r.jsx)(o.gN,{name:t,type:"text",placeholder:l,as:i.II,autoComplete:"off",...c?{onChange:c}:null,...s?{"data-testid":s}:null}),a?(0,r.jsx)(i.xv,{"data-testid":s?"".concat(s,"-error"):"input-error",sx:{color:"error",mt:1},children:a}):null]})}},1490:function(e,t,n){"use strict";var r=n(52322),o=n(63397),i=n(37149),l=n.n(i),a=n(75289),s=n(47861),c=n(11104),u=n(76805);t.Z=function(e){let{children:t,close:n,isOpen:i,formId:d,validate:m,onSubmit:f,widthInPx:p,initialValues:x,content:{title:y},cardProps:h,omitFooter:j=!1,isLoading:v=!1,buttonLabel:g="Save",testId:b,actionMessage:S}=e;return l().setAppElement("#__next"),(0,r.jsx)(c.Z,{isOpen:i,shouldCloseOnOverlayClick:!0,onRequestClose:n,contentLabel:y,style:{content:{width:null!=p?p:"900px"}},children:(0,r.jsx)(o.J9,{initialValues:x,validate:e=>m?m(e):void 0,onSubmit:e=>{f(e)},children:e=>{let{isValid:i,isSubmitting:l,values:c,errors:m,touched:f,setFieldValue:p,setValues:x}=e;return(0,r.jsx)(o.l0,{id:d,...null!=b?{"data-testid":b}:null,children:(0,r.jsx)(u.Z,{borderFooter:!0,footerSx:{p:3,position:"sticky",bottom:0,background:"gray"},bodySx:{px:4,py:4},sx:{border:"none"},...h,Header:e=>{let{radius:t}=e;return(0,r.jsxs)(a.kC,{sx:{position:"sticky",top:0,zIndex:1,p:"16px",pl:4,bg:"headSection",alignItems:"center",justifyContent:"space-between",borderTopLeftRadius:t,borderTopRightRadius:t,borderBottom:e=>{var t;return"1px solid ".concat(null===(t=e.colors)||void 0===t?void 0:t.borders)}},children:[(0,r.jsx)(a.X6,{sx:{fontSize:"20px"},children:y}),(0,r.jsx)(a.x8,{type:"button",onClick:n})]})},Footer:j?null:(0,r.jsxs)(a.kC,{sx:{alignItems:"space-between"},children:[(0,r.jsx)(a.kC,{sx:{fontSize:"14px",alignItems:"center"},children:"function"==typeof S?S(e):S}),(0,r.jsxs)(a.kC,{sx:{ml:"auto"},children:[(0,r.jsx)(a.zx,{mr:2,type:"button",onClick:n,variant:"secondary",disabled:l||v,children:"Cancel"}),(0,r.jsx)(s.z,{label:g,form:d,type:"submit",disabled:!i||l||v,isLoading:l||v,sx:{fontWeight:"400",paddingBlock:"8px",paddingInline:"16px",fontSize:"14px",borderRadius:"4px"}})]})]}),children:t({isValid:i,isSubmitting:l,values:c,errors:m,touched:f,setFieldValue:p,setValues:x})})})}})})}},43217:function(e){e.exports={column:"BlankSlate_column__genEe",root:"BlankSlate_root__CmSqW BlankSlate_column__genEe",fadeIn:"BlankSlate_fadeIn__mAfi5",withBackground:"BlankSlate_withBackground__mLYij",image:"BlankSlate_image__Jn90S BlankSlate_column__genEe",content:"BlankSlate_content__0Yt2d BlankSlate_column__genEe",desc:"BlankSlate_desc___Dl7e",actions:"BlankSlate_actions__OYRj4"}}}]);