Wip page auth discord
This commit is contained in:
@@ -1,4 +1,6 @@
|
|||||||
import webbrowser
|
import webbrowser
|
||||||
|
from sys import platform
|
||||||
|
from os import environ
|
||||||
|
|
||||||
from PySide6 import QtGui
|
from PySide6 import QtGui
|
||||||
from PySide6.QtCore import Qt
|
from PySide6.QtCore import Qt
|
||||||
@@ -12,6 +14,9 @@ from controllers.glow_animator import GlowAnimator
|
|||||||
from controllers.window_dragger import WindowDragger
|
from controllers.window_dragger import WindowDragger
|
||||||
from fake_patch_notes import patch_note
|
from fake_patch_notes import patch_note
|
||||||
|
|
||||||
|
# For Linux Wayland to authorize moving window
|
||||||
|
if platform.startswith('linux'):
|
||||||
|
environ["QT_QPA_PLATFORM"] = "xcb"
|
||||||
|
|
||||||
class MainWindow(QMainWindow):
|
class MainWindow(QMainWindow):
|
||||||
def __init__(self, bundle_dir):
|
def __init__(self, bundle_dir):
|
||||||
|
|||||||
@@ -1,19 +1,12 @@
|
|||||||
|
QLabel {
|
||||||
|
color: rgb(255, 255, 255);
|
||||||
|
}
|
||||||
|
|
||||||
#main_container {
|
#main_container {
|
||||||
border-radius: 30px;
|
border-radius: 30px;
|
||||||
/*background-image: url(:/assets/background.png);
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
background-position: center; */
|
|
||||||
/*background: qlineargradient(x1:0, y1:0, x2:0, y2:1,
|
|
||||||
stop: 0 #050a0f,
|
|
||||||
stop: 1 #0f172a);*/
|
|
||||||
background: qradialgradient(cx:0.5, cy:0.5, radius:0.8, fx:0.5, fy:0.5,
|
background: qradialgradient(cx:0.5, cy:0.5, radius:0.8, fx:0.5, fy:0.5,
|
||||||
stop: 0 #16213e,
|
stop: 0 #16213e,
|
||||||
stop: 1 #0a0e14);
|
stop: 1 #0a0e14);
|
||||||
|
|
||||||
/*background: qlineargradient(x1:0, y1:0, x2:1, y2:1,
|
|
||||||
stop: 0 #0d1117,
|
|
||||||
stop: 0.7 #0d1117,
|
|
||||||
stop: 1 #1e3a8a); /* Une pointe de bleu plus vif en bas à droite */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QFrame#logo_frame {
|
QFrame#logo_frame {
|
||||||
@@ -27,13 +20,16 @@ QFrame#frame_2 QLabel {
|
|||||||
}
|
}
|
||||||
|
|
||||||
QFrame#frame_2 QLabel#discord_title_label {
|
QFrame#frame_2 QLabel#discord_title_label {
|
||||||
color: rgb(255, 255, 255);
|
font-size: 28px;
|
||||||
font-size: 24px;
|
color: rgb(255, 255, 255) /* label enfant, obligé de définir la couleur car ne prend pas la général */
|
||||||
|
}
|
||||||
|
|
||||||
|
QFrame#frame_2 QLabel#label_2 {
|
||||||
|
/* font-family: 'sans serif'; */
|
||||||
}
|
}
|
||||||
|
|
||||||
QLabel#maintitle_label {
|
QLabel#maintitle_label {
|
||||||
font-size: 38px;
|
font-size: 38px;
|
||||||
color: rgb(255, 255, 255);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QLabel#subtitle_label {
|
QLabel#subtitle_label {
|
||||||
@@ -46,7 +42,7 @@ QLabel#queue_position {
|
|||||||
}
|
}
|
||||||
|
|
||||||
QLabel#queue_lbl {
|
QLabel#queue_lbl {
|
||||||
color: rgb(255, 255, 255);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QPushButton#connexion_btn {
|
QPushButton#connexion_btn {
|
||||||
@@ -75,48 +71,6 @@ QPushButton#connexionBtn:pressed {
|
|||||||
padding-top: 12px; /* Effet d'enfoncement */
|
padding-top: 12px; /* Effet d'enfoncement */
|
||||||
}
|
}
|
||||||
|
|
||||||
/* État normal - Bleu Cyan */
|
|
||||||
/* QPushButton#staff_btn {
|
|
||||||
background: qlineargradient(x1:0, y1:0, x2:0, y2:1,
|
|
||||||
stop:0 #00d2ff, stop:1 #3a7bd5);
|
|
||||||
color: white;
|
|
||||||
border-radius: 12px;
|
|
||||||
border: 1px solid #2d5ea3;
|
|
||||||
padding: 5px 15px;
|
|
||||||
}
|
|
||||||
|
|
||||||
QPushButton#staff_btn:hover {
|
|
||||||
background: qlineargradient(x1:0, y1:0, x2:0, y2:1,
|
|
||||||
stop:0 #33dbff, stop:1 #528ce0);
|
|
||||||
border: 1px solid #3a7bd5;
|
|
||||||
}
|
|
||||||
|
|
||||||
QPushButton#staff_btn:pressed {
|
|
||||||
background-color: #2d5ea3;
|
|
||||||
padding-top: 7px;
|
|
||||||
} */
|
|
||||||
|
|
||||||
/* État normal - Doré dégradé */
|
|
||||||
/* QPushButton#staff_btn {
|
|
||||||
background: qlineargradient(x1:0, y1:0, x2:0, y2:1,
|
|
||||||
stop:0 #f1c40f, stop:1 #e67e22);
|
|
||||||
color: white;
|
|
||||||
border-radius: 12px;
|
|
||||||
border: 1px solid #d35400;
|
|
||||||
padding: 5px 15px;
|
|
||||||
}
|
|
||||||
|
|
||||||
QPushButton#staff_btn:hover {
|
|
||||||
background: qlineargradient(x1:0, y1:0, x2:0, y2:1,
|
|
||||||
stop:0 #f39c12, stop:1 #f1c40f);
|
|
||||||
border: 1px solid #e67e22;
|
|
||||||
}
|
|
||||||
|
|
||||||
QPushButton#staff_btn:pressed {
|
|
||||||
background-color: #d35400;
|
|
||||||
padding-top: 7px;
|
|
||||||
} */
|
|
||||||
|
|
||||||
/* État normal - Rouge Corail Vibrant */
|
/* État normal - Rouge Corail Vibrant */
|
||||||
QPushButton#staff_btn {
|
QPushButton#staff_btn {
|
||||||
background: qlineargradient(x1:0, y1:0, x2:0, y2:1,
|
background: qlineargradient(x1:0, y1:0, x2:0, y2:1,
|
||||||
@@ -161,7 +115,6 @@ QPushButton#discord_auth_btn:hover
|
|||||||
}
|
}
|
||||||
|
|
||||||
QPushButton#intranet_btn:hover {
|
QPushButton#intranet_btn:hover {
|
||||||
/* background: rgb(68, 124, 143); */
|
|
||||||
background-color: rgba(0, 242, 255, 0.15); /* Teinte turquoise légère en fond */
|
background-color: rgba(0, 242, 255, 0.15); /* Teinte turquoise légère en fond */
|
||||||
border: 2px solid #00f2ff; /* Bordure turquoise vive et épaisse */
|
border: 2px solid #00f2ff; /* Bordure turquoise vive et épaisse */
|
||||||
color: #ffffff;
|
color: #ffffff;
|
||||||
|
|||||||
@@ -997,9 +997,15 @@
|
|||||||
<x>10</x>
|
<x>10</x>
|
||||||
<y>10</y>
|
<y>10</y>
|
||||||
<width>700</width>
|
<width>700</width>
|
||||||
<height>480</height>
|
<height>482</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>700</width>
|
||||||
|
<height>16777215</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
<property name="frameShape">
|
<property name="frameShape">
|
||||||
<enum>QFrame::Shape::NoFrame</enum>
|
<enum>QFrame::Shape::NoFrame</enum>
|
||||||
</property>
|
</property>
|
||||||
@@ -1007,8 +1013,35 @@
|
|||||||
<enum>QFrame::Shadow::Raised</enum>
|
<enum>QFrame::Shadow::Raised</enum>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||||
|
<property name="spacing">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QFrame" name="frame_6">
|
<widget class="QFrame" name="auth_discord_page_title">
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>0</width>
|
||||||
|
<height>80</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>16777215</width>
|
||||||
|
<height>80</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
<property name="frameShape">
|
<property name="frameShape">
|
||||||
<enum>QFrame::Shape::NoFrame</enum>
|
<enum>QFrame::Shape::NoFrame</enum>
|
||||||
</property>
|
</property>
|
||||||
@@ -1016,6 +1049,21 @@
|
|||||||
<enum>QFrame::Shadow::Raised</enum>
|
<enum>QFrame::Shadow::Raised</enum>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
|
<property name="spacing">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer_2">
|
<spacer name="horizontalSpacer_2">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
@@ -1086,38 +1134,86 @@
|
|||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QFrame" name="frame_7">
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>700</width>
|
||||||
|
<height>16777215</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="frameShape">
|
||||||
|
<enum>QFrame::Shape::NoFrame</enum>
|
||||||
|
</property>
|
||||||
|
<property name="frameShadow">
|
||||||
|
<enum>QFrame::Shadow::Raised</enum>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||||
|
<property name="spacing">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="verticalSpacer_4">
|
<spacer name="verticalSpacer_4">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Orientation::Vertical</enum>
|
<enum>Qt::Orientation::Vertical</enum>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="sizeType">
|
||||||
|
<enum>QSizePolicy::Policy::Fixed</enum>
|
||||||
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>0</width>
|
||||||
<height>40</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="info_discord_label">
|
<widget class="QLabel" name="label_2">
|
||||||
<property name="text">
|
<property name="minimumSize">
|
||||||
<string>Il semblerait que tu n'ai pas authentifié au moins une fois le launcher avec Discord</string>
|
<size>
|
||||||
|
<width>0</width>
|
||||||
|
<height>50</height>
|
||||||
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="wordWrap">
|
<property name="maximumSize">
|
||||||
<bool>true</bool>
|
<size>
|
||||||
|
<width>16777215</width>
|
||||||
|
<height>50</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>UNE PREMIÈRE AUTHENTIFICATION AVEC DISCORD EST NÉCESSAIRE.</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignmentFlag::AlignCenter</set>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="verticalSpacer_5">
|
<spacer name="verticalSpacer_2">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Orientation::Vertical</enum>
|
<enum>Qt::Orientation::Vertical</enum>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="sizeType">
|
||||||
|
<enum>QSizePolicy::Policy::Fixed</enum>
|
||||||
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>20</width>
|
||||||
<height>40</height>
|
<height>30</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
@@ -1131,6 +1227,21 @@
|
|||||||
<enum>QFrame::Shadow::Raised</enum>
|
<enum>QFrame::Shadow::Raised</enum>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||||
|
<property name="spacing">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer_7">
|
<spacer name="horizontalSpacer_7">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
@@ -1190,7 +1301,7 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="verticalSpacer_2">
|
<spacer name="verticalSpacer_5">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Orientation::Vertical</enum>
|
<enum>Qt::Orientation::Vertical</enum>
|
||||||
</property>
|
</property>
|
||||||
@@ -1200,13 +1311,16 @@
|
|||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>20</width>
|
||||||
<height>171</height>
|
<height>200</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
</widget>
|
</widget>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
|||||||
Reference in New Issue
Block a user