PageSourceSearch

https://younified.ca/_next/static/chunks/pages/create-blog-99e34d8772dbf4a7.js

js younified.ca collected 2026-10-10 00:58:11 UTC 13,010 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4568],{35573:function(e,t,n){var i=n(15787).w_;e.exports.Y=function(e){return i({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M864 256H736v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zm-200 0H360v-72h304v72z"}}]})(e)}},42339:function(e,t,n){var i=n(15787).w_;e.exports.Q=function(e){return i({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M880 836H144c-17.7 0-32 14.3-32 32v36c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-36c0-17.7-14.3-32-32-32zm-622.3-84c2 0 4-.2 6-.5L431.9 722c2-.4 3.9-1.3 5.3-2.8l423.9-423.9a9.96 9.96 0 0 0 0-14.1L694.9 114.9c-1.9-1.9-4.4-2.9-7.1-2.9s-5.2 1-7.1 2.9L256.8 538.8c-1.5 1.5-2.4 3.3-2.8 5.3l-29.5 168.2a33.5 33.5 0 0 0 9.4 29.8c6.6 6.4 14.9 9.9 23.8 9.9z"}}]})(e)}},55815:function(e,t,n){var i=n(15787).w_;e.exports.p=function(e){return i({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M908.1 353.1l-253.9-36.9L540.7 86.1c-3.1-6.3-8.2-11.4-14.5-14.5-15.8-7.8-35-1.3-42.9 14.5L369.8 316.2l-253.9 36.9c-7 1-13.4 4.3-18.3 9.3a32.05 32.05 0 0 0 .6 45.3l183.7 179.1-43.4 252.9a31.95 31.95 0 0 0 46.4 33.7L512 754l227.1 119.4c6.2 3.3 13.4 4.4 20.3 3.2 17.4-3 29.1-19.5 26.1-36.9l-43.4-252.9 183.7-179.1c5-4.9 8.3-11.3 9.3-18.3 2.7-17.5-9.5-33.7-27-36.3z"}}]})(e)}},51692:function(e,t,n){var i=n(15787).w_;e.exports.y=function(e){return i({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M908.1 353.1l-253.9-36.9L540.7 86.1c-3.1-6.3-8.2-11.4-14.5-14.5-15.8-7.8-35-1.3-42.9 14.5L369.8 316.2l-253.9 36.9c-7 1-13.4 4.3-18.3 9.3a32.05 32.05 0 0 0 .6 45.3l183.7 179.1-43.4 252.9a31.95 31.95 0 0 0 46.4 33.7L512 754l227.1 119.4c6.2 3.3 13.4 4.4 20.3 3.2 17.4-3 29.1-19.5 26.1-36.9l-43.4-252.9 183.7-179.1c5-4.9 8.3-11.3 9.3-18.3 2.7-17.5-9.5-33.7-27-36.3zM664.8 561.6l36.1 210.3L512 672.7 323.1 772l36.1-210.3-152.8-149L417.6 382 512 190.7 606.4 382l211.2 30.7-152.8 148.9z"}}]})(e)}},68056:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/create-blog",function(){return n(78973)}])},57680:function(e,t,n){"use strict";n.d(t,{Br:function(){return d},Vr:function(){return s},eE:function(){return u},ri:function(){return f}});var i=n(17283);function r(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}function o(){var e=r(["\n  mutation createBlogPost(\n    $unionID: UnifiedID!\n    $input: BlogInput!\n    $images: [Upload]\n  ) {\n    createBlogPost(unionID: $unionID, input: $input, images: $images)\n  }\n"]);return o=function(){return e},e}function c(){var e=r(["\n  mutation deleteBlogPost($unionID: UnifiedID!, $blogID: UnifiedID!) {\n    deleteBlogPost(unionID: $unionID, blogID: $blogID)\n  }\n"]);return c=function(){return e},e}function a(){var e=r(["\n  mutation makeFeature(\n    $unionID: UnifiedID!\n    $blogID: UnifiedID!\n    $featured: Boolean!\n  ) {\n    makeFeature(unionID: $unionID, blogID: $blogID, featured: $featured)\n  }\n"]);return a=function(){return e},e}function l(){var e=r(["\n  mutation editBlogPost(\n    $unionID: UnifiedID!\n    $blogID: UnifiedID!\n    $input: BlogInput!\n  ) {\n    editBlogPost(unionID: $unionID, blogID: $blogID, input: $input)\n  }\n"]);return l=function(){return e},e}var s=(0,i.Ps)(o()),u=(0,i.Ps)(c()),d=(0,i.Ps)(a()),f=(0,i.Ps)(l())},45854:function(e,t,n){"use strict";n.d(t,{No:function(){return r},dX:function(){return o},eC:function(){return c},xC:function(){return i}});var i={image:5e5,video:1e8,pdf:2e6},r=1e7,o=5e6,c=5e6},78973:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return F}});var i=n(85893),r=n(67294),o=n(34051),c=n.n(o),a=n(79547),l=n.n(a),s=n(5152),u=n.n(s),d=n(11163),f=n(30381),b=n.n(f),x=n(88065),p=n(2579),m=n(59932),g=n(81651),h=n(58474),v=n(78695),j=n(24961),w=n(55815),y=n(51692),k=n(35573),I=n(42339),D=n(45854),z=n(46912),B=n(57680),N=n(30111),C=n(71641),P=n(50319),$=n(22920);function S(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function _(e,t,n,i,r,o,c){try{var a=e[o](c),l=a.value}catch(s){return void n(s)}a.done?t(l):Promise.resolve(l).then(i,r)}function E(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i,r,o=[],c=!0,a=!1;try{for(n=n.call(e);!(c=(i=n.next()).done)&&(o.push(i.value),!t||o.length!==t);c=!0);}catch(l){a=!0,r=l}finally{try{c||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e,t)||function(e,t){if(!e)return;if("string"===typeof e)return S(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return S(e,t)}
1(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var L=u()((function(){return Promise.all([n.e(2937),n.e(939),n.e(1167)]).then(n.t.bind(n,71167,23))}),{loadableGenerated:{webpack:function(){return[71167]}},ssr:!1,loading:function(){return(0,i.jsx)(x.Z,{})}}),T={toolbar:[[{header:"1"},{header:"2"},{font:[]}],[{size:[]}],["bold","italic","underline"],[{list:"ordered"},{list:"bullet"},{indent:"-1"},{indent:"+1"}],["link","image","video"]],clipboard:{matchVisual:!1}},M=["header","font","size","bold","italic","underline","list","bullet","indent","link","image","video"],U=function(){var e=(0,r.useState)(""),t=e[0],n=e[1],o=(0,r.useState)(""),a=o[0],s=o[1],u=(0,r.useState)(!1),f=u[0],x=u[1],S=(0,r.useState)(""),U=S[0],F=S[1],O=(0,r.useState)(""),A=O[0],H=O[1],Y=(0,r.useState)([]),Z=Y[0],V=Y[1],X=(0,d.useRouter)(),G=(0,z.mF)(),Q=(0,C.a)(N.m),q=Q.data,R=Q.refetch,W=E((0,P.D)(B.Vr,{onCompleted:function(){ne(),R()},onError:function(e){console.error("Blog Creation Error",e)}}),2),J=W[0],K=W[1].loading,ee=E((0,P.D)(B.eE,{onCompleted:function(){R()},onError:function(e){console.error("Blog Deletion Error",e)}}),1)[0],te=E((0,P.D)(B.Br,{onCompleted:function(){R()},onError:function(e){console.error("Blog Feature Toggle Error",e)}}),1)[0],ne=function(){n(""),s(""),x(!1),F(""),V([])};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(p.Z,{title:"Create a Blog"}),(0,i.jsx)("p",{className:"jsx-c1b2361d98acfbc5 description",children:"This post will be available on the homepage of the public website. You can add and remove posts on this page."}),(0,i.jsxs)("section",{className:"jsx-c1b2361d98acfbc5 body",children:[!!A&&(0,i.jsx)("p",{className:"jsx-c1b2361d98acfbc5",children:A}),(0,i.jsxs)("div",{className:"jsx-c1b2361d98acfbc5 inputs",children:[(0,i.jsxs)("div",{className:"jsx-c1b2361d98acfbc5 switchContainer",children:[(0,i.jsx)("p",{className:"jsx-c1b2361d98acfbc5",children:"Featured"}),(0,i.jsx)(v.rs,{color:"primary",checked:f,onChange:function(e){x(e.target.checked)}})]}),(0,i.jsx)(h.GV,{files:Z,setFiles:V}),(0,i.jsx)(g.pr,{accept:"image/png, image/jpeg, image/jpg",inputID:"blog-image-file-input",files:Z,setFiles:V,maxSize:D.eC})]}),(0,i.jsx)(g.oi,{value:t,setState:function(e){return n(e)},label:"Title",style:{width:"85%"}}),(0,i.jsx)(g.oi,{value:a,setState:function(e){return s(e)},label:"Subtitle",style:{width:"85%"}}),(0,i.jsx)(L,{style:{height:"32rem",width:"85%",fontWeight:"normal",margin:"1rem 0 4rem"},value:U,modules:T,formats:M,onChange:function(){var e,t=(e=c().mark((function e(t){return c().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:F(t);case 1:case"end":return e.stop()}}),e)})),function(){var t=this,n=arguments;return new Promise((function(i,r){var o=e.apply(t,n);function c(e){_(o,i,r,c,a,"next",e)}function a(e){_(o,i,r,c,a,"throw",e)}c(void 0)}))});return function(e){return t.apply(this,arguments)}}()}),K?(0,i.jsx)($.Z,{style:{marginTop:"3rem"}}):(0,i.jsxs)("div",{className:"jsx-c1b2361d98acfbc5 buttonContainer",children:[(0,i.jsx)(m.Z,{func:function(){return ne()},children:"Clear"}),(0,i.jsx)(m.Z,{func:function(){return function(){if(U&&t){var e={header:t,subHeader:a,content:U,featured:f};J({variables:{unionID:G.id,input:e,images:Z}}),H("")}else H("Please provide a title and the content of the blog post"),window.scrollTo(0,0)}()},children:"Post"})]})]}),q&&!!q.getBlogPosts&&q.getBlogPosts.length&&(0,i.jsxs)("section",{className:"jsx-c1b2361d98acfbc5 allPosts",children:[(0,i.jsx)("h2",{className:"jsx-c1b2361d98acfbc5 sectionTitle",children:"All Posts"}),(0,i.jsx)("div",{className:"jsx-c1b2361d98acfbc5 postContainer",children:q.getBlogPosts.map((function(e){var t=b()(e.createdOn).format("MMMM Do, YYYY");return(0,i.jsxs)("div",{className:"jsx-c1b2361d98acfbc5 post",children:[(0,i.jsx)("div",{className:"jsx-c1b2361d98acfbc5 featureBtn",children:(0,i.jsx)(j.Lg,{color:"primary","aria-label":"featured",onClick:function(){return t=!e.featured,n=e.id,void te({variables:{unionID:G.id,blogID:n,featured:t}});var t,n},children:e.featured?(0,i.jsx)(w.p,{fontSize:"large"}):(0,i.jsx)(y.y,{fontSize:"large"})})}),(0,i.jsx)("div",{className:"jsx-c1b2361d98acfbc5 deleteBtn",children:(0,i.jsx)(j.Lg,{color:"secondary","aria-label":"delete",onClick:function(){return t=e.id,void ee({variables:{unionID:G.id,blogID:t}});var t},children:(0,i.jsx)(k.Y,{fontSize:"large"})})}),(0,i.jsx)("div",{className:"jsx-c1b2361d98acfbc5 editBtn",children:(0,i.jsx)(j.Lg,{color:"default","aria-label":"edit",onClick:function(){X.push({pathname:"/edit-blog",query:{id:e.id}}).then((function(){return window.scrollTo(0,0)}))},children:(0,i.jsx)(I.Q,{fontSize:"large"})})}),(0,i.jsx)("div",{className:"jsx-c1b2361d98acfbc5 postImg",children:(0,i.jsx)("img",{src:e.images?e.images[0]:"/img-placeholder.jpg",className:"jsx-c1b2361d98acfbc5"})}),(0,i.jsx)("h3",{className:"jsx-c1b2361d98acfbc5 header",children:e.header}),(0,i.jsx)("p",{className:"jsx-c1b2361d98acfbc5 date",children:t})]},e.id)}))})]}),(0,i.jsx)(l(),{id:"c1b2361d98acfbc5",children:"img.jsx-c1b2361d98acfbc5{height:auto;width:100%;-o-object-fit:cover;object-fit:cover}.body.jsx-c1b2361d98acfbc5{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-moz-box-orient:vertical;-moz-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-pack:center;
1-webkit-justify-content:center;-moz-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;margin:5rem 0 10rem 0}.buttonContainer.jsx-c1b2361d98acfbc5{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;width:85%;-webkit-box-pack:space-evenly;-webkit-justify-content:space-evenly;-moz-box-pack:space-evenly;-ms-flex-pack:space-evenly;justify-content:space-evenly;margin-top:2rem}.description.jsx-c1b2361d98acfbc5{color:grey;font-weight:500;font-size:2rem;padding:0 16px}.inputs.jsx-c1b2361d98acfbc5{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-pack:space-evenly;-webkit-justify-content:space-evenly;-moz-box-pack:space-evenly;-ms-flex-pack:space-evenly;justify-content:space-evenly;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;width:85%}.switchContainer.jsx-c1b2361d98acfbc5{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center}.sectionTitle.jsx-c1b2361d98acfbc5{font-size:3.5rem;text-align:center;text-decoration:underline}.postContainer.jsx-c1b2361d98acfbc5{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-pack:space-evenly;-webkit-justify-content:space-evenly;-moz-box-pack:space-evenly;-ms-flex-pack:space-evenly;justify-content:space-evenly;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;-moz-box-orient:horizontal;-moz-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap}.post.jsx-c1b2361d98acfbc5{max-width:450px;margin:40px 10px;position:relative}.postImg.jsx-c1b2361d98acfbc5{height:250px;width:450px}.header.jsx-c1b2361d98acfbc5{font-size:2.4rem}.date.jsx-c1b2361d98acfbc5{font-weight:400;color:grey}.featureBtn.jsx-c1b2361d98acfbc5{position:absolute;top:1rem;left:1rem}.deleteBtn.jsx-c1b2361d98acfbc5{position:absolute;top:1rem;right:1rem}.editBtn.jsx-c1b2361d98acfbc5{position:absolute;bottom:10.4rem;right:1rem}"})]})},F=function(){return(0,i.jsx)(U,{})}}},function(e){e.O(0,[9774,2888,179],(function(){return t=68056,e(e.s=t);var t}));var t=e.O();_N_E=t}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.