2020-10-20 23:25:34 +02:00
/ * *
* @ name OwnerTag
* @ authorId 278543574059057154
* @ invite Jx3TjNS
* @ donate https : //www.paypal.me/MircoWittrien
* @ patreon https : //www.patreon.com/MircoWittrien
* @ website https : //github.com/mwittrien/BetterDiscordAddons/tree/master/Plugins/OwnerTag
* @ source https : //raw.githubusercontent.com/mwittrien/BetterDiscordAddons/master/Plugins/OwnerTag/OwnerTag.plugin.js
2020-11-12 17:30:48 +01:00
* @ updateUrl https : //raw.githubusercontent.com/mwittrien/BetterDiscordAddons/master/Plugins/OwnerTag/OwnerTag.plugin.js
2020-10-20 23:25:34 +02:00
* /
2019-01-09 12:56:24 +01:00
2020-09-19 20:49:33 +02:00
module . exports = ( _ => {
2020-10-09 21:09:35 +02:00
const config = {
2020-09-19 20:49:33 +02:00
"info" : {
"name" : "OwnerTag" ,
"author" : "DevilBro" ,
2020-12-07 19:42:24 +01:00
"version" : "1.3.6" ,
2020-10-16 10:25:30 +02:00
"description" : "Add a tag or crown to the server owner (or admins/management)"
2020-10-07 10:20:55 +02:00
} ,
"changeLog" : {
"fixed" : {
2020-12-07 19:42:24 +01:00
"Compact" : "Fixed some issues with compact mode"
2020-10-07 10:20:55 +02:00
}
2020-02-04 08:20:40 +01:00
}
2020-09-19 20:49:33 +02:00
} ;
2020-11-13 19:47:44 +01:00
2020-10-09 21:09:35 +02:00
return ! window . BDFDB _Global || ( ! window . BDFDB _Global . loaded && ! window . BDFDB _Global . started ) ? class {
2021-01-06 12:38:36 +01:00
getName ( ) { return config . info . name ; }
getAuthor ( ) { return config . info . author ; }
getVersion ( ) { return config . info . version ; }
2021-01-14 16:14:44 +01:00
getDescription ( ) { return ` The Library Plugin needed for ${ config . info . name } is missing. Open the Plugin Settings to download it. \n \n ${ config . info . description } ` ; }
2020-09-19 20:49:33 +02:00
2021-01-06 12:38:36 +01:00
load ( ) {
2020-11-19 16:51:14 +01:00
if ( ! window . BDFDB _Global || ! Array . isArray ( window . BDFDB _Global . pluginQueue ) ) window . BDFDB _Global = Object . assign ( { } , window . BDFDB _Global , { pluginQueue : [ ] } ) ;
2020-09-19 20:49:33 +02:00
if ( ! window . BDFDB _Global . downloadModal ) {
window . BDFDB _Global . downloadModal = true ;
2021-01-14 16:14:44 +01:00
BdApi . showConfirmationModal ( "Library Missing" , ` The Library Plugin needed for ${ config . info . name } is missing. Please click "Download Now" to install it. ` , {
2020-09-19 20:49:33 +02:00
confirmText : "Download Now" ,
cancelText : "Cancel" ,
onCancel : _ => { delete window . BDFDB _Global . downloadModal ; } ,
2020-09-20 08:15:13 +02:00
onConfirm : _ => {
delete window . BDFDB _Global . downloadModal ;
require ( "request" ) . get ( "https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js" , ( e , r , b ) => {
2020-10-20 23:25:34 +02:00
if ( ! e && b && b . indexOf ( ` * @name BDFDB ` ) > - 1 ) require ( "fs" ) . writeFile ( require ( "path" ) . join ( BdApi . Plugins . folder , "0BDFDB.plugin.js" ) , b , _ => { } ) ;
2021-01-14 16:14:44 +01:00
else BdApi . alert ( "Error" , "Could not download BDFDB Library Plugin, try again later or download it manually from GitHub: https://github.com/mwittrien/BetterDiscordAddons/tree/master/Library/" ) ;
2020-09-20 08:15:13 +02:00
} ) ;
}
2020-09-19 20:49:33 +02:00
} ) ;
}
if ( ! window . BDFDB _Global . pluginQueue . includes ( config . info . name ) ) window . BDFDB _Global . pluginQueue . push ( config . info . name ) ;
2020-10-09 21:09:35 +02:00
}
2021-01-06 12:38:36 +01:00
start ( ) { this . load ( ) ; }
stop ( ) { }
getSettingsPanel ( ) {
2020-11-28 23:12:09 +01:00
let template = document . createElement ( "template" ) ;
2021-01-14 16:14:44 +01:00
template . innerHTML = ` <div style="color: var(--header-primary); font-size: 16px; font-weight: 300; white-space: pre; line-height: 22px;">The Library Plugin needed for ${ config . info . name } is missing. \n Please click <a style="font-weight: 500;">Download Now</a> to install it.</div> ` ;
2020-11-28 23:12:09 +01:00
template . content . firstElementChild . querySelector ( "a" ) . addEventListener ( "click" , _ => {
require ( "request" ) . get ( "https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js" , ( e , r , b ) => {
if ( ! e && b && b . indexOf ( ` * @name BDFDB ` ) > - 1 ) require ( "fs" ) . writeFile ( require ( "path" ) . join ( BdApi . Plugins . folder , "0BDFDB.plugin.js" ) , b , _ => { } ) ;
2021-01-14 16:14:44 +01:00
else BdApi . alert ( "Error" , "Could not download BDFDB Library Plugin, try again later or download it manually from GitHub: https://github.com/mwittrien/BetterDiscordAddons/tree/master/Library/" ) ;
2020-11-28 23:12:09 +01:00
} ) ;
} ) ;
return template . content . firstElementChild ;
}
2020-10-09 21:09:35 +02:00
} : ( ( [ Plugin , BDFDB ] ) => {
2020-09-19 20:49:33 +02:00
const userTypes = {
NONE : 0 ,
MANAGEMENT : 1 ,
ADMIN : 2 ,
OWNER : 3
} ;
var settings = { } , inputs = { } ;
2020-10-09 21:09:35 +02:00
return class OwnerTag extends Plugin {
2021-01-06 12:38:36 +01:00
onLoad ( ) {
2020-09-19 20:49:33 +02:00
this . patchedModules = {
after : {
MemberListItem : "render" ,
2020-10-07 10:20:55 +02:00
MessageUsername : "default" ,
2020-09-19 20:49:33 +02:00
NameTag : "default" ,
UserPopout : "render"
}
} ;
this . defaults = {
settings : {
2020-11-19 16:51:14 +01:00
addInChatWindow : { value : true , inner : true , description : "Messages" } ,
addInMemberList : { value : true , inner : true , description : "Member List" } ,
addInUserPopout : { value : true , inner : true , description : "User Popouts" } ,
addInUserProfile : { value : true , inner : true , description : "User Profile Modal" } ,
useRoleColor : { value : true , inner : false , description : "Use the Rolecolor instead of the default blue" } ,
useBlackFont : { value : false , inner : false , description : "Instead of darkening the Rolecolor on bright colors use black font" } ,
useCrown : { value : false , inner : false , description : "Use the Crown Icon instead of the Bot Tag Style" } ,
hideNativeCrown : { value : true , inner : false , description : "Hide the native Crown Icon (not the Plugin one)" } ,
addForAdmins : { value : false , inner : false , description : "Add an Admin Tag for users with admin permissions" } ,
addForManagement : { value : false , inner : false , description : "Add a Management Tag for users with management permissions" } ,
ignoreBotAdmins : { value : false , inner : false , description : "Do not add the Admin/Management tag for bots" }
2020-09-19 20:49:33 +02:00
} ,
inputs : {
2020-11-19 16:51:14 +01:00
ownTagName : { value : "Owner" , description : "Tag Text for Owners" } ,
ownAdminTagName : { value : "Admin" , description : "Tag Text for Admins" } ,
ownManagementTagName : { value : "Management" , description : "Tag Text for Management" }
2020-09-19 20:49:33 +02:00
}
} ;
2020-02-04 08:20:40 +01:00
2020-09-19 20:49:33 +02:00
this . css = `
$ { BDFDB . dotCN . memberownericon + BDFDB . dotCN . _ownertagadminicon } {
color : # c0c0c0 ;
}
$ { BDFDB . dotCN . memberownericon + BDFDB . dotCN . _ownertagmanagementicon } {
color : # ef7f32 ;
}
$ { BDFDB . dotCNS . message + BDFDB . dotCN . memberownericon } {
top : 2 px ;
}
2020-12-07 19:52:18 +01:00
$ { BDFDB . dotCNS . messagerepliedmessage + BDFDB . dotCN . memberownericon } ,
2020-12-07 19:42:24 +01:00
$ { BDFDB . dotCNS . messagecompact + BDFDB . dotCN . memberownericon } {
margin - left : 0 ;
margin - right : 4 px ;
}
2020-09-19 20:49:33 +02:00
$ { BDFDB . dotCNS . userprofile + BDFDB . dotCN . memberownericon } {
top : 0 px ;
}
` ;
2020-02-04 08:20:40 +01:00
}
2020-09-19 20:49:33 +02:00
2021-01-06 12:38:36 +01:00
onStart ( ) {
2020-02-04 08:20:40 +01:00
this . forceUpdateAll ( ) ;
}
2020-09-19 20:49:33 +02:00
2021-01-06 12:38:36 +01:00
onStop ( ) {
2020-02-04 08:20:40 +01:00
this . forceUpdateAll ( ) ;
}
2019-01-26 22:45:19 +01:00
2020-09-19 20:49:33 +02:00
getSettingsPanel ( collapseStates = { } ) {
let settingsPanel , settingsItems = [ ] ;
settingsItems . push ( BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . CollapseContainer , {
title : "Settings" ,
collapseStates : collapseStates ,
children : Object . keys ( settings ) . map ( key => ! this . defaults . settings [ key ] . inner && BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . SettingsSaveItem , {
type : "Switch" ,
plugin : this ,
key : key ,
disabled : key == "hideNativeCrown" && settings . useCrown ,
keys : [ "settings" , key ] ,
label : this . defaults . settings [ key ] . description ,
value : settings [ key ] ,
onChange : key == "useCrown" ? ( value , instance ) => {
2020-11-26 09:53:49 +01:00
let hideNativeCrownInstance = BDFDB . ReactUtils . findOwner ( BDFDB . ObjectUtils . get ( instance , ` ${ BDFDB . ReactUtils . instanceKey } .return ` ) , { key : "hideNativeCrown" } ) ;
2020-09-19 20:49:33 +02:00
if ( hideNativeCrownInstance ) {
hideNativeCrownInstance . props . disabled = value ;
BDFDB . ReactUtils . forceUpdate ( hideNativeCrownInstance ) ;
}
} : null
} ) )
} ) ) ;
settingsItems . push ( BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . CollapseContainer , {
title : "Tag Settings" ,
collapseStates : collapseStates ,
children : [ BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . FormComponents . FormTitle , {
className : BDFDB . disCN . marginbottom4 ,
tag : BDFDB . LibraryComponents . FormComponents . FormTitle . Tags . H3 ,
2020-11-19 16:51:14 +01:00
children : "Add Tags in: "
2020-09-19 20:49:33 +02:00
} ) ] . concat ( Object . keys ( settings ) . map ( key => this . defaults . settings [ key ] . inner && BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . SettingsSaveItem , {
type : "Switch" ,
plugin : this ,
keys : [ "settings" , key ] ,
label : this . defaults . settings [ key ] . description ,
value : settings [ key ]
} ) ) )
} ) ) ;
settingsItems . push ( BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . CollapseContainer , {
title : "Tag Text Settings" ,
collapseStates : collapseStates ,
children : Object . keys ( inputs ) . map ( key => BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . SettingsSaveItem , {
type : "TextInput" ,
plugin : this ,
keys : [ "inputs" , key ] ,
label : this . defaults . inputs [ key ] . description ,
basis : "50%" ,
value : inputs [ key ]
} ) )
} ) ) ;
return settingsPanel = BDFDB . PluginUtils . createSettingsPanel ( this , settingsItems ) ;
2020-02-04 08:20:40 +01:00
}
2019-09-04 12:34:02 +02:00
2021-01-06 12:38:36 +01:00
onSettingsClosed ( ) {
2020-09-19 20:49:33 +02:00
if ( this . SettingsUpdated ) {
delete this . SettingsUpdated ;
this . forceUpdateAll ( ) ;
}
}
2021-01-06 12:38:36 +01:00
forceUpdateAll ( ) {
2020-09-19 20:49:33 +02:00
settings = BDFDB . DataUtils . get ( this , "settings" ) ;
inputs = BDFDB . DataUtils . get ( this , "inputs" ) ;
BDFDB . PatchUtils . forceAllUpdates ( this ) ;
BDFDB . MessageUtils . rerenderAll ( ) ;
2020-02-04 08:20:40 +01:00
}
2019-09-04 12:34:02 +02:00
2020-09-19 20:49:33 +02:00
processMemberListItem ( e ) {
let userType = this . getUserType ( e . instance . props . user , e . instance . props . channel && e . instance . props . channel . id ) ;
if ( userType && settings . addInMemberList ) {
this . injectOwnerTag ( BDFDB . ObjectUtils . get ( e . returnvalue , "props.decorators.props.children" ) , e . instance . props . user , userType , 1 , {
tagClass : BDFDB . disCN . bottagmember
2020-04-09 09:29:38 +02:00
} ) ;
2020-02-27 11:53:07 +01:00
}
2020-02-04 08:20:40 +01:00
}
2019-01-26 22:45:19 +01:00
2020-10-07 10:20:55 +02:00
processMessageUsername ( e ) {
2020-09-19 20:49:33 +02:00
if ( e . instance . props . message && settings . addInChatWindow ) {
let userType = this . getUserType ( e . instance . props . message . author , e . instance . props . message . channel _id ) ;
2020-10-07 10:20:55 +02:00
if ( userType ) this . injectOwnerTag ( e . returnvalue . props . children , e . instance . props . message . author , userType , e . instance . props . compact ? 0 : 2 , {
tagClass : e . instance . props . compact ? BDFDB . disCN . messagebottagcompact : BDFDB . disCN . messagebottagcozy ,
useRem : true
} ) ;
2020-02-04 08:20:40 +01:00
}
}
2019-01-26 22:45:19 +01:00
2020-09-19 20:49:33 +02:00
processNameTag ( e ) {
if ( e . instance . props . user && e . instance . props . className ) {
let userType = this . getUserType ( e . instance . props . user ) ;
if ( userType ) {
let inject = false , tagClass = "" ;
switch ( e . instance . props . className ) {
case BDFDB . disCN . userpopoutheadertagnonickname :
inject = settings . addInUserPopout ;
tagClass = BDFDB . disCN . bottagnametag ;
break ;
case BDFDB . disCN . userprofilenametag :
inject = settings . addInUserProfile ;
tagClass = BDFDB . disCNS . userprofilebottag + BDFDB . disCN . bottagnametag ;
break ;
}
if ( inject ) this . injectOwnerTag ( e . returnvalue . props . children , e . instance . props . user , userType , 2 , {
tagClass : tagClass ,
useRem : e . instance . props . useRemSizes ,
inverted : e . instance . props . invertBotTagColor
} ) ;
}
2020-02-04 08:20:40 +01:00
}
}
2019-01-26 22:45:19 +01:00
2020-09-19 20:49:33 +02:00
processUserPopout ( e ) {
if ( e . instance . props . user && settings . addInUserPopout ) {
let userType = this . getUserType ( e . instance . props . user , e . instance . props . channel && e . instance . props . channel . id ) ;
if ( userType ) {
let [ children , index ] = BDFDB . ReactUtils . findParent ( e . returnvalue , { props : [ [ "className" , BDFDB . disCN . userpopoutheadertagwithnickname ] ] } ) ;
if ( index > - 1 ) this . injectOwnerTag ( children , e . instance . props . user , userType , 2 , {
tagClass : BDFDB . disCNS . userpopoutheaderbottagwithnickname + BDFDB . disCN . bottagnametag ,
inverted : typeof e . instance . getMode == "function" && e . instance . getMode ( ) !== "Normal"
} ) ;
}
2020-08-29 19:52:21 +02:00
}
2020-02-04 08:20:40 +01:00
}
2020-09-19 20:49:33 +02:00
injectOwnerTag ( children , user , userType , insertIndex , config = { } ) {
if ( ! BDFDB . ArrayUtils . is ( children ) || ! user ) return ;
if ( settings . useCrown || settings . hideNativeCrown ) {
let [ _ , index ] = BDFDB . ReactUtils . findParent ( children , { props : [ [ "text" , [ BDFDB . LanguageUtils . LanguageStrings . GROUP _OWNER , BDFDB . LanguageUtils . LanguageStrings . GUILD _OWNER ] ] ] } ) ;
if ( index > - 1 ) children [ index ] = null ;
2020-08-29 20:21:16 +02:00
}
2020-09-19 20:49:33 +02:00
let channel = BDFDB . LibraryModules . ChannelStore . getChannel ( BDFDB . LibraryModules . LastChannelStore . getChannelId ( ) ) ;
let member = settings . useRoleColor ? ( BDFDB . LibraryModules . MemberStore . getMember ( channel . guild _id , user . id ) || { } ) : { } ;
let tag = null ;
if ( settings . useCrown ) {
let label , className ;
switch ( userType ) {
case userTypes . OWNER :
label = channel . type == BDFDB . DiscordConstants . ChannelTypes . GROUP _DM ? BDFDB . LanguageUtils . LanguageStrings . GROUP _OWNER : BDFDB . LanguageUtils . LanguageStrings . GUILD _OWNER ;
className = BDFDB . disCN . _ownertagownericon ;
break ;
case userTypes . ADMIN :
label = BDFDB . LanguageUtils . LanguageStrings . ADMINISTRATOR ;
className = BDFDB . disCN . _ownertagadminicon ;
break ;
case userTypes . MANAGEMENT :
2020-12-21 19:56:36 +01:00
label = ` ${ this . labels . management } ( ${ [ BDFDB . UserUtils . can ( "MANAGE_GUILD" , user . id ) && BDFDB . LanguageUtils . LibraryStrings . server , BDFDB . UserUtils . can ( "MANAGE_CHANNELS" , user . id ) && BDFDB . LanguageUtils . LanguageStrings . CHANNELS , BDFDB . UserUtils . can ( "MANAGE_ROLES" , user . id ) && BDFDB . LanguageUtils . LanguageStrings . ROLES ] . filter ( n => n ) . join ( ", " ) } ) ` ;
2020-09-19 20:49:33 +02:00
className = BDFDB . disCN . _ownertagmanagementicon ;
break ;
}
tag = BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . TooltipContainer , {
text : label ,
children : BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . SvgIcon , {
className : BDFDB . DOMUtils . formatClassName ( BDFDB . disCN . memberownericon , className ) ,
name : BDFDB . LibraryComponents . SvgIcon . Names . CROWN ,
"aria-label" : label
} )
} ) ;
}
else {
let input , label ;
switch ( userType ) {
case userTypes . OWNER :
input = "ownTagName" ;
break ;
case userTypes . ADMIN :
input = "ownAdminTagName" ;
break ;
case userTypes . MANAGEMENT :
input = "ownManagementTagName" ;
label = [ BDFDB . UserUtils . can ( "MANAGE_GUILD" , user . id ) && BDFDB . LanguageUtils . LibraryStrings . server , BDFDB . UserUtils . can ( "MANAGE_CHANNELS" , user . id ) && BDFDB . LanguageUtils . LanguageStrings . CHANNELS , BDFDB . UserUtils . can ( "MANAGE_ROLES" , user . id ) && BDFDB . LanguageUtils . LanguageStrings . ROLES ] . filter ( n => n ) . join ( ", " ) ;
break ;
}
let tagColor = BDFDB . ColorUtils . convert ( member . colorString , "RGBA" ) ;
let isBright = BDFDB . ColorUtils . isBright ( tagColor ) ;
tagColor = isBright ? ( settings . useBlackFont ? tagColor : BDFDB . ColorUtils . change ( tagColor , - 0.3 ) ) : tagColor ;
tag = BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . BotTag , {
className : config . tagClass ,
useRemSizes : config . useRem ,
invertColor : config . inverted ,
style : {
backgroundColor : config . inverted ? ( isBright && settings . useBlackFont ? "black" : null ) : tagColor ,
color : ! config . inverted ? ( isBright && settings . useBlackFont ? "black" : null ) : tagColor
} ,
tag : inputs [ input ]
} ) ;
if ( label ) tag = BDFDB . ReactUtils . createElement ( BDFDB . LibraryComponents . TooltipContainer , {
text : label ,
children : tag
} ) ;
}
children . splice ( insertIndex , 0 , tag ) ;
2020-02-04 08:20:40 +01:00
}
2020-05-25 17:16:19 +02:00
2020-09-19 20:49:33 +02:00
getUserType ( user , channelId ) {
if ( ! user ) return userTypes . NONE ;
let channel = BDFDB . LibraryModules . ChannelStore . getChannel ( channelId || BDFDB . LibraryModules . LastChannelStore . getChannelId ( ) ) ;
if ( ! channel ) return userTypes . NONE ;
let guild = BDFDB . LibraryModules . GuildStore . getGuild ( channel . guild _id ) ;
let isOwner = channel . ownerId == user . id || guild && guild . ownerId == user . id ;
if ( isOwner ) return userTypes . OWNER ;
else if ( settings . addForAdmins && BDFDB . UserUtils . can ( "ADMINISTRATOR" , user . id ) && ! ( settings . ignoreBotAdmins && user . bot ) ) return userTypes . ADMIN ;
else if ( settings . addForManagement && ( BDFDB . UserUtils . can ( "MANAGE_GUILD" , user . id ) || BDFDB . UserUtils . can ( "MANAGE_CHANNELS" , user . id ) || BDFDB . UserUtils . can ( "MANAGE_ROLES" , user . id ) ) && ! ( settings . ignoreBotAdmins && user . bot ) ) return userTypes . MANAGEMENT ;
return userTypes . NONE ;
2020-08-31 23:32:22 +02:00
}
2020-07-26 16:39:51 +02:00
2021-01-06 12:38:36 +01:00
setLabelsByLanguage ( ) {
2020-09-19 20:49:33 +02:00
switch ( BDFDB . LanguageUtils . getLanguage ( ) . id ) {
2020-12-21 19:56:36 +01:00
case "bg" : // Bulgarian
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Управление"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "da" : // Danish
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Ledelse"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "de" : // German
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Verwaltung"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "el" : // Greek
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Διαχείριση"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "es" : // Spanish
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Administración"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "fi" : // Finnish
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Johto"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "fr" : // French
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "La gestion"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "hr" : // Croatian
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Upravljanje"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "hu" : // Hungarian
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Menedzsment"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "it" : // Italian
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Gestione"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "ja" : // Japanese
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "管理"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "ko" : // Korean
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "조치"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "lt" : // Lithuanian
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Valdymas"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "nl" : // Dutch
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Beheer"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "no" : // Norwegian
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Ledelse"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "pl" : // Polish
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Zarządzanie"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "pt-BR" : // Portuguese (Brazil)
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Gestão"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "ro" : // Romanian
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Administrare"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "ru" : // Russian
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Управление"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "sv" : // Swedish
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "Förvaltning"
2020-09-19 20:49:33 +02:00
} ;
2020-12-21 19:56:36 +01:00
case "th" : // Thai
2020-09-19 20:49:33 +02:00
return {
2020-12-21 19:56:36 +01:00
management : "การจัดการ"
} ;
case "tr" : // Turkish
return {
management : "Yönetim"
} ;
case "uk" : // Ukrainian
return {
management : "Управління"
} ;
case "vi" : // Vietnamese
return {
management : "Sự quản lý"
} ;
2021-01-15 17:54:22 +01:00
case "zh-CN" : // Chinese (China)
2020-12-21 19:56:36 +01:00
return {
management : "管理"
} ;
2021-01-15 17:54:22 +01:00
case "zh-TW" : // Chinese (Taiwan)
2020-12-21 19:56:36 +01:00
return {
management : "管理"
} ;
default : // English
return {
management : "Management"
2020-09-19 20:49:33 +02:00
} ;
}
}
} ;
2020-10-09 21:09:35 +02:00
} ) ( window . BDFDB _Global . PluginUtils . buildPlugin ( config ) ) ;
2020-09-19 20:49:33 +02:00
} ) ( ) ;