import app from 'flarum/admin/app'; import ExtensionPage from 'flarum/admin/components/ExtensionPage'; export default class MapSettingsModal extends ExtensionPage { oninit(vnode) { super.oninit(vnode); this.setting = this.setting.bind(this); } content() { return [ <div className="container"> <div className="MapSettingsPage"> <div className="Form"> <div className="Form-group"> <h2>{app.translator.trans('map.admin.settings.configuration_title')}</h2> </div> <div className="Form-group"> <label>{app.translator.trans('map.admin.settings.consentText')}</label> <textarea required className="FormControl" bidi={this.setting('ubuntuhu-map.consentText')} /> </div> {this.buildSettingComponent({ type: 'password', setting: 'ubuntuhu-map.gidSecret', required: true, label: app.translator.trans('map.admin.settings.gidSecret'), })} {this.buildSettingComponent({ type: 'text', setting: 'ubuntuhu-map.contentTitle', required: true, label: app.translator.trans('map.admin.settings.contentTitle'), })} {this.buildSettingComponent({ type: 'text', setting: 'ubuntuhu-map.contentTitleIcon', required: true, label: app.translator.trans('map.admin.settings.contentTitleIcon'), })} {this.buildSettingComponent({ type: 'text', setting: 'ubuntuhu-map.contentMenuTitle', required: true, label: app.translator.trans('map.admin.settings.contentMenuTitle'), })} {this.buildSettingComponent({ type: 'text', setting: 'ubuntuhu-map.contentMenuTitleIcon', required: true, label: app.translator.trans('map.admin.settings.contentMenuTitleIcon'), })} {this.buildSettingComponent({ type: 'text', setting: 'ubuntuhu-map.formButtonTitle', required: true, label: app.translator.trans('map.admin.settings.formButtonTitle'), })} {this.submitButton()} </div> </div> </div>, ]; } }