{"version":3,"names":["window","define","_exports","_pluginApi","_deprecated","Object","defineProperty","value","default","require","getObjectForTheme","name","after","initialize","id","url","withPluginApi","api","currentUser","getCurrentUser","console","log","addSidebarSection","BaseCustomSidebarSection","BaseCustomSidebarSectionLink","text","actionsIcon","links","classNames","route","models","title","prefixType","prefixValue","prefixBadge","suffixType","suffixValue","suffixCSSClass"],"sourceRoot":"theme-1/","sources":["discourse/initializers/theme-field-3-common-html-script-1.js"],"sourcesContent":["if ('define' in window) {\ndefine(\"discourse/theme-1/discourse/initializers/theme-field-3-common-html-script-1\", [\"exports\", \"discourse/lib/plugin-api\", \"discourse/lib/deprecated\"], function (_exports, _pluginApi, _deprecated) {\n  \"use strict\";\n\n  Object.defineProperty(_exports, \"__esModule\", {\n    value: true\n  });\n  _exports.default = void 0;\n  const settings = require(\"discourse/lib/theme-settings-store\").getObjectForTheme(1);\n  const themePrefix = key => `theme_translations.1.${key}`;\n  var _default = _exports.default = {\n    name: \"theme-field-3-common-html-script-1\",\n    after: \"inject-objects\",\n    initialize() {\n      (0, _deprecated.default)(\"Adding JS code using <script type='text/discourse-plugin'> is deprecated. Move this code to a dedicated JavaScript file.\", {\n        id: \"discourse.script-tag-discourse-plugin\",\n        url: \"https://meta.discourse.org/t/366482\"\n      });\n      (0, _pluginApi.withPluginApi)(\"0.8.22\", api => {\n        // api.decorateWidget('header-buttons:after', helper => {\n        let currentUser = api.getCurrentUser();\n        if (!currentUser) return;\n        //     return helper.h('li.custom-login-button-li', [\n        //         helper.h('button.icon.btn-flat', { href: 'ENTER URL HERE', target: '_blank'}, helper.h('svg.fa.fa-user.d-icon-lock'))\n        //     ]);\n        //});\n        console.log(currentUser);\n        api.addSidebarSection((BaseCustomSidebarSection, BaseCustomSidebarSectionLink) => {\n          return class extends BaseCustomSidebarSection {\n            get name() {\n              return \"building-tools\";\n            }\n            get text() {\n              return \"Facility Tools\";\n            }\n            get actionsIcon() {\n              return \"cog\";\n            }\n            get links() {\n              return [new class extends BaseCustomSidebarSectionLink {\n                get name() {\n                  return \"unlock-big-blue\";\n                }\n                get classNames() {\n                  return \"\";\n                }\n                get route() {\n                  return \"topic\";\n                }\n                get models() {\n                  return [\"some-slug\", 1];\n                }\n                get title() {\n                  return \"Unlock big blue\";\n                }\n                get text() {\n                  return \"Unlock Front Door\";\n                }\n                get prefixType() {\n                  return \"icon\";\n                }\n                get prefixValue() {\n                  return \"lock\";\n                }\n\n                //   get prefixColor() {\n                //     return \"FF0000\";\n                //   }\n\n                get prefixBadge() {\n                  return \"\";\n                }\n                get suffixType() {\n                  return \"icon\";\n                }\n                get suffixValue() {\n                  return \"circle\";\n                }\n                get suffixCSSClass() {\n                  return \"unread\";\n                }\n              }()];\n            }\n          };\n        }, \"new-panel\");\n      });\n    }\n  };\n});\n}\n"],"mappings":"AAAI,WAAYA,QAChBC,OAAO,8EAA+E,CAAC,UAAW,2BAA4B,6BAA6B,SAAUC,EAAUC,EAAYC,GACzL;AAEAC,OAAOC,eAAeJ,EAAU,aAAc,CAC5CK,OAAO,IAETL,EAASM,aAAU;AACFC,QAAQ,sCAAsCC,kBAAkB;AAElER,EAASM,QAAU,CAChCG,KAAM,qCACNC,MAAO,iBACP,UAAAC,IACE,EAAIT,EAAYI,SAAS,2HAA4H,CACnJM,GAAI,wCACJC,IAAK,yCAEP,EAAIZ,EAAWa,eAAe,UAAUC,IAEtC,IAAIC,EAAcD,EAAIE;AACjBD,IAKLE,QAAQC,IAAIH,GACZD,EAAIK,mBAAkB,CAACC,EAA0BC,IACxC,cAAcD,EACnB,QAAIZ,GACF,MAAO,gBACT,CACA,QAAIc,GACF,MAAO,gBACT,CACA,eAAIC,GACF,MAAO,KACT,CACA,SAAIC,GACF,MAAO,CAAC,IAAI,cAAcH,EACxB,QAAIb,GACF,MAAO,iBACT,CACA,cAAIiB,GACF,MAAO,EACT,CACA,SAAIC,GACF,MAAO,OACT,CACA,UAAIC,GACF,MAAO,CAAC,YAAa,EACvB,CACA,SAAIC,GACF,MAAO,iBACT,CACA,QAAIN,GACF,MAAO,mBACT,CACA,cAAIO,GACF,MAAO,MACT,CACA,eAAIC,GACF,MAAO,MACT,CAMA,eAAIC,GACF,MAAO,EACT,CACA,cAAIC,GACF,MAAO,MACT,CACA,eAAIC,GACF,MAAO,QACT,CACA,kBAAIC,GACF,MAAO,QACT,GAEJ,IAED,gBAEP,EAEJ","ignoreList":[]}