1
2
3
|
/*! For license information please see GithubPicker.09b2a104816c9e2d266a.js.LICENSE.txt */
(self.webpackChunkapp=self.webpackChunkapp||[]).push([[3203],{27926:function(t,e,n){"use strict";n.d(e,{Z:function(){return C}});var r=n(93379),o=n.n(r),i=n(7795),a=n.n(i),c=n(90569),s=n.n(c),u=n(3565),l=n.n(u),f=n(19216),d=n.n(f),h=n(44589),p=n.n(h),y=n(56281),m={};m.styleTagTransform=p(),m.setAttributes=l(),m.insert=s().bind(null,"head"),m.domAPI=a(),m.insertStyleElement=d(),o()(y.Z,m);var v=y.Z&&y.Z.locals?y.Z.locals:void 0,g=n(85893);function b(t){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},b(t)}var A=["children","secondary","className"];function x(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function w(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?x(Object(n),!0).forEach((function(e){j(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):x(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function j(t,e,n){return(e=function(t){var e=function(t,e){if("object"!==b(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,"string");if("object"!==b(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===b(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function E(t){var e=t.children,n=t.secondary,r=t.className,o=function(t,e){if(null==t)return{};var n,r,o=function(t,e){if(null==t)return{};var n,r,o={},i=Object.keys(t);for(r=0;r<i.length;r++)n=i[r],e.indexOf(n)>=0||(o[n]=t[n]);return o}(t,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(r=0;r<i.length;r++)n=i[r],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(o[n]=t[n])}return o}(t,A);return(0,g.jsx)("button",w(w({className:[r,v.action,n&&v.secondary].join(" ")},o),{},{children:e}))}E.defaultProps={className:""};var C=E},72054:function(t,e,n){"use strict";n.d(e,{Z:function(){return B}});var r=n(94184),o=n.n(r),i=n(67294),a=n(45697),c=n.n(a),s=n(93379),u=n.n(s),l=n(7795),f=n.n(l),d=n(90569),h=n.n(d),p=n(3565),y=n.n(p),m=n(19216),v=n.n(m),g=n(44589),b=n.n(g),A=n(56634),x={};x.styleTagTransform=b(),x.setAttributes=y(),x.insert=h().bind(null,"head"),x.domAPI=f(),x.insertStyleElement=v(),u()(A.Z,x);var w=A.Z&&A.Z.locals?A.Z.locals:void 0,j=n(21517),E=n(64261),C=n(62092),O=n(85893);function S(t){return S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},S(t)}function k(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function B(t){var e,n,r,a,c,s=t.actions,u=(e=(0,E.X)(),n=4,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],s=!0,u=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);s=!0);}catch(t){u=!0,o=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(e,n)||function(t,e){if(t){if("string"==typeof t)return k(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?k(t,e):void 0}}(e,n)||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.")}()),l=u[0],f=u[2],d=u[3],h=(0,i.useRef)();return(0,j.Z)(h,f),(0,O.jsxs)("div",{ref:h,className:w.wrapper,children:[(0,O.jsx)(C.Z,{className:w.button,onClick:d,icon:"ellipsis"}),(0,O.jsx)("div",{className:o()(w.menu,(r={},a=w.open,c=l,(a=function(t){var e=function(t,e){if("object"!==S(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,"string");if("object"!==S(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===S(e)?e:String(e)}(a))in r?Object.defineProperty(r,a,{value:c,enumerable:!0,configurable:!0,writable:!0}):r[a]=c,r)),children:(0,O.jsx)("ul",{children:s.map((function(t,e){return(0,O.jsx)("li",{onClick:function(){return function(t){f(),t()}(t.callback)},children:t.content},e)}))})})]})}B.propTypes={actions:c().arrayOf(c().shape({callback:c().func.isRequired,content:c().oneOfType([c().node,c().string]).isRequired})).isRequired}},97494:function(t,e,n){"use strict";n.d(e,{Z:function(){return O}});var r=n(45697),o=n.n(r),i=n(93379),a=n.n(i),c=n(7795),s=n.n(c),u=n(90569),l=n.n(u),f=n(3565),d=n.n(f),h=n(19216),p=n.n(h),y=n(44589),m=n.n(y),v=n(33988),g={};g.styleTagTransform=m(),g.setAttributes=d(),g.insert=l().bind(null,"head"),g.domAPI=s(),g.insertStyleElement=p(),a()(v.Z,g);var b=v.Z&&v.Z.locals?v.Z.locals:void 0,A=n(85893);function x(t){return x="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},x(t)}var w=["validator","required","value"];function j(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function E(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?j(Object(n),!0).forEach((function(e){C(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):j(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function C(t,e,n){return(e=function(t){var e=function(t,e){if("object"!==x(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,"string");if("object"!==x(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===x(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function O(t){var e=t.validator,n=t.required,r=void 0!==n&&n,o=t.value,i=void 0===o?"":o,a=function(t,e){if(null==t)return{};var n,r,o=function(t,e){if(null==t)return{};var n,r,o={},i=Object.keys(t);for(r=0;r<i.length;r++)n=i[r],e.indexOf(n)>=0||(o[n]=t[n]);return o}(t,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(r=0;r<i.length;r++)n=i[r],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(o[n]=t[n])}return o}(t,w),c=e(i)||!i&&r&&"cannot be empty";return(0,A.jsxs)("span",{className:b.wrapper,children:[(0,A.jsx)("input",E({type:"text",value:i},a)),c&&(0,A.jsx)("span",{className:b.error,children:c})]})}O.propTypes={value:o().any.isRequired,required:o().bool,validator:o().func}},92087:function(t,e,n){"use strict";var r=n(45697),o=n.n(r),i=n(96186),a=n(64261),c=n(80031),s=n(85893);function u(t){var e=t.onDismiss;return(0,s.jsx)(a.Z,{children:(0,s.jsxs)(i.Z,{onDismiss:e,children:[(0,s.jsx)("h2",{children:"Automatic Layout Generation Failed"}),(0,s.jsx)("p",{children:"No accompanying layout was found with your keymap file and the Keymap Editor was unable to generate one automatically for you."}),(0,s.jsx)("p",{children:"Something went wrong with the attempted automatic layout generation for your keyboard and there's no automatic way to recover, but if you want to reach out for assistance maybe we can work together to resolve any technical issues or else craft a manual layout for your keyboard."}),(0,s.jsxs)("p",{children:["Share your experience at ",c.qM,"."]})]})})}u.propTypes={onDismiss:o().func.isRequired},e.Z=u},12160:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return Ve}});var r=n(13311),o=n.n(r),i=n(66379),a=n.n(i),c=n(67294),s=n(45697),u=n.n(s),l=n(93965),f=n(96186),d=n(64261),h=n(85893),p={maxHeight:"300px",overflow:"auto",padding:"10px",fontFamily:"monospace",fontSize:"80%",backgroundColor:"rgb(239, 239, 239, 0.5)"},y={margin:"10px"};function m(t){var e=t.onDismiss,n=t.title,r=t.errors,o=function(t){if("InfoValidationError"===t)return"config/info.json"}(n);return(0,h.jsx)(d.Z,{children:(0,h.jsxs)(f.Z,{onDismiss:e,children:[(0,h.jsx)("h2",{children:n}),o&&(0,h.jsxs)("p",{children:["Errors in the file ",(0,h.jsx)("code",{children:o}),"."]}),(0,h.jsx)("ul",{style:p,children:r.map((function(t,e){return(0,h.jsx)("li",{style:y,children:t},e)}))})]})})}var v=n(97168),g=n(35161),b=n.n(g),A="selectedGithubRepository",x="selectedGithubBranch",w="selectedGithubKeyboard";function j(t,e){try{return JSON.parse(localStorage.getItem("".concat(w,":").concat(t,":").concat(e)))}catch(t){return null}}function E(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var C={blocked:!1,initialized:!1,selectedRepoId:null,selectedBranchName:null,selectedKeyboard:null,loadedGitInfo:null,noBranches:!1,branches:[],keyboards:[],loading:!1,warningFlags:[]},O=(0,v.oM)({name:"github-picker",initialState:C,reducers:{clearSelection:function(t){t.warningFlags=[],t.loading=!1},integrationInitialized:function(t){var e,n=function(){try{return JSON.parse(localStorage.getItem(A))}catch(t){return null}}(),r=l.Z.repositories||[];o()(r,{id:n})?e=n:r.length>0&&(e=r[0].id),t.initialized=!0,t.selectedRepoId=e},loadingBranchesList:function(t){t.noBranches=!1,t.loading=!0},loadedBranchesList:function(t,e){var n=t.selectedRepoId,r=e.payload.branches,i=o()(l.Z.repositories,{id:n});t.noBranches=0===r.length,t.branches=r,t.keyboard=null,t.keyboards=[],t.loading=!1;for(var a=b()(r,"name"),c=i.default_branch,s=function(t){try{return JSON.parse(localStorage.getItem("".concat(x,":").concat(t)))}catch(t){return null}}(n),u=0,f=[1===r.length?r[0].name:null,s,c];u<f.length;u++){var d=f[u];if(a.includes(d)){t.selectedBranchName=d,t.selectedKeyboard=j(n,d);break}}},loadingKeyboardsList:function(t){t.loading=!0},loadedKeyboardsList:function(t,e){var n=t.selectedRepoId,r=t.selectedBranchName,o=e.payload,i=o.keyboards,a=o.default;t.keyboards=i,t.loading=!1;for(var c=j(n,r),s=0,u=[1===i.length?i[0]:null,c,a];s<u.length;s++){var l=u[s];if(i.includes(l)){t.selectedKeyboard=l;break}}},createdBranch:function(t,e){t.branches.push({id:e.payload.name,name:e.payload.name,protected:!1})},selectedRepository:function(t,e){var n;t.selectedRepoId=e.payload.repository.id,t.selectedBranchName=null,t.selectedKeyboard=null,t.noBranches=!1,t.branches=[],n=t.selectedRepoId,localStorage.setItem(A,JSON.stringify(n))},selectedBranch:function(t,e){var n,r;t.selectedBranchName=e.payload.name,t.selectedKeyboard=j(t.selectedRepoId,t.selectedBranchName),n=t.selectedRepoId,r=t.selectedBranchName,localStorage.setItem("".concat(x,":").concat(n),JSON.stringify(r))},selectedKeyboard:function(t,e){var n,r,o;t.selectedKeyboard=e.payload.name,n=t.selectedRepoId,r=t.selectedBranchName,o=t.selectedKeyboard,localStorage.setItem("".concat(w,":").concat(n,":").concat(r),JSON.stringify(o))},keyboardLoading:function(t,e){t.loading=!0,t.loadedGitInfo=null},keyboardLoadedSuccess:function(t,e){var n=e.payload.response,r=n.keymap,o=n.gitInfo;t.warningFlags=r.warningFlags||[],t.loadedGitInfo=o,t.loading=!1}}});function S(){var t,e,n,r=(e=(0,c.useReducer)(O.reducer,C),n=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],s=!0,u=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);s=!0);}catch(t){u=!0,o=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(e,n)||function(t,e){if(t){if("string"==typeof t)return E(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?E(t,e):void 0}}(e,n)||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.")}()),o=r[0],i=(t=r[1],(0,c.useMemo)((function(){return Object.keys(O.actions).reduce((function(e,n){return e[n]=function(){var e;return t((e=O.actions)[n].apply(e,arguments))},e}),{})}),[t]));return[o,i]}var k=n(69247);function B(t){var e=t.onDismiss,n=t.missingPath;return(0,h.jsx)(d.Z,{children:(0,h.jsxs)(f.Z,{onDismiss:e,children:[(0,h.jsx)("h2",{children:"Missing keyboard definition?"}),(0,h.jsxs)("p",{children:["Hi there! The repository you're trying to load from doesn't have a defined ",(0,h.jsx)("code",{children:n}),". Right now this application is expecting to look at that directory to discover keyboard definitions for experimental features like automatic layout generation."]}),(0,h.jsx)("p",{children:"Is it possible that the keyboard you're trying to edit relies on data from the ZMK or other repositories? Fetching from other repositories is not currently supported."}),(0,h.jsx)("p",{children:"I'm a humble developer and have only worked with configurations for my own handwired builds, so if you feel you're receiving this message in error then please consider opening an issue on this project's GitHub repository to let me know what I can do differently."})]})})}B.propTypes={onDismiss:u().func.isRequired,missingPath:u().string.isRequired};var L=B,P=n(2968),Z=n(62092);function _(t){var e=t.installation,n="https://github.com/settings/installations/".concat(e.id);return(0,h.jsx)(d.Z,{children:(0,h.jsxs)(f.Z,{style:{maxWidth:"min-content"},dismissText:null,children:[(0,h.jsx)("h2",{children:"App Disabled"}),(0,h.jsxs)("p",{children:["Hello there, your installation of the keymap editor's GitHub app is currently disabled. ",(0,h.jsx)("em",{children:"This is not a ban!"})]}),(0,h.jsxs)("p",{children:["When you installed this app for your GitHub account you installed it for ",(0,h.jsx)("em",{children:"all"})," of your repositories, and we need to do a little cleanup as we roll out some new features as it's very likely you will have other repositories unrelated to ZMK keyboard configurations."]}),(0,h.jsx)("h3",{children:"How to fix this"}),(0,h.jsxs)("p",{children:["If you're still interested in using the keymap editor (and I'd love for you to be able to) please go to your ",(0,h.jsx)(P.Z,{href:n,children:"installation settings"})," on GitHub and select only the repositories you want to use with this tool. As soon as that's done you'll be sent back here and ready to go."]}),(0,h.jsxs)("div",{style:{display:"flex",gap:"20px",textAlign:"center"},children:[(0,h.jsxs)("div",{children:[(0,h.jsx)("p",{children:(0,h.jsx)("img",{alt:"Example correct GitHub installation selection",src:"repo-selection-good.png"})}),(0,h.jsx)("p",{children:(0,h.jsx)("strong",{children:"Do this!"})})]}),(0,h.jsxs)("div",{children:[(0,h.jsx)("p",{children:(0,h.jsx)("img",{alt:"Example incorrect GitHub installation selection",src:"repo-selection-bad.png"})}),(0,h.jsx)("p",{children:(0,h.jsx)("strong",{children:"Don't do this!"})})]})]}),(0,h.jsx)(Z.Z,{collection:"brands",icon:"github",text:"Fix Repository Selection",style:{display:"block",margin:"0 auto",fontSize:"120%",padding:"5px 10px"},onClick:function(){window.location.href=n}}),(0,h.jsx)("p",{children:"As always, if you're looking for clarification or further assistance please visit our GitHub repo and open an issue or start a discussion."})]})})}_.propTypes={installation:u().shape({id:u().number.isRequired}).isRequired};var T=_,D=n(80031);function M(t){var e=t.onDismiss;return(0,h.jsx)(d.Z,{children:(0,h.jsxs)(f.Z,{onDismiss:e,children:[(0,h.jsx)("h2",{children:"Is this a zmk-config repo?"}),(0,h.jsxs)("p",{children:["Hi there! The repository you're trying to load from doesn't have a defined ",(0,h.jsx)("code",{children:"config"})," directory. Right now this application is expecting to look at that directory to discover keymaps and other metadata."]}),D.t6]})})}M.propTypes={onDismiss:u().func.isRequired,otherRepoOrBranchAvailable:u().bool};var I=M,N=n(92087),G=function(){return(0,h.jsx)(d.Z,{children:(0,h.jsxs)(f.Z,{dismissText:null,children:[(0,h.jsx)("h2",{children:"GitHub Account Blocked"}),(0,h.jsx)("p",{children:"Hi, your access to this application has been disabled."}),(0,h.jsxs)("p",{children:["This could be an innocent mistake. Possibly you've misunderstood the intended purpose of this app, possibly I got carried away with some housekeeping. If you want more information or feel this was done in error, please reach out to ",(0,h.jsx)("em",{children:"nickcoutsos"})," on GitHub or Discord (you can find me on the ZMK server)."]})]})})};function R(t){var e=t.onDismiss;return(0,h.jsx)(d.Z,{children:(0,h.jsxs)(f.Z,{onDismiss:e,children:[(0,h.jsx)("h2",{children:"No Layout Available"}),(0,h.jsx)("p",{children:"Your keymap doesn't have an accompanying layout and we don't know enough about your keyboard to generate one for you automatically."}),(0,h.jsxs)("p",{children:["If you meant to include layout data, please make sure that its in the same directory as your keymap, like ",(0,h.jsx)("code",{children:"config/info.json"})," or ",(0,h.jsx)("code",{children:"config/<keyboard>.json"}),"."]}),D.Yo,D.t6]})})}R.propTypes={onDismiss:u().func.isRequired};var $=R;function Y(){return(0,h.jsx)(d.Z,{centerOnly:!0,children:(0,h.jsxs)(f.Z,{dismissText:null,style:{width:"400px"},children:[(0,h.jsx)("h2",{children:"Authenticate with GitHub"}),(0,h.jsx)("p",{children:"Please log-in to GitHub to continue."}),(0,h.jsx)(Z.Z,{collection:"brands",icon:"github",text:"Login with GitHub",style:{display:"block",margin:"0 auto"},onClick:function(){return l.Z.beginLoginFlow()}})]})})}Y.propTypes={};var F=Y;function q(){var t=l.Z.username?"Welcome, ".concat(l.Z.username,"!"):"Welcome!";return(0,h.jsx)(d.Z,{centerOnly:!0,children:(0,h.jsxs)(f.Z,{style:{maxWidth:"min-content"},dismissText:null,children:[(0,h.jsx)("h2",{children:t}),(0,h.jsxs)("p",{children:["To begin importing your own keymaps, you'll need to grant the Keymap Editor app access to your relevant GitHub repositories. Please make sure to ",(0,h.jsx)("em",{children:"only"})," select repositories that are set up for ZMK keyboard configurations."]}),(0,h.jsxs)("p",{children:["This app requires read and write access to the repositories you select in order to write to arbitrary ",(0,h.jsx)("code",{children:".keymap"})," files. It also receives all build action events for the repository, which generates quite a bit of traffic."]}),(0,h.jsxs)("div",{style:{display:"flex",gap:"20px",textAlign:"center"},children:[(0,h.jsxs)("div",{children:[(0,h.jsx)("p",{children:(0,h.jsx)("img",{alt:"Example correct GitHub installation selection",src:"repo-selection-good.png"})}),(0,h.jsx)("p",{children:(0,h.jsx)("strong",{children:"Do this!"})})]}),(0,h.jsxs)("div",{children:[(0,h.jsx)("p",{children:(0,h.jsx)("img",{alt:"Example incorrect GitHub installation selection",src:"repo-selection-bad.png"})}),(0,h.jsx)("p",{children:(0,h.jsx)("strong",{children:"Don't do this!"})})]})]}),(0,h.jsxs)("p",{children:["Selecting ",(0,h.jsx)("code",{children:"All repositories"})," for the app installation will lead to a suspension."]}),(0,h.jsx)(Z.Z,{collection:"brands",icon:"github",text:"Add Repository",style:{display:"block",margin:"0 auto",fontSize:"120%",padding:"5px 10px"},onClick:function(){return l.Z.beginInstallAppFlow()}})]})})}q.propTypes={};var H=q,W=(0,h.jsx)(P.Z,{external:!0,href:"https://zmk.dev/docs/user-setup#user-config-setup-script",children:"User Config Setup Script"});function K(t){var e=t.onDismiss;return(0,h.jsx)(d.Z,{children:(0,h.jsxs)(f.Z,{onDismiss:e,children:[(0,h.jsx)("h2",{children:"Empty Repository"}),(0,h.jsxs)("p",{children:["The selected repository doesn't appear to contain anything yet. please be sure to use ZMK's ",W," to initialize your repo first."]}),D.t6]})})}var z=n(41051);function U(t){var e=t.onDismiss;return(0,h.jsx)(d.Z,{children:(0,h.jsxs)(f.Z,{onDismiss:e,children:[(0,h.jsx)("h2",{children:"No Keymap Available"}),(0,h.jsxs)("p",{children:["We couldn't find a ",(0,h.jsx)("code",{children:".keymap"})," file in your ",(0,h.jsx)("code",{children:"config/"})," folder."]}),(0,h.jsxs)("p",{children:["Please ensure that any keymap(s) you wish to edit are placed in that directory even if an accompanying keyboard definition exists in your under the ",(0,h.jsx)("code",{children:"config/boards/..."})," directory."]}),(0,h.jsxs)("p",{children:["If you have any questions please feel free to reach out by creating an issue at ",D.qM,"."]})]})})}U.propTypes={onDismiss:u().func.isRequired};var V=U,J=n(80993),X=n(93379),Q=n.n(X),tt=n(7795),et=n.n(tt),nt=n(90569),rt=n.n(nt),ot=n(3565),it=n.n(ot),at=n(19216),ct=n.n(at),st=n(44589),ut=n.n(st),lt=n(92127),ft={};ft.styleTagTransform=ut(),ft.setAttributes=it(),ft.insert=rt().bind(null,"head"),ft.domAPI=et(),ft.insertStyleElement=ct(),Q()(lt.Z,ft);var dt=lt.Z&<.Z.locals?lt.Z.locals:void 0;function ht(t){return ht="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ht(t)}var pt=["children"];function yt(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function mt(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?yt(Object(n),!0).forEach((function(e){vt(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):yt(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function vt(t,e,n){return(e=function(t){var e=function(t,e){if("object"!==ht(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,"string");if("object"!==ht(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===ht(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function gt(t){var e=t.children,n=function(t,e){if(null==t)return{};var n,r,o=function(t,e){if(null==t)return{};var n,r,o={},i=Object.keys(t);for(r=0;r<i.length;r++)n=i[r],e.indexOf(n)>=0||(o[n]=t[n]);return o}(t,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(r=0;r<i.length;r++)n=i[r],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(o[n]=t[n])}return o}(t,pt);return(0,h.jsxs)("div",mt(mt({},n),{},{className:dt.spinner,children:[(0,h.jsx)("i",{className:"".concat(dt.icon," fa fa-spinner")}),e]}))}function bt(){return(0,h.jsx)(z.Z,{name:"shield",title:"Branch is protected -- cannot commit changes"})}function At(t){var e=t.state,n=t.actions,r=t.choices,i=t.selections,a=r.repositories,c=r.repositoryChoices,s=r.branchChoices,u=r.keyboardChoices,f=i.selectedRepoChoice,d=i.selectedBranchChoice,p=i.selectedKeyboardChoice,y=e.branches,m=e.keyboards,v=e.loading;return(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(J.Z,{label:"Repository",value:f,options:c,onChange:function(t){var e=t.id;if("installation"!==t.type){var r=o()(a,{id:e});n.selectedRepository({repository:r})}else l.Z.manageInstallationRepos(e)},getValue:function(t){return t.id},getOptionValue:function(t){return t.id},getOptionLabel:function(t){return t.full||t.name},formatOptionLabel:function(t,e){var n=e.context;return(0,h.jsx)(h.Fragment,{children:"value"===n?t.name:t.full||t.name})}}),y.length>1&&(0,h.jsx)(J.Z,{label:"Branch",value:d,options:s,onChange:function(t){var e=t.id;return n.selectedBranch({name:e})},getOptionValue:function(t){return t.id},getOptionLabel:function(t){return t.name},formatOptionLabel:function(t){return(0,h.jsxs)(h.Fragment,{children:[t.protected&&(0,h.jsx)(bt,{})," ",t.name]})}}),m.length>1&&(0,h.jsx)(J.Z,{label:"Keyboard",value:p,options:u,getOptionValue:function(t){return t.id},getOptionLabel:function(t){return t.name},onChange:function(t){var e=t.id;return n.selectedKeyboard({name:e})}}),v&&(0,h.jsx)(k.oT,{children:(0,h.jsx)(gt,{})})]})}var xt=n(80047),wt={};wt.styleTagTransform=ut(),wt.setAttributes=it(),wt.insert=rt().bind(null,"head"),wt.domAPI=et(),wt.insertStyleElement=ct(),Q()(xt.Z,wt);var jt=xt.Z&&xt.Z.locals?xt.Z.locals:void 0;function Et(t){var e,n=t.choices,r=t.selections,o=t.state,i=t.onExpand,a=n.keyboardChoices,c=r.selectedRepoChoice,s=o.selectedBranchName,u=o.selectedKeyboard,l=o.loading;return(0,h.jsx)("div",{onClick:i,children:(0,h.jsxs)("div",{className:jt.compactWrapper,children:[(0,h.jsxs)(k.oT,{id:"compact-github-picker",style:{display:"flex",flexDirection:"column",justifyContent:"center",lineHeight:"normal"},children:[(0,h.jsx)("span",{children:c.name}),(0,h.jsxs)("span",{style:{marginLeft:"10px",fontSize:"65%"},children:[(0,h.jsx)(z.Z,{name:"code-branch"}),(0,h.jsx)("span",{children:s})]})]}),(0,h.jsxs)(k.oT,{children:["/ ",l?(0,h.jsx)(gt,{}):(0,h.jsx)("span",{children:u||(null===(e=a[0])||void 0===e?void 0:e.name)})]})]})})}function Ct(t){return Ct="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ct(t)}function Ot(){Ot=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,r=Object.defineProperty||function(t,e,n){t[e]=n.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function s(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,n){return t[e]=n}}function u(t,e,n,o){var i=e&&e.prototype instanceof d?e:d,a=Object.create(i.prototype),c=new C(o||[]);return r(a,"_invoke",{value:x(t,n,c)}),a}function l(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}t.wrap=u;var f={};function d(){}function h(){}function p(){}var y={};s(y,i,(function(){return this}));var m=Object.getPrototypeOf,v=m&&m(m(O([])));v&&v!==e&&n.call(v,i)&&(y=v);var g=p.prototype=d.prototype=Object.create(y);function b(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function A(t,e){function o(r,i,a,c){var s=l(t[r],t,i);if("throw"!==s.type){var u=s.arg,f=u.value;return f&&"object"==Ct(f)&&n.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){u.value=t,a(u)}),(function(t){return o("throw",t,a,c)}))}c(s.arg)}var i;r(this,"_invoke",{value:function(t,n){function r(){return new e((function(e,r){o(t,n,e,r)}))}return i=i?i.then(r,r):r()}})}function x(t,e,n){var r="suspendedStart";return function(o,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===o)throw i;return{value:void 0,done:!0}}for(n.method=o,n.arg=i;;){var a=n.delegate;if(a){var c=w(a,n);if(c){if(c===f)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=l(t,e,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}function w(t,e){var n=e.method,r=t.iterator[n];if(void 0===r)return e.delegate=null,"throw"===n&&t.iterator.return&&(e.method="return",e.arg=void 0,w(t,e),"throw"===e.method)||"return"!==n&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var o=l(r,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,f;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function E(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function C(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function O(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,o=function e(){for(;++r<t.length;)if(n.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=p,r(g,"constructor",{value:p,configurable:!0}),r(p,"constructor",{value:h,configurable:!0}),h.displayName=s(p,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,c,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},b(A.prototype),s(A.prototype,a,(function(){return this})),t.AsyncIterator=A,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var a=new A(u(e,n,r,o),i);return t.isGeneratorFunction(n)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(g),s(g,c,"Generator"),s(g,i,(function(){return this})),s(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},t.values=O,C.prototype={constructor:C,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(E),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(n,r){return a.type="throw",a.arg=t,e.next=n,r&&(e.method="next",e.arg=void 0),!!r}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(c&&s){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),E(n),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var o=r.arg;E(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:O(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},t}function St(t,e,n,r,o,i,a){try{var c=t[i](a),s=c.value}catch(t){return void n(t)}c.done?e(s):Promise.resolve(s).then(r,o)}function kt(t){return function(){var e=this,n=arguments;return new Promise((function(r,o){var i=t.apply(e,n);function a(t){St(i,r,o,a,c,"next",t)}function c(t){St(i,r,o,a,c,"throw",t)}a(void 0)}))}}function Bt(t){return function(t){if(Array.isArray(t))return Lt(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return Lt(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Lt(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Lt(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var Pt=n(39693),Zt=n.n(Pt),_t=n(18446),Tt=n.n(_t),Dt=n(95998),Mt=n(27484),It=n.n(Mt),Nt=n(84110),Gt=n.n(Nt);function Rt(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}It().extend(Gt());var $t=["success"],Yt=["action_required","cancelled","failure","skipped","stale","timed_out"];function Ft(t){var e,n,r=t.timestamp,o=(e=(0,c.useState)(It()(r).fromNow()),n=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],s=!0,u=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);s=!0);}catch(t){u=!0,o=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(e,n)||function(t,e){if(t){if("string"==typeof t)return Rt(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Rt(t,e):void 0}}(e,n)||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.")}()),i=o[0],a=o[1];return(0,c.useEffect)((function(){a(It()(r).fromNow());var t=setInterval((function(){a(It()(r).fromNow())}),6e4);return function(){return clearInterval(t)}}),[r,a]),(0,h.jsx)("span",{title:r,children:i})}function qt(t){var e=t.latestRun,n=$t.includes(e.conclusion)?(0,h.jsx)(z.Z,{name:"check"}):Yt.includes(e.conclusion)?(0,h.jsx)(z.Z,{name:"xmark"}):(0,h.jsx)(gt,{});return(0,h.jsx)(P.Z,{href:e.html_url,external:!0,showExternal:!1,children:(0,h.jsxs)("div",{className:jt.buildDetails,children:[(0,h.jsxs)("span",{className:jt.buildSummary,children:[(0,h.jsx)("span",{children:"Latest"})," (",(0,h.jsx)("code",{children:e.head_sha.slice(0,5)}),") ",(0,h.jsx)("span",{children:n}),(0,h.jsx)("br",{}),(0,h.jsx)(Ft,{timestamp:e.updated_at})]}),(0,h.jsx)(z.Z,{name:"file-arrow-down",className:[jt.buildStatus,jt.buildSuccess].join(" ")})]})})}qt.propTypes={latestRun:u().shape({id:u().number.isRequired,name:u().string.isRequired,head_sha:u().string.isRequired,status:u().oneOf(["completed","action_required","cancelled","failure","neutral","skipped","stale","success","timed_out","in_progress","queued","requested","waiting"]).isRequired,conclusion:u().oneOf([null,"action_required","cancelled","failure","neutral","success","skipped","stale","timed_out"]),created_at:u().string.isRequired,updated_at:u().string.isRequired})};var Ht=qt,Wt=n(27926);function Kt(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function zt(t){var e,n,r=t.onConfirm,o=t.onCancel,i=(e=(0,c.useState)(""),n=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],s=!0,u=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);s=!0);}catch(t){u=!0,o=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(e,n)||function(t,e){if(t){if("string"==typeof t)return Kt(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Kt(t,e):void 0}}(e,n)||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.")}()),a=i[0],s=i[1];return(0,h.jsx)(d.Z,{children:(0,h.jsxs)(f.Z,{dismissText:null,children:[(0,h.jsx)("h2",{children:"Commit keymap changes"}),(0,h.jsx)("textarea",{style:{width:"100%"},placeholder:"Message (optional)",value:a,onChange:function(t){s(t.target.value)}}),(0,h.jsxs)("p",{style:{textAlign:"center",gap:"10px"},children:[(0,h.jsx)(Wt.Z,{onClick:function(){return r(a)},children:"Commit"}),(0,h.jsx)(Wt.Z,{onClick:o,secondary:!0,children:"Cancel"})]})]})})}zt.propTypes={onConfirm:u().func.isRequired,onCancel:u().func.isRequired};var Ut=zt,Vt=n(72054),Jt=n(97494);function Xt(t){return Xt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Xt(t)}function Qt(){Qt=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,r=Object.defineProperty||function(t,e,n){t[e]=n.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function s(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,n){return t[e]=n}}function u(t,e,n,o){var i=e&&e.prototype instanceof d?e:d,a=Object.create(i.prototype),c=new C(o||[]);return r(a,"_invoke",{value:x(t,n,c)}),a}function l(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}t.wrap=u;var f={};function d(){}function h(){}function p(){}var y={};s(y,i,(function(){return this}));var m=Object.getPrototypeOf,v=m&&m(m(O([])));v&&v!==e&&n.call(v,i)&&(y=v);var g=p.prototype=d.prototype=Object.create(y);function b(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function A(t,e){function o(r,i,a,c){var s=l(t[r],t,i);if("throw"!==s.type){var u=s.arg,f=u.value;return f&&"object"==Xt(f)&&n.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){u.value=t,a(u)}),(function(t){return o("throw",t,a,c)}))}c(s.arg)}var i;r(this,"_invoke",{value:function(t,n){function r(){return new e((function(e,r){o(t,n,e,r)}))}return i=i?i.then(r,r):r()}})}function x(t,e,n){var r="suspendedStart";return function(o,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===o)throw i;return{value:void 0,done:!0}}for(n.method=o,n.arg=i;;){var a=n.delegate;if(a){var c=w(a,n);if(c){if(c===f)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=l(t,e,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}function w(t,e){var n=e.method,r=t.iterator[n];if(void 0===r)return e.delegate=null,"throw"===n&&t.iterator.return&&(e.method="return",e.arg=void 0,w(t,e),"throw"===e.method)||"return"!==n&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var o=l(r,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,f;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function E(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function C(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function O(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,o=function e(){for(;++r<t.length;)if(n.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=p,r(g,"constructor",{value:p,configurable:!0}),r(p,"constructor",{value:h,configurable:!0}),h.displayName=s(p,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,c,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},b(A.prototype),s(A.prototype,a,(function(){return this})),t.AsyncIterator=A,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var a=new A(u(e,n,r,o),i);return t.isGeneratorFunction(n)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(g),s(g,c,"Generator"),s(g,i,(function(){return this})),s(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},t.values=O,C.prototype={constructor:C,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(E),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(n,r){return a.type="throw",a.arg=t,e.next=n,r&&(e.method="next",e.arg=void 0),!!r}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(c&&s){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),E(n),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var o=r.arg;E(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:O(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},t}function te(t,e,n,r,o,i,a){try{var c=t[i](a),s=c.value}catch(t){return void n(t)}c.done?e(s):Promise.resolve(s).then(r,o)}function ee(t){return function(){var e=this,n=arguments;return new Promise((function(r,o){var i=t.apply(e,n);function a(t){te(i,r,o,a,c,"next",t)}function c(t){te(i,r,o,a,c,"throw",t)}a(void 0)}))}}function ne(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function re(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?ne(Object(n),!0).forEach((function(e){oe(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ne(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function oe(t,e,n){return(e=function(t){var e=function(t,e){if("object"!==Xt(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,"string");if("object"!==Xt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===Xt(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function ie(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function ae(t){return t.match(/\/\./)?"slash-separated component cannot begin with a dot":t.match(/\/.*\.lock/)?"slash-separated component cannot end with .lock":-1!==t.indexOf("..")?"cannot have two consecutive dots anywhere":t.match(/[?*[]/)?'cannot contain "?", "*", "["':t.startsWith("/")||t.endsWith("/")?"cannot begin or end with slash":-1!==t.indexOf(" ")?'cannot contain " "':-1!==t.indexOf("@{")?'cannot contain sequence "@{"':"@"===t?'cannot be "@"':-1!==t.indexOf("\\")?'cannot contain "\\"':t.endsWith(".")?'cannot end with "."':void 0}function ce(t){var e,n,r=t.onConfirm,o=t.onCancel,i=t.branches,a=t.selected,s=t.repo,u=(0,c.useMemo)((function(){return i.map((function(t){var e=t.name;return{id:e,name:e}}))}),[i]),p=(e=(0,c.useState)({name:"",source:u.find((function(t){return t.id===a})),submitting:!1}),n=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],s=!0,u=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);s=!0);}catch(t){u=!0,o=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(e,n)||function(t,e){if(t){if("string"==typeof t)return ie(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ie(t,e):void 0}}(e,n)||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.")}()),y=p[0],m=p[1],v=(0,c.useMemo)((function(){return y.name&&y.source&&!y.submitting&&!ae(y.name)}),[y]),g=(0,c.useCallback)((function(t){m((function(e){return re(re({},e),{},{name:t.target.value})}))}),[m]),b=(0,c.useCallback)((function(t){m((function(e){return re(re({},e),{},{source:t})}))}),[m]),A=(0,c.useCallback)(ee(Qt().mark((function t(){return Qt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return m((function(t){return re(re({},t),{},{submitting:!0})})),t.prev=1,t.next=4,l.Z.createBranch(s,y.source.id,y.name);case 4:t.next=11;break;case 6:return t.prev=6,t.t0=t.catch(1),console.error("Branch creation failed",t.t0),m((function(t){return re(re({},t),{},{submitting:!1})})),t.abrupt("return");case 11:m((function(t){return re(re({},t),{},{submitting:!1})})),r(y.name);case 13:case"end":return t.stop()}}),t,null,[[1,6]])}))),[s,y.source,y.name,m,r]);return(0,h.jsx)(d.Z,{onDismiss:o,children:(0,h.jsxs)(f.Z,{dismissText:null,children:[(0,h.jsx)("h2",{children:"Create new branch"}),(0,h.jsxs)(k.__,{children:["Source ",(0,h.jsx)(J.Z,{value:y.source,options:u,getOptionValue:function(t){return t.id},getOptionLabel:function(t){return t.name},onChange:b})]}),(0,h.jsx)(k.oT,{children:(0,h.jsxs)(k.__,{children:["Branch ",(0,h.jsx)(Jt.Z,{value:y.name,validator:ae,disabled:y.submitting,onChange:g})]})}),(0,h.jsxs)("p",{style:{textAlign:"center",gap:"10px"},children:[(0,h.jsx)(Wt.Z,{disabled:!v,onClick:A,children:y.submitting?(0,h.jsx)(gt,{}):(0,h.jsx)(h.Fragment,{children:"Confirm"})}),(0,h.jsx)(Wt.Z,{disabled:y.submitting,onClick:o,secondary:!0,children:"Cancel"})]})]})})}ce.propTypes={onConfirm:u().func.isRequired,onCancel:u().func.isRequired,branches:u().array.isRequired,selected:u().string.isRequired,repo:u().any};var se=ce,ue=n(50361),le=n.n(ue),fe=n(83858),de=n.n(fe),he=n(59303),pe={};pe.styleTagTransform=ut(),pe.setAttributes=it(),pe.insert=rt().bind(null,"head"),pe.domAPI=et(),pe.insertStyleElement=ct(),Q()(he.Z,pe);var ye=he.Z&&he.Z.locals?he.Z.locals:void 0;function me(t){return me="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},me(t)}function ve(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function ge(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?ve(Object(n),!0).forEach((function(e){be(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ve(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function be(t,e,n){return(e=function(t){var e=function(t,e){if("object"!==me(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,"string");if("object"!==me(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===me(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ae(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function xe(t){var e,n,r=t.text,o=t.children,i=t.copyable,a=void 0!==i&&i,s=(e=(0,c.useState)(!1),n=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],s=!0,u=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);s=!0);}catch(t){u=!0,o=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(e,n)||function(t,e){if(t){if("string"==typeof t)return Ae(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ae(t,e):void 0}}(e,n)||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.")}()),u=s[0],l=s[1];return(0,c.useEffect)((function(){u&&setTimeout((function(){l(!1)}),3e3)}),[u,l]),(0,h.jsxs)("div",{style:{position:"relative"},children:[o,a&&(0,h.jsx)(Z.Z,{icon:"copy",title:"Copy to clipboard",className:ye.button,onClick:function(){navigator.clipboard.writeText(r).then((function(){return l(!0)}))}}),u&&(0,h.jsx)("div",{className:ye.copyMessage,children:"Copied!"})]})}function we(t){return(0,h.jsx)(xe,ge(ge({},t),{},{children:(0,h.jsx)("pre",{className:ye.code,children:t.text})}))}function je(t){return je="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},je(t)}function Ee(){Ee=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,r=Object.defineProperty||function(t,e,n){t[e]=n.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function s(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,n){return t[e]=n}}function u(t,e,n,o){var i=e&&e.prototype instanceof d?e:d,a=Object.create(i.prototype),c=new C(o||[]);return r(a,"_invoke",{value:x(t,n,c)}),a}function l(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}t.wrap=u;var f={};function d(){}function h(){}function p(){}var y={};s(y,i,(function(){return this}));var m=Object.getPrototypeOf,v=m&&m(m(O([])));v&&v!==e&&n.call(v,i)&&(y=v);var g=p.prototype=d.prototype=Object.create(y);function b(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function A(t,e){function o(r,i,a,c){var s=l(t[r],t,i);if("throw"!==s.type){var u=s.arg,f=u.value;return f&&"object"==je(f)&&n.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){u.value=t,a(u)}),(function(t){return o("throw",t,a,c)}))}c(s.arg)}var i;r(this,"_invoke",{value:function(t,n){function r(){return new e((function(e,r){o(t,n,e,r)}))}return i=i?i.then(r,r):r()}})}function x(t,e,n){var r="suspendedStart";return function(o,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===o)throw i;return{value:void 0,done:!0}}for(n.method=o,n.arg=i;;){var a=n.delegate;if(a){var c=w(a,n);if(c){if(c===f)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=l(t,e,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}function w(t,e){var n=e.method,r=t.iterator[n];if(void 0===r)return e.delegate=null,"throw"===n&&t.iterator.return&&(e.method="return",e.arg=void 0,w(t,e),"throw"===e.method)||"return"!==n&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var o=l(r,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,f;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function E(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function C(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function O(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,o=function e(){for(;++r<t.length;)if(n.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=p,r(g,"constructor",{value:p,configurable:!0}),r(p,"constructor",{value:h,configurable:!0}),h.displayName=s(p,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,c,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},b(A.prototype),s(A.prototype,a,(function(){return this})),t.AsyncIterator=A,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var a=new A(u(e,n,r,o),i);return t.isGeneratorFunction(n)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(g),s(g,c,"Generator"),s(g,i,(function(){return this})),s(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},t.values=O,C.prototype={constructor:C,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(E),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(n,r){return a.type="throw",a.arg=t,e.next=n,r&&(e.method="next",e.arg=void 0),!!r}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(c&&s){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),E(n),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var o=r.arg;E(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:O(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},t}function Ce(t,e,n,r,o,i,a){try{var c=t[i](a),s=c.value}catch(t){return void n(t)}c.done?e(s):Promise.resolve(s).then(r,o)}function Oe(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var Se=function(t){return t};function ke(t){var e,n,r=t.onDismiss,o=(e=(0,c.useState)(null),n=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],s=!0,u=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);s=!0);}catch(t){u=!0,o=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(e,n)||function(t,e){if(t){if("string"==typeof t)return Oe(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Oe(t,e):void 0}}(e,n)||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.")}()),i=o[0],a=o[1],s=(0,Dt.v9)(Se),u=s.keyboard,l=u.keymap,p=u.layout,y=s.sourceOther.keymapRaw;return(0,c.useEffect)((function(){function t(){var e;return e=Ee().mark((function t(){var e;return Ee().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,de()(p,le()(l),y);case 3:e=t.sent,a(e),t.next=12;break;case 7:throw t.prev=7,t.t0=t.catch(0),console.error("Failed to update/parse",l),console.error(t.t0),t.t0;case 12:case"end":return t.stop()}}),t,null,[[0,7]])})),t=function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function a(t){Ce(i,r,o,a,c,"next",t)}function c(t){Ce(i,r,o,a,c,"throw",t)}a(void 0)}))},t.apply(this,arguments)}!function(){t.apply(this,arguments)}()}),[l,y,p,a]),(0,h.jsx)(d.Z,{onDismiss:r,children:(0,h.jsxs)(f.Z,{onDismiss:r,style:{maxWidth:"70vw"},children:[(0,h.jsx)("h1",{children:"Raw Keymap"}),(0,h.jsxs)("p",{children:["This is a preview of your current keymap changes applied to the original ",(0,h.jsx)("code",{children:".keymap"})," file contents from your repository."]}),(0,h.jsxs)("p",{children:["Any changes shown here will not be committed to your repository until you click the ",(0,h.jsx)("em",{children:"Save"})," button in the action bar."]}),null!==i&&(0,h.jsx)(we,{copyable:!0,text:i})]})})}function Be(t){return Be="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Be(t)}function Le(){Le=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,r=Object.defineProperty||function(t,e,n){t[e]=n.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function s(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,n){return t[e]=n}}function u(t,e,n,o){var i=e&&e.prototype instanceof d?e:d,a=Object.create(i.prototype),c=new C(o||[]);return r(a,"_invoke",{value:x(t,n,c)}),a}function l(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}t.wrap=u;var f={};function d(){}function h(){}function p(){}var y={};s(y,i,(function(){return this}));var m=Object.getPrototypeOf,v=m&&m(m(O([])));v&&v!==e&&n.call(v,i)&&(y=v);var g=p.prototype=d.prototype=Object.create(y);function b(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function A(t,e){function o(r,i,a,c){var s=l(t[r],t,i);if("throw"!==s.type){var u=s.arg,f=u.value;return f&&"object"==Be(f)&&n.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){u.value=t,a(u)}),(function(t){return o("throw",t,a,c)}))}c(s.arg)}var i;r(this,"_invoke",{value:function(t,n){function r(){return new e((function(e,r){o(t,n,e,r)}))}return i=i?i.then(r,r):r()}})}function x(t,e,n){var r="suspendedStart";return function(o,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===o)throw i;return{value:void 0,done:!0}}for(n.method=o,n.arg=i;;){var a=n.delegate;if(a){var c=w(a,n);if(c){if(c===f)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=l(t,e,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}function w(t,e){var n=e.method,r=t.iterator[n];if(void 0===r)return e.delegate=null,"throw"===n&&t.iterator.return&&(e.method="return",e.arg=void 0,w(t,e),"throw"===e.method)||"return"!==n&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var o=l(r,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,f;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function E(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function C(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function O(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,o=function e(){for(;++r<t.length;)if(n.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=p,r(g,"constructor",{value:p,configurable:!0}),r(p,"constructor",{value:h,configurable:!0}),h.displayName=s(p,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,c,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},b(A.prototype),s(A.prototype,a,(function(){return this})),t.AsyncIterator=A,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var a=new A(u(e,n,r,o),i);return t.isGeneratorFunction(n)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(g),s(g,c,"Generator"),s(g,i,(function(){return this})),s(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},t.values=O,C.prototype={constructor:C,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(E),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(n,r){return a.type="throw",a.arg=t,e.next=n,r&&(e.method="next",e.arg=void 0),!!r}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(c&&s){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),E(n),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var o=r.arg;E(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:O(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},t}function Pe(t,e,n,r,o,i,a){try{var c=t[i](a),s=c.value}catch(t){return void n(t)}c.done?e(s):Promise.resolve(s).then(r,o)}function Ze(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],s=!0,u=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);s=!0);}catch(t){u=!0,o=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(t,e)||_e(t,e)||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.")}()}function _e(t,e){if(t){if("string"==typeof t)return Te(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Te(t,e):void 0}}function Te(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var De=function(t){return t};function Me(t){var e,n=t.state,r=t.actions,o=(0,Dt.I0)(),i=(0,Dt.v9)(De),a=i.source,s=i.sourceOther,u=i.keyboard,f=i._unmodifiedKeymap,p=i.saving,y=i.experimentalSettings,m=i.latestBuild,v=Ze((0,c.useState)(!1),2),g=v[0],b=v[1],A=Ze((0,d.X)(),3),x=A[0],w=A[1],j=A[2],E=n.loadedGitInfo,C=Zt()([(null==u?void 0:u.keymap)&&{callback:w,content:(0,h.jsx)("span",{title:"Generate keymap devicetree code without committing to GitHub",children:"View keymap data"})}].concat(function(t){if(Array.isArray(t))return Te(t)}(e=l.Z.installations.map((function(t){return{callback:function(){return l.Z.manageInstallationRepos(t.id)},content:(0,h.jsxs)(h.Fragment,{children:["Manage repos for ",(0,h.jsx)("em",{children:t.account.login})]})}})))||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(e)||_e(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),[{callback:function(){return b(!0)},content:(0,h.jsx)(h.Fragment,{children:"Create new branch"})},{callback:function(){return l.Z.logout()},content:(0,h.jsx)(h.Fragment,{children:"Log out"})}])),O=u&&!Tt()(u.keymap,f),S=(0,c.useCallback)((function(t){var e,n=s.github,r=n.repository,i=n.branch;(e=Le().mark((function e(){var n,a,c,f,d,h,p;return Le().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o({type:"COMMIT_DIALOG_CLOSE"}),o({type:"KEYMAP_SAVE_START"}),n=u.layout,a=u.keymap,e.prev=3,e.next=6,l.Z.commitChanges(r,i,n,a,{message:t,experimentalSettings:y,keyboard:s.github.keyboard,loadedGitInfo:E});case 6:c=e.sent,f=c.data,o({type:"KEYMAP_SAVE_SUCCESS",keymap:f}),e.next=15;break;case 11:e.prev=11,e.t0=e.catch(3),p=null!==(d=e.t0.response)&&void 0!==d&&null!==(h=d.data)&&void 0!==h&&h.commitMismatch?{commitMismatch:!0}:{},o({type:"KEYMAP_SAVE_FAILURE",details:p});case 15:case"end":return e.stop()}}),e,null,[[3,11]])})),function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function a(t){Pe(i,r,o,a,c,"next",t)}function c(t){Pe(i,r,o,a,c,"throw",t)}a(void 0)}))})()}),[s,E,u,o,y]);return(0,h.jsxs)("div",{className:jt.pickerActions,children:["github"===a&&!s.github.isProtected&&(0,h.jsx)(Wt.Z,{title:"Commit keymap changes to GitHub repository",disabled:!O,onClick:function(){o({type:"COMMIT_DIALOG_OPEN"})},children:p?(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)("span",{children:"Saving"})," ",(0,h.jsx)(gt,{})]}):(0,h.jsx)("span",{children:"Save"})}),"github"===a&&s.github.isProtected&&(0,h.jsxs)(Wt.Z,{title:"Cannot commit changes to this branch",disabled:!0,children:[(0,h.jsx)(z.Z,{name:"shield"})," Read-only"]}),i.commitDialogOpen&&(0,h.jsx)(Ut,{onConfirm:S,onCancel:function(){return o({type:"COMMIT_DIALOG_CLOSE"})}}),m&&(0,h.jsx)(Ht,{latestRun:m}),(0,h.jsx)(k.oT,{children:(0,h.jsx)(Vt.Z,{actions:C})}),g&&(0,h.jsx)(se,{repo:n.selectedRepoId,branches:n.branches,selected:n.selectedBranchName,onCancel:function(){return b(!1)},onConfirm:function(t){b(!1),r.createdBranch({name:t}),r.selectedBranch({name:t})}}),x&&(0,h.jsx)(ke,{onDismiss:j})]})}function Ie(t){return Ie="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ie(t)}function Ne(){Ne=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,r=Object.defineProperty||function(t,e,n){t[e]=n.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function s(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,n){return t[e]=n}}function u(t,e,n,o){var i=e&&e.prototype instanceof d?e:d,a=Object.create(i.prototype),c=new C(o||[]);return r(a,"_invoke",{value:x(t,n,c)}),a}function l(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}t.wrap=u;var f={};function d(){}function h(){}function p(){}var y={};s(y,i,(function(){return this}));var m=Object.getPrototypeOf,v=m&&m(m(O([])));v&&v!==e&&n.call(v,i)&&(y=v);var g=p.prototype=d.prototype=Object.create(y);function b(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function A(t,e){function o(r,i,a,c){var s=l(t[r],t,i);if("throw"!==s.type){var u=s.arg,f=u.value;return f&&"object"==Ie(f)&&n.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){u.value=t,a(u)}),(function(t){return o("throw",t,a,c)}))}c(s.arg)}var i;r(this,"_invoke",{value:function(t,n){function r(){return new e((function(e,r){o(t,n,e,r)}))}return i=i?i.then(r,r):r()}})}function x(t,e,n){var r="suspendedStart";return function(o,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===o)throw i;return{value:void 0,done:!0}}for(n.method=o,n.arg=i;;){var a=n.delegate;if(a){var c=w(a,n);if(c){if(c===f)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=l(t,e,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}function w(t,e){var n=e.method,r=t.iterator[n];if(void 0===r)return e.delegate=null,"throw"===n&&t.iterator.return&&(e.method="return",e.arg=void 0,w(t,e),"throw"===e.method)||"return"!==n&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var o=l(r,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,f;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function E(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function C(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function O(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,o=function e(){for(;++r<t.length;)if(n.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=p,r(g,"constructor",{value:p,configurable:!0}),r(p,"constructor",{value:h,configurable:!0}),h.displayName=s(p,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,c,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},b(A.prototype),s(A.prototype,a,(function(){return this})),t.AsyncIterator=A,t.async=function(e,n,r,o,i){void 0===i&&(i=Promise);var a=new A(u(e,n,r,o),i);return t.isGeneratorFunction(n)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(g),s(g,c,"Generator"),s(g,i,(function(){return this})),s(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},t.values=O,C.prototype={constructor:C,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(E),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(n,r){return a.type="throw",a.arg=t,e.next=n,r&&(e.method="next",e.arg=void 0),!!r}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(c&&s){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),E(n),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var o=r.arg;E(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:O(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},t}function Ge(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function Re(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?Ge(Object(n),!0).forEach((function(e){$e(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Ge(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function $e(t,e,n){return(e=function(t){var e=function(t,e){if("object"!==Ie(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,"string");if("object"!==Ie(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===Ie(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ye(t,e,n,r,o,i,a){try{var c=t[i](a),s=c.value}catch(t){return void n(t)}c.done?e(s):Promise.resolve(s).then(r,o)}function Fe(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],s=!0,u=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);s=!0);}catch(t){u=!0,o=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return qe(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?qe(t,e):void 0}}(t,e)||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.")}()}function qe(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var He=function(t){return a()(t,{name:"MissingRepoFile",path:"config"})},We=function(t){return a()(t,{name:"MissingRepoFile",intent:"directory-structure"})},Ke=function(t){return a()(t,{name:"MissingRepoFile",path:"config/info.json"})||a()(t,{name:"MissingRepoFile",intent:"metadata"})},ze=function(t){return"MissingRepoFile"===(null==t?void 0:t.name)&&(null==t?void 0:t.path.match(/config\/boards\/[^/]+\/[^/]+\/[^/]+?\..*$/))};function Ue(t){var e=Fe(S(),2),n=e[0],r=e[1],i=function(t,e){var n=t.branches,r=t.keyboards,i=t.selectedRepoId,a=t.selectedBranchName,s=t.selectedKeyboard,u=(l.Z.repositories||[]).map((function(t){return{id:t.id,name:t.name,full:t.full_name}})),f=(l.Z.installations||[]).map((function(t){return{id:t.id,type:"installation",name:"[Manage available repos for ".concat(t.account.login,"...]")}})),d=(0,c.useMemo)((function(){return[].concat(Bt(u),Bt(f))}),[u,f]),h=(0,c.useMemo)((function(){return n.map((function(t){return{id:t.name,name:t.name,protected:t.protected}}))}),[n]),p=(0,c.useMemo)((function(){return r.map((function(t){return{id:t,name:t}}))}),[r]),y=(0,c.useMemo)((function(){return o()(u,{id:i})}),[u,i]),m=(0,c.useMemo)((function(){return o()(h,{id:a})}),[h,a]),v=(0,c.useMemo)((function(){return o()(p,{id:s})}),[p,s]);return(0,c.useEffect)((function(){i&&kt(Ot().mark((function t(){var n,r;return Ot().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e.loadingBranchesList(),n=o()(l.Z.repositories,{id:i}),t.next=4,l.Z.fetchRepoBranches(n);case 4:r=t.sent,e.loadedBranchesList({branches:r});case 6:case"end":return t.stop()}}),t)})))()}),[i,e]),(0,c.useEffect)((function(){i&&a&&kt(Ot().mark((function t(){var n,r;return Ot().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e.loadingKeyboardsList(),n=o()(l.Z.repositories,{id:i}),t.next=4,l.Z.fetchBranchKeyboards(n,a);case 4:r=t.sent,e.loadedKeyboardsList(r);case 6:case"end":return t.stop()}}),t)})))()}),[i,a,e]),[{repositories:u,repositoryChoices:d,branchChoices:h,keyboardChoices:p},{selectedRepoChoice:y,selectedBranchChoice:m,selectedKeyboardChoice:v}]}(n,r),a=Fe(i,2),s=a[0],u=a[1],f=n.initialized,d=n.selectedRepoId,p=n.selectedBranchName,y=n.selectedKeyboard,v=n.loading,g=t.expanded,b=t.onSelect,A=t.onExpand,x=t.onError;(0,c.useEffect)((function(){var t=function(){return l.Z.beginLoginFlow()},e=function(){r.clearSelection(),x({dialog:G})},n=function(){r.clearSelection(),x({dialog:N.Z})},o=function(t){var e=m;He(t)&&(e=I),ze(t)&&(e=L),Ke(t)&&(e=$),We(t)&&(e=V),r.clearSelection(),x({dialog:e,dialogProps:{title:t.name,errors:t.errors}})};return l.Z.init().then(r.integrationInitialized),l.Z.on("authentication-failed",t),l.Z.on("blocked",e),l.Z.on("repo-validation-error",o),l.Z.on("layout-generation-failed",n),function(){l.Z.off("authentication-failed",t),l.Z.off("blocked",e),l.Z.off("repo-validation-error",o),l.Z.off("layout-generation-failed",n)}}),[r,x]),(0,c.useEffect)((function(){!n.loading&&n.noBranches&&x({dialog:K})}),[n,x]);var w=(0,c.useCallback)(function(){var t,e=(t=Ne().mark((function t(e,n,i){var a,c,u,f,d,h;return Ne().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return u=l.Z.repositories,f=null===(a=o()(u,{id:e}))||void 0===a?void 0:a.full_name,d=null===(c=o()(s.branchChoices,{id:n}))||void 0===c?void 0:c.protected,r.keyboardLoading(),t.next=6,l.Z.fetchLayoutAndKeymap(f,n,{keyboard:i});case 6:h=t.sent,r.keyboardLoadedSuccess({response:h}),b(Re({github:{repository:f,branch:n,keyboard:i,isProtected:d}},h));case 9:case"end":return t.stop()}}),t)})),function(){var e=this,n=arguments;return new Promise((function(r,o){var i=t.apply(e,n);function a(t){Ye(i,r,o,a,c,"next",t)}function c(t){Ye(i,r,o,a,c,"throw",t)}a(void 0)}))});return function(t,n,r){return e.apply(this,arguments)}}(),[r,s.branchChoices,b]),j=(0,c.useCallback)((function(){return w(d,p,y)}),[w,d,p,y]);return(0,c.useEffect)((function(){d&&p&&w(d,p,y)}),[d,p,y,w]),f?n.blocked?(0,h.jsx)(G,{}):l.Z.isGitHubAuthorized()?l.Z.isAppSuspendedForRepoSelection()?(0,h.jsx)(T,{installation:l.Z.installations[0]}):l.Z.isAppInstalled()?(0,h.jsxs)(h.Fragment,{children:[g?(0,h.jsx)(At,{state:n,actions:r,choices:s,selections:u}):(0,h.jsx)(Et,{onExpand:A,state:n,actions:r,choices:s,selections:u}),p&&!v&&(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(k.zx,{onClick:j,children:(0,h.jsx)(z.Z,{name:"sync"})}),(0,h.jsx)(Me,{state:n,actions:r})]})]}):(0,h.jsx)(H,{}):(0,h.jsx)(F,{}):null}Ue.propTypes={expanded:u().bool.isRequired,onExpand:u().func.isRequired,onError:u().func.isRequired,onSelect:u().func.isRequired};var Ve=Ue},56281:function(t,e,n){"use strict";var r=n(87537),o=n.n(r),i=n(23645),a=n.n(i)()(o());a.push([t.id,"button.pi2Ig8c3Fdh4H2Jpxdo7 {\n display: inline-block;\n cursor: pointer;\n background-color: var(--hover-selection);\n color: white;\n\n font-size: 16px;\n border: none;\n border-radius: 5px;\n padding: 0 5px;\n\n height: 30px;\n line-height: 30px;\n vertical-align: middle;\n}\n\nbutton.Ctpu4E2dZYJ6g8CUGFOF {\n color: var(--fg);\n background-color: transparent;\n}\n\nbutton.pi2Ig8c3Fdh4H2Jpxdo7[disabled] {\n filter: saturate(20%);\n opacity: .5;\n cursor: not-allowed;\n}\n","",{version:3,sources:["webpack://./src/Common/action-button.module.css"],names:[],mappings:"AAAA;EACE,qBAAqB;EACrB,eAAe;EACf,wCAAwC;EACxC,YAAY;;EAEZ,eAAe;EACf,YAAY;EACZ,kBAAkB;EAClB,cAAc;;EAEd,YAAY;EACZ,iBAAiB;EACjB,sBAAsB;AACxB;;AAEA;EACE,gBAAgB;EAChB,6BAA6B;AAC/B;;AAEA;EACE,qBAAqB;EACrB,WAAW;EACX,mBAAmB;AACrB",sourcesContent:["button.action {\n display: inline-block;\n cursor: pointer;\n background-color: var(--hover-selection);\n color: white;\n\n font-size: 16px;\n border: none;\n border-radius: 5px;\n padding: 0 5px;\n\n height: 30px;\n line-height: 30px;\n vertical-align: middle;\n}\n\nbutton.secondary {\n color: var(--fg);\n background-color: transparent;\n}\n\nbutton.action[disabled] {\n filter: saturate(20%);\n opacity: .5;\n cursor: not-allowed;\n}\n"],sourceRoot:""}]),a.locals={action:"pi2Ig8c3Fdh4H2Jpxdo7",secondary:"Ctpu4E2dZYJ6g8CUGFOF"},e.Z=a},56634:function(t,e,n){"use strict";var r=n(87537),o=n.n(r),i=n(23645),a=n.n(i)()(o());a.push([t.id,".Jzs3iq1rDP5C8GJijmFR {\n position: relative;\n}\n\n.NaSZTgWxjXTcejbI5OvU {\n border: none;\n background: none;\n}\n.NaSZTgWxjXTcejbI5OvU:hover {\n cursor: pointer;;\n}\n\n.jThiLc5_BrUyl71v3rKn {\n display: inline-block;\n position: absolute;\n top: 100%;\n left: 0;\n width: max-content;\n z-index: 1;\n font-size: 70%;\n padding: 5px 10px;\n\n border-radius: 4px;\n}\n\n.jThiLc5_BrUyl71v3rKn p {\n display: inline-block;\n cursor: pointer;\n margin: 0;\n}\n\n.jThiLc5_BrUyl71v3rKn ul {\n display: none;\n}\n.jThiLc5_BrUyl71v3rKn.xG2GKlsc07jLEb2aMC6H {\n background: var(--dialog-bg, var(--bg));\n box-shadow: 2px 2px 5px 0px rgba(0, 0, 0, 0.5);\n}\n.jThiLc5_BrUyl71v3rKn.xG2GKlsc07jLEb2aMC6H ul {\n display: block;\n padding: 0;\n margin: 0;\n list-style-type: none;\n}\n\n.jThiLc5_BrUyl71v3rKn li {\n cursor: pointer;\n margin: 2px 0;\n line-height: 20px;\n padding: 0 5px;\n border-radius: 10px;\n}\n\n.jThiLc5_BrUyl71v3rKn li:hover {\n background-color: var(--hover-selection);\n color: white;\n}\n","",{version:3,sources:["webpack://./src/Common/action-menu.module.css"],names:[],mappings:"AAAA;EACE,kBAAkB;AACpB;;AAEA;EACE,YAAY;EACZ,gBAAgB;AAClB;AACA;EACE,eAAe;AACjB;;AAEA;EACE,qBAAqB;EACrB,kBAAkB;EAClB,SAAS;EACT,OAAO;EACP,kBAAkB;EAClB,UAAU;EACV,cAAc;EACd,iBAAiB;;EAEjB,kBAAkB;AACpB;;AAEA;EACE,qBAAqB;EACrB,eAAe;EACf,SAAS;AACX;;AAEA;EACE,aAAa;AACf;AACA;EACE,uCAAuC;EACvC,8CAA8C;AAChD;AACA;EACE,cAAc;EACd,UAAU;EACV,SAAS;EACT,qBAAqB;AACvB;;AAEA;EACE,eAAe;EACf,aAAa;EACb,iBAAiB;EACjB,cAAc;EACd,mBAAmB;AACrB;;AAEA;EACE,wCAAwC;EACxC,YAAY;AACd",sourcesContent:[".wrapper {\n position: relative;\n}\n\n.button {\n border: none;\n background: none;\n}\n.button:hover {\n cursor: pointer;;\n}\n\n.menu {\n display: inline-block;\n position: absolute;\n top: 100%;\n left: 0;\n width: max-content;\n z-index: 1;\n font-size: 70%;\n padding: 5px 10px;\n\n border-radius: 4px;\n}\n\n.menu p {\n display: inline-block;\n cursor: pointer;\n margin: 0;\n}\n\n.menu ul {\n display: none;\n}\n.menu.open {\n background: var(--dialog-bg, var(--bg));\n box-shadow: 2px 2px 5px 0px rgba(0, 0, 0, 0.5);\n}\n.menu.open ul {\n display: block;\n padding: 0;\n margin: 0;\n list-style-type: none;\n}\n\n.menu li {\n cursor: pointer;\n margin: 2px 0;\n line-height: 20px;\n padding: 0 5px;\n border-radius: 10px;\n}\n\n.menu li:hover {\n background-color: var(--hover-selection);\n color: white;\n}\n"],sourceRoot:""}]),a.locals={wrapper:"Jzs3iq1rDP5C8GJijmFR",button:"NaSZTgWxjXTcejbI5OvU",menu:"jThiLc5_BrUyl71v3rKn",open:"xG2GKlsc07jLEb2aMC6H"},e.Z=a},33988:function(t,e,n){"use strict";var r=n(87537),o=n.n(r),i=n(23645),a=n.n(i)()(o());a.push([t.id,".OaJISbD1WCmb03at77EG {\n position: relative;\n}\n\n.MUN9De8dUvbPGH9cEDoQ {\n position: absolute;\n z-index: 10;\n bottom: 0;\n left: 50%;\n transform: translate(-50%, 100%);\n max-width: 250px;\n width: 100%;\n\n border-radius: 4px;\n padding: 3px 5px;\n\n color: white;\n background-color: var(--error-highlight);\n font-size: 85%;\n font-family: sans-serif;\n\n opacity: 0.9;\n}\n.MUN9De8dUvbPGH9cEDoQ::before {\n position: absolute;\n display: block;\n content: ' ';\n z-index: -1;\n\n left: 50%;\n width: 10px;\n height: 10px;\n\n background-color: var(--error-highlight);\n transform: translate(-50%, -7px) rotate(45deg);\n}\n","",{version:3,sources:["webpack://./src/Common/input.module.css"],names:[],mappings:"AAAA;EACE,kBAAkB;AACpB;;AAEA;EACE,kBAAkB;EAClB,WAAW;EACX,SAAS;EACT,SAAS;EACT,gCAAgC;EAChC,gBAAgB;EAChB,WAAW;;EAEX,kBAAkB;EAClB,gBAAgB;;EAEhB,YAAY;EACZ,wCAAwC;EACxC,cAAc;EACd,uBAAuB;;EAEvB,YAAY;AACd;AACA;EACE,kBAAkB;EAClB,cAAc;EACd,YAAY;EACZ,WAAW;;EAEX,SAAS;EACT,WAAW;EACX,YAAY;;EAEZ,wCAAwC;EACxC,8CAA8C;AAChD",sourcesContent:[".wrapper {\n position: relative;\n}\n\n.error {\n position: absolute;\n z-index: 10;\n bottom: 0;\n left: 50%;\n transform: translate(-50%, 100%);\n max-width: 250px;\n width: 100%;\n\n border-radius: 4px;\n padding: 3px 5px;\n\n color: white;\n background-color: var(--error-highlight);\n font-size: 85%;\n font-family: sans-serif;\n\n opacity: 0.9;\n}\n.error::before {\n position: absolute;\n display: block;\n content: ' ';\n z-index: -1;\n\n left: 50%;\n width: 10px;\n height: 10px;\n\n background-color: var(--error-highlight);\n transform: translate(-50%, -7px) rotate(45deg);\n}\n"],sourceRoot:""}]),a.locals={wrapper:"OaJISbD1WCmb03at77EG",error:"MUN9De8dUvbPGH9cEDoQ"},e.Z=a},59303:function(t,e,n){"use strict";var r=n(87537),o=n.n(r),i=n(23645),a=n.n(i)()(o());a.push([t.id,".RFVMBguaCs9auF7gm6DQ {\n max-width: fit-content;\n max-height: 60vh;\n overflow: auto;\n background-color: var(--code-bg);\n border-radius: 2px;\n padding: .15em .3em .05em;\n}\n\n._HrMiJ3KuZaYWO79HsSs {\n position: absolute;\n top: 15px;\n right: 15px;\n padding: 4px 7px;\n color: var(--key-color-base);\n background-color: var(--key-bg-base);\n border: 1px solid var(--key-color-base);\n border-radius: 3px;\n}\n._HrMiJ3KuZaYWO79HsSs:hover {\n cursor: pointer;\n background-color: var(--selection);\n border: var(--selection);\n color: white;\n}\n\n.Do4TDnmJm_28Bnk7CQwm {\n position: absolute;\n top: 5px;\n right: 0px;\n background-color: var(--selection);\n color: white;\n padding: 10px;\n border-radius: 2px;\n cursor: none;\n}\n","",{version:3,sources:["webpack://./src/Common/snippet.module.css"],names:[],mappings:"AAAA;EACE,sBAAsB;EACtB,gBAAgB;EAChB,cAAc;EACd,gCAAgC;EAChC,kBAAkB;EAClB,yBAAyB;AAC3B;;AAEA;EACE,kBAAkB;EAClB,SAAS;EACT,WAAW;EACX,gBAAgB;EAChB,4BAA4B;EAC5B,oCAAoC;EACpC,uCAAuC;EACvC,kBAAkB;AACpB;AACA;EACE,eAAe;EACf,kCAAkC;EAClC,wBAAwB;EACxB,YAAY;AACd;;AAEA;EACE,kBAAkB;EAClB,QAAQ;EACR,UAAU;EACV,kCAAkC;EAClC,YAAY;EACZ,aAAa;EACb,kBAAkB;EAClB,YAAY;AACd",sourcesContent:[".code {\n max-width: fit-content;\n max-height: 60vh;\n overflow: auto;\n background-color: var(--code-bg);\n border-radius: 2px;\n padding: .15em .3em .05em;\n}\n\n.button {\n position: absolute;\n top: 15px;\n right: 15px;\n padding: 4px 7px;\n color: var(--key-color-base);\n background-color: var(--key-bg-base);\n border: 1px solid var(--key-color-base);\n border-radius: 3px;\n}\n.button:hover {\n cursor: pointer;\n background-color: var(--selection);\n border: var(--selection);\n color: white;\n}\n\n.copyMessage {\n position: absolute;\n top: 5px;\n right: 0px;\n background-color: var(--selection);\n color: white;\n padding: 10px;\n border-radius: 2px;\n cursor: none;\n}\n"],sourceRoot:""}]),a.locals={code:"RFVMBguaCs9auF7gm6DQ",button:"_HrMiJ3KuZaYWO79HsSs",copyMessage:"Do4TDnmJm_28Bnk7CQwm"},e.Z=a},92127:function(t,e,n){"use strict";var r=n(87537),o=n.n(r),i=n(23645),a=n.n(i)()(o());a.push([t.id,".FMkASzwt_oMscZdObpDQ {\n display: inline-block;\n text-align: center;\n}\n.TNF6aRMBPANvZifB27ZK {\n display: inline-block;\n animation: GGCs7iiBiwDCnT80cyTh 1s linear infinite;\n}\n\n@keyframes GGCs7iiBiwDCnT80cyTh {\n from { transform: rotate(0deg); }\n to { transform: rotate(360deg); }\n}","",{version:3,sources:["webpack://./src/Common/spinner.module.css"],names:[],mappings:"AAAA;EACE,qBAAqB;EACrB,kBAAkB;AACpB;AACA;EACE,qBAAqB;EACrB,kDAAkC;AACpC;;AAEA;EACE,OAAO,uBAAuB,EAAE;EAChC,KAAK,yBAAyB,EAAE;AAClC",sourcesContent:[".spinner {\n display: inline-block;\n text-align: center;\n}\n.icon {\n display: inline-block;\n animation: spin 1s linear infinite;\n}\n\n@keyframes spin {\n from { transform: rotate(0deg); }\n to { transform: rotate(360deg); }\n}"],sourceRoot:""}]),a.locals={spinner:"FMkASzwt_oMscZdObpDQ",icon:"TNF6aRMBPANvZifB27ZK",spin:"GGCs7iiBiwDCnT80cyTh"},e.Z=a},80047:function(t,e,n){"use strict";var r=n(87537),o=n.n(r),i=n(23645),a=n.n(i)()(o());a.push([t.id,".z8z3GXuYqlepCz4tRPZj {\n cursor: pointer;\n display: flex;\n box-sizing: border-box;\n border-width: 1px;\n text-align: left;\n border-radius: 4px;\n gap: 5px;\n height: 38px;\n padding: 0 8px;\n\n /* color: hsl(0, 0%, 20%); */\n}\n\n.z8z3GXuYqlepCz4tRPZj:hover {\n background-color: var(--hover-selection);\n color: white;\n}\n\n.yyHfal9pM4DzShMl4LAY {\n display: inline-flex;\n height: 30px;\n border-radius: 5px;\n align-items: center;\n\n font-size: 70%;\n padding: 0 4px;\n\n background-color: royalblue;\n color: white;\n text-decoration: none;\n}\n\n.ukdycT4tarWVlV3PC6Rr {\n display: flex;\n height: 38px;\n gap: 4px;\n}\n\n.ukdycT4tarWVlV3PC6Rr button,\n.ukdycT4tarWVlV3PC6Rr .yyHfal9pM4DzShMl4LAY {\n height: 38px !important;\n}\n\n.yyHfal9pM4DzShMl4LAY code {\n font-family: monospace;\n}\n\n.QvI5wo7_u6OeAc12ib0W {\n width: 30px;\n height: 30px;\n line-height: 30px;\n font-size: 200%;\n text-align: center;\n}\n\n.eUw5NZqoPPF3BcyYDpJx {\n /* color: var(--selection); */\n}\n\n.XjY4lN_lY3nSgHcw67bX {\n /* color: brown; */\n}\n\n.Ap_OwCtp3j1Q29Phpw3V {\n color: gold;\n animation: WjBuPfls4V41d2sjbNFU 1s linear alternate infinite;\n}\n\n@keyframes WjBuPfls4V41d2sjbNFU {\n from { opacity: 0.5; }\n to { opacity: 1; }\n}\n","",{version:3,sources:["webpack://./src/Sources/Github/styles.module.css"],names:[],mappings:"AAAA;EACE,eAAe;EACf,aAAa;EACb,sBAAsB;EACtB,iBAAiB;EACjB,gBAAgB;EAChB,kBAAkB;EAClB,QAAQ;EACR,YAAY;EACZ,cAAc;;EAEd,4BAA4B;AAC9B;;AAEA;EACE,wCAAwC;EACxC,YAAY;AACd;;AAEA;EACE,oBAAoB;EACpB,YAAY;EACZ,kBAAkB;EAClB,mBAAmB;;EAEnB,cAAc;EACd,cAAc;;EAEd,2BAA2B;EAC3B,YAAY;EACZ,qBAAqB;AACvB;;AAEA;EACE,aAAa;EACb,YAAY;EACZ,QAAQ;AACV;;AAEA;;EAEE,uBAAuB;AACzB;;AAEA;EACE,sBAAsB;AACxB;;AAEA;EACE,WAAW;EACX,YAAY;EACZ,iBAAiB;EACjB,eAAe;EACf,kBAAkB;AACpB;;AAEA;EACE,6BAA6B;AAC/B;;AAEA;EACE,kBAAkB;AACpB;;AAEA;EACE,WAAW;EACX,4DAA6C;AAC/C;;AAEA;EACE,OAAO,YAAY,EAAE;EACrB,KAAK,UAAU,EAAE;AACnB",sourcesContent:[".compactWrapper {\n cursor: pointer;\n display: flex;\n box-sizing: border-box;\n border-width: 1px;\n text-align: left;\n border-radius: 4px;\n gap: 5px;\n height: 38px;\n padding: 0 8px;\n\n /* color: hsl(0, 0%, 20%); */\n}\n\n.compactWrapper:hover {\n background-color: var(--hover-selection);\n color: white;\n}\n\n.buildDetails {\n display: inline-flex;\n height: 30px;\n border-radius: 5px;\n align-items: center;\n\n font-size: 70%;\n padding: 0 4px;\n\n background-color: royalblue;\n color: white;\n text-decoration: none;\n}\n\n.pickerActions {\n display: flex;\n height: 38px;\n gap: 4px;\n}\n\n.pickerActions button,\n.pickerActions .buildDetails {\n height: 38px !important;\n}\n\n.buildDetails code {\n font-family: monospace;\n}\n\n.buildStatus {\n width: 30px;\n height: 30px;\n line-height: 30px;\n font-size: 200%;\n text-align: center;\n}\n\n.buildSuccess {\n /* color: var(--selection); */\n}\n\n.buildFailed {\n /* color: brown; */\n}\n\n.buildPending {\n color: gold;\n animation: pulse 1s linear alternate infinite;\n}\n\n@keyframes pulse {\n from { opacity: 0.5; }\n to { opacity: 1; }\n}\n"],sourceRoot:""}]),a.locals={compactWrapper:"z8z3GXuYqlepCz4tRPZj",buildDetails:"yyHfal9pM4DzShMl4LAY",pickerActions:"ukdycT4tarWVlV3PC6Rr",buildStatus:"QvI5wo7_u6OeAc12ib0W",buildSuccess:"eUw5NZqoPPF3BcyYDpJx",buildFailed:"XjY4lN_lY3nSgHcw67bX",buildPending:"Ap_OwCtp3j1Q29Phpw3V",pulse:"WjBuPfls4V41d2sjbNFU"},e.Z=a},27484:function(t){t.exports=function(){"use strict";var t=6e4,e=36e5,n="millisecond",r="second",o="minute",i="hour",a="day",c="week",s="month",u="quarter",l="year",f="date",d="Invalid Date",h=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,p=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,y={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],n=t%100;return"["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}},m=function(t,e,n){var r=String(t);return!r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},v={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),o=n%60;return(e<=0?"+":"-")+m(r,2,"0")+":"+m(o,2,"0")},m:function t(e,n){if(e.date()<n.date())return-t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),o=e.clone().add(r,s),i=n-o<0,a=e.clone().add(r+(i?-1:1),s);return+(-(r+(n-o)/(i?o-a:a-o))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:s,y:l,w:c,d:a,D:f,h:i,m:o,s:r,ms:n,Q:u}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},g="en",b={};b[g]=y;var A=function(t){return t instanceof E},x=function t(e,n,r){var o;if(!e)return g;if("string"==typeof e){var i=e.toLowerCase();b[i]&&(o=i),n&&(b[i]=n,o=i);var a=e.split("-");if(!o&&a.length>1)return t(a[0])}else{var c=e.name;b[c]=e,o=c}return!r&&o&&(g=o),o||!r&&g},w=function(t,e){if(A(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new E(n)},j=v;j.l=x,j.i=A,j.w=function(t,e){return w(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var E=function(){function y(t){this.$L=x(t.locale,null,!0),this.parse(t)}var m=y.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(j.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match(h);if(r){var o=r[2]-1||0,i=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],o,r[3]||1,r[4]||0,r[5]||0,r[6]||0,i)):new Date(r[1],o,r[3]||1,r[4]||0,r[5]||0,r[6]||0,i)}}return new Date(e)}(t),this.$x=t.x||{},this.init()},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},m.$utils=function(){return j},m.isValid=function(){return!(this.$d.toString()===d)},m.isSame=function(t,e){var n=w(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return w(t)<this.startOf(e)},m.isBefore=function(t,e){return this.endOf(e)<w(t)},m.$g=function(t,e,n){return j.u(t)?this[e]:this.set(n,t)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(t,e){var n=this,u=!!j.u(e)||e,d=j.p(t),h=function(t,e){var r=j.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return u?r:r.endOf(a)},p=function(t,e){return j.w(n.toDate()[t].apply(n.toDate("s"),(u?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},y=this.$W,m=this.$M,v=this.$D,g="set"+(this.$u?"UTC":"");switch(d){case l:return u?h(1,0):h(31,11);case s:return u?h(1,m):h(0,m+1);case c:var b=this.$locale().weekStart||0,A=(y<b?y+7:y)-b;return h(u?v-A:v+(6-A),m);case a:case f:return p(g+"Hours",0);case i:return p(g+"Minutes",1);case o:return p(g+"Seconds",2);case r:return p(g+"Milliseconds",3);default:return this.clone()}},m.endOf=function(t){return this.startOf(t,!1)},m.$set=function(t,e){var c,u=j.p(t),d="set"+(this.$u?"UTC":""),h=(c={},c[a]=d+"Date",c[f]=d+"Date",c[s]=d+"Month",c[l]=d+"FullYear",c[i]=d+"Hours",c[o]=d+"Minutes",c[r]=d+"Seconds",c[n]=d+"Milliseconds",c)[u],p=u===a?this.$D+(e-this.$W):e;if(u===s||u===l){var y=this.clone().set(f,1);y.$d[h](p),y.init(),this.$d=y.set(f,Math.min(this.$D,y.daysInMonth())).$d}else h&&this.$d[h](p);return this.init(),this},m.set=function(t,e){return this.clone().$set(t,e)},m.get=function(t){return this[j.p(t)]()},m.add=function(n,u){var f,d=this;n=Number(n);var h=j.p(u),p=function(t){var e=w(d);return j.w(e.date(e.date()+Math.round(t*n)),d)};if(h===s)return this.set(s,this.$M+n);if(h===l)return this.set(l,this.$y+n);if(h===a)return p(1);if(h===c)return p(7);var y=(f={},f[o]=t,f[i]=e,f[r]=1e3,f)[h]||1,m=this.$d.getTime()+n*y;return j.w(m,this)},m.subtract=function(t,e){return this.add(-1*t,e)},m.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||d;var r=t||"YYYY-MM-DDTHH:mm:ssZ",o=j.z(this),i=this.$H,a=this.$m,c=this.$M,s=n.weekdays,u=n.months,l=function(t,n,o,i){return t&&(t[n]||t(e,r))||o[n].slice(0,i)},f=function(t){return j.s(i%12||12,t,"0")},h=n.meridiem||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r},y={YY:String(this.$y).slice(-2),YYYY:this.$y,M:c+1,MM:j.s(c+1,2,"0"),MMM:l(n.monthsShort,c,u,3),MMMM:l(u,c),D:this.$D,DD:j.s(this.$D,2,"0"),d:String(this.$W),dd:l(n.weekdaysMin,this.$W,s,2),ddd:l(n.weekdaysShort,this.$W,s,3),dddd:s[this.$W],H:String(i),HH:j.s(i,2,"0"),h:f(1),hh:f(2),a:h(i,a,!0),A:h(i,a,!1),m:String(a),mm:j.s(a,2,"0"),s:String(this.$s),ss:j.s(this.$s,2,"0"),SSS:j.s(this.$ms,3,"0"),Z:o};return r.replace(p,(function(t,e){return e||y[t]||o.replace(":","")}))},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(n,f,d){var h,p=j.p(f),y=w(n),m=(y.utcOffset()-this.utcOffset())*t,v=this-y,g=j.m(this,y);return g=(h={},h[l]=g/12,h[s]=g,h[u]=g/3,h[c]=(v-m)/6048e5,h[a]=(v-m)/864e5,h[i]=v/e,h[o]=v/t,h[r]=v/1e3,h)[p]||v,d?g:j.a(g)},m.daysInMonth=function(){return this.endOf(s).$D},m.$locale=function(){return b[this.$L]},m.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=x(t,e,!0);return r&&(n.$L=r),n},m.clone=function(){return j.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},y}(),C=E.prototype;return w.prototype=C,[["$ms",n],["$s",r],["$m",o],["$H",i],["$W",a],["$M",s],["$y",l],["$D",f]].forEach((function(t){C[t[1]]=function(e){return this.$g(e,t[0],t[1])}})),w.extend=function(t,e){return t.$i||(t(e,E,w),t.$i=!0),w},w.locale=x,w.isDayjs=A,w.unix=function(t){return w(1e3*t)},w.en=b[g],w.Ls=b,w.p={},w}()},84110:function(t){t.exports=function(){"use strict";return function(t,e,n){t=t||{};var r=e.prototype,o={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function i(t,e,n,o){return r.fromToBase(t,e,n,o)}n.en.relativeTime=o,r.fromToBase=function(e,r,i,a,c){for(var s,u,l,f=i.$locale().relativeTime||o,d=t.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],h=d.length,p=0;p<h;p+=1){var y=d[p];y.d&&(s=a?n(e).diff(i,y.d,!0):i.diff(e,y.d,!0));var m=(t.rounding||Math.round)(Math.abs(s));if(l=s>0,m<=y.r||!y.r){m<=1&&p>0&&(y=d[p-1]);var v=f[y.l];c&&(m=c(""+m)),u="string"==typeof v?v.replace("%d",m):v(m,r,y.l,l);break}}if(r)return u;var g=l?f.future:f.past;return"function"==typeof g?g(u):g.replace("%s",u)},r.to=function(t,e){return i(t,e,this,!0)},r.from=function(t,e){return i(t,e,this)};var a=function(t){return t.$u?n.utc():n()};r.toNow=function(t){return this.to(a(this),t)},r.fromNow=function(t){return this.from(a(this),t)}}}()},69199:function(t,e,n){var r=n(89881),o=n(98612);t.exports=function(t,e){var n=-1,i=o(t)?Array(t.length):[];return r(t,(function(t,r,o){i[++n]=e(t,r,o)})),i}},66379:function(t,e,n){var r=n(2958),o=n(1499);t.exports=function(t,e){return t===e||r(t,e,o(e))}},35161:function(t,e,n){var r=n(29932),o=n(67206),i=n(69199),a=n(1469);t.exports=function(t,e){return(a(t)?r:i)(t,o(e,3))}},66317:function(){},99918:function(){}}]);
//# sourceMappingURL=GithubPicker.09b2a104816c9e2d266a.js.map
|