diff --git a/js/dist/admin.js b/js/dist/admin.js index fadbd3e..aa5007a 100644 --- a/js/dist/admin.js +++ b/js/dist/admin.js @@ -1,2 +1,2 @@ -(()=>{var t={n:e=>{var r=e&&e.__esModule?()=>e.default:()=>e;return t.d(r,{a:r}),r},d:(e,r)=>{for(var o in r)t.o(r,o)&&!t.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:r[o]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r:t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};(()=>{"use strict";t.r(e);const r=flarum.core.compat["common/app"];t.n(r)().initializers.add("mattoid/flarum-ext-money-history",(function(){console.log("[mattoid/flarum-ext-money-history] Hello, forum and admin!")}));const o=flarum.core.compat["admin/app"];var i=t.n(o);i().initializers.add("mattoid-money-history",(function(){i().extensionData.for("mattoid-money-history").registerSetting({setting:"mattoid-money-history.request-type-get",help:i().translator.trans("mattoid-money-history.admin.settings.request-type-get-requirement"),label:i().translator.trans("mattoid-money-history.admin.settings.request-type-get"),type:"switch",default:!1}).registerSetting({setting:"mattoid-money-history.request-type-post",help:i().translator.trans("mattoid-money-history.admin.settings.type-requirement"),label:i().translator.trans("mattoid-money-history.admin.settings.request-type-post"),type:"switch",default:!0}).registerSetting({setting:"mattoid-money-history.request-type-put",help:i().translator.trans("mattoid-money-history.admin.settings.type-requirement"),label:i().translator.trans("mattoid-money-history.admin.settings.request-type-put"),type:"switch",default:!0}).registerSetting({setting:"mattoid-money-history.request-type-delete",help:i().translator.trans("mattoid-money-history.admin.settings.type-requirement"),label:i().translator.trans("mattoid-money-history.admin.settings.request-type-delete"),type:"switch",default:!0})}))})(),module.exports=e})(); +(()=>{var o={n:e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t},d:(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o:(o,e)=>Object.prototype.hasOwnProperty.call(o,e),r:o=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(o,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(o,"__esModule",{value:!0})}},e={};(()=>{"use strict";o.r(e);const t=flarum.core.compat["common/app"];o.n(t)().initializers.add("mattoid/flarum-ext-money-history",(function(){console.log("[mattoid/flarum-ext-money-history] Hello, forum and admin!")}));const r=flarum.core.compat["admin/app"];o.n(r)().initializers.add("mattoid/flarum-ext-money-history",(function(){console.log("[mattoid/flarum-ext-money-history] Hello, forum and admin!")}))})(),module.exports=e})(); //# sourceMappingURL=admin.js.map \ No newline at end of file diff --git a/js/dist/admin.js.map b/js/dist/admin.js.map index 0f2e6b3..e3e5c37 100644 --- a/js/dist/admin.js.map +++ b/js/dist/admin.js.map @@ -1 +1 @@ -{"version":3,"file":"admin.js","mappings":"MACA,IAAIA,EAAsB,CCA1BA,EAAyBC,IACxB,IAAIC,EAASD,GAAUA,EAAOE,WAC7B,IAAOF,EAAiB,QACxB,IAAM,EAEP,OADAD,EAAoBI,EAAEF,EAAQ,CAAEG,EAAGH,IAC5BA,CAAM,ECLdF,EAAwB,CAACM,EAASC,KACjC,IAAI,IAAIC,KAAOD,EACXP,EAAoBS,EAAEF,EAAYC,KAASR,EAAoBS,EAAEH,EAASE,IAC5EE,OAAOC,eAAeL,EAASE,EAAK,CAAEI,YAAY,EAAMC,IAAKN,EAAWC,IAE1E,ECNDR,EAAwB,CAACc,EAAKC,IAAUL,OAAOM,UAAUC,eAAeC,KAAKJ,EAAKC,GCClFf,EAAyBM,IACH,oBAAXa,QAA0BA,OAAOC,aAC1CV,OAAOC,eAAeL,EAASa,OAAOC,YAAa,CAAEC,MAAO,WAE7DX,OAAOC,eAAeL,EAAS,aAAc,CAAEe,OAAO,GAAO,G,+BCL9D,MAAM,EAA+BC,OAAOC,KAAKC,OAAO,c,MCExDC,GAAAA,aAAiBC,IAAI,oCAAoC,WACvDC,QAAQC,IAAI,6DACd,ICJA,MAAM,EAA+BN,OAAOC,KAAKC,OAAO,a,aCExDC,IAAAA,aAAiBC,IAAI,yBAAyB,WAC5CD,IAAAA,cAAiB,IAAK,yBACnBI,gBAAgB,CACfC,QAAS,yCACTC,KAAMN,IAAAA,WAAeO,MAAM,qEAC3BC,MAAOR,IAAAA,WAAeO,MAAM,yDAC5BE,KAAM,SACNC,SAAS,IAEVN,gBAAgB,CACfC,QAAS,0CACTC,KAAMN,IAAAA,WAAeO,MAAM,yDAC3BC,MAAOR,IAAAA,WAAeO,MAAM,0DAC5BE,KAAM,SACNC,SAAS,IAEVN,gBAAgB,CACfC,QAAS,yCACTC,KAAMN,IAAAA,WAAeO,MAAM,yDAC3BC,MAAOR,IAAAA,WAAeO,MAAM,yDAC5BE,KAAM,SACNC,SAAS,IAEVN,gBAAgB,CACfC,QAAS,4CACTC,KAAMN,IAAAA,WAAeO,MAAM,yDAC3BC,MAAOR,IAAAA,WAAeO,MAAM,4DAC5BE,KAAM,SACNC,SAAS,GAEf,G","sources":["webpack://@mattoid/flarum-ext-money-history/webpack/bootstrap","webpack://@mattoid/flarum-ext-money-history/webpack/runtime/compat get default export","webpack://@mattoid/flarum-ext-money-history/webpack/runtime/define property getters","webpack://@mattoid/flarum-ext-money-history/webpack/runtime/hasOwnProperty shorthand","webpack://@mattoid/flarum-ext-money-history/webpack/runtime/make namespace object","webpack://@mattoid/flarum-ext-money-history/external root \"flarum.core.compat['common/app']\"","webpack://@mattoid/flarum-ext-money-history/./src/common/index.ts","webpack://@mattoid/flarum-ext-money-history/external root \"flarum.core.compat['admin/app']\"","webpack://@mattoid/flarum-ext-money-history/./src/admin/index.ts"],"sourcesContent":["// The require scope\nvar __webpack_require__ = {};\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/app'];","import app from 'flarum/common/app';\n\napp.initializers.add('mattoid/flarum-ext-money-history', () => {\n console.log('[mattoid/flarum-ext-money-history] Hello, forum and admin!');\n});\n","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['admin/app'];","import app from 'flarum/admin/app';\n\napp.initializers.add('mattoid-money-history', () => {\n app.extensionData.for(\"mattoid-money-history\")\n .registerSetting({\n setting: 'mattoid-money-history.request-type-get',\n help: app.translator.trans('mattoid-money-history.admin.settings.request-type-get-requirement'),\n label: app.translator.trans('mattoid-money-history.admin.settings.request-type-get'),\n type: 'switch',\n default: false\n })\n .registerSetting({\n setting: 'mattoid-money-history.request-type-post',\n help: app.translator.trans('mattoid-money-history.admin.settings.type-requirement'),\n label: app.translator.trans('mattoid-money-history.admin.settings.request-type-post'),\n type: 'switch',\n default: true\n })\n .registerSetting({\n setting: 'mattoid-money-history.request-type-put',\n help: app.translator.trans('mattoid-money-history.admin.settings.type-requirement'),\n label: app.translator.trans('mattoid-money-history.admin.settings.request-type-put'),\n type: 'switch',\n default: true\n })\n .registerSetting({\n setting: 'mattoid-money-history.request-type-delete',\n help: app.translator.trans('mattoid-money-history.admin.settings.type-requirement'),\n label: app.translator.trans('mattoid-money-history.admin.settings.request-type-delete'),\n type: 'switch',\n default: true\n })\n});\n"],"names":["__webpack_require__","module","getter","__esModule","d","a","exports","definition","key","o","Object","defineProperty","enumerable","get","obj","prop","prototype","hasOwnProperty","call","Symbol","toStringTag","value","flarum","core","compat","app","add","console","log","registerSetting","setting","help","trans","label","type","default"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"admin.js","mappings":"MACA,IAAIA,EAAsB,CCA1BA,EAAyBC,IACxB,IAAIC,EAASD,GAAUA,EAAOE,WAC7B,IAAOF,EAAiB,QACxB,IAAM,EAEP,OADAD,EAAoBI,EAAEF,EAAQ,CAAEG,EAAGH,IAC5BA,CAAM,ECLdF,EAAwB,CAACM,EAASC,KACjC,IAAI,IAAIC,KAAOD,EACXP,EAAoBS,EAAEF,EAAYC,KAASR,EAAoBS,EAAEH,EAASE,IAC5EE,OAAOC,eAAeL,EAASE,EAAK,CAAEI,YAAY,EAAMC,IAAKN,EAAWC,IAE1E,ECNDR,EAAwB,CAACc,EAAKC,IAAUL,OAAOM,UAAUC,eAAeC,KAAKJ,EAAKC,GCClFf,EAAyBM,IACH,oBAAXa,QAA0BA,OAAOC,aAC1CV,OAAOC,eAAeL,EAASa,OAAOC,YAAa,CAAEC,MAAO,WAE7DX,OAAOC,eAAeL,EAAS,aAAc,CAAEe,OAAO,GAAO,G,+BCL9D,MAAM,EAA+BC,OAAOC,KAAKC,OAAO,c,MCExDC,GAAAA,aAAiBC,IAAI,oCAAoC,WACvDC,QAAQC,IAAI,6DACd,ICJA,MAAM,EAA+BN,OAAOC,KAAKC,OAAO,a,MCExDC,GAAAA,aAAiBC,IAAI,oCAAoC,WACvDC,QAAQC,IAAI,6DACd,G","sources":["webpack://@mattoid/flarum-ext-money-history/webpack/bootstrap","webpack://@mattoid/flarum-ext-money-history/webpack/runtime/compat get default export","webpack://@mattoid/flarum-ext-money-history/webpack/runtime/define property getters","webpack://@mattoid/flarum-ext-money-history/webpack/runtime/hasOwnProperty shorthand","webpack://@mattoid/flarum-ext-money-history/webpack/runtime/make namespace object","webpack://@mattoid/flarum-ext-money-history/external root \"flarum.core.compat['common/app']\"","webpack://@mattoid/flarum-ext-money-history/./src/common/index.ts","webpack://@mattoid/flarum-ext-money-history/external root \"flarum.core.compat['admin/app']\"","webpack://@mattoid/flarum-ext-money-history/./src/admin/index.ts"],"sourcesContent":["// The require scope\nvar __webpack_require__ = {};\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/app'];","import app from 'flarum/common/app';\n\napp.initializers.add('mattoid/flarum-ext-money-history', () => {\n console.log('[mattoid/flarum-ext-money-history] Hello, forum and admin!');\n});\n","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['admin/app'];","import app from 'flarum/admin/app';\n\napp.initializers.add('mattoid/flarum-ext-money-history', () => {\n console.log('[mattoid/flarum-ext-money-history] Hello, forum and admin!');\n});\n"],"names":["__webpack_require__","module","getter","__esModule","d","a","exports","definition","key","o","Object","defineProperty","enumerable","get","obj","prop","prototype","hasOwnProperty","call","Symbol","toStringTag","value","flarum","core","compat","app","add","console","log"],"sourceRoot":""} \ No newline at end of file diff --git a/js/src/admin/index.ts b/js/src/admin/index.ts index 857c663..98f04a5 100644 --- a/js/src/admin/index.ts +++ b/js/src/admin/index.ts @@ -1,33 +1,5 @@ import app from 'flarum/admin/app'; -app.initializers.add('mattoid-money-history', () => { - app.extensionData.for("mattoid-money-history") - .registerSetting({ - setting: 'mattoid-money-history.request-type-get', - help: app.translator.trans('mattoid-money-history.admin.settings.request-type-get-requirement'), - label: app.translator.trans('mattoid-money-history.admin.settings.request-type-get'), - type: 'switch', - default: false - }) - .registerSetting({ - setting: 'mattoid-money-history.request-type-post', - help: app.translator.trans('mattoid-money-history.admin.settings.type-requirement'), - label: app.translator.trans('mattoid-money-history.admin.settings.request-type-post'), - type: 'switch', - default: true - }) - .registerSetting({ - setting: 'mattoid-money-history.request-type-put', - help: app.translator.trans('mattoid-money-history.admin.settings.type-requirement'), - label: app.translator.trans('mattoid-money-history.admin.settings.request-type-put'), - type: 'switch', - default: true - }) - .registerSetting({ - setting: 'mattoid-money-history.request-type-delete', - help: app.translator.trans('mattoid-money-history.admin.settings.type-requirement'), - label: app.translator.trans('mattoid-money-history.admin.settings.request-type-delete'), - type: 'switch', - default: true - }) +app.initializers.add('mattoid/flarum-ext-money-history', () => { + console.log('[mattoid/flarum-ext-money-history] Hello, forum and admin!'); });