From 20420ee9ead6d6cebb39b6c6488752f8d4b01e4b Mon Sep 17 00:00:00 2001 From: flarum-bot Date: Mon, 21 Oct 2024 06:45:35 +0000 Subject: [PATCH] Bundled output for commit ae293f7cb895d5fc7bde3a6414ac1387eccdd01c Includes transpiled JS/TS, and Typescript declaration files (typings). [skip ci] --- js/dist/forum.js | 2 +- js/dist/forum.js.map | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/js/dist/forum.js b/js/dist/forum.js index 1d0023d..d0ec6ae 100644 --- a/js/dist/forum.js +++ b/js/dist/forum.js @@ -1,2 +1,2 @@ -(()=>{var o={n:t=>{var r=t&&t.__esModule?()=>t.default:()=>t;return o.d(r,{a:r}),r},d:(t,r)=>{for(var n in r)o.o(r,n)&&!o.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:(o,t)=>Object.prototype.hasOwnProperty.call(o,t)};(()=>{"use strict";const t=flarum.core.compat["forum/app"];var r=o.n(t);const n=flarum.core.compat["common/extend"],e=flarum.core.compat["forum/states/DiscussionListState"];var a=o.n(e);const f=flarum.core.compat["forum/utils/DiscussionControls"];var c=o.n(f);const p=flarum.core.compat["common/components/Button"];var s=o.n(p);const m=flarum.core.compat["common/Model"];var u=o.n(m);const i=flarum.core.compat["common/models/Discussion"];var l=o.n(i);l().prototype.frontpage=u().attribute("frontpage"),l().prototype.front=u().attribute("front");const d=flarum.core.compat["common/components/Badge"];var g=o.n(d);l().prototype.frontpage=u().attribute("frontpage"),r().initializers.add("fof/frontpage",(function(){(0,n.extend)(a().prototype,"requestParams",(function(o){"front"===this.params.sort&&(o.filter.q?o.filter.q=(o.filter.q||"")+"is:frontpage":o.filter.frontpage=!0)})),(0,n.extend)(a().prototype,"sortMap",(function(o){o.front="-frontdate"})),(0,n.extend)(c(),"moderationControls",(function(o,t){var n=t.frontpage();t.front()&&o.add("frontpage",s().component({icon:"fas fa-home",onclick:function(){n=!n,t.save({frontpage:n})}},r().translator.trans(t.frontpage()?"core.forum.post_controls.pull_from_front_button":"core.forum.post_controls.push_to_front_button")))})),(0,n.extend)(l().prototype,"badges",(function(o){this.frontpage()&&o.add("frontpage",g().component({type:"frontpage",label:r().translator.trans("core.forum.badge.frontpage_tooltip"),icon:"fas fa-home"}),10)}))}))})(),module.exports={}})(); +(()=>{var o={n:t=>{var r=t&&t.__esModule?()=>t.default:()=>t;return o.d(r,{a:r}),r},d:(t,r)=>{for(var e in r)o.o(r,e)&&!o.o(t,e)&&Object.defineProperty(t,e,{enumerable:!0,get:r[e]})},o:(o,t)=>Object.prototype.hasOwnProperty.call(o,t),r:o=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(o,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(o,"__esModule",{value:!0})}},t={};(()=>{"use strict";o.r(t),o.d(t,{extend:()=>x});const r=flarum.core.compat["forum/app"];var e=o.n(r);const n=flarum.core.compat["common/extend"],a=flarum.core.compat["forum/states/DiscussionListState"];var f=o.n(a);const c=flarum.core.compat["forum/utils/DiscussionControls"];var s=o.n(c);const p=flarum.core.compat["common/components/Button"];var u=o.n(p);const l=flarum.core.compat["common/models/Discussion"];var i=o.n(l);const d=flarum.core.compat["common/components/Badge"];var g=o.n(d);const b=flarum.core.compat["common/extenders"];var v=o.n(b);const y=flarum.core.compat["common/Model"];var _=o.n(y);const x=[new(v().Model)(i()).attribute("frontpage").attribute("frontdate",_().transformDate).attribute("front")];e().initializers.add("fof/frontpage",(function(){(0,n.extend)(f().prototype,"requestParams",(function(o){"front"===this.params.sort&&(o.filter.q?o.filter.q=(o.filter.q||"")+"is:frontpage":o.filter.frontpage=!0)})),(0,n.extend)(f().prototype,"sortMap",(function(o){o.front="-frontdate"})),(0,n.extend)(s(),"moderationControls",(function(o,t){if(t.front()){var r=t.frontpage();o.add("frontpage",m(u(),{icon:"fas fa-home",onclick:function(){r=!r,t.save({frontpage:r})}},e().translator.trans(t.frontpage()?"core.forum.post_controls.pull_from_front_button":"core.forum.post_controls.push_to_front_button")))}})),(0,n.extend)(i().prototype,"badges",(function(o){this.frontpage()&&o.add("frontpage",m(g(),{type:"frontpage",label:e().translator.trans("core.forum.badge.frontpage_tooltip"),icon:"fas fa-home"}),10)}))}))})(),module.exports=t})(); //# sourceMappingURL=forum.js.map \ No newline at end of file diff --git a/js/dist/forum.js.map b/js/dist/forum.js.map index 5d0dfa8..4013378 100644 --- a/js/dist/forum.js.map +++ b/js/dist/forum.js.map @@ -1 +1 @@ -{"version":3,"file":"forum.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,I,mBCAlF,MAAM,EAA+BI,OAAOC,KAAKC,OAAO,a,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,iBCAlD,EAA+BF,OAAOC,KAAKC,OAAO,oC,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,kC,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,4B,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,gB,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,4B,aCOxDC,IAAAA,UAAqBC,UAAYC,IAAAA,UAAgB,aACjDF,IAAAA,UAAqBG,MAAQD,IAAAA,UAAgB,SCR7C,MAAM,EAA+BL,OAAOC,KAAKC,OAAO,2B,aCMxDC,IAAAA,UAAqBC,UAAYC,IAAAA,UAAgB,aCDjDE,IAAAA,aAAiBC,IAAI,iBAAiB,YCDpCC,EAAAA,EAAAA,QAAOC,IAAAA,UAA+B,iBAAiB,SAAUC,GACtC,UAArBC,KAAKD,OAAOE,OACVF,EAAOG,OAAOC,EAChBJ,EAAOG,OAAOC,GAAKJ,EAAOG,OAAOC,GAAK,IAAM,eAE5CJ,EAAOG,OAAOV,WAAY,EAGhC,KAEAK,EAAAA,EAAAA,QAAOC,IAAAA,UAA+B,WAAW,SAAUM,GACzDA,EAAIV,MAAQ,YACd,KJLAG,EAAAA,EAAAA,QAAOQ,IAAoB,sBAAsB,SAAUC,EAAOC,GAChE,IAAIC,EAAUD,EAAWf,YAErBe,EAAWb,SACbY,EAAMV,IACJ,YACAa,IAAAA,UACE,CACEC,KAAM,cACNC,QAAS,WACPH,GAAWA,EACXD,EAAWK,KAAK,CAAEpB,UAAWgB,GAC/B,GAEFb,IAAAA,WAAekB,MACbN,EAAWf,YAAc,kDAAoD,kDAKvF,KEtBAK,EAAAA,EAAAA,QAAON,IAAAA,UAAsB,UAAU,SAAUuB,GAC3Cd,KAAKR,aACPsB,EAAOlB,IACL,YACAmB,IAAAA,UAAgB,CACdC,KAAM,YACNC,MAAOtB,IAAAA,WAAekB,MAAM,sCAC5BH,KAAM,gBAER,GAGN,GCZF,G","sources":["webpack://@fof/frontpage/webpack/bootstrap","webpack://@fof/frontpage/webpack/runtime/compat get default export","webpack://@fof/frontpage/webpack/runtime/define property getters","webpack://@fof/frontpage/webpack/runtime/hasOwnProperty shorthand","webpack://@fof/frontpage/external root \"flarum.core.compat['forum/app']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/extend']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['forum/states/DiscussionListState']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['forum/utils/DiscussionControls']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/components/Button']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/Model']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/models/Discussion']\"","webpack://@fof/frontpage/./src/forum/addFrontPage.js","webpack://@fof/frontpage/external root \"flarum.core.compat['common/components/Badge']\"","webpack://@fof/frontpage/./src/forum/addStickyBadge.js","webpack://@fof/frontpage/./src/forum/index.ts","webpack://@fof/frontpage/./src/forum/addFrontSort.js"],"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))","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['forum/app'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/extend'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['forum/states/DiscussionListState'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['forum/utils/DiscussionControls'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/components/Button'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/Model'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/models/Discussion'];","import app from 'flarum/forum/app';\nimport { extend } from 'flarum/common/extend';\nimport DiscussionControls from 'flarum/forum/utils/DiscussionControls';\nimport Button from 'flarum/common/components/Button';\nimport Model from 'flarum/common/Model';\nimport Discussion from 'flarum/common/models/Discussion';\n\nDiscussion.prototype.frontpage = Model.attribute('frontpage');\nDiscussion.prototype.front = Model.attribute('front');\n\nexport default function addFrontPage() {\n extend(DiscussionControls, 'moderationControls', function (items, discussion) {\n let isFront = discussion.frontpage();\n\n if (discussion.front()) {\n items.add(\n 'frontpage',\n Button.component(\n {\n icon: 'fas fa-home',\n onclick: () => {\n isFront = !isFront;\n discussion.save({ frontpage: isFront });\n },\n },\n app.translator.trans(\n discussion.frontpage() ? 'core.forum.post_controls.pull_from_front_button' : 'core.forum.post_controls.push_to_front_button'\n )\n )\n );\n }\n });\n}\n","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/components/Badge'];","import app from 'flarum/forum/app';\nimport { extend } from 'flarum/common/extend';\nimport Model from 'flarum/common/Model';\nimport Discussion from 'flarum/common/models/Discussion';\nimport Badge from 'flarum/common/components/Badge';\n\nDiscussion.prototype.frontpage = Model.attribute('frontpage');\n\nexport default function addStickyBadge() {\n extend(Discussion.prototype, 'badges', function (badges) {\n if (this.frontpage()) {\n badges.add(\n 'frontpage',\n Badge.component({\n type: 'frontpage',\n label: app.translator.trans('core.forum.badge.frontpage_tooltip'),\n icon: 'fas fa-home',\n }),\n 10\n );\n }\n });\n}\n","import app from 'flarum/forum/app';\nimport addFrontSort from './addFrontSort';\nimport addFrontPage from './addFrontPage';\nimport addStickyBadge from './addStickyBadge';\n\napp.initializers.add('fof/frontpage', () => {\n addFrontSort();\n addFrontPage();\n addStickyBadge();\n});\n","import { extend } from 'flarum/common/extend';\nimport DiscussionListState from 'flarum/forum/states/DiscussionListState';\n\nexport default function () {\n extend(DiscussionListState.prototype, 'requestParams', function (params) {\n if (this.params.sort === 'front') {\n if (params.filter.q) {\n params.filter.q = (params.filter.q || '') + 'is:frontpage';\n } else {\n params.filter.frontpage = true;\n }\n }\n });\n\n extend(DiscussionListState.prototype, 'sortMap', function (map) {\n map.front = '-frontdate';\n });\n}\n"],"names":["__webpack_require__","module","getter","__esModule","d","a","exports","definition","key","o","Object","defineProperty","enumerable","get","obj","prop","prototype","hasOwnProperty","call","flarum","core","compat","Discussion","frontpage","Model","front","app","add","extend","DiscussionListState","params","this","sort","filter","q","map","DiscussionControls","items","discussion","isFront","Button","icon","onclick","save","trans","badges","Badge","type","label"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"forum.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,qDCL9D,MAAM,EAA+BC,OAAOC,KAAKC,OAAO,a,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,iBCAlD,EAA+BF,OAAOC,KAAKC,OAAO,oC,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,kC,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,4B,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,4B,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,2B,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,oB,aCAxD,MAAM,EAA+BF,OAAOC,KAAKC,OAAO,gB,aCIxD,SACE,IAAIC,IAAAA,OAAaC,KACdC,UAAmB,aACnBA,UAAU,YAAaC,IAAAA,eACvBD,UAAmB,UCDxBE,IAAAA,aAAiBC,IAAI,iBAAiB,YCDpCC,EAAAA,EAAAA,QAAOC,IAAAA,UAA+B,iBAAiB,SAAqCC,GACjE,UAArBC,KAAKD,OAAOE,OACVF,EAAOG,OAAOC,EAChBJ,EAAOG,OAAOC,GAAKJ,EAAOG,OAAOC,GAAK,IAAM,eAE5CJ,EAAOG,OAAOE,WAAY,EAGhC,KAEAP,EAAAA,EAAAA,QAAOC,IAAAA,UAA+B,WAAW,SAAUO,GACzDA,EAAIC,MAAQ,YACd,KCRAT,EAAAA,EAAAA,QAAOU,IAAoB,sBAAsB,SAAUC,EAAmCC,GAC5F,GAAKA,EAAWH,QAAhB,CAEA,IAAII,EAAUD,EAAWL,YAEzBI,EAAMZ,IACJ,YACAe,EAACC,IAAM,CACLC,KAAK,cACLC,QAAS,WACPJ,GAAWA,EACXD,EAAWM,KAAK,CAAEX,UAAWM,GAC/B,GAECf,IAAAA,WAAeqB,MACdP,EAAWL,YAAc,kDAAoD,kDAdpD,CAkBjC,KCpBAP,EAAAA,EAAAA,QAAOL,IAAAA,UAAsB,UAAU,SAAUyB,GAC1CjB,KAAKI,aAEVa,EAAOrB,IAAI,YAAae,EAACO,IAAK,CAACC,KAAK,YAAYC,MAAOzB,IAAAA,WAAeqB,MAAM,sCAAuCH,KAAK,gBAAkB,GAC5I,GHFF,G","sources":["webpack://@fof/frontpage/webpack/bootstrap","webpack://@fof/frontpage/webpack/runtime/compat get default export","webpack://@fof/frontpage/webpack/runtime/define property getters","webpack://@fof/frontpage/webpack/runtime/hasOwnProperty shorthand","webpack://@fof/frontpage/webpack/runtime/make namespace object","webpack://@fof/frontpage/external root \"flarum.core.compat['forum/app']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/extend']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['forum/states/DiscussionListState']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['forum/utils/DiscussionControls']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/components/Button']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/models/Discussion']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/components/Badge']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/extenders']\"","webpack://@fof/frontpage/external root \"flarum.core.compat['common/Model']\"","webpack://@fof/frontpage/./src/forum/extend.ts","webpack://@fof/frontpage/./src/forum/index.ts","webpack://@fof/frontpage/./src/forum/extenders/addFrontSort.ts","webpack://@fof/frontpage/./src/forum/extenders/addFrontPage.tsx","webpack://@fof/frontpage/./src/forum/extenders/addStickyBadge.tsx"],"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['forum/app'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/extend'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['forum/states/DiscussionListState'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['forum/utils/DiscussionControls'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/components/Button'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/models/Discussion'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/components/Badge'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/extenders'];","const __WEBPACK_NAMESPACE_OBJECT__ = flarum.core.compat['common/Model'];","import Extend from 'flarum/common/extenders';\nimport Discussion from 'flarum/common/models/Discussion';\nimport Model from 'flarum/common/Model';\n\nexport default [\n new Extend.Model(Discussion) //\n .attribute('frontpage')\n .attribute('frontdate', Model.transformDate)\n .attribute('front'),\n];\n","import app from 'flarum/forum/app';\nimport addFrontSort from './extenders/addFrontSort';\nimport addFrontPage from './extenders/addFrontPage';\nimport addStickyBadge from './extenders/addStickyBadge';\n\nexport { default as extend } from './extend';\n\napp.initializers.add('fof/frontpage', () => {\n addFrontSort();\n addFrontPage();\n addStickyBadge();\n});\n","import { extend } from 'flarum/common/extend';\nimport DiscussionListState from 'flarum/forum/states/DiscussionListState';\n\nimport type { PaginatedListParams } from 'flarum/common/states/PaginatedListState';\n\nexport default function () {\n extend(DiscussionListState.prototype, 'requestParams', function (this: DiscussionListState, params: PaginatedListParams) {\n if (this.params.sort === 'front') {\n if (params.filter.q) {\n params.filter.q = (params.filter.q || '') + 'is:frontpage';\n } else {\n params.filter.frontpage = true;\n }\n }\n });\n\n extend(DiscussionListState.prototype, 'sortMap', function (map: Record) {\n map.front = '-frontdate';\n });\n}\n","import app from 'flarum/forum/app';\nimport { extend } from 'flarum/common/extend';\nimport DiscussionControls from 'flarum/forum/utils/DiscussionControls';\nimport Button from 'flarum/common/components/Button';\n\nimport type Discussion from 'flarum/common/models/Discussion';\nimport type Mithril from 'mithril';\nimport type ItemList from 'flarum/common/utils/ItemList';\n\nexport default function addFrontPage() {\n extend(DiscussionControls, 'moderationControls', function (items: ItemList, discussion: Discussion) {\n if (!discussion.front()) return;\n\n let isFront = discussion.frontpage();\n\n items.add(\n 'frontpage',\n {\n isFront = !isFront;\n discussion.save({ frontpage: isFront });\n }}\n >\n {app.translator.trans(\n discussion.frontpage() ? 'core.forum.post_controls.pull_from_front_button' : 'core.forum.post_controls.push_to_front_button'\n )}\n \n );\n });\n}\n","import app from 'flarum/forum/app';\nimport { extend } from 'flarum/common/extend';\nimport Discussion from 'flarum/common/models/Discussion';\nimport Badge from 'flarum/common/components/Badge';\n\nimport type ItemList from 'flarum/common/utils/ItemList';\nimport type Mithril from 'mithril';\n\nexport default function addStickyBadge() {\n extend(Discussion.prototype, 'badges', function (badges: ItemList) {\n if (!this.frontpage()) return;\n\n badges.add('frontpage', , 10);\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","Extend","Discussion","attribute","Model","app","add","extend","DiscussionListState","params","this","sort","filter","q","frontpage","map","front","DiscussionControls","items","discussion","isFront","m","Button","icon","onclick","save","trans","badges","Badge","type","label"],"sourceRoot":""} \ No newline at end of file