Skip to content
This repository was archived by the owner on Mar 29, 2021. It is now read-only.

Commit f76ec15

Browse files
committed
moving the chat-options properly
adding whitelist-option for raids fixes #285
1 parent a7aa383 commit f76ec15

5 files changed

Lines changed: 18 additions & 2 deletions

File tree

src/mods/chat.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -854,7 +854,7 @@ idrinth.chat = {
854854
event.preventDefault ();
855855
idrinth.ui.base.appendChild ( idrinth.ui.buildElement ( {
856856
type: 'ul',
857-
css: 'idrinth-hovering-box',
857+
css: 'idrinth-hovering-box hover-over',
858858
children: [ {
859859
css: 'clipboard-copy',
860860
content: idrinth.text.get ( "chat.actions.copyIdPasswort" ),

src/mods/raids.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -395,7 +395,10 @@ idrinth.raids = {
395395
if ( !raid.joined ) {
396396
added++;
397397
options[0] ( key );//post link
398-
if ( !idrinth.settings.get ( "bannedRaids#" + raid.raid ) ) {
398+
if (
399+
(!idrinth.settings.get ( "bannedRaids#" + raid.raid ) && !idrinth.settings.get("raidWhitelist")) ||
400+
(idrinth.settings.get ( "bannedRaids#" + raid.raid ) && idrinth.settings.get("raidWhitelist"))
401+
) {
399402
for (var count = 1; count < options.length; count++) {
400403
options[count] ( key );
401404
}

src/mods/settings.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@ idrinth.settings = {
99
* @type Boolean
1010
*/
1111
raids: false,
12+
/**
13+
*
14+
* @type Boolean
15+
*/
16+
raidWhitelist: false,
1217
/**
1318
*
1419
* @type String

src/mods/ui.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -687,6 +687,11 @@ idrinth.ui = {
687687
rType: '#input',
688688
type: 'checkbox',
689689
label: "setting.enableFavRequest"
690+
},{
691+
name: 'raidWhitelist',
692+
rType: '#input',
693+
type: 'checkbox',
694+
label: "setting.raidWhitelist"
690695
}, {
691696
name: 'favs',
692697
rType: '#input',

src/root.scss

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020
display: block;
2121
box-shadow: 2px 2px 2px 1px rgba(0, 0, 0, 0.65);
2222
}
23+
.idrinth-hovering-box.hover-over {
24+
@include z-offset(100);
25+
}
2326

2427
.idrinth-hovering-box,
2528
.idrinth-hovering-box * {

0 commit comments

Comments
 (0)